Changeset 222 for trunk/Cocoa


Ignore:
Timestamp:
05/16/06 18:44:19 (14 years ago)
Author:
rchin
Message:

Fixed problem with F-Script leaking file handles (caused F-Script to not be able to inject into applications after a certain number of running apps had been launched). The problem was in appIsPEF calling open(2) but not close(2) before returning.

Location:
trunk/Cocoa/F-Script Anywhere/Source
Files:
8 edited

Legend:

Unmodified
Added
Removed
  • trunk/Cocoa/F-Script Anywhere/Source/Bundle Loader-Info.plist

    r153 r222  
    2222        <string>FSAL</string>
    2323        <key>CFBundleVersion</key>
    24         <string>1.2b1</string>
     24        <string>1.3</string>
    2525</dict>
    2626</plist>
  • trunk/Cocoa/F-Script Anywhere/Source/Bundle-Info.plist

    r153 r222  
    2222        <string>FSAB</string>
    2323        <key>CFBundleVersion</key>
    24         <string>1.2b1</string>
     24        <string>1.3</string>
    2525</dict>
    2626</plist>
  • trunk/Cocoa/F-Script Anywhere/Source/DeVercruesseProcess.m

    r154 r222  
    111111    bundleURL = CFURLCreateWithFileSystemPath(NULL, bundleLoc, kCFURLPOSIXPathStyle, NO);
    112112    bundleRef = CFBundleCreate(NULL, bundleURL);
     113    CFRelease(bundleURL);
    113114
    114115    if (bundleRef == NULL) {
    115116        BOOL isDir;
    116         CFRelease(bundleURL);
    117117        if ([[NSFileManager defaultManager] fileExistsAtPath: [self loc] isDirectory: &isDir] && !isDir)
    118118            return [self loc];
  • trunk/Cocoa/F-Script Anywhere/Source/FSAApp.mm

    r217 r222  
    239239    if (err != noErr)
    240240        [self installationError: err inAppWithPID: pid];
     241    else
     242        [appList didPatchProcessID: pid];
    241243}
    242244
  • trunk/Cocoa/F-Script Anywhere/Source/FSAAppList.m

    r221 r222  
    132132{
    133133    [tableView reloadData];
    134     [self tableView: tableView shouldSelectRow: [tableView selectedRow]];
     134//    [self tableView: tableView shouldSelectRow: [tableView selectedRow]];
    135135}
    136136
     
    143143{
    144144    DeVercruesseProcess *app = [self _applicationForPID: pid];
    145     [patchingApps removeObject: app];
    146     [patchedApps addObject: app];
     145    if(app){
     146        [patchingApps removeObject: app];
     147        [patchedApps addObject: app];
     148    }
    147149    [self _processStatusChanged];
    148150}
     
    170172        return NO;
    171173   
    172     if (read(fd, &pefHeader, sizeof(pefHeader)) != sizeof(pefHeader))
     174    if (read(fd, &pefHeader, sizeof(pefHeader)) != sizeof(pefHeader)){
     175        close(fd);
    173176        return NO;
     177    } else
     178        close(fd);
    174179   
    175180    if (pefHeader.tag1 != kPEFTag1 || pefHeader.tag2 != kPEFTag2)
     
    229234     }
    230235     */
    231    
    232236    if ( ![app isBackgroundOnly] &&
    233237         ( ( [app isCocoa] && ![self appIsPEF: app]) ||
     
    461465    id e = [cocoaApps objectEnumerator];
    462466    while(anApp = [e nextObject]){
    463         if([alwaysApps containsObject:[anApp name]] && ![patchedApps containsObject:anApp]){
     467        if([alwaysApps containsObject:[anApp name]]){
    464468            [NSApp installBundleInAppWithPID:[anApp pid]];
    465469        }
  • trunk/Cocoa/F-Script Anywhere/Source/Info-Application.plist

    r153 r222  
    88        <string>F-Script Anywhere</string>
    99        <key>CFBundleGetInfoString</key>
    10         <string>F-Script Anywhere 1.2b1,
    11 © 2002–04 Nicholas Riley</string>
     10        <string>F-Script Anywhere 1.3,
     11© 2002–06 Nicholas Riley</string>
    1212        <key>CFBundleIconFile</key>
    1313        <string>Application icon</string>
     
    2121        <string>APPL</string>
    2222        <key>CFBundleShortVersionString</key>
    23         <string>1.2b1</string>
     23        <string>1.3</string>
    2424        <key>CFBundleSignature</key>
    2525        <string>FSAn</string>
    2626        <key>CFBundleVersion</key>
    27         <string>1.2b1</string>
     27        <string>1.3</string>
    2828        <key>NSMainNibFile</key>
    2929        <string>MainMenu</string>
  • trunk/Cocoa/F-Script Anywhere/Source/VERSION

    r19 r222  
    1 1.1.6d1
     11.3
Note: See TracChangeset for help on using the changeset viewer.