~ubuntu-branches/ubuntu/saucy/flwm/saucy

« back to all changes in this revision

Viewing changes to debian/patches/03-parantheses-warnings.dpatch

  • Committer: Bazaar Package Importer
  • Author(s): Patrick Matthäi
  • Date: 2011-04-10 18:15:09 UTC
  • mfrom: (3.1.7 sid)
  • Revision ID: james.westby@ubuntu.com-20110410181509-0nuey5glwdiaq6vh
Tags: 1.02+cvs20080422-8
* Bump Standards-Version to 3.9.2 (no changes needed).
* Set the maintainer to the Debian QA Group.

Show diffs side-by-side

added added

removed removed

Lines of Context:
1
 
#!/bin/sh /usr/share/dpatch/dpatch-run
2
 
## 03-parantheses-warnings.dpatch by Patrick Matthäi <patrick.matthaei@web.de>
3
 
##
4
 
## DP: This patch adds some parantheses in the code to avoid some compiler
5
 
##     warnings.
6
 
 
7
 
@DPATCH@
8
 
 
9
 
diff -Naur flwm-1.02+cvs20080422.orig/Frame.C flwm-1.02+cvs20080422/Frame.C
10
 
--- flwm-1.02+cvs20080422.orig/Frame.C  2008-05-14 14:40:28.000000000 +0200
11
 
+++ flwm-1.02+cvs20080422/Frame.C       2008-05-14 14:43:34.000000000 +0200
12
 
@@ -915,7 +915,7 @@
13
 
   // preserving stacking order:
14
 
   for (p = &first; *p;) {
15
 
     Frame* f = *p;
16
 
-    if (f == this || f->is_transient_for(this) && f->state() != UNMAPPED) {
17
 
+    if (f == this || (f->is_transient_for(this) && f->state() != UNMAPPED)) {
18
 
       *p = f->next; // remove it from list
19
 
       if (previous) {
20
 
        XWindowChanges w;
21
 
@@ -970,7 +970,7 @@
22
 
 
23
 
 void Frame::iconize() {
24
 
   for (Frame* c = first; c; c = c->next) {
25
 
-    if (c == this || c->is_transient_for(this) && c->state() != UNMAPPED)
26
 
+    if (c == this || (c->is_transient_for(this) && c->state() != UNMAPPED))
27
 
       c->state(ICONIC);
28
 
   }
29
 
 }
30
 
@@ -1163,7 +1163,7 @@
31
 
 #endif
32
 
   }
33
 
   if (min_h == max_h || flag(KEEP_ASPECT|NO_RESIZE) ||
34
 
-      !max_h_button.value() && by+label_w+2*BUTTON_H > h()-BUTTON_BOTTOM) {
35
 
+      (!max_h_button.value() && by+label_w+2*BUTTON_H > h()-BUTTON_BOTTOM)) {
36
 
     max_h_button.hide();
37
 
   } else {
38
 
     max_h_button.position(BUTTON_LEFT,by);
39
 
@@ -1171,7 +1171,7 @@
40
 
     by += BUTTON_H;
41
 
   }
42
 
   if (min_w == max_w || flag(KEEP_ASPECT|NO_RESIZE) ||
43
 
-      !max_w_button.value() && by+label_w+2*BUTTON_H > h()-BUTTON_BOTTOM) {
44
 
+      (!max_w_button.value() && by+label_w+2*BUTTON_H > h()-BUTTON_BOTTOM)) {
45
 
     max_w_button.hide();
46
 
   } else {
47
 
     max_w_button.position(BUTTON_LEFT,by);
48
 
@@ -1646,8 +1646,8 @@
49
 
        nh = iy+ih-(Fl::event_y_root()-dy);
50
 
       else {ny = y(); nh = h();}
51
 
       if (flag(KEEP_ASPECT)) {
52
 
-       if (nw-dwidth > nh-dwidth
53
 
-           && (what&(FL_ALIGN_LEFT|FL_ALIGN_RIGHT))
54
 
+       if ((nw-dwidth > nh-dwidth
55
 
+           && (what&(FL_ALIGN_LEFT|FL_ALIGN_RIGHT)))
56
 
            || !(what&(FL_ALIGN_TOP|FL_ALIGN_BOTTOM)))
57
 
          nh = nw-dwidth+dheight;
58
 
        else
59
 
diff -Naur flwm-1.02+cvs20080422.orig/Hotkeys.C flwm-1.02+cvs20080422/Hotkeys.C
60
 
--- flwm-1.02+cvs20080422.orig/Hotkeys.C        2008-05-14 14:40:28.000000000 +0200
61
 
+++ flwm-1.02+cvs20080422/Hotkeys.C     2008-05-14 14:46:58.000000000 +0200
62
 
@@ -182,8 +182,8 @@
63
 
 int Handle_Hotkey() {
64
 
   for (int i = 0; keybindings[i].key; i++) {
65
 
     if (Fl::test_shortcut(keybindings[i].key) ||
66
 
-       (keybindings[i].key & 0xFFFF) == FL_Delete
67
 
-       && Fl::event_key() == FL_BackSpace// fltk bug?
68
 
+       ((keybindings[i].key & 0xFFFF) == FL_Delete
69
 
+       && Fl::event_key() == FL_BackSpace)// fltk bug?
70
 
        ) {
71
 
       keybindings[i].func();
72
 
       return 1;
73
 
diff -Naur flwm-1.02+cvs20080422.orig/Menu.C flwm-1.02+cvs20080422/Menu.C
74
 
--- flwm-1.02+cvs20080422.orig/Menu.C   2008-05-14 14:40:28.000000000 +0200
75
 
+++ flwm-1.02+cvs20080422/Menu.C        2008-05-14 14:45:50.000000000 +0200
76
 
@@ -568,7 +568,7 @@
77
 
       if (d == Desktop::current()) first_on_desk = menu+n;
78
 
       for (c = Frame::first; c; c = c->next) {
79
 
        if (c->state() == UNMAPPED || c->transient_for()) continue;
80
 
-       if (c->desktop() == d || !c->desktop() && d == Desktop::current()) {
81
 
+       if (c->desktop() == d || (!c->desktop() && d == Desktop::current())) {
82
 
          init(menu[n],(char*)c);
83
 
 #if FL_MAJOR_VERSION < 2
84
 
          init(menu[n],(char*)c);