[Sysfence-commit] sysfence cp2memory.c,1.2,1.3
Status: Alpha
Brought to you by:
emes
|
From: Michal S. <em...@us...> - 2004-05-26 04:06:34
|
Update of /cvsroot/sysfence/sysfence In directory sc8-pr-cvs1.sourceforge.net:/tmp/cvs-serv30928 Modified Files: cp2memory.c Log Message: * nasty bug fixed Index: cp2memory.c =================================================================== RCS file: /cvsroot/sysfence/sysfence/cp2memory.c,v retrieving revision 1.2 retrieving revision 1.3 diff -u -d -r1.2 -r1.3 --- cp2memory.c 23 May 2004 20:52:22 -0000 1.2 +++ cp2memory.c 26 May 2004 04:06:26 -0000 1.3 @@ -137,10 +137,12 @@ /* copy list node */ l = (sf_list *) *buf; memcpy (*buf, (void *) list, sizeof (sf_list)); + *buf += sizeof (sf_list); /* copy element linked to node */ l->el = *buf; memcpy (*buf, list->el, list->elsize); + *buf += list->elsize; /* copy list tail */ l->next = (sf_list *) cp_list (buf, list->next); @@ -276,6 +278,10 @@ /* copy logdata */ if (r->log) r->log = (sf_logdata *) cp_logdata (buf, rule->log); + + /* copy watched stats list */ + if (r->watchstats) + r->watchstats = (sf_list *) cp_list (buf, rule->watchstats); return (void *)r; } |