about summary refs log tree commit diff
path: root/library/std/src/sys/sgx
diff options
context:
space:
mode:
authorChristiaan Dirkx <christiaan@dirkx.email>2021-04-11 23:48:10 +0200
committerChristiaan Dirkx <christiaan@dirkx.email>2021-04-22 18:00:12 +0200
commit11445c10ab630a6ad8526f3fc5bcea1badad2964 (patch)
treef16c4f9a517ad55c4f36b79bd9194a9832f3478f /library/std/src/sys/sgx
parentcf470197addb37146eb2e0d16f14dd14293d91f0 (diff)
Move most init to `sys::init`
Diffstat (limited to 'library/std/src/sys/sgx')
-rw-r--r--library/std/src/sys/sgx/mod.rs7
-rw-r--r--library/std/src/sys/sgx/stack_overflow.rs2
2 files changed, 5 insertions, 4 deletions
diff --git a/library/std/src/sys/sgx/mod.rs b/library/std/src/sys/sgx/mod.rs
index 9681336631f..25250d060d0 100644
--- a/library/std/src/sys/sgx/mod.rs
+++ b/library/std/src/sys/sgx/mod.rs
@@ -32,7 +32,6 @@ pub mod pipe;
 #[path = "../unsupported/process.rs"]
 pub mod process;
 pub mod rwlock;
-pub mod stack_overflow;
 pub mod stdio;
 pub mod thread;
 pub mod thread_local_key;
@@ -41,7 +40,11 @@ pub mod time;
 pub use crate::sys_common::os_str_bytes as os_str;
 
 // SAFETY: must be called only once during runtime initialization.
-pub unsafe fn init() {}
+pub unsafe fn init(argc: isize, argv: *const *const u8) {
+    unsafe {
+        args::init(argc, argv);
+    }
+}
 
 // SAFETY: must be called only once during runtime cleanup.
 pub unsafe fn cleanup() {}
diff --git a/library/std/src/sys/sgx/stack_overflow.rs b/library/std/src/sys/sgx/stack_overflow.rs
deleted file mode 100644
index 1ca5810e61b..00000000000
--- a/library/std/src/sys/sgx/stack_overflow.rs
+++ /dev/null
@@ -1,2 +0,0 @@
-#[cfg_attr(test, allow(dead_code))]
-pub unsafe fn init() {}