pike.git / src / modules / Pipe / pipe.c

version» Context lines:

pike.git/src/modules/Pipe/pipe.c:19: Inside #if defined(HAVE_MMAP)
  #else   #ifdef HAVE_MMAP   /* sys/mman.h is _probably_ there anyway. */   #include <sys/mman.h>   #endif   #endif   #endif      #include <fcntl.h>    - RCSID("$Id: pipe.c,v 1.31 1999/03/05 01:49:27 grubba Exp $"); + RCSID("$Id: pipe.c,v 1.32 1999/03/05 16:17:19 grubba Exp $");      #include "threads.h"   #include "stralloc.h"   #include "pike_macros.h"   #include "object.h"   #include "constants.h"   #include "interpret.h"   #include "svalue.h"   #include "error.h"   #include "builtin_functions.h"
pike.git/src/modules/Pipe/pipe.c:321:   /* Wake up the sleepers */   static void low_start(void)   {    struct object *obj, *next;    struct output *o;          add_ref(THISOBJ); /* dont kill yourself now */    for(obj=THIS->firstoutput;obj;obj=next)    { -  /* add_ref(obj); /* Hang on PLEASE!! /hubbe */ +  /* add_ref(obj); */ /* Hang on PLEASE!! /hubbe */    o=(struct output *)(obj->storage);    next=o->next;    if (o->obj && o->mode==O_SLEEP)    {    if (!o->obj->prog)    {    output_finish(obj);    }    else    {    push_int(0);    push_callback(offset_output_write_callback);    push_callback(offset_output_close_callback);    apply_low(o->obj,o->set_nonblocking_offset,3);    /* output_try_write_some(obj); */ -  /* o->mode=O_RUN; /* Hubbe */ +  /* o->mode=O_RUN; */ /* Hubbe */    }    }    /* next=o->next; */    /* free_object(obj); */    }       free_object(THISOBJ);   }      /* Read some data from the blocking object.
pike.git/src/modules/Pipe/pipe.c:598:    destruct(o->obj);    }    free_object(o->obj);    noutputs--;    o->obj=NULL;       THIS->living_outputs--;       finished_p(); /* Moved by per, one line down.. :) */    -  /* free_object(THISOBJ); /* What? /Hubbe */ +  /* free_object(THISOBJ); */ /* What? /Hubbe */    }   }      /*    * Try to write some data to our precious output    */   static INLINE void output_try_write_some(struct object *obj)   {    struct output *out;    struct pike_string *s;
pike.git/src/modules/Pipe/pipe.c:890:    THIS->pos=0; */    push_int(0);    apply(sp[-args-2].u.object,"set_id", 1);    pop_n_elems(args+2); /* ... and from apply x 2 */    return;    }    pop_stack(); /* from apply */    }       THIS->living_outputs++; -  /* add_ref(THISOBJ); /* Weird */ +  /* add_ref(THISOBJ); */ /* Weird */       /* Allocate a new struct output */    obj=clone_object(output_program,0);    o=(struct output *)(obj->storage);    o->next=THIS->firstoutput;    THIS->firstoutput=obj;    noutputs++;    o->obj=NULL;       add_ref(o->obj=sp[-args].u.object);
pike.git/src/modules/Pipe/pipe.c:1264:   void pike_module_init(void)   {    start_new_program();    ADD_STORAGE(struct pipe);      /* function(:array) */    ADD_EFUN("_pipe_debug", f__pipe_debug,tFunc(,tArray), 0);    /* function(object:void) */    ADD_FUNCTION("input",pipe_input,tFunc(tObj,tVoid),0);    /* function(object,void|int:void) */ -  ADD_FUNCTION("output",pipe_output,tFunc(tObj tOr(tVoid|tInt),tVoid),0); +  ADD_FUNCTION("output",pipe_output,tFunc(tObj tOr(tVoid,tInt),tVoid),0);    /* function(string:void) */    ADD_FUNCTION("write",pipe_write,tFunc(tStr,tVoid),0);       /* function(:void) */    ADD_FUNCTION("start",pipe_start,tFunc(,tVoid),0);    /* function(:void) */    ADD_FUNCTION("finish",pipe_finish,tFunc(,tVoid),0);       /* function(void|function(mixed,object:mixed),void|mixed:void) */    ADD_FUNCTION("set_output_closed_callback",pipe_set_output_closed_callback,tFunc(tOr(tVoid,tFunc(tMix tObj,tMix)) tOr(tVoid,tMix),tVoid),0);