Since we use strlen() to determine the length
and then check it ourselves, there is really
no point in using strncpy.
But the compiler might complain that we use
the output of strlen() for the length of
strncpy which is usually a sign for bugs:
error: ‘strncpy’ specified bound depends
on the len
Am 28.03.23 um 20:58 schrieb Antonio Quartulli:
Hi,
On 28/03/2023 20:51, Matthias Andree wrote:
Am 28.03.23 um 17:12 schrieb Frank Lichtenheld:
Since we use strlen() to determine the length
and then check it ourselves, there is really
no point in using strncpy.
But the compiler might complain
Hi,
On 28/03/2023 20:51, Matthias Andree wrote:
Am 28.03.23 um 17:12 schrieb Frank Lichtenheld:
Since we use strlen() to determine the length
and then check it ourselves, there is really
no point in using strncpy.
But the compiler might complain that we use
the output of strlen() for the lengt
Am 28.03.23 um 17:12 schrieb Frank Lichtenheld:
Since we use strlen() to determine the length
and then check it ourselves, there is really
no point in using strncpy.
But the compiler might complain that we use
the output of strlen() for the length of
strncpy which is usually a sign for bugs:
er
Hi,
On 28/03/2023 17:12, Frank Lichtenheld wrote:
Since we use strlen() to determine the length
and then check it ourselves, there is really
no point in using strncpy.
But the compiler might complain that we use
the output of strlen() for the length of
strncpy which is usually a sign for bugs:
Since we use strlen() to determine the length
and then check it ourselves, there is really
no point in using strncpy.
But the compiler might complain that we use
the output of strlen() for the length of
strncpy which is usually a sign for bugs:
error: ‘strncpy’ specified bound depends
on the len