bug in ozostream.cc @ mozart-1-3-0-fixes

Filip Konvička filip.konvicka.removethisantispamtoken at logis.cz
Tue Apr 18 11:20:00 CEST 2006


> Thanks a lot. I moved the bug to Engine and we'll let you know during 
> next week if we committed to the cvs. (Sorry, no access to a windows 
> machine during the weekend)


Oh my, I posted incorrect patch, it should be

Index: platform/emulator/ozostream.cc
===================================================================
RCS file: /services/mozart/CVS/mozart/platform/emulator/ozostream.cc,v
retrieving revision 1.18.18.1
diff -u -r1.18.18.1 ozostream.cc
--- platform/emulator/ozostream.cc	21 Feb 2006 09:36:05 -0000	1.18.18.1
+++ platform/emulator/ozostream.cc	16 Apr 2006 08:43:22 -0000
@@ -83,9 +83,9 @@
  {
    char buf[100];
    if (ozconf.printScientificFloats)
-    sprintf(buf,"%2$.*1$e",ozconf.printFloatPrecision,d);
+    sprintf(buf,"%.*e",ozconf.printFloatPrecision,d);
    else
-    sprintf(buf,"%2$.*1$g",ozconf.printFloatPrecision,d);
+    sprintf(buf,"%.*g",ozconf.printFloatPrecision,d);
    return *this << buf;
  }

This one does not print 0. as " 0" but as "0". Sorry!

Filip




More information about the mozart-hackers mailing list