classpath
[Top][All Lists]
Advanced

[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]

Bad sprintf code in Double.c / Float.c ?


From: John Leuner
Subject: Bad sprintf code in Double.c / Float.c ?
Date: Sun, 22 Apr 2001 20:19:48 +0000
User-agent: Mutt/1.3.15i

Looking at the Float.c and Double.c I couldn't help but wonder at these lines:

  char buf[1024];
  jstring retval;

  sprintf((char*)&buf, "%G", d);


Why is there a cast to char*, surely buf is a char* itself (not needing the & 
operator)?


What needs to be done to get this output conformant with what SUN's JVM prints 
out?

John Leuner
-- 



reply via email to

[Prev in Thread] Current Thread [Next in Thread]