comparison lwasm/list.c @ 456:83a124428f44

Cause warnings to show up in the listing output.
author William Astle <lost@l-w.ca>
date Fri, 16 Feb 2018 23:24:18 -0700
parents 61580fc48f98
children 7d6eacd87370
comparison
equal deleted inserted replaced
455:cad5937314cb 456:83a124428f44
89 if (nl -> warn) 89 if (nl -> warn)
90 { 90 {
91 lwasm_error_t *e; 91 lwasm_error_t *e;
92 for (e = nl -> warn; e; e = e -> next) 92 for (e = nl -> warn; e; e = e -> next)
93 { 93 {
94 printf("Warning: %s\n", e -> mess); 94 if (of != stdout) printf("Warning: %s\n", e -> mess);
95 fprintf(of, "Warning: %s\n", e -> mess);
95 } 96 }
96 } 97 }
97 if (nc == 0) 98 if (nc == 0)
98 break; 99 break;
99 } 100 }
117 if (cl -> warn) 118 if (cl -> warn)
118 { 119 {
119 lwasm_error_t *e; 120 lwasm_error_t *e;
120 for (e = cl -> warn; e; e = e -> next) 121 for (e = cl -> warn; e; e = e -> next)
121 { 122 {
122 printf("Warning: %s\n", e -> mess); 123 if (of != stdout) printf("Warning: %s\n", e -> mess);
124 fprintf(of, "Warning: %s\n", e -> mess);
123 } 125 }
124 } 126 }
125 obytelen = cl -> outputl; 127 obytelen = cl -> outputl;
126 if (obytelen > 0) 128 if (obytelen > 0)
127 { 129 {