Commit 918910e2 authored by Rémi Denis-Courmont's avatar Rémi Denis-Courmont

Disable mmap by default (works around #2188)

parent d3ab3afe
...@@ -58,11 +58,7 @@ vlc_module_begin(); ...@@ -58,11 +58,7 @@ vlc_module_begin();
set_capability ("access", 52); set_capability ("access", 52);
add_shortcut ("file"); add_shortcut ("file");
set_callbacks (Open, Close); set_callbacks (Open, Close);
#ifdef __APPLE__
add_bool ("file-mmap", false, NULL, add_bool ("file-mmap", false, NULL,
#else
add_bool ("file-mmap", true, NULL,
#endif
FILE_MMAP_TEXT, FILE_MMAP_LONGTEXT, true); FILE_MMAP_TEXT, FILE_MMAP_LONGTEXT, true);
vlc_module_end(); vlc_module_end();
...@@ -86,6 +82,8 @@ static int Open (vlc_object_t *p_this) ...@@ -86,6 +82,8 @@ static int Open (vlc_object_t *p_this)
const char *path = p_access->psz_path; const char *path = p_access->psz_path;
int fd; int fd;
assert ((INT64_C(1) << 63) == ((off_t)(INT64_C(1) << 63)));
if (!var_CreateGetBool (p_this, "file-mmap")) if (!var_CreateGetBool (p_this, "file-mmap"))
return VLC_EGENERIC; /* disabled */ return VLC_EGENERIC; /* disabled */
......
Markdown is supported
0%
or
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment