mirror of
https://github.com/Gnucash/gnucash.git
synced 2025-02-25 18:55:30 -06:00
Only use long long format specifiers if available - avoids error message when compiler thinks they're not available.
git-svn-id: svn+ssh://svn.gnucash.org/repo/gnucash/trunk@18858 57a11ea4-9604-0410-9ed3-97b8803252fd
This commit is contained in:
parent
ddf85bd445
commit
c3997d495a
@ -219,8 +219,13 @@ init_from_file(const char *filename, size_t max_size)
|
|||||||
|
|
||||||
file_bytes = init_from_stream(fp, max_size);
|
file_bytes = init_from_stream(fp, max_size);
|
||||||
|
|
||||||
|
#ifdef HAVE_SCANF_LLD
|
||||||
PINFO ("guid_init got %llu bytes from %s", (unsigned long long int) file_bytes,
|
PINFO ("guid_init got %llu bytes from %s", (unsigned long long int) file_bytes,
|
||||||
filename);
|
filename);
|
||||||
|
#else
|
||||||
|
PINFO ("guid_init got %lu bytes from %s", (unsigned long int) file_bytes,
|
||||||
|
filename);
|
||||||
|
#endif
|
||||||
|
|
||||||
total += file_bytes;
|
total += file_bytes;
|
||||||
|
|
||||||
@ -446,12 +451,21 @@ guid_init(void)
|
|||||||
/* time in secs and clock ticks */
|
/* time in secs and clock ticks */
|
||||||
bytes += init_from_time();
|
bytes += init_from_time();
|
||||||
|
|
||||||
|
#ifdef HAVE_SCANF_LLD
|
||||||
PINFO ("got %llu bytes", (unsigned long long int) bytes);
|
PINFO ("got %llu bytes", (unsigned long long int) bytes);
|
||||||
|
|
||||||
if (bytes < THRESHOLD)
|
if (bytes < THRESHOLD)
|
||||||
PWARN("only got %llu bytes.\n"
|
PWARN("only got %llu bytes.\n"
|
||||||
"The identifiers might not be very random.\n",
|
"The identifiers might not be very random.\n",
|
||||||
(unsigned long long int)bytes);
|
(unsigned long long int)bytes);
|
||||||
|
#else
|
||||||
|
PINFO ("got %lu bytes", (unsigned long int) bytes);
|
||||||
|
|
||||||
|
if (bytes < THRESHOLD)
|
||||||
|
PWARN("only got %lu bytes.\n"
|
||||||
|
"The identifiers might not be very random.\n",
|
||||||
|
(unsigned long int)bytes);
|
||||||
|
#endif
|
||||||
|
|
||||||
guid_initialized = TRUE;
|
guid_initialized = TRUE;
|
||||||
}
|
}
|
||||||
|
Loading…
Reference in New Issue
Block a user