swarm-support
[Top][All Lists]
Advanced

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

[Swarm-Support] Questions about simpleBatchBug3


From: Clements
Subject: [Swarm-Support] Questions about simpleBatchBug3
Date: Sat, 16 Aug 2003 23:56:27 -0600 (MDT)

First:

I'm converting createTimeString from the tutorial's simpleBatchBug3
Output.m file to a usableform for a project I am working on and came to
wonder why timeString is 100 chars long? According to the man page for
ctime it returns a 26 character set, while a %4d sprintf shouldn't go over
that boundary either (I can represent a pretty big number with 25 base-10
characters).  A much smaller number or even a variable array could be used
without incident?

Is it just set that large for safety reasons, formatting reasons, or is
there something fundamental I'm missing???

Secondary question:

Do we have to worry about a character being ':' or ' ' or '\n' in the
snprintf of the run number?

Tertiary question:

The code in createTimeString iterates through all 100 items in the array.
Is there a reason to continue after setting a \n to a \0 in the string?

Thanks for any help on clarifying these.

Sincerely,
David




reply via email to

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