From: haris iqbal <haris.phnx@gmail.com>
To: qemu-devel@nongnu.org
Subject: [Qemu-devel] Query about BiteSizeTasks
Date: Mon, 21 Mar 2016 19:11:46 +0530 [thread overview]
Message-ID: <CAE_WKMy2s8v2L=S4YfBg0H8hWGvAvFd=TDoBirdbUJMqbPfBVQ@mail.gmail.com> (raw)
Hello,
I saw a task which says to " Add checks for NULL return value to uses
of load_image_targphys,...". But what I saw in the codebase,
load_image_targphys() returns int. So why should it be checks for
NULL.
NULL check is for pointer which can also be changed to (void *)0.
Should the return value be checked for 0. But when I saw what the
function is doing, it basically is what lseek will return in
get_image_size() and lseek return (off_t)-1 if it fails.
--
With regards,
Md Haris Iqbal,
Placement Coordinator, MTech IT
NITK Surathkal,
Contact: +91 8861996962
next reply other threads:[~2016-03-21 13:42 UTC|newest]
Thread overview: 5+ messages / expand[flat|nested] mbox.gz Atom feed top
2016-03-21 13:41 haris iqbal [this message]
2016-03-21 13:56 ` [Qemu-devel] Query about BiteSizeTasks Paolo Bonzini
2016-03-21 14:09 ` haris iqbal
2016-03-22 4:34 ` haris iqbal
2016-03-22 8:30 ` Paolo Bonzini
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='CAE_WKMy2s8v2L=S4YfBg0H8hWGvAvFd=TDoBirdbUJMqbPfBVQ@mail.gmail.com' \
--to=haris.phnx@gmail.com \
--cc=qemu-devel@nongnu.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;
as well as URLs for NNTP newsgroup(s).