From: Pete Zaitcev <zaitcev@redhat.com>
To: Colin McCabe <cmccabe@alumni.cmu.edu>
Cc: Project Hail List <hail-devel@vger.kernel.org>,
Jeff Garzik <jeff@garzik.org>,
Colin McCabe <cmccabe@alumni.cmu.edu>
Subject: Re: [RFCv2] cld: replace "if (verbose) { act_log }" with CLD_DEBUG
Date: Sun, 6 Dec 2009 17:23:04 -0700 [thread overview]
Message-ID: <20091206172304.30cb0361@redhat.com> (raw)
In-Reply-To: <1260114065-14473-1-git-send-email-cmccabe@alumni.cmu.edu>
On Sun, 6 Dec 2009 07:41:05 -0800
Colin McCabe <cmccabe@alumni.cmu.edu> wrote:
> Move prototypes for common.c functions out of cld_msg.h and into a new header
> file, common.h. Create a structure that represents the current log level and
> also the function to use for logging.
> static int sess_send_pkt(struct cldc_session *sess,
> const struct cld_packet *pkt, size_t pkt_len)
> {
> - if (sess->verbose) {
> + if (sess->log.verbose) {
> uint32_t flags = le32_to_cpu(pkt->flags);
> bool first = (flags & CPF_FIRST);
> bool last = (flags & CPF_LAST);
I'm wondering if we can drop these ifs now, at the cost of some
small inefficiency.
-- Pete
next prev parent reply other threads:[~2009-12-07 0:23 UTC|newest]
Thread overview: 4+ messages / expand[flat|nested] mbox.gz Atom feed top
2009-12-06 15:41 [RFCv2] cld: replace "if (verbose) { act_log }" with CLD_DEBUG Colin McCabe
2009-12-07 0:23 ` Pete Zaitcev [this message]
2009-12-07 1:06 ` Jeff Garzik
2009-12-07 22:03 ` Jeff Garzik
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=20091206172304.30cb0361@redhat.com \
--to=zaitcev@redhat.com \
--cc=cmccabe@alumni.cmu.edu \
--cc=hail-devel@vger.kernel.org \
--cc=jeff@garzik.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 an external index of several public inboxes,
see mirroring instructions on how to clone and mirror
all data and code used by this external index.