summaryrefslogtreecommitdiffstats
diff options
context:
space:
mode:
authorRainer Gerhards <rgerhards@adiscon.com>2005-06-28 13:34:18 +0000
committerRainer Gerhards <rgerhards@adiscon.com>2005-06-28 13:34:18 +0000
commit1399d6bd18217aced574ce66d0b39891f7bb495d (patch)
tree289a4f675daffdc42ce9d00387ffb9a616e1d8da
parent23968b1f758ae3a1a1cfb6ea2a8eb28cb7aa1ebf (diff)
downloadrsyslog-1399d6bd18217aced574ce66d0b39891f7bb495d.tar.gz
rsyslog-1399d6bd18217aced574ce66d0b39891f7bb495d.tar.xz
rsyslog-1399d6bd18217aced574ce66d0b39891f7bb495d.zip
remove some annoying printf format warnings
-rw-r--r--NEWS5
-rw-r--r--syslogd.c4
2 files changed, 7 insertions, 2 deletions
diff --git a/NEWS b/NEWS
index 51f04b52..24d8c852 100644
--- a/NEWS
+++ b/NEWS
@@ -5,6 +5,11 @@ Version 0.9.1 (RGer)
- changed the make file so that it contains more defines for
different environments (in the long term, we need a better
system for disabling/enabling features...)
+- changed some printf's printing off_t types to %lld and
+ explicit (long long) casts. I tried to figure out the exact type,
+ but did not succeed in this. In the worst case, ultra-large peta-
+ byte files will now display funny informational messages on rollover,
+ something I think we can live with for the next 10 years or so...
---------------------------------------------------------------------------
Version 0.9.0 (RGer)
diff --git a/syslogd.c b/syslogd.c
index 41637fa9..6e3fa8f6 100644
--- a/syslogd.c
+++ b/syslogd.c
@@ -3027,14 +3027,14 @@ again:
f->f_type = F_UNUSED;
snprintf(errMsg, sizeof(errMsg),
"no longer writing to file %s; grown beyond configured file size of %lld bytes, actual size %lld - configured command did not resolve situation\n",
- f->f_un.f_fname, f->f_sizeLimit, actualFileSize);
+ f->f_un.f_fname, (long long) f->f_sizeLimit, (long long) actualFileSize);
errno = 0;
logerror(errMsg);
return;
} else {
snprintf(errMsg, sizeof(errMsg),
"file %s had grown beyond configured file size of %lld bytes, actual size was %lld - configured command resolved situation\n",
- f->f_un.f_fname, f->f_sizeLimit, actualFileSize);
+ f->f_un.f_fname, (long long) f->f_sizeLimit, (long long) actualFileSize);
errno = 0;
logerror(errMsg);
}