Retro video games delivered to your door every month!
Click above to get retro games delivered to your door ever month!
X-Hacker.org- Watcom C Library Reference - <u>synopsis:</u> http://www.X-Hacker.org [<<Previous Entry] [^^Up^^] [Next Entry>>] [Menu] [About The Guide]
Synopsis:
    #include <string.h>
    char *strset( char *s1, int fill );
    char *_strset( char *s1, int fill );
    char __far *_fstrset( char __far *s1, int fill );
    #include <wchar.h>
    wchar_t *_wcsset( wchar_t *s1, int fill );
    #include <mbstring.h>
    unsigned char *_mbsset( unsigned char *s1,
                            unsigned int fill );
    unsigned char __far *_fmbsset( unsigned char __far *s1,
                                   unsigned int fill );

Description:
    The strset function fills the string pointed to by s1 with the character
    fill.  The terminating null character in the original string remains
    unchanged.

    The _strset function is identical to strset.  Use _strset for ANSI
    naming conventions.

    The _fstrset function is a data model independent form of the strset
    function.  It accepts far pointer arguments and returns a far pointer.
     It is most useful in mixed memory model applications.

    The _wcsset function is a wide-character version of strset that operates
    with wide-character strings.

    The _mbsset function is a multibyte character version of strset that
    operates with multibyte character strings.

    The _fmbsset function is a data model independent form of the _mbsset
    function that accepts far pointer arguments.  It is most useful in mixed
    memory model applications.

Returns:
    The address of the original string s1 is returned.

Example:
    #include <stdio.h>
    #include <string.h>

    char source[] = { "A sample STRING" };

    void main()
      {
        printf( "%s\n", source );
        printf( "%s\n", strset( source, '=' ) );
        printf( "%s\n", strset( source, '*' ) );
      }

    produces the following:

    A sample STRING
    ===============
    ***************

Classification:
    WATCOM

Systems:
     strset - All, Netware

    _strset - All, Netware
    _fstrset - All
    _wcsset - All
    _mbsset - DOS, Windows, Win386, Win32, OS/2 1.x(all), OS/2-32
    _fmbsset - DOS, Windows, Win386, Win32, OS/2 1.x(all), OS/2-32

See Also:
    strnset

See Also:

Online resources provided by: http://www.X-Hacker.org --- NG 2 HTML conversion by Dave Pearson