]> git.proxmox.com Git - proxmox-backup.git/commitdiff
allow(clippy::cast_ptr_alignment)
authorDietmar Maurer <dietmar@proxmox.com>
Fri, 25 Oct 2019 16:03:55 +0000 (18:03 +0200)
committerDietmar Maurer <dietmar@proxmox.com>
Fri, 25 Oct 2019 16:03:55 +0000 (18:03 +0200)
src/backup/dynamic_index.rs
src/backup/fixed_index.rs

index ef6b3178c6d4e1b8d1ae820352ce7f1fd89e5463..ddb09f9ace9313cc95d9ab1924217cb78e573672 100644 (file)
@@ -131,6 +131,7 @@ impl DynamicIndexReader {
         Ok(())
     }
 
+    #[allow(clippy::cast_ptr_alignment)]
     pub fn chunk_info(&self, pos: usize) -> Result<(u64, u64, [u8; 32]), Error> {
         if pos >= self.index_entries {
             bail!("chunk index out of range");
@@ -156,6 +157,7 @@ impl DynamicIndexReader {
     }
 
     #[inline]
+    #[allow(clippy::cast_ptr_alignment)]
     fn chunk_end(&self, pos: usize) -> u64 {
         if pos >= self.index_entries {
             panic!("chunk index out of range");
index b3a5459b65973bc9b098c23f9773281c5a4f853f..9dbdada842e7d51e83817f0203de49e3738378be 100644 (file)
@@ -256,6 +256,7 @@ impl Drop for FixedIndexWriter {
 
 impl FixedIndexWriter {
 
+    #[allow(clippy::cast_ptr_alignment)]
     pub fn create(store: Arc<ChunkStore>, path: &Path, size: usize, chunk_size: usize) -> Result<Self, Error> {
 
         let shared_lock = store.try_shared_lock()?;