bug-coreutils
[Top][All Lists]
Advanced

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

Re: Double include of getopt.h in env.c and groups.c (coreutils-6.12)


From: Jim Meyering
Subject: Re: Double include of getopt.h in env.c and groups.c (coreutils-6.12)
Date: Sun, 31 Aug 2008 16:37:17 +0200

Jerry Snitselaar <address@hidden> wrote:
> Is there a reason that getopt.h gets included twice?
>
> src/env.c:
>
> #include <getopt.h>
> #include <sys/types.h>
> #include <getopt.h>
>
> src/groups.c:
>
> #include <getopt.h>
> #include <sys/types.h>
> #include <pwd.h>
> #include <grp.h>
> #include <getopt.h>

No.
You've just fixed both ;-)
Thanks!

>From 63a7120c283ab4ad6ce204ea47dbe45f561a34c0 Mon Sep 17 00:00:00 2001
From: Jerry Snitselaar <address@hidden>
Date: Sun, 31 Aug 2008 15:58:27 +0200
Subject: [PATCH] env, groups: remove duplicate inclusion of <getopt.h>

* src/env.c: Remove redundant #include.
* src/groups.c: Likewise.
Tiny change.
---
 src/env.c    |    1 -
 src/groups.c |    1 -
 2 files changed, 0 insertions(+), 2 deletions(-)

diff --git a/src/env.c b/src/env.c
index 67e411f..97bec71 100644
--- a/src/env.c
+++ b/src/env.c
@@ -78,7 +78,6 @@

 #include <config.h>
 #include <stdio.h>
-#include <getopt.h>
 #include <sys/types.h>
 #include <getopt.h>

diff --git a/src/groups.c b/src/groups.c
index c71667b..907af1c 100644
--- a/src/groups.c
+++ b/src/groups.c
@@ -19,7 +19,6 @@

 #include <config.h>
 #include <stdio.h>
-#include <getopt.h>
 #include <sys/types.h>
 #include <pwd.h>
 #include <grp.h>
--
1.6.0.1.157.g7df43




reply via email to

[Prev in Thread] Current Thread [Next in Thread]