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

Problem with image #15

Closed
GoogleCodeExporter opened this issue Feb 26, 2016 · 1 comment
Closed

Problem with image #15

GoogleCodeExporter opened this issue Feb 26, 2016 · 1 comment

Comments

@GoogleCodeExporter
Copy link

Hello.

I've downloaded the ZipArchive library and I've added to my project. I use the 
method CreateZipFile2: , I add the file to the zip with addFileToZip:newname: 
and I close the zip calling back the method CloseZipFile2.

Then the zip is done in the finder, but in its inside I've an image that I 
can't open because it's empity (it's 0kb).

Someone knows why?

In attachment I put the portion of code that I use to do the zip.

        NSString* zipName = @"archivio.zip";
    NSMutableArray* array = [[NSMutableArray alloc]init];
    [array addObject:@"photo1.jpg"];

    ZipArchive* zip = [[ZipArchive alloc] init];

     [zip CreateZipFile2:zipName];
     [zip addFileToZip:[array objectAtIndex:0] newname:[array objectAtIndex:0]];
     [zip CloseZipFile2];

    [zip release];

Original issue reported on code.google.com by alessio....@gmail.com on 8 Nov 2010 at 5:04

@GoogleCodeExporter
Copy link
Author

Probably doesn't find the file--you should get better results by passing 
ZipArchive the complete path to a file, and not just the filename.  

I just joined this project, so I realize the reply is a little late, but let me 
know if you still have troubles.

Original comment by elinc...@hachisoft.com on 15 Feb 2011 at 8:01

  • Changed state: WontFix

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

No branches or pull requests

1 participant