netdev.vger.kernel.org archive mirror
 help / color / mirror / Atom feed
From: Sven Eckelmann <sven-KaDOiPu9UxWEi8DpZVb4nw@public.gmane.org>
To: David Howells <dhowells-H+wXaHxf7aLQT0dZR+AlfA@public.gmane.org>
Cc: netdev-u79uwXL29TY76Z2rM5mHXA@public.gmane.org,
	b.a.t.m.a.n-ZwoEplunGu2X36UT3dwllkB+6BGkLq7r@public.gmane.org,
	Marek Lindner <lindner_marek-LWAfsSFWpa4@public.gmane.org>,
	Simon Wunderlich
	<siwu-MaAgPAbsBIVS8oHt8HbXEIQuADTiUCJX@public.gmane.org>
Subject: Re: [PATCH 1/2] batman-adv: count_real_packets() in batman-adv assumes char is signed
Date: Wed, 15 Jun 2011 07:59:15 +0200	[thread overview]
Message-ID: <201106150759.15643.sven@narfation.org> (raw)
In-Reply-To: <20110614235132.3724.57632.stgit-S6HVgzuS8uM4Awkfq6JHfwNdhmdF6hFW@public.gmane.org>

[-- Attachment #1: Type: Text/Plain, Size: 738 bytes --]

David Howells wrote:
> count_real_packets() in batman-adv assumes char is signed, and returns -1
> through it:
> 
> net/batman-adv/routing.c: In function 'receive_bat_packet':
> net/batman-adv/routing.c:739: warning: comparison is always false due to
> limited range of data type
> 
> Use int instead.
> 

[...]
> -static char count_real_packets(struct ethhdr *ethhdr,
> -			       struct batman_packet *batman_packet,
> -			       struct hard_iface *if_incoming)
> +static int count_real_packets(struct ethhdr *ethhdr,
> +			      struct batman_packet *batman_packet,
> +			      struct hard_iface *if_incoming)
>  {


This one doesn't apply on linux-next/net-next-2.6, but I will fix it by hand.

Thanks,
	Sven

[-- Attachment #2: This is a digitally signed message part. --]
[-- Type: application/pgp-signature, Size: 836 bytes --]

  parent reply	other threads:[~2011-06-15  5:59 UTC|newest]

Thread overview: 5+ messages / expand[flat|nested]  mbox.gz  Atom feed  top
2011-06-14 23:51 [PATCH 1/2] batman-adv: count_real_packets() in batman-adv assumes char is signed David Howells
2011-06-14 23:51 ` [PATCH 2/2] batman-adv: compare_eth() should take const pointer arguments David Howells
2011-06-15  5:56   ` Sven Eckelmann
     [not found] ` <20110614235132.3724.57632.stgit-S6HVgzuS8uM4Awkfq6JHfwNdhmdF6hFW@public.gmane.org>
2011-06-15  5:59   ` Sven Eckelmann [this message]
2011-06-15  6:58 ` [PATCH 1/2] batman-adv: count_real_packets() in batman-adv assumes char is signed Sven Eckelmann

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=201106150759.15643.sven@narfation.org \
    --to=sven-kadoipu9uxwei8dpzvb4nw@public.gmane.org \
    --cc=b.a.t.m.a.n-ZwoEplunGu2X36UT3dwllkB+6BGkLq7r@public.gmane.org \
    --cc=dhowells-H+wXaHxf7aLQT0dZR+AlfA@public.gmane.org \
    --cc=lindner_marek-LWAfsSFWpa4@public.gmane.org \
    --cc=netdev-u79uwXL29TY76Z2rM5mHXA@public.gmane.org \
    --cc=siwu-MaAgPAbsBIVS8oHt8HbXEIQuADTiUCJX@public.gmane.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).