mirror of
https://git.proxmox.com/git/proxmox-backup
synced 2025-04-28 12:50:53 +00:00
fix typos in variables and function names
Variables, methods and functions in public API were not changed. Signed-off-by: Maximiliano Sandoval <m.sandoval@proxmox.com>
This commit is contained in:
parent
19dfc86198
commit
42e5be0f87
@ -52,7 +52,7 @@ struct AddressAssignmentPage {
|
||||
storage_element_count: u16,
|
||||
first_import_export_element_address: u16,
|
||||
import_export_element_count: u16,
|
||||
first_tranfer_element_address: u16,
|
||||
first_transfer_element_address: u16,
|
||||
transfer_element_count: u16,
|
||||
reserved22: u8,
|
||||
reserved23: u8,
|
||||
|
@ -76,7 +76,7 @@ struct SspSetDataEncryptionPage {
|
||||
control_byte_5: u8,
|
||||
encryption_mode: u8,
|
||||
decryption_mode: u8,
|
||||
algorythm_index: u8,
|
||||
algorithm_index: u8,
|
||||
key_format: u8,
|
||||
reserved: [u8; 8],
|
||||
key_len: u16,
|
||||
@ -86,7 +86,7 @@ struct SspSetDataEncryptionPage {
|
||||
#[allow(clippy::vec_init_then_push)]
|
||||
fn sg_spout_set_encryption<F: AsRawFd>(
|
||||
file: &mut F,
|
||||
algorythm_index: u8,
|
||||
algorithm_index: u8,
|
||||
key: Option<[u8; 32]>,
|
||||
) -> Result<(), Error> {
|
||||
let mut sg_raw = SgRaw::new(file, 0)?;
|
||||
@ -106,7 +106,7 @@ fn sg_spout_set_encryption<F: AsRawFd>(
|
||||
control_byte_5: (chok << 2),
|
||||
encryption_mode: if key.is_some() { 2 } else { 0 },
|
||||
decryption_mode: if key.is_some() { 3 } else { 0 }, // mixed mode
|
||||
algorythm_index,
|
||||
algorithm_index,
|
||||
key_format: 0,
|
||||
reserved: [0u8; 8],
|
||||
key_len: if let Some(ref key) = key {
|
||||
@ -221,7 +221,7 @@ struct SspDataEncryptionCapabilityPage {
|
||||
#[derive(Endian)]
|
||||
#[repr(C, packed)]
|
||||
struct SspDataEncryptionAlgorithmDescriptor {
|
||||
algorythm_index: u8,
|
||||
algorithm_index: u8,
|
||||
reserved1: u8,
|
||||
descriptor_len: u16,
|
||||
control_byte_4: u8,
|
||||
@ -259,7 +259,7 @@ fn decode_spin_data_encryption_caps(data: &[u8]) -> Result<u8, Error> {
|
||||
continue; // can't decrypt in hardware
|
||||
}
|
||||
if desc.algorithm_code == 0x00010014 && desc.key_size == 32 {
|
||||
aes_gcm_index = Some(desc.algorythm_index);
|
||||
aes_gcm_index = Some(desc.algorithm_index);
|
||||
break;
|
||||
}
|
||||
}
|
||||
@ -280,7 +280,7 @@ struct SspDataEncryptionStatusPage {
|
||||
scope_byte: u8,
|
||||
encryption_mode: u8,
|
||||
decryption_mode: u8,
|
||||
algorythm_index: u8,
|
||||
algorithm_index: u8,
|
||||
key_instance_counter: u32,
|
||||
control_byte: u8,
|
||||
key_format: u8,
|
||||
|
@ -9,7 +9,7 @@ use crate::sgutils2::SgRaw;
|
||||
|
||||
#[repr(C, packed)]
|
||||
#[derive(Endian)]
|
||||
struct DesnityDescriptorBlock {
|
||||
struct DensityDescriptorBlock {
|
||||
primary_density_code: u8,
|
||||
secondary_density_code: u8,
|
||||
flags2: u8,
|
||||
@ -58,7 +58,7 @@ pub fn report_density<F: AsRawFd>(file: &mut F) -> Result<u8, Error> {
|
||||
if reader.is_empty() {
|
||||
break;
|
||||
}
|
||||
let block: DesnityDescriptorBlock = unsafe { reader.read_be_value()? };
|
||||
let block: DensityDescriptorBlock = unsafe { reader.read_be_value()? };
|
||||
if block.primary_density_code > max_density {
|
||||
max_density = block.primary_density_code;
|
||||
}
|
||||
|
@ -51,7 +51,7 @@ fn create_restore_log_dir() -> Result<String, Error> {
|
||||
Ok(logpath)
|
||||
}
|
||||
|
||||
fn validate_img_existance(debug: bool) -> Result<(), Error> {
|
||||
fn validate_img_existence(debug: bool) -> Result<(), Error> {
|
||||
let kernel = PathBuf::from(pbs_buildcfg::PROXMOX_BACKUP_KERNEL_FN);
|
||||
let initramfs = PathBuf::from(if debug {
|
||||
pbs_buildcfg::PROXMOX_BACKUP_INITRAMFS_DBG_FN
|
||||
@ -213,7 +213,7 @@ pub async fn start_vm(
|
||||
|
||||
let debug = debug_mode();
|
||||
|
||||
validate_img_existance(debug)?;
|
||||
validate_img_existence(debug)?;
|
||||
|
||||
let pid;
|
||||
let (mut pid_file, pid_path) =
|
||||
|
@ -787,7 +787,7 @@ impl FileEntryPrinter {
|
||||
Ok(())
|
||||
}
|
||||
|
||||
fn write_column_seperator(&mut self) -> Result<(), Error> {
|
||||
fn write_column_separator(&mut self) -> Result<(), Error> {
|
||||
write!(self.stream, " ")?;
|
||||
Ok(())
|
||||
}
|
||||
@ -800,25 +800,25 @@ impl FileEntryPrinter {
|
||||
operation: FileOperation,
|
||||
) -> Result<(), Error> {
|
||||
self.write_operation(operation)?;
|
||||
self.write_column_seperator()?;
|
||||
self.write_column_separator()?;
|
||||
|
||||
self.write_entry_type(entry, changed.entry_type)?;
|
||||
self.write_column_seperator()?;
|
||||
self.write_column_separator()?;
|
||||
|
||||
self.write_uid(entry, changed.uid)?;
|
||||
self.write_column_seperator()?;
|
||||
self.write_column_separator()?;
|
||||
|
||||
self.write_gid(entry, changed.gid)?;
|
||||
self.write_column_seperator()?;
|
||||
self.write_column_separator()?;
|
||||
|
||||
self.write_mode(entry, changed.mode)?;
|
||||
self.write_column_seperator()?;
|
||||
self.write_column_separator()?;
|
||||
|
||||
self.write_filesize(entry, changed.size)?;
|
||||
self.write_column_seperator()?;
|
||||
self.write_column_separator()?;
|
||||
|
||||
self.write_mtime(entry, changed.mtime)?;
|
||||
self.write_column_seperator()?;
|
||||
self.write_column_separator()?;
|
||||
|
||||
self.write_file_name(entry, changed.content)?;
|
||||
writeln!(self.stream)?;
|
||||
|
@ -92,7 +92,7 @@ fn network_match_len(networks: &[IpInet], ip: &IpAddr) -> Option<u8> {
|
||||
match_len
|
||||
}
|
||||
|
||||
fn cannonical_ip(ip: IpAddr) -> IpAddr {
|
||||
fn canonical_ip(ip: IpAddr) -> IpAddr {
|
||||
// TODO: use std::net::IpAddr::to_cananical once stable
|
||||
match ip {
|
||||
IpAddr::V4(addr) => IpAddr::V4(addr),
|
||||
@ -332,7 +332,7 @@ impl TrafficControlCache {
|
||||
peer: SocketAddr,
|
||||
now: i64,
|
||||
) -> (&str, Option<SharedRateLimit>, Option<SharedRateLimit>) {
|
||||
let peer_ip = cannonical_ip(peer.ip());
|
||||
let peer_ip = canonical_ip(peer.ip());
|
||||
|
||||
log::debug!("lookup_rate_limiter: {:?}", peer_ip);
|
||||
|
||||
|
@ -272,8 +272,8 @@ Ext.define('PBS.view.main.NavigationTree', {
|
||||
if (maintenance) {
|
||||
const [type, message] = PBS.Utils.parseMaintenanceMode(maintenance);
|
||||
qtip = `${type}${message ? ': ' + message : ''}`;
|
||||
let mainenanceTypeCls = type === 'delete' ? 'destroying' : 'maintenance';
|
||||
iconCls = `fa fa-database pmx-tree-icon-custom ${mainenanceTypeCls}`;
|
||||
let maintenanceTypeCls = type === 'delete' ? 'destroying' : 'maintenance';
|
||||
iconCls = `fa fa-database pmx-tree-icon-custom ${maintenanceTypeCls}`;
|
||||
}
|
||||
|
||||
if (getChildTextAt(j).localeCompare(name) !== 0) {
|
||||
|
@ -53,8 +53,8 @@ Ext.define('PBS.config.PruneAndGC', {
|
||||
}
|
||||
},
|
||||
|
||||
cbindData: function(initalConfig) {
|
||||
cbindData: function(initialConfig) {
|
||||
let me = this;
|
||||
me.datastore = initalConfig.datastore ? initalConfig.datastore : undefined;
|
||||
me.datastore = initialConfig.datastore ? initialConfig.datastore : undefined;
|
||||
},
|
||||
});
|
||||
|
@ -9,7 +9,7 @@ Ext.define('PBS.DataStoreNotes', {
|
||||
scrollable: true,
|
||||
animCollapse: false,
|
||||
|
||||
cbindData: function(initalConfig) {
|
||||
cbindData: function(initialConfig) {
|
||||
let me = this;
|
||||
me.url = `/api2/extjs/config/datastore/${me.datastore}`;
|
||||
return { };
|
||||
|
@ -3,7 +3,7 @@ Ext.define('PBS.DataStorePanel', {
|
||||
alias: 'widget.pbsDataStorePanel',
|
||||
mixins: ['Proxmox.Mixin.CBind'],
|
||||
|
||||
cbindData: function(initalConfig) {
|
||||
cbindData: function(initialConfig) {
|
||||
let me = this;
|
||||
return {
|
||||
aclPath: `/datastore/${me.datastore}`,
|
||||
|
@ -168,7 +168,7 @@ Ext.define('PBS.panel.NotificationRulesEditPanel', {
|
||||
onGetValues: function(values) {
|
||||
let me = this;
|
||||
|
||||
let deleteArrayIfEmtpy = (field) => {
|
||||
let deleteArrayIfEmpty = (field) => {
|
||||
if (Ext.isArray(values[field])) {
|
||||
if (values[field].length === 0) {
|
||||
delete values[field];
|
||||
@ -178,9 +178,9 @@ Ext.define('PBS.panel.NotificationRulesEditPanel', {
|
||||
}
|
||||
}
|
||||
};
|
||||
deleteArrayIfEmtpy('match-field');
|
||||
deleteArrayIfEmtpy('match-severity');
|
||||
deleteArrayIfEmtpy('match-calendar');
|
||||
deleteArrayIfEmpty('match-field');
|
||||
deleteArrayIfEmpty('match-severity');
|
||||
deleteArrayIfEmpty('match-calendar');
|
||||
|
||||
return values;
|
||||
},
|
||||
|
Loading…
Reference in New Issue
Block a user