projects
/
cronie
/ commitdiff
commit
grep
author
committer
pickaxe
?
search:
re
summary
|
shortlog
|
log
|
commit
| commitdiff |
tree
raw
|
patch
| inline |
side by side
(parent:
4c2a6e1
)
Fix "warning: unused variable" if LOG_FILE is not defined
author
SATOH Fumiyasu
<fumiyas@osstech.co.jp>
Tue, 3 Nov 2009 09:56:24 +0000
(10:56 +0100)
committer
Marcela Mašláňová
<mmaslano@redhat.com>
Tue, 3 Nov 2009 09:56:24 +0000
(10:56 +0100)
Signed-off-by: Marcela Mašláňová <mmaslano@redhat.com>
src/misc.c
patch
|
blob
|
history
diff --git
a/src/misc.c
b/src/misc.c
index c9f30545c84cddb9447a4ae22ce333a18aec40bb..8ccda51d2ff50e1b2e5976e902e7bdbb473f0ed3 100644
(file)
--- a/
src/misc.c
+++ b/
src/misc.c
@@
-489,10
+489,12
@@
void log_it(const char *username, PID_T xpid, const char *event,
#if defined(LOG_FILE) || DEBUGGING
PID_T pid = xpid;
#endif
+#if defined(LOG_FILE)
char *msg;
TIME_T now = time((TIME_T) 0);
struct tm *t = localtime(&now);
int msg_size;
+#endif
#if defined(LOG_FILE)
/* we assume that MAX_TEMPSTR will hold the date, time, &punctuation.