You are viewing a plain text version of this content. The canonical link for it is here.
Posted to commits@arrow.apache.org by uw...@apache.org on 2018/04/24 08:17:39 UTC

[arrow] branch master updated: ARROW-2502: [Rust] Restore Windows Compatibility

This is an automated email from the ASF dual-hosted git repository.

uwe pushed a commit to branch master
in repository https://gitbox.apache.org/repos/asf/arrow.git


The following commit(s) were added to refs/heads/master by this push:
     new a609309  ARROW-2502: [Rust] Restore Windows Compatibility
a609309 is described below

commit a6093095db53bdc0dabb3b8b48b64293cc26e30b
Author: Paddy <pa...@hotmail.com>
AuthorDate: Tue Apr 24 10:17:14 2018 +0200

    ARROW-2502: [Rust] Restore Windows Compatibility
    
    This PR restores the windows compatibility for the current master.  The memory pool abstraction is not used anywhere else within the code base and so is not included in windows builds.
    
    Next I plan to add [CI](https://issues.apache.org/jira/browse/ARROW-2436?filter=12343557&jql=project%20%3D%20ARROW%20AND%20component%20%3D%20Rust%20AND%20status%20%3D%20Open) for windows.  Followed by [ARROW-2474](https://issues.apache.org/jira/browse/ARROW-2474?filter=12343557&jql=project%20%3D%20ARROW%20AND%20component%20%3D%20Rust%20AND%20status%20%3D%20Open), which I will add windows compatibility to the memory pool abstraction, allowing it to be used throughout the code base.
    
    Author: Paddy <pa...@hotmail.com>
    
    Closes #1938 from paddyhoran/ARROW-2502 and squashes the following commits:
    
    3e00f137 <Paddy> Fixes ARROW-2502
---
 rust/src/builder.rs | 2 +-
 rust/src/lib.rs     | 1 +
 2 files changed, 2 insertions(+), 1 deletion(-)

diff --git a/rust/src/builder.rs b/rust/src/builder.rs
index bb18d2e..ad0caec 100644
--- a/rust/src/builder.rs
+++ b/rust/src/builder.rs
@@ -123,7 +123,7 @@ impl<T> Builder<T> {
             );
             self.capacity = new_capacity;
             self.data = mem::transmute::<*const u8, *mut T>(new_buffer);
-            libc::free(mem::transmute::<*mut T, *mut libc::c_void>(old_buffer));
+            free_aligned(mem::transmute::<*mut T, *const u8>(old_buffer));
         }
     }
 
diff --git a/rust/src/lib.rs b/rust/src/lib.rs
index 80b53a1..0ac8155 100644
--- a/rust/src/lib.rs
+++ b/rust/src/lib.rs
@@ -30,4 +30,5 @@ pub mod error;
 pub mod list;
 pub mod list_builder;
 pub mod memory;
+#[cfg(not(windows))]
 pub mod memory_pool;

-- 
To stop receiving notification emails like this one, please contact
uwe@apache.org.