[PATCH] D30010: Improve the robustness of mmap

Zachary Turner via llvm-commits llvm-commits at lists.llvm.org
Mon Feb 20 07:48:47 PST 2017


Thanks for the heads up, I'll commit this on Tuesday after the long weekend
is over
On Mon, Feb 20, 2017 at 7:39 AM Pavel Labath via Phabricator <
reviews at reviews.llvm.org> wrote:

> labath added a comment.
>
> Seems to work for me after adding the magic.h include. I can't really
> guarantee that all bots will be happy with it though..
>
>
>
> ================
> Comment at: llvm/lib/Support/Unix/Path.inc:78
>  #include <sys/mount.h>
> -#elif defined(__ANDROID__)
> +#elif defined(__ANDROID__) || defined(__linux__)
>  #include <sys/vfs.h>
> ----------------
> `__ANDROID__` is a subset of `__linux__`. You can drop the former.
>
>
> ================
> Comment at: llvm/lib/Support/Unix/Path.inc:350
> +  switch ((uint32_t)Vfs.f_type) {
> +  case NFS_SUPER_MAGIC:
> +  case SMB_SUPER_MAGIC:
> ----------------
> You need to #include <linux/magic.h> to get these constants.
>
>
> https://reviews.llvm.org/D30010
>
>
>
>
-------------- next part --------------
An HTML attachment was scrubbed...
URL: <http://lists.llvm.org/pipermail/llvm-commits/attachments/20170220/fe243f9f/attachment.html>


More information about the llvm-commits mailing list