strbuf: use unsigned lengths

Fixes rhbz#1034869.

Signed-off-by: Martin Milata <mmilata@redhat.com>