| iMatix home page
| << | < | > | >>
SFL Logo SFL
Version 1.91

 

insertstring

#include "sflstr.h"
char *
insertstring (
    char *strbuf,
    char *chrstoins,
    int pos)

Synopsis

Inserts a string into another string. Returns a pointer to head of the buffer. Submitted by Scott Beasley jscottb@infoave.com

Source Code - (sflstr.c)

{
   memmove ((strbuf + pos)+ strlen (chrstoins),
   (strbuf + pos), strlen ((strbuf + pos))+ 1);
   memcpy ((strbuf + pos), chrstoins, strlen (chrstoins));

   return strbuf;
}

| << | < | > | >> iMatix Copyright © 1996-98 iMatix