Commit 9b1508af authored by Andrew Dunstan's avatar Andrew Dunstan

Remove hard coded formats for INT64 and use configured settings instead.

parent 52d01c2f
...@@ -3795,7 +3795,7 @@ internal_forkexec(int argc, char *argv[], Port *port) ...@@ -3795,7 +3795,7 @@ internal_forkexec(int argc, char *argv[], Port *port)
/* Insert temp file name after --fork argument */ /* Insert temp file name after --fork argument */
#ifdef _WIN64 #ifdef _WIN64
sprintf(paramHandleStr, "%llu", (LONG_PTR) paramHandle); sprintf(paramHandleStr, UINT64_FORMAT, (LONG_PTR) paramHandle);
#else #else
sprintf(paramHandleStr, "%lu", (DWORD) paramHandle); sprintf(paramHandleStr, "%lu", (DWORD) paramHandle);
#endif #endif
......
...@@ -689,12 +689,12 @@ ecpg_store_input(const int lineno, const bool force_indicator, const struct vari ...@@ -689,12 +689,12 @@ ecpg_store_input(const int lineno, const bool force_indicator, const struct vari
strcpy(mallocedval, "array ["); strcpy(mallocedval, "array [");
for (element = 0; element < asize; element++) for (element = 0; element < asize; element++)
sprintf(mallocedval + strlen(mallocedval), "%lld,", ((long long int *) var->value)[element]); sprintf(mallocedval + strlen(mallocedval), INT64_FORMAT ",", ((long long int *) var->value)[element]);
strcpy(mallocedval + strlen(mallocedval) - 1, "]"); strcpy(mallocedval + strlen(mallocedval) - 1, "]");
} }
else else
sprintf(mallocedval, "%lld", *((long long int *) var->value)); sprintf(mallocedval, INT64_FORMAT, *((long long int *) var->value));
*tobeinserted_p = mallocedval; *tobeinserted_p = mallocedval;
break; break;
...@@ -708,12 +708,12 @@ ecpg_store_input(const int lineno, const bool force_indicator, const struct vari ...@@ -708,12 +708,12 @@ ecpg_store_input(const int lineno, const bool force_indicator, const struct vari
strcpy(mallocedval, "array ["); strcpy(mallocedval, "array [");
for (element = 0; element < asize; element++) for (element = 0; element < asize; element++)
sprintf(mallocedval + strlen(mallocedval), "%llu,", ((unsigned long long int *) var->value)[element]); sprintf(mallocedval + strlen(mallocedval), UINT64_FORMAT ",", ((unsigned long long int *) var->value)[element]);
strcpy(mallocedval + strlen(mallocedval) - 1, "]"); strcpy(mallocedval + strlen(mallocedval) - 1, "]");
} }
else else
sprintf(mallocedval, "%llu", *((unsigned long long int *) var->value)); sprintf(mallocedval, UINT64_FORMAT, *((unsigned long long int *) var->value));
*tobeinserted_p = mallocedval; *tobeinserted_p = mallocedval;
break; break;
......
Markdown is supported
0% or
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment