summaryrefslogtreecommitdiffstats
path: root/hl/tools/gif2h5
diff options
context:
space:
mode:
authorDana Robinson <43805+derobins@users.noreply.github.com>2022-04-07 13:01:44 (GMT)
committerGitHub <noreply@github.com>2022-04-07 13:01:44 (GMT)
commit65568d75746b56ce7066337cf4c5c4aad11ff5f9 (patch)
tree4d43fd73ab9eb9c2218c7f2df21d54f7f6509bf2 /hl/tools/gif2h5
parent7a83173c7b289453e17f3026e825cb97778180cd (diff)
downloadhdf5-65568d75746b56ce7066337cf4c5c4aad11ff5f9.zip
hdf5-65568d75746b56ce7066337cf4c5c4aad11ff5f9.tar.gz
hdf5-65568d75746b56ce7066337cf4c5c4aad11ff5f9.tar.bz2
Normalization of HL library with develop (#1609)
Diffstat (limited to 'hl/tools/gif2h5')
-rw-r--r--hl/tools/gif2h5/decompress.c4
-rw-r--r--hl/tools/gif2h5/gif2mem.c34
-rw-r--r--hl/tools/gif2h5/gifread.c44
-rw-r--r--hl/tools/gif2h5/h52giftest.sh.in2
-rw-r--r--hl/tools/gif2h5/hdfgifwr.c14
-rw-r--r--hl/tools/gif2h5/writehdf.c4
6 files changed, 51 insertions, 51 deletions
diff --git a/hl/tools/gif2h5/decompress.c b/hl/tools/gif2h5/decompress.c
index 64d9643..ca33f86 100644
--- a/hl/tools/gif2h5/decompress.c
+++ b/hl/tools/gif2h5/decompress.c
@@ -178,7 +178,7 @@ Decompress(GIFIMAGEDESC *GifImageDesc, GIFHEAD *GifHead)
DataMask = (1 << ((GifHead->PackedField & 0x07) + 1)) - 1;
Raster = GifImageDesc->GIFImage;
- /* Check for image seperator */
+ /* Check for image separator */
/* Now read in values from the image descriptor */
IWidth = GifImageDesc->ImageWidth;
@@ -193,7 +193,7 @@ Decompress(GIFIMAGEDESC *GifImageDesc, GIFHEAD *GifHead)
*/
/*
- * Start reading the raster data. First we get the intial code size and
+ * Start reading the raster data. First we get the initial code size and
* compute decompressor constant values, based on this code size.
*/
diff --git a/hl/tools/gif2h5/gif2mem.c b/hl/tools/gif2h5/gif2mem.c
index c66250b..44e18e0 100644
--- a/hl/tools/gif2h5/gif2mem.c
+++ b/hl/tools/gif2h5/gif2mem.c
@@ -40,7 +40,7 @@ Gif2Mem(GIFBYTE *MemGif, GIFTOMEM *GifMemoryStruct)
{
/*
* The gif structure outline for passing data to memory is given in gif.h.
- * These pointers are redunant, should take them out in ver. 2
+ * These pointers are redundant, should take them out in ver. 2
*/
GIFHEAD * gifHead; /* GIF Header structure */
GIFIMAGEDESC ** gifImageDesc; /* Logical Image Descriptor struct */
@@ -49,22 +49,22 @@ Gif2Mem(GIFBYTE *MemGif, GIFTOMEM *GifMemoryStruct)
GIFCOMMENT ** gifComment; /* Comment Extension structure */
GIFGRAPHICCONTROL **gifGraphicControl; /* Graphic Control Extension strct */
- register GIFWORD i; /* Loop counter */
- GIFBYTE Identifier; /* Extension block identifier holder */
- GIFBYTE Label; /* Extension block label holder */
- GIFBYTE ImageCount; /* Count of the number of images in the file */
- GIFBYTE ImageArray; /* Keep the size of the array to store Images */
- GIFBYTE CommentCount;
- GIFBYTE CommentArray;
- GIFBYTE ApplicationCount;
- GIFBYTE ApplicationArray;
- GIFBYTE PlainTextCount;
- GIFBYTE PlainTextArray;
- GIFBYTE GCEflag;
- GIFBYTE aTemp;
- GIFBYTE j;
- GIFBYTE w; /* Two more variables needed only while testing */
- GIFBYTE * b; /* Endian Ordering */
+ GIFWORD i; /* Loop counter */
+ GIFBYTE Identifier; /* Extension block identifier holder */
+ GIFBYTE Label; /* Extension block label holder */
+ GIFBYTE ImageCount; /* Count of the number of images in the file */
+ GIFBYTE ImageArray; /* Keep the size of the array to store Images */
+ GIFBYTE CommentCount;
+ GIFBYTE CommentArray;
+ GIFBYTE ApplicationCount;
+ GIFBYTE ApplicationArray;
+ GIFBYTE PlainTextCount;
+ GIFBYTE PlainTextArray;
+ GIFBYTE GCEflag;
+ GIFBYTE aTemp;
+ GIFBYTE j;
+ GIFBYTE w; /* Two more variables needed only while testing */
+ GIFBYTE *b; /* Endian Ordering */
/* Allocate memory for the GIF structures */
/* Plug the structs into GifMemoryStruct at the end */
diff --git a/hl/tools/gif2h5/gifread.c b/hl/tools/gif2h5/gifread.c
index dd9e5be..3a6bcae 100644
--- a/hl/tools/gif2h5/gifread.c
+++ b/hl/tools/gif2h5/gifread.c
@@ -50,15 +50,15 @@ GetByte(const GIFBYTE *MemGif)
* Global Color Table (if any) from a GIF image file. The information
* is stored in a GIFHEAD structure.
*
- * Returns: -1 if a FILE stream error occured during the read,
- * otherwise 0 if no error occured.
+ * Returns: -1 if a FILE stream error occurred during the read,
+ * otherwise 0 if no error occurred.
*/
int
ReadGifHeader(GIFHEAD * GifHead, /* Pointer to GIF header structure */
GIFBYTE **MemGif2) /* GIF image file input FILE stream */
{
GIFWORD i; /* Loop counter */
- GIFWORD tableSize; /* Number of entires in the Global Color Table */
+ GIFWORD tableSize; /* Number of entries in the Global Color Table */
GifHead->TableSize = 0;
for (i = 0; i < 6; i++) {
@@ -103,7 +103,7 @@ ReadGifHeader(GIFHEAD * GifHead, /* Pointer to GIF header structure */
return -1;
#endif /* 0 */
- return 0; /* No FILE stream error occured */
+ return 0; /* No FILE stream error occurred */
}
/*
@@ -116,8 +116,8 @@ ReadGifHeader(GIFHEAD * GifHead, /* Pointer to GIF header structure */
** Note that the ImageSeparator field value in the GIFIMAGEDESC
** structure is assigned by the function calling ReadGifImageDesc().
**
-** Returns: -1 if a FILE stream error occured during the read,
-** otherwise 0 if no error occured.
+** Returns: -1 if a FILE stream error occurred during the read,
+** otherwise 0 if no error occurred.
*/
int
ReadGifImageDesc(GIFIMAGEDESC *GifImageDesc, /* Pointer to GIF image descriptor structure */
@@ -196,7 +196,7 @@ ReadGifImageDesc(GIFIMAGEDESC *GifImageDesc, /* Pointer to GIF image descriptor
*TempPtr++ = *(*MemGif2)++;
} while (ch1);
- return (0); /* No FILE stream error occured */
+ return (0); /* No FILE stream error occurred */
}
/*
@@ -205,8 +205,8 @@ ReadGifImageDesc(GIFIMAGEDESC *GifImageDesc, /* Pointer to GIF image descriptor
** Note that the Introducer and Label field values in the GIFGRAPHICCONTROL
** structure are assigned by the function calling ReadGifGraphicControl().
**
-** Returns: -1 if a FILE stream error occured during the read,
-** otherwise 0 if no error occured.
+** Returns: -1 if a FILE stream error occurred during the read,
+** otherwise 0 if no error occurred.
*/
int
ReadGifGraphicControl(GIFGRAPHICCONTROL *GifGraphicControl, /* Pointer to GC Extension structure */
@@ -219,7 +219,7 @@ ReadGifGraphicControl(GIFGRAPHICCONTROL *GifGraphicControl, /* Pointer to GC Ext
GifGraphicControl->GCEDump[i] = *(*MemGif2)++;
}
- return (0); /* No FILE stream error occured */
+ return (0); /* No FILE stream error occurred */
}
/*
@@ -228,8 +228,8 @@ ReadGifGraphicControl(GIFGRAPHICCONTROL *GifGraphicControl, /* Pointer to GC Ext
** Note that the Introducer and Label field values in the GIFLPLAINTEXT
** structure are assigned by the function calling ReadGifPlainText().
**
-** Returns: -1 if a FILE stream error occured during the read,
-** otherwise 0 if no error occured.
+** Returns: -1 if a FILE stream error occurred during the read,
+** otherwise 0 if no error occurred.
*/
int
ReadGifPlainText(GIFPLAINTEXT *GifPlainText, /* Pointer to Plain Text Extension structure */
@@ -256,7 +256,7 @@ ReadGifPlainText(GIFPLAINTEXT *GifPlainText, /* Pointer to Plain Text Extension
return(-1);
*/
- return (0); /* No FILE stream error occured */
+ return (0); /* No FILE stream error occurred */
}
/*
@@ -265,8 +265,8 @@ ReadGifPlainText(GIFPLAINTEXT *GifPlainText, /* Pointer to Plain Text Extension
** Note that the Introducer and Label field values in the GIFAPPLICATION
** structure are assigned by the function calling ReadGifApplication().
**
-** Returns: -1 if a FILE stream error occured during the read,
-** otherwise 0 if no error occured.
+** Returns: -1 if a FILE stream error occurred during the read,
+** otherwise 0 if no error occurred.
*/
int
ReadGifApplication(GIFAPPLICATION *GifApplication, /* Pointer to Application Extension structure */
@@ -292,7 +292,7 @@ ReadGifApplication(GIFAPPLICATION *GifApplication, /* Pointer to Application Ext
return(-1);
*/
- return (0); /* No FILE stream error occured */
+ return (0); /* No FILE stream error occurred */
}
/*
@@ -301,8 +301,8 @@ ReadGifApplication(GIFAPPLICATION *GifApplication, /* Pointer to Application Ext
** Note that the Introducer and Label field values in the GIFCOMMENT
** structure are assigned by the function calling ReadGifComment().
**
-** Returns: -1 if a FILE stream error occured during the read,
-** otherwise 0 if no error occured.
+** Returns: -1 if a FILE stream error occurred during the read,
+** otherwise 0 if no error occurred.
*/
int
ReadGifComment(GIFCOMMENT *GifComment, /* Pointer to GIF Comment Extension structure */
@@ -316,7 +316,7 @@ ReadGifComment(GIFCOMMENT *GifComment, /* Pointer to GIF Comment Extension struc
GifComment->Terminator = 0;
- return (0); /* No FILE stream error occured */
+ return (0); /* No FILE stream error occurred */
}
/*
@@ -326,8 +326,8 @@ ReadGifComment(GIFCOMMENT *GifComment, /* Pointer to GIF Comment Extension struc
** A GIF "sub-block" is a single count byte followed by 1 to 255
** additional data bytes.
**
-** Returns: A NULL pointer if a memory allocation error occured,
-** otherwise a valid pointer if no error occured.
+** Returns: A NULL pointer if a memory allocation error occurred,
+** otherwise a valid pointer if no error occurred.
*/
static GIFBYTE *
ReadDataSubBlocks(GIFBYTE **MemGif2, /* GIF image file input FILE stream */
@@ -364,7 +364,7 @@ ReadDataSubBlocks(GIFBYTE **MemGif2, /* GIF image file input FILE stream
if ((dataSize = *(*MemGif2)++) == 0)
break; /* Block Terminator encountered */
- /* Increase the buffer size to accomodate the next sub-block */
+ /* Increase the buffer size to accommodate the next sub-block */
if (!(ptr1 = ptr2 = (GIFBYTE *)realloc(ptr2, bufSize + dataSize + 1)))
return ((GIFBYTE *)NULL);
diff --git a/hl/tools/gif2h5/h52giftest.sh.in b/hl/tools/gif2h5/h52giftest.sh.in
index 2f84ef6..4f4057f 100644
--- a/hl/tools/gif2h5/h52giftest.sh.in
+++ b/hl/tools/gif2h5/h52giftest.sh.in
@@ -46,7 +46,7 @@ TOOLTEST()
# Verify the test runs with failure (return code is not 0)
# Use for testing if tool can handle error conditions like
-# illegal input, bad arguments, exeeding limits, ...
+# illegal input, bad arguments, exceeding limits, ...
TOOLTESTFAIL()
{
# for now, discard any error messages generated.
diff --git a/hl/tools/gif2h5/hdfgifwr.c b/hl/tools/gif2h5/hdfgifwr.c
index 21b14d1..7126da9 100644
--- a/hl/tools/gif2h5/hdfgifwr.c
+++ b/hl/tools/gif2h5/hdfgifwr.c
@@ -188,13 +188,13 @@ hdfWriteGIF(FILE *fp, byte *pic, int ptype, int w, int h, const byte *rmap, cons
static void
compress(int init_bits, FILE *outfile, byte *data, int len)
{
- register long fcode;
- register int i = 0;
- register int c;
- register int ent;
- register int disp;
- register int hsize_reg;
- register int hshift;
+ long fcode;
+ int i = 0;
+ int c;
+ int ent;
+ int disp;
+ int hsize_reg;
+ int hshift;
/*
* Set up the globals: g_init_bits - initial number of bits g_outfile -
diff --git a/hl/tools/gif2h5/writehdf.c b/hl/tools/gif2h5/writehdf.c
index a444cf7..b49e2a6 100644
--- a/hl/tools/gif2h5/writehdf.c
+++ b/hl/tools/gif2h5/writehdf.c
@@ -27,7 +27,7 @@
* Programmer: Unknown
*
* Modifications: pvn
- * Use the HDF5 IMAGE API to write the HDF5 image and pallete
+ * Use the HDF5 IMAGE API to write the HDF5 image and palette
*
* Date: January, 31, 2006
*
@@ -68,7 +68,7 @@ WriteHDF(GIFTOMEM GifMemoryStruct, char *HDFName)
#endif /* UNUSED */
if ((file_id = H5Fcreate(HDFName, H5F_ACC_TRUNC, H5P_DEFAULT, H5P_DEFAULT)) < 0) {
- /* error occured opening the HDF File for write */
+ /* error occurred opening the HDF File for write */
fprintf(stderr, "HDF file could not be opened for writing\n");
fprintf(stderr,
"NOTE: GIF file must be present in the same directory as the binary on UNIX systems.\n");