ports/emulators/simh/files/patch-Interdata_id__mt.c
Matthew Seaman 7c084f620e Fixes to allow building on 12-CURRENT
- fix build failures in i386 and amd64 due to compiler changes
- fix numerous compilation warnings and logical errors that may trap
  in the future
- convert all distribution files from DOS format to ease future changes
- convert legacy patch file to new naming convention

PR:		214990
Submitted by:	bob@eager.cx (maintainer)
2017-01-03 14:00:47 +00:00

27 lines
1.4 KiB
C

--- Interdata/id_mt.c.orig 2016-12-01 22:43:42 UTC
+++ Interdata/id_mt.c
@@ -368,13 +368,13 @@ switch (uptr->UCMD) {
}
if (mt_bptr) { /* any chars? */
- if (st = sim_tape_wrrecf (uptr, mtxb, mt_bptr)) /* write, err? */
+ if ((st = sim_tape_wrrecf (uptr, mtxb, mt_bptr))) /* write, err? */
r = mt_map_err (uptr, st); /* map error */
}
break; /* record done */
case MTC_WEOF: /* write eof */
- if (st = sim_tape_wrtmk (uptr)) /* write tmk, err? */
+ if ((st = sim_tape_wrtmk (uptr))) /* write tmk, err? */
r = mt_map_err (uptr, st); /* map error */
mt_sta = mt_sta | STA_EOF; /* set eof */
if (mt_arm[u]) /* set intr */
@@ -402,7 +402,7 @@ switch (uptr->UCMD) {
break;
case MTC_SPCR: /* backspace */
- if (st = sim_tape_sprecr (uptr, &tbc)) /* skip rec rev, err? */
+ if ((st = sim_tape_sprecr (uptr, &tbc))) /* skip rec rev, err? */
r = mt_map_err (uptr, st); /* map error */
break;
} /* end case */