mirror of
https://github.com/kennethreitz-archive/gitx.git
synced 2026-06-05 23:40:18 +00:00
Remove use of deprecated stringWithCString
This commit is contained in:
+1
-1
@@ -66,7 +66,7 @@ static NSString* gitPath = nil;
|
||||
|
||||
// Try to find the path of the Git binary
|
||||
char* path = getenv("GIT_PATH");
|
||||
if (path && [self acceptBinary:[NSString stringWithCString:path]])
|
||||
if (path && [self acceptBinary:[NSString stringWithUTF8String:path]])
|
||||
return;
|
||||
|
||||
// No explicit path. Try it with "which"
|
||||
|
||||
@@ -132,7 +132,7 @@ int main(int argc, const char** argv)
|
||||
NSMutableArray* arguments = [NSMutableArray arrayWithCapacity:argc];
|
||||
int i = 0;
|
||||
for (i = 0; i < argc; i++)
|
||||
[arguments addObject: [NSString stringWithCString:argv[i]]];
|
||||
[arguments addObject: [NSString stringWithUTF8String:argv[i]]];
|
||||
|
||||
if (!isatty(STDIN_FILENO) && fdopen(STDIN_FILENO, "r"))
|
||||
handleSTDINDiff(proxy);
|
||||
|
||||
Reference in New Issue
Block a user