ref: 75de8111f83acd49a2eb75bed348cb4fac9f1e97
parent: 4db6758c0acf306c07cea834e22414d2db42b56a
author: Ralph Giles <giles@ghostscript.com>
date: Tue Feb 24 13:29:48 EST 2009
Remove trailing whitespace.
--- a/autogen.sh
+++ b/autogen.sh
@@ -78,7 +78,7 @@
echo "or get the source tarball at ftp://ftp.gnu.org/pub/gnu/"
exit 1
}
-fi
+fi
echo "Generating configuration files for $package, please wait...."
@@ -111,9 +111,9 @@
# endif /* JBIG2_REPLACE_STDINT */
#endif /* HAVE_STDINT_H */
EOF
-
+
echo " $AUTOMAKE --add-missing $AUTOMAKE_FLAGS"
-$AUTOMAKE --add-missing $AUTOMAKE_FLAGS
+$AUTOMAKE --add-missing $AUTOMAKE_FLAGS
echo " autoconf"
autoconf
--- a/jbig2.h
+++ b/jbig2.h
@@ -1,13 +1,13 @@
/*
jbig2dec
-
+
Copyright (C) 2002-2005 Artifex Software, Inc.
-
+
This software is distributed under license and may not
be copied, modified or distributed except as expressly
authorized under the terms of the license contained in
the file LICENSE in this distribution.
-
+
For information on commercial licensing, go to
http://www.artifex.com/licensing/ or contact
Artifex Software, Inc., 101 Lucas Valley Road #110,
@@ -68,7 +68,7 @@
/* errors are returned from the library via a callback. If no callback
is provided (a NULL argument is passed ot jbig2_ctx_new) a default
handler is used which prints fatal errors to the stderr stream. */
-
+
/* error callback */
typedef int (*Jbig2ErrorCallback) (void *data,
const char *msg, Jbig2Severity severity,
@@ -78,7 +78,7 @@
clients can better control memory usage. If a NULL is passed for
this argumennt of jbig2_ctx_new, a default allocator based on malloc()
is used. */
-
+
/* dynamic memory callbacks */
struct _Jbig2Allocator {
void *(*alloc) (Jbig2Allocator *allocator, size_t size);
--- a/jbig2_arith.h
+++ b/jbig2_arith.h
@@ -1,13 +1,13 @@
/*
jbig2dec
-
+
Copyright (C) 2001 Artifex Software, Inc.
-
+
This software is distributed under license and may not
be copied, modified or distributed except as expressly
authorized under the terms of the license contained in
the file LICENSE in this distribution.
-
+
For information on commercial licensing, go to
http://www.artifex.com/licensing/ or contact
Artifex Software, Inc., 101 Lucas Valley Road #110,
--- a/jbig2_arith_iaid.h
+++ b/jbig2_arith_iaid.h
@@ -7,7 +7,7 @@
be copied, modified or distributed except as expressly
authorized under the terms of the license contained in
the file LICENSE in this distribution.
-
+
For information on commercial licensing, go to
http://www.artifex.com/licensing/ or contact
Artifex Software, Inc., 101 Lucas Valley Road #110,
--- a/jbig2_arith_int.h
+++ b/jbig2_arith_int.h
@@ -7,7 +7,7 @@
be copied, modified or distributed except as expressly
authorized under the terms of the license contained in
the file LICENSE in this distribution.
-
+
For information on commercial licensing, go to
http://www.artifex.com/licensing/ or contact
Artifex Software, Inc., 101 Lucas Valley Road #110,
--- a/jbig2_generic.c
+++ b/jbig2_generic.c
@@ -538,7 +538,7 @@
return -1;
}
-/**
+/**
* Handler for immediate generic region segments
*/
int
--- a/jbig2_generic.h
+++ b/jbig2_generic.h
@@ -1,13 +1,13 @@
/*
jbig2dec
-
+
Copyright (C) 2002-2004 Artifex Software, Inc.
-
+
This software is distributed under license and may not
be copied, modified or distributed except as expressly
authorized under the terms of the license contained in
the file LICENSE in this distribution.
-
+
For information on commercial licensing, go to
http://www.artifex.com/licensing/ or contact
Artifex Software, Inc., 101 Lucas Valley Road #110,
--- a/jbig2_huffman.h
+++ b/jbig2_huffman.h
@@ -1,13 +1,13 @@
/*
jbig2dec
-
+
Copyright (C) 2001-2005 Artifex Software, Inc.
-
+
This software is distributed under license and may not
be copied, modified or distributed except as expressly
authorized under the terms of the license contained in
the file LICENSE in this distribution.
-
+
For information on commercial licensing, go to
http://www.artifex.com/licensing/ or contact
Artifex Software, Inc., 101 Lucas Valley Road #110,
@@ -64,7 +64,7 @@
void jbig2_huffman_advance(Jbig2HuffmanState *hs, int offset);
-int
+int
jbig2_huffman_offset(Jbig2HuffmanState *hs);
int32_t
--- a/jbig2_image.h
+++ b/jbig2_image.h
@@ -1,13 +1,13 @@
/*
jbig2dec
-
+
Copyright (C) 2001-2002 Artifex Software, Inc.
-
+
This software is distributed under license and may not
be copied, modified or distributed except as expressly
authorized under the terms of the license contained in
the file LICENSE in this distribution.
-
+
For information on commercial licensing, go to
http://www.artifex.com/licensing/ or contact
Artifex Software, Inc., 101 Lucas Valley Road #110,
--- a/jbig2_image_pbm.c
+++ b/jbig2_image_pbm.c
@@ -1,13 +1,13 @@
/*
jbig2dec
-
+
Copyright (C) 2002 Artifex Software, Inc.
-
+
This software is distributed under license and may not
be copied, modified or distributed except as expressly
authorized under the terms of the license contained in
the file LICENSE in this distribution.
-
+
For information on commercial licensing, go to
http://www.artifex.com/licensing/ or contact
Artifex Software, Inc., 101 Lucas Valley Road #110,
@@ -16,7 +16,7 @@
#ifdef HAVE_CONFIG_H
#include "config.h"
-#endif
+#endif
#include "os_types.h"
#include <stdio.h>
@@ -31,14 +31,14 @@
{
FILE *out;
int error;
-
+
if ((out = fopen(filename, "wb")) == NULL) {
fprintf(stderr, "unable to open '%s' for writing", filename);
return 1;
}
-
+
error = jbig2_image_write_pbm(image, out);
-
+
fclose(out);
return (error);
}
@@ -49,12 +49,12 @@
{
/* pbm header */
fprintf(out, "P4\n%d %d\n", image->width, image->height);
-
+
/* pbm format pads to a byte boundary, so we can
just write out the whole data buffer
NB: this assumes minimal stride for the width */
fwrite(image->data, 1, image->height*image->stride, out);
-
+
/* success */
return 0;
}
@@ -64,14 +64,14 @@
{
FILE *in;
Jbig2Image *image;
-
+
if ((in = fopen(filename, "rb")) == NULL) {
fprintf(stderr, "unable to open '%s' for reading\n", filename);
return NULL;
}
-
+
image = jbig2_image_read_pbm(ctx, in);
-
+
return (image);
}
@@ -83,7 +83,7 @@
Jbig2Image *image;
int c;
char buf[32];
-
+
/* look for 'P4' magic */
while ((c = fgetc(in)) != 'P') {
if (feof(in)) return NULL;
@@ -134,7 +134,7 @@
fprintf(stderr, "unexpected end of pbm file.\n");
jbig2_image_release(ctx, image);
return NULL;
- }
+ }
/* success */
return image;
}
--- a/jbig2_image_png.c
+++ b/jbig2_image_png.c
@@ -1,13 +1,13 @@
/*
jbig2dec
-
+
Copyright (C) 2002 Artifex Software, Inc.
-
+
This software is distributed under license and may not
be copied, modified or distributed except as expressly
authorized under the terms of the license contained in
the file LICENSE in this distribution.
-
+
For information on commercial licensing, go to
http://www.artifex.com/licensing/ or contact
Artifex Software, Inc., 101 Lucas Valley Road #110,
@@ -16,7 +16,7 @@
#ifdef HAVE_CONFIG_H
#include "config.h"
-#endif
+#endif
#include "os_types.h"
#include <stdio.h>
@@ -53,14 +53,14 @@
{
FILE *out;
int error;
-
+
if ((out = fopen(filename, "wb")) == NULL) {
fprintf(stderr, "unable to open '%s' for writing\n", filename);
return 1;
}
-
+
error = jbig2_image_write_png(image, out);
-
+
fclose(out);
return (error);
}
@@ -73,7 +73,7 @@
png_structp png;
png_infop info;
png_bytep rowpointer;
-
+
png = png_create_write_struct(PNG_LIBPNG_VER_STRING,
NULL, NULL, NULL);
if (png == NULL) {
@@ -80,7 +80,7 @@
fprintf(stderr, "unable to create png structure\n");
return 2;
}
-
+
info = png_create_info_struct(png);
if (info == NULL) {
fprintf(stderr, "unable to create png info structure\n");
@@ -102,7 +102,7 @@
/* png_init_io(png, out); */
png_set_write_fn(png, (png_voidp)out, jbig2_png_write_data,
jbig2_png_flush);
-
+
/* now we fill out the info structure with our format data */
png_set_IHDR(png, info, image->width, image->height,
1, PNG_COLOR_TYPE_GRAY, PNG_INTERLACE_NONE,
@@ -111,7 +111,7 @@
/* png natively treates 0 as black. This will convert for us */
png_set_invert_mono(png);
-
+
/* write out each row in turn */
rowpointer = (png_bytep)image->data;
for(i = 0; i < image->height; i++) {
@@ -118,10 +118,10 @@
png_write_row(png, rowpointer);
rowpointer += image->stride;
}
-
+
/* finish and clean up */
png_write_end(png, info);
png_destroy_write_struct(&png, &info);
-
+
return 0;
}
--- a/jbig2_metadata.h
+++ b/jbig2_metadata.h
@@ -1,13 +1,13 @@
/*
jbig2dec
-
+
Copyright (C) 2003 Artifex Software, Inc.
-
+
This software is distributed under license and may not
be copied, modified or distributed except as expressly
authorized under the terms of the license contained in
the file LICENSE in this distribution.
-
+
For information on commercial licensing, go to
http://www.artifex.com/licensing/ or contact
Artifex Software, Inc., 101 Lucas Valley Road #110,
--- a/jbig2_mmr.h
+++ b/jbig2_mmr.h
@@ -7,7 +7,7 @@
be copied, modified or distributed except as expressly
authorized under the terms of the license contained in
the file LICENSE in this distribution.
-
+
For information on commercial licensing, go to
http://www.artifex.com/licensing/ or contact
Artifex Software, Inc., 101 Lucas Valley Road #110,
--- a/jbig2_symbol_dict.c
+++ b/jbig2_symbol_dict.c
@@ -483,7 +483,7 @@
}
/* multiple symbols are handled as a text region */
- jbig2_decode_text_region(ctx, segment, tparams, (const Jbig2SymbolDict * const *)refagg_dicts,
+ jbig2_decode_text_region(ctx, segment, tparams, (const Jbig2SymbolDict * const *)refagg_dicts,
n_refagg_dicts, image, data, size, GR_stats, as, (Jbig2WordStream *)NULL);
SDNEWSYMS->glyphs[NSYMSDECODED] = image;
@@ -699,7 +699,7 @@
code = jbig2_arith_int_decode(IAEX, as, &exrunlength);
for(k = 0; k < exrunlength; k++)
if (exflag) {
- SDEXSYMS->glyphs[j++] = (i < m) ?
+ SDEXSYMS->glyphs[j++] = (i < m) ?
jbig2_image_clone(ctx, params->SDINSYMS->glyphs[i]) :
jbig2_image_clone(ctx, SDNEWSYMS->glyphs[i-m]);
i++;
--- a/jbig2_symbol_dict.h
+++ b/jbig2_symbol_dict.h
@@ -1,13 +1,13 @@
/*
jbig2dec
-
+
Copyright (C) 2001-2002 Artifex Software, Inc.
-
+
This software is distributed under license and may not
be copied, modified or distributed except as expressly
authorized under the terms of the license contained in
the file LICENSE in this distribution.
-
+
For information on commercial licensing, go to
http://www.artifex.com/licensing/ or contact
Artifex Software, Inc., 101 Lucas Valley Road #110,
@@ -45,12 +45,12 @@
jbig2_sd_cat(Jbig2Ctx *ctx, int n_dicts,
Jbig2SymbolDict **dicts);
-/* count the number of dictionary segments referred
+/* count the number of dictionary segments referred
to by the given segment */
int
jbig2_sd_count_referred(Jbig2Ctx *ctx, Jbig2Segment *segment);
-/* return an array of pointers to symbol dictionaries referred
+/* return an array of pointers to symbol dictionaries referred
to by a segment */
Jbig2SymbolDict **
jbig2_sd_list_referred(Jbig2Ctx *ctx, Jbig2Segment *segment);
--- a/jbig2_text.c
+++ b/jbig2_text.c
@@ -364,7 +364,7 @@
/* (3c.ix) */
#ifdef JBIG2_DEBUG
jbig2_error(ctx, JBIG2_SEVERITY_DEBUG, segment->number,
- "composing glyph id %d: %dx%d @ (%d,%d) symbol %d/%d",
+ "composing glyph id %d: %dx%d @ (%d,%d) symbol %d/%d",
ID, IB->width, IB->height, x, y, NINSTANCES + 1,
params->SBNUMINSTANCES);
#endif
--- a/jbig2_text.h
+++ b/jbig2_text.h
@@ -1,13 +1,13 @@
/*
jbig2dec
-
+
Copyright (C) 2002-2004 Artifex Software, Inc.
-
+
This software is distributed under license and may not
be copied, modified or distributed except as expressly
authorized under the terms of the license contained in
the file LICENSE in this distribution.
-
+
For information on commercial licensing, go to
http://www.artifex.com/licensing/ or contact
Artifex Software, Inc., 101 Lucas Valley Road #110,
--- a/memcmp.c
+++ b/memcmp.c
@@ -1,13 +1,13 @@
/*
jbig2dec
-
+
Copyright (C) 2001-2005 Artifex Software, Inc.
-
+
This software is distributed under license and may not
be copied, modified or distributed except as expressly
authorized under the terms of the license contained in
the file LICENSE in this distribution.
-
+
For information on commercial licensing, go to
http://www.artifex.com/licensing/ or contact
Artifex Software, Inc., 101 Lucas Valley Road #110,