equal
deleted
inserted
replaced
103 */ |
103 */ |
104 void GetParseRecordData(RBTrace& aTrace, const TTestLogCtrl* apControlStruct = NULL) |
104 void GetParseRecordData(RBTrace& aTrace, const TTestLogCtrl* apControlStruct = NULL) |
105 { |
105 { |
106 TUint8* record; |
106 TUint8* record; |
107 TTraceLayout traceLayout; |
107 TTraceLayout traceLayout; |
|
108 TInt nRecords = 0; |
108 |
109 |
109 for(TInt i=0; ;++i) |
110 for(TInt i=0; ;++i) |
110 { |
111 { |
111 //-- get raw trace record |
112 //-- get raw trace record |
112 TInt dataSize = aTrace.GetData(record); |
113 TInt dataSize = aTrace.GetData(record); |
132 } |
133 } |
133 |
134 |
134 |
135 |
135 TUint8* end = record+dataSize; |
136 TUint8* end = record+dataSize; |
136 TUint8* currPos = record; |
137 TUint8* currPos = record; |
137 TInt nRecords = 0; |
|
138 TUint nBytes = 0; |
138 TUint nBytes = 0; |
139 |
139 |
140 //-- parser the record, print out fields and optionally check the correspondence to the fields of the control structure. |
140 //-- parser the record, print out fields and optionally check the correspondence to the fields of the control structure. |
141 for(; currPos<end; currPos+=nBytes) |
141 for(; currPos<end; currPos+=nBytes) |
142 { |
142 { |
166 test(traceLayout.ipData[1] == apControlStruct->iUserData2); |
166 test(traceLayout.ipData[1] == apControlStruct->iUserData2); |
167 |
167 |
168 } |
168 } |
169 |
169 |
170 } |
170 } |
|
171 |
|
172 //-- release data buffer. |
|
173 aTrace.DataUsed(); |
|
174 } |
171 |
175 |
172 //-- check number of trace records obtained |
176 //-- check number of trace records obtained |
173 if(apControlStruct) |
177 if(apControlStruct) |
174 { |
178 { |
175 test(nRecords == apControlStruct->iLogsNum); |
179 test(nRecords == apControlStruct->iLogsNum); |
176 } |
180 } |
177 |
181 |
178 //-- release data buffer. |
|
179 aTrace.DataUsed(); |
|
180 } |
|
181 } |
182 } |
182 |
183 |
183 |
184 |
184 //--------------------------------------------------------------------------------- |
185 //--------------------------------------------------------------------------------- |
185 |
186 |