lkml.org 
[lkml]   [2000]   [Nov]   [23]   [last100]   RSS Feed
Views: [wrap][no wrap]   [headers]  [forward] 
 
Messages in this thread
/
SubjectRe: Too long network device names corrupts kernel
Date
From

>>>>> "Tobias" == Tobias Ringstrom <tori@tellus.mine.nu> writes:
Tobias> Btw, does anyone know of a C function that works like strncpy, but does
Tobias> add a terminating null character, event if the string does not fit, ro
Tobias> does one have to do str[5]=0 first, and then strncpy(str,src,4)?

str[0]=0;
strncat(str, src, 4);

Works as you want.

] Train travel features AC outlets with no take-off restrictions|gigabit is no[
] Michael Richardson, Solidum Systems Oh where, oh where has|problem with[
] mcr@solidum.com www.solidum.com the little fishy gone?|PAX.port 1100[
] panic("Just another NetBSD/notebook using, kernel hacking, security guy"); [



-
To unsubscribe from this list: send the line "unsubscribe linux-kernel" in
the body of a message to majordomo@vger.kernel.org
Please read the FAQ at http://www.tux.org/lkml/

\
 
 \ /
  Last update: 2005-03-22 12:47    [W:0.039 / U:0.788 seconds]
©2003-2018 Jasper Spaans|hosted at Digital Ocean and TransIP|Read the blog|Advertise on this site