diff --git a/src/post_modules/Shuffler/d_source_pikestream.c b/src/post_modules/Shuffler/d_source_pikestream.c index 2946c6e639f6b3f3af077a85b09db53e00855b7c..8db07942db9f5946ef469b8abee12920fc01400e 100644 --- a/src/post_modules/Shuffler/d_source_pikestream.c +++ b/src/post_modules/Shuffler/d_source_pikestream.c @@ -2,7 +2,7 @@ || This file is part of Pike. For copyright information see COPYRIGHT. || Pike is distributed under GPL, LGPL and MPL. See the file COPYING || for more information. -|| $Id: d_source_pikestream.c,v 1.7 2004/10/16 07:27:29 agehall Exp $ +|| $Id: d_source_pikestream.c,v 1.8 2007/11/10 21:23:02 nilsson Exp $ */ #include "global.h" @@ -72,7 +72,7 @@ static void remove_callbacks( struct source *_s ) static struct data get_data( struct source *_s, off_t len ) { struct pf_source *s = (struct pf_source *)_s; - struct data res; + struct data res = { 0, 0, 0, NULL }; char *buffer = NULL; if( s->str ) @@ -83,10 +83,7 @@ static struct data get_data( struct source *_s, off_t len ) if( s->skip >= (size_t)s->str->len ) { s->skip -= (size_t)s->str->len; - res.do_free = 0; - res.data = 0; res.len = -2; - res.off = 0; return res; } len -= s->skip; @@ -109,7 +106,6 @@ static struct data get_data( struct source *_s, off_t len ) res.data = buffer; res.len = len; res.do_free = 1; - res.off = 0; free_string( s->str ); s->str = 0; setup_callbacks( _s ); diff --git a/src/post_modules/Shuffler/e_source_block_pikestream.c b/src/post_modules/Shuffler/e_source_block_pikestream.c index 70a33eb40c2dc1488010d818efb8a63dc3f60414..261cee1af7b2dd13ab290774aab0795b5a86d7e0 100644 --- a/src/post_modules/Shuffler/e_source_block_pikestream.c +++ b/src/post_modules/Shuffler/e_source_block_pikestream.c @@ -2,7 +2,7 @@ || This file is part of Pike. For copyright information see COPYRIGHT. || Pike is distributed under GPL, LGPL and MPL. See the file COPYING || for more information. -|| $Id: e_source_block_pikestream.c,v 1.5 2004/10/16 07:27:29 agehall Exp $ +|| $Id: e_source_block_pikestream.c,v 1.6 2007/11/10 21:23:14 nilsson Exp $ */ #include "global.h" @@ -35,11 +35,7 @@ struct pf_source static struct data get_data( struct source *_s, off_t len ) { struct pf_source *s = (struct pf_source *)_s; - struct data res; - - res.len = 0; - res.off = 0; - res.do_free = 0; + struct data res = { 0, 0, 0, NULL }; if( s->len>0 && len > s->len ) { len = s->len;