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

Commit81cca21

Browse files
committed
Allow compilation when CODESET is not defined (OpenBSD).
1 parent7a7ffe9 commit81cca21

File tree

1 file changed

+5
-5
lines changed

1 file changed

+5
-5
lines changed

‎src/bin/initdb/initdb.c

Lines changed: 5 additions & 5 deletions
Original file line numberDiff line numberDiff line change
@@ -39,7 +39,7 @@
3939
* Portions Copyright (c) 1994, Regents of the University of California
4040
* Portions taken from FreeBSD.
4141
*
42-
* $PostgreSQL: pgsql/src/bin/initdb/initdb.c,v 1.47 2004/08/09 20:20:47 tgl Exp $
42+
* $PostgreSQL: pgsql/src/bin/initdb/initdb.c,v 1.48 2004/08/11 11:06:23 petere Exp $
4343
*
4444
*-------------------------------------------------------------------------
4545
*/
@@ -619,7 +619,7 @@ get_encoding_id(char *encoding_name)
619619
exit(1);
620620
}
621621

622-
#ifdefHAVE_LANGINFO_H
622+
#if defined(HAVE_LANGINFO_H)&& defined(CODESET)
623623
/*
624624
* Checks whether the encoding selected for PostgreSQL and the
625625
* encoding used by the system locale match.
@@ -802,7 +802,7 @@ find_matching_encoding(const char *ctype)
802802
free(sys);
803803
return-1;
804804
}
805-
#endif/* HAVE_LANGINFO_H */
805+
#endif/* HAVE_LANGINFO_H&& CODESET*/
806806

807807
/*
808808
* get short version of VERSION
@@ -2322,7 +2322,7 @@ main(int argc, char *argv[])
23222322
lc_time);
23232323
}
23242324

2325-
#ifdefHAVE_LANGINFO_H
2325+
#if defined(HAVE_LANGINFO_H)&& defined(CODESET)
23262326
if (strcmp(lc_ctype,"C")!=0&&strcmp(lc_ctype,"POSIX")!=0)
23272327
{
23282328
if (strlen(encoding)==0)
@@ -2346,7 +2346,7 @@ main(int argc, char *argv[])
23462346
else
23472347
check_encodings_match(atoi(encodingid),lc_ctype);
23482348
}
2349-
#endif/* HAVE_LANGINFO_H */
2349+
#endif/* HAVE_LANGINFO_H&& CODESET*/
23502350

23512351
printf("\n");
23522352

0 commit comments

Comments
 (0)

[8]ページ先頭

©2009-2025 Movatter.jp