This is the mail archive of the gdb-prs@sourceware.org mailing list for the GDB project.


Index Nav: [Date Index] [Subject Index] [Author Index] [Thread Index]
Message Nav: [Date Prev] [Date Next] [Thread Prev] [Thread Next]
Other format: [Raw text]

[Bug build/12904] New: dwarf2loc.c uses return in void functions


http://sourceware.org/bugzilla/show_bug.cgi?id=12904

           Summary: dwarf2loc.c uses return in void functions
           Product: gdb
           Version: 7.2
            Status: NEW
          Severity: minor
          Priority: P2
         Component: build
        AssignedTo: unassigned@sourceware.org
        ReportedBy: tim.mooney@ndsu.edu


Created attachment 5797
  --> http://sourceware.org/bugzilla/attachment.cgi?id=5797
patch to remove "return" statements from two void functions

I'm building gdb-7.2 on x86_64-sun-solaris2.10 with the Sun Workshop 12u1
compiler toolchain.

gdb/dwarf2loc.c has a couple of functions that are "void", but for which the
function tries to return the result of some other function call.

That's illegal, and the return is superfluous in this case.  Just call the
function without using "return".

Patch attached.

-- 
Configure bugmail: http://sourceware.org/bugzilla/userprefs.cgi?tab=email
------- You are receiving this mail because: -------
You are on the CC list for the bug.


Index Nav: [Date Index] [Subject Index] [Author Index] [Thread Index]
Message Nav: [Date Prev] [Date Next] [Thread Prev] [Thread Next]