pike.git
/
src
/
modules
/
_Roxen
/
roxen.c
version
»
Context lines:
10
20
40
80
file
none
3
pike.git/src/modules/_Roxen/roxen.c:86:
*! function. */ { struct buffer_str *str = THB; if( args && Pike_sp[-1].type == PIKE_T_INT ) str->initial = Pike_sp[-1].u.integer; else str->initial = INITIAL_BUF_LEN; }
+
static void f_buf_nullfun( INT32 args )
+
{
+
pop_n_elems( args );
+
push_int( 0 );
+
}
+
static void f_buf_add( INT32 args ) /*! @method void add(string data) *! Adds @[data] to the buffer */ { struct buffer_str *str = THB; struct pike_string *a; unsigned int l; if( args != 1 || Pike_sp[-args].type != PIKE_T_STRING )
pike.git/src/modules/_Roxen/roxen.c:464:
start_new_program(); ADD_STORAGE( struct header_buf ); pike_add_function( "feed", f_hp_feed, "function(string:array(string|mapping))",0 ); pike_add_function( "create", f_hp_create, "function(void:void)", 0 ); end_class( "HeaderParser", 0 ); start_new_program(); ADD_STORAGE( struct buffer_str ); pike_add_function( "add", f_buf_add, "function(string:int)",0 );
+
pike_add_function( "nullfun", f_buf_nullfun, "function(string:int)",0 );
pike_add_function( "get", f_buf_get, "function(void:string)", 0 ); pike_add_function( "create", f_buf_create, "function(int|void:void)", 0 ); set_init_callback( f_buf_init ); set_exit_callback( f_buf_free ); end_class( "Buffer", 0 ); } void pike_module_exit() { }