fix unsigned integer overflow when number of rows is 0
Merge pull request #6 from drico/master

Little bug fix