bug-gnubg
[Top][All Lists]
Advanced

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

Re: [Bug-gnubg] Crash when generating 2-sided db


From: Jim Segrave
Subject: Re: [Bug-gnubg] Crash when generating 2-sided db
Date: Thu, 12 Dec 2002 16:45:49 +0100
User-agent: Mutt/1.4i

On Thu 12 Dec 2002 (16:31 +0100), Holger wrote:
> At 15:03 12.12.2002 +0000, Joern Thyssen wrote:
> >It's hard to say what goes wrong if I can't see a dump analysis with
> >gdb. 
> 
> I'm in the process of debugging.
> 
> So far I can tell that it crashes here:
> 
>     fprintf ( stderr,
>               _("Two-sided database:\n"
>                 "Number of points             : %12d\n"
>                 "Number of chequers           : %12d\n"
>                 "Calculate equities           : %s\n"
>                 "Write header                 : %s\n"
>                 "Number of one-sided positions: %12d\n"
>                 "Total number of positions    : %12d\n"
>                 "Size of resulting file       : %12lld bytes (%lld MB)\n"
>                 "Size of hash                 : %12d bytes\n"
>                 "Reuse old bearoff database   : %s %s\n"),
>               nTSP, nTSC,
>               fCubeful ? _("cubeless and cubeful") : _("cubeless only"),
>               fHeader ? _("yes") : ("no"),
>               n,
>               n * n,
>               l,l >> 20,
>               nHashSize,
>               szOldBearoff ? "yes" : "no",
>               szOldBearoff ? szOldBearoff : "" );
> 
> I've commented out the above statement. Then it runs through.
> 
> I just don't know yet which variable doesn't coincide with the format.

Mr. Thyssen is too modern and is using C99 things:

fred.c:6: warning: ANSI C does not support the `ll' length modifier

See what happens if you change %12lld to %12ld. Although I'm surprised
(if this fixes it) that a compiler would accept 
  long long l;
but not let you print it with %lld

-- 
Jim Segrave           address@hidden



reply via email to

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