Source-Changes-HG archive

[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index][Old Index]

[src/trunk]: src/tests/lib/libc/gen Cleanup.



details:   https://anonhg.NetBSD.org/src/rev/a57c771281d9
branches:  trunk
changeset: 765677:a57c771281d9
user:      jruoho <jruoho%NetBSD.org@localhost>
date:      Thu Jun 02 12:42:27 2011 +0000

description:
Cleanup.

diffstat:

 tests/lib/libc/gen/t_sethostname.c |  6 ++++--
 1 files changed, 4 insertions(+), 2 deletions(-)

diffs (27 lines):

diff -r 81227f8cdbbf -r a57c771281d9 tests/lib/libc/gen/t_sethostname.c
--- a/tests/lib/libc/gen/t_sethostname.c        Thu Jun 02 12:15:33 2011 +0000
+++ b/tests/lib/libc/gen/t_sethostname.c        Thu Jun 02 12:42:27 2011 +0000
@@ -1,4 +1,4 @@
-/* $NetBSD: t_sethostname.c,v 1.1 2011/06/02 12:15:33 jruoho Exp $ */
+/* $NetBSD: t_sethostname.c,v 1.2 2011/06/02 12:42:27 jruoho Exp $ */
 
 /*-
  * Copyright (c) 2011 The NetBSD Foundation, Inc.
@@ -29,7 +29,7 @@
  * POSSIBILITY OF SUCH DAMAGE.
  */
 #include <sys/cdefs.h>
-__RCSID("$NetBSD: t_sethostname.c,v 1.1 2011/06/02 12:15:33 jruoho Exp $");
+__RCSID("$NetBSD: t_sethostname.c,v 1.2 2011/06/02 12:42:27 jruoho Exp $");
 
 #include <sys/param.h>
 
@@ -67,6 +67,8 @@
                ATF_REQUIRE(gethostname(name, sizeof(name)) == 0);
                ATF_REQUIRE(strcmp(hosts[i], name) == 0);
        }
+
+       (void)sethostname(host, sizeof(host));
 }
 
 ATF_TC_CLEANUP(sethostname_basic, tc)



Home | Main Index | Thread Index | Old Index