| ... | ... |
@@ -307,10 +307,12 @@ static int hfsplus_scanfile(cli_ctx *ctx, hfsPlusVolumeHeader *volHeader, hfsHea |
| 307 | 307 |
|
| 308 | 308 |
/* check limits */ |
| 309 | 309 |
targetSize = fork->logicalSize; |
| 310 |
+#if SIZEOF_LONG < 8 |
|
| 310 | 311 |
if (targetSize > ULONG_MAX) {
|
| 311 | 312 |
cli_dbgmsg("hfsplus_dumpfile: File too large for limit check.\n");
|
| 312 | 313 |
return CL_EFORMAT; |
| 313 | 314 |
} |
| 315 |
+#endif |
|
| 314 | 316 |
ret = cli_checklimits("hfsplus_scanfile", ctx, (unsigned long)targetSize, 0, 0);
|
| 315 | 317 |
if (ret != CL_CLEAN) {
|
| 316 | 318 |
return ret; |