Merge pull request #2 from adafruit/fix-unused-var

Avoid an unused variable diagnostic in newest emscripten
This commit is contained in:
foamyguy 2024-11-07 08:06:54 -06:00 committed by GitHub
commit 7924283773
No known key found for this signature in database
GPG key ID: B5690EEEBB952194
2 changed files with 3 additions and 12 deletions

View file

@ -10,7 +10,7 @@ on:
jobs: jobs:
test: test:
runs-on: ubuntu-18.04 runs-on: ubuntu-latest
steps: steps:
- name: checkout - name: checkout
@ -35,7 +35,7 @@ jobs:
git remote set-url --push origin https://jepler:${{ secrets.GITHUB_TOKEN }}@github.com/${{ github.repository }} git remote set-url --push origin https://jepler:${{ secrets.GITHUB_TOKEN }}@github.com/${{ github.repository }}
git push -f origin gh-pages git push -f origin gh-pages
- uses: actions/upload-artifact@v2 - uses: actions/upload-artifact@v4
with: with:
name: Web pages name: Web pages
path: output/ path: output/

View file

@ -263,8 +263,7 @@ bdfReadCharacters(FontFilePtr file, FontPtr pFont, bdfFileState *pState,
register CharInfoPtr ci; register CharInfoPtr ci;
int i, int i,
ndx, ndx,
nchars, nchars;
nignored;
unsigned int char_row, char_col; unsigned int char_row, char_col;
int numEncodedGlyphs = 0; int numEncodedGlyphs = 0;
CharInfoPtr *bdfEncoding[256]; CharInfoPtr *bdfEncoding[256];
@ -332,7 +331,6 @@ bdfReadCharacters(FontFilePtr file, FontPtr pFont, bdfFileState *pState,
pFont->info.lastRow = 0; pFont->info.lastRow = 0;
pFont->info.firstCol = 256; pFont->info.firstCol = 256;
pFont->info.lastCol = 0; pFont->info.lastCol = 0;
nignored = 0;
for (ndx = 0; (ndx < nchars) && (line) && (bdfIsPrefix(line, "STARTCHAR"));) { for (ndx = 0; (ndx < nchars) && (line) && (bdfIsPrefix(line, "STARTCHAR"));) {
int t; int t;
int wx; /* x component of width */ int wx; /* x component of width */
@ -368,7 +366,6 @@ bdfReadCharacters(FontFilePtr file, FontPtr pFont, bdfFileState *pState,
ignore = 0; ignore = 0;
if (enc == -1) { if (enc == -1) {
if (!bitmapExtra) { if (!bitmapExtra) {
nignored++;
ignore = 1; ignore = 1;
} }
} else if (enc > MAXENCODING) { } else if (enc > MAXENCODING) {
@ -496,12 +493,6 @@ bdfReadCharacters(FontFilePtr file, FontPtr pFont, bdfFileState *pState,
* ENDFONT */ * ENDFONT */
} }
#if 0
if (ndx + nignored != nchars) {
bdfError("%d too few characters\n", nchars - (ndx + nignored));
goto BAILOUT;
}
#endif
nchars = ndx; nchars = ndx;
bitmapFont->num_chars = nchars; bitmapFont->num_chars = nchars;
if ((line) && (bdfIsPrefix(line, "STARTCHAR"))) { if ((line) && (bdfIsPrefix(line, "STARTCHAR"))) {