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

Commitcdedfe6

Browse files
committed
Cast NULL to a pointer type in the execl() call, to avoid a compiler warning on
some platforms and possibly a bug. Per report from Stefan and subsequentdiscussion.
1 parentdc32d2c commitcdedfe6

File tree

1 file changed

+2
-2
lines changed

1 file changed

+2
-2
lines changed

‎src/test/regress/pg_regress.c

Lines changed: 2 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -11,7 +11,7 @@
1111
* Portions Copyright (c) 1996-2007, PostgreSQL Global Development Group
1212
* Portions Copyright (c) 1994, Regents of the University of California
1313
*
14-
* $PostgreSQL: pgsql/src/test/regress/pg_regress.c,v 1.35 2007/06/12 13:54:58 mha Exp $
14+
* $PostgreSQL: pgsql/src/test/regress/pg_regress.c,v 1.36 2007/07/18 21:19:17 alvherre Exp $
1515
*
1616
*-------------------------------------------------------------------------
1717
*/
@@ -911,7 +911,7 @@ spawn_process(const char *cmdline)
911911
char*cmdline2=malloc(strlen(cmdline)+6);
912912

913913
sprintf(cmdline2,"exec %s",cmdline);
914-
execl(shellprog,shellprog,"-c",cmdline2,NULL);
914+
execl(shellprog,shellprog,"-c",cmdline2,(char*)NULL);
915915
fprintf(stderr,_("%s: could not exec \"%s\": %s\n"),
916916
progname,shellprog,strerror(errno));
917917
exit(1);/* not exit_nicely here... */

0 commit comments

Comments
 (0)

[8]ページ先頭

©2009-2025 Movatter.jp