login about faq

Hi, I am unable to untar a tar.gz file following is mine code

CkoTar *tarTask = [[CkoTar alloc] init];
BOOL success = [gzip UnlockComponent: @"Anything for 30-day trial"];
if (success != YES) {
    NSLog(@"Error");
    return;
}
tarTask.UntarFromDir = utarFilePath;
BOOL success = [tarTask UntarGz:tarFilePath];
if (success != YES) {
    NSLog(@"Unxiped %@", tarTask.LastErrorText);
}

This is the error Log

Unxiped ChilkatLog: UntarGz: DllDate: Dec 30 2015 ChilkatVersion: 9.5.0.55 UnlockPrefix: Anything for 30-day trial Architecture: Little Endian; 64-bit Language: IOS Objective-C VerboseLogging: 0 pathQP: Alfresco_Resources.tar.gz fopen_failed: errno: 2 osErrorMessage: No such file or directory Failed to open file. mode: r path: Alfresco_Resources.tar.gz --fopen_failed Failed to open file data source. --UntarGz --ChilkatLog


I have tried with both

tarTask.NoAbsolutePaths = YES & NO both.

This question is marked "community wiki".

asked Jan 27 at 03:34

Lakshaya%20Chhabra's gravatar image

Lakshaya Chhabra
31


When a filename with no path part is passed to a method requiring a file path, one cannot assume the file to be located anywhere except for the current working directory of the process. I don't know what that might be in iOS. The solution is to pass an absolute file path to the .tar.gz so there is no question about where the file is located.

link

answered Jan 27 at 15:18

chilkat's gravatar image

chilkat ♦♦
11.8k316358420

Your answer
toggle preview

Follow this question

By Email:

Once you sign in you will be able to subscribe for any updates here

By RSS:

Answers

Answers and Comments

Markdown Basics

  • *italic* or __italic__
  • **bold** or __bold__
  • link:[text](http://url.com/ "title")
  • image?![alt text](/path/img.jpg "title")
  • numbered list: 1. Foo 2. Bar
  • to add a line break simply add two spaces to where you would like the new line to be.
  • basic HTML tags are also supported

Tags:

×94
×17

Asked: Jan 27 at 03:34

Seen: 375 times

Last updated: Jan 27 at 15:18

powered by OSQA