mirror of
https://github.com/postgres/postgres.git
synced 2025-04-27 22:56:53 +03:00
psql: fix \copy stdin trailing space requirement
Previously a trailing space was required for \copy ... stdin: copy foo from stdin ; Etsuro Fujita
This commit is contained in:
parent
601f48076f
commit
d8a5608d4a
@ -196,7 +196,7 @@ parse_slash_copy(const char *args)
|
|||||||
goto error;
|
goto error;
|
||||||
|
|
||||||
/* { 'filename' | PROGRAM 'command' | STDIN | STDOUT | PSTDIN | PSTDOUT } */
|
/* { 'filename' | PROGRAM 'command' | STDIN | STDOUT | PSTDIN | PSTDOUT } */
|
||||||
token = strtokx(NULL, whitespace, NULL, "'",
|
token = strtokx(NULL, whitespace, ";", "'",
|
||||||
0, false, false, pset.encoding);
|
0, false, false, pset.encoding);
|
||||||
if (!token)
|
if (!token)
|
||||||
goto error;
|
goto error;
|
||||||
@ -205,7 +205,7 @@ parse_slash_copy(const char *args)
|
|||||||
{
|
{
|
||||||
int toklen;
|
int toklen;
|
||||||
|
|
||||||
token = strtokx(NULL, whitespace, NULL, "'",
|
token = strtokx(NULL, whitespace, ";", "'",
|
||||||
0, false, false, pset.encoding);
|
0, false, false, pset.encoding);
|
||||||
if (!token)
|
if (!token)
|
||||||
goto error;
|
goto error;
|
||||||
|
Loading…
x
Reference in New Issue
Block a user