Browse Source

Remove the sdmc module

The SD card is automatically mounted by libctru on startup, so this
isn't needed anymore.
pull/14/head
AzureMarker 3 years ago
parent
commit
4b95068fac
No known key found for this signature in database
GPG Key ID: 47A133F3BF9D03D3
  1. 2
      ctru-rs/src/lib.rs
  2. 20
      ctru-rs/src/sdmc.rs

2
ctru-rs/src/lib.rs

@ -33,7 +33,6 @@ pub mod applets;
pub mod console; pub mod console;
pub mod error; pub mod error;
pub mod gfx; pub mod gfx;
pub mod sdmc;
pub mod services; pub mod services;
pub mod srv; pub mod srv;
pub mod thread; pub mod thread;
@ -57,5 +56,4 @@ pub mod romfs {
pub use crate::error::{Error, Result}; pub use crate::error::{Error, Result};
pub use crate::gfx::Gfx; pub use crate::gfx::Gfx;
pub use crate::sdmc::Sdmc;
pub use crate::srv::Srv; pub use crate::srv::Srv;

20
ctru-rs/src/sdmc.rs

@ -1,20 +0,0 @@
pub struct Sdmc(());
impl Sdmc {
pub fn init() -> crate::Result<Sdmc> {
unsafe {
let r = ctru_sys::archiveMountSdmc();
if r < 0 {
Err(r.into())
} else {
Ok(Sdmc(()))
}
}
}
}
impl Drop for Sdmc {
fn drop(&mut self) {
unsafe { ctru_sys::archiveUnmountAll() };
}
}
Loading…
Cancel
Save