correct handling of offset - partial merge from volker mildes patch. at date only disk.c uses offset, so there wont be any problem.