Added imginfo format check

Resolves: http://bugzilla.redhat.com/show_bug.cgi?id=969296
(CVE-2013-2131)

Signed-off-by: Jaroslav Škarvada <jskarvad@redhat.com>
Merge pull request #397 from yarda/yardas

Added imginfo format check
Update a maximum of row_cnt rows when updating an rra
Merge pull request #399 from CapnBry/overupdate

Update a maximum of row_cnt rows when updating an rra
fix typo, localststedir->localstatedir
pull in libgen.h, needed for basename()
Merge pull request #401 from sthen/master

fixes for rrdupdate, and rrdcached doc
Add prototype for bad_format_imginfo

This patch solve implicit declaration of function 'bad_format_imginfo'
warning introduced by commit 37d3050 "Added imginfo format check".

rrd_graph.c: In function 'rrd_graph_v':
rrd_graph.c:4025: warning: implicit declaration of function 'bad_format_imginfo'
rrd_graph.c:4025: warning: nested extern declaration of 'bad_format_imginfo'
rrd_graph.c: At top level:
rrd_graph.c:4836: warning: no previous prototype for 'bad_format_imginfo'
Allow empty imginfo string format

Commit 37d3050 "Added imginfo format check" breaks -f "" which used
to be very usefull to print data as text format on stdout. Allowing
an empty -f was particularly interesting because there was no
<width>x<height> printed out.

Before :

[root@nagios-2b ~]# rrdtool graph /dev/null -f "" --start -1d \
    DEF:d=/var/lib/rrd/nagios-2b/load.rrd:load5:AVERAGE \
    VDEF:v=d,AVERAGE \
    PRINT:v:%.6lf
5.284605

After :

[root@nagios-2b ~]# rrdtool graph /dev/null -f "" --start -1d \
    DEF:d=/var/lib/rrd/nagios-2b/load.rrd:load5:AVERAGE \
    VDEF:v=d,AVERAGE \
    PRINT:v:%.6lf
ERROR: bad format for imginfo
Merge pull request #402 from julthomas/jth/imginfo

Related to  37d3050 "Added imginfo format check"