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

Commit354a39b

Browse files
committed
Clean up temp files from \e.
1 parentc85a8e9 commit354a39b

File tree

1 file changed

+9
-8
lines changed

1 file changed

+9
-8
lines changed

‎src/bin/psql/command.c

Lines changed: 9 additions & 8 deletions
Original file line numberDiff line numberDiff line change
@@ -3,7 +3,7 @@
33
*
44
* Copyright 2000 by PostgreSQL Global Development Group
55
*
6-
* $Header: /cvsroot/pgsql/src/bin/psql/command.c,v 1.26 2000/03/27 21:11:37 petere Exp $
6+
* $Header: /cvsroot/pgsql/src/bin/psql/command.c,v 1.27 2000/04/11 17:35:50 momjian Exp $
77
*/
88
#include"postgres.h"
99
#include"command.h"
@@ -1456,14 +1456,15 @@ do_edit(const char *filename_arg, PQExpBuffer query_buf)
14561456
fclose(stream);
14571457
}
14581458

1459-
/* remove temp file */
1460-
if (!filename_arg)
1459+
}
1460+
1461+
/* remove temp file */
1462+
if (!filename_arg)
1463+
{
1464+
if (remove(fname)==-1)
14611465
{
1462-
if (remove(fname)==-1)
1463-
{
1464-
psql_error("%s: %s\n",fname,strerror(errno));
1465-
error=true;
1466-
}
1466+
psql_error("%s: %s\n",fname,strerror(errno));
1467+
error=true;
14671468
}
14681469
}
14691470

0 commit comments

Comments
 (0)

[8]ページ先頭

©2009-2025 Movatter.jp