mirror of
https://github.com/saymrwulf/xous-core.git
synced 2026-11-18 08:52:45 +00:00
fix another errant mut that wasn't needed in pddb
This commit is contained in:
parent
3b1629744c
commit
2eee81b218
3 changed files with 4 additions and 4 deletions
|
|
@ -62,7 +62,7 @@ pub(crate) fn connection_manager(sid: xous::SID, activity_interval: Arc<AtomicU3
|
||||||
let xns = xous_names::XousNames::new().unwrap();
|
let xns = xous_names::XousNames::new().unwrap();
|
||||||
let mut com = com::Com::new(&xns).unwrap();
|
let mut com = com::Com::new(&xns).unwrap();
|
||||||
let netmgr = net::NetManager::new();
|
let netmgr = net::NetManager::new();
|
||||||
let mut pddb = pddb::Pddb::new();
|
let pddb = pddb::Pddb::new();
|
||||||
let self_cid = xous::connect(sid).unwrap();
|
let self_cid = xous::connect(sid).unwrap();
|
||||||
// give the system some time to boot before trying to run a check on the EC minimum version, as it is in reset on boot
|
// give the system some time to boot before trying to run a check on the EC minimum version, as it is in reset on boot
|
||||||
tt.sleep_ms(POLL_INTERVAL_MS).unwrap();
|
tt.sleep_ms(POLL_INTERVAL_MS).unwrap();
|
||||||
|
|
|
||||||
|
|
@ -495,7 +495,7 @@ impl Pddb {
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
|
|
||||||
pub fn list_keys(&mut self, dict_name: &str, basis_name: Option<&str>) -> Result<Vec::<String>> {
|
pub fn list_keys(&self, dict_name: &str, basis_name: Option<&str>) -> Result<Vec::<String>> {
|
||||||
if dict_name.len() > (DICT_NAME_LEN - 1) {
|
if dict_name.len() > (DICT_NAME_LEN - 1) {
|
||||||
return Err(Error::new(ErrorKind::InvalidInput, "dictionary name too long"));
|
return Err(Error::new(ErrorKind::InvalidInput, "dictionary name too long"));
|
||||||
}
|
}
|
||||||
|
|
@ -557,7 +557,7 @@ impl Pddb {
|
||||||
}
|
}
|
||||||
|
|
||||||
|
|
||||||
pub fn list_dict(&mut self, basis_name: Option<&str>) -> Result<Vec::<String>> {
|
pub fn list_dict(&self, basis_name: Option<&str>) -> Result<Vec::<String>> {
|
||||||
let bname = if let Some(bname) = basis_name {
|
let bname = if let Some(bname) = basis_name {
|
||||||
if bname.len() > BASIS_NAME_LEN - 1 {
|
if bname.len() > BASIS_NAME_LEN - 1 {
|
||||||
return Err(Error::new(ErrorKind::InvalidInput, "basis name too long"));
|
return Err(Error::new(ErrorKind::InvalidInput, "basis name too long"));
|
||||||
|
|
|
||||||
|
|
@ -121,7 +121,7 @@ impl<'a> ShellCmdApi<'a> for Wlan {
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
"known" => {
|
"known" => {
|
||||||
let mut pddb = pddb::Pddb::new();
|
let pddb = pddb::Pddb::new();
|
||||||
match pddb.list_keys(net::AP_DICT_NAME, None) {
|
match pddb.list_keys(net::AP_DICT_NAME, None) {
|
||||||
Ok(list) => {
|
Ok(list) => {
|
||||||
write!(ret, "Saved network configs:\n").unwrap();
|
write!(ret, "Saved network configs:\n").unwrap();
|
||||||
|
|
|
||||||
Loading…
Reference in a new issue