mirror of
https://github.com/saymrwulf/xous-core.git
synced 2026-11-15 08:30:02 +00:00
xous-rs: add a function call to get current server address
This function will assist us in creating calls to spawn processes and threads. Signed-off-by: Sean Cross <sean@xobs.io>
This commit is contained in:
parent
fb32aab691
commit
62cff0b9c7
1 changed files with 7 additions and 1 deletions
|
|
@ -20,6 +20,13 @@ pub fn set_xous_address(new_address: SocketAddr) {
|
|||
});
|
||||
}
|
||||
|
||||
/// Set the network address for this particular thread.
|
||||
pub fn xous_address() -> SocketAddr {
|
||||
NETWORK_CONNECT_ADDRESS.with(|nca| {
|
||||
*nca.borrow()
|
||||
})
|
||||
}
|
||||
|
||||
#[allow(clippy::too_many_arguments)]
|
||||
#[no_mangle]
|
||||
pub fn _xous_syscall(
|
||||
|
|
@ -41,7 +48,6 @@ pub fn _xous_syscall(
|
|||
*xsc.borrow_mut() = Some(conn);
|
||||
});
|
||||
}
|
||||
// let xsc: &mut TcpStream = (*xous_server_connection).as_mut().unwrap();
|
||||
_xous_syscall_to(
|
||||
nr,
|
||||
a1,
|
||||
|
|
|
|||
Loading…
Reference in a new issue