|
42 | 42 | * Portions Copyright (c) 1994, Regents of the University of California
|
43 | 43 | * Portions taken from FreeBSD.
|
44 | 44 | *
|
45 |
| - * $PostgreSQL: pgsql/src/bin/initdb/initdb.c,v 1.137 2007/05/3115:13:03 petere Exp $ |
| 45 | + * $PostgreSQL: pgsql/src/bin/initdb/initdb.c,v 1.138 2007/07/11 23:15:38 tgl Exp $ |
46 | 46 | *
|
47 | 47 | *-------------------------------------------------------------------------
|
48 | 48 | */
|
@@ -2155,6 +2155,13 @@ escape_quotes(const char *src)
|
2155 | 2155 | returnresult;
|
2156 | 2156 | }
|
2157 | 2157 |
|
| 2158 | +/* Hack to suppress a warning about %x from some versions of gcc */ |
| 2159 | +staticinlinesize_t |
| 2160 | +my_strftime(char*s,size_tmax,constchar*fmt,conststructtm*tm) |
| 2161 | +{ |
| 2162 | +returnstrftime(s,max,fmt,tm); |
| 2163 | +} |
| 2164 | + |
2158 | 2165 | /*
|
2159 | 2166 | * Determine likely date order from locale
|
2160 | 2167 | */
|
@@ -2184,7 +2191,7 @@ locale_date_order(const char *locale)
|
2184 | 2191 | testtime.tm_mon=10;/* November, should come out as "11" */
|
2185 | 2192 | testtime.tm_year=133;/* 2033 */
|
2186 | 2193 |
|
2187 |
| -res=strftime(buf,sizeof(buf),"%x",&testtime); |
| 2194 | +res=my_strftime(buf,sizeof(buf),"%x",&testtime); |
2188 | 2195 |
|
2189 | 2196 | setlocale(LC_TIME,save);
|
2190 | 2197 | free(save);
|
|