2012-09-25 14:01 Xcode升级后的Bug处理
来源:互联网 发布:淘宝显示地址怎么改 编辑:程序博客网 时间:2024/05/18 11:08
Xcode升级到4.4后,出现了一堆的Warning.网上搜了一些办法,总结一下。
1:Jsonkit中的
Direct access to objective-c's isa is deprecated in favor of object_setClass() and object_getClass()
object->isa 替换为 object_getClass(object)keyObject->isa 替换为 object_getClass(keyObject)
(id)keys[idx]->isa 替换为 object_getClass((id)keys[idx])format specifies type 'unsigned long' but the argument has type 'nsuinteger' (aka 'unsigned int')
给变量增加(unsigned long)进行类型转换
2:md5加密(iOS SDK中自带了CommonCrypto)
Implicit declaration of function 'CC_MD5' is invalid in C99
#define CC_MD5_DIGEST_LENGTH 16
+(NSString *)MD5HashForString:(NSString *)input {
const char *cStr = [input UTF8String];
unsigned char result[CC_MD5_DIGEST_LENGTH];
CC_MD5(cStr, strlen(cStr), result);
return [NSString stringWithFormat: @"%02x%02x%02x%02x%02x%02x%02x%02x%02x%02x%02x%02x%02x%02x%02x%02x",
result[0], result[1], result[2], result[3],
result[4], result[5], result[6], result[7],
result[8], result[9], result[10], result[11],
result[12], result[13], result[14], result[15]];
}
#import <CommonCrypto/CommonDigest.h>
3:ASIDataDecompressor中的警告
format specifies type 'short' but the argument has type 'int'
在+ (NSError *)deflateErrorWithCode:(int)code 和 +(NSError *)inflateErrorWithCode:(int)code中
[NSString stringWithFormat:@"Compression of data failed with code %hi",code] 中
将code改为 (short)code,类型转换
4:Reachability中警告
Using 'stringWithString:' with a literal is redundant
statusString = [NSString stringWithString: @"Not Reachable"]; 改为:statusString = @"Not Reachable";- 2012-09-25 14:01 Xcode升级后的Bug处理
- Xcode升级4.4后的Bug处理
- Xcode升级后的Bug处理
- Xcode升级4.6后的Bug处理
- xcode升级到6.3.2后找不到Alcatraz的bug
- 升级Xcode后的插件无效问题
- Xcode升级后Alcatraz失效的解决方案。
- Xcode升级后Alcatraz失效的解决方案
- XCode升级后插件失效的解决办法
- Xcode升级后插件失效的解决办法
- 关于xcode7升级以后,无法archive,或者archive后xcode闪退的问题处理方案
- Hive-0.9 升级 Hive-0.12后结合HBase统计遇到的BUG处理
- 女朋友升级到妻子后的BUG
- VVDocumenter-Xcode在Xcode升级后不能用的解决办法
- 升级Xcode后VVDocumenter-Xcode不能用的解决办法
- Xcode7升级以后,无法archive,archive卡住,或者archive后Xcode闪退的问题处理方案
- [xamarin]更新xcode和xamarin后mac出现的bug
- Xcode 升级后,常常遇到的遇到的警告解决方法
- Linux定时任务系统Crontab
- STL 容器类型
- 转化率的因素
- 无聊
- 发个自定义Xshell颜色主题Color Schemes
- 2012-09-25 14:01 Xcode升级后的Bug处理
- STL 之includes,set_intersection,set_union,set_difference,set_symmetric_difference
- linux安装笔记
- Java之Socket与HTTP区别
- Java电话号码和手机号码正则验证
- 自动战斗的计算过程
- SpringMVC结合ajaxfileupload.js实现文件无刷新上传
- TCP/IP、Http、Socket的区别
- js弹出层