mirror of
https://gitlab.torproject.org/tpo/core/tor.git
synced 2024-11-24 12:23:32 +01:00
when we decide not to mmap, because the file is empty or isn't
there at all, don't yell so loud. svn:r9065
This commit is contained in:
parent
ea93289590
commit
8cf8b8087a
@ -131,7 +131,7 @@ tor_mmap_file(const char *filename)
|
|||||||
|
|
||||||
fd = open(filename, O_RDONLY, 0);
|
fd = open(filename, O_RDONLY, 0);
|
||||||
if (fd<0) {
|
if (fd<0) {
|
||||||
log_warn(LD_FS,"Could not open \"%s\" for mmap().",filename);
|
log_info(LD_FS,"Could not open \"%s\" for mmap().",filename);
|
||||||
return NULL;
|
return NULL;
|
||||||
}
|
}
|
||||||
|
|
||||||
@ -144,7 +144,7 @@ tor_mmap_file(const char *filename)
|
|||||||
if (!size) {
|
if (!size) {
|
||||||
/* Zero-length file. If we call mmap on it, it will succeed but
|
/* Zero-length file. If we call mmap on it, it will succeed but
|
||||||
* return NULL, and bad things will happen. So just fail. */
|
* return NULL, and bad things will happen. So just fail. */
|
||||||
log_notice(LD_FS,"File \"%s\" is empty. Ignoring.",filename);
|
log_info(LD_FS,"File \"%s\" is empty. Ignoring.",filename);
|
||||||
return NULL;
|
return NULL;
|
||||||
}
|
}
|
||||||
|
|
||||||
|
Loading…
Reference in New Issue
Block a user