MCPcopy Create free account
hub / github.com/ReadyTalk/avian / doOpen

Function doOpen

classpath/java-io.cpp:141–152  ·  view source on GitHub ↗

Source from the content-addressed store, hash-verified

139}
140
141inline int doOpen(JNIEnv* e, string_t path, int mask)
142{
143 int fd = OPEN(path, mask | OPEN_MASK, S_IRUSR | S_IWUSR);
144 if (fd == -1) {
145 if (errno == ENOENT) {
146 throwNewErrno(e, "java/io/FileNotFoundException");
147 } else {
148 throwNewErrno(e, "java/io/IOException");
149 }
150 }
151 return fd;
152}
153
154inline void doClose(JNIEnv* e, jint fd)
155{

Calls 2

throwNewErrnoFunction · 0.85
OPENFunction · 0.70

Tested by

no test coverage detected