From: hpa Date: Fri, 30 Jun 2000 07:44:26 +0000 (+0000) Subject: Fix running as a normal user (incorrect handling of "offset") X-Git-Tag: syslinux-1.49-0x3964365c~1 X-Git-Url: http://review.tizen.org/git/?a=commitdiff_plain;h=32e9ad305fdfcfbea01e2d95f2b1db0cb7e728bc;p=platform%2Fupstream%2Fsyslinux.git Fix running as a normal user (incorrect handling of "offset") --- diff --git a/syslinux.c b/syslinux.c index f095f8f2..fb82fc5 100644 --- a/syslinux.c +++ b/syslinux.c @@ -282,7 +282,8 @@ int main(int argc, char *argv[]) !hasmntopt(mnt, "ro") && mnt->mnt_dir[0] == '/' && !!hasmntopt(mnt, "loop") == !!S_ISREG(st.st_mode) && - atol(hasmntopt(mnt, "offset")) == offset) { + ( (!hasmntopt(mnt,"offset") && offset == 0) || + (atol(hasmntopt(mnt, "offset")) == offset) ) ) { /* Okay, this is an fstab entry we should be able to live with. */ mntpath = mnt->mnt_dir;