summaryrefslogtreecommitdiff
diff options
context:
space:
mode:
authorAndrew Dunstan2011-04-27 15:28:14 +0000
committerAndrew Dunstan2011-04-27 15:28:14 +0000
commit348c10efe08f01872daeeb62f32c8e362fcbba69 (patch)
tree181364b0daa08783f4a75917787d96bd1bd56c5a
parent9b1508af8971c1627cda5bb65f5e9eddb9a1a55e (diff)
Revert "Remove hard coded formats for INT64 and use configured settings instead."
This reverts commit 9b1508af8971c1627cda5bb65f5e9eddb9a1a55e. As requested by Tom.
-rw-r--r--src/backend/postmaster/postmaster.c2
-rw-r--r--src/interfaces/ecpg/ecpglib/execute.c8
2 files changed, 5 insertions, 5 deletions
diff --git a/src/backend/postmaster/postmaster.c b/src/backend/postmaster/postmaster.c
index 0d98b7ec26..c0cf0336a1 100644
--- a/src/backend/postmaster/postmaster.c
+++ b/src/backend/postmaster/postmaster.c
@@ -3795,7 +3795,7 @@ internal_forkexec(int argc, char *argv[], Port *port)
/* Insert temp file name after --fork argument */
#ifdef _WIN64
- sprintf(paramHandleStr, UINT64_FORMAT, (LONG_PTR) paramHandle);
+ sprintf(paramHandleStr, "%llu", (LONG_PTR) paramHandle);
#else
sprintf(paramHandleStr, "%lu", (DWORD) paramHandle);
#endif
diff --git a/src/interfaces/ecpg/ecpglib/execute.c b/src/interfaces/ecpg/ecpglib/execute.c
index 0e908c99b0..970fa93509 100644
--- a/src/interfaces/ecpg/ecpglib/execute.c
+++ b/src/interfaces/ecpg/ecpglib/execute.c
@@ -689,12 +689,12 @@ ecpg_store_input(const int lineno, const bool force_indicator, const struct vari
strcpy(mallocedval, "array [");
for (element = 0; element < asize; element++)
- sprintf(mallocedval + strlen(mallocedval), INT64_FORMAT ",", ((long long int *) var->value)[element]);
+ sprintf(mallocedval + strlen(mallocedval), "%lld,", ((long long int *) var->value)[element]);
strcpy(mallocedval + strlen(mallocedval) - 1, "]");
}
else
- sprintf(mallocedval, INT64_FORMAT, *((long long int *) var->value));
+ sprintf(mallocedval, "%lld", *((long long int *) var->value));
*tobeinserted_p = mallocedval;
break;
@@ -708,12 +708,12 @@ ecpg_store_input(const int lineno, const bool force_indicator, const struct vari
strcpy(mallocedval, "array [");
for (element = 0; element < asize; element++)
- sprintf(mallocedval + strlen(mallocedval), UINT64_FORMAT ",", ((unsigned long long int *) var->value)[element]);
+ sprintf(mallocedval + strlen(mallocedval), "%llu,", ((unsigned long long int *) var->value)[element]);
strcpy(mallocedval + strlen(mallocedval) - 1, "]");
}
else
- sprintf(mallocedval, UINT64_FORMAT, *((unsigned long long int *) var->value));
+ sprintf(mallocedval, "%llu", *((unsigned long long int *) var->value));
*tobeinserted_p = mallocedval;
break;