about summary refs log tree commit diff stats
path: root/WWW/Library/Implementation/SGML.c
diff options
context:
space:
mode:
authorThomas E. Dickey <dickey@invisible-island.net>2007-04-29 20:52:12 -0400
committerThomas E. Dickey <dickey@invisible-island.net>2007-04-29 20:52:12 -0400
commit89168f60aa971ea8290d91e05557c7a21cdb22f1 (patch)
treee9c0b951a9c833d8949c542f7574f0f534ac1355 /WWW/Library/Implementation/SGML.c
parent8759afbc0bd7e698baeab1cfb8e8bf3f3df96653 (diff)
downloadlynx-snapshots-89168f60aa971ea8290d91e05557c7a21cdb22f1.tar.gz
snapshot of project "lynx", label v2-8-7dev_4b
Diffstat (limited to 'WWW/Library/Implementation/SGML.c')
-rw-r--r--WWW/Library/Implementation/SGML.c18
1 files changed, 12 insertions, 6 deletions
diff --git a/WWW/Library/Implementation/SGML.c b/WWW/Library/Implementation/SGML.c
index 235c898f..8412465f 100644
--- a/WWW/Library/Implementation/SGML.c
+++ b/WWW/Library/Implementation/SGML.c
@@ -3470,8 +3470,10 @@ static void SGML_character(HTStream *context, char c_in)
 	break;
 
     case S_tag_gap:		/* Expecting attribute or '>' */
-	if (WHITE(c))
+	if (WHITE(c)) {
+	    /* PUTC(c); - no, done as special case */
 	    break;		/* Gap between attributes */
+	}
 	if (c == '>') {		/* End of tag */
 #ifdef USE_PRETTYSRC
 	    if (!psrc_view)
@@ -3521,9 +3523,9 @@ static void SGML_character(HTStream *context, char c_in)
 			LYUpperCase(string->data);
 		}
 		PUTS(string->data);
-		if (c == '=')
-		    PUTC('=');
-		if (c == '=' || c == '>') {
+		if (c == '=' || WHITE(c))
+		    PUTC(c);
+		if (c == '=' || c == '>' || c == ' ') {
 		    if (context->current_attribute_number == INVALID)
 			PSRCSTOP(badattr);
 		    else
@@ -3546,8 +3548,10 @@ static void SGML_character(HTStream *context, char c_in)
 	break;
 
     case S_attr_gap:		/* Expecting attribute or '=' or '>' */
-	if (WHITE(c))
+	if (WHITE(c)) {
+	    PUTC(c);
 	    break;		/* Gap after attribute */
+	}
 	if (c == '>') {		/* End of tag */
 #ifdef USE_PRETTYSRC
 	    if (psrc_view) {
@@ -3584,8 +3588,10 @@ static void SGML_character(HTStream *context, char c_in)
 	break;
 
     case S_equals:		/* After attr = */
-	if (WHITE(c))
+	if (WHITE(c)) {
+	    PUTC(c);
 	    break;		/* Before attribute value */
+	}
 	if (c == '>') {		/* End of tag */
 	    CTRACE((tfp, "SGML: found = but no value\n"));
 #ifdef USE_PRETTYSRC