From 5c6b9eb00d0d623c12f72eb82a471cb4c71f4f33 Mon Sep 17 00:00:00 2001 From: Jerome Duval Date: Thu, 23 Feb 2012 20:26:18 +0100 Subject: [PATCH] Some fixes for GCC 4.6 warning: variable set but not used --- src/apps/mail/ComboBox.cpp | 3 --- src/apps/mail/Content.cpp | 3 +-- src/apps/mail/KUndoBuffer.cpp | 7 ++++--- src/apps/mediaconverter/MediaConverterApp.cpp | 4 +--- .../video/VideoProducer.cpp | 2 -- src/apps/poorman/PoorManPreferencesWindow.cpp | 15 +++++---------- src/apps/poorman/PoorManServer.cpp | 12 +++--------- src/apps/processcontroller/Preferences.cpp | 3 +-- src/apps/showimage/Filter.cpp | 3 +-- src/apps/terminal/AppearPrefView.cpp | 2 -- src/apps/terminal/TermParse.cpp | 4 ++-- src/bin/dstcheck.cpp | 2 -- src/bin/error.c | 1 - src/bin/fdinfo.cpp | 2 +- src/kits/media/SoundPlayer.cpp | 4 ---- src/kits/tracker/FSUtils.cpp | 3 --- src/kits/tracker/FindPanel.cpp | 18 ++++++++++-------- src/kits/tracker/MountMenu.cpp | 2 -- src/kits/tracker/OpenWithWindow.cpp | 2 -- src/kits/tracker/RecentItems.cpp | 6 +++--- src/kits/tracker/SlowContextPopup.cpp | 12 ++++++------ src/kits/tracker/TrackerInitialState.cpp | 4 ++-- .../shortcuts/clv/CLVColumnLabelView.cpp | 6 ------ .../Painter/drawing_modes/DrawingModeInvert.h | 1 + .../drawing_modes/DrawingModeInvertSUBPIX.h | 1 + src/servers/app/font/GlyphLayoutEngine.h | 4 ++-- src/servers/notification/AppGroupView.cpp | 1 - 27 files changed, 44 insertions(+), 83 deletions(-) diff --git a/src/apps/mail/ComboBox.cpp b/src/apps/mail/ComboBox.cpp index a9c60f34fa..68abfcd741 100644 --- a/src/apps/mail/ComboBox.cpp +++ b/src/apps/mail/ComboBox.cpp @@ -1417,7 +1417,6 @@ BComboBox::Draw(BRect /*updateRect*/) BRect bounds = Bounds(); font_height fInfo; rgb_color high = HighColor(); - rgb_color low = LowColor(); rgb_color base = ViewColor(); bool focused; bool enabled; @@ -1474,8 +1473,6 @@ BComboBox::Draw(BRect /*updateRect*/) StrokeRect(fr); SetHighColor(high); - rgb_color oldCol = HighColor(); - bounds.right = bounds.left + fDivider; if ((Label()) && (fDivider > 0.0)) { BPoint loc; diff --git a/src/apps/mail/Content.cpp b/src/apps/mail/Content.cpp index 28a3687580..036e77f484 100644 --- a/src/apps/mail/Content.cpp +++ b/src/apps/mail/Content.cpp @@ -1550,9 +1550,8 @@ TTextView::MouseDown(BPoint where) BMenuItem *menuItem; BPopUpMenu menu("Words", false, false); - int32 matchCount; for (int32 i = 0; i < gDictCount; i++) - matchCount = gWords[i]->FindBestMatches(&matches, + gWords[i]->FindBestMatches(&matches, srcWord.String()); if (matches.CountItems()) { diff --git a/src/apps/mail/KUndoBuffer.cpp b/src/apps/mail/KUndoBuffer.cpp index 5babccb763..37729c57ba 100644 --- a/src/apps/mail/KUndoBuffer.cpp +++ b/src/apps/mail/KUndoBuffer.cpp @@ -131,9 +131,10 @@ status_t KUndoBuffer::AddUndo(const char* text, int32 length, int32 offset, undo_type history, int32 cursor_pos) { - if (fNoTouch) return B_OK; + if (fNoTouch) + return B_OK; - status_t status; + status_t status = B_OK; if (fNewItem || (fIndex < CountItems()) || (CountItems()==0)) { status = NewUndo(text, length, offset, history, cursor_pos); @@ -167,7 +168,7 @@ KUndoBuffer::AddUndo(const char* text, int32 length, int32 offset, } } - return B_OK; + return status; } diff --git a/src/apps/mediaconverter/MediaConverterApp.cpp b/src/apps/mediaconverter/MediaConverterApp.cpp index 24354a9beb..14419668b4 100644 --- a/src/apps/mediaconverter/MediaConverterApp.cpp +++ b/src/apps/mediaconverter/MediaConverterApp.cpp @@ -359,8 +359,6 @@ MediaConverterApp::_ConvertFile(BMediaFile* inFile, BMediaFile* outFile, int32 width = -1; int32 height = -1; - short audioFrameSize = 1; - uint8* videoBuffer = NULL; uint8* audioBuffer = NULL; @@ -384,7 +382,7 @@ MediaConverterApp::_ConvertFile(BMediaFile* inFile, BMediaFile* outFile, audioBuffer = new uint8[raf->buffer_size]; // audioFrameSize = (raf->format & media_raw_audio_format::B_AUDIO_SIZE_MASK) - audioFrameSize = (raf->format & 0xf) * raf->channel_count; +// audioFrameSize = (raf->format & 0xf) * raf->channel_count; outAudTrack = outFile->CreateTrack(&outAudFormat, audioCodec); if (outAudTrack != NULL) { diff --git a/src/apps/mediaplayer/media_node_framework/video/VideoProducer.cpp b/src/apps/mediaplayer/media_node_framework/video/VideoProducer.cpp index 063e63d445..a8a28befb5 100644 --- a/src/apps/mediaplayer/media_node_framework/video/VideoProducer.cpp +++ b/src/apps/mediaplayer/media_node_framework/video/VideoProducer.cpp @@ -634,7 +634,6 @@ VideoProducer::_FrameGeneratorThread() bigtime_t waitUntil = 0; bigtime_t nextWaitUntil = 0; int32 playingDirection = 0; - int32 playingMode = 0; int64 playlistFrame = 0; switch (err) { case B_OK: { @@ -645,7 +644,6 @@ VideoProducer::_FrameGeneratorThread() // get the times for the current and the next frame performanceTime = fManager->TimeForFrame(fFrame); nextPerformanceTime = fManager->TimeForFrame(fFrame + 1); - playingMode = fManager->PlayModeAtFrame(fFrame); waitUntil = TimeSource()->RealTimeFor(fPerformanceTimeBase + performanceTime, fBufferLatency); nextWaitUntil = TimeSource()->RealTimeFor(fPerformanceTimeBase diff --git a/src/apps/poorman/PoorManPreferencesWindow.cpp b/src/apps/poorman/PoorManPreferencesWindow.cpp index 94667bad21..1ceb036aaf 100644 --- a/src/apps/poorman/PoorManPreferencesWindow.cpp +++ b/src/apps/poorman/PoorManPreferencesWindow.cpp @@ -218,17 +218,12 @@ PoorManPreferencesWindow::SelectWebDir(BMessage * message) const char * name; BPath path; BEntry entry; - status_t err = B_OK; - err = message->FindRef("refs", &ref) != B_OK; - //if (err = message->FindRef("directory", &ref) != B_OK) - //return err; - err = message->FindString("name", &name) != B_OK; - //if (err = message->FindString("name", &name) != B_OK) - // ;//return err; - err = entry.SetTo(&ref) != B_OK; - //if (err = entry.SetTo(&ref) != B_OK) - // ;//return err; + if (message->FindRef("refs", &ref) != B_OK + || message->FindString("name", &name) != B_OK + || entry.SetTo(&ref) != B_OK) { + return; + } entry.GetPath(&path); PRINT(("DIR: %s\n", path.Path())); diff --git a/src/apps/poorman/PoorManServer.cpp b/src/apps/poorman/PoorManServer.cpp index 3c433c2795..dacc2ac013 100644 --- a/src/apps/poorman/PoorManServer.cpp +++ b/src/apps/poorman/PoorManServer.cpp @@ -350,25 +350,19 @@ cleanup: ; status_t PoorManServer::_HandleGet(httpd_conn* hc) { PRINT(("HandleGet() called\n")); - - off_t length; + ssize_t bytesRead; uint8* buf; BString log; - + BFile file(hc->expnfilename, B_READ_ONLY); if (file.InitCheck() != B_OK) return B_ERROR; - + buf = new uint8[POOR_MAN_BUF_SIZE]; if (buf == NULL) return B_ERROR; - if (hc->got_range == 1) - length = hc->last_byte_index + 1 - hc->first_byte_index; - else - length = hc->sb.st_size; - static_cast(be_app)->GetPoorManWindow()->SetHits( static_cast(be_app)-> GetPoorManWindow()->GetHits() + 1); diff --git a/src/apps/processcontroller/Preferences.cpp b/src/apps/processcontroller/Preferences.cpp index 15b49d9dba..e7fd7b9da5 100644 --- a/src/apps/processcontroller/Preferences.cpp +++ b/src/apps/processcontroller/Preferences.cpp @@ -89,14 +89,13 @@ Preferences::~Preferences() { if (fSavePreferences) { BFile file; - status_t set = B_ERROR; if (fSettingsFile) file.SetTo(fSettingsFile, B_READ_WRITE | B_CREATE_FILE | B_ERASE_FILE); else { BPath prefpath; if (find_directory(B_USER_SETTINGS_DIRECTORY, &prefpath, true) == B_OK) { BDirectory prefdir(prefpath.Path()); - set = prefdir.CreateFile(fName, &file, false); + prefdir.CreateFile(fName, &file, false); } } diff --git a/src/apps/showimage/Filter.cpp b/src/apps/showimage/Filter.cpp index 3d9f65bb88..17678b53db 100644 --- a/src/apps/showimage/Filter.cpp +++ b/src/apps/showimage/Filter.cpp @@ -731,7 +731,7 @@ Scaler::Dither(int32 fromRow, int32 toRow) { BBitmap* src; BBitmap* dest; - intType destW, destH; + intType destW; intType x, y; uchar* srcBits; @@ -759,7 +759,6 @@ Scaler::Dither(int32 fromRow, int32 toRow) ASSERT(src->Bounds().IntegerHeight() == dest->Bounds().IntegerHeight()); destW = dest->Bounds().IntegerWidth(); - destH = dest->Bounds().IntegerHeight(); srcBits = (uchar*)src->Bits(); srcBPR = src->BytesPerRow(); diff --git a/src/apps/terminal/AppearPrefView.cpp b/src/apps/terminal/AppearPrefView.cpp index 64eb813c5a..75b87848f7 100644 --- a/src/apps/terminal/AppearPrefView.cpp +++ b/src/apps/terminal/AppearPrefView.cpp @@ -380,12 +380,10 @@ AppearancePrefView::_SetCurrentColorSchema(BMenuField* field) schemas++; } - bool found = false; for (int32 i = 0; i < fColorSchemaField->Menu()->CountItems(); i++) { BMenuItem* item = fColorSchemaField->Menu()->ItemAt(i); if (!strcmp(item->Label(), currentSchemaName)) { item->SetMarked(true); - found = true; break; } } diff --git a/src/apps/terminal/TermParse.cpp b/src/apps/terminal/TermParse.cpp index 856e12dcd0..e5600c3b87 100644 --- a/src/apps/terminal/TermParse.cpp +++ b/src/apps/terminal/TermParse.cpp @@ -361,7 +361,7 @@ TermParse::EscParse() { int top; int bottom; - int cs96 = 0; +// int cs96 = 0; uchar curess = 0; char cbuf[4] = { 0 }; @@ -586,7 +586,7 @@ TermParse::EscParse() case CASE_GSETS: /* ESC $ ? */ parsestate = gCS96GroundTable; - cs96 = 1; + // cs96 = 1; break; case CASE_SCS_STATE: diff --git a/src/bin/dstcheck.cpp b/src/bin/dstcheck.cpp index 32eb98aaff..90715ae8ad 100644 --- a/src/bin/dstcheck.cpp +++ b/src/bin/dstcheck.cpp @@ -112,11 +112,9 @@ main(int argc, char **argv) } strcat(path, "/time_dststatus"); - bool newFile = false; bool dst = false; int fd = open(path, O_RDWR | O_EXCL | O_CREAT, S_IRUSR | S_IWUSR); if (fd < 0) { - newFile = false; fd = open(path, O_RDWR); if (fd < 0) { perror("couldn't open dst status settings file"); diff --git a/src/bin/error.c b/src/bin/error.c index 5db4b329f6..ff2b98c8d5 100644 --- a/src/bin/error.c +++ b/src/bin/error.c @@ -310,7 +310,6 @@ print_error(char *number) if (end[0]) { // not a number, check names - int i; struct error_pair *p = kErrorNames; while (p->name && strcmp(p->name, number)) p++; diff --git a/src/bin/fdinfo.cpp b/src/bin/fdinfo.cpp index 97036666f2..2ac12e071a 100644 --- a/src/bin/fdinfo.cpp +++ b/src/bin/fdinfo.cpp @@ -174,7 +174,7 @@ main(int argc, char **argv) switch (mode) { case kList: if ((id != -1 && id != info.team) - || pattern != NULL && !strstr(info.args, pattern)) + || (pattern != NULL && !strstr(info.args, pattern))) continue; print_fds(info); break; diff --git a/src/kits/media/SoundPlayer.cpp b/src/kits/media/SoundPlayer.cpp index c37d400328..42db720bca 100644 --- a/src/kits/media/SoundPlayer.cpp +++ b/src/kits/media/SoundPlayer.cpp @@ -121,24 +121,20 @@ BSoundPlayer::~BSoundPlayer() // nodes that we're using. We *are* supposed to do that even for global // nodes like the Mixer. err = roster->Disconnect(fMediaOutput, fMediaInput); -#if DEBUG > 0 if (err != B_OK) { TRACE("BSoundPlayer::~BSoundPlayer: Error disconnecting nodes: " "%ld (%s)\n", err, strerror(err)); } -#endif } if ((fFlags & F_MUST_RELEASE_MIXER) != 0) { // Release the mixer as it was acquired // through BMediaRoster::GetAudioMixer() err = roster->ReleaseNode(fMediaInput.node); -#if DEBUG > 0 if (err != B_OK) { TRACE("BSoundPlayer::~BSoundPlayer: Error releasing input node: " "%ld (%s)\n", err, strerror(err)); } -#endif } cleanup: diff --git a/src/kits/tracker/FSUtils.cpp b/src/kits/tracker/FSUtils.cpp index 150225bb33..f85df2dbc2 100644 --- a/src/kits/tracker/FSUtils.cpp +++ b/src/kits/tracker/FSUtils.cpp @@ -870,7 +870,6 @@ MoveTask(BObjectList *srcList, BEntry *destEntry, BList *pointList, StatStruct deststat; BVolume volume(srcVolumeDevice); entry_ref destRef; - const entry_ref *destRefToCheck = NULL; bool destIsTrash = false; BDirectory destDir; @@ -885,7 +884,6 @@ MoveTask(BObjectList *srcList, BEntry *destEntry, BList *pointList, // if we're not passed a destEntry then we are supposed to move to trash if (destEntry != NULL) { destEntry->GetRef(&destRef); - destRefToCheck = &destRef; destDir.SetTo(destEntry); destDir.GetStat(&deststat); @@ -913,7 +911,6 @@ MoveTask(BObjectList *srcList, BEntry *destEntry, BList *pointList, destDirToCheck = &destDir; entry.GetRef(&destRef); - destRefToCheck = &destRef; } // change the move mode if needed diff --git a/src/kits/tracker/FindPanel.cpp b/src/kits/tracker/FindPanel.cpp index e2264c1981..f2a1a12551 100644 --- a/src/kits/tracker/FindPanel.cpp +++ b/src/kits/tracker/FindPanel.cpp @@ -433,10 +433,12 @@ FindWindow::SaveQueryAsAttributes(BNode *file, BEntry *entry, bool queryTemplate ssize_t size = message.FlattenedSize(); BString buffer; status_t result = message.Flatten(buffer.LockBuffer(size), size); - ASSERT(result == B_OK); - result = file->WriteAttr(kAttrQueryVolume, B_MESSAGE_TYPE, 0, - buffer.String(), (size_t)size); - ASSERT(result == size); + if (result == B_OK) { + if (file->WriteAttr(kAttrQueryVolume, B_MESSAGE_TYPE, 0, + buffer.String(), (size_t)size) != size) { + return B_IO_ERROR; + } + } buffer.UnlockBuffer(); } // default to query for everything @@ -2068,10 +2070,10 @@ FindPanel::SaveWindowState(BNode *node, bool editTemplate) ssize_t size = message.FlattenedSize(); char *buffer = new char[size]; status_t result = message.Flatten(buffer, size); - ASSERT(result == B_OK); - result = node->WriteAttr(kAttrQueryInitialAttrs, B_MESSAGE_TYPE, 0, - buffer, (size_t)size); - ASSERT(result == size); + if (result == B_OK) { + node->WriteAttr(kAttrQueryInitialAttrs, B_MESSAGE_TYPE, 0, + buffer, (size_t)size); + } delete [] buffer; } break; diff --git a/src/kits/tracker/MountMenu.cpp b/src/kits/tracker/MountMenu.cpp index 24e1eb55d1..ea124ea20c 100644 --- a/src/kits/tracker/MountMenu.cpp +++ b/src/kits/tracker/MountMenu.cpp @@ -190,10 +190,8 @@ MountMenu::AddDynamicItem(add_state) // by the autoMounter because they do not show up in the /dev tree BVolumeRoster volumeRoster; BVolume volume; - bool needSeparator = false; while (volumeRoster.GetNextVolume(&volume) == B_OK) { if (volume.IsShared()) { - needSeparator = true; BBitmap *icon = new BBitmap(BRect(0, 0, 15, 15), B_CMAP8); fs_info info; if (fs_stat_dev(volume.Device(), &info) != B_OK) { diff --git a/src/kits/tracker/OpenWithWindow.cpp b/src/kits/tracker/OpenWithWindow.cpp index 8bc53857e4..cda26cb805 100644 --- a/src/kits/tracker/OpenWithWindow.cpp +++ b/src/kits/tracker/OpenWithWindow.cpp @@ -592,7 +592,6 @@ AddOneRefSignatures(const entry_ref *ref, void *castToIterator) // if model is of unknown type, try mimeseting it first model.Mimeset(true); - bool preferredAppFromNode = false; entry_ref preferredRef; // add preferred app for file, if any @@ -600,7 +599,6 @@ AddOneRefSignatures(const entry_ref *ref, void *castToIterator) // got one, mark it as preferred for this node if (be_roster->FindApp(model.PreferredAppSignature(), &preferredRef) == B_OK) { queryIterator->PushUniqueSignature(model.PreferredAppSignature()); - preferredAppFromNode = true; queryIterator->TrySettingPreferredAppForFile(&preferredRef); } } diff --git a/src/kits/tracker/RecentItems.cpp b/src/kits/tracker/RecentItems.cpp index 53ca018ae4..1b8c8cd036 100644 --- a/src/kits/tracker/RecentItems.cpp +++ b/src/kits/tracker/RecentItems.cpp @@ -284,11 +284,11 @@ BRecentItemsList::GetNextMenuItem(const BMessage *fileOpenInvokeMessage, // open the model, if it ain't open already PoseInfo poseInfo; - ssize_t size = -1; - if (result->Node()) - size = result->Node()->ReadAttr(kAttrPoseInfo, B_RAW_TYPE, 0, + if (result->Node()) { + result->Node()->ReadAttr(kAttrPoseInfo, B_RAW_TYPE, 0, &poseInfo, sizeof(poseInfo)); + } result->CloseNode(); diff --git a/src/kits/tracker/SlowContextPopup.cpp b/src/kits/tracker/SlowContextPopup.cpp index 6a12c9def3..5c9ec17b06 100644 --- a/src/kits/tracker/SlowContextPopup.cpp +++ b/src/kits/tracker/SlowContextPopup.cpp @@ -320,12 +320,12 @@ BSlowContextMenu::AddNextItem() return true; } - ssize_t size = -1; PoseInfo poseInfo; - if (model.Node()) - size = model.Node()->ReadAttr(kAttrPoseInfo, B_RAW_TYPE, 0, + if (model.Node()) { + model.Node()->ReadAttr(kAttrPoseInfo, B_RAW_TYPE, 0, &poseInfo, sizeof(poseInfo)); + } model.CloseNode(); @@ -384,11 +384,11 @@ BSlowContextMenu::NewModelItem(Model *model, const BMessage *invokeMessage, // open the model, if it ain't open already PoseInfo poseInfo; - ssize_t size = -1; - if (result->Node()) - size = result->Node()->ReadAttr(kAttrPoseInfo, B_RAW_TYPE, 0, + if (result->Node()) { + result->Node()->ReadAttr(kAttrPoseInfo, B_RAW_TYPE, 0, &poseInfo, sizeof(poseInfo)); + } result->CloseNode(); diff --git a/src/kits/tracker/TrackerInitialState.cpp b/src/kits/tracker/TrackerInitialState.cpp index a6a3251d84..bfaf138364 100644 --- a/src/kits/tracker/TrackerInitialState.cpp +++ b/src/kits/tracker/TrackerInitialState.cpp @@ -544,8 +544,8 @@ TTracker::InstallIndices() void TTracker::InstallIndices(dev_t device) { - status_t error = fs_create_index(device, kAttrQueryLastChange, B_INT32_TYPE, 0); - error = fs_create_index(device, "_trk/recentQuery", B_INT32_TYPE, 0); + fs_create_index(device, kAttrQueryLastChange, B_INT32_TYPE, 0); + fs_create_index(device, "_trk/recentQuery", B_INT32_TYPE, 0); } diff --git a/src/preferences/shortcuts/clv/CLVColumnLabelView.cpp b/src/preferences/shortcuts/clv/CLVColumnLabelView.cpp index 82819eb853..e1ea8cc3b6 100644 --- a/src/preferences/shortcuts/clv/CLVColumnLabelView.cpp +++ b/src/preferences/shortcuts/clv/CLVColumnLabelView.cpp @@ -538,7 +538,6 @@ void CLVColumnLabelView::ShiftDragGroup(int32 NewPos) int32 NumberOfGroups = fDragGroups.CountItems(); int32 GroupCounter; CLVDragGroup* ThisGroup; - int32 NumberOfColumnsInGroup; int32 ColumnCounter; BList NewDisplayList; @@ -548,8 +547,6 @@ void CLVColumnLabelView::ShiftDragGroup(int32 NewPos) if(GroupCounter != fDragGroup) { ThisGroup = (CLVDragGroup*)fDragGroups.ItemAt(GroupCounter); - NumberOfColumnsInGroup = ThisGroup->GroupStopDispListIndex - - ThisGroup->GroupStartDispListIndex + 1; for(ColumnCounter = ThisGroup->GroupStartDispListIndex; ColumnCounter <= ThisGroup->GroupStopDispListIndex; ColumnCounter++) NewDisplayList.AddItem(fDisplayList->ItemAt(ColumnCounter)); @@ -557,7 +554,6 @@ void CLVColumnLabelView::ShiftDragGroup(int32 NewPos) } //Copy the group into the new position ThisGroup = (CLVDragGroup*)fDragGroups.ItemAt(fDragGroup); - NumberOfColumnsInGroup = ThisGroup->GroupStopDispListIndex - ThisGroup->GroupStartDispListIndex + 1; for(ColumnCounter = ThisGroup->GroupStartDispListIndex; ColumnCounter <= ThisGroup->GroupStopDispListIndex; ColumnCounter++) NewDisplayList.AddItem(fDisplayList->ItemAt(ColumnCounter)); @@ -567,8 +563,6 @@ void CLVColumnLabelView::ShiftDragGroup(int32 NewPos) if(GroupCounter != fDragGroup) { ThisGroup = (CLVDragGroup*)fDragGroups.ItemAt(GroupCounter); - NumberOfColumnsInGroup = ThisGroup->GroupStopDispListIndex - - ThisGroup->GroupStartDispListIndex + 1; for(ColumnCounter = ThisGroup->GroupStartDispListIndex; ColumnCounter <= ThisGroup->GroupStopDispListIndex; ColumnCounter++) NewDisplayList.AddItem(fDisplayList->ItemAt(ColumnCounter)); diff --git a/src/servers/app/drawing/Painter/drawing_modes/DrawingModeInvert.h b/src/servers/app/drawing/Painter/drawing_modes/DrawingModeInvert.h index 5fb8930d65..2a8e523f8d 100644 --- a/src/servers/app/drawing/Painter/drawing_modes/DrawingModeInvert.h +++ b/src/servers/app/drawing/Painter/drawing_modes/DrawingModeInvert.h @@ -17,6 +17,7 @@ pixel32 _p; \ _p.data32 = *(uint32*)d; \ BLEND(d, 255 - _p.data8[2], 255 - _p.data8[1], 255 - _p.data8[0], a); \ + (void)_p; \ } // ASSIGN_INVERT diff --git a/src/servers/app/drawing/Painter/drawing_modes/DrawingModeInvertSUBPIX.h b/src/servers/app/drawing/Painter/drawing_modes/DrawingModeInvertSUBPIX.h index 4a548eec97..bf39d6bc43 100644 --- a/src/servers/app/drawing/Painter/drawing_modes/DrawingModeInvertSUBPIX.h +++ b/src/servers/app/drawing/Painter/drawing_modes/DrawingModeInvertSUBPIX.h @@ -20,6 +20,7 @@ _p.data32 = *(uint32*)d; \ BLEND_SUBPIX(d, 255 - _p.data8[2], 255 - _p.data8[1], 255 - _p.data8[0], \ a1, a2, a3); \ + (void)_p; \ } diff --git a/src/servers/app/font/GlyphLayoutEngine.h b/src/servers/app/font/GlyphLayoutEngine.h index 7717fc22ed..63ec4d0891 100644 --- a/src/servers/app/font/GlyphLayoutEngine.h +++ b/src/servers/app/font/GlyphLayoutEngine.h @@ -211,7 +211,7 @@ GlyphLayoutEngine::LayoutGlyphs(GlyphConsumer& consumer, double advanceX = 0.0; double advanceY = 0.0; - uint32 lastCharCode = 0; +// uint32 lastCharCode = 0; uint32 charCode; int32 index = 0; bool writeLocked = false; @@ -268,7 +268,7 @@ GlyphLayoutEngine::LayoutGlyphs(GlyphConsumer& consumer, advanceY = glyph->advance_y; } - lastCharCode = charCode; +// lastCharCode = charCode; if (utf8String - start + 1 > length) break; } diff --git a/src/servers/notification/AppGroupView.cpp b/src/servers/notification/AppGroupView.cpp index 1b3343f4f0..5779b59223 100644 --- a/src/servers/notification/AppGroupView.cpp +++ b/src/servers/notification/AppGroupView.cpp @@ -45,7 +45,6 @@ AppGroupView::Draw(BRect updateRect) rgb_color menuColor = ViewColor(); BRect bounds = Bounds(); rgb_color hilite = tint_color(menuColor, B_DARKEN_1_TINT); - rgb_color dark = tint_color(menuColor, B_DARKEN_2_TINT); rgb_color vlight = tint_color(menuColor, B_LIGHTEN_2_TINT); bounds.bottom = bounds.top + kHeaderSize;