Skip to content

Commit

Permalink
MDEV-12310 openat(<directory>, ...O_EXEC) fails on Illumos / Solaris
Browse files Browse the repository at this point in the history
it could be
* O_SEARCH on Illumos
* O_EXEC on FreeBSD
* O_PATH on Linux
ugh
  • Loading branch information
vuvova committed Apr 20, 2017
1 parent 786363e commit 036b689
Showing 1 changed file with 5 additions and 1 deletion.
6 changes: 5 additions & 1 deletion mysys/mysys_priv.h
Original file line number Diff line number Diff line change
Expand Up @@ -89,9 +89,13 @@ void sf_free(void *ptr);

void my_error_unregister_all(void);

#if !defined(O_PATH) && defined(O_EXEC) /* FreeBSD */
#ifndef O_PATH /* not Linux */
#if defined(O_SEARCH) /* Illumos */
#define O_PATH O_SEARCH
#elif defined(O_EXEC) /* FreeBSD */
#define O_PATH O_EXEC
#endif
#endif

#ifdef O_PATH
#define HAVE_OPEN_PARENT_DIR_NOSYMLINKS
Expand Down

0 comments on commit 036b689

Please sign in to comment.