diff options
author | Peter Breitenlohner <peb@mppmu.mpg.de> | 2013-01-09 13:58:46 +0000 |
---|---|---|
committer | Peter Breitenlohner <peb@mppmu.mpg.de> | 2013-01-09 13:58:46 +0000 |
commit | a7ee03f4f16e3dcc75957f11ac8cd4a29b034bef (patch) | |
tree | ebcb39b2baff42ba78ec5ad9a97a542f721f6932 | |
parent | d751bb640e6ea7b340c2c4c79eea858a93862b9d (diff) |
dvipdfmx: Avoid various gcc-4.6 warnings
git-svn-id: svn://tug.org/texlive/trunk@28775 c570f23f-e606-0410-a88d-b1316a301751
-rw-r--r-- | Build/source/texk/dvipdfmx/ChangeLog | 22 | ||||
-rw-r--r-- | Build/source/texk/dvipdfmx/src/bmpimage.c | 4 | ||||
-rw-r--r-- | Build/source/texk/dvipdfmx/src/cidtype0.c | 6 | ||||
-rw-r--r-- | Build/source/texk/dvipdfmx/src/cidtype2.c | 18 | ||||
-rw-r--r-- | Build/source/texk/dvipdfmx/src/dvi.c | 4 | ||||
-rw-r--r-- | Build/source/texk/dvipdfmx/src/dvipdfmx.c | 13 | ||||
-rw-r--r-- | Build/source/texk/dvipdfmx/src/fontmap.c | 7 | ||||
-rw-r--r-- | Build/source/texk/dvipdfmx/src/jpegimage.c | 4 | ||||
-rw-r--r-- | Build/source/texk/dvipdfmx/src/otl_conf.c | 5 | ||||
-rw-r--r-- | Build/source/texk/dvipdfmx/src/pdfdraw.c | 2 | ||||
-rw-r--r-- | Build/source/texk/dvipdfmx/src/pdfencoding.c | 4 | ||||
-rw-r--r-- | Build/source/texk/dvipdfmx/src/pdffont.c | 12 | ||||
-rw-r--r-- | Build/source/texk/dvipdfmx/src/pkfont.c | 6 | ||||
-rw-r--r-- | Build/source/texk/dvipdfmx/src/spc_pdfm.c | 13 | ||||
-rw-r--r-- | Build/source/texk/dvipdfmx/src/tt_aux.c | 3 | ||||
-rw-r--r-- | Build/source/texk/dvipdfmx/src/tt_cmap.c | 11 | ||||
-rw-r--r-- | Build/source/texk/dvipdfmx/src/tt_glyf.c | 3 | ||||
-rw-r--r-- | Build/source/texk/dvipdfmx/src/tt_post.c | 3 | ||||
-rw-r--r-- | Build/source/texk/dvipdfmx/src/type1.c | 6 |
19 files changed, 81 insertions, 65 deletions
diff --git a/Build/source/texk/dvipdfmx/ChangeLog b/Build/source/texk/dvipdfmx/ChangeLog index d33a5faae00..54de19d7243 100644 --- a/Build/source/texk/dvipdfmx/ChangeLog +++ b/Build/source/texk/dvipdfmx/ChangeLog @@ -1,3 +1,15 @@ +2012-09-24 Peter Breitenlohner <peb@mppmu.mpg.de> + + Avoid various gcc-4.6 warnings. + * src/cidtype2.c, src/dvipdfmx.c, src/fontmap.c, src/otl_conf.c, + src/pdfencoding.c, src/spc_pdfm.c, src/tt_cmap.c: Do not use + unsafe casts (char **) -> (const char **). + * src/bmpimage.c, src/cidtype0.c, src/cidtype2.c, src/dvi.c, + src/jpegimage.c, src/pdffont.c, src/pkfont.c, src/spc_pdfm.c, + src/tt_aux.c, src/tt_cmap.c, src/tt_glyf.c, src/tt_post.c, + src/type1.c: Drop set but unused variables. + src/pdfdraw.c: Do not test '(&v) != NULL', this is always true. + 2012-12-12 Khaled Hosny <khaledhosny@eglug.org> * src/tt_cmap.c: Make sure CMapName of embedded CMaps does not contain @@ -21,11 +33,11 @@ 2012-08-31 Peter Breitenlohner <peb@mppmu.mpg.de> Reduce TL/W32TeX diffs. - * cidtype0.c, cidtype2.c, cmap_write.c, mpost.c, truetype.c, - tt_cmap.c, tt_gsub.c, tt_post.c: Cast function args to avoid - WIN32 (MSVC) warnings. - * pdfobj.c (pdf_out_xchar): Reformulate to avoid MSVC warnings. - * xbb.c (show_usage): Correctly report .bb or .xbb as default. + * src/cidtype0.c, src/cidtype2.c, src/cmap_write.c, src/mpost.c, + src/truetype.c, src/tt_cmap.c, src/tt_gsub.c, src/tt_post.c: + Cast function args to avoid WIN32 (MSVC) warnings. + * src/pdfobj.c (pdf_out_xchar): Reformulate to avoid MSVC warnings. + * src/xbb.c (show_usage): Correctly report .bb or .xbb as default. Always use binary mode for output file. 2012-08-26 Akira Kakuto <kakuto@fuk.kindai.ac.jp> diff --git a/Build/source/texk/dvipdfmx/src/bmpimage.c b/Build/source/texk/dvipdfmx/src/bmpimage.c index ce9b725bc9d..ef23e70a3a4 100644 --- a/Build/source/texk/dvipdfmx/src/bmpimage.c +++ b/Build/source/texk/dvipdfmx/src/bmpimage.c @@ -78,7 +78,7 @@ bmp_include_image (pdf_ximage *ximage, FILE *fp) ximage_info info; unsigned char buf[DIB_HEADER_SIZE_MAX+4]; unsigned char *p; - long offset, fsize, hsize, compression; + long offset, hsize, compression; long psize; /* Bytes per palette color: 3 for OS2, 4 for Win */ unsigned short bit_count; /* Bits per pix */ int num_palette, flip; @@ -105,7 +105,7 @@ bmp_include_image (pdf_ximage *ximage, FILE *fp) ((b)[2] << 16) + ((b)[3] << 24)) #define USHORT_LE(b) ((b)[0] + ((b)[1] << 8)) - fsize = ULONG_LE(p); p += 4; + /* fsize = ULONG_LE(p); */ p += 4; if (ULONG_LE(p) != 0) { WARN("Not a BMP file???"); return -1; diff --git a/Build/source/texk/dvipdfmx/src/cidtype0.c b/Build/source/texk/dvipdfmx/src/cidtype0.c index 9b335b89e2a..f2a2afaed00 100644 --- a/Build/source/texk/dvipdfmx/src/cidtype0.c +++ b/Build/source/texk/dvipdfmx/src/cidtype0.c @@ -161,7 +161,10 @@ add_CIDVMetrics (sfnt *sfont, pdf_obj *fontdict, struct tt_head_table *head, struct tt_longMetrics *hmtx) { pdf_obj *w2_array, *an_array = NULL; - long cid, prev, start; + long cid; +#if 0 + long prev = 0, start = 0; +#endif struct tt_VORG_table *vorg; struct tt_vhea_table *vhea = NULL; struct tt_longMetrics *vmtx = NULL; @@ -197,7 +200,6 @@ add_CIDVMetrics (sfnt *sfont, pdf_obj *fontdict, } w2_array = pdf_new_array(); - start = prev = 0; for (cid = 0; cid <= last_cid; cid++) { USHORT i, gid; double advanceHeight, vertOriginX, vertOriginY; diff --git a/Build/source/texk/dvipdfmx/src/cidtype2.c b/Build/source/texk/dvipdfmx/src/cidtype2.c index 61fb320ede8..dcf74c6abec 100644 --- a/Build/source/texk/dvipdfmx/src/cidtype2.c +++ b/Build/source/texk/dvipdfmx/src/cidtype2.c @@ -301,7 +301,10 @@ add_TTCIDVMetrics (pdf_obj *fontdict, struct tt_glyphs *g, char *used_chars, unsigned char *cidtogidmap, unsigned short last_cid) { pdf_obj *w2_array, *an_array = NULL; - long cid, prev, start; + long cid; +#if 0 + long prev = 0, start = 0; +#endif double defaultVertOriginY, defaultAdvanceHeight; int empty = 1; @@ -309,14 +312,18 @@ add_TTCIDVMetrics (pdf_obj *fontdict, struct tt_glyphs *g, defaultAdvanceHeight = PDFUNIT(g->default_advh); w2_array = pdf_new_array(); - start = prev = 0; for (cid = 0; cid <= last_cid; cid++) { - USHORT idx, gid; + USHORT idx; +#if 0 + USHORT gid; +#endif double vertOriginX, vertOriginY, advanceHeight; if (!is_used_char2(used_chars, cid)) continue; +#if 0 gid = (cidtogidmap) ? ((cidtogidmap[2*cid] << 8)|cidtogidmap[2*cid+1]) : cid; +#endif idx = tt_get_index(g, (USHORT)cid); if (cid != 0 && idx == 0) continue; @@ -452,7 +459,8 @@ cid_to_code (CMap *cmap, CID cid) { unsigned char inbuf[2], outbuf[32]; long inbytesleft = 2, outbytesleft = 32; - unsigned char *p, *q; + const unsigned char *p; + unsigned char *q; if (!cmap) return cid; @@ -461,7 +469,7 @@ cid_to_code (CMap *cmap, CID cid) inbuf[1] = cid & 0xff; p = inbuf; q = outbuf; - CMap_decode_char(cmap, (const unsigned char **) &p, &inbytesleft, &q, &outbytesleft); + CMap_decode_char(cmap, &p, &inbytesleft, &q, &outbytesleft); if (inbytesleft != 0) return 0; diff --git a/Build/source/texk/dvipdfmx/src/dvi.c b/Build/source/texk/dvipdfmx/src/dvi.c index 571e703b03a..38f48dccd42 100644 --- a/Build/source/texk/dvipdfmx/src/dvi.c +++ b/Build/source/texk/dvipdfmx/src/dvi.c @@ -280,14 +280,14 @@ static void read_font_record (SIGNED_QUAD tex_id) { UNSIGNED_BYTE dir_length, name_length; - UNSIGNED_QUAD checksum, point_size, design_size; + UNSIGNED_QUAD point_size, design_size; char *directory, *font_name; if (num_def_fonts >= max_def_fonts) { max_def_fonts += TEX_FONTS_ALLOC_SIZE; def_fonts = RENEW (def_fonts, max_def_fonts, struct font_def); } - checksum = get_unsigned_quad(dvi_file); + get_unsigned_quad(dvi_file); point_size = get_unsigned_quad(dvi_file); design_size = get_unsigned_quad(dvi_file); dir_length = get_unsigned_byte(dvi_file); diff --git a/Build/source/texk/dvipdfmx/src/dvipdfmx.c b/Build/source/texk/dvipdfmx/src/dvipdfmx.c index 307e5a11b39..128ffd1b5b9 100644 --- a/Build/source/texk/dvipdfmx/src/dvipdfmx.c +++ b/Build/source/texk/dvipdfmx/src/dvipdfmx.c @@ -385,6 +385,7 @@ do_args (int argc, char *argv[]) { while (argc > 0 && *argv[0] == '-') { char *flag, *nextptr; + const char *nnextptr; for (flag = argv[0] + 1; *flag != 0; flag++) { switch (*flag) { @@ -424,20 +425,20 @@ do_args (int argc, char *argv[]) break; case 'g': CHECK_ARG(1, "annotation \"grow\" amount"); - nextptr = argv[1]; - read_length(&annot_grow, (const char **) &nextptr, nextptr + strlen(nextptr)); + nnextptr = nextptr = argv[1]; + read_length(&annot_grow, &nnextptr, nextptr + strlen(nextptr)); POP_ARG(); break; case 'x': CHECK_ARG(1, "horizontal offset value"); - nextptr = argv[1]; - read_length(&x_offset, (const char **) &nextptr, nextptr + strlen(nextptr)); + nnextptr = nextptr = argv[1]; + read_length(&x_offset, &nnextptr, nextptr + strlen(nextptr)); POP_ARG(); break; case 'y': CHECK_ARG(1, "vertical offset value"); - nextptr = argv[1]; - read_length(&y_offset, (const char **) &nextptr, nextptr + strlen(nextptr)); + nnextptr = nextptr = argv[1]; + read_length(&y_offset, &nnextptr, nextptr + strlen(nextptr)); POP_ARG(); break; case 'o': diff --git a/Build/source/texk/dvipdfmx/src/fontmap.c b/Build/source/texk/dvipdfmx/src/fontmap.c index 0a023419100..133a3bff337 100644 --- a/Build/source/texk/dvipdfmx/src/fontmap.c +++ b/Build/source/texk/dvipdfmx/src/fontmap.c @@ -474,6 +474,7 @@ fontmap_parse_mapdef_dpm (fontmap_rec *mrec, } else if (p + 4 <= endptr && !memcmp(p, "sfd:", strlen("sfd:"))) { char *r; + const char *rr; /* SFD mapping: sfd:Big5,00 */ p += 4; skip_blank(&p, endptr); q = parse_string_value(&p, endptr); @@ -487,14 +488,14 @@ fontmap_parse_mapdef_dpm (fontmap_rec *mrec, RELEASE(q); return -1; } - *r = 0; r++; skip_blank((const char **)&r, r + strlen(r)); - if (*r == '\0') { + *r = 0; rr = ++r; skip_blank(&rr, r + strlen(r)); + if (*rr == '\0') { WARN("Invalid value for option 'm': %s,", q); RELEASE(q); return -1; } mrec->charmap.sfd_name = mstrdup(q); - mrec->charmap.subfont_id = mstrdup(r); + mrec->charmap.subfont_id = mstrdup(rr); RELEASE(q); } else if (p + 4 < endptr && !memcmp(p, "pad:", strlen("pad:"))) { diff --git a/Build/source/texk/dvipdfmx/src/jpegimage.c b/Build/source/texk/dvipdfmx/src/jpegimage.c index 4f2faeef0af..062b8a23788 100644 --- a/Build/source/texk/dvipdfmx/src/jpegimage.c +++ b/Build/source/texk/dvipdfmx/src/jpegimage.c @@ -569,9 +569,7 @@ read_APP0_JFIF (struct JPEG_info *j_info, FILE *fp, unsigned short length) static unsigned short read_APP0_JFXX (struct JPEG_info *j_info, FILE *fp, unsigned short length) { - unsigned char extension_code; - - extension_code = get_unsigned_byte(fp); + get_unsigned_byte(fp); /* Extension Code: * * 0x10: Thumbnail coded using JPEG diff --git a/Build/source/texk/dvipdfmx/src/otl_conf.c b/Build/source/texk/dvipdfmx/src/otl_conf.c index 4db9e5b01c1..cffbe505645 100644 --- a/Build/source/texk/dvipdfmx/src/otl_conf.c +++ b/Build/source/texk/dvipdfmx/src/otl_conf.c @@ -461,6 +461,7 @@ otl_read_conf (const char *conf_name) pdf_obj *gclass; FILE *fp; char *filename, *wbuf, *p, *endptr; + const char *pp; long size, len; filename = NEW(strlen(conf_name)+strlen(".otl")+1, char); @@ -493,9 +494,9 @@ otl_read_conf (const char *conf_name) size -= len; } - p = wbuf; + pp = wbuf; gclass = pdf_new_dict(); - rule = parse_block(gclass, (const char **) &p, endptr); + rule = parse_block(gclass, &pp, endptr); pdf_release_obj(gclass); RELEASE(wbuf); diff --git a/Build/source/texk/dvipdfmx/src/pdfdraw.c b/Build/source/texk/dvipdfmx/src/pdfdraw.c index 90a252f1016..de5b4dc7f11 100644 --- a/Build/source/texk/dvipdfmx/src/pdfdraw.c +++ b/Build/source/texk/dvipdfmx/src/pdfdraw.c @@ -992,7 +992,7 @@ m_stack_top (m_stack *stack) return data; } -#define m_stack_depth(s) (((s) != NULL) ? (s)->size : 0) +#define m_stack_depth(s) ((s)->size) static m_stack gs_stack; diff --git a/Build/source/texk/dvipdfmx/src/pdfencoding.c b/Build/source/texk/dvipdfmx/src/pdfencoding.c index 182a3598b53..539a575748e 100644 --- a/Build/source/texk/dvipdfmx/src/pdfencoding.c +++ b/Build/source/texk/dvipdfmx/src/pdfencoding.c @@ -287,7 +287,7 @@ load_encoding_file (const char *filename) pdf_obj *encoding_array = NULL; char *wbuf; const char *p, *endptr; - char *enc_vec[256]; + const char *enc_vec[256]; int code, fsize, enc_id; if (!filename) @@ -339,7 +339,7 @@ load_encoding_file (const char *filename) enc_vec[code] = pdf_name_value(pdf_get_array(encoding_array, code)); } enc_id = pdf_encoding_new_encoding(enc_name ? pdf_name_value(enc_name) : NULL, - filename, (const char **) enc_vec, NULL, 0); + filename, enc_vec, NULL, 0); if (enc_name) { if (verbose > 1) diff --git a/Build/source/texk/dvipdfmx/src/pdffont.c b/Build/source/texk/dvipdfmx/src/pdffont.c index 8de5e6e3fa2..599b6783cd2 100644 --- a/Build/source/texk/dvipdfmx/src/pdffont.c +++ b/Build/source/texk/dvipdfmx/src/pdffont.c @@ -448,7 +448,7 @@ try_load_ToUnicode_CMap (pdf_font *font) void pdf_close_fonts (void) { - int font_id, retval; + int font_id; for (font_id = 0; font_id < font_cache.count; font_id++) { @@ -489,24 +489,22 @@ pdf_close_fonts (void) if (__verbose) MESG("[Type1]"); if (!pdf_font_get_flag(font, PDF_FONT_FLAG_BASEFONT)) - retval = pdf_font_load_type1(font); - else - retval = 0; + pdf_font_load_type1(font); break; case PDF_FONT_FONTTYPE_TYPE1C: if (__verbose) MESG("[Type1C]"); - retval = pdf_font_load_type1c(font); + pdf_font_load_type1c(font); break; case PDF_FONT_FONTTYPE_TRUETYPE: if (__verbose) MESG("[TrueType]"); - retval = pdf_font_load_truetype(font); + pdf_font_load_truetype(font); break; case PDF_FONT_FONTTYPE_TYPE3: if (__verbose) MESG("[Type3/PK]"); - retval = pdf_font_load_pkfont (font); + pdf_font_load_pkfont (font); break; case PDF_FONT_FONTTYPE_TYPE0: break; diff --git a/Build/source/texk/dvipdfmx/src/pkfont.c b/Build/source/texk/dvipdfmx/src/pkfont.c index a005a7e716c..12ba5b76fae 100644 --- a/Build/source/texk/dvipdfmx/src/pkfont.c +++ b/Build/source/texk/dvipdfmx/src/pkfont.c @@ -480,7 +480,7 @@ create_pk_CharProc_stream (struct pk_header_ *pkh, { pdf_obj *stream; /* charproc */ long llx, lly, urx, ury; - int len, error = 0; + int len; llx = -pkh->bm_hoff; lly = pkh->bm_voff - pkh->bm_ht; @@ -517,12 +517,12 @@ create_pk_CharProc_stream (struct pk_header_ *pkh, pdf_add_stream(stream, work_buffer, len); /* Add bitmap data */ if (pkh->dyn_f == 14) /* bitmap */ - error = pk_decode_bitmap(stream, + pk_decode_bitmap(stream, pkh->bm_wd, pkh->bm_ht, pkh->dyn_f, pkh->run_color, pkt_ptr, pkt_len); else - error = pk_decode_packed(stream, + pk_decode_packed(stream, pkh->bm_wd, pkh->bm_ht, pkh->dyn_f, pkh->run_color, pkt_ptr, pkt_len); diff --git a/Build/source/texk/dvipdfmx/src/spc_pdfm.c b/Build/source/texk/dvipdfmx/src/spc_pdfm.c index 135bafe9e49..6ae6a94fded 100644 --- a/Build/source/texk/dvipdfmx/src/spc_pdfm.c +++ b/Build/source/texk/dvipdfmx/src/spc_pdfm.c @@ -392,7 +392,7 @@ reencodestring (CMap *cmap, pdf_obj *instring) #define WBUF_SIZE 4096 unsigned char wbuf[WBUF_SIZE]; unsigned char *obufcur; - unsigned char *inbufcur; + const unsigned char *inbufcur; long inbufleft, obufleft; if (!cmap || !instring) @@ -407,7 +407,7 @@ reencodestring (CMap *cmap, pdf_obj *instring) obufleft = WBUF_SIZE - 2; CMap_decode(cmap, - (const unsigned char **)&inbufcur, &inbufleft, + &inbufcur, &inbufleft, &obufcur, &obufleft); if (inbufleft > 0) { @@ -1026,7 +1026,6 @@ static int spc_handler_pdfm_dest (struct spc_env *spe, struct spc_arg *args) { pdf_obj *name, *array; - int error = 0; skip_white(&args->curptr, args->endptr); @@ -1052,10 +1051,10 @@ spc_handler_pdfm_dest (struct spc_env *spe, struct spc_arg *args) return -1; } - error = pdf_doc_add_names("Dests", - pdf_string_value (name), - pdf_string_length(name), - array); + pdf_doc_add_names("Dests", + pdf_string_value (name), + pdf_string_length(name), + array); pdf_release_obj(name); return 0; diff --git a/Build/source/texk/dvipdfmx/src/tt_aux.c b/Build/source/texk/dvipdfmx/src/tt_aux.c index 6288a2a4d74..fc19300f431 100644 --- a/Build/source/texk/dvipdfmx/src/tt_aux.c +++ b/Build/source/texk/dvipdfmx/src/tt_aux.c @@ -38,7 +38,6 @@ ULONG ttc_read_offset (sfnt *sfont, int ttc_idx) { - LONG version; ULONG offset = 0, num_dirs = 0; if (sfont == NULL || sfont->stream == NULL) @@ -49,7 +48,7 @@ ULONG ttc_read_offset (sfnt *sfont, int ttc_idx) sfnt_seek_set (sfont, 4); /* skip version tag */ - version = sfnt_get_ulong(sfont); + /* version = */ sfnt_get_ulong(sfont); num_dirs = sfnt_get_ulong(sfont); if (ttc_idx < 0 || ttc_idx > num_dirs - 1) ERROR("Invalid TTC index number"); diff --git a/Build/source/texk/dvipdfmx/src/tt_cmap.c b/Build/source/texk/dvipdfmx/src/tt_cmap.c index b9fdae5b445..6fad1352ded 100644 --- a/Build/source/texk/dvipdfmx/src/tt_cmap.c +++ b/Build/source/texk/dvipdfmx/src/tt_cmap.c @@ -452,13 +452,13 @@ tt_cmap_read (sfnt *sfont, USHORT platform, USHORT encoding) { tt_cmap *cmap = NULL; ULONG offset, length = 0; - USHORT version, p_id, e_id; + USHORT p_id, e_id; USHORT i, n_subtabs; ASSERT(sfont); offset = sfnt_locate_table(sfont, "cmap"); - version = sfnt_get_ushort(sfont); + (void) sfnt_get_ushort(sfont); n_subtabs = sfnt_get_ushort(sfont); for (i = 0; i < n_subtabs; i++) { @@ -848,7 +848,8 @@ handle_subst_glyphs (CMap *cmap, for (count = 0, i = 0; i < 8192; i++) { int j; long len, inbytesleft, outbytesleft; - unsigned char *inbuf, *outbuf; + const unsigned char *inbuf; + unsigned char *outbuf; if (used_glyphs[i] == 0) continue; @@ -866,10 +867,10 @@ handle_subst_glyphs (CMap *cmap, wbuf[1] = gid & 0xff; inbuf = wbuf; inbytesleft = 2; - outbuf = inbuf + 2; + outbuf = wbuf + 2; outbytesleft = WBUF_SIZE - 2; CMap_decode(cmap_add, - (const unsigned char **) &inbuf , &inbytesleft, + &inbuf , &inbytesleft, &outbuf, &outbytesleft); if (inbytesleft != 0) { WARN("CMap conversion failed..."); diff --git a/Build/source/texk/dvipdfmx/src/tt_glyf.c b/Build/source/texk/dvipdfmx/src/tt_glyf.c index c34f95a69bd..c258a784f65 100644 --- a/Build/source/texk/dvipdfmx/src/tt_glyf.c +++ b/Build/source/texk/dvipdfmx/src/tt_glyf.c @@ -583,7 +583,6 @@ tt_get_metrics (sfnt *sfont, struct tt_glyphs *g) for (i = 0; i < g->num_glyphs; i++) { USHORT gid; /* old gid */ ULONG loc, len; - SHORT number_of_contours; gid = g->gd[i].ogid; if (gid >= maxp->numGlyphs) @@ -616,7 +615,7 @@ tt_get_metrics (sfnt *sfont, struct tt_glyphs *g) } sfnt_seek_set(sfont, offset+loc); - number_of_contours = sfnt_get_short(sfont); + (void) sfnt_get_short(sfont); /* BoundingBox: FWord x 4 */ g->gd[i].llx = sfnt_get_short(sfont); diff --git a/Build/source/texk/dvipdfmx/src/tt_post.c b/Build/source/texk/dvipdfmx/src/tt_post.c index 23783c49216..8c6f6e293d0 100644 --- a/Build/source/texk/dvipdfmx/src/tt_post.c +++ b/Build/source/texk/dvipdfmx/src/tt_post.c @@ -109,9 +109,8 @@ struct tt_post_table * tt_read_post_table (sfnt *sfont) { struct tt_post_table *post; - ULONG offset; - offset = sfnt_locate_table(sfont, "post"); + /* offset = */ sfnt_locate_table(sfont, "post"); post = NEW(1, struct tt_post_table); diff --git a/Build/source/texk/dvipdfmx/src/type1.c b/Build/source/texk/dvipdfmx/src/type1.c index e3dbc832de7..fff0e44cab5 100644 --- a/Build/source/texk/dvipdfmx/src/type1.c +++ b/Build/source/texk/dvipdfmx/src/type1.c @@ -479,7 +479,7 @@ write_fontfile (pdf_font *font, cff_font *cffont, long num_glyphs) int pdf_font_load_type1 (pdf_font *font) { - pdf_obj *fontdict, *descriptor; + pdf_obj *fontdict; int encoding_id; char *usedchars, *ident; char *fontname, *uniqueTag; @@ -505,7 +505,7 @@ pdf_font_load_type1 (pdf_font *font) encoding_id = pdf_font_get_encoding (font); fontdict = pdf_font_get_resource (font); - descriptor = pdf_font_get_descriptor(font); + pdf_font_get_descriptor(font); usedchars = pdf_font_get_usedchars (font); ident = pdf_font_get_ident (font); fontname = pdf_font_get_fontname (font); @@ -681,7 +681,6 @@ pdf_font_load_type1 (pdf_font *font) t1_ginfo gm; card16 gid, gid_orig; long dstlen_max, srclen; - int have_seac = 0; card8 *srcptr, *dstptr; offset = dstlen_max = 0L; @@ -753,7 +752,6 @@ pdf_font_load_type1 (pdf_font *font) charset->data.glyphs[charset->num_entries] = cff_get_seac_sid(cffont, bchar_name); charset->num_entries += 1; } - have_seac = 1; } widths[gid] = gm.wx; } |