about summary refs log tree commit diff stats
path: root/WWW/Library/Implementation/HTGroup.c
diff options
context:
space:
mode:
authorThomas E. Dickey <dickey@invisible-island.net>1999-03-18 03:40:20 -0500
committerThomas E. Dickey <dickey@invisible-island.net>1999-03-18 03:40:20 -0500
commit79de405977ac0d7820576b353dde07ce09cedba9 (patch)
treed9c4fe55a871bb65fc0e1448764604b47083100e /WWW/Library/Implementation/HTGroup.c
parent2d9e91f9543486865c65bf1b2837b2a7a1e3d1b9 (diff)
downloadlynx-snapshots-79de405977ac0d7820576b353dde07ce09cedba9.tar.gz
snapshot of project "lynx", label v2-8-2dev_20
Diffstat (limited to 'WWW/Library/Implementation/HTGroup.c')
-rw-r--r--WWW/Library/Implementation/HTGroup.c16
1 files changed, 12 insertions, 4 deletions
diff --git a/WWW/Library/Implementation/HTGroup.c b/WWW/Library/Implementation/HTGroup.c
index 09340b30..490699d3 100644
--- a/WWW/Library/Implementation/HTGroup.c
+++ b/WWW/Library/Implementation/HTGroup.c
@@ -108,6 +108,8 @@ PRIVATE AddressDefList *parse_address_part ARGS1(FILE *, fp)
 
     for(;;) {
 	Ref *ref = (Ref*)calloc(1, sizeof(Ref));
+	if (ref == NULL)
+	    outofmem(__FILE__, "parse_address_part");
 	ref->name = NULL;
 	ref->translation = NULL;
 	StrAllocCopy(ref->name, HTlex_buffer);
@@ -162,6 +164,8 @@ PRIVATE UserDefList *parse_user_part ARGS1(FILE *, fp)
 
     for (;;) {
 	Ref *ref = (Ref*)calloc(1, sizeof(Ref));
+	if (ref == NULL)
+	    outofmem(__FILE__, "parse_user_part");
 	ref->name = NULL;
 	ref->translation = NULL;
 	StrAllocCopy(ref->name, HTlex_buffer);
@@ -220,7 +224,7 @@ PRIVATE Item *parse_item ARGS1(FILE *, fp)
 	}
 	else {
 	    if (user_def_list) {
-	        HTList_delete(user_def_list);	/* @@@@ */
+		HTList_delete(user_def_list);	/* @@@@ */
 		user_def_list = NULL;
 	    }
 	    syntax_error(fp, "Expected address part (single address or list)",
@@ -235,6 +239,8 @@ PRIVATE Item *parse_item ARGS1(FILE *, fp)
 	return NULL;
     }
     item = (Item*)calloc(1, sizeof(Item));
+    if (item == NULL)
+	outofmem(__FILE__, "parse_item");
     item->user_def_list = user_def_list;
     item->address_def_list = address_def_list;
     return item;
@@ -282,6 +288,8 @@ PUBLIC GroupDef *HTAA_parseGroupDef ARGS1(FILE *, fp)
 	return NULL;
     }
     group_def = (GroupDef*)calloc(1, sizeof(GroupDef));
+    if (group_def == NULL)
+	outofmem(__FILE__, "HTAA_parseGroupDef");
     group_def->group_name = NULL;
     group_def->item_list = item_list;
 
@@ -341,8 +349,8 @@ PRIVATE GroupDef *find_group_def ARGS2(GroupDefList *,	group_list,
 	while (NULL != (group_def = (GroupDef*)HTList_nextObject(cur))) {
 	    if (!strcmp(group_name, group_def->group_name)) {
 		return group_def;
-            }
-        }
+	    }
+	}
     }
     return NULL;
 }
@@ -661,7 +669,7 @@ PUBLIC GroupDefList *HTAA_readGroupFile ARGS1(CONST char *, filename)
     } /* cache exists */
 
     CTRACE(tfp, "HTAA_readGroupFile: reading group file `%s'\n",
-	        filename);
+		filename);
 
     if (!(fp = fopen(filename, "r"))) {
 	CTRACE(tfp, "%s '%s'\n",