Module Name: src Committed By: snj Date: Fri Aug 14 20:44:06 UTC 2009
Modified Files: src/sbin/ifconfig [netbsd-5-0]: parse.c Log Message: Pull up following revision(s) (requested by dyoung in ticket #878): sbin/ifconfig/parse.c: revision 1.14 Both carp.c and vlan.c expect for a keyword with a KW_T_STR-type value to put a prop_string_t into the environment, but the keyword parser put a prop_data_t into the environment, instead. That broke the -vlanif and -carpdev keywords and defied developer expectations. Let's put a prop_string_t into the environment. Thanks to Arnaud Degroote for reporting the problem. To generate a diff of this commit: cvs rdiff -u -r1.12 -r1.12.4.1 src/sbin/ifconfig/parse.c Please note that diffs are not public domain; they are subject to the copyright notices on the relevant files.
Modified files: Index: src/sbin/ifconfig/parse.c diff -u src/sbin/ifconfig/parse.c:1.12 src/sbin/ifconfig/parse.c:1.12.4.1 --- src/sbin/ifconfig/parse.c:1.12 Fri Aug 1 22:29:14 2008 +++ src/sbin/ifconfig/parse.c Fri Aug 14 20:44:06 2009 @@ -1,4 +1,4 @@ -/* $NetBSD: parse.c,v 1.12 2008/08/01 22:29:14 dyoung Exp $ */ +/* $NetBSD: parse.c,v 1.12.4.1 2009/08/14 20:44:06 snj Exp $ */ /*- * Copyright (c) 2008 David Young. All rights reserved. @@ -27,7 +27,7 @@ #include <sys/cdefs.h> #ifndef lint -__RCSID("$NetBSD: parse.c,v 1.12 2008/08/01 22:29:14 dyoung Exp $"); +__RCSID("$NetBSD: parse.c,v 1.12.4.1 2009/08/14 20:44:06 snj Exp $"); #endif /* not lint */ #include <err.h> @@ -685,8 +685,7 @@ o = u->u_obj; break; case KW_T_STR: - o = (prop_object_t)prop_data_create_data_nocopy(u->u_str, - strlen(u->u_str)); + o = (prop_object_t)prop_string_create_cstring_nocopy(u->u_str); if (o == NULL) goto err; break;