Skip to content

Commit eeef2d1

Browse files
committed
update 1
1 parent 38a308d commit eeef2d1

File tree

3 files changed

+6
-6
lines changed

3 files changed

+6
-6
lines changed

proxy_wasm_api.h

+3-3
Original file line numberDiff line numberDiff line change
@@ -723,9 +723,9 @@ inline WasmResult getSharedData(std::string_view key, WasmDataPtr *value, uint32
723723
return WasmResult::Ok;
724724
}
725725

726-
// inline WasmResult setSharedData(std::string_view key, std::string_view value, uint32_t cas = 0) {
727-
// return proxy_set_shared_data(key.data(), key.size(), value.data(), value.size(), cas);
728-
// }
726+
inline WasmResult setSharedData(std::string_view key, std::string_view value, uint32_t cas = 0) {
727+
return proxy_set_shared_data(key.data(), key.size(), value.data(), value.size(), cas);
728+
}
729729

730730
inline WasmResult removeSharedData(std::string_view key, uint32_t cas = 0) {
731731
return proxy_remove_shared_data(key.data(), key.size(), cas);

proxy_wasm_externs.h

+2-2
Original file line numberDiff line numberDiff line change
@@ -72,8 +72,8 @@ extern "C" WasmResult proxy_get_shared_data(const char *key_ptr, size_t key_size
7272
// If cas != 0 and cas != the current cas for 'key' return false, otherwise set
7373
// the value and return true.
7474
// Returns: Ok, CasMismatch
75-
// extern "C" WasmResult proxy_set_shared_data(const char *key_ptr, size_t key_size,
76-
// const char *value_ptr, size_t value_size, uint32_t cas);
75+
extern "C" WasmResult proxy_set_shared_data(const char *key_ptr, size_t key_size,
76+
const char *value_ptr, size_t value_size, uint32_t cas);
7777

7878
extern "C" WasmResult proxy_remove_shared_data(const char *key_ptr, size_t key_size, uint32_t cas);
7979

proxy_wasm_intrinsics.js

+1-1
Original file line numberDiff line numberDiff line change
@@ -33,7 +33,7 @@ mergeInto(LibraryManager.library, {
3333
proxy_set_header_map_pairs: function() {},
3434
proxy_get_header_map_size: function() {},
3535
proxy_get_shared_data: function() {},
36-
// proxy_set_shared_data: function() {},
36+
proxy_set_shared_data: function() {},
3737
proxy_remove_shared_data: function() {},
3838
proxy_register_shared_queue: function() {},
3939
proxy_resolve_shared_queue: function() {},

0 commit comments

Comments
 (0)