pike.git / src / modules / _Stdio / file.c

version» Context lines:

pike.git/src/modules/_Stdio/file.c:143:   #ifdef UNIX_SOCKETS_WORK_WITH_SHUTDOWN   #undef UNIX_SOCKET_CAPABILITIES   #define UNIX_SOCKET_CAPABILITIES (fd_INTERPROCESSABLE | fd_BIDIRECTIONAL | fd_CAN_NONBLOCK | fd_CAN_SHUTDOWN | fd_SEND_FD)   #endif      /* #define SOCKETPAIR_DEBUG */      struct program *file_program;   struct program *file_ref_program;    - /*! @module _Stdio + /*! @module Stdio    */      /*! @class Fd_ref    *!    *! Proxy class that contains stub functions    *! that call the corresponding functions in    *! @[Fd].    *!    *! Used by @[Stdio.File].    *!
pike.git/src/modules/_Stdio/file.c:226:    ref_push_object_inherit(Pike_fp->current_object,    Pike_fp->context -    Pike_fp->current_program->inherits);   }      /*! @endclass    */      /* The class below is not accurate, but it's the lowest exposed API    * interface, which make the functions appear where users actually -  * look for them. One could perhaps put them in Fd_ref and fix the doc -  * generator to show inherited functions in a better way, but if they -  * only are documented in Fd then the doc has to be duplicated in at -  * least Fd_ref. /mast */ +  * look for them. /mast */    - /*! @class Fd + /*! @class File    */      static struct my_file *get_file_storage(struct object *o)   {    struct my_file *f;    struct svalue *sval;    struct object *ob;    if(o->prog == file_program)    return ((struct my_file *)    (o->storage + file_program->inherits->storage_offset));
pike.git/src/modules/_Stdio/file.c:5823: Inside #if defined(HAVE_TERMIOS_H)
  void file_tcgetattr(INT32 args);   void file_tcsetattr(INT32 args);   void file_tcsendbreak(INT32 args);   void file_tcflush(INT32 args);   /* void file_tcdrain(INT32 args); */   /* void file_tcflow(INT32 args); */   /* void file_tcgetpgrp(INT32 args); */   /* void file_tcsetpgrp(INT32 args); */   #endif    - /*! @decl string _sprintf(int type, void|mapping flags) -  */ +    static void fd__sprintf(INT32 args)   {    INT_TYPE type;       if(args < 1)    SIMPLE_TOO_FEW_ARGS_ERROR("_sprintf",2);    if(TYPEOF(Pike_sp[-args]) != PIKE_T_INT)    SIMPLE_BAD_ARG_ERROR("_sprintf",0,"int");       type = Pike_sp[-args].u.integer;
pike.git/src/modules/_Stdio/file.c:5980:    tFunc(tNone, tObjIs_STDIO_FD), ID_PROTECTED);       fd_receive_fd_fun_num =    ADD_FUNCTION("receive_fd", NULL,    tFunc(tObjIs_STDIO_FD, tVoid), ID_PROTECTED);       ADD_FUNCTION("`_fd", fd_backtick__fd, tFunc(tNone, tObjIs_STDIO_FD), 0);       /* function(int, void|mapping:string) */    ADD_FUNCTION("_sprintf",fd__sprintf, -  tFunc(tInt tOr(tVoid,tMapping),tString),0); +  tFunc(tInt tOr(tVoid,tMapping),tString),ID_PROTECTED);       init_file_locking();    pike_set_prog_event_callback(file_handle_events);       file_program=end_program();    add_program_constant("Fd",file_program,0);       o=file_make_object_from_fd(0, low_fd_query_properties(0)|FILE_READ,    fd_CAN_NONBLOCK);    ((struct my_file *)(o->storage + file_program->inherits->storage_offset))->flags |= FILE_NO_CLOSE_ON_DESTRUCT;