nbis: Add patch to fix unused variable warning
With the spatch to use GLib memory functions a lot of error paths were removed. This causes an unused variable warning, so drop in a further patch to remove the unused variable.
This commit is contained in:
parent
cddd0f4653
commit
fd5f511b33
3 changed files with 19 additions and 2 deletions
13
libfprint/nbis/glib-mem-warning.patch
Normal file
13
libfprint/nbis/glib-mem-warning.patch
Normal file
|
@ -0,0 +1,13 @@
|
||||||
|
diff --git a/libfprint/nbis/mindtct/shape.c b/libfprint/nbis/mindtct/shape.c
|
||||||
|
index 28bc66c..c399f36 100644
|
||||||
|
--- mindtct/shape.c
|
||||||
|
+++ mindtct/shape.c
|
||||||
|
@@ -86,7 +86,7 @@ int alloc_shape(SHAPE **oshape, const int xmin, const int ymin,
|
||||||
|
{
|
||||||
|
SHAPE *shape;
|
||||||
|
int alloc_rows, alloc_pts;
|
||||||
|
- int i, j, y;
|
||||||
|
+ int i, y;
|
||||||
|
|
||||||
|
/* Compute allocation parameters. */
|
||||||
|
/* First, compute the number of scanlines spanned by the shape. */
|
|
@ -86,7 +86,7 @@ int alloc_shape(SHAPE **oshape, const int xmin, const int ymin,
|
||||||
{
|
{
|
||||||
SHAPE *shape;
|
SHAPE *shape;
|
||||||
int alloc_rows, alloc_pts;
|
int alloc_rows, alloc_pts;
|
||||||
int i, j, y;
|
int i, y;
|
||||||
|
|
||||||
/* Compute allocation parameters. */
|
/* Compute allocation parameters. */
|
||||||
/* First, compute the number of scanlines spanned by the shape. */
|
/* First, compute the number of scanlines spanned by the shape. */
|
||||||
|
|
|
@ -180,4 +180,8 @@ sed -i 's/[ \t]*$//' `find -name "*.[ch]"`
|
||||||
sed -i '/usebsd.h/d' `find -name "*.[ch]"`
|
sed -i '/usebsd.h/d' `find -name "*.[ch]"`
|
||||||
|
|
||||||
# Use GLib memory management
|
# Use GLib memory management
|
||||||
spatch --sp-file glib-memory.cocci --dir . --in-place
|
spatch --sp-file glib-memory.cocci --dir . --in-place
|
||||||
|
|
||||||
|
# The above leaves an unused variable around, triggering a warning
|
||||||
|
# remove it.
|
||||||
|
patch -p0 < glib-mem-warning.patch
|
Loading…
Reference in a new issue