pike.git / src / post_modules / Shuffler / e_source_block_pikestream.c

version» Context lines:

pike.git/src/post_modules/Shuffler/e_source_block_pikestream.c:1:   /*   || 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.6 2007/11/10 21:23:14 nilsson Exp $ + || $Id: e_source_block_pikestream.c,v 1.7 2009/08/13 16:21:14 grubba Exp $   */      #include "global.h"   #include "bignum.h"   #include "object.h"   #include "interpret.h"      #include "fdlib.h"   #include "fd_control.h"   
pike.git/src/post_modules/Shuffler/e_source_block_pikestream.c:25:      struct pf_source   {    struct source s;       struct object *obj;    INT64 len, skip;   };       - static struct data get_data( struct source *_s, off_t len ) + static struct data get_data( struct source *src, off_t len )   { -  struct pf_source *s = (struct pf_source *)_s; +  struct pf_source *s = (struct pf_source *)src;    struct data res = { 0, 0, 0, NULL };       if( s->len>0 && len > s->len ) {    len = s->len;    s->s.eof = 1;    }       do {    struct pike_string *st;   
pike.git/src/post_modules/Shuffler/e_source_block_pikestream.c:65:    pop_stack();    }    while(s->skip || !res.len);    if(res.len < len)    s->s.eof = 1;    if(s->len > 0)    s->len -= res.len;    return res;   }    - static void free_source( struct source *_s ) + static void free_source( struct source *src )   { -  free_object(((struct pf_source *)_s)->obj); +  free_object(((struct pf_source *)src)->obj);   }      struct source *source_block_pikestream_make( struct svalue *s,    INT64 start, INT64 len )   {    struct pf_source *res;       if( (s->type != PIKE_T_OBJECT) ||    (find_identifier("read",s->u.object->prog)==-1) )    return 0;