[rrd-users] Question about the %lu (and so on)

Steve Shipway s.shipway at auckland.ac.nz
Wed Feb 19 02:54:45 CET 2014


%lu means 'insert long unsigned data type here'.  In your example, since the
width is always positive (IE unsigned) and stored internally as a long
(4byte value) a long-unsigned is used.  The imginfo definition replaces the
%s with the filename, and the two %lu with the width and height of the
generated image.  However, since this is just a format specifier for a
printf function, you cannot place any other % symbols in there and expect
different data...

For more details, read up on the C function 'printf' and the format
specifier http://www.cplusplus.com/reference/cstdio/printf/

Steve

Steve Shipway
s.shipway at auckland.ac.nz


-----Original Message-----
From: rrd-users-bounces+s.shipway=auckland.ac.nz at lists.oetiker.ch
[mailto:rrd-users-bounces+s.shipway=auckland.ac.nz at lists.oetiker.ch] On
Behalf Of Peter Thurner
Sent: Wednesday, 19 February 2014 4:57 a.m.
To: rrd-users at lists.oetiker.ch
Subject: [rrd-users] Question about the %lu (and so on)

Hi guys,


I was wondering what the %lu stands for, for example in this graphing
argument:

--imginfo '<IMG SRC=/rrd/%s WIDTH=%lu HEIGHT=%lu >'

I found the %s in the man page of rrdcgi, but only examples for %lu and no
explicit description of it.
Are there any more of those I want to know of? :) Is there a online manual
where I can reference those?


Also I'd like to ask if #rrdtool on IRCnet is the official channel? I've
asked a few questions there the last few days and never got a reply :( Also
I can of course understand that the community is not that big ;)


Thanks a lot in advance!
Peter

-------------- next part --------------
A non-text attachment was scrubbed...
Name: smime.p7s
Type: application/pkcs7-signature
Size: 5909 bytes
Desc: not available
Url : http://lists.oetiker.ch/pipermail/rrd-users/attachments/20140219/2b6a70cd/attachment.bin 


More information about the rrd-users mailing list