Skip to content

Commit f4d4d69

Browse files
J-HeinemannJoshua Heinemannwenyongh
authored
wasm_export.h Function Description & SGX SDK Include path (#279)
* Missing SGX SDK Include fixed * Update shared_platform.cmake * CMakeFile remove stdlib from untrusted part * Added two times in function description zero as possible return value * Update shared_platform.cmake Co-authored-by: Joshua Heinemann <[email protected]> Co-authored-by: wenyongh <[email protected]>
1 parent 10980a1 commit f4d4d69

File tree

2 files changed

+7
-5
lines changed

2 files changed

+7
-5
lines changed

core/iwasm/include/wasm_export.h

Lines changed: 2 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -319,7 +319,7 @@ wasm_runtime_lookup_wasi_start_function(wasm_module_inst_t module_inst);
319319
* @param name the name of the function
320320
* @param signature the signature of the function, ignored currently
321321
*
322-
* @return the function instance found
322+
* @return the function instance found. Otherwise NULL will be returned.
323323
*/
324324
wasm_function_inst_t
325325
wasm_runtime_lookup_function(wasm_module_inst_t const module_inst,
@@ -331,7 +331,7 @@ wasm_runtime_lookup_function(wasm_module_inst_t const module_inst,
331331
* @param module_inst the module instance
332332
* @param stack_size the stack size to execute a WASM function
333333
*
334-
* @return the execution environment
334+
* @return the execution environment. In case of invalid stack size, NULL will be returned.
335335
*/
336336
wasm_exec_env_t
337337
wasm_runtime_create_exec_env(wasm_module_inst_t module_inst,

core/shared/platform/linux-sgx/shared_platform.cmake

Lines changed: 5 additions & 3 deletions
Original file line numberDiff line numberDiff line change
@@ -14,9 +14,11 @@ else()
1414
set (SGX_SDK_DIR $ENV{SGX_SDK})
1515
endif()
1616

17-
include_directories (${SGX_SDK_DIR}/include
18-
${SGX_SDK_DIR}/include/tlibc
19-
${SGX_SDK_DIR}/include/libcxx)
17+
include_directories (${SGX_SDK_DIR}/include)
18+
if (NOT BUILD_UNTRUST_PART EQUAL 1)
19+
include_directories (${SGX_SDK_DIR}/include/tlibc
20+
${SGX_SDK_DIR}/include/libcxx)
21+
endif ()
2022

2123
file (GLOB_RECURSE source_all ${PLATFORM_SHARED_DIR}/*.c)
2224

0 commit comments

Comments
 (0)