fixed some issue on scanning data block

Signed-off-by: Claudio Bisegni <Claudio.Bisegni@lnf.infn.it>