From 8e4b3a1e3930fe1b54a94a62ab3521c09fa22df6 Mon Sep 17 00:00:00 2001 From: Andreas Baumann Date: Mon, 7 May 2012 09:27:53 +0200 Subject: - --- pgsql.c | 3 +++ 1 file changed, 3 insertions(+) diff --git a/pgsql.c b/pgsql.c index 3198137..4932810 100644 --- a/pgsql.c +++ b/pgsql.c @@ -82,6 +82,9 @@ static PgDataInfo compute_block_info( size_t block_size, off_t offset, size_t le if( info.to_len == 0 ) { info.to_block--; + if( info.to_block < 0 ) { + info.to_block = 0; + } info.to_len = block_size; } -- cgit v1.2.3-54-g00ecf