summaryrefslogtreecommitdiffstats
path: root/src/hidden.c
diff options
context:
space:
mode:
authorChristophe Grenier <grenier@cgsecurity.org>2010-05-21 09:17:55 +0200
committerChristophe Grenier <grenier@cgsecurity.org>2010-05-21 09:17:55 +0200
commit76dffac4ca51aa1e79130a3c4752a429e3a086e0 (patch)
tree82764e9e113bda707960315128f12fcb160e55e7 /src/hidden.c
parent21d47fea5168186938a4187055afe1d4d042977e (diff)
Another fix for DCO/HPA detection
Diffstat (limited to 'src/hidden.c')
-rw-r--r--src/hidden.c4
1 files changed, 2 insertions, 2 deletions
diff --git a/src/hidden.c b/src/hidden.c
index 556bbfa..c167005 100644
--- a/src/hidden.c
+++ b/src/hidden.c
@@ -37,8 +37,8 @@ int is_hpa_or_dco(const disk_t *disk)
log_warning("%s: Host Protected Area (HPA) present.\n", disk->device);
res=1;
}
- if((disk->native_max > 0 && disk->native_max < disk->dco) ||
- (disk->user_max > 0 && disk->user_max < disk->dco))
+ if((disk->native_max > 0 && disk->user_max < disk->native_max+1 && disk->native_max < disk->dco) ||
+ (disk->user_max > 0 && disk->user_max < disk->dco+1))
{
log_warning("%s: Device Configuration Overlay (DCO) present.\n", disk->device);
res=1;