Skip to content
Browse files

WaE: -Wunused-but-set-variable

  • Loading branch information...
1 parent 7566d53 commit ab7cf7a8b4c3daddbe64a747373a45baeb5ed03f @khaledhosny khaledhosny committed
Showing with 6 additions and 19 deletions.
  1. +1 −2 fontforge/bvedit.c
  2. +0 −3 fontforge/cvimages.c
  3. +0 −4 fontforge/featurefile.c
  4. +5 −10 gdraw/gimagexdraw.c
View
3 fontforge/bvedit.c
@@ -564,7 +564,7 @@ return( ret );
}
int BDFCharQuickBounds( BDFChar *bc,IBounds *bb,int8 xoff,int8 yoff,int use_backup,int first ) {
- int bmp_width, has_bitmap = false;
+ int has_bitmap = false;
int xmin, xmax, ymin, ymax;
BDFRefChar *head;
@@ -575,7 +575,6 @@ int BDFCharQuickBounds( BDFChar *bc,IBounds *bb,int8 xoff,int8 yoff,int use_back
xmin = bc->xmin; xmax = bc->xmax;
ymin = bc->ymin; ymax = bc->ymax;
}
- bmp_width = xmax - xmin + 1;
has_bitmap = BCHasOutputtableBitmap( bc );
if ( has_bitmap && first ) {
View
3 fontforge/cvimages.c
@@ -149,13 +149,10 @@ return;
void SCImportPDFFile(SplineChar *sc,int layer,FILE *pdf,int doclear,int flags) {
SplinePointList *spl, *espl;
SplineSet **head;
- int empty, width;
if ( pdf==NULL )
return;
- width = UNDEFINED_WIDTH;
- empty = sc->layers[layer].splines==NULL && sc->layers[layer].refs==NULL;
if ( sc->parent->multilayer && layer>ly_back ) {
SCAppendEntityLayers(sc, EntityInterpretPDFPage(pdf,-1));
} else {
View
4 fontforge/featurefile.c
@@ -4854,7 +4854,6 @@ static void fea_ParseLookupDef(struct parseState *tok, int could_be_stat ) {
char *lookup_name;
struct feat_item *item, *first_after_mark;
enum otlookup_type lookuptype;
- int has_marks;
int ret;
int has_single, has_multiple;
@@ -4964,11 +4963,8 @@ return;
/* Make sure all entries in this lookup of the same lookup type */
lookuptype = ot_undef;
- has_marks = false;
for ( item=tok->sofar ; item!=NULL && item->type!=ft_lookup_start; item=item->next ) {
enum otlookup_type cur = fea_LookupTypeFromItem(item);
- if ( item->type==ft_ap && item->u2.ap->type == at_mark )
- has_marks = true;
if ( cur==ot_undef ) /* Some entries in the list (lookupflags) have no type */
/* Tum, ty, tum tum */;
else if ( lookuptype==ot_undef )
View
15 gdraw/gimagexdraw.c
@@ -67,7 +67,7 @@ static void intersect_rectangles(GRect *rect, GRect *clip) {
static void gdraw_8_on_1_nomag_dithered_masked(GXDisplay *gdisp,GImage *image,
GRect *src) {
struct gcol clut[256];
- int i,j,end, index;
+ int i,j, index;
struct _GImage *base = image->list_len==0?image->u.image:image->u.images[0];
int trans = base->trans;
unsigned char *pt, *ipt, *mpt;
@@ -81,7 +81,6 @@ static void gdraw_8_on_1_nomag_dithered_masked(GXDisplay *gdisp,GImage *image,
for ( i=src->width-1; i>=0; --i )
gdisp->gg.green_dith[i] = 0;
- end = src->width;
for ( i=src->y; i<src->y+src->height; ++i ) {
pt = (unsigned char *) (base->data) + i*base->bytes_per_line + src->x;
ipt = (unsigned char *) (gdisp->gg.img->data) + (i-src->y)*gdisp->gg.img->bytes_per_line;
@@ -120,7 +119,7 @@ static void gdraw_8_on_1_nomag_dithered_masked(GXDisplay *gdisp,GImage *image,
}
static void gdraw_32_on_1_nomag_dithered_masked(GXDisplay *gdisp, GImage *image, GRect *src) {
- int i,j,end, index;
+ int i,j, index;
struct _GImage *base = image->list_len==0?image->u.image:image->u.images[0];
int trans = base->trans;
uint32 *pt;
@@ -132,7 +131,6 @@ static void gdraw_32_on_1_nomag_dithered_masked(GXDisplay *gdisp, GImage *image,
for ( i=src->width-1; i>=0; --i )
gdisp->gg.green_dith[i] = 0;
- end = src->width;
for ( i=src->y; i<src->y+src->height; ++i ) {
pt = (uint32 *) (base->data + i*base->bytes_per_line) + src->x;
ipt = (uint8 *) (gdisp->gg.img->data) + (i-src->y)*gdisp->gg.img->bytes_per_line;
@@ -170,7 +168,7 @@ static void gdraw_32_on_1_nomag_dithered_masked(GXDisplay *gdisp, GImage *image,
}
static void gdraw_32a_on_1_nomag_dithered(GXDisplay *gdisp, GImage *image, GRect *src) {
- int i,j,end;
+ int i,j;
unsigned int index;
struct _GImage *base = image->list_len==0?image->u.image:image->u.images[0];
int trans = base->trans;
@@ -183,7 +181,6 @@ static void gdraw_32a_on_1_nomag_dithered(GXDisplay *gdisp, GImage *image, GRect
for ( i=src->width-1; i>=0; --i )
gdisp->gg.green_dith[i] = 0;
- end = src->width;
for ( i=src->y; i<src->y+src->height; ++i ) {
pt = (uint32 *) (base->data + i*base->bytes_per_line) + src->x;
ipt = (uint8 *) (gdisp->gg.img->data) + (i-src->y)*gdisp->gg.img->bytes_per_line;
@@ -222,7 +219,7 @@ static void gdraw_32a_on_1_nomag_dithered(GXDisplay *gdisp, GImage *image, GRect
static void gdraw_8_on_1_nomag_dithered_nomask(GXDisplay *gdisp, GImage *image, GRect *src) {
struct gcol clut[256];
- int i,j,end, index;
+ int i,j, index;
struct _GImage *base = image->list_len==0?image->u.image:image->u.images[0];
unsigned char *pt, *ipt;
short *g_d;
@@ -235,7 +232,6 @@ static void gdraw_8_on_1_nomag_dithered_nomask(GXDisplay *gdisp, GImage *image,
for ( i=src->width-1; i>=0; --i )
gdisp->gg.green_dith[i] = 0;
- end = src->width;
for ( i=src->y; i<src->y+src->height; ++i ) {
pt = (unsigned char *) (base->data) + i*base->bytes_per_line + src->x;
ipt = (unsigned char *) (gdisp->gg.img->data) + (i-src->y)*gdisp->gg.img->bytes_per_line;
@@ -267,7 +263,7 @@ static void gdraw_8_on_1_nomag_dithered_nomask(GXDisplay *gdisp, GImage *image,
static void gdraw_32_on_1_nomag_dithered_nomask(GXDisplay *gdisp, GImage *image, GRect *src) {
struct gcol clut[256];
- int i,j,end, index;
+ int i,j, index;
struct _GImage *base = image->list_len==0?image->u.image:image->u.images[0];
uint32 *pt;
uint8 *ipt;
@@ -280,7 +276,6 @@ static void gdraw_32_on_1_nomag_dithered_nomask(GXDisplay *gdisp, GImage *image,
for ( i=src->width-1; i>=0; --i )
gdisp->gg.green_dith[i] = 0;
- end = src->width;
for ( i=src->y; i<src->y+src->height; ++i ) {
pt = (uint32 *) (base->data + i*base->bytes_per_line) + src->x;
ipt = (uint8 *) (gdisp->gg.img->data) + (i-src->y)*gdisp->gg.img->bytes_per_line;

0 comments on commit ab7cf7a

Please sign in to comment.
Something went wrong with that request. Please try again.