Commit Graph

8 Commits

Author SHA1 Message Date
Pedro Alves 5c9e4427a7 Fix gdb.base/print-file-var-main.c value check logic
Fix a typo introduced in commit c56e7c4390 ("Make ctxobj.exp and
print-file-var.exp work on all platforms.").

This doesn't really affect the outcome of the testcase.  I only
noticed the typo because I stepped through the program manually.

To avoid such problems if the test is extended, this moves the STOP
marker until after the program self-validates the values.  With the
typo in place, this alone would have resulted in a test FAIL.  I.e.,
it'd have caught the typo.

gdb/testsuite/ChangeLog:
2017-10-09  Pedro Alves  <palves@redhat.com>

	* gdb.base/print-file-var-main.c: Fix get_version_2 value check
	logic.  Move STOP marker after the value checks.
	* gdb.base/print-file-var.exp (continue to STOP marker): Tighten
	regexp.
2017-10-09 12:33:31 +01:00
Joel Brobecker 61baf725ec update copyright year range in GDB files
This applies the second part of GDB's End of Year Procedure, which
updates the copyright year range in all of GDB's files.

gdb/ChangeLog:

        Update copyright year range in all GDB files.
2017-01-01 10:52:34 +04:00
Joel Brobecker 618f726fcb GDB copyright headers update after running GDB's copyright.py script.
gdb/ChangeLog:

        Update year range in copyright notice of all files.
2016-01-01 08:43:22 +04:00
Joel Brobecker 32d0add0a6 Update year range in copyright notice of all files owned by the GDB project.
gdb/ChangeLog:

        Update year range in copyright notice of all files.
2015-01-01 13:32:14 +04:00
Joel Brobecker ecd75fc8ee Update Copyright year range in all files maintained by GDB. 2014-01-01 07:54:24 +04:00
Joel Brobecker 28e7fd6234 Update years in copyright notice for the GDB files.
Two modifications:
  1. The addition of 2013 to the copyright year range for every file;
  2. The use of a single year range, instead of potentially multiple
     year ranges, as approved by the FSF.
2013-01-01 06:33:28 +00:00
Joel Brobecker c56e7c4390 Make ctxobj.exp and print-file-var.exp work on all platforms.
This patch adjusts the testing strategy used in a couple of testcases
where we are trying to print the value of a global variable defined
at multiple locations.  The problem is that the actual value depends
on the platform.  So instead of hard-coding the expected value in
the testcase script, we use local variables (in the inferior) holding
the correct value, and we compare the global variable's value with
the local variable's value.

gdb/testsuite/ChangeLog:

        * gdb.base/ctxobj-f.c (GET_VERSION): Introduce local variable
        and add comment.
        * gdb.base/ctxobj-m.c (main): Rewrite, and add comment.
        * gdb.base/ctxobj.exp: Insert breakpoint in ctxobj-f.c using
        "STOP" marker.  Adjust testing strategy to make it work on
        all targets.

        * gdb.base/print-file-var-main.c (main): Rewrite using local
        variables and adjust get_version_2's return value check.
        Add small comment.
        * gdb.base/print-file-var.exp: Insert breakpoint using "STOP"
        marker.  Adjust testing strategy to make it work on all targets.
2012-06-05 13:50:31 +00:00
Joel Brobecker 64ea88dcd7 Add print 'file'::var testcase with two libs defining the same global variable
gdb/testsuite/ChangeLog:

	* gdb.base/print-file-var-lib1.c, gdb.base/print-file-var-lib2.c,
	gdb.base/print-file-var-main.c, gdb.base/print-file-var.exp:
	New files.

gdb/ChangeLog:

        * config/djgpp/fnchange.lst: Add entries for print-file-var-lib1.c,
        print-file-var-lib2.c, print-file-var-main.c and
        print-file-var.exp (located in gdb/testsuite/gdb.base).
2012-05-10 16:25:19 +00:00