Home
last modified time | relevance | path

Searched refs:env (Results 1 – 25 of 88) sorted by relevance

1234

/unit/src/java/
H A Dnxt_jni.c35 (*env)->DeleteLocalRef(env, cls); in nxt_java_jni_init()
38 cls = (*env)->FindClass(env, "java/io/IOException"); in nxt_java_jni_init()
44 nxt_java_IOException_class = (*env)->NewGlobalRef(env, cls); in nxt_java_jni_init()
45 (*env)->DeleteLocalRef(env, cls); in nxt_java_jni_init()
56 (*env)->DeleteLocalRef(env, cls); in nxt_java_jni_init()
59 cls = (*env)->FindClass(env, "java/io/File"); in nxt_java_jni_init()
67 nxt_java_File_class = (*env)->NewGlobalRef(env, cls); in nxt_java_jni_init()
68 (*env)->DeleteLocalRef(env, cls); in nxt_java_jni_init()
77 (*env)->DeleteGlobalRef(env, nxt_java_File_class); in nxt_java_jni_init()
95 (*env)->ThrowNew(env, nxt_java_IOException_class, msg); in nxt_java_throw_IOException()
[all …]
H A Dnxt_jni_URLClassLoader.c27 cls = (*env)->FindClass(env, "java/net/URLClassLoader"); in nxt_java_initURLClassLoader()
34 (*env)->DeleteLocalRef(env, cls); in nxt_java_initURLClassLoader()
37 nxt_java_URLClassLoader_ctor = (*env)->GetMethodID(env, cls, in nxt_java_initURLClassLoader()
65 cls = (*env)->FindClass(env, "java/net/URL"); in nxt_java_initURLClassLoader()
71 nxt_java_URL_class = (*env)->NewGlobalRef(env, cls); in nxt_java_initURLClassLoader()
72 (*env)->DeleteLocalRef(env, cls); in nxt_java_initURLClassLoader()
75 nxt_java_URL_ctor = (*env)->GetMethodID(env, cls, in nxt_java_initURLClassLoader()
86 (*env)->DeleteGlobalRef(env, cls); in nxt_java_initURLClassLoader()
137 surl = (*env)->NewStringUTF(env, urls[i]); in nxt_java_newURLs()
160 jname = (*env)->NewStringUTF(env, name); in nxt_java_loadClass()
[all …]
H A Dnxt_jni_Thread.c23 cls = (*env)->FindClass(env, "java/lang/Thread"); in nxt_java_initThread()
29 nxt_java_Thread_class = (*env)->NewGlobalRef(env, cls); in nxt_java_initThread()
30 (*env)->DeleteLocalRef(env, cls); in nxt_java_initThread()
33 nxt_java_Thread_currentThread = (*env)->GetStaticMethodID(env, cls, in nxt_java_initThread()
40 nxt_java_Thread_getContextClassLoader = (*env)->GetMethodID(env, cls, in nxt_java_initThread()
48 nxt_java_Thread_setContextClassLoader = (*env)->GetMethodID(env, cls, in nxt_java_initThread()
60 (*env)->DeleteGlobalRef(env, cls); in nxt_java_initThread()
69 thread = (*env)->CallStaticObjectMethod(env, nxt_java_Thread_class, in nxt_java_setContextClassLoader()
76 (*env)->CallVoidMethod(env, thread, nxt_java_Thread_setContextClassLoader, in nxt_java_setContextClassLoader()
85 thread = (*env)->CallStaticObjectMethod(env, nxt_java_Thread_class, in nxt_java_getContextClassLoader()
[all …]
H A Dnxt_jni_Context.c39 nxt_java_Context_class = (*env)->NewGlobalRef(env, cls); in nxt_java_initContext()
40 (*env)->DeleteLocalRef(env, cls); in nxt_java_initContext()
50 nxt_java_Context_service = (*env)->GetMethodID(env, cls, "service", in nxt_java_initContext()
74 res = (*env)->RegisterNatives(env, nxt_java_Context_class, in nxt_java_initContext()
90 (*env)->DeleteGlobalRef(env, cls); in nxt_java_initContext()
100 webapp_str = (*env)->NewStringUTF(env, webapp); in nxt_java_startContext()
121 (*env)->CallVoidMethod(env, ctx, nxt_java_Context_stop); in nxt_java_stopContext()
134 msg_str = (*env)->GetStringUTFChars(env, msg, NULL); in nxt_java_Context_log()
141 (*env)->ReleaseStringUTFChars(env, msg, msg_str); in nxt_java_Context_log()
155 msg_str = (*env)->GetStringUTFChars(env, msg, NULL); in nxt_java_Context_trace()
[all …]
H A Dnxt_jni_Request.c97 (*env)->DeleteLocalRef(env, cls); in nxt_java_initRequest()
102 (*env)->DeleteGlobalRef(env, cls); in nxt_java_initRequest()
108 (*env)->DeleteGlobalRef(env, cls); in nxt_java_initRequest()
114 (*env)->DeleteGlobalRef(env, cls); in nxt_java_initRequest()
258 (*env)->DeleteGlobalRef(env, cls); in nxt_java_initRequest()
402 return (*env)->NewStringUTF(env, query); in nxt_java_Request_getQueryString()
424 return (*env)->NewStringUTF(env, target); in nxt_java_Request_getRequestURI()
713 (*env)->ReleaseStringUTFChars(env, msg, msg_str); in nxt_java_Request_log()
734 (*env)->ReleaseStringUTFChars(env, msg, msg_str); in nxt_java_Request_trace()
804 (*env)->DeleteGlobalRef(env, data->jresp); in nxt_java_Request_closeWs()
[all …]
H A Dnxt_jni_Response.c124 (*env)->DeleteLocalRef(env, cls); in nxt_java_initResponse()
129 (*env)->DeleteGlobalRef(env, cls); in nxt_java_initResponse()
244 (*env)->DeleteGlobalRef(env, cls); in nxt_java_initResponse()
269 name_len = (*env)->GetArrayLength(env, name); in nxt_java_Response_addHeader()
367 name_len = (*env)->GetArrayLength(env, name); in nxt_java_Response_addIntHeader()
439 name_len = (*env)->GetArrayLength(env, name); in nxt_java_Response_containsHeader()
480 name_len = (*env)->GetArrayLength(env, name); in nxt_java_Response_getHeader()
549 name_len = (*env)->GetArrayLength(env, name); in nxt_java_Response_getHeaders()
636 loc_len = (*env)->GetArrayLength(env, loc); in nxt_java_Response_sendRedirect()
1069 msg_len = (*env)->GetArrayLength(env, msg); in nxt_java_Response_log()
[all …]
H A Dnxt_jni_HeaderNamesEnumeration.c29 nxt_java_initHeaderNamesEnumeration(JNIEnv *env, jobject cl) in nxt_java_initHeaderNamesEnumeration() argument
39 nxt_java_HeaderNamesEnumeration_class = (*env)->NewGlobalRef(env, cls); in nxt_java_initHeaderNamesEnumeration()
40 (*env)->DeleteLocalRef(env, cls); in nxt_java_initHeaderNamesEnumeration()
43 nxt_java_HeaderNamesEnumeration_ctor = (*env)->GetMethodID(env, cls, in nxt_java_initHeaderNamesEnumeration()
46 (*env)->DeleteGlobalRef(env, cls); in nxt_java_initHeaderNamesEnumeration()
60 res = (*env)->RegisterNatives(env, nxt_java_HeaderNamesEnumeration_class, in nxt_java_initHeaderNamesEnumeration()
68 (*env)->DeleteGlobalRef(env, cls); in nxt_java_initHeaderNamesEnumeration()
77 nxt_java_newHeaderNamesEnumeration(JNIEnv *env, nxt_unit_field_t *f, in nxt_java_newHeaderNamesEnumeration() argument
80 return (*env)->NewObject(env, in nxt_java_newHeaderNamesEnumeration()
132 nxt_java_throw_NoSuchElementException(env, "pos >= size"); in nxt_java_HeaderNamesEnumeration_nextElement()
[all …]
H A Dnxt_jni_HeadersEnumeration.c30 nxt_java_initHeadersEnumeration(JNIEnv *env, jobject cl) in nxt_java_initHeadersEnumeration() argument
40 nxt_java_HeadersEnumeration_class = (*env)->NewGlobalRef(env, cls); in nxt_java_initHeadersEnumeration()
41 (*env)->DeleteLocalRef(env, cls); in nxt_java_initHeadersEnumeration()
44 nxt_java_HeadersEnumeration_ctor = (*env)->GetMethodID(env, cls, in nxt_java_initHeadersEnumeration()
47 (*env)->DeleteGlobalRef(env, cls); in nxt_java_initHeadersEnumeration()
61 res = (*env)->RegisterNatives(env, nxt_java_HeadersEnumeration_class, in nxt_java_initHeadersEnumeration()
68 (*env)->DeleteGlobalRef(env, cls); in nxt_java_initHeadersEnumeration()
77 nxt_java_newHeadersEnumeration(JNIEnv *env, nxt_unit_field_t *f, in nxt_java_newHeadersEnumeration() argument
80 return (*env)->NewObject(env, in nxt_java_newHeadersEnumeration()
131 nxt_java_throw_IOException(env, "pos >= size"); in nxt_java_HeadersEnumeration_nextElement()
[all …]
H A Dnxt_jni_OutputStream.c32 nxt_java_initOutputStream(JNIEnv *env, jobject cl) in nxt_java_initOutputStream() argument
42 nxt_java_OutputStream_class = (*env)->NewGlobalRef(env, cls); in nxt_java_initOutputStream()
43 (*env)->DeleteLocalRef(env, cls); in nxt_java_initOutputStream()
65 res = (*env)->RegisterNatives(env, nxt_java_OutputStream_class, in nxt_java_initOutputStream()
72 (*env)->DeleteGlobalRef(env, cls); in nxt_java_initOutputStream()
91 buf = nxt_java_OutputStream_req_buf(env, req); in nxt_java_OutputStream_writeByte()
99 nxt_java_OutputStream_flush_buf(env, req); in nxt_java_OutputStream_writeByte()
188 ptr = (*env)->GetPrimitiveArrayCritical(env, b, NULL); in nxt_java_OutputStream_write()
191 buf = nxt_java_OutputStream_req_buf(env, req); in nxt_java_OutputStream_write()
213 (*env)->ReleasePrimitiveArrayCritical(env, b, ptr, 0); in nxt_java_OutputStream_write()
[all …]
H A Dnxt_jni_InputStream.c35 nxt_java_initInputStream(JNIEnv *env, jobject cl) in nxt_java_initInputStream() argument
40 cls = nxt_java_loadClass(env, cl, "nginx.unit.InputStream"); in nxt_java_initInputStream()
45 nxt_java_InputStream_class = (*env)->NewGlobalRef(env, cls); in nxt_java_initInputStream()
46 (*env)->DeleteLocalRef(env, cls); in nxt_java_initInputStream()
74 res = (*env)->RegisterNatives(env, nxt_java_InputStream_class, in nxt_java_initInputStream()
81 (*env)->DeleteGlobalRef(env, cls); in nxt_java_initInputStream()
90 nxt_java_InputStream_readLine(JNIEnv *env, jclass cls, in nxt_java_InputStream_readLine() argument
99 data = (*env)->GetPrimitiveArrayCritical(env, out, NULL); in nxt_java_InputStream_readLine()
109 (*env)->ReleasePrimitiveArrayCritical(env, out, data, 0); in nxt_java_InputStream_readLine()
151 data = (*env)->GetPrimitiveArrayCritical(env, b, NULL); in nxt_java_InputStream_read()
[all …]
H A Dnxt_jni_URLClassLoader.h13 int nxt_java_initURLClassLoader(JNIEnv *env);
15 jobject nxt_java_newURLClassLoader(JNIEnv *env, int url_count, char **urls);
17 jobject nxt_java_newURLClassLoader_parent(JNIEnv *env, int url_count,
20 jobjectArray nxt_java_newURLs(JNIEnv *env, int url_count, char **urls);
22 jclass nxt_java_loadClass(JNIEnv *env, jobject cl, const char *name);
24 void nxt_java_addURL(JNIEnv *env, jobject cl, const char *url);
H A Dnxt_jni.h14 int nxt_java_jni_init(JNIEnv *env);
16 void nxt_java_throw_NoSuchElementException(JNIEnv *env, const char *msg);
18 void nxt_java_throw_IOException(JNIEnv *env, const char *msg);
20 void nxt_java_throw_IllegalStateException(JNIEnv *env, const char *msg);
27 jstring nxt_java_newString(JNIEnv *env, char *str, uint32_t len);
H A Dnxt_jni_Context.h13 int nxt_java_initContext(JNIEnv *env, jobject cl);
15 jobject nxt_java_startContext(JNIEnv *env, const char *webapp,
18 void nxt_java_service(JNIEnv *env, jobject ctx, jobject jreq, jobject jresp);
20 void nxt_java_stopContext(JNIEnv *env, jobject ctx);
H A Dnxt_jni_Request.h14 int nxt_java_initRequest(JNIEnv *env, jobject cl);
16 jobject nxt_java_newRequest(JNIEnv *env, jobject ctx, nxt_unit_request_info_t *req);
18 void nxt_java_Request_websocket(JNIEnv *env, jobject jreq, jobject jbuf,
21 void nxt_java_Request_close(JNIEnv *env, jobject jreq);
H A Dnxt_jni_Thread.h13 int nxt_java_initThread(JNIEnv *env);
15 void nxt_java_setContextClassLoader(JNIEnv *env, jobject cl);
17 jobject nxt_java_getContextClassLoader(JNIEnv *env);
/unit/test/ruby/variables/
H A Dconfig.ru1 app = Proc.new do |env|
2 body = env['rack.input'].read
3 version = env['rack.version'].join('')
6 'Content-Type' => env['CONTENT_TYPE'],
8 'Request-Method' => env['REQUEST_METHOD'],
9 'Request-Uri' => env['REQUEST_URI'],
10 'Http-Host' => env['HTTP_HOST'],
11 'Script-Name' => env['SCRIPT_NAME'],
12 'Server-Protocol' => env['SERVER_PROTOCOL'],
13 'Server-Software' => env['SERVER_SOFTWARE'],
[all …]
/unit/src/
H A Dnxt_java.c420 if ((*env)->ExceptionCheck(env)) { in nxt_java_start()
422 (*env)->ExceptionDescribe(env); in nxt_java_start()
453 if ((*env)->ExceptionCheck(env)) { in nxt_java_start()
454 (*env)->ExceptionDescribe(env); in nxt_java_start()
467 if ((*env)->ExceptionCheck(env)) { in nxt_java_start()
468 (*env)->ExceptionDescribe(env); in nxt_java_start()
525 if ((*env)->ExceptionCheck(env)) { in nxt_java_request_handler()
526 (*env)->ExceptionDescribe(env); in nxt_java_request_handler()
527 (*env)->ExceptionClear(env); in nxt_java_request_handler()
552 (*env)->DeleteLocalRef(env, jresp); in nxt_java_request_handler()
[all …]
H A Dnxt_process_title.c105 env = (u_char **) *orig_envp; in nxt_process_arguments()
108 for (i = 0; env[i] != NULL; i++) { in nxt_process_arguments()
111 if (env[i] == end) { in nxt_process_arguments()
115 end = env[i] + size; in nxt_process_arguments()
150 env = nxt_malloc(environ_size); in nxt_process_arguments()
151 if (env == NULL) { in nxt_process_arguments()
163 *orig_envp = (char **) env; in nxt_process_arguments()
167 if (env[i] != end) { in nxt_process_arguments()
173 nxt_memcpy(p, env[i], size); in nxt_process_arguments()
175 end = env[i] + size; in nxt_process_arguments()
[all …]
/unit/src/nodejs/unit-http/
H A Dunit.h14 static napi_value init(napi_env env, napi_value exports);
17 Unit(napi_env env, napi_value jsthis);
20 static napi_value create(napi_env env, napi_callback_info info);
21 static void destroy(napi_env env, void *nativeObject, void *finalize_hint);
27 static napi_value create_server(napi_env env, napi_callback_info info);
28 static napi_value listen(napi_env env, napi_callback_info info);
29 static napi_value _read(napi_env env, napi_callback_info info);
64 static napi_value request_read(napi_env env, napi_callback_info info);
66 static napi_value response_send_headers(napi_env env,
70 static napi_value response_end(napi_env env, napi_callback_info info);
[all …]
/unit/test/ruby/errors_write/
H A Dconfig.ru1 app = Proc.new do |env|
2 env['rack.errors'].write('Error in application')
3 env['rack.errors'].flush
4 env['rack.errors'].close
/unit/test/ruby/input_rewind/
H A Dconfig.ru1 app = Proc.new do |env|
2 env['rack.input'].read
3 env['rack.input'].rewind
4 body = env['rack.input'].read
/unit/test/ruby/input_read_parts/
H A Dconfig.ru1 app = Proc.new do |env|
2 body = env['rack.input'].read(4)
3 body += env['rack.input'].read(4)
4 body += env['rack.input'].read(1)
/unit/test/python/forwarded_header/
H A Dwsgi.py1 def application(env, start_response): argument
6 ('Remote-Addr', env.get('REMOTE_ADDR')),
7 ('Url-Scheme', env.get('wsgi.url_scheme')),
/unit/test/python/host/
H A Dwsgi.py1 def application(env, start_response): argument
6 ('X-Server-Name', env.get('SERVER_NAME')),
7 ('X-Http-Host', str(env.get('HTTP_HOST'))),
/unit/test/unit/applications/lang/
H A Dgo.py27 env = os.environ.copy()
28 env['GOPATH'] = option.current_dir + '/build/go'
29 env['GOCACHE'] = cache_dir
67 print("\n$ GOPATH=" + env['GOPATH'] + " " + " ".join(args))
70 process = subprocess.run(args, env=env, cwd=temp_dir)

1234