gawk-diffs
[Top][All Lists]
Advanced

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

[gawk-diffs] [SCM] gawk branch, select, updated. gawk-4.1.0-1061-g4323eb


From: Andrew J. Schorr
Subject: [gawk-diffs] [SCM] gawk branch, select, updated. gawk-4.1.0-1061-g4323eba
Date: Mon, 05 Jan 2015 18:08:09 +0000

This is an automated email from the git hooks/post-receive script. It was
generated because a ref change was pushed to the repository containing
the project "gawk".

The branch, select has been updated
       via  4323eba6170c7aee1661d834a9b7c177a10b7764 (commit)
      from  0d867aa42ea8c3487678dcceea484c10c88914cb (commit)

Those revisions listed above that are new to this repository have
not appeared on any other notification email; so we list those
revisions in full, below.

- Log -----------------------------------------------------------------
http://git.sv.gnu.org/cgit/gawk.git/commit/?id=4323eba6170c7aee1661d834a9b7c177a10b7764

commit 4323eba6170c7aee1661d834a9b7c177a10b7764
Author: Andrew J. Schorr <address@hidden>
Date:   Mon Jan 5 13:07:47 2015 -0500

    Add new errno test to make sure PROCINFO["errno"] is working.

diff --git a/test/ChangeLog b/test/ChangeLog
index 7ff3e42..49b2684 100644
--- a/test/ChangeLog
+++ b/test/ChangeLog
@@ -1,3 +1,10 @@
+2015-01-05         Andrew J. Schorr     <address@hidden>
+
+       * Makefile.am (EXTRA_DIST): Add errno.awk, errno.in, and errno.ok.
+       (BASIC_TESTS): Add errno.
+       (errno): New test.
+       * errno.awk, errno.in, errno.ok: New files.
+
 2014-12-24         Arnold D. Robbins     <address@hidden>
 
        * Makefile.am (badbuild): New test.
diff --git a/test/Makefile.am b/test/Makefile.am
index 7335da3..0feaebc 100644
--- a/test/Makefile.am
+++ b/test/Makefile.am
@@ -208,6 +208,9 @@ EXTRA_DIST = \
        dynlj.ok \
        eofsplit.awk \
        eofsplit.ok \
+       errno.awk \
+       errno.in \
+       errno.ok \
        exit.ok \
        exit.sh \
        exit2.awk \
@@ -983,7 +986,7 @@ BASIC_TESTS = \
        childin clobber closebad clsflnam compare compare2 concat1 concat2 \
        concat3 concat4 convfmt \
        datanonl defref delargv delarpm2 delarprm delfunc dfamb1 dfastress 
dynlj \
-       eofsplit exit2 exitval1 exitval2 \
+       eofsplit errno exit2 exitval1 exitval2 \
        fcall_exit fcall_exit2 fldchg fldchgnf fnamedat fnarray fnarray2 \
        fnaryscl fnasgnm fnmisc fordel forref forsimp fsbs fsrs fsspcoln \
        fstabplus funsemnl funsmnam funstack \
@@ -1310,6 +1313,11 @@ devfd::
        @$(AWK) 1 /dev/fd/4 /dev/fd/5 4<"$(srcdir)"/devfd.in4 
5<"$(srcdir)"/devfd.in5 >_$@ 2>&1 || echo EXIT CODE: $$? >> _$@
        @-$(CMP) "$(srcdir)"/address@hidden _$@ && rm -f _$@
 
+errno:
+       @echo $@
+       @AWKPATH="$(srcdir)" $(AWK) -f address@hidden 
"$(srcdir)"/address@hidden >_$@ 2>&1 || echo EXIT CODE: $$? >>_$@
+       @-$(CMP) "$(srcdir)"/address@hidden _$@ && rm -f _$@
+
 fflush::
        @echo $@
        @"$(srcdir)"/fflush.sh >_$@
diff --git a/test/errno.awk b/test/errno.awk
new file mode 100644
index 0000000..bcb7761
--- /dev/null
+++ b/test/errno.awk
@@ -0,0 +1,10 @@
+BEGIN {
+  # check that PROCINFO["errno"] is working properly
+  getline
+  if (close(FILENAME)) {
+      print "Error `" ERRNO "' closing input file"
+      print "errno =", PROCINFO["errno"]
+  }
+  getline < (FILENAME "/bogus")
+  print (PROCINFO["errno"] > 0), ERRNO
+}
diff --git a/test/errno.in b/test/errno.in
new file mode 100644
index 0000000..a92d664
--- /dev/null
+++ b/test/errno.in
@@ -0,0 +1,3 @@
+line 1
+line 2
+line 3
diff --git a/test/errno.ok b/test/errno.ok
new file mode 100644
index 0000000..181afda
--- /dev/null
+++ b/test/errno.ok
@@ -0,0 +1,3 @@
+Error `close of redirection that was never opened' closing input file
+errno = 0
+1 Not a directory

-----------------------------------------------------------------------

Summary of changes:
 test/ChangeLog                 |    7 +++++++
 test/Makefile.am               |   10 +++++++++-
 test/errno.awk                 |   10 ++++++++++
 test/{clsflnam.in => errno.in} |    0
 test/{clsflnam.ok => errno.ok} |    2 ++
 5 files changed, 28 insertions(+), 1 deletions(-)
 create mode 100644 test/errno.awk
 copy test/{clsflnam.in => errno.in} (100%)
 copy test/{clsflnam.ok => errno.ok} (71%)


hooks/post-receive
-- 
gawk



reply via email to

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