static void _error(int class, char *fn, unsigned int ln, char *fmt, va_list ap)
{
- char *remark;
+ char *remark = NULL;
/* check visibility of message */
switch (class) {
/* fund must be a type constructor: FIELD, FUNCTION, POINTER or
ARRAY. The pointer to the constructed type is returned.
*/
- struct type *dtp;
+ struct type *dtp = NULL;
switch (fund) {
#ifndef NOBITFIELD
* name table and read and write the names one by one. Update the ranlib table
* accordingly.
*/
+#define NNAMES 100
+
void do_names(struct outhead *headp)
{
- register char *strings;
- register int nnames = headp->oh_nname;
-#define NNAMES 100
+ char *strings = NULL;
+ int nnames = headp->oh_nname;
struct outname namebuf[NNAMES];
long xxx = OFF_CHAR(*headp);
- if ( headp->oh_nchar != (unsigned int)headp->oh_nchar ||
- (strings = malloc((unsigned int)headp->oh_nchar)) == (char *)0
+ if ( (headp->oh_nchar != (unsigned int)headp->oh_nchar) ||
+ (strings = malloc((unsigned int)headp->oh_nchar)) == (char *)0
) {
error(TRUE, "string table too big\n", NULL, NULL, NULL);
}
/* Read the operand of the given instruction.
* Create a line struct and return a pointer to it.
*/
- line_p lnp;
+ line_p lnp = NULL;
short flag;
VI(instr);
{
/* Process a data block defining occurrence */
- byte m;
+ byte m = 0;
switch(n) {
case ps_hol:
* up to date.
*/
- line_p l, text, lab;
+ line_p l, text = NULL, lab = NULL;
offset ab_off, lb_off;
line_p startscan, ncal;
short lastcid;
* a[iv] -> *tmp
*/
- line_p l;
+ line_p l = NULL;
switch(code->co_instr) {
case op_mli:
* the induction variable.
*/
- line_p load_tmp, loc, add, store_tmp, l;
+ line_p load_tmp = NULL, loc = NULL, add = NULL,
+ store_tmp = NULL, l = NULL;
add = newline(OPSHORT);
SHORT(add) = ws; /* the add instruction, can be ADI,ADU or ADS */
*/
short sz1, sz2;
- offset v;
+ offset v = 0;
line_p l;
sz1 = ws;