1,Incorrect decrement of the reference count of an object that is not owned at this point by the caller
AttrTable = [[AttrTable node] initAttrTable];
其中node已经创建并初始化了,不需要再调用initAttrTable。如果要调用initAttrTable需改为
[[[AttrTable alloc] initAttrTable] autorelease]
这种问题一般就是变量申请了内存并初始化了,但没有使用此变量,接着将此变量又重新赋值。如下:
NSString *imageString = [[NSString alloc] init];
imageString = @"HResout";
2,Value stored to 'isHD' is never read
变量isHD没有使用
3,Potential leak of an object allocated on line 226 and stored into 'smallclassname'
潜在的内存泄露点
NSString *smallclassname = [[NSString alloc] initWithString:[NSString stringWithFormat: @"%d",m_NpcClass]];
创建变量的时候尽量使用静态创建,因为静态方法都添加了anturelease,若使用alloc,init时后面最好加上autorelease
4,Pass-by-value argument in function call is undefined
CGFloat x,y;
CGFloat w,h;
w = [backSprite boundingBox].size.width;
h = [backSprite boundingBox].size.height;
myRect = CGRectMake(x, y,w ,h );
使用方法CGRectMake时,变量要初始化。代码里的x,y没有赋值。
5,Receiver in message expression is a garbage value
UIColor* tempCol;
if (level==4) {
tempCol= [[UIColor alloc] initWithRed:0.39f green:0.82f blue:0.32f alpha:1.0f];
}else if (level==5) {
tempCol= [[UIColor alloc] initWithRed:0.61f green:0.68f blue:0.83f alpha:1.0f];
}else if (level==6) {
tempCol= [[UIColor alloc] initWithRed:0.90f green:0.68f blue:0.99f alpha:1.0f];
}else if (level==7) {
tempCol= [[UIColor alloc] initWithRed:0.68f green:0.97f blue:0.99f alpha:1.0f];
}
return [tempCol autorelease];
被赋值的是个要回收的变量
6,Assigned value is garbage or undefined
Icon *leftTemp,*centerTemp,*rightTemp;
if(isHD)
{
leftTemp = cell;
}
iconLeft = leftTemp;
iconCenter = centerTemp;
iconRight = rightTemp;
变量没有初始化就赋值给其他变量时会出现这个提示。即使有条件语句也会有提示。
遇到的就这么多,继续ing。。。
分享到:
相关推荐
Analyze and extract actionable insights from your social data using various Python tools A highly practical guide to conducting efficient social media analytics at scale Who This Book Is For If you ...
By Wireshark analyze a ‘ping’ commond Open wireshark select our network In order to analyze ping commond, usually select wlan use filter : icmp(Internet Control Message Protocol), because ICMP...
wrangle-and-analyze-data
资源名:Contains the code to simulate and analyze Turing patterns on growing domains from a wide variety of reaction networks. 资源类型:matlab项目全套源码 源码说明: 全部项目源码都是经过测试校正后百...
Build Mobile Apps with Ionic 2 and Firebase: Hybrid Mobile App Development 27 May 2017 | English | ISBN-10: 1484227360 | 276 pages | PDF | 2.9 Mb Learn to build hybrid mobile apps using Ionic and ...
分析.js analyze.js 是一种分析依赖于 node 或 JavaScript 或任何编译为 JavaScript 的语言的应用程序的工具。 动态分析过程侧重于协议函数调用以及确定模块依赖性和各种运行时特征。 analysis.js 包括: 一个后端,...
重要通知:我已经放弃了这个项目,因为我现在使用而不是 Caliper 进行微基准测试。 项目介绍 该项目旨在提供一种简单的方法来分析结果。 Caliper 包含一个托管在 Google AppEngine 上的网络界面,但目前它非常缓慢...
02GB_Analyze统计分析.pptx
您将在Jupyter Notebook中记录您的艰苦努力,并通过使用Python(及其库)和/或SQL进行分析和可视化来展示它们。 您将要处理(以及分析和可视化)的数据集是Twitter用户@dog_rates的推文存档,也称为WeRateDogs。 ...
Profit from analytics throughout the entire customer experience and lifecycle Make the most of all the fast-changing data sources now available to you For all ecommerce executives, strategists, ...
可以使用 systemd-analyze 分析开机过程。 使用 systemd-analyze 分析开机过程 # 打印耗时的服务 systemd-analyze blame > 20.132s boot.mount > 19.963s kdump.service # 11.355s lvm2-monitor.service > 9.906s ...
QGroundControl Analyze 模块源码,引用QWt。可独立编译成库,用于传感器原始数据的分析。
Synthesize & Power Analyze
Title: Learn Android Studio: Build Android Apps Quickly and Effectively Author: Adam Gerber, Clifton Craig Length: 484 pages Edition: 1 Language: English Publisher: Apress Publication Date: 2015-05-11...
一个一个项目analyze太麻烦了,自己试验写了个批量analyze的脚本,很好用!
在VC盘安装analyze6.exe,可解决link问题
我找了很多资料,终于被我找到了关于Analyze format的一种存储格式。这种格式用于MRI 图像存储~
前端开源库-analyze-css分析CSS、CSS选择器的复杂性和性能分析器
Learning Apache Drill Queryand Analyze Distributed Data Sources with SQL
要开始使用fastlane-plugin-analyze_apk ,请运行以下fastlane-plugin-analyze_apk将其添加到您的项目中: fastlane add_plugin analyze_apk关于analyzer_apk 分析APK会提取有关您生成的APK的有用信息。 选项: 键...