login
Login
/
Register
Search
Forums
News
Blogs
Features
Site
Home
»
Mailing list archives
»
linux-kernel
»
2007
»
September
»
27
Re: Floating Point Issue
view
thread
!MAILaRCHIVE_VOTE_RePLACE
Previous message: [
thread
] [
date
] [
author
]
Next message: [
thread
] [
date
] [
author
]
[view in full thread]
From:
Xavier Bestel <xavier.bestel@...>
To: mahamuni ashish <ash_lkp@...>
Cc: <linux-kernel@...>
Subject:
Re: Floating Point Issue
Date: Thursday, September 27, 2007 - 11:21 am
On Thu, 2007-09-27 at 12:41 +0100, mahamuni ashish wrote:
quoted text
> int main() > { > float f= 1256.35; > char ch[4]; > > printf("\n1. f : %f",f); > memset(ch,'__PLACEHOLDER__0_',strlen(ch) );
Can't work. ch[]'s content is undefined, so strlen(ch) may read anywhere in memory, and/or memset() write anywhere. Xav -
unsubscribe notice
To unsubscribe from this list: send the line "unsubscribe linux-kernel" in the body of a message to
majordomo@vger.kernel.org
More majordomo info at
http://vger.kernel.org/majordomo-info.html
Please read the FAQ at
http://www.tux.org/lkml/
Previous message: [
thread
] [
date
] [
author
]
Next message: [
thread
] [
date
] [
author
]
Messages in current thread:
Floating Point Issue
, mahamuni ashish
, (Thu Sep 27, 7:41 am)
Re: Floating Point Issue
, Bernd Petrovitsch
, (Fri Sep 28, 4:31 am)
Re: Floating Point Issue
, linux-os (Dick Johnson)
, (Thu Sep 27, 4:53 pm)
Re: Floating Point Issue
, Jan Engelhardt
, (Thu Sep 27, 5:01 pm)
Re: Floating Point Issue
, Trond Myklebust
, (Thu Sep 27, 2:25 pm)
Re: Floating Point Issue
, Al Viro
, (Thu Sep 27, 11:29 am)
Re: Floating Point Issue
, Xavier Bestel
, (Thu Sep 27, 11:21 am)
Re: Floating Point Issue
, Jan Engelhardt
, (Thu Sep 27, 11:17 am)
Re: Floating Point Issue
, WANG Cong
, (Thu Sep 27, 10:32 pm)
Navigation
Create content
Mailing list archives
Recent posts
Popular discussions
linux-kernel
:
Tarkan Erimer
Re: Dual-Licensing Linux Kernel with GPL V2 and GPL V3
David Woodhouse
[PATCH 1/3] firmware: allow firmware files to be built into kernel image
Linus Torvalds
Linux 2.6.21
Parag Warudkar
BUG: soft lockup - CPU#1 stuck for 15s! [swapper:0]
git
:
linux-netdev
:
David Miller
[GIT]: Networking
Rick Jones
Re: Network latency regressions from 2.6.22 to 2.6.29
Gerrit Renker
[PATCH 18/37] dccp: Support for Mandatory options
David Miller
Re: [PATCH] pkt_sched: Destroy gen estimators under rtnl_lock().
openbsd-misc
:
Colocation donated by:
Who's online
There are currently
2 users
and
739 guests
online.
Online users
spinalaidhudson
Adikajtaz
Syndicate