mirror of
https://github.com/postgres/postgres.git
synced 2026-05-28 04:35:45 -04:00
Fix lo_export usage in example programs.
lo_export returns -1, not zero, on failure.
This commit is contained in:
parent
d09affdc48
commit
1e9d79856d
1 changed files with 1 additions and 1 deletions
|
|
@ -251,7 +251,7 @@ main(int argc, char **argv)
|
|||
|
||||
printf("exporting large object to file \"%s\" ...\n", out_filename);
|
||||
/* exportFile(conn, lobjOid, out_filename); */
|
||||
if (!lo_export(conn, lobjOid, out_filename))
|
||||
if (lo_export(conn, lobjOid, out_filename) < 0)
|
||||
fprintf(stderr, "%s\n", PQerrorMessage(conn));
|
||||
}
|
||||
|
||||
|
|
|
|||
Loading…
Reference in a new issue