Movatterモバイル変換


[0]ホーム

URL:


Skip to content

Navigation Menu

Sign in
Appearance settings

Search code, repositories, users, issues, pull requests...

Provide feedback

We read every piece of feedback, and take your input very seriously.

Saved searches

Use saved searches to filter your results more quickly

Sign up
Appearance settings

Commit6d8b8a5

Browse files
committed
[ Have readline save edit history.]
>> > I already posted a one-line patch to implement this, but it doesn't> > seem to hve come through to the list. Here it is inline, instead of as> > an attachment:>> We need this to work without readline as well. (Of course there won't be> any history, but it needs to compile.)<blush> Even after slogging my way through the nesting #ifdefs for readlineand win32, I forgot! Let's make that a three line patch, then.Ross J. Reedstrom
1 parent68c67fc commit6d8b8a5

File tree

1 file changed

+4
-1
lines changed

1 file changed

+4
-1
lines changed

‎src/bin/psql/command.c

Lines changed: 4 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -3,7 +3,7 @@
33
*
44
* Copyright 2000-2002 by PostgreSQL Global Development Group
55
*
6-
* $Header: /cvsroot/pgsql/src/bin/psql/command.c,v 1.88 2003/01/10 21:57:44 petere Exp $
6+
* $Header: /cvsroot/pgsql/src/bin/psql/command.c,v 1.89 2003/02/13 04:08:16 momjian Exp $
77
*/
88
#include"postgres_fe.h"
99
#include"command.h"
@@ -1648,6 +1648,9 @@ do_edit(const char *filename_arg, PQExpBuffer query_buf)
16481648
error= true;
16491649
}
16501650

1651+
#ifdefUSE_READLINE
1652+
replace_history_entry(where_history(),query_buf->data,NULL);
1653+
#endif
16511654
fclose(stream);
16521655
}
16531656

0 commit comments

Comments
 (0)

[8]ページ先頭

©2009-2025 Movatter.jp