projects
/
postgresql.git
/ commitdiff
commit
grep
author
committer
pickaxe
?
search:
re
summary
|
shortlog
|
log
|
commit
| commitdiff |
tree
raw
|
patch
| inline |
side by side
(parent:
ad76242
)
Fix error messages for FreeFile in COPY command.
author
Itagaki Takahiro
<
[email protected]
>
Mon, 7 Feb 2011 01:46:56 +0000
(10:46 +0900)
committer
Itagaki Takahiro
<
[email protected]
>
Mon, 7 Feb 2011 01:46:56 +0000
(10:46 +0900)
They are extracted from COPY API patch.
suggested by Noah Misch
src/backend/commands/copy.c
patch
|
blob
|
blame
|
history
diff --git
a/src/backend/commands/copy.c
b/src/backend/commands/copy.c
index 841bf220c766d390773b3afef4d5234d0d6e3dec..3350ca0b6ef510999a266fd70badfd6b51ebfb01 100644
(file)
--- a/
src/backend/commands/copy.c
+++ b/
src/backend/commands/copy.c
@@
-1319,7
+1319,7
@@
DoCopyTo(CopyState cstate)
if (FreeFile(cstate->copy_file))
ereport(ERROR,
(errcode_for_file_access(),
- errmsg("could not
write to
file \"%s\": %m",
+ errmsg("could not
close
file \"%s\": %m",
cstate->filename)));
}
}
@@
-2263,7
+2263,7
@@
CopyFrom(CopyState cstate)
if (FreeFile(cstate->copy_file))
ereport(ERROR,
(errcode_for_file_access(),
- errmsg("could not
read from
file \"%s\": %m",
+ errmsg("could not
close
file \"%s\": %m",
cstate->filename)));
}