void-packages/srcpkgs/yeahwm/patches/fix-shape.patch
Đoàn Trần Công Danh ad877a7e29 srcpkgs/y*: convert patches to -Np1
```sh
git grep -l '^patch_args=-Np0' "srcpkgs/$1*/template" |
while read template; do
	for p in ${template%/template}/patches/*; do
		sed -i '
			\,^[+-][+-][+-] /dev/null,b
			/^[*-]\+ [0-9]\+\(,[0-9]\+\)\? [*-]\+$/b
			s,^[*][*][*] ,&a/,
			/^--- /{
				s,\(^--- \)\(./\)*,\1a/,
				s,[.-][Oo][Rr][Ii][Gg]\([	/]\),\1,
				s/[.-][Oo][Rr][Ii][Gg]$//
				s/[.]patched[.]\([^.]\)/.\1/
				h
			}
			/^+++ -/{
				g
				s/^--- a/+++ b/
				b
			}
			s,\(^+++ \)\(./\)*,\1b/,
		' "$p"
	done
	sed -i '/^patch_args=/d' $template
done
```
2021-06-20 13:17:29 +07:00

20 lines
548 B
Diff

Fix misplaced #ifdef. A closing brace is always required
for switch() and an empty default is a bug.
--- a/main.c 2004-11-21 19:00:54.000000000 +0100
+++ b/main.c 2015-10-25 23:08:33.060565151 +0100
@@ -173,12 +173,12 @@
if (ev.xexpose.count == 0);
handle_expose_event(&ev.xexpose);
break;
- default:
#ifdef SHAPE
+ default:
if (have_shape && ev.type == shape_event)
handle_shape_event((XShapeEvent *) & ev);
- }
#endif
+ }
}
return 1;