Bug 1269501: Part 2 - Add additional libc constants to OS.Constants.libc. r=aswan

MozReview-Commit-ID: H7t3lUvKfY

--HG--
extra : rebase_source : bcbf14796fcaa31097273df81d64173e824bb45e
This commit is contained in:
Kris Maglione 2016-05-08 20:34:48 -07:00
Родитель 91c9dcbb5c
Коммит 1f20564e4e
1 изменённых файлов: 23 добавлений и 2 удалений

Просмотреть файл

@ -14,12 +14,14 @@
#if defined(XP_UNIX)
#include "unistd.h"
#include "dirent.h"
#include "poll.h"
#include "sys/stat.h"
#if defined(ANDROID)
#include <sys/vfs.h>
#define statvfs statfs
#else
#include "sys/statvfs.h"
#include "sys/wait.h"
#include <spawn.h>
#endif // defined(ANDROID)
#endif // defined(XP_UNIX)
@ -404,6 +406,9 @@ static const dom::ConstantSpec gLibcProperties[] =
{
// Arguments for open
INT_CONSTANT(O_APPEND),
#if defined(O_CLOEXEC)
INT_CONSTANT(O_CLOEXEC),
#endif // defined(O_CLOEXEC)
INT_CONSTANT(O_CREAT),
#if defined(O_DIRECTORY)
INT_CONSTANT(O_DIRECTORY),
@ -441,6 +446,10 @@ static const dom::ConstantSpec gLibcProperties[] =
INT_CONSTANT(O_TRUNC),
INT_CONSTANT(O_WRONLY),
#if defined(FD_CLOEXEC)
INT_CONSTANT(FD_CLOEXEC),
#endif // defined(FD_CLOEXEC)
#if defined(AT_EACCESS)
INT_CONSTANT(AT_EACCESS),
#endif //defined(AT_EACCESS)
@ -482,13 +491,25 @@ static const dom::ConstantSpec gLibcProperties[] =
INT_CONSTANT(SEEK_END),
INT_CONSTANT(SEEK_SET),
// fcntl command values
#if defined(XP_UNIX)
// poll
INT_CONSTANT(POLLERR),
INT_CONSTANT(POLLHUP),
INT_CONSTANT(POLLIN),
INT_CONSTANT(POLLNVAL),
INT_CONSTANT(POLLOUT),
// wait
INT_CONSTANT(WNOHANG),
// fcntl command values
INT_CONSTANT(F_GETLK),
INT_CONSTANT(F_SETFD),
INT_CONSTANT(F_SETFL),
INT_CONSTANT(F_SETLK),
INT_CONSTANT(F_SETLKW),
// flock type values
// flock type values
INT_CONSTANT(F_RDLCK),
INT_CONSTANT(F_WRLCK),
INT_CONSTANT(F_UNLCK),