Sign Up

Sign Up to our social questions and Answers Engine to ask questions, answer people’s questions, and connect with other people.

Have an account? Sign In

Have an account? Sign In Now

Sign In

Login to our social questions & Answers Engine to ask questions answer people’s questions & connect with other people.

Sign Up Here

Forgot Password?

Don't have account, Sign Up Here

Forgot Password

Lost your password? Please enter your email address. You will receive a link and will create a new password via email.

Have an account? Sign In Now

You must login to ask a question.

Forgot Password?

Need An Account, Sign Up Here

Please briefly explain why you feel this question should be reported.

Please briefly explain why you feel this answer should be reported.

Please briefly explain why you feel this user should be reported.

Sign InSign Up

The Archive Base

The Archive Base Logo The Archive Base Logo

The Archive Base Navigation

  • SEARCH
  • Home
  • About Us
  • Blog
  • Contact Us
Search
Ask A Question

Mobile menu

Close
Ask a Question
  • Home
  • Add group
  • Groups page
  • Feed
  • User Profile
  • Communities
  • Questions
    • New Questions
    • Trending Questions
    • Must read Questions
    • Hot Questions
  • Polls
  • Tags
  • Badges
  • Buy Points
  • Users
  • Help
  • Buy Theme
  • SEARCH
Home/ Questions/Q 6674433
In Process

The Archive Base Latest Questions

Editorial Team
  • 0
Editorial Team
Asked: May 26, 20262026-05-26T03:44:40+00:00 2026-05-26T03:44:40+00:00

We are getting an error when trying to delete a folder on startup. We

  • 0

We are getting an error when trying to delete a folder on startup. We are removing a folder placed in documents used to store cache-data. Any idea why it is crashing?

0   libsystem_kernel.dylib  0x364b62d0 __unlink + 8
1   libsystem_kernel.dylib  0x364b46a6 unlink + 2
2   libremovefile.dylib     0x313099c8 __removefile_process_file + 232
3   libremovefile.dylib     0x31309a50 __removefile_tree_walker + 100
4   libremovefile.dylib     0x313090f4 removefile + 88
5   Foundation              0x3156c11a -[NSFilesystemItemRemoveOperation main] + 138
6   Foundation              0x31551d14 -[__NSOperationInternal start] + 652
7   Foundation              0x31551a78 -[NSOperation start] + 16
8   Foundation              0x3156bfda -[NSFileManager removeItemAtPath:error:] + 46
9   VG                      0x0004f030 +[VGFileManager removeOldCacheFolder] + 319536
10  VG                      0x00003e1c -[VGAppDelegate application:didFinishLaunchingWithOptions:] + 11804
11  UIKit                   0x31de481a -[UIApplication _callInitializationDelegatesForURL:payload:suspended:] + 766
12  UIKit                   0x31ddeb5e -[UIApplication _runWithURL:payload:launchOrientation:statusBarStyle:statusBarHidden:] + 266
13  UIKit                   0x31db37d0 -[UIApplication handleEvent:withNewEvent:] + 1108
14  UIKit                   0x31db320e -[UIApplication sendEvent:] + 38
15  UIKit                   0x31db2c4c _UIApplicationHandleEvent + 5084
16  GraphicsServices        0x34720e70 PurpleEventCallback + 660
17  CoreFoundation          0x30ba5a90 __CFRUNLOOP_IS_CALLING_OUT_TO_A_SOURCE1_PERFORM_FUNCTION__ + 20
18  CoreFoundation          0x30ba7838 __CFRunLoopDoSource1 + 160
19  CoreFoundation          0x30ba8606 __CFRunLoopRun + 514
20  CoreFoundation          0x30b38ebc CFRunLoopRunSpecific + 224
21  CoreFoundation          0x30b38dc4 CFRunLoopRunInMode + 52
22  UIKit                   0x31dddd42 -[UIApplication _run] + 366
23  UIKit                   0x31ddb800 UIApplicationMain + 664
24  VG                      0x0000bd96 0x1000 + 44438
25  VG                      0x00003990 0x1000 + 10640

This is the function called on “9”.

+ (void)removeOldCacheFolder {

    BOOL oldCacheFolderRemoved = [[NSUserDefaults standardUserDefaults] boolForKey:kVGFileCacheFolder_1_2];

    if(!oldCacheFolderRemoved){
        NSArray *paths = NSSearchPathForDirectoriesInDomains(NSDocumentDirectory, NSUserDomainMask, YES);
        NSString *documentsDirectory = [paths objectAtIndex:0]; //Get documents folder  
        NSString *cacheDirectory = [documentsDirectory stringByAppendingPathComponent:kVGFileCacheFolder_1_2]; 

        if ([[NSFileManager defaultManager] fileExistsAtPath:cacheDirectory]) {
            NSError *error = nil;

            if (!([[NSFileManager defaultManager] removeItemAtPath:cacheDirectory error:&error])) {
                ELog(@"Unresolved error %@, %@", error, [error userInfo]);
            }
            else{
                [[NSUserDefaults standardUserDefaults] setBool:YES forKey:kVGFileCacheFolder_1_2];
            }
        }
    }

    BOOL oldSQLFileDeleted = [[NSUserDefaults standardUserDefaults] boolForKey:kVGFileDb_1_3];

    if(!oldSQLFileDeleted){

        NSArray *paths = NSSearchPathForDirectoriesInDomains(NSDocumentDirectory, NSUserDomainMask, YES);
        NSString *documentsDirectory = [paths objectAtIndex:0]; //Get documents folder

        NSString *sqlFile = [documentsDirectory stringByAppendingPathComponent:kVGFileDb_1_3]; 

        if ([[NSFileManager defaultManager] fileExistsAtPath:sqlFile]) {
            NSError *error = nil;

            if (!([[NSFileManager defaultManager] removeItemAtPath:sqlFile error:&error])) {
                ELog(@"Unresolved error %@, %@", error, [error userInfo]);
            }
            else{
                [[NSUserDefaults standardUserDefaults] setBool:YES forKey:kVGFileDb_1_3];
            }
        }
    }
}

EDIT: Just discovered this process can take 2 minutes…

  • 1 1 Answer
  • 0 Views
  • 0 Followers
  • 0
Share
  • Facebook
  • Report

Leave an answer
Cancel reply

You must login to add an answer.

Forgot Password?

Need An Account, Sign Up Here

1 Answer

  • Voted
  • Oldest
  • Recent
  • Random
  1. Editorial Team
    Editorial Team
    2026-05-26T03:44:40+00:00Added an answer on May 26, 2026 at 3:44 am

    Maybe we’re getting killed by the iOS watchdog, any app that takes too long to launch gets terminated. Could it be a too time consuming process?

    • 0
    • Reply
    • Share
      Share
      • Share on Facebook
      • Share on Twitter
      • Share on LinkedIn
      • Share on WhatsApp
      • Report

Sidebar

Related Questions

I'm trying to delete the vector's content and I'm getting an error - vector
I'm getting the same error when I'm trying to delete my save files. The
I am getting the following error msg when I am trying to delete a
I keep getting this error when trying to delete a record from my table.
I am getting an error when trying to delete a record from the database.
I am getting error trying to run my asp code for executing stored proc.
I am getting Bus Error trying to read stdin into a char* variable. I
I am new to php and I am getting this error trying to load
I´m getting this error while trying to commit to a svn repository: svn: MKACTIVITY
I am getting this error when trying to run internet information services on a

Explore

  • Home
  • Add group
  • Groups page
  • Communities
  • Questions
    • New Questions
    • Trending Questions
    • Must read Questions
    • Hot Questions
  • Polls
  • Tags
  • Badges
  • Users
  • Help
  • SEARCH

Footer

© 2021 The Archive Base. All Rights Reserved
With Love by The Archive Base

Insert/edit link

Enter the destination URL

Or link to existing content

    No search term specified. Showing recent items. Search or use up and down arrow keys to select an item.