< prev index next >

make/src/native/genconstants/fs/genUnixConstants.c

Print this page
rev 13048 : 8203369: Check for both EAGAIN and EWOULDBLOCK error codes
Reviewed-by: alanb
   1 /*
   2  * Copyright (c) 2008, 2012, Oracle and/or its affiliates. All rights reserved.
   3  * DO NOT ALTER OR REMOVE COPYRIGHT NOTICES OR THIS FILE HEADER.
   4  *
   5  * This code is free software; you can redistribute it and/or modify it
   6  * under the terms of the GNU General Public License version 2 only, as
   7  * published by the Free Software Foundation.  Oracle designates this
   8  * particular file as subject to the "Classpath" exception as provided
   9  * by Oracle in the LICENSE file that accompanied this code.
  10  *
  11  * This code is distributed in the hope that it will be useful, but WITHOUT
  12  * ANY WARRANTY; without even the implied warranty of MERCHANTABILITY or
  13  * FITNESS FOR A PARTICULAR PURPOSE.  See the GNU General Public License
  14  * version 2 for more details (a copy is included in the LICENSE file that
  15  * accompanied this code).
  16  *
  17  * You should have received a copy of the GNU General Public License version
  18  * 2 along with this work; if not, write to the Free Software Foundation,
  19  * Inc., 51 Franklin St, Fifth Floor, Boston, MA 02110-1301 USA.
  20  *
  21  * Please contact Oracle, 500 Oracle Parkway, Redwood Shores, CA 94065 USA
  22  * or visit www.oracle.com if you need additional information or have any


  96     DEFX(S_IFBLK);
  97     DEFX(S_IFIFO);
  98 
  99     // access modes
 100     DEF(R_OK);
 101     DEF(W_OK);
 102     DEF(X_OK);
 103     DEF(F_OK);
 104 
 105     // errors
 106     DEF(ENOENT);
 107     DEF(EACCES);
 108     DEF(EEXIST);
 109     DEF(ENOTDIR);
 110     DEF(EINVAL);
 111     DEF(EXDEV);
 112     DEF(EISDIR);
 113     DEF(ENOTEMPTY);
 114     DEF(ENOSPC);
 115     DEF(EAGAIN);

 116     DEF(ENOSYS);
 117     DEF(ELOOP);
 118     DEF(EROFS);
 119 #ifndef ENODATA
 120     // Only used in Linux java source, provide any value so it compiles
 121     emit("ENODATA", ELAST);
 122 #else
 123     DEF(ENODATA);
 124 #endif
 125     DEF(ERANGE);
 126     DEF(EMFILE);
 127 
 128     // flags used with openat/unlinkat/etc.
 129 #if defined(AT_SYMLINK_NOFOLLOW) && defined(AT_REMOVEDIR)
 130     DEFX(AT_SYMLINK_NOFOLLOW)
 131     DEFX(AT_REMOVEDIR);
 132 #else
 133     // not supported (dummy values will not be used at runtime).
 134     emitX("AT_SYMLINK_NOFOLLOW", 0x0);
 135     emitX("AT_REMOVEDIR", 0x0);
   1 /*
   2  * Copyright (c) 2008, 2018, Oracle and/or its affiliates. All rights reserved.
   3  * DO NOT ALTER OR REMOVE COPYRIGHT NOTICES OR THIS FILE HEADER.
   4  *
   5  * This code is free software; you can redistribute it and/or modify it
   6  * under the terms of the GNU General Public License version 2 only, as
   7  * published by the Free Software Foundation.  Oracle designates this
   8  * particular file as subject to the "Classpath" exception as provided
   9  * by Oracle in the LICENSE file that accompanied this code.
  10  *
  11  * This code is distributed in the hope that it will be useful, but WITHOUT
  12  * ANY WARRANTY; without even the implied warranty of MERCHANTABILITY or
  13  * FITNESS FOR A PARTICULAR PURPOSE.  See the GNU General Public License
  14  * version 2 for more details (a copy is included in the LICENSE file that
  15  * accompanied this code).
  16  *
  17  * You should have received a copy of the GNU General Public License version
  18  * 2 along with this work; if not, write to the Free Software Foundation,
  19  * Inc., 51 Franklin St, Fifth Floor, Boston, MA 02110-1301 USA.
  20  *
  21  * Please contact Oracle, 500 Oracle Parkway, Redwood Shores, CA 94065 USA
  22  * or visit www.oracle.com if you need additional information or have any


  96     DEFX(S_IFBLK);
  97     DEFX(S_IFIFO);
  98 
  99     // access modes
 100     DEF(R_OK);
 101     DEF(W_OK);
 102     DEF(X_OK);
 103     DEF(F_OK);
 104 
 105     // errors
 106     DEF(ENOENT);
 107     DEF(EACCES);
 108     DEF(EEXIST);
 109     DEF(ENOTDIR);
 110     DEF(EINVAL);
 111     DEF(EXDEV);
 112     DEF(EISDIR);
 113     DEF(ENOTEMPTY);
 114     DEF(ENOSPC);
 115     DEF(EAGAIN);
 116     DEF(EWOULDBLOCK);
 117     DEF(ENOSYS);
 118     DEF(ELOOP);
 119     DEF(EROFS);
 120 #ifndef ENODATA
 121     // Only used in Linux java source, provide any value so it compiles
 122     emit("ENODATA", ELAST);
 123 #else
 124     DEF(ENODATA);
 125 #endif
 126     DEF(ERANGE);
 127     DEF(EMFILE);
 128 
 129     // flags used with openat/unlinkat/etc.
 130 #if defined(AT_SYMLINK_NOFOLLOW) && defined(AT_REMOVEDIR)
 131     DEFX(AT_SYMLINK_NOFOLLOW)
 132     DEFX(AT_REMOVEDIR);
 133 #else
 134     // not supported (dummy values will not be used at runtime).
 135     emitX("AT_SYMLINK_NOFOLLOW", 0x0);
 136     emitX("AT_REMOVEDIR", 0x0);
< prev index next >