}
mailmap = mmap(0, st.st_size, PROT_READ, MAP_SHARED, mailfd, 0);
- if(mailmap == (void *)-1) {
+ if(mailmap == MAP_FAILED) {
log_error(LOG_ARGS, "Could not mmap mailfd");
exit(EXIT_FAILURE);
}
}
if((inmap = mmap(0, st.st_size, PROT_READ, MAP_SHARED,
- subreadfd, 0)) == (void *)-1) {
+ subreadfd, 0)) == MAP_FAILED) {
log_error(LOG_ARGS, "Could not mmap fd");
return 1;
}
}
if((start = mmap(0, st.st_size, PROT_READ, MAP_SHARED, fd, 0)) ==
- (void *)-1) {
+ MAP_FAILED) {
log_error(LOG_ARGS, "Could not mmap fd");
return (off_t)-1;
}