mirror of
https://github.com/ZeroTier/ZeroTierOne
synced 2025-07-07 13:31:45 -07:00
oidc stuff coming across the wire properly and generating a working login URL
This commit is contained in:
parent
eaccce743f
commit
663a09b38d
6 changed files with 26 additions and 15 deletions
|
@ -156,10 +156,14 @@ pub extern "C" fn zeroidc_auth_info_delete(ptr: *mut AuthInfo) {
|
|||
|
||||
#[no_mangle]
|
||||
pub extern "C" fn zeroidc_get_auth_url(ptr: *mut AuthInfo) -> *const c_char {
|
||||
if ptr.is_null() {
|
||||
println!("passed a null object");
|
||||
return std::ptr::null_mut();
|
||||
}
|
||||
let ai = unsafe {
|
||||
assert!(!ptr.is_null());
|
||||
&mut *ptr
|
||||
};
|
||||
|
||||
let s = CString::new(ai.url.to_string()).unwrap();
|
||||
return s.as_ptr();
|
||||
return s.into_raw();
|
||||
}
|
||||
|
|
Loading…
Add table
Add a link
Reference in a new issue