!C99Shell v. 1.0 pre-release build #13!

Software: Apache/2.0.54 (Unix) mod_perl/1.99_09 Perl/v5.8.0 mod_ssl/2.0.54 OpenSSL/0.9.7l DAV/2 FrontPage/5.0.2.2635 PHP/4.4.0 mod_gzip/2.0.26.1a 

uname -a: Linux snow.he.net 4.4.276-v2-mono-1 #1 SMP Wed Jul 21 11:21:17 PDT 2021 i686 

uid=99(nobody) gid=98(nobody) groups=98(nobody) 

Safe-mode: OFF (not secure)

/usr/doc/slang-1.4.5/html/   drwxr-xr-x
Free 318.37 GB of 458.09 GB (69.5%)
Home    Back    Forward    UPDIR    Refresh    Search    Buffer    Encoder    Tools    Proc.    FTP brute    Sec.    SQL    PHP-code    Update    Feedback    Self remove    Logout    


Viewing file:     cref-42.html (2.46 KB)      -rw-r--r--
Select action/file-type:
(+) | (+) | (+) | Code (+) | Session (+) | (+) | SDB (+) | (+) | (+) | (+) | (+) | (+) |
{The S-lang C Library Reference}: SLclass_set_string_function Next Previous Contents

42. SLclass_set_string_function

Synopsis

Set a data type's string representation callback

Usage

int SLclass_set_string_function (cl, sfun)

   SLang_Class_Type *cl
   char *(*sfun) (unsigned char, VOID_STAR);
Description

The SLclass_set_string_function routine is used to define a callback function, sfun, that that will be used when a string representation of an object of the data type represented by cl is needed. cl must have already been obtained via a call to SLclass_allocate_class. When called, sfun will be passed two arguments: a unsigned char which represents the data type, and the address of the object for which a string represetation is required. The callback function must return a malloced string.

Upon success, SLclass_set_string_function returns zero, or upon error it returns -1.

Example

A callback function that handles both SLANG_STRING_TYPE and SLANG_INT_TYPE variables looks like:

     char *string_and_int_callback (unsigned char type, VOID_STAR addr)
     {
        char buf[64];

        switch (type)
          {
             case SLANG_STRING_TYPE:
               return SLmake_string (*(char **)addr);
             
             case SLANG_INTEGER_TYPE:
               sprintf (buf, "%d", *(int *)addr);
               return SLmake_string (buf);
          }
        return NULL;
     }
Notes

The default string callback simply returns the name of the data type.

See Also

SLclass_allocate_class, SLclass_register_class


Next Previous Contents

:: Command execute ::

Enter:
 
Select:
 

:: Search ::
  - regexp 

:: Upload ::
 
[ Read-Only ]

:: Make Dir ::
 
[ Read-Only ]
:: Make File ::
 
[ Read-Only ]

:: Go Dir ::
 
:: Go File ::
 

--[ c99shell v. 1.0 pre-release build #13 powered by Captain Crunch Security Team | http://ccteam.ru | Generation time: 0.0044 ]--