Mail Archives: djgpp/2001/12/18/15:09:59
It has to be a logic error of some kind because the code runs fine
aside from a few warning messages...
-----------------------------------------------------------------------
/* This is a memmory string cut function.
*string = pointer to the string were cutting from
*new_string = pointer to the memmory where the 'cut' string will go
start_offset = Where we will start cutting >= 0
end_offset = Where we will stop cutting >= start_offset
*/
void getstr(const char *string, const char *new_string, int
start_offset, int end_offset);
/**************************************************************************/
void getstr(const char *string, const char *new_string, int
start_offset, int end_offset)
{
int i=0;
int b=0;
for (i=start_offset; i<=end_offset; i++) {
*(new_string+b)=string+i;
b++;
}
*(new_string+b)='\0';
return;
}
=====
~ Twisted Matrix (Founder of ULTRATECH)
URL: N/A
ICQ: 74628745
__________________________________________________
Do You Yahoo!?
Check out Yahoo! Shopping and Yahoo! Auctions for all of
your unique holiday gifts! Buy at http://shopping.yahoo.com
or bid at http://auctions.yahoo.com
- Raw text -