Menu

#1 compilation error on linux

open
nobody
None
5
2006-01-27
2006-01-27
Anonymous
No

Dear all,
I've found an error in the program code of
ciscoconfd.c, in my linuxbox I've solve this issue
with this patch:

--- ciscoconfd.c Fri Feb 16 19:19:21 2001
+++ ../../ciscoconf-1.1/ciscoconfd.c Fri Jan 27
11:06:48 2006
@@ -144,12 +144,12 @@

if (stat(p->name, &sb) == -1)
{
- p->offset = (fpos_t) 0;
+ p->offset = (fpos_t) {0, 0 };
moanf(cfg, LOG_WARNING, "Unable to stat file
'%s': %m (unnecessary config check-ins may result)",
p->name);
} else {
if (sb.st_ino != p->ino)
{
- p->offset = (fpos_t) 0;
+ p->offset = (fpos_t) {0,0};
p->ino = sb.st_ino;
moanf(cfg, LOG_INFO, "Log file '%s' has
rotated", p->name);
}
@@ -272,7 +272,7 @@
cfg.interval = (unsigned int) DEFAULT_INTERVAL;
cfg.head.name = NULL;
cfg.head.ino = (ino_t) 0;
- cfg.head.offset = (fpos_t) 0;
+ cfg.head.offset = (fpos_t) {0,0};
cfg.retriever = NULL;
cfg.head.next = NULL;

@@ -387,7 +387,7 @@
}

p->ino = (ino_t) 0;
- p->offset = (long) 0;
+ p->offset = (fpos_t) {0,0};
p->next = NULL;
if ((p->name = (char *) calloc(sizeof(char), 1 +
strlen(argv[optind]))) == NULL)

by
roberto

Discussion


Log in to post a comment.