bugGNUstep - Bugs: bug #10791, NSLog() does not support long long...

 
 

You are not allowed to post comments on this tracker with your current authentication level.

bug #10791: NSLog() does not support long long int correctly

Submitted by:  Fred Kiefer <FredKiefer>
Submitted on:  Sun 24 Oct 2004 06:33:24 PM UTC  
 
Category: Base/FoundationSeverity: 2 - Minor
Item Group: BugStatus: Fixed
Privacy: PublicAssigned to: Richard Frith-Macdonald <CaS>
Open/Closed: Closed

Mon 01 Nov 2004 01:21:21 PM UTC, comment #4:

That black magic of moving the include statements did the trick! The long long number is now outputed correctly on my system.

Thank you!

Fred Kiefer <FredKiefer>
Project Member
Mon 01 Nov 2004 08:27:04 AM UTC, comment #3:

I have tried moving around the order of including headers in GSFormat.m to
exactly mirror the way it's done in the autoconf tests ...
hopefully this will fix things on your system (as you report that the autoconf test produces the correct result).

Richard Frith-Macdonald <CaS>
Project MemberIn charge of this item.
Sun 31 Oct 2004 05:53:13 PM UTC, comment #2:

I also think that it is a system specific problem, but not that easy this time. It used to be the case that LONG_LONG_MAX was not found on SuSE systems, but we already corrected this and config.log correctly reports that it is found (LLONG_MAX isn't found).
In config.h I see the line:
#define HANDLE_LONG_LONG_MAX 1

We need another idea, what may go wrong here. Or perhaps this constant is found in the confic code, beacuse we use
#define _GNU_SOURCE
and a similar line is missing, when the constant gets used? But than the compiler should complain about a missing definition. No, just checked GSFormat.m has this define as well.

Fred Kiefer <FredKiefer>
Project Member
Sun 31 Oct 2004 10:01:40 AM UTC, comment #1:

I'm afraid this looks like a system specific problem.

I thing the configure.ac and/or the code in GSFormat.m is failing to find a definition of LONG_LONG_MAX on your system for some reason.
Please could you check this ...
If I've guessed the problem correctly, and you can figure out why the define is not being found, we can include the appropriate fields or define whatever other preprocessor constants we need to have it work on suse.

Richard Frith-Macdonald <CaS>
Project MemberIn charge of this item.
Sun 24 Oct 2004 06:33:24 PM UTC, original submission:

While debugging the output of a keyed decoding conversion from binary to XML, which did not handle a long long int value correctly I noticed that NSLog() does not handle this type correctly using %lli as template. Looks like
the value gets treated as an int.
I tried the same with printf() and this gave the correct output. I am using SuSE Linux 9.1 on Intel hardware.

Fred Kiefer <FredKiefer>
Project Member

 

No files currently attached

 

Depends on the following items: None found

Items that depend on this one: None found

 

CC list is empty

 

Do you think this task is very important?
If so, you can click here to add your encouragement to it.
This task has 0 encouragements so far.

Only logged-in users can vote.

 

Please enter the title of George Orwell's famous dystopian book (it's a date):

 

 

Follow 3 latest changes.

Date Changed By Updated Field Previous Value => Replaced By
Mon 01 Nov 2004 01:21:21 PM UTCFredKieferStatusNone=>Fixed
  Open/ClosedOpen=>Closed
Sun 31 Oct 2004 10:01:40 AM UTCCaSAssigned toNone=>CaS

Back to the top


Powered by Savane 3.1-cleanup1