Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

xcode 8 - ios 9.3 - compiler warnings #17

Open
MavEtJu opened this issue May 14, 2017 · 1 comment
Open

xcode 8 - ios 9.3 - compiler warnings #17

MavEtJu opened this issue May 14, 2017 · 1 comment

Comments

@MavEtJu
Copy link

MavEtJu commented May 14, 2017

gzFile is already a "struct gzsomething *", so it shouldn't be "gzFile *".

--- a/Geocube/NVHTarGzip/NVHGzipFile.m
+++ b/Geocube/NVHTarGzip/NVHGzipFile.m
@@ -103,7 +103,7 @@ - (NSInteger)inflateGzip:(NSString *)sourcePath
        // Convert source path into something a C library can handle
        const char *sourceCString = [sourcePath cStringUsingEncoding:NSASCIIStringEncoding];
     
-       gzFile *sourceGzFile = gzopen(sourceCString, "rb");
+       gzFile sourceGzFile = gzopen(sourceCString, "rb");
     
        unsigned int bufferLength = 1024*256;   //Thats like 256Kb
        void *buffer = malloc(bufferLength);
@@ -221,7 +221,7 @@ - (NSInteger)deflateToGzip:(NSString *)destinationPath
     // Convert destination path into something a C library can handle
     const char *destinationCString = [destinationPath cStringUsingEncoding:NSASCIIStringEncoding];
     
-    gzFile *destinationGzFile = gzopen(destinationCString, "wb");
+    gzFile destinationGzFile = gzopen(destinationCString, "wb");
     
     unsigned int bufferLength = 1024*256;      //Thats like 256Kb
     void *buffer = malloc(bufferLength);
@nvh
Copy link
Owner

nvh commented May 15, 2017

I'm not actively maintaining this project, but If you submit a PR, I'd happily merge it.

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

No branches or pull requests

2 participants