unity: Dead code in Launcher.cpp: "mask | (Button1Mask & Button2Mask & Button3Mask)"

Bug #805327 reported by Daniel van Vugt
6
This bug affects 1 person
Affects Status Importance Assigned to Milestone
Unity
Fix Released
Undecided
Daniel van Vugt
unity (Ubuntu)
Fix Released
Undecided
Daniel van Vugt

Bug Description

This expression in Launcher.cpp: Launcher::OnUpdateDragManagerTimeout appears to be partially useless:
  mask | (Button1Mask & Button2Mask & Button3Mask)

Because "Button1Mask & Button2Mask & Button3Mask" are mutually exclusive, the value will always be zero.

It looks like maybe the author meant:
  mask & (Button1Mask | Button2Mask | Button3Mask)

Related branches

summary: unity: Dead code in Launcher.cpp: "mask | (Button1Mask & Button2Mask &
- Button3Mask))"
+ Button3Mask)"
description: updated
Changed in unity:
assignee: nobody → Daniel van Vugt (vanvugt)
status: New → In Progress
Changed in unity (Ubuntu):
assignee: nobody → Daniel van Vugt (vanvugt)
status: New → In Progress
Gord Allott (gordallott)
Changed in unity:
status: In Progress → Fix Committed
Changed in unity (Ubuntu):
status: In Progress → Fix Committed
Gord Allott (gordallott)
Changed in unity:
milestone: none → 4.4.0
Changed in unity:
status: Fix Committed → Fix Released
Revision history for this message
Launchpad Janitor (janitor) wrote :

This bug was fixed in the package unity - 4.4.0-0ubuntu1

---------------
unity (4.4.0-0ubuntu1) oneiric; urgency=low

  * New upstream release.
    - moving a launcher icon around generates lots of disk write activity
      (LP: #733425)
    - compiz crashed with SIGSEGV in sigc::signal_base::impl() (LP: #762801)
    - Drag and drop a USB key into the trash should eject the USB key
      (LP: #764905)
    - unity window decorator needs to support different metacity frame types
      (LP: #795048)
    - Don't switch title to menu when hovering window buttons (LP: #691808)
    - spacing between indicators should be 5 pixels (LP: #734010)
    - Dash: highlight box is mis-aligned with smaller icon (LP: #761465)
    - Merge libindicator scroll signals (LP: #804618)
    - unity: Dead code in Launcher.cpp: "mask | (Button1Mask & Button2Mask &
      Button3Mask)" (LP: #805327)
    - TrashLauncherIcon::UpdateTrashIconCb is leaking (LP: #806984)
    - Title fade effect no longer works (LP: #809907)
    - Accessibility support not initialized on Oneiric (LP: #810033)
  * debian/control:
    - build-dep on libnotify-dev
    - bump libnux-1.0-dev dep for ABI break
  * debian/rules:
    - bump libunity-core-4.0-4 shlib for ABI break
 -- Didier Roche <email address hidden> Thu, 21 Jul 2011 18:41:15 +0200

Changed in unity (Ubuntu):
status: Fix Committed → Fix Released
Revision history for this message
Daniel van Vugt (vanvugt) wrote :

In case anyone cares, it seems this fix resolves bug 769703.

Revision history for this message
Omer Akram (om26er) wrote : Re: [Bug 805327] Re: unity: Dead code in Launcher.cpp: "mask | (Button1Mask & Button2Mask & Button3Mask)"
To post a comment you must log in.
This report contains Public information  
Everyone can see this information.

Other bug subscribers

Remote bug watches

Bug watches keep track of this bug in other bug trackers.