pike.git / src / modules / Yp / yp.c

version» Context lines:

pike.git/src/modules/Yp/yp.c:58:   }      static void f_create(INT32 args)   {    int err;    if(!args)    {    f_default_yp_domain(0);    args = 1;    } -  check_all_args("yp->create", args, 1, BIT_STRING); +  check_all_args("yp->create", args, BIT_STRING,0);       if(this->domain)    {    yp_unbind( this->domain );    free(this->domain);    }    this->domain = strdup( sp[-args].u.string->str );    err = yp_bind( this->domain );    YPERROR("create", err);   }      static void f_all(INT32 args)   {    int err, num=0;    char *retval, *retkey;    int retlen, retkeylen;    char *map;    struct mapping *res_map; -  check_all_args("yp->all", args, 1, BIT_STRING); +  check_all_args("yp->all", args, BIT_STRING, 0);       map = sp[-1].u.string->str;    res_map = allocate_mapping( (this->last_size?this->last_size+2:40) );       if(!(err = yp_first(this->domain, map, &retkey,&retkeylen, &retval,&retlen)))    do {    push_string(make_shared_binary_string(retkey, retkeylen));    push_string(make_shared_binary_string(retval, retlen));    mapping_insert( res_map, sp-2, sp-1 );    pop_stack(); pop_stack();
pike.git/src/modules/Yp/yp.c:113:      void f_map(INT32 args)   {    int err;    char *retval, *retkey;    int retlen, retkeylen;    char *map;       struct svalue *f = &sp[-1];    -  check_all_args("map", args, 2, BIT_STRING, BIT_FUNCTION|BIT_ARRAY ); +  check_all_args("map", args, BIT_STRING, BIT_FUNCTION|BIT_ARRAY, 0 );       map = sp[-2].u.string->str;       if(!(err = yp_first(this->domain,map, &retkey,&retkeylen, &retval, &retlen)))    do {    push_string(make_shared_binary_string(retkey, retkeylen));    push_string(make_shared_binary_string(retval, retlen));    apply_svalue( f, 2 );       err = yp_next(this->domain, map, retkey, retkeylen,
pike.git/src/modules/Yp/yp.c:136:       pop_n_elems(args);    if(err != YPERR_NOMORE)    YPERROR( "all", err );   }      static void f_order(INT32 args)   {    int err;    unsigned long ret; -  check_all_args("yp->order()", args, 1, BIT_STRING); +  check_all_args("yp->order", args, BIT_STRING, 0);       err = yp_order( this->domain, sp[-args].u.string->str, &ret);    YPERROR("order", err );    pop_n_elems( args );    push_int( (INT32) ret );   }      static void f_match(INT32 args)   {    int err;    char *retval;    int retlen;    -  check_all_args("yp->match", args, 2, BIT_STRING, BIT_STRING); +  check_all_args("yp->match", args, BIT_STRING, BIT_STRING, 0);       err = yp_match( this->domain, sp[-args].u.string->str,    sp[-args+1].u.string->str, sp[-args+1].u.string->len,    &retval, &retlen );       pop_n_elems( args );    if(err == YPERR_KEY)    {    push_int(0);    sp[-1].subtype = NUMBER_UNDEFINED;