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

Commit2597056

Browse files
committed
Use sizeof() rather than strlen() in array size.
1 parente6cba71 commit2597056

File tree

1 file changed

+2
-2
lines changed

1 file changed

+2
-2
lines changed

‎src/port/path.c

Lines changed: 2 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -8,7 +8,7 @@
88
*
99
*
1010
* IDENTIFICATION
11-
* $PostgreSQL: pgsql/src/port/path.c,v 1.19 2004/06/10 22:26:24 momjian Exp $
11+
* $PostgreSQL: pgsql/src/port/path.c,v 1.20 2004/06/11 17:09:13 momjian Exp $
1212
*
1313
*-------------------------------------------------------------------------
1414
*/
@@ -252,7 +252,7 @@ set_pglocale_pgservice(const char *argv0, const char *app)
252252
{
253253
charpath[MAXPGPATH];
254254
charmy_exec_path[MAXPGPATH];
255-
charenv_path[MAXPGPATH+strlen("PGLOCALEDIR=")];/* longer than PGSYSCONFDIR */
255+
charenv_path[MAXPGPATH+sizeof("PGLOCALEDIR=")];/* longer than PGSYSCONFDIR */
256256

257257
/* don't set LC_ALL in the backend */
258258
if (strcmp(app,"postgres")!=0)

0 commit comments

Comments
 (0)

[8]ページ先頭

©2009-2025 Movatter.jp