Merge pull request #116 from MasahikoSawada/fix_format_ident

Change format identifier %lu to UINT64_FORMAT for portability.
This commit is contained in:
masahiko 2017-02-22 00:06:01 +09:00 committed by GitHub
commit b16886d4ea
2 changed files with 3 additions and 3 deletions

View File

@ -1307,7 +1307,7 @@ pgut_malloc(size_t size)
if ((ret = malloc(size)) == NULL)
ereport(FATAL,
(errcode_errno(),
errmsg("could not allocate memory (%lu bytes): ",
errmsg("could not allocate memory (" UINT64_FORMAT " bytes): ",
(unsigned long) size)));
return ret;
}
@ -1320,7 +1320,7 @@ pgut_realloc(void *p, size_t size)
if ((ret = realloc(p, size)) == NULL)
ereport(FATAL,
(errcode_errno(),
errmsg("could not re-allocate memory (%lu bytes): ",
errmsg("could not re-allocate memory (" UINT64_FORMAT " bytes): ",
(unsigned long) size)));
return ret;
}

View File

@ -1306,7 +1306,7 @@ repack_index_swap(PG_FUNCTION_ARGS)
orig_idx_oid);
execute(SPI_OK_SELECT, str.data);
if (SPI_processed != 1)
elog(ERROR, "Could not find index 'index_%u', found %lu matches",
elog(ERROR, "Could not find index 'index_%u', found " UINT64_FORMAT " matches",
orig_idx_oid, (uint64) SPI_processed);
tuptable = SPI_tuptable;