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

Commitc6d3c1b

Browse files
committed
Fix seriously broken patch for psql '' ... per its comment, emit() is
NOT the thing to use here.
1 parent8f165ee commitc6d3c1b

File tree

1 file changed

+6
-4
lines changed

1 file changed

+6
-4
lines changed

‎src/bin/psql/psqlscan.l

Lines changed: 6 additions & 4 deletions
Original file line numberDiff line numberDiff line change
@@ -33,7 +33,7 @@
3333
* Portions Copyright (c) 1994, Regents of the University of California
3434
*
3535
* IDENTIFICATION
36-
* $PostgreSQL: pgsql/src/bin/psql/psqlscan.l,v 1.19 2006/05/31 11:35:17 momjian Exp $
36+
* $PostgreSQL: pgsql/src/bin/psql/psqlscan.l,v 1.20 2006/05/3122:11:44 tgl Exp $
3737
*
3838
*-------------------------------------------------------------------------
3939
*/
@@ -857,12 +857,14 @@ other.
857857
}
858858

859859
<xslashquote>{
860-
/* single-quoted text: copy literally except for backslash sequences */
860+
/*
861+
* single-quoted text: copy literally except for '' and backslash
862+
* sequences
863+
*/
861864

862865
{quote}{return LEXRES_OK; }
863866

864-
/* We don't need a state here because we are already in a string */
865-
{xqdouble}{emit("'",1); }
867+
{xqdouble}{appendPQExpBufferChar(output_buf,'\''); }
866868

867869
"\\n"{appendPQExpBufferChar(output_buf,'\n'); }
868870
"\\t"{appendPQExpBufferChar(output_buf,'\t'); }

0 commit comments

Comments
 (0)

[8]ページ先頭

©2009-2025 Movatter.jp