Re: strcat strncat and strlen
- From: santosh <santosh.k83@xxxxxxxxx>
- Date: Mon, 31 Mar 2008 06:17:40 +0530
Bill Cunningham wrote:
Strncat is supposed to be better than strcat for some reason
I've read.
It does something different to what it's name would suggest. We have had
innumerable threads dealing with this topic. Just do a Google search.
Is this because of a potential buffer overflow?
Well, it can be used with that aim, in which case it leaves an array of
char instead of a string in the destination.
I have compiled properly and used strlen too and I just wonder what is
the need to return a strlen?
Has anyone used quite abit anyway the strlen function?
You are not making any sense. Are you asking why strlen exists? It
should be obvious, even to you. How else do you find the length of a
zero terminated string?
.
- Follow-Ups:
- Re: strcat strncat and strlen
- From: vippstar
- Re: strcat strncat and strlen
- From: Richard
- Re: strcat strncat and strlen
- From: Bill Cunningham
- Re: strcat strncat and strlen
- References:
- strcat strncat and strlen
- From: Bill Cunningham
- strcat strncat and strlen
- Prev by Date: strcat strncat and strlen
- Next by Date: Re: Doubts about pointers
- Previous by thread: strcat strncat and strlen
- Next by thread: Re: strcat strncat and strlen
- Index(es):