Message ID | 20200102144714.93956-1-ldurfina@tachyum.com |
---|---|
State | New, archived |
Headers |
Received: (qmail 115265 invoked by alias); 2 Jan 2020 14:47:29 -0000 Mailing-List: contact gdb-patches-help@sourceware.org; run by ezmlm Precedence: bulk List-Id: <gdb-patches.sourceware.org> List-Unsubscribe: <mailto:gdb-patches-unsubscribe-##L=##H@sourceware.org> List-Subscribe: <mailto:gdb-patches-subscribe@sourceware.org> List-Archive: <http://sourceware.org/ml/gdb-patches/> List-Post: <mailto:gdb-patches@sourceware.org> List-Help: <mailto:gdb-patches-help@sourceware.org>, <http://sourceware.org/ml/#faqs> Sender: gdb-patches-owner@sourceware.org Delivered-To: mailing list gdb-patches@sourceware.org Received: (qmail 115251 invoked by uid 89); 2 Jan 2020 14:47:29 -0000 Authentication-Results: sourceware.org; auth=none X-Spam-SWARE-Status: No, score=-16.4 required=5.0 tests=AWL, BAYES_00, GIT_PATCH_0, GIT_PATCH_1, GIT_PATCH_2, GIT_PATCH_3, SPF_PASS autolearn=ham version=3.3.1 spammy=H*r:0800 X-HELO: mail.tachyum.com Received: from mail.tachyum.com (HELO mail.tachyum.com) (66.160.133.170) by sourceware.org (qpsmtpd/0.93/v0.84-503-g423c35a) with ESMTP; Thu, 02 Jan 2020 14:47:28 +0000 Received: from THQ-IP-EX1.tachyum.com (relayhost.tachyum.com [10.7.1.6]) (using TLSv1.2 with cipher ECDHE-RSA-AES256-SHA384 (256/256 bits)) (No client certificate requested) by mail.tachyum.com (Postfix) with ESMTPS id 7BF1E214 for <gdb-patches@sourceware.org>; Thu, 2 Jan 2020 06:47:29 -0800 (PST) Received: from tachyum-sk-server.tachyum.com (10.7.241.13) by THQ-IP-EX1.tachyum.com (10.7.1.6) with Microsoft SMTP Server (version=TLS1_2, cipher=TLS_ECDHE_RSA_WITH_AES_256_CBC_SHA384_P256) id 15.1.1779.2; Thu, 2 Jan 2020 06:47:25 -0800 From: Lukas Durfina <ldurfina@tachyum.com> To: <gdb-patches@sourceware.org> Subject: [PATCH] gdb/testsuite: Updated includes Date: Thu, 2 Jan 2020 15:47:14 +0100 Message-ID: <20200102144714.93956-1-ldurfina@tachyum.com> MIME-Version: 1.0 Content-Type: text/plain |
Commit Message
ldurfina@tachyum.com
Jan. 2, 2020, 2:47 p.m. UTC
Fixed compilation error with musl. --- gdb/testsuite/ChangeLog | 4 ++++ gdb/testsuite/gdb.base/fileio.c | 3 +-- 2 files changed, 5 insertions(+), 2 deletions(-)
Comments
Hi Lukas, > Fixed compilation error with musl. Thanks for the patch! > --- > gdb/testsuite/ChangeLog | 4 ++++ > gdb/testsuite/gdb.base/fileio.c | 3 +-- > 2 files changed, 5 insertions(+), 2 deletions(-) > > diff --git a/gdb/testsuite/ChangeLog b/gdb/testsuite/ChangeLog > index f7835f35f7..89d403897c 100644 > --- a/gdb/testsuite/ChangeLog > +++ b/gdb/testsuite/ChangeLog > @@ -1,3 +1,7 @@ > +2020-01-02 Lukas Durfina <ldurfina@tachyum.com> > + > + * gdb.base/fileio.c: Updated includes to be more generic. For the revision log, I think it's import to be a bit more specific when explaining what changes you made and why. I see you removed the <sys/errno.h> #include without replacing it by a #include of <errno.h>. However, this file does make references to errno, so I think there is an oversight there. Also, I see you not only replace <sys/fcntl.h> by <fcntl.h>, but you also move its include further down. Any reason for that. Was it to move that include outside of the range of #include-s that include files in "sys"? For the ChangeLog, I think it is worth being a little more specific. For instance, I would have written the ChangeLog as follow: * gdb.base/fileio.c: Remove #include of <sys/errno.h>. Replace #include of <sys/fcntl.h> by <fcntl.h>. I'm usually the first in line to take shortcuts with ChangeLog files, but I try to be more informative when the cost of being so is so small... > + > 2019-12-29 Bernd Edlinger <bernd.edlinger@hotmail.de> > > * gdb.base/line65535.exp: New file. > diff --git a/gdb/testsuite/gdb.base/fileio.c b/gdb/testsuite/gdb.base/fileio.c > index 7f482a34d3..0f201518b7 100644 > --- a/gdb/testsuite/gdb.base/fileio.c > +++ b/gdb/testsuite/gdb.base/fileio.c > @@ -1,13 +1,12 @@ > #include <stdio.h> > #include <stdlib.h> > #include <string.h> > -#include <sys/errno.h> > #include <sys/types.h> > -#include <sys/fcntl.h> > #include <sys/stat.h> > #include <sys/time.h> > #include <errno.h> > #include <sys/wait.h> > +#include <fcntl.h> > #include <unistd.h> > #include <time.h> > /* TESTS : > -- > 2.17.1
Hi Joel, Thanks for review. > -----Original Message----- > From: Joel Brobecker <brobecker@adacore.com> > Sent: Sunday, January 5, 2020 7:26 AM > To: Lukas Durfina <ldurfina@tachyum.com> > Cc: gdb-patches@sourceware.org > Subject: Re: [PATCH] gdb/testsuite: Updated includes > > Hi Lukas, > > > Fixed compilation error with musl. > > Thanks for the patch! > > > --- > > gdb/testsuite/ChangeLog | 4 ++++ > > gdb/testsuite/gdb.base/fileio.c | 3 +-- > > 2 files changed, 5 insertions(+), 2 deletions(-) > > > > diff --git a/gdb/testsuite/ChangeLog b/gdb/testsuite/ChangeLog index > > f7835f35f7..89d403897c 100644 > > --- a/gdb/testsuite/ChangeLog > > +++ b/gdb/testsuite/ChangeLog > > @@ -1,3 +1,7 @@ > > +2020-01-02 Lukas Durfina <ldurfina@tachyum.com> > > + > > + * gdb.base/fileio.c: Updated includes to be more generic. > > For the revision log, I think it's import to be a bit more specific when > explaining what changes you made and why. > > I see you removed the <sys/errno.h> #include without replacing it by a > #include of <errno.h>. However, this file does make references to errno, so I > think there is an oversight there. There is already #include <errno.h> a few lines below, so I skipped it. > > Also, I see you not only replace <sys/fcntl.h> by <fcntl.h>, but you also move > its include further down. Any reason for that. > Was it to move that include outside of the range of #include-s that include > files in "sys"? Exactly. My intention was to move it out of <sys/...> includes. No other reason. > > For the ChangeLog, I think it is worth being a little more specific. > For instance, I would have written the ChangeLog as follow: > > * gdb.base/fileio.c: Remove #include of <sys/errno.h>. > Replace #include of <sys/fcntl.h> by <fcntl.h>. > > I'm usually the first in line to take shortcuts with ChangeLog files, but I try to > be more informative when the cost of being so is so small... I see your point. Is it fine to send the patch with updated Changelog? Lukas > > > + > > 2019-12-29 Bernd Edlinger <bernd.edlinger@hotmail.de> > > > > * gdb.base/line65535.exp: New file. > > diff --git a/gdb/testsuite/gdb.base/fileio.c > > b/gdb/testsuite/gdb.base/fileio.c index 7f482a34d3..0f201518b7 100644 > > --- a/gdb/testsuite/gdb.base/fileio.c > > +++ b/gdb/testsuite/gdb.base/fileio.c > > @@ -1,13 +1,12 @@ > > #include <stdio.h> > > #include <stdlib.h> > > #include <string.h> > > -#include <sys/errno.h> > > #include <sys/types.h> > > -#include <sys/fcntl.h> > > #include <sys/stat.h> > > #include <sys/time.h> > > #include <errno.h> > > #include <sys/wait.h> > > +#include <fcntl.h> > > #include <unistd.h> > > #include <time.h> > > /* TESTS : > > -- > > 2.17.1 > > -- > Joel
> > I see you removed the <sys/errno.h> #include without replacing it by a > > #include of <errno.h>. However, this file does make references to errno, so I > > think there is an oversight there. > > There is already #include <errno.h> a few lines below, so I skipped it. Duh (head slap). <accent=french>but of course</accent>. Sorry. > > Also, I see you not only replace <sys/fcntl.h> by <fcntl.h>, but you also move > > its include further down. Any reason for that. > > Was it to move that include outside of the range of #include-s that include > > files in "sys"? > > Exactly. My intention was to move it out of <sys/...> includes. No > other reason. > > > > > For the ChangeLog, I think it is worth being a little more specific. > > For instance, I would have written the ChangeLog as follow: > > > > * gdb.base/fileio.c: Remove #include of <sys/errno.h>. > > Replace #include of <sys/fcntl.h> by <fcntl.h>. > > > > I'm usually the first in line to take shortcuts with ChangeLog > > files, but I try to be more informative when the cost of being so is > > so small... > > I see your point. Is it fine to send the patch with updated Changelog? That would be fine. On the other hand, if you want, you can push the patch with the ChangeLog above, since the change itself looks good to me, now. Thank you! > > Lukas > > > > > > + > > > 2019-12-29 Bernd Edlinger <bernd.edlinger@hotmail.de> > > > > > > * gdb.base/line65535.exp: New file. > > > diff --git a/gdb/testsuite/gdb.base/fileio.c > > > b/gdb/testsuite/gdb.base/fileio.c index 7f482a34d3..0f201518b7 100644 > > > --- a/gdb/testsuite/gdb.base/fileio.c > > > +++ b/gdb/testsuite/gdb.base/fileio.c > > > @@ -1,13 +1,12 @@ > > > #include <stdio.h> > > > #include <stdlib.h> > > > #include <string.h> > > > -#include <sys/errno.h> > > > #include <sys/types.h> > > > -#include <sys/fcntl.h> > > > #include <sys/stat.h> > > > #include <sys/time.h> > > > #include <errno.h> > > > #include <sys/wait.h> > > > +#include <fcntl.h> > > > #include <unistd.h> > > > #include <time.h> > > > /* TESTS : > > > -- > > > 2.17.1 > > > > -- > > Joel
diff --git a/gdb/testsuite/ChangeLog b/gdb/testsuite/ChangeLog index f7835f35f7..89d403897c 100644 --- a/gdb/testsuite/ChangeLog +++ b/gdb/testsuite/ChangeLog @@ -1,3 +1,7 @@ +2020-01-02 Lukas Durfina <ldurfina@tachyum.com> + + * gdb.base/fileio.c: Updated includes to be more generic. + 2019-12-29 Bernd Edlinger <bernd.edlinger@hotmail.de> * gdb.base/line65535.exp: New file. diff --git a/gdb/testsuite/gdb.base/fileio.c b/gdb/testsuite/gdb.base/fileio.c index 7f482a34d3..0f201518b7 100644 --- a/gdb/testsuite/gdb.base/fileio.c +++ b/gdb/testsuite/gdb.base/fileio.c @@ -1,13 +1,12 @@ #include <stdio.h> #include <stdlib.h> #include <string.h> -#include <sys/errno.h> #include <sys/types.h> -#include <sys/fcntl.h> #include <sys/stat.h> #include <sys/time.h> #include <errno.h> #include <sys/wait.h> +#include <fcntl.h> #include <unistd.h> #include <time.h> /* TESTS :