File tree Expand file tree Collapse file tree
Expand file tree Collapse file tree Original file line number Diff line number Diff line change @@ -54,7 +54,7 @@ - (instancetype)init {
5454
5555- (void )awakeFromNib {
5656 NSNumber *userFontSizeNum = [DEFAULTS objectForKey: DefaultsKey_EditorFontSize];
57- CGFloat fontSize = userFontSizeNum ? [userFontSizeNum floatValue ] : DEFAULT_TEXT_FONT_SIZE;
57+ CGFloat fontSize = userFontSizeNum != nil ? [userFontSizeNum floatValue ] : DEFAULT_TEXT_FONT_SIZE;
5858 NSFont *font = [NSFont fontWithName: DEFAULT_TEXT_FONT_NAME size: fontSize];
5959 [textView setFont: font];
6060 [textView setAutomaticQuoteSubstitutionEnabled: NO ];
Original file line number Diff line number Diff line change 445445 <key >CFBundleSignature </key >
446446 <string >???? </string >
447447 <key >CFBundleVersion </key >
448- <string >1331 </string >
448+ <string >1332 </string >
449449 <key >LSApplicationCategoryType </key >
450450 <string >public.app-category.developer-tools </string >
451451 <key >LSMinimumSystemVersion </key >
Original file line number Diff line number Diff line change @@ -284,14 +284,14 @@ - (void)loadAppSettings {
284284
285285 // Font and size
286286 NSNumber *userFontSizeNum = [DEFAULTS objectForKey: ScriptExecDefaultsKey_UserFontSize];
287- CGFloat fontSize = userFontSizeNum ? [userFontSizeNum floatValue ] : [appSettings[AppSpecKey_TextSize] floatValue ];
287+ CGFloat fontSize = userFontSizeNum != nil ? [userFontSizeNum floatValue ] : [appSettings[AppSpecKey_TextSize] floatValue ];
288288 fontSize = fontSize != 0 ? fontSize : DEFAULT_TEXT_FONT_SIZE;
289289
290290 if (appSettings[AppSpecKey_TextFont]) {
291291 textFont = [NSFont fontWithName: appSettings[AppSpecKey_TextFont] size: fontSize];
292292 }
293293 if (textFont == nil ) {
294- textFont = [NSFont fontWithName: DEFAULT_TEXT_FONT_NAME size: DEFAULT_TEXT_FONT_SIZE ];
294+ textFont = [NSFont fontWithName: DEFAULT_TEXT_FONT_NAME size: fontSize ];
295295 }
296296
297297 BOOL darkMode = NO ;
Original file line number Diff line number Diff line change 3131#import < stdio.h>
3232#import < unistd.h>
3333#import < dlfcn.h>
34+ #import < sys/param.h>
3435
3536// New error code denoting that AuthorizationExecuteWithPrivileges no longer exists
3637OSStatus const errAuthorizationFnNoLongerExists = -70001 ;
@@ -217,7 +218,8 @@ - (OSStatus)launchWithAuthorization:(AuthorizationRef)authorization
217218 args[numberOfArguments] = NULL ;
218219
219220 // change to the current dir specified
220- char *prevCwd = (char *)getcwd (nil , 0 );
221+ char prevCwd[MAXPATHLEN];
222+ getcwd (prevCwd, sizeof (prevCwd));
221223 chdir ([self .currentDirectoryPath fileSystemRepresentation ]);
222224
223225 // use Authorization Reference to execute script with privileges
You can’t perform that action at this time.
0 commit comments