-
Notifications
You must be signed in to change notification settings - Fork 72
Description
Changed as you can see in these lines.
Is It Fine?
//
// base64EncodedString
//
// Creates an NSString object that contains the base 64 encoding of the
// receiver's data. Lines are broken at 64 characters long.
//
// returns an autoreleased NSString being the base 64 representation of the
// receiver.
//
-
(NSString *)base64EncodedString
{
size_t outputLength;
char *outputBuffer = NewBase64Encode([self bytes], [self length], true, &outputLength);// Delete the Autorelease in ORIG
NSString *result = [[NSString alloc]
initWithBytes:outputBuffer
length:outputLength
encoding:NSASCIIStringEncoding];
free(outputBuffer);
return result;
}
// added by Hiroshi Hashiguchi
-
(NSString *)base64EncodedStringWithSeparateLines:(BOOL)separateLines
{
// ORIG size_t outputLength;
size_t outputLength = 0;
char *outputBuffer = NewBase64Encode([self bytes], [self length], separateLines, &outputLength);// Delete the Autorelease in ORIG
NSString *result = [[NSString alloc]
initWithBytes:outputBuffer
length:outputLength
encoding:NSASCIIStringEncoding];
free(outputBuffer);
return result;
}