佳为好友

原:gdb与时间戳

创建:2012年12月27日

gdb
使用while循环打印ctime失败。
不得已,在代码中定义了一个临时函数
- (NSDate *)getTTT:(NSTimeInterval)tt
{
    return [NSDate dateWithTimeIntervalSince1970:tt];
}
(gdb) p $p=0
$828 = 0
(gdb) while ($p<$c)
 >p $ttt = (double)[(NSNumber *)[$ts objectAtIndex:$p] doubleValue]
 >po [self getTTT:$ttt]
 >p $p++
 >end
$829 = 1351569600
2012-10-30 04:00:00 +0000
$830 = 0
$831 = 1351570500
2012-10-30 04:15:00 +0000
$832 = 1
$833 = 1351571400
2012-10-30 04:30:00 +0000
$834 = 2
$835 = 1351572300
2012-10-30 04:45:00 +0000
$836 = 3
$837 = 1351573200
2012-10-30 05:00:00 +0000
$838 = 4
$839 = 1351574100
2012-10-30 05:15:00 +0000
$840 = 5
$841 = 1351575000
2012-10-30 05:30:00 +0000
$842 = 6
$843 = 1351575900
2012-10-30 05:45:00 +0000
$844 = 7
$845 = 1351576800
2012-10-30 06:00:00 +0000
$846 = 8
$847 = 1351577700
2012-10-30 06:15:00 +0000
$848 = 9
$849 = 1351578600
2012-10-30 06:30:00 +0000
$850 = 10
$851 = 1351579500
2012-10-30 06:45:00 +0000
$852 = 11
$853 = 1351580400
2012-10-30 07:00:00 +0000
$854 = 12
$855 = 1351581300
2012-10-30 07:15:00 +0000
$856 = 13
$857 = 1351582200
2012-10-30 07:30:00 +0000
$858 = 14
$859 = 1351583100
2012-10-30 07:45:00 +0000
$860 = 15
$861 = 1351584000
2012-10-30 08:00:00 +0000
$862 = 16
$863 = 1351584900
2012-10-30 08:15:00 +0000
$864 = 17
$865 = 1351585800
2012-10-30 08:30:00 +0000
$866 = 18
$867 = 1351586700
2012-10-30 08:45:00 +0000
$868 = 19
$869 = 1351587600
2012-10-30 09:00:00 +0000
$870 = 20
$871 = 1351589400
2012-10-30 09:30:00 +0000
$872 = 21
$873 = 1351590300
2012-10-30 09:45:00 +0000
$874 = 22
$875 = 1351597500
2012-10-30 11:45:00 +0000
$876 = 23
$877 = 1351638000
2012-10-30 23:00:00 +0000
$878 = 24
$879 = 1351645200
2012-10-31 01:00:00 +0000
$880 = 25
$881 = 1351646100
2012-10-31 01:15:00 +0000
$882 = 26
$883 = 1351647000
2012-10-31 01:30:00 +0000
$884 = 27
$885 = 1351647900
2012-10-31 01:45:00 +0000
$886 = 28
$887 = 1351648800
2012-10-31 02:00:00 +0000
$888 = 29
$889 = 1351649700
2012-10-31 02:15:00 +0000
$890 = 30
$891 = 1351650600
2012-10-31 02:30:00 +0000
$892 = 31
$893 = 1351651500
2012-10-31 02:45:00 +0000
$894 = 32
$895 = 1351652400
2012-10-31 03:00:00 +0000
$896 = 33
$897 = 1351653300
2012-10-31 03:15:00 +0000
$898 = 34
$899 = 1351654200
2012-10-31 03:30:00 +0000
$900 = 35
$901 = 1351656000
2012-10-31 04:00:00 +0000
$902 = 36
$903 = 1351656900
2012-10-31 04:15:00 +0000
$904 = 37
$905 = 1351657800
2012-10-31 04:30:00 +0000
$906 = 38
$907 = 1351658700
2012-10-31 04:45:00 +0000
$908 = 39
$909 = 1351659600
2012-10-31 05:00:00 +0000
$910 = 40
$911 = 1351660500
2012-10-31 05:15:00 +0000
$912 = 41
$913 = 1351661400
2012-10-31 05:30:00 +0000
$914 = 42
$915 = 1351662300
2012-10-31 05:45:00 +0000
$916 = 43
$917 = 1351663200
2012-10-31 06:00:00 +0000
$918 = 44
$919 = 1351664100
2012-10-31 06:15:00 +0000
$920 = 45
$921 = 1351665000
2012-10-31 06:30:00 +0000
$922 = 46
$923 = 1351665900
2012-10-31 06:45:00 +0000
$924 = 47
$925 = 1351666800
2012-10-31 07:00:00 +0000
$926 = 48
$927 = 1351667700
2012-10-31 07:15:00 +0000
$928 = 49
$929 = 1351668600
2012-10-31 07:30:00 +0000
$930 = 50
$931 = 1351669500
2012-10-31 07:45:00 +0000
$932 = 51
$933 = 1351670400
2012-10-31 08:00:00 +0000
$934 = 52
$935 = 1351671300
2012-10-31 08:15:00 +0000
$936 = 53
$937 = 1351672200
2012-10-31 08:30:00 +0000
$938 = 54
$939 = 1351673100
2012-10-31 08:45:00 +0000
$940 = 55
$941 = 1351674000
2012-10-31 09:00:00 +0000
$942 = 56
$943 = 1351702800
2012-10-31 17:00:00 +0000
$944 = 57
$945 = 1351724400
2012-10-31 23:00:00 +0000
$946 = 58
$947 = 1351731600
2012-11-01 01:00:00 +0000
$948 = 59
$949 = 1351732500
2012-11-01 01:15:00 +0000
$950 = 60
$951 = 1351733400
2012-11-01 01:30:00 +0000
$952 = 61
$953 = 1351734300
2012-11-01 01:45:00 +0000
$954 = 62
$955 = 1351735200
2012-11-01 02:00:00 +0000
$956 = 63
$957 = 1351736100
2012-11-01 02:15:00 +0000
$958 = 64
$959 = 1351737000
2012-11-01 02:30:00 +0000
$960 = 65
$961 = 1351737900
2012-11-01 02:45:00 +0000
$962 = 66
$963 = 1351738800
2012-11-01 03:00:00 +0000
$964 = 67
$965 = 1351739700
2012-11-01 03:15:00 +0000
$966 = 68
$967 = 1351740600
2012-11-01 03:30:00 +0000
$968 = 69
$969 = 1351742400
2012-11-01 04:00:00 +0000
$970 = 70
$971 = 1351743300
2012-11-01 04:15:00 +0000
$972 = 71
$973 = 1351744200
2012-11-01 04:30:00 +0000
$974 = 72
$975 = 1351745100
2012-11-01 04:45:00 +0000
$976 = 73
$977 = 1351746000
2012-11-01 05:00:00 +0000
$978 = 74
$979 = 1351746900
2012-11-01 05:15:00 +0000
$980 = 75
$981 = 1351747800
2012-11-01 05:30:00 +0000
$982 = 76
$983 = 1351748700
2012-11-01 05:45:00 +0000
$984 = 77
$985 = 1351749600
2012-11-01 06:00:00 +0000
$986 = 78
$987 = 1351750500
2012-11-01 06:15:00 +0000
$988 = 79
$989 = 1351751400
2012-11-01 06:30:00 +0000
$990 = 80
$991 = 1351752300
2012-11-01 06:45:00 +0000
$992 = 81
$993 = 1351753200
2012-11-01 07:00:00 +0000
$994 = 82
$995 = 1351754100
2012-11-01 07:15:00 +0000
$996 = 83
$997 = 1351755000
2012-11-01 07:30:00 +0000
$998 = 84
$999 = 1351755900
2012-11-01 07:45:00 +0000
$1000 = 85
$1001 = 1351756800
2012-11-01 08:00:00 +0000
$1002 = 86
$1003 = 1351757700
2012-11-01 08:15:00 +0000
$1004 = 87
$1005 = 1351758600
2012-11-01 08:30:00 +0000
$1006 = 88
$1007 = 1351759500
2012-11-01 08:45:00 +0000
$1008 = 89
$1009 = 1351760400
2012-11-01 09:00:00 +0000
$1010 = 90
$1011 = 1351810800
2012-11-01 23:00:00 +0000
$1012 = 91
$1013 = 1351816200
2012-11-02 00:30:00 +0000
$1014 = 92
$1015 = 1351818000
2012-11-02 01:00:00 +0000
$1016 = 93
$1017 = 1351818900
2012-11-02 01:15:00 +0000
$1018 = 94
$1019 = 1351819800
2012-11-02 01:30:00 +0000
$1020 = 95
$1021 = 1351820700
2012-11-02 01:45:00 +0000
$1022 = 96
$1023 = 1351821600
2012-11-02 02:00:00 +0000
$1024 = 97
$1025 = 1351822500
2012-11-02 02:15:00 +0000
$1026 = 98
$1027 = 1351823400
2012-11-02 02:30:00 +0000
$1028 = 99
$1029 = 1351824300
2012-11-02 02:45:00 +0000
$1030 = 100
$1031 = 1351825200
2012-11-02 03:00:00 +0000
$1032 = 101
$1033 = 1351826100
2012-11-02 03:15:00 +0000
$1034 = 102
$1035 = 1351827000
2012-11-02 03:30:00 +0000
$1036 = 103
$1037 = 1351828800
2012-11-02 04:00:00 +0000
$1038 = 104
$1039 = 1351829700
2012-11-02 04:15:00 +0000
$1040 = 105
$1041 = 1351830600
2012-11-02 04:30:00 +0000
$1042 = 106
$1043 = 1351831500
2012-11-02 04:45:00 +0000
$1044 = 107
$1045 = 1351832400
2012-11-02 05:00:00 +0000
$1046 = 108
$1047 = 1351833300
2012-11-02 05:15:00 +0000
$1048 = 109
$1049 = 1351834200
2012-11-02 05:30:00 +0000
$1050 = 110
$1051 = 1351835100
2012-11-02 05:45:00 +0000
$1052 = 111
$1053 = 1351836000
2012-11-02 06:00:00 +0000
$1054 = 112
$1055 = 1351836900
2012-11-02 06:15:00 +0000
$1056 = 113
$1057 = 1351837800
2012-11-02 06:30:00 +0000
$1058 = 114
$1059 = 1351838700
2012-11-02 06:45:00 +0000
$1060 = 115
$1061 = 1351839600
2012-11-02 07:00:00 +0000
$1062 = 116
$1063 = 1351840500
2012-11-02 07:15:00 +0000
$1064 = 117
$1065 = 1351841400
2012-11-02 07:30:00 +0000
$1066 = 118
$1067 = 1351842300
2012-11-02 07:45:00 +0000
$1068 = 119
$1069 = 1351843200
2012-11-02 08:00:00 +0000
$1070 = 120
$1071 = 1351844100
2012-11-02 08:15:00 +0000
$1072 = 121
$1073 = 1351845000
2012-11-02 08:30:00 +0000
$1074 = 122
$1075 = 1351845900
2012-11-02 08:45:00 +0000
$1076 = 123
$1077 = 1351846800
2012-11-02 09:00:00 +0000
$1078 = 124
$1079 = 1351881000
2012-11-02 18:30:00 +0000
$1080 = 125
$1081 = 1351882800
2012-11-02 19:00:00 +0000
$1082 = 126
$1083 = 1351884600
2012-11-02 19:30:00 +0000
$1084 = 127
$1085 = 1351886400
2012-11-02 20:00:00 +0000
$1086 = 128
$1087 = 1352077200
2012-11-05 01:00:00 +0000
$1088 = 129
$1089 = 1352078100
2012-11-05 01:15:00 +0000
$1090 = 130
$1091 = 1352079000
2012-11-05 01:30:00 +0000
$1092 = 131
$1093 = 1352079900
2012-11-05 01:45:00 +0000
$1094 = 132
$1095 = 1352080800
2012-11-05 02:00:00 +0000
$1096 = 133
$1097 = 1352081700
2012-11-05 02:15:00 +0000
$1098 = 134
$1099 = 1352082600
2012-11-05 02:30:00 +0000
$1100 = 135
$1101 = 1352083500
2012-11-05 02:45:00 +0000
$1102 = 136
$1103 = 1352084400
2012-11-05 03:00:00 +0000
$1104 = 137
$1105 = 1352085300
2012-11-05 03:15:00 +0000
$1106 = 138
$1107 = 1352086200
2012-11-05 03:30:00 +0000
$1108 = 139
$1109 = 1352087100
2012-11-05 03:45:00 +0000
$1110 = 140
$1111 = 1352088000
2012-11-05 04:00:00 +0000
$1112 = 141
$1113 = 1352088900
2012-11-05 04:15:00 +0000
$1114 = 142
$1115 = 1352089800
2012-11-05 04:30:00 +0000
$1116 = 143
$1117 = 1352091600
2012-11-05 05:00:00 +0000
$1118 = 144
$1119 = 1352092500
2012-11-05 05:15:00 +0000
$1120 = 145
$1121 = 1352093400
2012-11-05 05:30:00 +0000
$1122 = 146
$1123 = 1352094300
2012-11-05 05:45:00 +0000
$1124 = 147
$1125 = 1352095200
2012-11-05 06:00:00 +0000
$1126 = 148
$1127 = 1352096100
2012-11-05 06:15:00 +0000
$1128 = 149
$1129 = 1352097000
2012-11-05 06:30:00 +0000
$1130 = 150
$1131 = 1352097900
2012-11-05 06:45:00 +0000
$1132 = 151
$1133 = 1352098800
2012-11-05 07:00:00 +0000
$1134 = 152
$1135 = 1352099700
2012-11-05 07:15:00 +0000
$1136 = 153
$1137 = 1352100600
2012-11-05 07:30:00 +0000
$1138 = 154
$1139 = 1352101500
2012-11-05 07:45:00 +0000
$1140 = 155
$1141 = 1352102400
2012-11-05 08:00:00 +0000
$1142 = 156
$1143 = 1352103300
2012-11-05 08:15:00 +0000
$1144 = 157
$1145 = 1352104200
2012-11-05 08:30:00 +0000
$1146 = 158
$1147 = 1352105100
2012-11-05 08:45:00 +0000
$1148 = 159
$1149 = 1352106000
2012-11-05 09:00:00 +0000
$1150 = 160
$1151 = 1352110500
2012-11-05 10:15:00 +0000
$1152 = 161
$1153 = 1352111400
2012-11-05 10:30:00 +0000
$1154 = 162
$1155 = 1352131200
2012-11-05 16:00:00 +0000
$1156 = 163
$1157 = 1352132100
2012-11-05 16:15:00 +0000
$1158 = 164
$1159 = 1352156400
2012-11-05 23:00:00 +0000
$1160 = 165
$1161 = 1352163600
2012-11-06 01:00:00 +0000
$1162 = 166
$1163 = 1352164500
2012-11-06 01:15:00 +0000
$1164 = 167
$1165 = 1352165400
2012-11-06 01:30:00 +0000
$1166 = 168
$1167 = 1352166300
2012-11-06 01:45:00 +0000
$1168 = 169
$1169 = 1352167200
2012-11-06 02:00:00 +0000
$1170 = 170
$1171 = 1352168100
2012-11-06 02:15:00 +0000
$1172 = 171
$1173 = 1352169000
2012-11-06 02:30:00 +0000
$1174 = 172
$1175 = 1352169900
2012-11-06 02:45:00 +0000
$1176 = 173
$1177 = 1352170800
2012-11-06 03:00:00 +0000
$1178 = 174
$1179 = 1352171700
2012-11-06 03:15:00 +0000
$1180 = 175
$1181 = 1352172600
2012-11-06 03:30:00 +0000
$1182 = 176
$1183 = 1352173500
2012-11-06 03:45:00 +0000
$1184 = 177
$1185 = 1352174400
2012-11-06 04:00:00 +0000
$1186 = 178
$1187 = 1352175300
2012-11-06 04:15:00 +0000
$1188 = 179
$1189 = 1352178000
2012-11-06 05:00:00 +0000
$1190 = 180
$1191 = 1352178900
2012-11-06 05:15:00 +0000
$1192 = 181
$1193 = 1352179800
2012-11-06 05:30:00 +0000
$1194 = 182
$1195 = 1352180700
2012-11-06 05:45:00 +0000
$1196 = 183
$1197 = 1352181600
2012-11-06 06:00:00 +0000
$1198 = 184
$1199 = 1352182500
2012-11-06 06:15:00 +0000
$1200 = 185
$1201 = 1352183400
2012-11-06 06:30:00 +0000
$1202 = 186
$1203 = 1352184300
2012-11-06 06:45:00 +0000
$1204 = 187
$1205 = 1352185200
2012-11-06 07:00:00 +0000
$1206 = 188
$1207 = 1352186100
2012-11-06 07:15:00 +0000
$1208 = 189
$1209 = 1352187000
2012-11-06 07:30:00 +0000
$1210 = 190
$1211 = 1352187900
2012-11-06 07:45:00 +0000
$1212 = 191
$1213 = 1352188800
2012-11-06 08:00:00 +0000
$1214 = 192
$1215 = 1352189700
2012-11-06 08:15:00 +0000
$1216 = 193
$1217 = 1352190600
2012-11-06 08:30:00 +0000
$1218 = 194
$1219 = 1352191500
2012-11-06 08:45:00 +0000
$1220 = 195
$1221 = 1352192400
2012-11-06 09:00:00 +0000
$1222 = 196
(gdb) 
+++++

posted on 2012-12-27 13:28 佳为好友 阅读(693) 评论(0)  编辑 收藏 引用 所属分类: Debug-GDB


只有注册用户登录后才能发表评论。
网站导航: 博客园   IT新闻   BlogJava   博问   Chat2DB   管理


导航

<2012年12月>
2526272829301
2345678
9101112131415
16171819202122
23242526272829
303112345

留言簿(1)

随笔分类

搜索

最新评论

评论排行榜