linux-wireless.vger.kernel.org archive mirror
 help / color / mirror / Atom feed
From: Ben Greear <greearb@candelatech.com>
To: Andreas Schwab <schwab@linux-m68k.org>
Cc: Ben Greear <greearb-my8/4N5VtI7c+919tysfdA@public.gmane.org>,
	linux-wireless@vger.kernel.org
Subject: Re: Patch to get iw building on Fedora 8
Date: Tue, 21 Sep 2010 14:09:57 -0700	[thread overview]
Message-ID: <4C991F25.1000102@candelatech.com> (raw)
In-Reply-To: <m2wrqej2qk.fsf@igel.home>

On 09/21/2010 12:49 PM, Andreas Schwab wrote:
> Ben Greear<greearb-my8/4N5VtI7c+919tysfdA@public.gmane.org>  writes:
>
>> I need this in order to get iw to build on Fedora 8.
>>
>> [greearb@fs2 iw]$ git diff
>> diff --git a/bitrate.c b/bitrate.c
>> index 8de8839..9b6defc 100644
>> --- a/bitrate.c
>> +++ b/bitrate.c
>> @@ -1,4 +1,6 @@
>>   #include<errno.h>
>> +#define  __USE_ISOC99
>
> This is wrong.  You must never define internal glibc macros.

How about this then?

diff --git a/bitrate.c b/bitrate.c
index 8de8839..f0d513f 100644
--- a/bitrate.c
+++ b/bitrate.c
@@ -70,7 +70,7 @@ static int handle_bitrates(struct nl80211_state *state,
  #endif
                 else switch (parser_state) {
                 case S_LEGACY:
-                       tmpf = strtof(argv[i], &end);
+                       tmpf = strtod(argv[i], &end);
                         if (*end != '\0')
                                 return 1;
                         if (tmpf < 1 || tmpf > 255 * 2)

Seems you don't have to do anything clever to get strtod to work,
and I assume it should cast just fine.

Thanks,
Ben

>
> Andreas.
>


-- 
Ben Greear <greearb@candelatech.com>
Candela Technologies Inc  http://www.candelatech.com


  reply	other threads:[~2010-09-21 21:10 UTC|newest]

Thread overview: 10+ messages / expand[flat|nested]  mbox.gz  Atom feed  top
2010-09-21 16:39 Patch to get iw building on Fedora 8 Ben Greear
2010-09-21 17:28 ` Johannes Berg
2010-09-23 23:05   ` Ben Greear
2010-09-24  9:31     ` Johannes Berg
2010-09-24 13:45       ` Ben Greear
2010-09-24 13:58         ` Johannes Berg
2010-09-21 19:49 ` Andreas Schwab
2010-09-21 21:09   ` Ben Greear [this message]
2010-09-21 21:34     ` Johannes Stezenbach
2010-09-22 16:52       ` Ben Greear

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=4C991F25.1000102@candelatech.com \
    --to=greearb@candelatech.com \
    --cc=greearb-my8/4N5VtI7c+919tysfdA@public.gmane.org \
    --cc=linux-wireless@vger.kernel.org \
    --cc=schwab@linux-m68k.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).