Skip to content

Commit 1b4ffb2

Browse files
committed
refactor: cargo make format
1 parent afcaddc commit 1b4ffb2

File tree

2 files changed

+7
-4
lines changed

2 files changed

+7
-4
lines changed

rust-sgx-workspace/projects/ntc-tee-server/enclave/Cargo.toml

Lines changed: 4 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -16,6 +16,8 @@ serde_json = { version = "1.0", default-features = false, features = ["alloc"] }
1616

1717
[target.'cfg(not(target_env = "sgx"))'.dependencies] # You can remove what you don't need, except types and tstd
1818
sgx_types = { git = "https://github.com/apache/incubator-teaclave-sgx-sdk", rev = "e8a9fc22939befa27ff67f5509b2c2dfe8499945" }
19-
sgx_tstd = { git = "https://github.com/apache/incubator-teaclave-sgx-sdk", features = ["backtrace"], rev = "e8a9fc22939befa27ff67f5509b2c2dfe8499945" }
19+
sgx_tstd = { git = "https://github.com/apache/incubator-teaclave-sgx-sdk", features = [
20+
"backtrace",
21+
], rev = "e8a9fc22939befa27ff67f5509b2c2dfe8499945" }
2022

21-
[patch.'https://github.com/apache/teaclave-sgx-sdk.git']
23+
[patch.'https://github.com/apache/teaclave-sgx-sdk.git']

rust-sgx-workspace/projects/ntc-tee-server/enclave/src/lib.rs

Lines changed: 3 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -8,8 +8,9 @@ extern crate serde_json;
88

99
use std::io::{self, Write};
1010
use std::slice;
11-
use std::vec::Vec;
1211
use std::string::String;
12+
use std::vec::Vec;
13+
1314
use serde_json::Value;
1415
use sgx_types::sgx_status_t;
1516

@@ -100,7 +101,7 @@ pub unsafe extern "C" fn append_data(some_string: *const u8, some_len: usize) ->
100101

101102
let pool_1 = serde_json::from_str::<Value>(&json_pool_1).expect("JSON was not well-formatted");
102103
let pool_2 = serde_json::from_str::<Value>(&json_pool_2).expect("JSON was not well-formatted");
103-
104+
104105
let pool_1_length = pool_1["pool"].as_array().unwrap().len();
105106
let pool_2_length = pool_1["pool"].as_array().unwrap().len();
106107

0 commit comments

Comments
 (0)