Fix "control reaches end of non-void function" errors in testsuite
authorGary Benson <gbenson@redhat.com>
Fri, 15 May 2020 14:03:42 +0000 (15:03 +0100)
committerGary Benson <gbenson@redhat.com>
Fri, 15 May 2020 14:03:42 +0000 (15:03 +0100)
commit86e4e63d7cabb94a80a5ce767f670b65add5a083
tree3d623c14d1475c21d0c7fc4076f4ae134e96fec9
parent163df4df08aa7b0dda75261c19832c8e66b2059c
Fix "control reaches end of non-void function" errors in testsuite

When running the testsuite with clang, a number of testcases fail to
build with the following errors:
  warning: control reaches end of non-void function [-Wreturn-type]
  warning: control may reach end of non-void function [-Wreturn-type]

This prevents a number of testcases from executing.  This commit fixes.

gdb/testsuite/ChangeLog:

* gdb.base/info-os.c (main): Add return statement.
* gdb.base/info_minsym.c (minsym_fun): Likewise.
* gdb.base/large-frame-2.c (func): Likewise.
* gdb.base/pr10179-a.c (foo1, bar1): Likewise.
* gdb.base/pr10179-b.c (foo2): Likewise.
* gdb.base/valgrind-disp-step.c (foo): Likewise.
* gdb.base/watch-cond.c (func): Likewise.
* gdb.multi/goodbye.c (verylongfun): Likewise.
* gdb.multi/hello.c (commonfun): Likewise.
* gdb.python/py-finish-breakpoint.c (call_longjmp): Likewise.
* gdb.threads/fork-plus-threads.c (thread_func): Likewise.
* gdb.threads/forking-threads-plus-breakpoint.c (thread_forks):
Likewise.
* gdb.threads/hand-call-new-thread.c (foo): Likewise.
* gdb.threads/interrupt-while-step-over.c (child_function):
Likewise.
* gdb.trace/actions-changed.c (end): Likewise.
16 files changed:
gdb/testsuite/ChangeLog
gdb/testsuite/gdb.base/info-os.c
gdb/testsuite/gdb.base/info_minsym.c
gdb/testsuite/gdb.base/large-frame-2.c
gdb/testsuite/gdb.base/pr10179-a.c
gdb/testsuite/gdb.base/pr10179-b.c
gdb/testsuite/gdb.base/valgrind-disp-step.c
gdb/testsuite/gdb.base/watch-cond.c
gdb/testsuite/gdb.multi/goodbye.c
gdb/testsuite/gdb.multi/hello.c
gdb/testsuite/gdb.python/py-finish-breakpoint.c
gdb/testsuite/gdb.threads/fork-plus-threads.c
gdb/testsuite/gdb.threads/forking-threads-plus-breakpoint.c
gdb/testsuite/gdb.threads/hand-call-new-thread.c
gdb/testsuite/gdb.threads/interrupt-while-step-over.c
gdb/testsuite/gdb.trace/actions-changed.c
This page took 0.046947 seconds and 4 git commands to generate.