From owner-p4-projects@FreeBSD.ORG Thu Jul 30 05:56:30 2009 Return-Path: Delivered-To: p4-projects@freebsd.org Received: by hub.freebsd.org (Postfix, from userid 32767) id D0BFA1065679; Thu, 30 Jul 2009 05:56:29 +0000 (UTC) Delivered-To: perforce@freebsd.org Received: from mx1.freebsd.org (mx1.freebsd.org [IPv6:2001:4f8:fff6::34]) by hub.freebsd.org (Postfix) with ESMTP id 8ED9B106564A for ; Thu, 30 Jul 2009 05:56:29 +0000 (UTC) (envelope-from trasz@freebsd.org) Received: from repoman.freebsd.org (repoman.freebsd.org [IPv6:2001:4f8:fff6::29]) by mx1.freebsd.org (Postfix) with ESMTP id 7CDAD8FC0C for ; Thu, 30 Jul 2009 05:56:29 +0000 (UTC) (envelope-from trasz@freebsd.org) Received: from repoman.freebsd.org (localhost [127.0.0.1]) by repoman.freebsd.org (8.14.3/8.14.3) with ESMTP id n6U5uTWP000299 for ; Thu, 30 Jul 2009 05:56:29 GMT (envelope-from trasz@freebsd.org) Received: (from perforce@localhost) by repoman.freebsd.org (8.14.3/8.14.3/Submit) id n6U5uTko000297 for perforce@freebsd.org; Thu, 30 Jul 2009 05:56:29 GMT (envelope-from trasz@freebsd.org) Date: Thu, 30 Jul 2009 05:56:29 GMT Message-Id: <200907300556.n6U5uTko000297@repoman.freebsd.org> X-Authentication-Warning: repoman.freebsd.org: perforce set sender to trasz@freebsd.org using -f From: Edward Tomasz Napierala To: Perforce Change Reviews Cc: Subject: PERFORCE change 166761 for review X-BeenThere: p4-projects@freebsd.org X-Mailman-Version: 2.1.5 Precedence: list List-Id: p4 projects tree changes List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , X-List-Received-Date: Thu, 30 Jul 2009 05:56:30 -0000 http://perforce.freebsd.org/chv.cgi?CH=166761 Change 166761 by trasz@trasz_victim on 2009/07/30 05:55:57 Fix rule addition and removal. Previously, we always rewrote the rule with "::". Affected files ... .. //depot/projects/soc2009/trasz_limits/TODO#5 edit .. //depot/projects/soc2009/trasz_limits/usr.sbin/hrl/hrl.c#19 edit Differences ... ==== //depot/projects/soc2009/trasz_limits/TODO#5 (text+ko) ==== @@ -10,7 +10,7 @@ - Add sorting to hrl(8). - - Add resolving numeric IDs into names to hrl(8). + - Use expand_number(3) in hrl(8). Limits to do: ==== //depot/projects/soc2009/trasz_limits/usr.sbin/hrl/hrl.c#19 (text+ko) ==== @@ -317,10 +317,12 @@ if (argc > 1) usage(); - if (argc == 1) - rule = strdup(argv[0]); - else - rule = strdup("::"); + if (rule == NULL) { + if ( argc == 1) + rule = strdup(argv[0]); + else + rule = strdup("::"); + } if (aflag + lflag + rflag + uflag + argc > 1) errx(1, "only one flag or argument may be specified "