-rw-r--r-- | core/apps/embeddedkonsole/TEScreen.cpp | 4 | ||||
-rw-r--r-- | noncore/apps/checkbook/listedit.cpp | 2 | ||||
-rw-r--r-- | noncore/apps/opie-console/TEScreen.cpp | 4 | ||||
-rw-r--r-- | noncore/apps/opie-sheet/Excel.cpp | 2 | ||||
-rw-r--r-- | noncore/apps/tinykate/libkate/document/katedocument.cpp | 4 | ||||
-rw-r--r-- | noncore/comm/keypebble/krfbdecoder.cpp | 6 | ||||
-rw-r--r-- | noncore/games/sfcave/sfcave.cpp | 2 | ||||
-rw-r--r-- | noncore/settings/aqpkg/settingsimpl.cpp | 2 | ||||
-rw-r--r-- | noncore/settings/aqpkg/version.cpp | 2 |
9 files changed, 14 insertions, 14 deletions
diff --git a/core/apps/embeddedkonsole/TEScreen.cpp b/core/apps/embeddedkonsole/TEScreen.cpp index 8e69a88..1db34d2 100644 --- a/core/apps/embeddedkonsole/TEScreen.cpp +++ b/core/apps/embeddedkonsole/TEScreen.cpp | |||
@@ -1133,18 +1133,18 @@ QString TEScreen::getSelText(const BOOL preserve_line_breaks) | |||
1133 | 1133 | ||
1134 | for (int i = 0; i < d; i++) | 1134 | for (int i = 0; i < d; i++) |
1135 | { | 1135 | { |
1136 | qc[i] = m[i]; | 1136 | qc[i] = m[i]; |
1137 | } | 1137 | } |
1138 | 1138 | ||
1139 | QString res(qc, d); | 1139 | QString res(qc, d); |
1140 | 1140 | ||
1141 | delete m; | 1141 | delete [] m; |
1142 | delete qc; | 1142 | delete [] qc; |
1143 | 1143 | ||
1144 | return res; | 1144 | return res; |
1145 | } | 1145 | } |
1146 | /* above ... end of line processing for selection -- psilva | 1146 | /* above ... end of line processing for selection -- psilva |
1147 | cases: | 1147 | cases: |
1148 | 1148 | ||
1149 | 1) (eol+1)%columns == 0 --> the whole line is filled. | 1149 | 1) (eol+1)%columns == 0 --> the whole line is filled. |
1150 | If the last char is a space, insert (preserve) space. otherwise | 1150 | If the last char is a space, insert (preserve) space. otherwise |
diff --git a/noncore/apps/checkbook/listedit.cpp b/noncore/apps/checkbook/listedit.cpp index e40377b..b297d69 100644 --- a/noncore/apps/checkbook/listedit.cpp +++ b/noncore/apps/checkbook/listedit.cpp | |||
@@ -231,17 +231,17 @@ void ListEdit::fixTypes(int iColumn) | |||
231 | } | 231 | } |
232 | lst.sort(); | 232 | lst.sort(); |
233 | 233 | ||
234 | // copy back clean up col map | 234 | // copy back clean up col map |
235 | for(int i=0; i<_typeTable->childCount(); i++) { | 235 | for(int i=0; i<_typeTable->childCount(); i++) { |
236 | colMap[i]->getItem()->setText(iColumn, colMap[i]->getValue()); | 236 | colMap[i]->getItem()->setText(iColumn, colMap[i]->getValue()); |
237 | delete colMap[i]; | 237 | delete colMap[i]; |
238 | } | 238 | } |
239 | delete colMap; | 239 | delete [] colMap; |
240 | } | 240 | } |
241 | 241 | ||
242 | void ListEdit::fixTypes() | 242 | void ListEdit::fixTypes() |
243 | { | 243 | { |
244 | int i; | 244 | int i; |
245 | ColumnDef *pDef; | 245 | ColumnDef *pDef; |
246 | for(pDef=this->first(), i=0; pDef; pDef=this->next(), i++) { | 246 | for(pDef=this->first(), i=0; pDef; pDef=this->next(), i++) { |
247 | if( pDef->hasFlag(ColumnDef::typeUnique) ) | 247 | if( pDef->hasFlag(ColumnDef::typeUnique) ) |
diff --git a/noncore/apps/opie-console/TEScreen.cpp b/noncore/apps/opie-console/TEScreen.cpp index 2675d31..8e91532 100644 --- a/noncore/apps/opie-console/TEScreen.cpp +++ b/noncore/apps/opie-console/TEScreen.cpp | |||
@@ -1110,18 +1110,18 @@ QString TEScreen::getSelText(const BOOL preserve_line_breaks) | |||
1110 | 1110 | ||
1111 | for (int i = 0; i < d; i++) | 1111 | for (int i = 0; i < d; i++) |
1112 | { | 1112 | { |
1113 | qc[i] = m[i]; | 1113 | qc[i] = m[i]; |
1114 | } | 1114 | } |
1115 | 1115 | ||
1116 | QString res(qc, d); | 1116 | QString res(qc, d); |
1117 | 1117 | ||
1118 | delete m; | 1118 | delete [] m; |
1119 | delete qc; | 1119 | delete [] qc; |
1120 | 1120 | ||
1121 | return res; | 1121 | return res; |
1122 | } | 1122 | } |
1123 | QString TEScreen::getHistory() { | 1123 | QString TEScreen::getHistory() { |
1124 | sel_begin = 0; | 1124 | sel_begin = 0; |
1125 | sel_BR = sel_begin; | 1125 | sel_BR = sel_begin; |
1126 | sel_TL = sel_begin; | 1126 | sel_TL = sel_begin; |
1127 | setSelExtentXY(columns-1,lines-1); | 1127 | setSelExtentXY(columns-1,lines-1); |
diff --git a/noncore/apps/opie-sheet/Excel.cpp b/noncore/apps/opie-sheet/Excel.cpp index 338bc30..51fe707 100644 --- a/noncore/apps/opie-sheet/Excel.cpp +++ b/noncore/apps/opie-sheet/Excel.cpp | |||
@@ -333,17 +333,17 @@ int ExcelBook::SeekBOF(void) | |||
333 | opcode=Get2Bytes(); | 333 | opcode=Get2Bytes(); |
334 | if(opcode==XL_BOF) | 334 | if(opcode==XL_BOF) |
335 | { | 335 | { |
336 | length=Get2Bytes(); | 336 | length=Get2Bytes(); |
337 | data=Read(Position,length); | 337 | data=Read(Position,length); |
338 | version=Integer2Byte(data[0], data[1]); | 338 | version=Integer2Byte(data[0], data[1]); |
339 | streamtype=Integer2Byte(data[2], data[3]); | 339 | streamtype=Integer2Byte(data[2], data[3]); |
340 | printf("SEEKBOF:opcode=XLBOF, %d ,version %d\r\n",Position,version); | 340 | printf("SEEKBOF:opcode=XLBOF, %d ,version %d\r\n",Position,version); |
341 | delete data; data=NULL; | 341 | delete [] data; data=NULL; |
342 | if (version==BIFF8) ret=8; | 342 | if (version==BIFF8) ret=8; |
343 | else if(version==BIFF7) ret=7; | 343 | else if(version==BIFF7) ret=7; |
344 | printf("SEEKBOF:versionBIFF%d\r\n",ret); | 344 | printf("SEEKBOF:versionBIFF%d\r\n",ret); |
345 | if(streamtype==WBKGLOBAL) return ret *2; | 345 | if(streamtype==WBKGLOBAL) return ret *2; |
346 | else if(streamtype==WRKSHEET) return ret *1; | 346 | else if(streamtype==WRKSHEET) return ret *1; |
347 | return 1; | 347 | return 1; |
348 | }; | 348 | }; |
349 | }; | 349 | }; |
diff --git a/noncore/apps/tinykate/libkate/document/katedocument.cpp b/noncore/apps/tinykate/libkate/document/katedocument.cpp index 6dc4fd2..a70f3aa 100644 --- a/noncore/apps/tinykate/libkate/document/katedocument.cpp +++ b/noncore/apps/tinykate/libkate/document/katedocument.cpp | |||
@@ -2214,17 +2214,17 @@ bool KateDocument::doSearch(SConfig &sc, const QString &searchFor) { | |||
2214 | } | 2214 | } |
2215 | searchEnd = selectEnd; | 2215 | searchEnd = selectEnd; |
2216 | } else searchEnd = lastLine(); | 2216 | } else searchEnd = lastLine(); |
2217 | 2217 | ||
2218 | while (line <= searchEnd) { | 2218 | while (line <= searchEnd) { |
2219 | textLine = getTextLine(line); | 2219 | textLine = getTextLine(line); |
2220 | tlen = textLine->length(); | 2220 | tlen = textLine->length(); |
2221 | if (tlen > bufLen) { | 2221 | if (tlen > bufLen) { |
2222 | delete t; | 2222 | delete [] t; |
2223 | bufLen = (tlen + 255) & (~255); | 2223 | bufLen = (tlen + 255) & (~255); |
2224 | t = new QChar[bufLen]; | 2224 | t = new QChar[bufLen]; |
2225 | } | 2225 | } |
2226 | memcpy(t, textLine->getText(), tlen*sizeof(QChar)); | 2226 | memcpy(t, textLine->getText(), tlen*sizeof(QChar)); |
2227 | if (sc.flags & KateView::sfSelected) { | 2227 | if (sc.flags & KateView::sfSelected) { |
2228 | pos = 0; | 2228 | pos = 0; |
2229 | do { | 2229 | do { |
2230 | pos = textLine->findSelected(pos); | 2230 | pos = textLine->findSelected(pos); |
@@ -2275,17 +2275,17 @@ bool KateDocument::doSearch(SConfig &sc, const QString &searchFor) { | |||
2275 | } | 2275 | } |
2276 | searchEnd = selectStart; | 2276 | searchEnd = selectStart; |
2277 | } else searchEnd = 0; | 2277 | } else searchEnd = 0; |
2278 | 2278 | ||
2279 | while (line >= searchEnd) { | 2279 | while (line >= searchEnd) { |
2280 | textLine = getTextLine(line); | 2280 | textLine = getTextLine(line); |
2281 | tlen = textLine->length(); | 2281 | tlen = textLine->length(); |
2282 | if (tlen > bufLen) { | 2282 | if (tlen > bufLen) { |
2283 | delete t; | 2283 | delete [] t; |
2284 | bufLen = (tlen + 255) & (~255); | 2284 | bufLen = (tlen + 255) & (~255); |
2285 | t = new QChar[bufLen]; | 2285 | t = new QChar[bufLen]; |
2286 | } | 2286 | } |
2287 | memcpy(t, textLine->getText(), tlen*sizeof(QChar)); | 2287 | memcpy(t, textLine->getText(), tlen*sizeof(QChar)); |
2288 | if (sc.flags & KateView::sfSelected) { | 2288 | if (sc.flags & KateView::sfSelected) { |
2289 | pos = 0; | 2289 | pos = 0; |
2290 | do { | 2290 | do { |
2291 | pos = textLine->findSelected(pos); | 2291 | pos = textLine->findSelected(pos); |
diff --git a/noncore/comm/keypebble/krfbdecoder.cpp b/noncore/comm/keypebble/krfbdecoder.cpp index 837fcc5..27ae101 100644 --- a/noncore/comm/keypebble/krfbdecoder.cpp +++ b/noncore/comm/keypebble/krfbdecoder.cpp | |||
@@ -220,17 +220,17 @@ void KRFBDecoder::gotDesktopName() | |||
220 | CHECK_PTR( buf ); | 220 | CHECK_PTR( buf ); |
221 | 221 | ||
222 | con->read( buf, info->nameLength ); | 222 | con->read( buf, info->nameLength ); |
223 | buf[ info->nameLength ] = '\0'; | 223 | buf[ info->nameLength ] = '\0'; |
224 | info->name = buf; | 224 | info->name = buf; |
225 | 225 | ||
226 | owarn << "Desktop: " << info->name.latin1() << "" << oendl; | 226 | owarn << "Desktop: " << info->name.latin1() << "" << oendl; |
227 | 227 | ||
228 | delete buf; | 228 | delete [] buf; |
229 | 229 | ||
230 | // Get the format we'll really use and tell the server | 230 | // Get the format we'll really use and tell the server |
231 | decidePixelFormat(); | 231 | decidePixelFormat(); |
232 | sendPixelFormat(); | 232 | sendPixelFormat(); |
233 | sendAllowedEncodings(); | 233 | sendAllowedEncodings(); |
234 | currentState = Idle; | 234 | currentState = Idle; |
235 | 235 | ||
236 | QString msg; | 236 | QString msg; |
@@ -530,17 +530,17 @@ void KRFBDecoder::gotRawRectChunk() | |||
530 | // Read the rect data and copy it to the buffer. | 530 | // Read the rect data and copy it to the buffer. |
531 | // | 531 | // |
532 | 532 | ||
533 | // TODO: Replace this! | 533 | // TODO: Replace this! |
534 | int count = lines * w * format->bpp / 8; | 534 | int count = lines * w * format->bpp / 8; |
535 | char *hack = new char[ count ]; | 535 | char *hack = new char[ count ]; |
536 | con->read( hack, count ); | 536 | con->read( hack, count ); |
537 | buf->drawRawRectChunk( hack, x, y, w, lines ); | 537 | buf->drawRawRectChunk( hack, x, y, w, lines ); |
538 | delete hack; | 538 | delete [] hack; |
539 | // /TODO: | 539 | // /TODO: |
540 | 540 | ||
541 | h = h - lines; | 541 | h = h - lines; |
542 | y = y + lines; | 542 | y = y + lines; |
543 | 543 | ||
544 | if ( h > 0 ) { | 544 | if ( h > 0 ) { |
545 | handleRawRect(); | 545 | handleRawRect(); |
546 | } | 546 | } |
@@ -723,17 +723,17 @@ void KRFBDecoder::gotServerCutText() | |||
723 | /* For some reason QApplication::clipboard()->setText() segfaults when called | 723 | /* For some reason QApplication::clipboard()->setText() segfaults when called |
724 | * from within keypebble's mass of signals and slots | 724 | * from within keypebble's mass of signals and slots |
725 | owarn << "Server cut: " << cutbuf << "" << oendl; | 725 | owarn << "Server cut: " << cutbuf << "" << oendl; |
726 | 726 | ||
727 | QString cutText( cutbuf ); // DANGER!! | 727 | QString cutText( cutbuf ); // DANGER!! |
728 | qApp->clipboard()->setText( cutText ); | 728 | qApp->clipboard()->setText( cutText ); |
729 | */ | 729 | */ |
730 | 730 | ||
731 | delete cutbuf; | 731 | delete [] cutbuf; |
732 | // Now wait for the update (again) | 732 | // Now wait for the update (again) |
733 | if ( oldState == AwaitingUpdate ) { | 733 | if ( oldState == AwaitingUpdate ) { |
734 | currentState = AwaitingUpdate; | 734 | currentState = AwaitingUpdate; |
735 | connect( con, SIGNAL( gotEnoughData() ), SLOT( gotUpdateHeader() ) ); | 735 | connect( con, SIGNAL( gotEnoughData() ), SLOT( gotUpdateHeader() ) ); |
736 | con->waitForData( UpdateHeaderLength ); | 736 | con->waitForData( UpdateHeaderLength ); |
737 | } | 737 | } |
738 | else if ( oldState == Idle ) { | 738 | else if ( oldState == Idle ) { |
739 | currentState = Idle; | 739 | currentState = Idle; |
diff --git a/noncore/games/sfcave/sfcave.cpp b/noncore/games/sfcave/sfcave.cpp index a6c92a0..516dc93 100644 --- a/noncore/games/sfcave/sfcave.cpp +++ b/noncore/games/sfcave/sfcave.cpp | |||
@@ -993,17 +993,17 @@ void SFCave :: loadReplay() | |||
993 | 993 | ||
994 | replayList.clear(); | 994 | replayList.clear(); |
995 | for ( ; it != list.end(); ++it ) | 995 | for ( ; it != list.end(); ++it ) |
996 | { | 996 | { |
997 | int v = (*it).toInt(); | 997 | int v = (*it).toInt(); |
998 | replayList.append( new int( v ) ); | 998 | replayList.append( new int( v ) ); |
999 | } | 999 | } |
1000 | 1000 | ||
1001 | delete data; | 1001 | delete [] data; |
1002 | 1002 | ||
1003 | fclose( in ); | 1003 | fclose( in ); |
1004 | 1004 | ||
1005 | printf( "Replay loaded from %s\n", QFile::encodeName(replayFile).data() ); | 1005 | printf( "Replay loaded from %s\n", QFile::encodeName(replayFile).data() ); |
1006 | } | 1006 | } |
1007 | 1007 | ||
1008 | 1008 | ||
1009 | //--------------- MENU CODE --------------------- | 1009 | //--------------- MENU CODE --------------------- |
diff --git a/noncore/settings/aqpkg/settingsimpl.cpp b/noncore/settings/aqpkg/settingsimpl.cpp index 7ffa1d6..0886e69 100644 --- a/noncore/settings/aqpkg/settingsimpl.cpp +++ b/noncore/settings/aqpkg/settingsimpl.cpp | |||
@@ -342,17 +342,17 @@ void SettingsImpl :: changeServerDetails() | |||
342 | if ( newName[i] == ' ' ) | 342 | if ( newName[i] == ' ' ) |
343 | tmpStr[i] = '_'; | 343 | tmpStr[i] = '_'; |
344 | else | 344 | else |
345 | tmpStr[i] = newName[i].latin1(); | 345 | tmpStr[i] = newName[i].latin1(); |
346 | } | 346 | } |
347 | tmpStr[newName.length()] = '\0'; | 347 | tmpStr[newName.length()] = '\0'; |
348 | 348 | ||
349 | newName = tmpStr; | 349 | newName = tmpStr; |
350 | delete tmpStr; | 350 | delete [] tmpStr; |
351 | 351 | ||
352 | if ( !newserver ) | 352 | if ( !newserver ) |
353 | { | 353 | { |
354 | Server *s = dataMgr->getServer( servers->currentText() ); | 354 | Server *s = dataMgr->getServer( servers->currentText() ); |
355 | if ( s ) | 355 | if ( s ) |
356 | { | 356 | { |
357 | // Update url | 357 | // Update url |
358 | s->setServerUrl( serverurl->text() ); | 358 | s->setServerUrl( serverurl->text() ); |
diff --git a/noncore/settings/aqpkg/version.cpp b/noncore/settings/aqpkg/version.cpp index 59e6f3f..ce2de7b 100644 --- a/noncore/settings/aqpkg/version.cpp +++ b/noncore/settings/aqpkg/version.cpp | |||
@@ -33,17 +33,17 @@ public: | |||
33 | versionrevision() | 33 | versionrevision() |
34 | { | 34 | { |
35 | version = 0; | 35 | version = 0; |
36 | } | 36 | } |
37 | 37 | ||
38 | ~versionrevision() | 38 | ~versionrevision() |
39 | { | 39 | { |
40 | if ( version ) | 40 | if ( version ) |
41 | delete version; | 41 | delete [] version; |
42 | } | 42 | } |
43 | 43 | ||
44 | void setVersion( const char *str ) | 44 | void setVersion( const char *str ) |
45 | { | 45 | { |
46 | version = new char[(strlen(str)+1)]; | 46 | version = new char[(strlen(str)+1)]; |
47 | strcpy( version, str ); | 47 | strcpy( version, str ); |
48 | } | 48 | } |
49 | 49 | ||