Mirror of the gdb mailing list
 help / color / mirror / Atom feed
From: "Grzegorz Cieslewski" <cieslewski@hcs.ufl.edu>
To: gdb@sourceware.org
Subject: Return value of program being debugged
Date: Sat, 15 Dec 2007 14:33:00 -0000	[thread overview]
Message-ID: <7aa837f80712150633t11dbfc41wb865f5797cc1d897@mail.gmail.com> (raw)

Hi,

I have encountered an interesting problem.
Upon executing the program:
int main()
{
        return(-1);
}

in gdb I get the following output

(gdb) r
Starting program: /tmp/test

Program exited with code 0377.
(gdb) q

Could someone tell me how is "-1" mapped to "0377"?

Greg
-- 
=====================================================
Grzegorz Cieslewski
Research Assistant
High-performance Computing & Simulation (HCS) Research Laboratory
University of Florida, Dept. of Electrical and Computer Engineering
330 Benton Hall, Gainesville, FL, 32611-6200
Phone: (352) 392-9041
Email: cieslewski@hcs.ufl.edu
Web: www.hcs.ufl.edu
=====================================================


             reply	other threads:[~2007-12-15 14:33 UTC|newest]

Thread overview: 2+ messages / expand[flat|nested]  mbox.gz  Atom feed  top
2007-12-15 14:33 Grzegorz Cieslewski [this message]
2007-12-15 15:07 ` Daniel Jacobowitz

Reply instructions:

You may reply publicly to this message via plain-text email
using any one of the following methods:

* Save the following mbox file, import it into your mail client,
  and reply-to-all from there: mbox

  Avoid top-posting and favor interleaved quoting:
  https://en.wikipedia.org/wiki/Posting_style#Interleaved_style

* Reply using the --to, --cc, and --in-reply-to
  switches of git-send-email(1):

  git send-email \
    --in-reply-to=7aa837f80712150633t11dbfc41wb865f5797cc1d897@mail.gmail.com \
    --to=cieslewski@hcs.ufl.edu \
    --cc=gdb@sourceware.org \
    /path/to/YOUR_REPLY

  https://kernel.org/pub/software/scm/git/docs/git-send-email.html

* If your mail client supports setting the In-Reply-To header
  via mailto: links, try the mailto: link
Be sure your reply has a Subject: header at the top and a blank line before the message body.
This is a public inbox, see mirroring instructions
for how to clone and mirror all data and code used for this inbox