summaryrefslogtreecommitdiff
diff options
context:
space:
mode:
authorPeter Hutterer <peter.hutterer@who-t.net>2010-07-01 11:35:07 +1000
committerPeter Hutterer <peter.hutterer@who-t.net>2010-11-15 13:30:39 +1000
commitf75571f9cc9c32af5415ca7273e554505de5acbf (patch)
treefe9510be2e246cb81c0fbbfaed30020ca324f109
parentcc1254e564ae1ffade8cb5a502b713175f6f24f4 (diff)
more void cast removal
Signed-off-by: Peter Hutterer <peter.hutterer@who-t.net>
-rw-r--r--src/helpers/sigtool22
-rw-r--r--src/tet3/apilib/dconfig.c6
-rw-r--r--src/tet3/apilib/dresfile.c42
-rw-r--r--src/tet3/apilib/exit.c6
-rw-r--r--src/tet3/apilib/getsysid.c2
-rw-r--r--src/tet3/apilib/remexec.c24
-rw-r--r--src/tet3/apilib/remtime.c2
-rw-r--r--src/tet3/apilib/sync.c14
-rw-r--r--src/tet3/apilib/tet_exec.c4
-rw-r--r--src/tet3/apilib/tet_fork.c54
-rw-r--r--src/tet3/apilib/tet_spawn.c38
-rw-r--r--src/tet3/apithr/api_lock.c6
-rw-r--r--src/tet3/apithr/thr_create.c22
-rw-r--r--src/tet3/apithr/thr_create.c.orig22
-rw-r--r--src/tet3/demo/master/ts/tc3.c8
-rw-r--r--src/tet3/demo/slave/ts/tc3.c10
-rw-r--r--src/tet3/dtet2lib/alarm.c32
-rw-r--r--src/tet3/dtet2lib/avmsg.c2
-rw-r--r--src/tet3/dtet2lib/errname.c2
-rw-r--r--src/tet3/dtet2lib/fcopy.c24
-rw-r--r--src/tet3/dtet2lib/fork.c2
-rw-r--r--src/tet3/dtet2lib/globals.c4
-rw-r--r--src/tet3/dtet2lib/hexdump.c14
-rw-r--r--src/tet3/dtet2lib/madir.c2
-rw-r--r--src/tet3/dtet2lib/mkdir.c16
-rw-r--r--src/tet3/dtet2lib/notty.c10
-rw-r--r--src/tet3/dtet2lib/prerror.c10
-rw-r--r--src/tet3/dtet2lib/ptstate.c2
-rw-r--r--src/tet3/dtet2lib/ptype.c2
-rw-r--r--src/tet3/dtet2lib/repcode.c2
-rw-r--r--src/tet3/dtet2lib/reqcode.c2
-rw-r--r--src/tet3/dtet2lib/rescode.c4
-rw-r--r--src/tet3/dtet2lib/rtoa.c2
-rw-r--r--src/tet3/dtet2lib/sigsafe.c16
-rw-r--r--src/tet3/dtet2lib/strstore.c2
-rw-r--r--src/tet3/dtet2lib/svote.c2
-rw-r--r--src/tet3/dtet2lib/sysent.c6
-rw-r--r--src/tet3/dtet2lib/systate.c2
-rw-r--r--src/tet3/dtet2lib/targs.c2
-rw-r--r--src/tet3/dtet2lib/tdump.c2
-rw-r--r--src/tet3/dtet2lib/tfname.c4
-rw-r--r--src/tet3/dtet2lib/trace.c16
-rw-r--r--src/tet3/inc/dtthr.h4
-rw-r--r--src/tet3/inc/sigsafe.h4
-rw-r--r--src/tet3/inetlib/connect.c4
-rw-r--r--src/tet3/inetlib/discon.c2
-rw-r--r--src/tet3/inetlib/host.c2
-rw-r--r--src/tet3/inetlib/rdwr.c28
-rw-r--r--src/tet3/inetlib/rdwr.c.orig22
-rw-r--r--src/tet3/servlib/fio.c4
-rw-r--r--src/tet3/servlib/logon.c2
-rw-r--r--src/tet3/servlib/smain.c4
-rw-r--r--src/tet3/servlib/sproc.c6
-rw-r--r--src/tet3/servlib/tctalk.c2
-rw-r--r--src/tet3/servlib/tcxconf.c2
-rw-r--r--src/tet3/servlib/titcmenv.c8
-rw-r--r--src/tet3/servlib/xdxfile.c4
-rw-r--r--src/tet3/tcc/config.c58
-rw-r--r--src/tet3/tcc/copysave.c16
-rw-r--r--src/tet3/tcc/dtcc.c4
-rw-r--r--src/tet3/tcc/environ.c4
-rw-r--r--src/tet3/tcc/error.c8
-rw-r--r--src/tet3/tcc/exec.c2
-rw-r--r--src/tet3/tcc/jnlproc.c18
-rw-r--r--src/tet3/tcc/journal.c102
-rw-r--r--src/tet3/tcc/lock.c8
-rw-r--r--src/tet3/tcc/proctab.c6
-rw-r--r--src/tet3/tcc/proctc.c24
-rw-r--r--src/tet3/tcc/proctcd.c4
-rw-r--r--src/tet3/tcc/rescode.c10
-rw-r--r--src/tet3/tcc/resdir.c4
-rw-r--r--src/tet3/tcc/rrproc.c72
-rw-r--r--src/tet3/tcc/scen1.c16
-rw-r--r--src/tet3/tcc/scen2.c10
-rw-r--r--src/tet3/tcc/scenario.c2
-rw-r--r--src/tet3/tcc/scenpp.c48
-rw-r--r--src/tet3/tcc/scentab.c4
-rw-r--r--src/tet3/tcc/sigtrap.c42
-rw-r--r--src/tet3/tcc/tcc.c28
-rw-r--r--src/tet3/tcc/tcc_in.c10
-rw-r--r--src/tet3/tcc/tcc_xt.c32
-rw-r--r--src/tet3/tcc/tool.c12
-rw-r--r--src/tet3/tcc/utils.c16
-rw-r--r--src/tet3/tccd/config.c10
-rw-r--r--src/tet3/tccd/etab.c2
-rw-r--r--src/tet3/tccd/exec.c22
-rw-r--r--src/tet3/tccd/log.c14
-rw-r--r--src/tet3/tccd/log.c.orig14
-rw-r--r--src/tet3/tccd/stcc.c2
-rw-r--r--src/tet3/tccd/tccd.c26
-rw-r--r--src/tet3/tccd/tccd_in.c22
-rw-r--r--src/tet3/tccd/tccd_xt.c20
-rw-r--r--src/tet3/tccd/tccdstart.c2
-rw-r--r--src/tet3/tccd/tsfile.c14
-rw-r--r--src/tet3/tcclib/lockfile.c4
-rw-r--r--src/tet3/tcclib/lsdir.c2
-rw-r--r--src/tet3/tcclib/lsdir.c.orig2
-rw-r--r--src/tet3/tcclib/mktmpdir.c4
-rw-r--r--src/tet3/tcclib/procdir.c16
-rw-r--r--src/tet3/tcclib/rmrf.c4
-rw-r--r--src/tet3/tcclib/sharlock.c8
-rw-r--r--src/tet3/tcclib/tcfexec.c20
-rw-r--r--src/tet3/tcm/child.c2
-rw-r--r--src/tet3/tcm/ckversion.c10
-rw-r--r--src/tet3/tcm/dtcm.c46
-rw-r--r--src/tet3/tcm/ictp.c50
-rw-r--r--src/tet3/tcm/tcm_xt.c4
-rw-r--r--src/tet3/tcm/tcmfuncs.c6
-rw-r--r--src/tet3/xresd/tfproc.c4
-rw-r--r--src/tet3/xresd/xresd.c2
-rw-r--r--src/tet3/xresd/xresproc.c12
-rw-r--r--src/tet3/xresd/xtab.c10
-rw-r--r--src/tet3/xtilib/accept.c8
-rw-r--r--src/tet3/xtilib/addr2lname.c2
-rw-r--r--src/tet3/xtilib/connect.c8
-rw-r--r--src/tet3/xtilib/discon.c2
-rw-r--r--src/tet3/xtilib/poll.c10
-rw-r--r--src/tet3/xtilib/rdwr.c6
-rw-r--r--src/tet3/xtilib/tccdaddr.c2
-rw-r--r--src/tet3/xtilib/xtierror.c18
-rw-r--r--xts5/Xlib4/XCreateWindow/commattr.mc18
-rw-r--r--xts5/lib/gc/subwindow.mc2
-rw-r--r--xts5/src/bin/mc/code.c262
-rw-r--r--xts5/src/bin/mc/error.c62
-rw-r--r--xts5/src/bin/mc/expand.c2
-rw-r--r--xts5/src/bin/mc/files.c28
-rw-r--r--xts5/src/bin/mc/gccomps.c4
-rw-r--r--xts5/src/bin/mc/ma.c12
-rw-r--r--xts5/src/bin/mc/main.c16
-rw-r--r--xts5/src/bin/mc/make.c54
-rw-r--r--xts5/src/bin/mc/mas.c14
-rw-r--r--xts5/src/bin/mc/sections.c28
-rw-r--r--xts5/src/bin/mc/set.c2
-rw-r--r--xts5/src/bin/mc/shortname.c16
-rw-r--r--xts5/src/lib/block.c6
-rw-r--r--xts5/src/lib/checkarea.c2
-rw-r--r--xts5/src/lib/delete.c2
-rw-r--r--xts5/src/lib/events.c2
-rw-r--r--xts5/src/lib/ex_startup.c4
-rw-r--r--xts5/src/lib/makeimg.c4
-rw-r--r--xts5/src/lib/pointer.c8
-rw-r--r--xts5/src/lib/report.c20
-rw-r--r--xts5/src/lib/rpt.c6
-rw-r--r--xts5/src/lib/savimage.c2
-rw-r--r--xts5/src/lib/settimeout.c6
-rw-r--r--xts5/src/lib/startup.c8
-rw-r--r--xts5/src/lib/tpstartup.c4
-rw-r--r--xts5/src/lib/verimage.c8
-rw-r--r--xts5/src/lib/winh.c38
-rw-r--r--xts5/src/libXR5/r5startup.c8
-rw-r--r--xts5/src/libXtTest/AvsForm.c2
-rw-r--r--xts5/src/libXtTest/AvsForm2.c2
-rw-r--r--xts5/src/libXtTest/AvsForm3.c2
-rw-r--r--xts5/src/libXtTest/avs_hier.c6
-rw-r--r--xts5/src/libXtTest/avs_hierd.c2
-rw-r--r--xts5/src/libXtTest/box.c4
-rw-r--r--xts5/src/libXtTest/errlook.c4
-rw-r--r--xts5/src/libXtTest/event.c4
-rw-r--r--xts5/src/libXtTest/pshpop.c8
-rw-r--r--xts5/src/libXtTest/waitfor.c4
-rw-r--r--xts5/src/libXtaw/Box.c4
-rw-r--r--xts5/src/libXtaw/Form.c2
-rw-r--r--xts5/src/libXtaw/Paned.c2
-rw-r--r--xts5/src/libXtaw/Viewport.c6
-rw-r--r--xts5/src/libXtmu/CloseHook.c2
-rw-r--r--xts5/src/libXtmu/DisplayQue.c8
-rw-r--r--xts5/src/libXtmu/LocBitmap.c2
-rw-r--r--xts5/src/libproto/ClientMng.c8
-rw-r--r--xts5/src/libproto/ConnDis.c4
-rw-r--r--xts5/src/libproto/Expect.c2
-rw-r--r--xts5/src/libproto/TestSup.c8
-rw-r--r--xts5/src/libproto/XlibNoXtst.c16
-rw-r--r--xts5/src/libproto/XlibXtst.c6
-rw-r--r--xts5/src/libproto/XstIO.c2
-rw-r--r--xts5/src/libproto/delete.c2
-rw-r--r--xts5/src/libproto/startup.c8
-rw-r--r--xts5/src/libproto/tpstartup.c4
-rw-r--r--xts5/src/xim/linklocale.c8
178 files changed, 1157 insertions, 1157 deletions
diff --git a/src/helpers/sigtool b/src/helpers/sigtool
index 6d2dadd4..85f3ace4 100644
--- a/src/helpers/sigtool
+++ b/src/helpers/sigtool
@@ -81,9 +81,9 @@ for sig in $std_sigs1 $std_sigs2
do
cat <<!EOF
#ifdef $sig
- (void) printf(" %d", $sig);
+ printf(" %d", $sig);
#else
- (void) printf(" $sig");
+ printf(" $sig");
#endif
!EOF
done > $tmp1_c
@@ -92,9 +92,9 @@ for sig in $spec_sigs
do
cat <<!EOF
#ifdef $sig
- (void) printf(" %d", $sig);
+ printf(" %d", $sig);
#else
- (void) printf(" $sig");
+ printf(" $sig");
#endif
!EOF
done > $tmp2_c
@@ -104,21 +104,21 @@ cat > $tmp3_c <<!EOF
#include <signal.h>
int main()
{
- (void) printf("SH_STD_SIGNALS =");
+ printf("SH_STD_SIGNALS =");
#include "$tmp1_c"
- (void) printf("\nSH_SPEC_SIGNALS =");
+ printf("\nSH_SPEC_SIGNALS =");
#include "$tmp2_c"
- (void) printf("\nSH_NSIG = ");
+ printf("\nSH_NSIG = ");
#ifdef NSIG
- (void) printf("%d", NSIG);
+ printf("%d", NSIG);
#else
# ifdef _NSIG
- (void) printf("%d", _NSIG);
+ printf("%d", _NSIG);
# else
- (void) printf("NSIG");
+ printf("NSIG");
# endif
#endif
- (void) printf("\n");
+ printf("\n");
return(0);
}
!EOF
diff --git a/src/tet3/apilib/dconfig.c b/src/tet3/apilib/dconfig.c
index 832ee2bb..6306dc21 100644
--- a/src/tet3/apilib/dconfig.c
+++ b/src/tet3/apilib/dconfig.c
@@ -150,7 +150,7 @@ TET_IMPORT void tet_config()
/* open the file */
if ((fp = fopen(file, "r")) == (FILE *) 0) {
err = errno;
- (void) sprintf(msg, "could not open config file \"%.*s\"",
+ sprintf(msg, "could not open config file \"%.*s\"",
MAXPATH, file);
tet_error(err, msg);
return;
@@ -181,7 +181,7 @@ TET_IMPORT void tet_config()
if (p < buf)
continue;
if (!tet_equindex(buf)) {
- (void) sprintf(msg, fmt, lcount, MAXPATH, file);
+ sprintf(msg, fmt, lcount, MAXPATH, file);
tet_error(0, msg);
continue;
}
@@ -195,6 +195,6 @@ TET_IMPORT void tet_config()
}
/* finally, close the file and return */
- (void) fclose(fp);
+ fclose(fp);
}
diff --git a/src/tet3/apilib/dresfile.c b/src/tet3/apilib/dresfile.c
index 8cf9451c..70aacfcc 100644
--- a/src/tet3/apilib/dresfile.c
+++ b/src/tet3/apilib/dresfile.c
@@ -364,7 +364,7 @@ char *data;
if (tet_minfoline(&data, 1) != 0)
{
- (void) sprintf(errbuf, fmt, data);
+ sprintf(errbuf, fmt, data);
tet_error(-tet_errno, errbuf);
tet_exit(EXIT_FAILURE);
}
@@ -414,7 +414,7 @@ int nlines;
continue;
/* generate the info line preamble and format the line */
- (void) sprintf(header, "%d|%ld %d %03d%05ld %ld %ld|",
+ sprintf(header, "%d|%ld %d %03d%05ld %ld %ld|",
TET_JNL_TC_INFO, tet_activity, tet_thistest,
tet_mysysid, tet_context, tet_block, tet_sequence++);
tet_msgform(header, lines[lnum], linebuf);
@@ -441,7 +441,7 @@ int nlines;
API_UNLOCK;
return(-1);
}
- (void) strcpy(&outbuf[bufpos], linebuf);
+ strcpy(&outbuf[bufpos], linebuf);
/* remember offset from start of outbuf */
/* (can't save pointer, as outbuf may move when grown) */
@@ -537,7 +537,7 @@ va_list ap;
else
{
inbuflen = vfprintf(fp, format, ap) + 1;
- (void) fclose(fp);
+ fclose(fp);
if (inbuflen <= (int) sizeof(defaultbuf))
{
@@ -591,7 +591,7 @@ va_list ap;
len = endp - inptr;
/* generate the info line preamble */
- (void) sprintf(linebuf, "%d|%ld %d %03d%05ld %ld %ld|",
+ sprintf(linebuf, "%d|%ld %d %03d%05ld %ld %ld|",
TET_JNL_TC_INFO, tet_activity, tet_thistest,
tet_mysysid, tet_context, tet_block, tet_sequence++);
@@ -616,7 +616,7 @@ va_list ap;
/* assemble the complete line and add it to output buffer */
- (void) strncat(linebuf, inptr, (size_t)len);
+ strncat(linebuf, inptr, (size_t)len);
if (*(inptr += len) == '\n')
inptr++; /* now points to start of next line */
len = strlen(linebuf) + 1; /* length including the null */
@@ -645,7 +645,7 @@ va_list ap;
API_UNLOCK;
return(-1);
}
- (void) strcpy(&outbuf[outpos], linebuf);
+ strcpy(&outbuf[outpos], linebuf);
/* remember offset from start of outbuf */
/* (can't save pointer, as outbuf may move when grown) */
@@ -746,7 +746,7 @@ int result;
if (tet_thistest == 0)
{
- (void) sprintf(errmsg,
+ sprintf(errmsg,
"tet_result(%d) called from test case startup or cleanup function",
result);
tet_error(0, errmsg);
@@ -770,7 +770,7 @@ int result;
tet_combined_ok = 0;
break;
}
- (void) sprintf(errmsg,
+ sprintf(errmsg,
"tet_result(): can't send result %d to XRESD",
result);
tet_error(tet_xderrno, errmsg);
@@ -790,7 +790,7 @@ int result;
resname = tet_get_code(result, (int *)NULL);
if (resname == NULL)
{
- (void) sprintf(errmsg,
+ sprintf(errmsg,
"INVALID result code %d passed to tet_result()",
result);
tet_error(0, errmsg);
@@ -932,20 +932,20 @@ char **msgs;
for (; nmsgs > 0; nmsgs--, msgs++) {
if (!*msgs && !errnum)
continue;
- (void) fprintf(stderr, "%s: %s",
+ fprintf(stderr, "%s: %s",
tet_pname, *msgs ? *msgs : "(NULL)");
if (errnum > 0) {
- (void) fprintf(stderr, ", errno = %d (%s)",
+ fprintf(stderr, ", errno = %d (%s)",
errnum, tet_errname(errnum));
}
else if (errnum < 0) {
- (void) fprintf(stderr, ", reply code = %s",
+ fprintf(stderr, ", reply code = %s",
tet_ptrepcode(errnum));
}
- (void) fprintf(stderr, "\n");
+ fprintf(stderr, "\n");
errnum = 0;
}
- (void) fflush(stderr);
+ fflush(stderr);
}
/*
@@ -1073,17 +1073,17 @@ char *msg, *outbuf;
** put errno first so as to avoid it being lost by truncation
*/
p = header;
- (void) sprintf(p, "%d|%ld|system %d", TET_JNL_TCM_INFO,
+ sprintf(p, "%d|%ld|system %d", TET_JNL_TCM_INFO,
tet_activity, tet_mysysid);
p += strlen(p);
if (errnum > 0)
- (void) sprintf(p, ", errno = %d (%s)",
+ sprintf(p, ", errno = %d (%s)",
errnum, tet_errname(errnum));
else if (errnum < 0)
- (void) sprintf(p, ", reply code = %s",
+ sprintf(p, ", reply code = %s",
tet_ptrepcode(errnum));
p += strlen(p);
- (void) sprintf(p, ": ");
+ sprintf(p, ": ");
/* Check the message format and write it into outbuf */
tet_msgform(header, msg ? msg : "(NULL)", outbuf);
@@ -1180,7 +1180,7 @@ char *header, *data, *outbuf;
/* see if the line was truncated */
if (*p1) {
- (void) sprintf(errmsg, fmt, (int) (sizeof errmsg - sizeof fmt),
+ sprintf(errmsg, fmt, (int) (sizeof errmsg - sizeof fmt),
header);
tet_error(0, errmsg);
}
@@ -1207,7 +1207,7 @@ int *abortflag;
/* file name is specified by TET_CODE communication variable */
fname = getenv("TET_CODE");
if (fname != NULL && *fname != '\0')
- (void) tet_readrescodes(fname);
+ tet_readrescodes(fname);
read_done++;
}
diff --git a/src/tet3/apilib/exit.c b/src/tet3/apilib/exit.c
index 963ca065..d5200a9d 100644
--- a/src/tet3/apilib/exit.c
+++ b/src/tet3/apilib/exit.c
@@ -120,14 +120,14 @@ TET_IMPORT void tet_logoff()
while (tet_ptab) {
pp = tet_ptab;
TET_SIGSAFE_START;
- (void) tet_ti_logoff(pp, 0);
+ tet_ti_logoff(pp, 0);
tet_ptrm(pp);
tet_ptfree(pp);
TET_SIGSAFE_END;
}
- (void) tet_sdlogoff(0);
- (void) tet_xdlogoff();
+ tet_sdlogoff(0);
+ tet_xdlogoff();
tet_ts_cleanup();
diff --git a/src/tet3/apilib/getsysid.c b/src/tet3/apilib/getsysid.c
index bc264ecd..06687174 100644
--- a/src/tet3/apilib/getsysid.c
+++ b/src/tet3/apilib/getsysid.c
@@ -94,7 +94,7 @@ struct tet_sysent *sysp;
#if TET_SNAMELEN != SNAMELEN
#error "TET_SNAMELEN != SNAMELEN"
#endif
- (void) strncpy(sysp->ts_name, entp->sy_name, sizeof(sysp->ts_name));
+ strncpy(sysp->ts_name, entp->sy_name, sizeof(sysp->ts_name));
sysp->ts_name[sizeof(sysp->ts_name) - 1] = '\0';
/* ignore the sy_tccd */
diff --git a/src/tet3/apilib/remexec.c b/src/tet3/apilib/remexec.c
index 444ec2ed..44fe17bf 100644
--- a/src/tet3/apilib/remexec.c
+++ b/src/tet3/apilib/remexec.c
@@ -176,10 +176,10 @@ register char **argv;
tet_errno = TET_ER_ERR;
return(-1);
}
- (void) sprintf(thistest, "%d", tet_thistest);
- (void) sprintf(activity, "%ld", tet_activity);
- (void) sprintf(context, "%ld", tet_context);
- (void) sprintf(block, "%ld", tet_block);
+ sprintf(thistest, "%d", tet_thistest);
+ sprintf(activity, "%ld", tet_activity);
+ sprintf(context, "%ld", tet_context);
+ sprintf(block, "%ld", tet_block);
*newargv = file;
*(newargv + TET_TCMC_THISTEST) = thistest;
*(newargv + TET_TCMC_ACTIVITY) = activity;
@@ -275,8 +275,8 @@ char *file, **argv;
/* do an auto-sync with the new process, kill the process and wait
for it a bit if this fails */
if (tet_sdasync(snid, tet_xrid, SV_EXEC_SPNO, SV_YES, SV_EXEC_TIMEOUT, (struct synreq *) 0, (int *) 0) < 0) {
- (void) tet_tckill(sysid, pid, SIGTERM);
- (void) tet_tcwait(sysid, pid, 10, (int *) 0);
+ tet_tckill(sysid, pid, SIGTERM);
+ tet_tcwait(sysid, pid, 10, (int *) 0);
errno = ENOEXEC;
tet_errno = -tet_sderrno;
return(-1L);
@@ -394,14 +394,14 @@ int *lconfp, *nconfp;
/* open the master config file */
if ((fid = tet_xdfopen(cfname)) < 0) {
- (void) sprintf(msg, fmt, MAXPATH, cfname);
+ sprintf(msg, fmt, MAXPATH, cfname);
error(0, msg, tet_ptrepcode(tet_xderrno));
return(-1);
}
/* get the config lines and close the file */
rc = getcf3(fid, confp, lconfp, nconfp);
- (void) tet_xdfclose(fid);
+ tet_xdfclose(fid);
return(rc);
}
@@ -569,14 +569,14 @@ int sysid;
for (ep = envs; ep < &envs[Nenvs]; ep++)
*ep = (char *) 0;
ep = &envs[0];
- (void) sprintf(buf, "%s=%.*s",
+ sprintf(buf, "%s=%.*s",
tetroot_name,
(int) sizeof buf - (int) sizeof tetroot_name - 1,
tetroot_value);
if ((*ep++ = tet_strstore(buf)) == (char *) 0)
rc = -1;
if (!rc && tetexec_value) {
- (void) sprintf(buf, "%s=%.*s",
+ sprintf(buf, "%s=%.*s",
tetexec_name,
(int) sizeof buf - (int) sizeof tetexec_name - 1,
tetexec_value);
@@ -598,7 +598,7 @@ int sysid;
return(rc);
/* construct target system exec config file name and send it to TCCD */
- (void) sprintf(buf, "%.*s/%s",
+ sprintf(buf, "%.*s/%s",
(int) sizeof buf - (int) sizeof ecfname - 1,
tsroot_value, ecfname);
TRACE3(tet_Ttcm, 6, "send exec config file name \"%s\" to system %s",
@@ -640,7 +640,7 @@ int sysid;
for (p1 = cconf, n = ncconf; n > 0; p1++, n--) {
if (tet_remvar(*p1, -1) != *p1)
continue;
- (void) sprintf(buf, "TET_REM%03d_%.*s", sysid % 1000,
+ sprintf(buf, "TET_REM%03d_%.*s", sysid % 1000,
(int) sizeof buf - 12, *p1);
if (BUFCHK((char **) &tconf, &ltconf, (int) ((ntconf + 1) * sizeof *tconf)) < 0)
return(-1);
diff --git a/src/tet3/apilib/remtime.c b/src/tet3/apilib/remtime.c
index 9794c553..e4d90f31 100644
--- a/src/tet3/apilib/remtime.c
+++ b/src/tet3/apilib/remtime.c
@@ -83,7 +83,7 @@ time_t *tp;
/* do something sensible if sysid is the local system */
if (sysid == tet_mysysid)
{
- (void) time(tp);
+ time(tp);
API_UNLOCK;
return 0;
}
diff --git a/src/tet3/apilib/sync.c b/src/tet3/apilib/sync.c
index e20ad757..53675e04 100644
--- a/src/tet3/apilib/sync.c
+++ b/src/tet3/apilib/sync.c
@@ -247,7 +247,7 @@ struct tet_synmsg *msgp;
char buf[100];
switch (tet_sderrno) {
case ER_DONE:
- (void) sprintf(buf,
+ sprintf(buf,
"sync event already happened, syncptno = %ld",
syncptno);
tet_error(0, buf);
@@ -362,19 +362,19 @@ int nsys;
** written out all at once;
** if this is not possible they are written out one-at-a-time
*/
- (void) sprintf(buf, "sync operation failed, syncptno = %ld, ",
+ sprintf(buf, "sync operation failed, syncptno = %ld, ",
syncptno);
p = buf + strlen(buf);
if (tet_errno == TET_ER_SYNCERR)
- (void) sprintf(p, "%sother system%s did not sync or timed out",
+ sprintf(p, "%sother system%s did not sync or timed out",
nsys > 1 ? "one or more of the " : nullstr,
nsys == 1 ? nullstr : sstr);
else if (tet_errno == TET_ER_TIMEDOUT)
- (void) sprintf(p, "request timed out");
+ sprintf(p, "request timed out");
else if (tet_errno >= 0 && tet_errno < tet_nerr)
- (void) sprintf(p, "%s", tet_errlist[tet_errno]);
+ sprintf(p, "%s", tet_errlist[tet_errno]);
else
- (void) sprintf(p, "tet_errno = %d (unknown value)", tet_errno);
+ sprintf(p, "tet_errno = %d (unknown value)", tet_errno);
if (lines)
*lp++ = tet_strstore(buf);
else
@@ -382,7 +382,7 @@ int nsys;
/* generate the per-system diagnostics */
for (tsp = statp; tsp < statp + nsys; tsp++) {
- (void) sprintf(buf, "system = %2d, state = %s",
+ sprintf(buf, "system = %2d, state = %s",
tsp->tsy_sysid, tet_systate(tsp->tsy_state));
if (lines)
*lp++ = tet_strstore(buf);
diff --git a/src/tet3/apilib/tet_exec.c b/src/tet3/apilib/tet_exec.c
index 7a11bc00..c4893276 100644
--- a/src/tet3/apilib/tet_exec.c
+++ b/src/tet3/apilib/tet_exec.c
@@ -389,8 +389,8 @@ char *file, *argv[], *envp[];
# ifndef TET_LITE /* -START-LITE-CUT- */
API_LOCK;
if (tet_xdlogon() == 0)
- (void) tet_xdxrsend(tet_xrid);
- (void) tet_sdlogon();
+ tet_xdxrsend(tet_xrid);
+ tet_sdlogon();
API_UNLOCK;
# endif /* -END-LITE-CUT- */
switch (errsave) {
diff --git a/src/tet3/apilib/tet_fork.c b/src/tet3/apilib/tet_fork.c
index ad0ac259..1106fa31 100644
--- a/src/tet3/apilib/tet_fork.c
+++ b/src/tet3/apilib/tet_fork.c
@@ -253,13 +253,13 @@ int sig;
struct sigaction sa;
if (tet_child > 0)
- (void) tet_killw(tet_child, KILLWAIT);
+ tet_killw(tet_child, KILLWAIT);
sa.sa_handler = SIG_DFL;
sa.sa_flags = 0;
- (void) sigemptyset(&sa.sa_mask);
- (void) sigaction(SIGTERM, &sa, (struct sigaction *)NULL);
- (void) kill(getpid(), SIGTERM);
+ sigemptyset(&sa.sa_mask);
+ sigaction(SIGTERM, &sa, (struct sigaction *)NULL);
+ kill(getpid(), SIGTERM);
}
# ifdef FORK1
@@ -288,8 +288,8 @@ int exitvals;
# endif
# endif /* TET_THREADS */
- (void) fflush(stdout);
- (void) fflush(stderr);
+ fflush(stdout);
+ fflush(stderr);
/* Save old value of tet_child in case of recursive calls
to tet_fork(). RESTORE tet_child BEFORE ALL RETURNS. */
@@ -342,10 +342,10 @@ int exitvals;
# else
TET_MUTEX_UNLOCK(&tet_top_mtx);
# endif
- (void) TET_THR_SIGSETMASK(SIG_SETMASK, &oldset, (sigset_t *)0);
+ TET_THR_SIGSETMASK(SIG_SETMASK, &oldset, (sigset_t *)0);
# endif /* TET_THREADS */
- (void) sprintf(buf,
+ sprintf(buf,
# ifdef FORK1
# ifdef TET_POSIX_THREADS
"fork() failed in tet_fork1() - errno %d (%s)",
@@ -386,7 +386,7 @@ int exitvals;
new_sa.sa_handler != SIG_IGN)
{
new_sa.sa_handler = SIG_DFL;
- (void) sigaction(i, &new_sa,
+ sigaction(i, &new_sa,
(struct sigaction *)NULL);
}
}
@@ -398,8 +398,8 @@ int exitvals;
/* logon again to XRESD and SYNCD */
if (tet_xdlogon() == 0)
- (void) tet_xdxrsend(tet_xrid);
- (void) tet_sdlogon();
+ tet_xdxrsend(tet_xrid);
+ tet_sdlogon();
# endif /* -END-LITE-CUT- */
# ifdef TET_THREADS
@@ -408,7 +408,7 @@ int exitvals;
# else
TET_MUTEX_UNLOCK(&tet_top_mtx);
# endif
- (void) TET_THR_SIGSETMASK(SIG_SETMASK, &oldset, (sigset_t *)0);
+ TET_THR_SIGSETMASK(SIG_SETMASK, &oldset, (sigset_t *)0);
# endif /* TET_THREADS */
/* change context to distinguish output from parent's */
@@ -438,7 +438,7 @@ int exitvals;
new_sa.sa_handler == SIG_DFL)
{
new_sa.sa_handler = sig_term;
- (void) sigaction(SIGTERM, &new_sa, (struct sigaction *)NULL);
+ sigaction(SIGTERM, &new_sa, (struct sigaction *)NULL);
}
# ifdef TET_THREADS
@@ -447,7 +447,7 @@ int exitvals;
# else
TET_MUTEX_UNLOCK(&tet_top_mtx);
# endif
- (void) TET_THR_SIGSETMASK(SIG_SETMASK, &oldset, (sigset_t *)0);
+ TET_THR_SIGSETMASK(SIG_SETMASK, &oldset, (sigset_t *)0);
# endif /* TET_THREADS */
if (parentproc != NULL)
@@ -465,7 +465,7 @@ int exitvals;
if (waittime < 0)
{
- (void) tet_killw(tet_child, KILLWAIT);
+ tet_killw(tet_child, KILLWAIT);
tet_child = savchild;
return 0;
}
@@ -477,7 +477,7 @@ int exitvals;
new_aa.waittime = waittime;
new_aa.sa.sa_handler = alrm;
new_aa.sa.sa_flags = 0;
- (void) sigemptyset(&new_aa.sa.sa_mask);
+ sigemptyset(&new_aa.sa.sa_mask);
alrm_flag = 0;
if (tet_set_alarm(&new_aa, &old_aa) == -1)
fatal(errno, "failed to set alarm", (char *)0);
@@ -487,7 +487,7 @@ int exitvals;
err = errno;
if (waittime > 0)
- (void) tet_clr_alarm(&old_aa);
+ tet_clr_alarm(&old_aa);
/* check child wait status shows valid exit code, if not
report wait status and give UNRESOLVED result */
@@ -495,13 +495,13 @@ int exitvals;
if (rtval == -1)
{
if (alrm_flag > 0)
- (void) sprintf(buf, "child process timed out");
+ sprintf(buf, "child process timed out");
else
- (void) sprintf(buf, "waitpid() failed - errno %d (%s)",
+ sprintf(buf, "waitpid() failed - errno %d (%s)",
err, tet_errname(err));
tet_infoline(buf);
tet_result(TET_UNRESOLVED);
- (void) tet_killw(tet_child, KILLWAIT);
+ tet_killw(tet_child, KILLWAIT);
switch (err)
{
@@ -534,7 +534,7 @@ int exitvals;
}
else
{
- (void) sprintf(buf,
+ sprintf(buf,
"child process gave unexpected exit code %d",
status);
tet_infoline(buf);
@@ -543,7 +543,7 @@ int exitvals;
else if (WIFSIGNALED(status))
{
status = WTERMSIG(status);
- (void) sprintf(buf,
+ sprintf(buf,
"child process was terminated by signal %d (%s)",
status, tet_signame(status));
tet_infoline(buf);
@@ -551,15 +551,15 @@ int exitvals;
else if (WIFSTOPPED(status))
{
status = WSTOPSIG(status);
- (void) sprintf(buf,
+ sprintf(buf,
"child process was stopped by signal %d (%s)",
status, tet_signame(status));
tet_infoline(buf);
- (void) tet_killw(tet_child, KILLWAIT);
+ tet_killw(tet_child, KILLWAIT);
}
else
{
- (void) sprintf(buf,
+ sprintf(buf,
"child process returned bad wait status (%#x)", status);
tet_infoline(buf);
}
@@ -589,7 +589,7 @@ unsigned int timeout;
new_aa.waittime = timeout;
new_aa.sa.sa_handler = alrm;
new_aa.sa.sa_flags = 0;
- (void) sigemptyset(&new_aa.sa.sa_mask);
+ sigemptyset(&new_aa.sa.sa_mask);
for (count = 0; count < 2; count++)
{
@@ -604,7 +604,7 @@ unsigned int timeout;
fatal(errno, "failed to set alarm", (char *)0);
pid = waitpid(child, &status, 0);
err = errno;
- (void) tet_clr_alarm(&old_aa);
+ tet_clr_alarm(&old_aa);
if (pid == child)
{
diff --git a/src/tet3/apilib/tet_spawn.c b/src/tet3/apilib/tet_spawn.c
index 1cea1018..9308b856 100644
--- a/src/tet3/apilib/tet_spawn.c
+++ b/src/tet3/apilib/tet_spawn.c
@@ -131,13 +131,13 @@ int sig;
struct sigaction sa;
if (childpid > 0)
- (void) tet_killw(childpid, KILLWAIT);
+ tet_killw(childpid, KILLWAIT);
sa.sa_handler = SIG_DFL;
sa.sa_flags = 0;
- (void) sigemptyset(&sa.sa_mask);
- (void) sigaction(SIGTERM, &sa, (struct sigaction *)NULL);
- (void) kill(getpid(), SIGTERM);
+ sigemptyset(&sa.sa_mask);
+ sigaction(SIGTERM, &sa, (struct sigaction *)NULL);
+ kill(getpid(), SIGTERM);
}
@@ -158,8 +158,8 @@ char *envp[];
return(-1);
}
- (void) fflush(stdout);
- (void) fflush(stderr);
+ fflush(stdout);
+ fflush(stderr);
# ifdef TET_THREADS
@@ -187,7 +187,7 @@ char *envp[];
# ifdef TET_THREADS
/* release all the mutexes and restore the signal mask */
tet_mtx_unlock();
- (void) TET_THR_SIGSETMASK(SIG_SETMASK, &oldset, (sigset_t *)0);
+ TET_THR_SIGSETMASK(SIG_SETMASK, &oldset, (sigset_t *)0);
# endif /* TET_THREADS */
@@ -226,9 +226,9 @@ char *envp[];
/* close the pipe and return */
if (pfd[0] >= 0)
- (void) close(pfd[0]);
+ close(pfd[0]);
if (pfd[1] >= 0)
- (void) close(pfd[1]);
+ close(pfd[1]);
return(pid);
}
@@ -279,7 +279,7 @@ int pfd[];
tet_mypid = getpid();
/* close the read side of the pipe */
- (void) close(pfd[0]);
+ close(pfd[0]);
pfd[0] = -1;
# ifdef TET_THREADS
@@ -300,7 +300,7 @@ int pfd[];
new_sa.sa_handler != SIG_IGN)
{
new_sa.sa_handler = SIG_DFL;
- (void) sigaction(i, &new_sa,
+ sigaction(i, &new_sa,
(struct sigaction *)NULL);
}
}
@@ -310,12 +310,12 @@ int pfd[];
tet_disconnect();
/* logon again to XRESD */
if (tet_xdlogon() == 0)
- (void) tet_xdxrsend(tet_xrid);
+ tet_xdxrsend(tet_xrid);
# endif /* -END-LITE-CUT- */
# ifdef TET_THREADS
tet_mtx_unlock();
- (void) TET_THR_SIGSETMASK(SIG_SETMASK, &oldset, (sigset_t *)0);
+ TET_THR_SIGSETMASK(SIG_SETMASK, &oldset, (sigset_t *)0);
# endif /* TET_THREADS */
/* change context to distinguish output from parent's */
@@ -330,19 +330,19 @@ int pfd[];
/* execute specified file */
errno = 0;
- (void) tet_exec(file, argv, envp);
+ tet_exec(file, argv, envp);
if (errno == ENOMEM)
{
/* This message is to distinguish malloc()
failure from exec() failure */
error(errno, "tet_exec() failed:", file);
- (void) fflush(stderr);
+ fflush(stderr);
}
/* send tet_errno to the parent process */
if ((rc = write(pfd[1], (void *) &tet_errno, sizeof tet_errno)) != sizeof tet_errno)
error(rc < 0 ? errno : 0,
"pipe write error in tet_spawn()", (char *) 0);
- (void) close(pfd[1]);
+ close(pfd[1]);
pfd[1] = -1;
tet_logoff();
_exit(127);
@@ -351,7 +351,7 @@ int pfd[];
/* parent process */
/* close the write side of the pipe */
- (void) close(pfd[1]);
+ close(pfd[1]);
pfd[1] = -1;
/*
@@ -378,7 +378,7 @@ int pfd[];
new_sa.sa_handler == SIG_DFL)
{
new_sa.sa_handler = sig_term;
- (void) sigaction(SIGTERM, &new_sa,
+ sigaction(SIGTERM, &new_sa,
(struct sigaction *)NULL);
}
}
@@ -462,7 +462,7 @@ int *statp;
new_sa.sa_handler == sig_term)
{
new_sa.sa_handler = SIG_DFL;
- (void) sigaction(SIGTERM, &new_sa,
+ sigaction(SIGTERM, &new_sa,
(struct sigaction *)NULL);
}
diff --git a/src/tet3/apithr/api_lock.c b/src/tet3/apithr/api_lock.c
index 7b2444fe..18bc9f7f 100644
--- a/src/tet3/apithr/api_lock.c
+++ b/src/tet3/apithr/api_lock.c
@@ -100,7 +100,7 @@ tet_api_lock(int getlock, const char *file, int line)
ownertid = TET_THR_SELF();
/* now it's safe to store the old signal set */
- (void) memcpy((void *)&oset, (void *)&tmpset, sizeof oset);
+ memcpy((void *)&oset, (void *)&tmpset, sizeof oset);
}
nestlevel++;
@@ -118,11 +118,11 @@ tet_api_lock(int getlock, const char *file, int line)
if (nestlevel == 0)
{
/* copy signal set to safe storage before unlocking */
- (void) memcpy((void *)&tmpset, (void *)&oset, sizeof oset);
+ memcpy((void *)&tmpset, (void *)&oset, sizeof oset);
TET_MUTEX_UNLOCK(&tet_top_mtx);
- (void) TET_THR_SIGSETMASK(SIG_SETMASK, &tmpset, (sigset_t *)0);
+ TET_THR_SIGSETMASK(SIG_SETMASK, &tmpset, (sigset_t *)0);
}
}
}
diff --git a/src/tet3/apithr/thr_create.c b/src/tet3/apithr/thr_create.c
index 651296a7..32acec0e 100644
--- a/src/tet3/apithr/thr_create.c
+++ b/src/tet3/apithr/thr_create.c
@@ -440,7 +440,7 @@ int sig;
/* wrong thread received SIGABRT signal - try to do what it
would have done */
- (void) sigaction(SIGABRT, &oldsigact, (struct sigaction *)NULL);
+ sigaction(SIGABRT, &oldsigact, (struct sigaction *)NULL);
if (oldsigact.sa_handler == SIG_DFL)
{
abort();
@@ -468,7 +468,7 @@ int sig;
}
if (tet_child > 0)
- (void) tet_killw(tet_child, KILLWAIT);
+ tet_killw(tet_child, KILLWAIT);
TET_THR_EXIT((void *)0);
}
@@ -489,7 +489,7 @@ int signum;
MTX_LOCK(&tet_thrtab_mtx);
- (void) TET_COND_INIT(&thrwait_cv);
+ TET_COND_INIT(&thrwait_cv);
/* Start at the end of the table and work backwards. This is
so that if a call to tet_pthread_join() is in progress, the
@@ -537,19 +537,19 @@ int signum;
*/
if (!TET_THR_EQUAL(ttp->tid, tid2))
- (void) TET_THR_JOIN(ttp->tid, (void **) NULL);
+ TET_THR_JOIN(ttp->tid, (void **) NULL);
TET_MUTEX_LOCK(&tet_thrwait_mtx);
joined = 1;
- (void) TET_COND_SIGNAL(&thrwait_cv);
+ TET_COND_SIGNAL(&thrwait_cv);
TET_MUTEX_UNLOCK(&tet_thrwait_mtx);
- (void) TET_THR_JOIN(tid2, (void **) NULL);
+ TET_THR_JOIN(tid2, (void **) NULL);
tet_listremove((struct llist **) &thrtab, (struct llist *) ttp);
TRACE2(tet_Tbuf, 6, "free thrtab entry = %s", tet_i2x(ttp));
free((void *)ttp);
}
thrtab = NULL;
- (void) TET_COND_DESTROY(&thrwait_cv);
+ TET_COND_DESTROY(&thrwait_cv);
MTX_UNLOCK(&tet_thrtab_mtx);
}
@@ -591,8 +591,8 @@ void *arg;
target_tid = carg->tid;
sa.sa_handler = make_thr_exit;
sa.sa_flags = 0;
- (void) sigemptyset(&sa.sa_mask);
- (void) sigaction(SIGABRT, &sa, &oldsigact);
+ sigemptyset(&sa.sa_mask);
+ sigaction(SIGABRT, &sa, &oldsigact);
err = TET_THR_KILL(carg->tid, SIGABRT);
switch (err)
{
@@ -600,7 +600,7 @@ void *arg;
break;
case ESRCH:
/* thread has gone away already */
- (void) sigaction(SIGABRT, &oldsigact, (struct sigaction *)0);
+ sigaction(SIGABRT, &oldsigact, (struct sigaction *)0);
return (void *)0;
default:
fatal(err, "TET_THR_KILL() failed in cln_thr2()", (char *)0);
@@ -620,7 +620,7 @@ void *arg;
err = 0;
TET_MUTEX_UNLOCK(&tet_thrwait_mtx);
if (err == 0)
- (void) sigaction(SIGABRT, &oldsigact, (struct sigaction *)0);
+ sigaction(SIGABRT, &oldsigact, (struct sigaction *)0);
else if (1
#ifdef ETIME
&& err != ETIME
diff --git a/src/tet3/apithr/thr_create.c.orig b/src/tet3/apithr/thr_create.c.orig
index 6262b146..c8ab2fc1 100644
--- a/src/tet3/apithr/thr_create.c.orig
+++ b/src/tet3/apithr/thr_create.c.orig
@@ -299,7 +299,7 @@ int sig;
/* wrong thread received SIGABRT signal - try to do what it
would have done */
- (void) sigaction(SIGABRT, &oldsigact, (struct sigaction *)NULL);
+ sigaction(SIGABRT, &oldsigact, (struct sigaction *)NULL);
if (oldsigact.sa_handler == SIG_DFL)
{
abort();
@@ -327,7 +327,7 @@ int sig;
}
if (tet_child > 0)
- (void) tet_killw(tet_child, KILLWAIT);
+ tet_killw(tet_child, KILLWAIT);
TET_THR_EXIT((void *)0);
}
@@ -348,7 +348,7 @@ int signum;
MTX_LOCK(&tet_thrtab_mtx);
- (void) TET_COND_INIT(&thrwait_cv);
+ TET_COND_INIT(&thrwait_cv);
for (ttp = thrtab; ttp; ttp = ttpnext)
{
@@ -385,19 +385,19 @@ int signum;
*/
if (!TET_THR_EQUAL(ttp->tid, tid2))
- (void) TET_THR_JOIN(ttp->tid, (void **) NULL);
+ TET_THR_JOIN(ttp->tid, (void **) NULL);
TET_MUTEX_LOCK(&tet_thrwait_mtx);
joined = 1;
- (void) TET_COND_SIGNAL(&thrwait_cv);
+ TET_COND_SIGNAL(&thrwait_cv);
TET_MUTEX_UNLOCK(&tet_thrwait_mtx);
- (void) TET_THR_JOIN(tid2, (void **) NULL);
+ TET_THR_JOIN(tid2, (void **) NULL);
tet_listremove((struct llist **) &thrtab, (struct llist *) ttp);
TRACE2(tet_Tbuf, 6, "free thrtab entry = %s", tet_i2x(ttp));
free((void *)ttp);
}
thrtab = NULL;
- (void) TET_COND_DESTROY(&thrwait_cv);
+ TET_COND_DESTROY(&thrwait_cv);
MTX_UNLOCK(&tet_thrtab_mtx);
}
@@ -439,8 +439,8 @@ void *arg;
target_tid = carg->tid;
sa.sa_handler = make_thr_exit;
sa.sa_flags = 0;
- (void) sigemptyset(&sa.sa_mask);
- (void) sigaction(SIGABRT, &sa, &oldsigact);
+ sigemptyset(&sa.sa_mask);
+ sigaction(SIGABRT, &sa, &oldsigact);
err = TET_THR_KILL(carg->tid, SIGABRT);
switch (err)
{
@@ -448,7 +448,7 @@ void *arg;
break;
case ESRCH:
/* thread has gone away already */
- (void) sigaction(SIGABRT, &oldsigact, (struct sigaction *)0);
+ sigaction(SIGABRT, &oldsigact, (struct sigaction *)0);
return (void *)0;
default:
fatal(err, "TET_THR_KILL() failed in cln_thr2()", (char *)0);
@@ -468,7 +468,7 @@ void *arg;
err = 0;
TET_MUTEX_UNLOCK(&tet_thrwait_mtx);
if (err == 0)
- (void) sigaction(SIGABRT, &oldsigact, (struct sigaction *)0);
+ sigaction(SIGABRT, &oldsigact, (struct sigaction *)0);
else if (err != ETIME)
fatal(err, "TET_COND_TIMEDWAIT() failed in cln_thr2()",
(char *) 0);
diff --git a/src/tet3/demo/master/ts/tc3.c b/src/tet3/demo/master/ts/tc3.c
index 3a93eea8..7d178b6d 100644
--- a/src/tet3/demo/master/ts/tc3.c
+++ b/src/tet3/demo/master/ts/tc3.c
@@ -55,12 +55,12 @@ char *rptstr; /* failure to report */
else if (err > 0 && err < tet_nerr)
errstr = tet_errlist[err];
else {
- (void) sprintf(errbuf, "unknown tet_errno value %d", tet_errno);
+ sprintf(errbuf, "unknown tet_errno value %d", tet_errno);
errstr = errbuf;
}
if (tet_printf("%s%s%s", rptstr, colonstr, errstr) < 0) {
- (void) fprintf(stderr, "tet_printf() failed: tet_errno %d\n",
+ fprintf(stderr, "tet_printf() failed: tet_errno %d\n",
tet_errno);
exit(EXIT_FAILURE);
}
@@ -70,7 +70,7 @@ static void tp1()
{
tet_infoline("This is tp1 in the third test case (tc3, master)");
- (void) tet_printf("sync with slave (sysid: %d)", *sys1);
+ tet_printf("sync with slave (sysid: %d)", *sys1);
if (tet_remsync(101L, sys1, 1, TIMEOUT, TET_SV_YES,
(struct tet_synmsg *)0) != 0) {
@@ -89,7 +89,7 @@ static void tp2()
tet_infoline("This is tp2 in the third test case (tc3, master)");
- (void) tet_printf("send message \"%s\" to slave (sysid: %d)",
+ tet_printf("send message \"%s\" to slave (sysid: %d)",
tdata, *sys1);
msg.tsm_flags = TET_SMSNDMSG;
diff --git a/src/tet3/demo/slave/ts/tc3.c b/src/tet3/demo/slave/ts/tc3.c
index a7966290..84b98237 100644
--- a/src/tet3/demo/slave/ts/tc3.c
+++ b/src/tet3/demo/slave/ts/tc3.c
@@ -55,12 +55,12 @@ char *rptstr; /* failure to report */
else if (err > 0 && err < tet_nerr)
errstr = tet_errlist[err];
else {
- (void) sprintf(errbuf, "unknown tet_errno value %d", tet_errno);
+ sprintf(errbuf, "unknown tet_errno value %d", tet_errno);
errstr = errbuf;
}
if (tet_printf("%s%s%s", rptstr, colonstr, errstr) < 0) {
- (void) fprintf(stderr, "tet_printf() failed: tet_errno %d\n",
+ fprintf(stderr, "tet_printf() failed: tet_errno %d\n",
tet_errno);
exit(EXIT_FAILURE);
}
@@ -70,7 +70,7 @@ static void tp1()
{
tet_infoline("This is tp1 in the third test case (tc3, slave)");
- (void) tet_printf("sync with master (sysid: %d)", *sys0);
+ tet_printf("sync with master (sysid: %d)", *sys0);
if (tet_remsync(101L, sys0, 1, TIMEOUT, TET_SV_YES,
(struct tet_synmsg *)0) != 0) {
@@ -89,7 +89,7 @@ static void tp2()
tet_infoline("This is tp2 in the third test case (tc3, slave)");
- (void) tet_printf("sync with master (sysid: %d) and receive data",
+ tet_printf("sync with master (sysid: %d) and receive data",
*sys0);
msg.tsm_flags = TET_SMRCVMSG;
@@ -106,7 +106,7 @@ static void tp2()
error(0, "tet_remsync() set tsm_dlen <= 0 on slave");
else
{
- (void) tet_printf("received message \"%.*s\" from master",
+ tet_printf("received message \"%.*s\" from master",
msg.tsm_dlen, rcvbuf);
rescode = TET_PASS;
}
diff --git a/src/tet3/dtet2lib/alarm.c b/src/tet3/dtet2lib/alarm.c
index 0e182e4c..406298c1 100644
--- a/src/tet3/dtet2lib/alarm.c
+++ b/src/tet3/dtet2lib/alarm.c
@@ -134,11 +134,11 @@ struct alrmaction *new_aa, *old_aa;
/* SIGALRM is blocked between tet_sigsafe_start/end calls,
so unblock it. (This means the handler mustn't longjmp.) */
- (void) sigemptyset(&alrmset);
- (void) sigaddset(&alrmset, SIGALRM);
- (void) sigprocmask(SIG_UNBLOCK, &alrmset, &old_aa->mask);
+ sigemptyset(&alrmset);
+ sigaddset(&alrmset, SIGALRM);
+ sigprocmask(SIG_UNBLOCK, &alrmset, &old_aa->mask);
- (void) alarm(new_aa->waittime);
+ alarm(new_aa->waittime);
#else /* TET_THREADS */
@@ -166,7 +166,7 @@ struct alrmaction *new_aa, *old_aa;
TRACE2(tet_Tbuf, 6, "allocate condition variable = %s",
tet_i2x(alrmarg->cvp));
- (void) TET_COND_INIT(alrmarg->cvp);
+ TET_COND_INIT(alrmarg->cvp);
/* call alrm_thr() in a new thread */
alrmarg->waittime = new_aa->waittime;
@@ -176,7 +176,7 @@ struct alrmaction *new_aa, *old_aa;
err = TET_THR_CREATE(alrm_thr, (void *) alrmarg, &old_aa->join_tid);
if (err != 0)
{
- (void) TET_COND_DESTROY(alrmarg->cvp);
+ TET_COND_DESTROY(alrmarg->cvp);
TRACE2(tet_Tbuf, 6, "free condition variable = %s",
tet_i2x(alrmarg->cvp));
free((void *)alrmarg->cvp);
@@ -193,9 +193,9 @@ struct alrmaction *new_aa, *old_aa;
* action and send a SIGALRM to this thread.
*/
- (void) sigemptyset(&alrmset);
- (void) sigaddset(&alrmset, SIGALRM);
- (void) TET_THR_SIGSETMASK(SIG_UNBLOCK, &alrmset, &old_aa->mask);
+ sigemptyset(&alrmset);
+ sigaddset(&alrmset, SIGALRM);
+ TET_THR_SIGSETMASK(SIG_UNBLOCK, &alrmset, &old_aa->mask);
old_aa->cvp = alrmarg->cvp;
/* note alrmarg is freed in alrm_thr() */
@@ -253,7 +253,7 @@ void *varg;
MTX_UNLOCK(&tet_alarm_mtx);
if (err == 0)
{
- (void) TET_COND_DESTROY(cvp);
+ TET_COND_DESTROY(cvp);
TRACE2(tet_Tbuf, 6, "free condition variable = %s",
tet_i2x(cvp));
free((void *)cvp);
@@ -293,11 +293,11 @@ void *varg;
"second TET_COND_TIMEDWAIT() timed out in alrm_thr()",
(char *)0);
- (void) sigaction(SIGALRM, &oldsigact, (struct sigaction *)0);
+ sigaction(SIGALRM, &oldsigact, (struct sigaction *)0);
MTX_UNLOCK(&tet_sigalrm_mtx);
- (void) TET_COND_DESTROY(cvp);
+ TET_COND_DESTROY(cvp);
TRACE2(tet_Tbuf, 6, "free condition variable = %s", tet_i2x(cvp));
free((void *)cvp);
@@ -312,8 +312,8 @@ struct alrmaction *old_aa;
{
#ifndef TET_THREADS
- (void) alarm(0);
- (void) sigprocmask(SIG_SETMASK, &old_aa->mask, (sigset_t *)0);
+ alarm(0);
+ sigprocmask(SIG_SETMASK, &old_aa->mask, (sigset_t *)0);
if (sigaction(SIGALRM, &old_aa->sa, (struct sigaction *)0) == -1)
return -1;
@@ -326,10 +326,10 @@ struct alrmaction *old_aa;
return -1;
}
- (void) TET_THR_SIGSETMASK(SIG_SETMASK, &old_aa->mask, (sigset_t *) 0);
+ TET_THR_SIGSETMASK(SIG_SETMASK, &old_aa->mask, (sigset_t *) 0);
MTX_LOCK(&tet_alarm_mtx);
old_aa->waittime = 0; /* used as condition var */
- (void) TET_COND_SIGNAL(old_aa->cvp);
+ TET_COND_SIGNAL(old_aa->cvp);
MTX_UNLOCK(&tet_alarm_mtx);
old_aa->cvp = NULL; /* so a second call will give EINVAL */
diff --git a/src/tet3/dtet2lib/avmsg.c b/src/tet3/dtet2lib/avmsg.c
index bc0c06e7..11ffab98 100644
--- a/src/tet3/dtet2lib/avmsg.c
+++ b/src/tet3/dtet2lib/avmsg.c
@@ -108,7 +108,7 @@ register char *to;
for (n = 0; n < (int) from->av_argc; n++)
if (from->av_argv[n]) {
offset = sp - to;
- (void) tet_st2bs((char *) &offset,
+ tet_st2bs((char *) &offset,
to + AV_AVMSGSZ(n), &offst[0], 1);
for (p = from->av_argv[n]; *p; p++)
*sp++ = *p;
diff --git a/src/tet3/dtet2lib/errname.c b/src/tet3/dtet2lib/errname.c
index 52150382..2955688a 100644
--- a/src/tet3/dtet2lib/errname.c
+++ b/src/tet3/dtet2lib/errname.c
@@ -63,6 +63,6 @@ register int errnum;
if (errnum == ep->em_errno)
return(ep->em_errname);
- (void) sprintf(text, fmt, errnum);
+ sprintf(text, fmt, errnum);
return(text);
}
diff --git a/src/tet3/dtet2lib/fcopy.c b/src/tet3/dtet2lib/fcopy.c
index d3bd5ba0..cc5a9da1 100644
--- a/src/tet3/dtet2lib/fcopy.c
+++ b/src/tet3/dtet2lib/fcopy.c
@@ -137,7 +137,7 @@ char *dest;
if (dest_exists) {
dest_is_directory = S_ISDIR(st_dest.st_mode);
if (S_ISDIR(st_src.st_mode) && !dest_is_directory) {
- (void) sprintf(msg, fmt1, MAXPATH, src);
+ sprintf(msg, fmt1, MAXPATH, src);
error(ENOTDIR, msg, dest);
errno = ENOTDIR;
return(-1);
@@ -165,7 +165,7 @@ char *dest;
}
else {
len = (int) sizeof destfile - (int) strlen(dest) - 2;
- (void) sprintf(destfile, "%.*s/%.*s",
+ sprintf(destfile, "%.*s/%.*s",
(int) (sizeof destfile - 2), dest,
TET_MAX(len, 0), tet_basename(src));
dest = destfile;
@@ -177,7 +177,7 @@ char *dest;
** ignore files other than regular files
*/
if (!S_ISREG(st_src.st_mode)) {
- (void) sprintf(msg, fmt2, MAXPATH, src, MAXPATH, dest);
+ sprintf(msg, fmt2, MAXPATH, src, MAXPATH, dest);
error(0, msg, "(source is not a plain file)");
return(0);
}
@@ -210,12 +210,12 @@ char *dest;
if (dest_exists && !dest_is_directory) {
if (SRC_IS_DEST) {
- (void) sprintf(msg, fmt2, MAXPATH, src, MAXPATH, dest);
+ sprintf(msg, fmt2, MAXPATH, src, MAXPATH, dest);
error(0, msg, "(source and destination are identical)");
return(-1);
}
if (!S_ISREG(st_dest.st_mode)) {
- (void) sprintf(msg, fmt2, MAXPATH, src, MAXPATH, dest);
+ sprintf(msg, fmt2, MAXPATH, src, MAXPATH, dest);
error(0, msg,
"(destination exists and is not a plain file)");
return(-1);
@@ -240,14 +240,14 @@ char *dest;
if ((ofp = fopen(dest, "wb")) == (FILE *) 0) {
save_errno = errno;
error(errno, "can't open", dest);
- (void) fclose(ifp);
+ fclose(ifp);
errno = save_errno;
return(-1);
}
rc = 0;
while ((nread = fread(buf, sizeof buf[0], sizeof buf, ifp)) > 0) {
- (void) fwrite(buf, sizeof buf[0], (size_t) nread, ofp);
+ fwrite(buf, sizeof buf[0], (size_t) nread, ofp);
if (ferror(ofp)) {
save_errno = errno;
error(errno, "write error on", dest);
@@ -264,7 +264,7 @@ char *dest;
rc = -1;
}
- (void) fclose(ifp);
+ fclose(ifp);
if (fclose(ofp) < 0) {
save_errno = errno;
error(errno, "close error on", dest);
@@ -315,7 +315,7 @@ char *to;
&&
(len1 == len2 || isdirsep(*(to + len1)))
) {
- (void) sprintf(msg, fmt, MAXPATH, from, MAXPATH, to);
+ sprintf(msg, fmt, MAXPATH, from, MAXPATH, to);
error(0, msg, "would never return!");
return(-1);
}
@@ -337,10 +337,10 @@ char *to;
while ((dp = READDIR(dirp)) != (struct dirent *) 0) {
if (!strcmp(dp->d_name, ".") || !strcmp(dp->d_name, ".."))
continue;
- (void) sprintf(fromname, "%.*s/%.*s",
+ sprintf(fromname, "%.*s/%.*s",
(int) (sizeof fromname - 2), from,
TET_MAX(len1, 0), dp->d_name);
- (void) sprintf(toname, "%.*s/%.*s",
+ sprintf(toname, "%.*s/%.*s",
(int) (sizeof toname - 2), to,
TET_MAX(len2, 0), dp->d_name);
if ((tet_fcopy(fromname, toname) != 0) && (errno != ENOENT))
@@ -348,7 +348,7 @@ char *to;
}
save_errno = errno;
- (void) CLOSEDIR(dirp);
+ CLOSEDIR(dirp);
errno = save_errno;
return (errcount > 0 ? -1 : 0);
}
diff --git a/src/tet3/dtet2lib/fork.c b/src/tet3/dtet2lib/fork.c
index dcb10ec8..ab32e0e6 100644
--- a/src/tet3/dtet2lib/fork.c
+++ b/src/tet3/dtet2lib/fork.c
@@ -63,7 +63,7 @@ int tet_dofork()
register int rc, try;
for (try = 0; (rc = fork()) < 0 && try < 5; try++)
- (void) sleep((unsigned) TET_MAX(1 << try, 2));
+ sleep((unsigned) TET_MAX(1 << try, 2));
if (rc == 0)
tet_mypid = (int) getpid();
diff --git a/src/tet3/dtet2lib/globals.c b/src/tet3/dtet2lib/globals.c
index a65f4cc6..e2842c9c 100644
--- a/src/tet3/dtet2lib/globals.c
+++ b/src/tet3/dtet2lib/globals.c
@@ -103,7 +103,7 @@ TET_IMPORT void tet_init_globals(const char *progname, int ptype, int sysid,
tet_mysysid = sysid;
if ((p = getenv("TET_ROOT")) != (char *) 0)
- (void) sprintf(tet_root, "%.*s", (int) sizeof tet_root - 1, p);
+ sprintf(tet_root, "%.*s", (int) sizeof tet_root - 1, p);
if (!tet_libfatal)
tet_libfatal = minfatal;
@@ -124,7 +124,7 @@ static TET_NORETURN void minfatal(int err, const char *file, int line, const cha
if (tet_liberror)
(*tet_liberror)(err, file, line, s1, s2);
else
- (void) fprintf(stderr, "%s (%s, %d): %s %s\n",
+ fprintf(stderr, "%s (%s, %d): %s %s\n",
tet_progname, file, line, s1, s2 ? s2 : "");
exit(1);
}
diff --git a/src/tet3/dtet2lib/hexdump.c b/src/tet3/dtet2lib/hexdump.c
index db76c3c4..42558789 100644
--- a/src/tet3/dtet2lib/hexdump.c
+++ b/src/tet3/dtet2lib/hexdump.c
@@ -58,21 +58,21 @@ FILE *fp;
start = dp;
do {
- (void) fprintf(fp, "%#lx:", (long) start);
+ fprintf(fp, "%#lx:", (long) start);
if (start >= end)
continue;
p2 = TET_MIN(start + 16, end);
for (p1 = start; p1 < p2; p1++)
- (void) fprintf(fp, " %02x", (unsigned char) *p1);
+ fprintf(fp, " %02x", (unsigned char) *p1);
while (p1++ <= start + 16)
- (void) fprintf(fp, " ");
+ fprintf(fp, " ");
for (p1 = start; p1 < p2; p1++)
- (void) fprintf(fp, "%c",
+ fprintf(fp, "%c",
*p1 > '\040' && *p1 < '\177' ? *p1 : '.');
- (void) fprintf(fp, "\n");
+ fprintf(fp, "\n");
} while ((start += 16) < end);
- (void) fprintf(fp, "\n");
- (void) fflush(fp);
+ fprintf(fp, "\n");
+ fflush(fp);
}
diff --git a/src/tet3/dtet2lib/madir.c b/src/tet3/dtet2lib/madir.c
index 1a5c71e0..ae1d584f 100644
--- a/src/tet3/dtet2lib/madir.c
+++ b/src/tet3/dtet2lib/madir.c
@@ -68,7 +68,7 @@ char *path;
if (STAT(path, &stbuf) < 0) {
if (errno == ENOENT) {
- (void) sprintf(buf, "%.*s", (int)sizeof buf - 1, path);
+ sprintf(buf, "%.*s", (int)sizeof buf - 1, path);
rc = mkad2(buf);
}
else {
diff --git a/src/tet3/dtet2lib/mkdir.c b/src/tet3/dtet2lib/mkdir.c
index 131b4b80..2337c4a1 100644
--- a/src/tet3/dtet2lib/mkdir.c
+++ b/src/tet3/dtet2lib/mkdir.c
@@ -101,7 +101,7 @@ int mode;
break;
if (p > path) {
n = p - path;
- (void) sprintf(dir, "%.*s",
+ sprintf(dir, "%.*s",
TET_MIN(n, (int) sizeof dir - 1), path);
if (stat(dir, &stbuf) < 0)
return(-1);
@@ -162,7 +162,7 @@ char *path;
break;
if (p > path) {
n = p - path;
- (void) sprintf(dir, "%.*s",
+ sprintf(dir, "%.*s",
TET_MIN(n, (int) sizeof dir - 1), path);
if (tet_eaccess(dir, 02) < 0)
return(-1);
@@ -223,15 +223,15 @@ int mode;
argv[0] = prog;
argv[1] = path;
argv[2] = (char *) 0;
- (void) umask(~(mode & ~umask(0)) & 077);
- (void) execvp(prog, argv);
- (void) sprintf(msg, "can't exec: %s", prog);
+ umask(~(mode & ~umask(0)) & 077);
+ execvp(prog, argv);
+ sprintf(msg, "can't exec: %s", prog);
error(errno, msg, path);
_exit(~0);
/* NOTREACHED */
case -1:
save_errno = errno;
- (void) sprintf(msg, "can't fork: %s", prog);
+ sprintf(msg, "can't fork: %s", prog);
error(errno, msg, path);
errno = save_errno;
return(-2);
@@ -242,14 +242,14 @@ int mode;
break;
if (rc < 0) {
save_errno = errno;
- (void) sprintf(msg, "wait failed: %s", prog);
+ sprintf(msg, "wait failed: %s", prog);
error(errno, prog, msg);
errno = save_errno;
return(-2);
}
if (status & 0xffff) {
if ((status & 0xff00) != 0xff00) {
- (void) sprintf(msg, "%s failed:", prog);
+ sprintf(msg, "%s failed:", prog);
error(0, msg, path);
}
return(-1);
diff --git a/src/tet3/dtet2lib/notty.c b/src/tet3/dtet2lib/notty.c
index 24ffff0f..840c8fb4 100644
--- a/src/tet3/dtet2lib/notty.c
+++ b/src/tet3/dtet2lib/notty.c
@@ -72,7 +72,7 @@ void tet_tiocnotty()
# ifdef HAS_SETSID
/* easy - use setsid() to start a new session */
- (void) setsid();
+ setsid();
# else /* HAS_SETSID */
@@ -83,10 +83,10 @@ void tet_tiocnotty()
# endif
# if defined(SVR2) || defined(SVR3) || defined(SVR4) || defined(__hpux) || defined(_AIX)
- (void) setpgrp();
+ setpgrp();
# else
int pid = getpid();
- (void) setpgrp(pid, pid);
+ setpgrp(pid, pid);
# endif
@@ -96,8 +96,8 @@ void tet_tiocnotty()
** control terminal
*/
if ((ttyfd = open("/dev/tty", O_RDONLY | O_NDELAY)) >= 0) {
- (void) ioctl(ttyfd, TIOCNOTTY, 0);
- (void) close(ttyfd);
+ ioctl(ttyfd, TIOCNOTTY, 0);
+ close(ttyfd);
}
# endif /* TIOCNOTTY */
diff --git a/src/tet3/dtet2lib/prerror.c b/src/tet3/dtet2lib/prerror.c
index b02f7074..91dd0c52 100644
--- a/src/tet3/dtet2lib/prerror.c
+++ b/src/tet3/dtet2lib/prerror.c
@@ -65,20 +65,20 @@ void tet_prerror(FILE *fp, int errnum, const char *hdr, const char *file,
{
const char *s3, *s4;
- (void) fprintf(fp, "%s (%s, %d): %s",
+ fprintf(fp, "%s (%s, %d): %s",
hdr, tet_basename(file), line, s1);
if (s2 && *s2)
- (void) fprintf(fp, " %s", s2);
+ fprintf(fp, " %s", s2);
if (errnum > 0) {
s3 = ":";
if ((s4 = strerror(errnum)) == (char *) 0) {
s3 = ", errno =";
s4 = tet_errname(errnum);
}
- (void) fprintf(fp, "%s %s", s3, s4);
+ fprintf(fp, "%s %s", s3, s4);
}
- (void) putc('\n', fp);
- (void) fflush(fp);
+ putc('\n', fp);
+ fflush(fp);
errno = 0;
}
diff --git a/src/tet3/dtet2lib/ptstate.c b/src/tet3/dtet2lib/ptstate.c
index a6c1e422..ccf3115c 100644
--- a/src/tet3/dtet2lib/ptstate.c
+++ b/src/tet3/dtet2lib/ptstate.c
@@ -77,7 +77,7 @@ int state;
case PS_CONNECT:
return("CONNECT");
default:
- (void) sprintf(msg, "%s%d", text, state);
+ sprintf(msg, "%s%d", text, state);
return(msg);
}
}
diff --git a/src/tet3/dtet2lib/ptype.c b/src/tet3/dtet2lib/ptype.c
index 4547945d..8c6b67f6 100644
--- a/src/tet3/dtet2lib/ptype.c
+++ b/src/tet3/dtet2lib/ptype.c
@@ -74,7 +74,7 @@ int ptype;
case PT_STAND:
return("STANDALONE");
default:
- (void) sprintf(msg, "%s%d", text, ptype);
+ sprintf(msg, "%s%d", text, ptype);
return(msg);
}
}
diff --git a/src/tet3/dtet2lib/repcode.c b/src/tet3/dtet2lib/repcode.c
index 5d4bc381..560516d0 100644
--- a/src/tet3/dtet2lib/repcode.c
+++ b/src/tet3/dtet2lib/repcode.c
@@ -179,7 +179,7 @@ int rc;
case ER_ENOTEMPTY:
return("ER_ENOTEMPTY");
default:
- (void) sprintf(msg, "%s%d", text, rc);
+ sprintf(msg, "%s%d", text, rc);
return(msg);
}
}
diff --git a/src/tet3/dtet2lib/reqcode.c b/src/tet3/dtet2lib/reqcode.c
index 7c407c64..430df745 100644
--- a/src/tet3/dtet2lib/reqcode.c
+++ b/src/tet3/dtet2lib/reqcode.c
@@ -185,7 +185,7 @@ int request;
return("PRINT");
#endif
default:
- (void) sprintf(msg, "%s%d", text, request);
+ sprintf(msg, "%s%d", text, request);
return(msg);
}
}
diff --git a/src/tet3/dtet2lib/rescode.c b/src/tet3/dtet2lib/rescode.c
index fe7905f1..a68c1544 100644
--- a/src/tet3/dtet2lib/rescode.c
+++ b/src/tet3/dtet2lib/rescode.c
@@ -257,7 +257,7 @@ char *fname;
break;
}
- (void) fclose(fp);
+ fclose(fp);
return(rc);
}
@@ -329,7 +329,7 @@ int line;
{
char buf[128];
- (void) sprintf(buf, "%s in line %d, file", msg, line);
+ sprintf(buf, "%s in line %d, file", msg, line);
error(0, buf, file);
}
diff --git a/src/tet3/dtet2lib/rtoa.c b/src/tet3/dtet2lib/rtoa.c
index b674797f..f0ad1dff 100644
--- a/src/tet3/dtet2lib/rtoa.c
+++ b/src/tet3/dtet2lib/rtoa.c
@@ -71,7 +71,7 @@ struct remid *rp;
count = 0;
p = buf[count];
- (void) sprintf(p, fmt, rp->re_sysid, rp->re_pid,
+ sprintf(p, fmt, rp->re_sysid, rp->re_pid,
tet_ptptype(rp->re_ptype));
return(p);
}
diff --git a/src/tet3/dtet2lib/sigsafe.c b/src/tet3/dtet2lib/sigsafe.c
index 798ae5a3..adca65ce 100644
--- a/src/tet3/dtet2lib/sigsafe.c
+++ b/src/tet3/dtet2lib/sigsafe.c
@@ -72,23 +72,23 @@ TET_IMPORT void tet_init_blockable_sigs()
/* start with full set, and then remove signals that
should not be blocked */
- (void) sigfillset(&tet_blockable_sigs);
+ sigfillset(&tet_blockable_sigs);
/* the system won't allow these to be blocked */
- (void) sigdelset(&tet_blockable_sigs, SIGKILL);
- (void) sigdelset(&tet_blockable_sigs, SIGSTOP);
+ sigdelset(&tet_blockable_sigs, SIGKILL);
+ sigdelset(&tet_blockable_sigs, SIGSTOP);
/* blocking this could give problems, and it is unlikely
anyone would longjmp out of a SIGCHLD handler (no TET
code does), so it should be safe to leave it unblocked */
- (void) sigdelset(&tet_blockable_sigs, SIGCHLD);
+ sigdelset(&tet_blockable_sigs, SIGCHLD);
/* hardware signals that give undefined behaviour if blocked */
- (void) sigdelset(&tet_blockable_sigs, SIGSEGV);
- (void) sigdelset(&tet_blockable_sigs, SIGILL);
- (void) sigdelset(&tet_blockable_sigs, SIGFPE);
+ sigdelset(&tet_blockable_sigs, SIGSEGV);
+ sigdelset(&tet_blockable_sigs, SIGILL);
+ sigdelset(&tet_blockable_sigs, SIGFPE);
# ifdef SIGBUS
- (void) sigdelset(&tet_blockable_sigs, SIGBUS);
+ sigdelset(&tet_blockable_sigs, SIGBUS);
# endif
diff --git a/src/tet3/dtet2lib/strstore.c b/src/tet3/dtet2lib/strstore.c
index 6ef61d74..d0596796 100644
--- a/src/tet3/dtet2lib/strstore.c
+++ b/src/tet3/dtet2lib/strstore.c
@@ -72,7 +72,7 @@ char *s;
if ((p = malloc(len)) == (char *) 0)
error(errno, "can't get memory for string:", s);
else
- (void) strcpy(p, s);
+ strcpy(p, s);
TRACE4(tet_Tbuf, 6, "tet_strstore(\"%.24s%s\") returns %s",
s, len > 25 ? " ..." : "", tet_i2x(p));
diff --git a/src/tet3/dtet2lib/svote.c b/src/tet3/dtet2lib/svote.c
index 9df510a7..1517326e 100644
--- a/src/tet3/dtet2lib/svote.c
+++ b/src/tet3/dtet2lib/svote.c
@@ -63,7 +63,7 @@ int vote;
case SV_NO:
return("NO");
default:
- (void) sprintf(msg, "%s%d", text, vote);
+ sprintf(msg, "%s%d", text, vote);
return(msg);
}
}
diff --git a/src/tet3/dtet2lib/sysent.c b/src/tet3/dtet2lib/sysent.c
index 48c31c74..14d8c268 100644
--- a/src/tet3/dtet2lib/sysent.c
+++ b/src/tet3/dtet2lib/sysent.c
@@ -114,7 +114,7 @@ int tet_libsetsysent()
}
ASSERT(tet_root[0]);
- (void) sprintf(path, "%.*s/%s",
+ sprintf(path, "%.*s/%s",
(int) sizeof path - (int) sizeof file - 1, tet_root, file);
if ((sfp = fopen(path, "r")) == NULL) {
@@ -122,7 +122,7 @@ int tet_libsetsysent()
return(-1);
}
- (void) tet_fioclex(FILENO(sfp));
+ tet_fioclex(FILENO(sfp));
return(0);
}
@@ -133,7 +133,7 @@ int tet_libsetsysent()
void tet_libendsysent()
{
if (sfp != NULL) {
- (void) fclose(sfp);
+ fclose(sfp);
sfp = NULL;
}
}
diff --git a/src/tet3/dtet2lib/systate.c b/src/tet3/dtet2lib/systate.c
index 85c70370..7ab35e9d 100644
--- a/src/tet3/dtet2lib/systate.c
+++ b/src/tet3/dtet2lib/systate.c
@@ -72,7 +72,7 @@ int state;
case SS_DEAD:
return("DEAD");
default:
- (void) sprintf(msg, "%s%d", text, state);
+ sprintf(msg, "%s%d", text, state);
return(msg);
}
}
diff --git a/src/tet3/dtet2lib/targs.c b/src/tet3/dtet2lib/targs.c
index 0723cd48..6e162221 100644
--- a/src/tet3/dtet2lib/targs.c
+++ b/src/tet3/dtet2lib/targs.c
@@ -158,7 +158,7 @@ char **argv;
*p++ = sp->st_name;
*p++ = ',';
}
- (void) sprintf(p, "%c%d", tp->tf_name, tp->tf_value);
+ sprintf(p, "%c%d", tp->tf_name, tp->tf_value);
TRACE2(tet_Ttrace, 4, "trace arg = \"%s\"", *(ap - 1));
p += strlen(p) + 1;
}
diff --git a/src/tet3/dtet2lib/tdump.c b/src/tet3/dtet2lib/tdump.c
index 2af16ed0..f2bf7017 100644
--- a/src/tet3/dtet2lib/tdump.c
+++ b/src/tet3/dtet2lib/tdump.c
@@ -59,7 +59,7 @@ int len;
if (!tet_tfp)
tet_tfopen();
- (void) fprintf(tet_tfp, "%s:\n",
+ fprintf(tet_tfp, "%s:\n",
title && *title ? title : "data dump:");
tet_hexdump(from, len, tet_tfp);
diff --git a/src/tet3/dtet2lib/tfname.c b/src/tet3/dtet2lib/tfname.c
index 43bce3e7..0a617f55 100644
--- a/src/tet3/dtet2lib/tfname.c
+++ b/src/tet3/dtet2lib/tfname.c
@@ -158,7 +158,7 @@ char **np;
TRACE2(tet_Tbuf, 6, "allocate tfname = %s", tet_i2x(fname));
/* generate the file name */
- (void) sprintf(fname, "%s/%s%s%s", dir, prefix, &salt[1], pidstr);
+ sprintf(fname, "%s/%s%s%s", dir, prefix, &salt[1], pidstr);
/* try to open the file */
if ((fd = OPEN(fname, O_RDWR|O_CREAT|O_EXCL|O_BINARY, MODEANY)) < 0)
@@ -187,7 +187,7 @@ char **np;
break;
}
/* close the file and unlink it */
- (void) CLOSE(fd);
+ CLOSE(fd);
if (UNLINK(fname) < 0)
error(errno, "can't unlink", fname);
}
diff --git a/src/tet3/dtet2lib/trace.c b/src/tet3/dtet2lib/trace.c
index d315daa2..c05106a8 100644
--- a/src/tet3/dtet2lib/trace.c
+++ b/src/tet3/dtet2lib/trace.c
@@ -341,25 +341,25 @@ TET_IMPORT void tet_trace(const char *s1, const char *s2, const char *s3,
tet_tfopen();
#ifndef TET_THREADS
- (void) fprintf(tet_tfp, "%s (%ld)", tet_progname, (long) GETPID());
+ fprintf(tet_tfp, "%s (%ld)", tet_progname, (long) GETPID());
#else
- (void) fprintf(tet_tfp, "%s (%ld.%ld)", tet_progname, (long) GETPID(),
+ fprintf(tet_tfp, "%s (%ld.%ld)", tet_progname, (long) GETPID(),
(long) TET_THR_SELF());
#endif
if (tet_Ttrace > 0) {
now = time((time_t *) 0);
tp = localtime(&now);
if (tet_Ttrace > 1)
- (void) fprintf(tet_tfp, " %d:%02d:%02d",
+ fprintf(tet_tfp, " %d:%02d:%02d",
tp->tm_hour, tp->tm_min, tp->tm_sec);
else
- (void) fprintf(tet_tfp, " %d:%02d",
+ fprintf(tet_tfp, " %d:%02d",
tp->tm_min, tp->tm_sec);
}
- (void) fprintf(tet_tfp, ": ");
- (void) fprintf(tet_tfp, s1, s2, s3, s4, s5, s6);
- (void) putc('\n', tet_tfp);
- (void) fflush(tet_tfp);
+ fprintf(tet_tfp, ": ");
+ fprintf(tet_tfp, s1, s2, s3, s4, s5, s6);
+ putc('\n', tet_tfp);
+ fflush(tet_tfp);
errno = save_errno;
}
diff --git a/src/tet3/inc/dtthr.h b/src/tet3/inc/dtthr.h
index 4ca1fee0..d414a787 100644
--- a/src/tet3/inc/dtthr.h
+++ b/src/tet3/inc/dtthr.h
@@ -209,7 +209,7 @@ MODIFICATIONS:
# define TET_THR_EQUAL(a, b) ((a) == (b))
# define TET_THR_EXIT(sp) thr_exit((sp))
# define TET_THR_GETSPECIFIC(key, vp) \
- (*(vp) = (void *) 0, (void) thr_getspecific((key), (vp)))
+ (*(vp) = (void *) 0, thr_getspecific((key), (vp)))
# define TET_THR_JOIN(tid, sp) thr_join((tid), (thread_t *) 0, (sp))
# define TET_THR_KEYCREATE(kp) thr_keycreate((kp), TET_NULLFP)
# define TET_THR_KILL(tid, sig) thr_kill((tid), (sig))
@@ -237,7 +237,7 @@ MODIFICATIONS:
TET_THR_SIGSETMASK(SIG_BLOCK, &tet_blockable_sigs, &MTX_LOCK_oss); \
TET_MUTEX_LOCK(mp);
# define MTX_UNLOCK(mp) TET_MUTEX_UNLOCK(mp); if (MTX_LOCK_maskret == 0) \
- (void) TET_THR_SIGSETMASK(SIG_SETMASK, &MTX_LOCK_oss, (sigset_t *)0); }
+ TET_THR_SIGSETMASK(SIG_SETMASK, &MTX_LOCK_oss, (sigset_t *)0); }
/* top-level API mutex with calls that can be nested */
diff --git a/src/tet3/inc/sigsafe.h b/src/tet3/inc/sigsafe.h
index f8f9ee51..d4144dff 100644
--- a/src/tet3/inc/sigsafe.h
+++ b/src/tet3/inc/sigsafe.h
@@ -42,8 +42,8 @@ MODIFICATIONS:
** and how to call the functions themselves
*/
# define TET_SIGSAFE_DEF sigset_t oldset;
-# define TET_SIGSAFE_START (void) tet_sigsafe_start(&oldset)
-# define TET_SIGSAFE_END (void) tet_sigsafe_end(&oldset)
+# define TET_SIGSAFE_START tet_sigsafe_start(&oldset)
+# define TET_SIGSAFE_END tet_sigsafe_end(&oldset)
/* set of all blockable signals (to be blocked during critical code) */
TET_EXPORT_DATA(sigset_t, tet_blockable_sigs);
diff --git a/src/tet3/inetlib/connect.c b/src/tet3/inetlib/connect.c
index c129c278..e6c239b7 100644
--- a/src/tet3/inetlib/connect.c
+++ b/src/tet3/inetlib/connect.c
@@ -124,7 +124,7 @@ register struct ptab *pp;
pp->pt_flags |= PF_ATTENTION;
return;
}
- (void) close(sd);
+ close(sd);
sd = nsd;
}
@@ -164,7 +164,7 @@ register struct ptab *pp;
}
/* else fall through */
default:
- (void) sprintf(msg, fmt,
+ sprintf(msg, fmt,
inet_ntoa(tp->tp_sin.sin_addr),
(int) ntohs(tp->tp_sin.sin_port));
error(err, msg, tet_r2a(&pp->pt_rid));
diff --git a/src/tet3/inetlib/discon.c b/src/tet3/inetlib/discon.c
index f5274a43..04b4f389 100644
--- a/src/tet3/inetlib/discon.c
+++ b/src/tet3/inetlib/discon.c
@@ -71,7 +71,7 @@ struct ptab *pp;
tet_i2a(tp->tp_sd));
if (tp->tp_sd != INVALID_SOCKET) {
- (void) SOCKET_CLOSE(tp->tp_sd);
+ SOCKET_CLOSE(tp->tp_sd);
tp->tp_sd = INVALID_SOCKET;
}
diff --git a/src/tet3/inetlib/host.c b/src/tet3/inetlib/host.c
index 9654ee50..c8e14fd8 100644
--- a/src/tet3/inetlib/host.c
+++ b/src/tet3/inetlib/host.c
@@ -112,7 +112,7 @@ char *host;
cp2->hc_addr = *((struct in_addr *) hp->h_addr);
cp2->hc_refcnt = 1;
- (void) sprintf(cp2->hc_host, "%.*s",
+ sprintf(cp2->hc_host, "%.*s",
(int) sizeof cp2->hc_host - 1, host);
return(&cp2->hc_addr);
diff --git a/src/tet3/inetlib/rdwr.c b/src/tet3/inetlib/rdwr.c
index 23c350d8..52180c1e 100644
--- a/src/tet3/inetlib/rdwr.c
+++ b/src/tet3/inetlib/rdwr.c
@@ -119,7 +119,7 @@ register struct ptab *pp;
}
TDUMP(tet_Tio, 10, tp->tp_buf, DM_HDRSZ, msghdr);
pp->pt_flags &= ~PF_RCVHDR;
- (void) tet_bs2dtmhdr(tp->tp_buf, &pp->ptm_hdr, DM_HDRSZ);
+ tet_bs2dtmhdr(tp->tp_buf, &pp->ptm_hdr, DM_HDRSZ);
if (pp->ptm_magic != DTM_MAGIC && pp->ptm_len) {
/* we are probably out of sync with sender */
error(0, "received bad message header,",
@@ -249,7 +249,7 @@ register struct ptab *pp;
ignsa.sa_handler = SIG_IGN;
ignsa.sa_flags = 0;
- (void) sigemptyset(&ignsa.sa_mask);
+ sigemptyset(&ignsa.sa_mask);
/* set up variables for this message on first time through */
if ((pp->pt_flags & PF_INPROGRESS) == 0) {
@@ -278,7 +278,7 @@ register struct ptab *pp;
rc, msgdata);
tp->tp_cnt += rc;
}
- (void) tet_dmlen2bs(rc, tp->tp_buf);
+ tet_dmlen2bs(rc, tp->tp_buf);
} while (err);
tp->tp_ptr = tp->tp_buf;
pp->pt_flags |= PF_INPROGRESS;
@@ -292,13 +292,13 @@ register struct ptab *pp;
Signals just cause the write to be restarted (in an attempt
to cope with systems without restartable system calls) */
# ifndef TET_THREADS
- (void) sigaction(SIGPIPE, &ignsa, &oldsa);
+ sigaction(SIGPIPE, &ignsa, &oldsa);
# else
/* just block the signal for now so as to avoid interfering with
another thread's usage of SIGPIPE */
- (void) sigemptyset(&newset);
- (void) sigaddset(&newset, SIGPIPE);
- (void) TET_THR_SIGSETMASK(SIG_BLOCK, &newset, &oldset);
+ sigemptyset(&newset);
+ sigaddset(&newset, SIGPIPE);
+ TET_THR_SIGSETMASK(SIG_BLOCK, &newset, &oldset);
# endif /* TET_THREADS */
do {
@@ -308,7 +308,7 @@ register struct ptab *pp;
} while (rc < 0 && err == SOCKET_EINTR);
# ifndef TET_THREADS
- (void) sigaction(SIGPIPE, &oldsa, (struct sigaction *)NULL);
+ sigaction(SIGPIPE, &oldsa, (struct sigaction *)NULL);
# else
if (rc < 0 && (err == EPIPE || err == ECONNRESET))
{
@@ -317,15 +317,15 @@ register struct ptab *pp;
with another thread's usage of SIGPIPE, but the
chances are very small. Note that we unblock SIGPIPE
explicitly, since it may be a member of "oldset". */
- (void) sigaction(SIGPIPE, &ignsa, &oldsa);
- (void) TET_THR_SIGSETMASK(SIG_UNBLOCK, &newset, (sigset_t *) 0);
+ sigaction(SIGPIPE, &ignsa, &oldsa);
+ TET_THR_SIGSETMASK(SIG_UNBLOCK, &newset, (sigset_t *) 0);
/* now restore the original mask and handler */
- (void) TET_THR_SIGSETMASK(SIG_SETMASK, &oldset, (sigset_t *) 0);
- (void) sigaction(SIGPIPE, &oldsa, (struct sigaction *)NULL);
+ TET_THR_SIGSETMASK(SIG_SETMASK, &oldset, (sigset_t *) 0);
+ sigaction(SIGPIPE, &oldsa, (struct sigaction *)NULL);
}
else
- (void) TET_THR_SIGSETMASK(SIG_SETMASK, &oldset, (sigset_t *) 0);
+ TET_THR_SIGSETMASK(SIG_SETMASK, &oldset, (sigset_t *) 0);
# endif /* TET_THREADS */
/* set state and flags according to results */
@@ -452,7 +452,7 @@ register struct ptab *pp;
TRACE2(tet_Tio, 4, "tet_ts_dead: close sd %s", tet_i2a(tp->tp_sd));
- (void) SOCKET_CLOSE(tp->tp_sd);
+ SOCKET_CLOSE(tp->tp_sd);
tp->tp_sd = INVALID_SOCKET;
pp->pt_flags &= ~(PF_CONNECTED | PF_INPROGRESS);
}
diff --git a/src/tet3/inetlib/rdwr.c.orig b/src/tet3/inetlib/rdwr.c.orig
index ece32ab3..9b9a06fe 100644
--- a/src/tet3/inetlib/rdwr.c.orig
+++ b/src/tet3/inetlib/rdwr.c.orig
@@ -112,7 +112,7 @@ register struct ptab *pp;
}
TDUMP(tet_Tio, 10, tp->tp_buf, DM_HDRSZ, msghdr);
pp->pt_flags &= ~PF_RCVHDR;
- (void) tet_bs2dtmhdr(tp->tp_buf, &pp->ptm_hdr, DM_HDRSZ);
+ tet_bs2dtmhdr(tp->tp_buf, &pp->ptm_hdr, DM_HDRSZ);
if (pp->ptm_magic != DTM_MAGIC && pp->ptm_len) {
/* we are probably out of sync with sender */
error(0, "received bad message header,",
@@ -267,7 +267,7 @@ register struct ptab *pp;
rc, msgdata);
tp->tp_cnt += rc;
}
- (void) tet_dmlen2bs(rc, tp->tp_buf);
+ tet_dmlen2bs(rc, tp->tp_buf);
} while (err);
tp->tp_ptr = tp->tp_buf;
pp->pt_flags |= PF_INPROGRESS;
@@ -285,9 +285,9 @@ register struct ptab *pp;
# else
/* just block the signal for now so as to avoid interfering with
another thread's usage of SIGPIPE */
- (void) sigemptyset(&newset);
- (void) sigaddset(&newset, SIGPIPE);
- (void) TET_THR_SIGSETMASK(SIG_BLOCK, &newset, &oldset);
+ sigemptyset(&newset);
+ sigaddset(&newset, SIGPIPE);
+ TET_THR_SIGSETMASK(SIG_BLOCK, &newset, &oldset);
# endif /* TET_THREADS */
do {
@@ -297,7 +297,7 @@ register struct ptab *pp;
} while (rc < 0 && err == SOCKET_EINTR);
# ifndef TET_THREADS
- (void) signal(SIGPIPE, (SIG_FUNC_T (*) ()) pipe_save);
+ signal(SIGPIPE, (SIG_FUNC_T (*) ()) pipe_save);
# else
if (rc < 0 && (err == EPIPE || err == ECONNRESET))
{
@@ -307,14 +307,14 @@ register struct ptab *pp;
chances are very small. Note that we unblock SIGPIPE
explicitly, since it may be a member of "oldset". */
pipe_save = signal(SIGPIPE, SIG_IGN);
- (void) TET_THR_SIGSETMASK(SIG_UNBLOCK, &newset, (sigset_t *) 0);
+ TET_THR_SIGSETMASK(SIG_UNBLOCK, &newset, (sigset_t *) 0);
/* now restore the original mask and handler */
- (void) TET_THR_SIGSETMASK(SIG_SETMASK, &oldset, (sigset_t *) 0);
- (void) signal(SIGPIPE, (SIG_FUNC_T (*) ()) pipe_save);
+ TET_THR_SIGSETMASK(SIG_SETMASK, &oldset, (sigset_t *) 0);
+ signal(SIGPIPE, (SIG_FUNC_T (*) ()) pipe_save);
}
else
- (void) TET_THR_SIGSETMASK(SIG_SETMASK, &oldset, (sigset_t *) 0);
+ TET_THR_SIGSETMASK(SIG_SETMASK, &oldset, (sigset_t *) 0);
# endif /* TET_THREADS */
/* set state and flags according to results */
@@ -441,7 +441,7 @@ register struct ptab *pp;
TRACE2(tet_Tio, 4, "tet_ts_dead: close sd %s", tet_i2a(tp->tp_sd));
- (void) SOCKET_CLOSE(tp->tp_sd);
+ SOCKET_CLOSE(tp->tp_sd);
tp->tp_sd = INVALID_SOCKET;
pp->pt_flags &= ~(PF_CONNECTED | PF_INPROGRESS);
}
diff --git a/src/tet3/servlib/fio.c b/src/tet3/servlib/fio.c
index 96f9769d..da666ab5 100644
--- a/src/tet3/servlib/fio.c
+++ b/src/tet3/servlib/fio.c
@@ -351,7 +351,7 @@ register struct ptab *pp;
done = 1;
for (ftp = ftab; ftp; ftp = ftp->ft_next)
if (ftp->ft_ptab == pp) {
- (void) dofclose(ftp);
+ dofclose(ftp);
done = 0;
break;
}
@@ -416,7 +416,7 @@ register struct ftab *ftp;
if (ftp) {
if (ftp->ft_fp)
- (void) fclose(ftp->ft_fp);
+ fclose(ftp->ft_fp);
if (ftp->ft_name) {
TRACE2(tet_Tbuf, 6, "free ftab fname = %s",
tet_i2x(ftp->ft_name));
diff --git a/src/tet3/servlib/logon.c b/src/tet3/servlib/logon.c
index 72c6e6c0..b2424ccf 100644
--- a/src/tet3/servlib/logon.c
+++ b/src/tet3/servlib/logon.c
@@ -140,7 +140,7 @@ register struct ptab *pp;
error(0, "wanted to log on to", tet_ptptype(wantptype));
error(0, "but found", tet_r2a(&pp->pt_rid));
if (pp->pt_flags & PF_LOGGEDON)
- (void) tet_ti_logoff(pp, 1);
+ tet_ti_logoff(pp, 1);
tet_ts_dead(pp);
}
diff --git a/src/tet3/servlib/smain.c b/src/tet3/servlib/smain.c
index d9ab41dc..ef03a613 100644
--- a/src/tet3/servlib/smain.c
+++ b/src/tet3/servlib/smain.c
@@ -89,10 +89,10 @@ char **argv;
if (needtetroot) {
if (argc > 0)
- (void) sprintf(tet_root, "%.*s",
+ sprintf(tet_root, "%.*s",
(int) sizeof tet_root - 1, *argv);
else {
- (void) sprintf(buf, "%.14s [options] tetrootdir",
+ sprintf(buf, "%.14s [options] tetrootdir",
tet_progname);
fatal(0, "usage:", buf);
}
diff --git a/src/tet3/servlib/sproc.c b/src/tet3/servlib/sproc.c
index 805bd045..5121abdb 100644
--- a/src/tet3/servlib/sproc.c
+++ b/src/tet3/servlib/sproc.c
@@ -269,11 +269,11 @@ register struct ptab *pp;
register struct avmsg *mp = (struct avmsg *) pp->ptm_data;
register int n;
- (void) printf("%s: call to op_print(): argc = %d\n",
+ printf("%s: call to op_print(): argc = %d\n",
tet_progname, mp->av_argc);
for (n = 0; n < (int) mp->av_argc; n++)
- (void) printf("%s\n", mp->av_argv[n]);
- (void) fflush(stdout);
+ printf("%s\n", mp->av_argv[n]);
+ fflush(stdout);
pp->ptm_rc = ER_OK;
pp->ptm_mtype = MT_NODATA;
diff --git a/src/tet3/servlib/tctalk.c b/src/tet3/servlib/tctalk.c
index 5cf8e06c..cdd07cda 100644
--- a/src/tet3/servlib/tctalk.c
+++ b/src/tet3/servlib/tctalk.c
@@ -149,7 +149,7 @@ int sysid;
/* do the rest of the logon processing */
if (tc_l3(pp) < 0) {
- (void) tet_ti_logoff(pp, 0);
+ tet_ti_logoff(pp, 0);
return(-1);
}
diff --git a/src/tet3/servlib/tcxconf.c b/src/tet3/servlib/tcxconf.c
index 9e61fd00..b49bfc87 100644
--- a/src/tet3/servlib/tcxconf.c
+++ b/src/tet3/servlib/tcxconf.c
@@ -174,7 +174,7 @@ register struct cflist *mlp, *vlp;
for (cp1 = vlp->cf_conf; cp1 < vlp->cf_conf + vlp->cf_nconf; cp1++) {
if (tet_remvar(*cp1, -1) != *cp1)
continue;
- (void) sprintf(buf, fmt, sysid % 1000,
+ sprintf(buf, fmt, sysid % 1000,
sizeof buf - sizeof fmt, *cp1);
if (BUFCHK((char **) &tcfg.cf_conf, &tcfg.cf_lconf, (int) ((tcfg.cf_nconf + 1) * sizeof *tcfg.cf_conf)) < 0)
return(-1);
diff --git a/src/tet3/servlib/titcmenv.c b/src/tet3/servlib/titcmenv.c
index 47eed3e0..e585d681 100644
--- a/src/tet3/servlib/titcmenv.c
+++ b/src/tet3/servlib/titcmenv.c
@@ -82,19 +82,19 @@ register int *sname, nsname;
#endif
/* start with the sysid and parent sysid arguments */
- (void) sprintf(sysidstr, "%d", tet_mysysid);
- (void) sprintf(psysidstr, "%d", psysid);
+ sprintf(sysidstr, "%d", tet_mysysid);
+ sprintf(psysidstr, "%d", psysid);
needlen = sizeof envname + strlen(sysidstr) + strlen(psysidstr) + 6;
/* add the snid argument */
if (snid >= 0L) {
- (void) sprintf(snidstr, "%ld", snid);
+ sprintf(snidstr, "%ld", snid);
needlen += strlen(snidstr) + 3;
}
/* add the xrid argument */
if (xrid >= 0L) {
- (void) sprintf(xridstr, "%ld", xrid);
+ sprintf(xridstr, "%ld", xrid);
needlen += strlen(xridstr) + 3;
}
diff --git a/src/tet3/servlib/xdxfile.c b/src/tet3/servlib/xdxfile.c
index 3737c899..ddeaa17c 100644
--- a/src/tet3/servlib/xdxfile.c
+++ b/src/tet3/servlib/xdxfile.c
@@ -95,7 +95,7 @@ char *ifile, *ofile;
/* open the transfer file on the master system */
if ((xfid = xd_tfopen(ofile, (int) stbuf.st_mode)) < 0) {
- (void) fclose(ifp);
+ fclose(ifp);
return(-1);
}
@@ -103,7 +103,7 @@ char *ifile, *ofile;
rc = xd_wrloop(ifp, xfid, ifile);
/* close the local file and the transfer file on the master system */
- (void) fclose(ifp);
+ fclose(ifp);
return(xd_tfclose(xfid) < 0 ? -1 : rc);
}
diff --git a/src/tet3/tcc/config.c b/src/tet3/tcc/config.c
index d46a359e..6a16ae90 100644
--- a/src/tet3/tcc/config.c
+++ b/src/tet3/tcc/config.c
@@ -389,7 +389,7 @@ struct cflist *lp;
proccfline(buf, lp, lcount, fname);
}
- (void) fclose(fp);
+ fclose(fp);
}
/*
@@ -407,7 +407,7 @@ int lineno;
/* check the format of the config line */
if (!tet_equindex(line) || !tet_remvar(line, -1)) {
- (void) sprintf(msg, fmt, lineno);
+ sprintf(msg, fmt, lineno);
error(0, msg, fname);
conferrors++;
return;
@@ -487,7 +487,7 @@ int mode;
return;
/* here to add a default value of !TET_OUTPUT_CAPTURE */
- (void) sprintf(line, "%s=%s", name,
+ sprintf(line, "%s=%s", name,
getmcflag("TET_OUTPUT_CAPTURE", mode) ? "False" : "True");
proccfl2(line, &MCFLIST(mode));
}
@@ -511,7 +511,7 @@ int mode;
return;
/* here to add a default value of TET_OUTPUT_CAPTURE */
- (void) sprintf(line, "%s=%s", name,
+ sprintf(line, "%s=%s", name,
getmcflag("TET_OUTPUT_CAPTURE", mode) ? "True" : "False");
proccfl2(line, &MCFLIST(mode));
}
@@ -634,7 +634,7 @@ void distcfg()
for (dvp = dvar; dvp < dvar + Ndvar; dvp++) {
if (!dvp->dv_value || !*dvp->dv_value)
continue;
- (void) sprintf(buf, "%s=%.*s",dvp->dv_name,
+ sprintf(buf, "%s=%.*s",dvp->dv_name,
(int) sizeof buf - dvp->dv_len - 1,
dvp->dv_value);
proccfl2(buf, &CFLIST(sp, CONF_DIST));
@@ -722,7 +722,7 @@ void distcfg()
if (sysid == 0)
ASSERT(isabspathloc(p));
else if (!isabspathrem(p)) {
- (void) sprintf(buf, fmt1,
+ sprintf(buf, fmt1,
dvp->dv_name, sysid);
error(0, buf, "is not an "
"absolute path name");
@@ -731,7 +731,7 @@ void distcfg()
}
}
else if (dvp->dv_needed) {
- (void) sprintf(buf, fmt2, dvp->dv_name);
+ sprintf(buf, fmt2, dvp->dv_name);
error(0, buf, tet_i2a(sysid));
conferrors++;
}
@@ -899,7 +899,7 @@ void doconfig()
for (cp = lp->cf_conf; cp < lp->cf_conf + lp->cf_nconf; cp++) {
if (!*cp)
continue;
- (void) sprintf(buf, fmt, sysid % 1000,
+ sprintf(buf, fmt, sysid % 1000,
(int) (sizeof buf - sizeof fmt), *cp);
RBUFCHK((char **) &tmp.cf_conf, &tmp.cf_lconf,
(int) ((tmp.cf_nconf + 1) * sizeof *tmp.cf_conf));
@@ -1106,7 +1106,7 @@ int mode;
/* make sure that the remote config file is accessible */
if (tcc_access(sp->sy_sysid, fname, 04) < 0) {
- (void) sprintf(msg, fmt1, prcfmode(mode), MAXPATH, fname);
+ sprintf(msg, fmt1, prcfmode(mode), MAXPATH, fname);
error(errno ? errno : tet_tcerrno, msg, tet_i2a(sp->sy_sysid));
conferrors++;
return;
@@ -1137,7 +1137,7 @@ int mode;
/* perform a config variable exchange with the remote system */
if (tet_tcxconfig(sp->sy_sysid, fname, tp, &vopts, to) < 0) {
- (void) sprintf(msg, fmt2, prcfmode(mode));
+ sprintf(msg, fmt2, prcfmode(mode));
error(tet_tcerrno, msg, tet_i2a(sp->sy_sysid));
conferrors++;
}
@@ -1215,7 +1215,7 @@ int mode;
case 'f':
break;
default:
- (void) sprintf(msg, fmt, vp->bv_name,
+ sprintf(msg, fmt, vp->bv_name,
prcfmode(mode));
error(0, msg, tet_i2a(sysid));
conferrors++;
@@ -1293,7 +1293,7 @@ static void reportdcfg()
lp = &CFLIST(sp, CONF_DIST);
for (cp = lp->cf_conf; cp < lp->cf_conf + lp->cf_nconf; cp++) {
RBUFCHK(&buf, &buflen, (int) strlen(*cp) + 12);
- (void) sprintf(buf, "TET_REM%03d_%s",
+ sprintf(buf, "TET_REM%03d_%s",
sysid % 1000, *cp);
jnl_cfg(buf);
}
@@ -1372,11 +1372,11 @@ char *fname, *type;
}
/* write out the variables */
- (void) fprintf(fp, "# %s configuration variables\n\n", type);
+ fprintf(fp, "# %s configuration variables\n\n", type);
for (cp = lp->cf_conf; cp < lp->cf_conf + lp->cf_nconf; cp++)
if (fprintf(fp, "%s\n", *cp) < 0) {
error(errno, "write error on", fname);
- (void) fclose(fp);
+ fclose(fp);
return(-1);
}
@@ -1509,7 +1509,7 @@ struct cfstack *stp;
p = tet_equindex(*cp);
ASSERT(*p == '=');
*p = '\0';
- (void) sprintf(msg, fmt, *cp);
+ sprintf(msg, fmt, *cp);
*p = '=';
error(0, msg,
"variable assignment in the distributed configuration");
@@ -1633,7 +1633,7 @@ struct cfstack *stp;
len += (int) strlen(p);
buflen = (int) strlen(*cp) + 1;
RBUFCHK(cp, &buflen, len);
- (void) sprintf(*cp, "%s=%s%s%s", name, head, p ? p : "", tail);
+ sprintf(*cp, "%s=%s%s%s", name, head, p ? p : "", tail);
TRACE2(tet_Ttcc, 8, "cve3(): assignment after expansion: \"%s\"", *cp);
}
@@ -1692,7 +1692,7 @@ struct cfstack *stp1;
p = cve3_opmode(name, var, mmm, sysid, mode, stp1);
if (!p) {
- (void) sprintf(msg, fmt, fullvar);
+ sprintf(msg, fmt, fullvar);
cve_error(name, mode, sysid, msg);
}
@@ -1889,18 +1889,18 @@ int mode, sysid;
if (mode == CONF_DIST) {
p = "Distributed";
- (void) sprintf(msg2, conf);
+ sprintf(msg2, conf);
}
else {
p = prcfmode(mode);
if (sysid < 0) {
- (void) sprintf(msg2, "%s %s", p, conf);
+ sprintf(msg2, "%s %s", p, conf);
p = "master";
}
else
- (void) sprintf(msg2, fmt2, conf, sysid);
+ sprintf(msg2, fmt2, conf, sysid);
}
- (void) sprintf(msg1, fmt1, text, name, p);
+ sprintf(msg1, fmt1, text, name, p);
error(0, msg1, msg2);
conferrors++;
@@ -2221,7 +2221,7 @@ int sysid;
ASSERT(IS_CFSETUP(sp, CONF_DIST));
lp = &CFLIST(sp, CONF_DIST);
- (void) sprintf(buf, "%s=%.*s", name,
+ sprintf(buf, "%s=%.*s", name,
(int) sizeof buf - (int) strlen(name) - 2, value);
proccfl2(buf, lp);
}
@@ -2416,7 +2416,7 @@ int mode;
case CONF_DIST:
return("DIST");
default:
- (void) sprintf(msg, "%s%d", text, mode);
+ sprintf(msg, "%s%d", text, mode);
return(msg);
}
}
@@ -2478,7 +2478,7 @@ int opmode;
ASSERT(TCFNAME(cfmode));
if (BUFCHK(&var, &lvar, (int) (sizeof envname + strlen(TCFNAME(cfmode)) + 1)) < 0)
return(-1);
- (void) sprintf(var, "%s=%s", envname, TCFNAME(cfmode));
+ sprintf(var, "%s=%s", envname, TCFNAME(cfmode));
/* put the variable in the environment */
if (tet_putenv(var) < 0)
@@ -2499,7 +2499,7 @@ int opmode;
static void confgiveup()
{
- (void) fprintf(stderr,
+ fprintf(stderr,
"%s: giving up after %d configuration error%s\n",
tet_progname, conferrors, conferrors == 1 ? "" : "s");
tcc_exit(1);
@@ -2518,16 +2518,16 @@ void config_cleanup()
for (fname = tcfname; fname < &tcfname[Ntcfname]; fname++)
if (*fname)
- (void) UNLINK(*fname);
+ UNLINK(*fname);
#else /* -START-LITE-CUT- */
if (ecfname)
- (void) UNLINK(ecfname);
+ UNLINK(ecfname);
if (dcfname)
- (void) UNLINK(dcfname);
+ UNLINK(dcfname);
if (ccfname)
- (void) UNLINK(ccfname);
+ UNLINK(ccfname);
#endif /* TET_LITE */ /* -END-LITE-CUT- */
diff --git a/src/tet3/tcc/copysave.c b/src/tet3/tcc/copysave.c
index 5c16d311..bab53e9b 100644
--- a/src/tet3/tcc/copysave.c
+++ b/src/tet3/tcc/copysave.c
@@ -96,7 +96,7 @@ void rtlcopy()
/* do the copy */
errno = 0;
if (tet_fcopy(tet_tsroot, dest) < 0) {
- (void) sprintf(msg, fmt, MAXPATH, tet_tsroot, MAXPATH, dest);
+ sprintf(msg, fmt, MAXPATH, tet_tsroot, MAXPATH, dest);
fatal(errno, msg, "the local system");
}
@@ -151,7 +151,7 @@ char *rtdir;
/* do the copy */
errno = 0;
if (tet_tcrcopy(sysid, tsroot, dest) < 0) {
- (void) sprintf(msg, fmt, MAXPATH, tsroot, MAXPATH, dest);
+ sprintf(msg, fmt, MAXPATH, tsroot, MAXPATH, dest);
if (!IS_ER_ERRNO(tet_tcerrno))
errno = 0;
fatal(errno ? errno : tet_tcerrno, msg, tet_i2a(sysid));
@@ -235,7 +235,7 @@ char tdir[];
/* here to create the tmpdir */
errno = 0;
if (tcc_mkdir(sysid, tdir) < 0) {
- (void) sprintf(msg, fmt, MAXPATH, tdir);
+ sprintf(msg, fmt, MAXPATH, tdir);
fatal(errno ? errno : tet_tcerrno, msg, tet_i2a(sysid));
}
@@ -398,7 +398,7 @@ char *from, *to;
err = IS_ER_ERRNO(tet_tcerrno) ? errno : tet_tcerrno;
#endif /* TET_LITE */ /* -END-LITE-CUT- */
if (rc < 0) {
- (void) sprintf(msg, fmt, MAXPATH, from);
+ sprintf(msg, fmt, MAXPATH, from);
prperror(prp, *prp->pr_sys, err, msg, to);
return(-1);
}
@@ -459,7 +459,7 @@ struct systab *sp;
/* create the results directory on the remote system if necessary */
if (tet_tcmkalldirs(sp->sy_sysid, resroot) < 0) {
- (void) sprintf(msg, fmt, "",
+ sprintf(msg, fmt, "",
sizeof msg - sizeof fmt, resroot);
if (!IS_ER_ERRNO(tet_tcerrno))
errno = 0;
@@ -469,7 +469,7 @@ struct systab *sp;
/* create the saved files directory on the remote system */
if ((sfdir = tet_tcmksdir(sp->sy_sysid, resroot, resdirsuffix())) == (char *) 0) {
- (void) sprintf(msg, fmt, below,
+ sprintf(msg, fmt, below,
sizeof msg - sizeof fmt - sizeof below, resroot);
error(tet_tcerrno, msg, tet_i2a(sp->sy_sysid));
return(-1);
@@ -548,7 +548,7 @@ int nsfiles;
prp->pr_currmode);
if (tsfiles) {
- (void) sprintf(subdir, remote, *prp->pr_sys % 1000);
+ sprintf(subdir, remote, *prp->pr_sys % 1000);
fullpath(resdirname(), subdir, path, sizeof path,
*prp->pr_sys ? 1 : 0);
tcexecdir(prp, path, savedir, sizeof savedir);
@@ -571,7 +571,7 @@ int nsfiles;
#endif /* TET_LITE */ /* -END-LITE-CUT- */
if (rc < 0) {
- (void) sprintf(msg, fmt, MAXPATH, prp->pr_tcedir, *prp->pr_sys);
+ sprintf(msg, fmt, MAXPATH, prp->pr_tcedir, *prp->pr_sys);
prperror(prp, tsfiles ? 0 : *prp->pr_sys, tet_tcerrno,
msg, savedir);
}
diff --git a/src/tet3/tcc/dtcc.c b/src/tet3/tcc/dtcc.c
index edff0fd8..d0b474be 100644
--- a/src/tet3/tcc/dtcc.c
+++ b/src/tet3/tcc/dtcc.c
@@ -238,7 +238,7 @@ static int tccdlogon()
dir = getdcfg("TET_ROOT", sysid);
ASSERT(dir && *dir);
if (tcc_access(sysid, dir, 04) < 0) {
- (void) sprintf(msg, fmt,
+ sprintf(msg, fmt,
sizeof msg - sizeof fmt, dir);
error(errno, msg, tet_i2a(sysid));
return(-1);
@@ -246,7 +246,7 @@ static int tccdlogon()
dir = getdcfg("TET_TSROOT", sysid);
ASSERT(dir && *dir);
if (tcc_access(sysid, dir, 04) < 0) {
- (void) sprintf(msg, fmt,
+ sprintf(msg, fmt,
sizeof msg - sizeof fmt, dir);
error(errno, msg, tet_i2a(sysid));
return(-1);
diff --git a/src/tet3/tcc/environ.c b/src/tet3/tcc/environ.c
index 1620d361..354daac2 100644
--- a/src/tet3/tcc/environ.c
+++ b/src/tet3/tcc/environ.c
@@ -106,14 +106,14 @@ struct systab *sp;
for (cvp = comvar; cvp < comvar + Ncomvar; cvp++) {
if ((val = getdcfg(*cvp, sp->sy_sysid)) == (char *) 0)
val = "";
- (void) sprintf(buf, "%s=%.*s", *cvp,
+ sprintf(buf, "%s=%.*s", *cvp,
(int) sizeof buf - (int) strlen(*cvp) - 2, val);
ASSERT(ep < &envstr[Nenvstr]);
*ep++ = rstrstore(buf);
}
/* then add in TET_CODE */
- (void) sprintf(buf, "TET_CODE=%.*s", MAXPATH, sp->sy_rcfname);
+ sprintf(buf, "TET_CODE=%.*s", MAXPATH, sp->sy_rcfname);
ASSERT(ep < &envstr[Nenvstr]);
*ep++ = rstrstore(buf);
diff --git a/src/tet3/tcc/error.c b/src/tet3/tcc/error.c
index 7fcd3a9c..fcd76fb6 100644
--- a/src/tet3/tcc/error.c
+++ b/src/tet3/tcc/error.c
@@ -86,8 +86,8 @@ void tcc_error(int errnum, const char *file, int line, const char *s1,
if (jnl_usable())
jnl_tcc_msg(msg);
else {
- (void) fprintf(stderr, "%s %s\n", tet_progname, msg);
- (void) fflush(stderr);
+ fprintf(stderr, "%s %s\n", tet_progname, msg);
+ fflush(stderr);
}
}
@@ -116,7 +116,7 @@ void tcc_prperror(struct proctab *prp, int sysid, int errnum, const char *file,
/* format the message */
if (sysid >= 0)
- (void) sprintf(text, fmt, sysid);
+ sprintf(text, fmt, sysid);
else
text[0] = '\0';
errfmt(errnum, file, line, s1, s2, text, msg);
@@ -136,7 +136,7 @@ static void errfmt(int errnum, const char *file, int line, const char *s1,
register char *p = msg;
/* generate the source file and line number */
- (void) sprintf(p, "(%s, %d): ", file, line);
+ sprintf(p, "(%s, %d): ", file, line);
p += strlen(p);
/* append the first message string */
diff --git a/src/tet3/tcc/exec.c b/src/tet3/tcc/exec.c
index ba53100c..03597d0b 100644
--- a/src/tet3/tcc/exec.c
+++ b/src/tet3/tcc/exec.c
@@ -90,7 +90,7 @@ char *path, **argv, *tcdir, *outfile;
sp = syfind(*prp->pr_sys);
ASSERT(sp);
if (sp->sy_activity != prp->pr_activity) {
- (void) sprintf(buf, fmt, prp->pr_activity);
+ sprintf(buf, fmt, prp->pr_activity);
TRACE3(tet_Ttcc, 6, "putenv \"%s\" on system %s",
buf, tet_i2a(*prp->pr_sys));
if (tcc_putenv(*prp->pr_sys, buf) < 0) {
diff --git a/src/tet3/tcc/jnlproc.c b/src/tet3/tcc/jnlproc.c
index 8417b9c2..c45a571e 100644
--- a/src/tet3/tcc/jnlproc.c
+++ b/src/tet3/tcc/jnlproc.c
@@ -132,7 +132,7 @@ struct proctab *prp;
if ((fp = open_xresdfile(prp)) != (FILE *) 0) {
TRACE2(tet_Ttcc, 6, "using XRESD file %s", prp->pr_xfname);
rc = jp_xres(prp, fp, prp->pr_xfname);
- (void) fclose(fp);
+ fclose(fp);
}
else
#endif /* !TET_LITE */ /* -END-LITE-CUT- */
@@ -185,7 +185,7 @@ struct proctab *prp;
||
(getremfile(prp, prp->pr_tetxres, tet_basename(fname)) < 0)
) {
- (void) UNLINK(fname);
+ UNLINK(fname);
return(-1);
}
}
@@ -208,7 +208,7 @@ struct proctab *prp;
/* process it */
rc = jp_xres(prp, fp, prp->pr_tetxres);
- (void) fclose(fp);
+ fclose(fp);
#ifndef TET_LITE /* -START-LITE-CUT- */
@@ -217,7 +217,7 @@ struct proctab *prp;
** from a remote system, unlink it now
*/
if (fname != prp->pr_tetxres)
- (void) UNLINK(fname);
+ UNLINK(fname);
#endif /* !TET_LITE */ /* -END-LITE-CUT- */
return(rc);
@@ -265,7 +265,7 @@ char *fname;
#endif /* !TET_LITE */ /* -END-LITE-CUT- */
) {
tpno = -1;
- (void) sscanf(flds[1], "%*s %d", &tpno);
+ sscanf(flds[1], "%*s %d", &tpno);
if (jp_reorder(prp, fp, fname, tpno, line, buf) < 0)
rc = -1;
}
@@ -311,14 +311,14 @@ int tpno;
}
switch (id = atoi(flds[0])) {
case TET_JNL_TP_RESULT:
- (void) sscanf(flds[1], "%*s %*s %d", &result);
+ sscanf(flds[1], "%*s %*s %d", &result);
done = 1;
break;
case TET_JNL_IC_START:
case TET_JNL_IC_END:
case TET_JNL_TP_START:
line[0] = '\0';
- (void) fseek(fp, offs, SEEK_SET);
+ fseek(fp, offs, SEEK_SET);
done = 1;
break;
}
@@ -331,7 +331,7 @@ int tpno;
lp1->xr_block = 0L;
lp1->xr_sequence = 0L;
if (id == TET_JNL_TC_INFO)
- (void) sscanf(flds[1], "%*s %*s %ld %ld %ld",
+ sscanf(flds[1], "%*s %*s %ld %ld %ld",
&lp1->xr_context, &lp1->xr_block,
&lp1->xr_sequence);
lp1->xr_id = id;
@@ -547,7 +547,7 @@ struct proctab *prp;
if (fgets(buf, sizeof buf, fp) == (char *) 0) {
TRACE2(tet_Ttcc, 6, "open_xresdfile(): %s is empty",
prp->pr_xfname);
- (void) fclose(fp);
+ fclose(fp);
return((FILE *) 0);
}
diff --git a/src/tet3/tcc/journal.c b/src/tet3/tcc/journal.c
index 79f9156f..93e29152 100644
--- a/src/tet3/tcc/journal.c
+++ b/src/tet3/tcc/journal.c
@@ -231,7 +231,7 @@ struct proctab *prp;
return(-1);
}
else if (tet_fioclex(FILENO(fp)) < 0) {
- (void) fclose(fp);
+ fclose(fp);
return(-1);
}
@@ -264,11 +264,11 @@ char *dir, *prefix;
int fd;
for (try = 0; try < trymax; try++) {
- (void) sprintf(fname, fmt, (int) sizeof fname - 14,
+ sprintf(fname, fmt, (int) sizeof fname - 14,
dir, prefix, tet_mypid, salt);
errno = 0;
if ((fd = OPEN(fname, O_WRONLY|O_CREAT|O_EXCL, MODEANY)) >= 0)
- (void) CLOSE(fd);
+ CLOSE(fd);
if (fd >= 0 || errno != EEXIST)
return(fname);
for (p = &salt[sizeof salt - 2]; p >= salt; p--)
@@ -307,7 +307,7 @@ char **argv;
int sp;
/* generate the first part */
- (void) sprintf(s1, "%s %s %s", tcc_version,
+ sprintf(s1, "%s %s %s", tcc_version,
jnl_time(now), jnl_date(now));
/* determine the user id and name */
@@ -321,7 +321,7 @@ char **argv;
}
/* generate the second part */
- (void) sprintf(p2, "User: %s (%d) TCC Start, Command line:",
+ sprintf(p2, "User: %s (%d) TCC Start, Command line:",
user, (int) uid);
p2 += strlen(p2);
@@ -391,7 +391,7 @@ void jnl_uname()
return;
}
- (void) sprintf(s1, "%.*s %.*s %.*s %.*s %.*s",
+ sprintf(s1, "%.*s %.*s %.*s %.*s %.*s",
(int) sizeof uts.sysname, uts.sysname,
(int) sizeof uts.nodename, uts.nodename,
(int) sizeof uts.release, uts.release,
@@ -413,7 +413,7 @@ register struct proctab *prp;
register char *p;
register int needlen;
- (void) sprintf(s1, "%d %.*s %s", prp->pr_activity,
+ sprintf(s1, "%d %.*s %s", prp->pr_activity,
MAXPATH, prp->pr_scen->sc_tcname, jnl_time(time((time_t *) 0)));
needlen = sizeof s2p1fmt + REFSZ;
@@ -423,10 +423,10 @@ register struct proctab *prp;
RBUFCHK(&s2, &s2len, needlen);
p = s2;
- (void) sprintf(p, s2p1fmt, jnl_scenref(prp));
+ sprintf(p, s2p1fmt, jnl_scenref(prp));
if (prp->pr_exiclist) {
p += strlen(p);
- (void) sprintf(p, s2p2fmt, prp->pr_exiclist);
+ sprintf(p, s2p2fmt, prp->pr_exiclist);
}
jnl_write(TET_JNL_INVOKE_TC, s1, s2, prp->pr_jfp, prp->pr_jfname);
@@ -439,7 +439,7 @@ int mode;
{
char s1[MAXPATH + LONUMSZ + 2];
- (void) sprintf(s1, "%.*s %s", MAXPATH, fname, jnl_mode(mode));
+ sprintf(s1, "%.*s %s", MAXPATH, fname, jnl_mode(mode));
jnl_cfg_start(s1);
}
@@ -452,7 +452,7 @@ int sysid, mode;
static char fmt[] = "remote_%03d %s";
char s1[sizeof fmt + LNUMSZ + LONUMSZ];
- (void) sprintf(s1, fmt, sysid, jnl_mode(mode));
+ sprintf(s1, fmt, sysid, jnl_mode(mode));
jnl_cfg_start(s1);
}
@@ -522,9 +522,9 @@ struct proctab *prp;
static char fmt[] = "TC End, %s";
char s2[sizeof fmt + REFSZ];
- (void) sprintf(s1, "%d %d %s", prp->pr_activity, prp->pr_jnlstatus,
+ sprintf(s1, "%d %d %s", prp->pr_activity, prp->pr_jnlstatus,
jnl_time(time((time_t *) 0)));
- (void) sprintf(s2, fmt, jnl_scenref(prp));
+ sprintf(s2, fmt, jnl_scenref(prp));
jnl_write(TET_JNL_TC_END, s1, s2, prp->pr_jfp, prp->pr_jfname);
jnl_itrace(TET_JNL_TC_END, s1, s2);
}
@@ -554,7 +554,7 @@ struct proctab *prp;
static char fmt[] = "Build Start, %s";
char s2[sizeof fmt + REFSZ];
- (void) sprintf(s2, fmt, jnl_scenref(prp));
+ sprintf(s2, fmt, jnl_scenref(prp));
jnl_bc_start(prp, TET_JNL_BUILD_START, s2);
}
@@ -564,7 +564,7 @@ struct proctab *prp;
static char fmt[] = "Clean Start, %s";
char s2[sizeof fmt + REFSZ];
- (void) sprintf(s2, fmt, jnl_scenref(prp));
+ sprintf(s2, fmt, jnl_scenref(prp));
jnl_bc_start(prp, TET_JNL_CLEAN_START, s2);
}
@@ -575,7 +575,7 @@ char *s2;
{
char s1[LNUMSZ + MAXPATH + TIMESZ + 3];
- (void) sprintf(s1, "%d %.*s %s", prp->pr_activity, MAXPATH,
+ sprintf(s1, "%d %.*s %s", prp->pr_activity, MAXPATH,
prp->pr_scen->sc_tcname, jnl_time(time((time_t *) 0)));
jnl_write(id, s1, s2, prp->pr_jfp, prp->pr_jfname);
@@ -588,7 +588,7 @@ struct proctab *prp;
static char fmt[] = "Build End, %s";
char s2[sizeof fmt + REFSZ];
- (void) sprintf(s2, fmt, jnl_scenref(prp));
+ sprintf(s2, fmt, jnl_scenref(prp));
jnl_bc_end(prp, TET_JNL_BUILD_END, s2);
}
@@ -598,7 +598,7 @@ struct proctab *prp;
static char fmt[] = "Clean End, %s";
char s2[sizeof fmt + REFSZ];
- (void) sprintf(s2, fmt, jnl_scenref(prp));
+ sprintf(s2, fmt, jnl_scenref(prp));
jnl_bc_end(prp, TET_JNL_CLEAN_END, s2);
}
@@ -609,7 +609,7 @@ char *s2;
{
char s1[(LNUMSZ * 2) + TIMESZ + 3];
- (void) sprintf(s1, "%d %d %s", prp->pr_activity, prp->pr_jnlstatus,
+ sprintf(s1, "%d %d %s", prp->pr_activity, prp->pr_jnlstatus,
jnl_time(time((time_t *) 0)));
jnl_write(id, s1, s2, prp->pr_jfp, prp->pr_jfname);
@@ -623,7 +623,7 @@ struct proctab *prp;
char *s1 = tet_i2a(prp->pr_scen->sc_count);
char s2[sizeof fmt + REFSZ];
- (void) sprintf(s2, fmt, jnl_scenref(prp));
+ sprintf(s2, fmt, jnl_scenref(prp));
jnl_write(TET_JNL_PRL_START, s1, s2, prp->pr_jfp, prp->pr_jfname);
}
@@ -633,7 +633,7 @@ struct proctab *prp;
static char fmt[] = "Parallel End, %s";
char s2[sizeof fmt + REFSZ];
- (void) sprintf(s2, fmt, jnl_scenref(prp));
+ sprintf(s2, fmt, jnl_scenref(prp));
jnl_write(TET_JNL_PRL_END, (char *) 0, s2,
prp->pr_jfp, prp->pr_jfname);
}
@@ -645,7 +645,7 @@ struct proctab *prp;
static char fmt[] = "%sSequential Start, %s";
char s2[sizeof fmt + sizeof implied + REFSZ];
- (void) sprintf(s2, fmt,
+ sprintf(s2, fmt,
prp->pr_scen->sc_flags & SCF_IMPLIED ? implied : "",
jnl_scenref(prp));
jnl_write(TET_JNL_SEQ_START, (char *) 0, s2,
@@ -659,7 +659,7 @@ struct proctab *prp;
static char fmt[] = "%sSequential End, %s";
char s2[sizeof fmt + sizeof implied + REFSZ];
- (void) sprintf(s2, fmt,
+ sprintf(s2, fmt,
prp->pr_scen->sc_flags & SCF_IMPLIED ? implied : "",
jnl_scenref(prp));
jnl_write(TET_JNL_SEQ_END, (char *) 0, s2,
@@ -673,7 +673,7 @@ struct proctab *prp;
char *s1 = tet_i2a(prp->pr_scen->sc_count);
char s2[sizeof fmt + REFSZ];
- (void) sprintf(s2, fmt, jnl_scenref(prp));
+ sprintf(s2, fmt, jnl_scenref(prp));
jnl_write(TET_JNL_RPT_START, s1, s2, prp->pr_jfp, prp->pr_jfname);
}
@@ -683,7 +683,7 @@ struct proctab *prp;
static char fmt[] = "Repeat End, %s";
char s2[sizeof fmt + REFSZ];
- (void) sprintf(s2, fmt, jnl_scenref(prp));
+ sprintf(s2, fmt, jnl_scenref(prp));
jnl_write(TET_JNL_RPT_END, (char *) 0, s2,
prp->pr_jfp, prp->pr_jfname);
}
@@ -695,7 +695,7 @@ struct proctab *prp;
char *s1 = tet_l2a(prp->pr_scen->sc_seconds);
char s2[sizeof fmt + REFSZ];
- (void) sprintf(s2, fmt, jnl_scenref(prp));
+ sprintf(s2, fmt, jnl_scenref(prp));
jnl_write(TET_JNL_TLOOP_START, s1, s2, prp->pr_jfp, prp->pr_jfname);
}
@@ -705,7 +705,7 @@ struct proctab *prp;
static char fmt[] = "Timed Loop End, %s";
char s2[sizeof fmt + REFSZ];
- (void) sprintf(s2, fmt, jnl_scenref(prp));
+ sprintf(s2, fmt, jnl_scenref(prp));
jnl_write(TET_JNL_TLOOP_END, (char *) 0, s2,
prp->pr_jfp, prp->pr_jfname);
}
@@ -716,7 +716,7 @@ struct proctab *prp;
static char fmt[] = "Random Start, %s";
char s2[sizeof fmt + REFSZ];
- (void) sprintf(s2, fmt, jnl_scenref(prp));
+ sprintf(s2, fmt, jnl_scenref(prp));
jnl_write(TET_JNL_RND_START, (char *) 0, s2,
prp->pr_jfp, prp->pr_jfname);
}
@@ -727,7 +727,7 @@ struct proctab *prp;
static char fmt[] = "Random End, %s";
char s2[sizeof fmt + REFSZ];
- (void) sprintf(s2, fmt, jnl_scenref(prp));
+ sprintf(s2, fmt, jnl_scenref(prp));
jnl_write(TET_JNL_RND_END, (char *) 0, s2,
prp->pr_jfp, prp->pr_jfname);
}
@@ -741,7 +741,7 @@ struct proctab *prp;
static char fmt[] = "Remote Start, %s";
char s2[sizeof fmt + REFSZ];
- (void) sprintf(s2, fmt, jnl_scenref(prp));
+ sprintf(s2, fmt, jnl_scenref(prp));
jnl_rd_start(prp, TET_JNL_RMT_START, s2);
}
@@ -751,7 +751,7 @@ struct proctab *prp;
static char fmt[] = "Remote End, %s";
char s2[sizeof fmt + REFSZ];
- (void) sprintf(s2, fmt, jnl_scenref(prp));
+ sprintf(s2, fmt, jnl_scenref(prp));
jnl_write(TET_JNL_RMT_END, (char *) 0, s2,
prp->pr_jfp, prp->pr_jfname);
}
@@ -762,7 +762,7 @@ struct proctab *prp;
static char fmt[] = "Distributed Start, %s";
char s2[sizeof fmt + REFSZ];
- (void) sprintf(s2, fmt, jnl_scenref(prp));
+ sprintf(s2, fmt, jnl_scenref(prp));
jnl_rd_start(prp, TET_JNL_DIST_START, s2);
}
@@ -772,7 +772,7 @@ struct proctab *prp;
static char fmt[] = "Distributed End, %s";
char s2[sizeof fmt + REFSZ];
- (void) sprintf(s2, fmt, jnl_scenref(prp));
+ sprintf(s2, fmt, jnl_scenref(prp));
jnl_write(TET_JNL_DIST_END, (char *) 0, s2,
prp->pr_jfp, prp->pr_jfname);
}
@@ -803,7 +803,7 @@ char *s2;
for (ip = ep->sc_sys; ip < ep->sc_sys + ep->sc_nsys; ip++) {
if (ip > ep->sc_sys)
*p++ = ',';
- (void) sprintf(p, "%03d", *ip);
+ sprintf(p, "%03d", *ip);
p += strlen(p);
}
@@ -821,7 +821,7 @@ struct proctab *prp;
register struct scentab *ep = prp->pr_scen;
register char **vp;
- (void) sprintf(s2, fmt, jnl_scenref(prp));
+ sprintf(s2, fmt, jnl_scenref(prp));
jnl_write(TET_JNL_VAR_START, (char *) 0, s2,
prp->pr_jfp, prp->pr_jfname);
for (vp = ep->sc_vars; vp < ep->sc_vars + ep->sc_nvars; vp++)
@@ -834,7 +834,7 @@ struct proctab *prp;
static char fmt[] = "Variable End, %s";
char s2[sizeof fmt + REFSZ];
- (void) sprintf(s2, fmt, jnl_scenref(prp));
+ sprintf(s2, fmt, jnl_scenref(prp));
jnl_write(TET_JNL_VAR_END, (char *) 0, s2,
prp->pr_jfp, prp->pr_jfname);
}
@@ -858,7 +858,7 @@ struct proctab *prp;
char s1[LNUMSZ + sizeof tcc_version + 4];
static char s2[] = "TCM Start (auto-generated by TCC)";
- (void) sprintf(s1, "%d %s 1", prp->pr_activity, tcc_version);
+ sprintf(s1, "%d %s 1", prp->pr_activity, tcc_version);
jnl_write(TET_JNL_TCM_START, s1, s2, prp->pr_jfp, prp->pr_jfname);
}
@@ -885,7 +885,7 @@ char *s2;
{
char s1[LNUMSZ + TIMESZ + 6];
- (void) sprintf(s1, "%d 1 1 %s",
+ sprintf(s1, "%d 1 1 %s",
prp->pr_activity, jnl_time(time((time_t *) 0)));
jnl_write(id, s1, s2, prp->pr_jfp, prp->pr_jfname);
}
@@ -896,7 +896,7 @@ struct proctab *prp;
char s1[LNUMSZ + TIMESZ + 4];
static char s2[] = "TP Start (auto-generated by TCC)";
- (void) sprintf(s1, "%d 1 %s",
+ sprintf(s1, "%d 1 %s",
prp->pr_activity, jnl_time(time((time_t *) 0)));
jnl_write(TET_JNL_TP_START, s1, s2, prp->pr_jfp, prp->pr_jfname);
}
@@ -912,13 +912,13 @@ int tpno, result;
static char s2p2[] = "(auto-generated by TCC)";
int needlen;
- (void) sprintf(s1, "%d %d %d %s", prp->pr_activity, tpno, result,
+ sprintf(s1, "%d %d %d %s", prp->pr_activity, tpno, result,
jnl_time(time((time_t *) 0)));
s2p1 = tet_getresname(result, (int *) 0);
needlen = strlen(s2p1) + sizeof s2p2 + 1;
RBUFCHK(&s2, &s2len, needlen);
- (void) sprintf(s2, "%s %s", s2p1, s2p2);
+ sprintf(s2, "%s %s", s2p1, s2p2);
jnl_write(TET_JNL_TP_RESULT, s1, s2, prp->pr_jfp, prp->pr_jfname);
}
@@ -967,7 +967,7 @@ FILE *fp;
TET_MAX(s2max, 0), s2) < 0 || fflush(fp) < 0) {
error(errno, "write error on", fname);
s2max = (int) sizeof msg - len0 - len1 - 3;
- (void) sprintf(msg, "%s|%.*s|%.*s", s0,
+ sprintf(msg, "%s|%.*s|%.*s", s0,
(int) sizeof msg - len0 - 3, s1,
TET_MAX(s2max, 0), s2);
error(0, "the journal line that cannot be written is:",
@@ -979,9 +979,9 @@ FILE *fp;
if (jnl_usable())
error(0, "the previous journal line has been truncated",
(char *) 0);
- (void) fprintf(stderr, "%s: a journal line has been truncated - the complete line is:\n%s|%s|%s\n",
+ fprintf(stderr, "%s: a journal line has been truncated - the complete line is:\n%s|%s|%s\n",
tet_progname, s0, s1, s2);
- (void) fflush(stderr);
+ fflush(stderr);
}
}
@@ -1021,7 +1021,7 @@ FILE *fp;
while (p > s2 && isspace(*(p - 1)))
p--;
n = (p > s2) ? p - s2 : space;
- (void) sprintf(msg, "%.*s", n, s2);
+ sprintf(msg, "%.*s", n, s2);
jnl_write(id, s1, msg, fp, fname);
s2 += n;
while (isspace(*s2))
@@ -1045,8 +1045,8 @@ int id;
char *s1, *s2;
{
if (tcc_Iflag) {
- (void) fprintf(stderr, "tcc:%d|%s|%s\n", id, s1, s2);
- (void) fflush(stderr);
+ fprintf(stderr, "tcc:%d|%s|%s\n", id, s1, s2);
+ fflush(stderr);
}
}
@@ -1061,7 +1061,7 @@ time_t now;
struct tm *tp = localtime(&now);
static char buf[DATESZ + 1];
- (void) sprintf(buf, "%4.4d%.2d%.2d",
+ sprintf(buf, "%4.4d%.2d%.2d",
tp->tm_year + 1900, tp->tm_mon + 1, tp->tm_mday);
return(buf);
@@ -1078,7 +1078,7 @@ time_t now;
struct tm *tp = localtime(&now);
static char buf[TIMESZ + 1];
- (void) sprintf(buf, "%.2d:%.2d:%.2d",
+ sprintf(buf, "%.2d:%.2d:%.2d",
tp->tm_hour, tp->tm_min, tp->tm_sec);
return(buf);
@@ -1147,7 +1147,7 @@ register struct proctab *prp;
error(errno, werrmsg, prp->pr_jfname);
if (fflush(prp->pr_jfp) < 0)
error(errno, werrmsg, prp->pr_jfname);
- (void) fclose(child->pr_jfp);
+ fclose(child->pr_jfp);
child->pr_jfp = prp->pr_jfp;
if (UNLINK(child->pr_jfname) < 0)
error(errno, "can't unlink", child->pr_jfname);
@@ -1168,7 +1168,7 @@ struct proctab *prp;
{
static char scenref[REFSZ];
- (void) sprintf(scenref, tcc_scenref_fmt,
+ sprintf(scenref, tcc_scenref_fmt,
prp->pr_scen->sc_ref,
prp->pr_sys ? *prp->pr_sys : 0);
diff --git a/src/tet3/tcc/lock.c b/src/tet3/tcc/lock.c
index bb13fb73..8c4dd429 100644
--- a/src/tet3/tcc/lock.c
+++ b/src/tet3/tcc/lock.c
@@ -116,7 +116,7 @@ char *dir, lkname[];
err = errno ? errno : tet_tcerrno;
break;
}
- (void) sprintf(msg, fmt, lktype);
+ sprintf(msg, fmt, lktype);
prperror(prp, *prp->pr_sys, err, msg, lkpath);
return(-1);
}
@@ -124,7 +124,7 @@ char *dir, lkname[];
TRACE4(tet_Ttcc, 4, "created %s lock %s on system %s",
lktype, lnp, tet_i2a(*prp->pr_sys));
- (void) sprintf(lkname, "%.*s", lknamelen, lnp);
+ sprintf(lkname, "%.*s", lknamelen, lnp);
return(0);
}
@@ -153,7 +153,7 @@ char *lkname;
/* remove the lock file */
errno = 0;
if (tcc_unlink(*prp->pr_sys, lkname) < 0) {
- (void) sprintf(msg, fmt, lktype, "");
+ sprintf(msg, fmt, lktype, "");
prperror(prp, *prp->pr_sys, errno ? errno : tet_tcerrno,
msg, lkname);
rc = -1;
@@ -183,7 +183,7 @@ char *lkname;
#endif
break;
default:
- (void) sprintf(msg, fmt, lktype, " directory");
+ sprintf(msg, fmt, lktype, " directory");
prperror(prp, *prp->pr_sys, errno ? errno : tet_tcerrno,
msg, lkdir);
rc = -1;
diff --git a/src/tet3/tcc/proctab.c b/src/tet3/tcc/proctab.c
index 8464ae16..85a9a151 100644
--- a/src/tet3/tcc/proctab.c
+++ b/src/tet3/tcc/proctab.c
@@ -214,7 +214,7 @@ int state;
case PRS_WAIT:
return("WAIT");
default:
- (void) sprintf(msg, "%s%d", text, state);
+ sprintf(msg, "%s%d", text, state);
return(msg);
}
}
@@ -256,7 +256,7 @@ int state;
case TCS_END:
return("END");
default:
- (void) sprintf(msg, "%s%d", text, state);
+ sprintf(msg, "%s%d", text, state);
return(msg);
}
}
@@ -308,7 +308,7 @@ int state;
case PTS_SIGKILL:
return("SIGKILL");
default:
- (void) sprintf(msg, "%s%d", text, state);
+ sprintf(msg, "%s%d", text, state);
return(msg);
}
}
diff --git a/src/tet3/tcc/proctc.c b/src/tet3/tcc/proctc.c
index 576e7775..80161cd0 100644
--- a/src/tet3/tcc/proctc.c
+++ b/src/tet3/tcc/proctc.c
@@ -488,13 +488,13 @@ struct proctab *prp;
timestr = jnl_time(time((time_t *) 0));
ep = prp->pr_scen;
#ifdef TET_LITE /* -LITE-CUT-LINE- */
- (void) printf("%s %-7s %s\n", timestr, action, ep->sc_tcname);
+ printf("%s %-7s %s\n", timestr, action, ep->sc_tcname);
#else /* -START-LITE-CUT- */
for (ip = prp->pr_sys; ip < prp->pr_sys + prp->pr_nsys; ip++)
- (void) printf("%s %-7s %s on system %03d\n",
+ printf("%s %-7s %s on system %03d\n",
timestr, action, ep->sc_tcname, *ip);
#endif /* TET_LITE */ /* -END-LITE-CUT- */
- (void) fflush(stdout);
+ fflush(stdout);
}
/* start a new activity */
@@ -689,7 +689,7 @@ register struct proctab *prp;
/* unlock the execution directory */
if (prp->pr_execlock) {
- (void) tcc_unlock(prp, prp->pr_flags & PRF_SHLOCK,
+ tcc_unlock(prp, prp->pr_flags & PRF_SHLOCK,
prp->pr_execlock);
TRACE2(tet_Tbuf, 6, "free pr_execlock = %s",
tet_i2x(prp->pr_execlock));
@@ -699,7 +699,7 @@ register struct proctab *prp;
/* unlock the source directory */
if (prp->pr_srclock) {
- (void) tcc_unlock(prp, prp->pr_flags & PRF_SHLOCK,
+ tcc_unlock(prp, prp->pr_flags & PRF_SHLOCK,
prp->pr_srclock);
TRACE2(tet_Tbuf, 6, "free pr_srclock = %s",
tet_i2x(prp->pr_srclock));
@@ -1282,25 +1282,25 @@ register struct proctab *prp;
/* perform per-proctab journal end processing */
#ifndef TET_LITE /* -START-LITE-CUT- */
if (prp->pr_flags & PRF_JNL_CHILD) {
- (void) run_child_proctabs(prp, tcs1_jnlend);
+ run_child_proctabs(prp, tcs1_jnlend);
jnl_consolidate(prp);
prp->pr_flags &= ~PRF_JNL_CHILD;
}
else
#endif /* !TET_LITE */ /* -END-LITE-CUT- */
- (void) tcs1_jnlend(prp);
+ tcs1_jnlend(prp);
/* remove the temporary directory if there is one */
- (void) RUN_PROCTABS(prp, tcs1_rmtmpdir);
+ RUN_PROCTABS(prp, tcs1_rmtmpdir);
/* ensure that all locks are removed */
- (void) RUN_PROCTABS(prp, tcs1_unlock);
+ RUN_PROCTABS(prp, tcs1_unlock);
/* free the tet_xres file names */
- (void) RUN_PROCTABS(prp, tcs1_freetetxres);
+ RUN_PROCTABS(prp, tcs1_freetetxres);
/* free the execution directory names */
- (void) RUN_PROCTABS(prp, tcs1_freetcedir);
+ RUN_PROCTABS(prp, tcs1_freetcedir);
#ifdef TET_LITE /* -LITE-CUT-LINE- */
ASSERT(prp->pr_child == (struct proctab *) 0);
@@ -1374,7 +1374,7 @@ struct proctab *prp;
tet_i2x(prp), prpflags(prp->pr_flags));
if (prp->pr_tmpdir) {
- (void) tcc_rmtmpdir(prp, prp->pr_tmpdir);
+ tcc_rmtmpdir(prp, prp->pr_tmpdir);
TRACE2(tet_Tbuf, 6, "free pr_tmpdir = %s",
tet_i2x(prp->pr_tmpdir));
free(prp->pr_tmpdir);
diff --git a/src/tet3/tcc/proctcd.c b/src/tet3/tcc/proctcd.c
index 47b90dfb..c152f7a5 100644
--- a/src/tet3/tcc/proctcd.c
+++ b/src/tet3/tcc/proctcd.c
@@ -106,7 +106,7 @@ register struct proctab *prp;
prperror(prp, -1, tet_xderrno,
"can't send system list to XRESD", (char *) 0);
rm_snid_xrid(prp);
- (void) UNLINK(fname);
+ UNLINK(fname);
return(-1);
}
@@ -240,7 +240,7 @@ void unlink_xres(prp)
struct proctab *prp;
{
if (prp->pr_xfname) {
- (void) UNLINK(prp->pr_xfname);
+ UNLINK(prp->pr_xfname);
TRACE2(tet_Tbuf, 6, "free prp->pr_xfname = %s",
tet_i2x(prp->pr_xfname));
free(prp->pr_xfname);
diff --git a/src/tet3/tcc/rescode.c b/src/tet3/tcc/rescode.c
index f0ebce72..d75f5d14 100644
--- a/src/tet3/tcc/rescode.c
+++ b/src/tet3/tcc/rescode.c
@@ -148,7 +148,7 @@ static void irc2()
fatal(errno, "can't open combined rescode file", rcftmp);
/* write out the default results codes */
- (void) fprintf(fp, "# master results code file\n\n");
+ fprintf(fp, "# master results code file\n\n");
for (rtp = tet_restab; rtp < tet_restab + tet_nrestab; rtp++)
if (fprintf(fp, "%d \"%s\" %s\n", rtp->rt_code, rtp->rt_name,
rtp->rt_abrt ? "Abort" : "Continue") < 0)
@@ -192,7 +192,7 @@ static void rescode_distribute()
*(lines + nlines++) = rstrstore(line);
}
- (void) fclose(fp);
+ fclose(fp);
/* distribute the lines to each remote system */
for (sysid = 1, sysmax = symax(); sysid <= sysmax; sysid++)
@@ -241,7 +241,7 @@ int nlines;
/* open the remote file */
if ((fid = tet_tcfopen(sp->sy_sysid, cfname)) < 0) {
- (void) sprintf(msg, fmt, sizeof msg - sizeof fmt, cfname);
+ sprintf(msg, fmt, sizeof msg - sizeof fmt, cfname);
if (!IS_ER_ERRNO(tet_tcerrno))
errno = 0;
error(errno ? errno : tet_tcerrno, msg, tet_i2a(sp->sy_sysid));
@@ -282,14 +282,14 @@ void rescode_cleanup()
#endif /* !TET_LITE */ /* -END-LITE-CUT- */
/* remove the local tmp result code file */
- (void) UNLINK(rcftmp);
+ UNLINK(rcftmp);
#ifndef TET_LITE /* -START-LITE-CUT- */
/* remove all the remote tmp rescode files */
for (sysid = 1, sysmax = symax(); sysid <= sysmax; sysid++)
if ((sp = syfind(sysid)) != (struct systab *) 0 &&
sp->sy_rcfname)
- (void) tet_tcunlink(sysid, sp->sy_rcfname);
+ tet_tcunlink(sysid, sp->sy_rcfname);
#endif /* !TET_LITE */ /* -END-LITE-CUT- */
}
diff --git a/src/tet3/tcc/resdir.c b/src/tet3/tcc/resdir.c
index 86232bd8..869b894c 100644
--- a/src/tet3/tcc/resdir.c
+++ b/src/tet3/tcc/resdir.c
@@ -143,7 +143,7 @@ char *resroot;
while ((dp = READDIR(dirp)) != (struct dirent *) 0)
if ((thisval = atoi(dp->d_name)) > maxval)
maxval = thisval;
- (void) CLOSEDIR(dirp);
+ CLOSEDIR(dirp);
}
/*
@@ -156,7 +156,7 @@ char *resroot;
/* construct the name of the subdirectory for the selected
modes of operation */
- (void) sprintf(buf, "%04d%s", maxval, resdirsuffix());
+ sprintf(buf, "%04d%s", maxval, resdirsuffix());
return(buf);
}
diff --git a/src/tet3/tcc/rrproc.c b/src/tet3/tcc/rrproc.c
index 3d3ea4f9..bf0b4b0e 100644
--- a/src/tet3/tcc/rrproc.c
+++ b/src/tet3/tcc/rrproc.c
@@ -162,7 +162,7 @@ char *codelist, *old_journal_file;
** and split the codelist into fields
*/
RBUFCHK((char **) &argv, &largv, n * sizeof *argv);
- (void) sprintf(buf, "%.*s", (int) sizeof buf - 1, codelist);
+ sprintf(buf, "%.*s", (int) sizeof buf - 1, codelist);
argc = split(buf, argv, n, ',');
/*
@@ -223,7 +223,7 @@ char *codelist, *old_journal_file;
(jlp = rrp_getline(buf)) == (struct jline *) 0 ||
jlp->jl_id != TET_JNL_TCC_START
) {
- (void) fprintf(stderr, "TCC: old journal file does not start with a TCC Start line: %s\n",
+ fprintf(stderr, "TCC: old journal file does not start with a TCC Start line: %s\n",
jfname);
tcc_exit(1);
}
@@ -270,7 +270,7 @@ char *codelist, *old_journal_file;
case TET_JNL_TP_START:
case TET_JNL_TP_RESULT:
if ((tcc_modes & TCC_RESUME) == 0 || !resume_scen) {
- (void) fprintf(stderr, "TCC: found %s outside the scope of a Test Case at line %ld in old journal file %s\n",
+ fprintf(stderr, "TCC: found %s outside the scope of a Test Case at line %ld in old journal file %s\n",
prjnlid(jlp->jl_id), jlp->jl_lineno,
jfname);
tcc_exit(1);
@@ -299,25 +299,25 @@ char *codelist, *old_journal_file;
case TET_JNL_RMT_END:
case TET_JNL_DIST_END:
#endif /* !TET_LITE */ /* -END-LITE-CUT- */
- (void) rrp_findscen(jlp);
+ rrp_findscen(jlp);
break;
}
}
- (void) fclose(jfp);
+ fclose(jfp);
/*
** see if any test cases have been selected (in RERUN mode) or if
** a resume point has been found (in RESUME mode)
*/
if ((tcc_modes & TCC_RERUN) && !sel) {
- (void) printf("TCC: rerun codelist does not select any test cases to rerun\n");
- (void) fflush(stdout);
+ printf("TCC: rerun codelist does not select any test cases to rerun\n");
+ fflush(stdout);
tcc_exit(0);
}
if ((tcc_modes & TCC_RESUME) && !resume_scen) {
- (void) printf("TCC: resume codelist does not identify a resume point in the scenario\n");
- (void) fflush(stdout);
+ printf("TCC: resume codelist does not identify a resume point in the scenario\n");
+ fflush(stdout);
tcc_exit(0);
}
@@ -353,7 +353,7 @@ struct jline *jlp;
/* ensure that the tcc version number matches our version number */
if (strcmp(jlp->jl_flds2[0], tcc_version)) {
- (void) fprintf(stderr, "TCC version %s: old journal file was generated by a different version of tcc (%s)\n",
+ fprintf(stderr, "TCC version %s: old journal file was generated by a different version of tcc (%s)\n",
tcc_version, jlp->jl_flds2[0]);
tcc_exit(1);
}
@@ -392,7 +392,7 @@ struct jline *jlp;
break;
case 'm':
if (tcc_modes & TCC_RESUME) {
- (void) fprintf(stderr, "TCC: can't RESUME using an old journal file which has been generated by tcc in RESUME mode\n");
+ fprintf(stderr, "TCC: can't RESUME using an old journal file which has been generated by tcc in RESUME mode\n");
tcc_exit(1);
}
break;
@@ -409,7 +409,7 @@ struct jline *jlp;
badynopt(c);
break;
case '?':
- (void) fprintf(stderr, "TCC: TCC Start line in old journal file contains an invalid or incomplete command-line option\n");
+ fprintf(stderr, "TCC: TCC Start line in old journal file contains an invalid or incomplete command-line option\n");
tcc_exit(1);
break;
}
@@ -422,7 +422,7 @@ struct jline *jlp;
(tcc_modes & TCC_RESUME) &&
(tcc_modes & (TCC_BUILD | TCC_EXEC | TCC_CLEAN)) != modes
) {
- (void) fprintf(stderr, "TCC: set of operation modes in old journal file (%s) does not match the set selected for this run (%s)\n",
+ fprintf(stderr, "TCC: set of operation modes in old journal file (%s) does not match the set selected for this run (%s)\n",
prtccmode(modes),
prtccmode(tcc_modes & (TCC_BUILD | TCC_EXEC | TCC_CLEAN)));
tcc_exit(1);
@@ -476,7 +476,7 @@ int *argcp;
if (!strncmp(p1, key, sizeof key - 1))
break;
if (!*p1) {
- (void) fprintf(stderr, "TCC: can't find tcc command in TCC Start line in old journal file\n");
+ fprintf(stderr, "TCC: can't find tcc command in TCC Start line in old journal file\n");
tcc_exit(1);
}
@@ -545,7 +545,7 @@ int *argcp;
static void badynopt(c)
int c;
{
- (void) fprintf(stderr, "TCC: TCC Start line in old journal file contains a bad format -%c option\n", c);
+ fprintf(stderr, "TCC: TCC Start line in old journal file contains a bad format -%c option\n", c);
tcc_exit(1);
}
@@ -563,7 +563,7 @@ struct jline *jlp;
/* find the scenario element corresponding to the scenario reference */
if ((ep = rrp_fs2(sctree->sc_child, jlp->jl_ref)) == (struct scentab *) 0) {
- (void) fprintf(stderr, "TCC: the specified scenario does not contain an element which corresponds to reference %ld-%d at line %ld in old journal file %s\n",
+ fprintf(stderr, "TCC: the specified scenario does not contain an element which corresponds to reference %ld-%d at line %ld in old journal file %s\n",
jlp->jl_ref, jlp->jl_sys, jlp->jl_lineno, jfname);
tcc_exit(1);
}
@@ -647,9 +647,9 @@ struct jline *jlp;
directive = prscdir(ep->sc_directive);
else
directive = "";
- (void) fprintf(stderr, "TCC: %s line %ld in old journal file %s\n",
+ fprintf(stderr, "TCC: %s line %ld in old journal file %s\n",
prjnlid(jlp->jl_id), jlp->jl_lineno, jfname);
- (void) fprintf(stderr, "does not match %s%s%s element at line %d in scenario file %s\n",
+ fprintf(stderr, "does not match %s%s%s element at line %d in scenario file %s\n",
directive, (ep->sc_type == SC_DIRECTIVE) ? " " : "",
prsctype(ep->sc_type), ep->sc_lineno, ep->sc_fname);
tcc_exit(1);
@@ -712,10 +712,10 @@ struct jline *jlp;
ASSERT(is_testcase_start_id);
if (strcmp(ep->sc_tcname, jlp->jl_flds2[1])) {
- (void) fprintf(stderr, "TCC: the test case name (%s) on %s line %ld in old journal file %s\n",
+ fprintf(stderr, "TCC: the test case name (%s) on %s line %ld in old journal file %s\n",
jlp->jl_flds2[1], prjnlid(jlp->jl_id),
jlp->jl_lineno, jfname);
- (void) fprintf(stderr, "does not match the test case name (%s) at line %d of scenario file %s\n",
+ fprintf(stderr, "does not match the test case name (%s) at line %d of scenario file %s\n",
ep->sc_tcname, ep->sc_lineno, ep->sc_fname);
tcc_exit(1);
}
@@ -792,9 +792,9 @@ int startid;
case TET_JNL_TC_END:
case TET_JNL_CLEAN_END:
if (endid != jlp->jl_id) {
- (void) fprintf(stderr, "TCC: expected %s at line %ld in old journal file %s\n",
+ fprintf(stderr, "TCC: expected %s at line %ld in old journal file %s\n",
prjnlid(endid), jlp->jl_lineno, jfname);
- (void) fprintf(stderr,
+ fprintf(stderr,
"instead, found %s line\n",
prjnlid(jlp->jl_id));
tcc_exit(1);
@@ -808,7 +808,7 @@ int startid;
case TET_JNL_IC_END:
case TET_JNL_TP_START:
case TET_JNL_TP_RESULT:
- (void) fprintf(stderr, "TCC: found %s outside the scope of an IC at line %ld in old journal file %s\n",
+ fprintf(stderr, "TCC: found %s outside the scope of an IC at line %ld in old journal file %s\n",
prjnlid(jlp->jl_id), jlp->jl_lineno, jfname);
tcc_exit(1);
break;
@@ -959,7 +959,7 @@ int mode;
done = 1;
break;
case TET_JNL_TP_RESULT:
- (void) fprintf(stderr, "TCC: found %s outside the scope of a TP at line %ld in old journal file %s\n",
+ fprintf(stderr, "TCC: found %s outside the scope of a TP at line %ld in old journal file %s\n",
prjnlid(jlp->jl_id), jlp->jl_lineno, jfname);
tcc_exit(1);
break;
@@ -982,7 +982,7 @@ int mode;
p = tet_i2a(icno);
needlen = len + strlen(p) + 1;
RBUFCHK(&resume_iclist, &tmplen, needlen);
- (void) sprintf(resume_iclist + len - 1, ",%s", p);
+ sprintf(resume_iclist + len - 1, ",%s", p);
}
return(sel);
}
@@ -1004,7 +1004,7 @@ int mode;
resume_mode = mode;
if (mode == TCC_EXEC) {
ASSERT(resume_iclist == (char *) 0);
- (void) sprintf(buf, "%d", icno);
+ sprintf(buf, "%d", icno);
resume_iclist = rstrstore(buf);
TRACE2(tet_Ttcc, 6, "\tresume at IC %s",
resume_iclist);
@@ -1165,7 +1165,7 @@ char *buf;
/* split the line into 3 |-separated fields */
if (jnlproc_split(line, flds, buf) < 0 || !isdigit(*flds[0])) {
- (void) sprintf(line, fmt1, lcount);
+ sprintf(line, fmt1, lcount);
error(0, line, jfname);
continue;
}
@@ -1217,9 +1217,9 @@ char *buf;
/* check the number of subfields in the 2nd field */
if (expflds != nflds2) {
- (void) sprintf(line, fmt2, expflds);
+ sprintf(line, fmt2, expflds);
error(0, line, tet_i2a(nflds2));
- (void) sprintf(line, fmt1, lcount);
+ sprintf(line, fmt1, lcount);
error(0, line, jfname);
continue;
}
@@ -1238,7 +1238,7 @@ char *buf;
case TET_JNL_DIST_START:
#endif /* !TET_LITE */ /* -END-LITE-CUT- */
if (!isdigit(*jline.jl_flds2[0])) {
- (void) sprintf(line, fmt1, lcount);
+ sprintf(line, fmt1, lcount);
error(0, line, jfname);
continue;
}
@@ -1253,7 +1253,7 @@ char *buf;
*jline.jl_flds2[1] == '@'
)
) {
- (void) sprintf(line, fmt1, lcount);
+ sprintf(line, fmt1, lcount);
error(0, line, jfname);
continue;
}
@@ -1268,7 +1268,7 @@ char *buf;
*jline.jl_flds2[1] == '-'
)
) {
- (void) sprintf(line, fmt1, lcount);
+ sprintf(line, fmt1, lcount);
error(0, line, jfname);
continue;
}
@@ -1278,7 +1278,7 @@ char *buf;
!isdigit(*jline.jl_flds2[0]) ||
!isdigit(*jline.jl_flds2[1])
) {
- (void) sprintf(line, fmt1, lcount);
+ sprintf(line, fmt1, lcount);
error(0, line, jfname);
continue;
}
@@ -1291,7 +1291,7 @@ char *buf;
!isdigit(*jline.jl_flds2[1]) ||
!isdigit(*jline.jl_flds2[2])
) {
- (void) sprintf(line, fmt1, lcount);
+ sprintf(line, fmt1, lcount);
error(0, line, jfname);
continue;
}
@@ -1529,7 +1529,7 @@ int icno;
p = tet_i2a(icno);
needlen = strlen(ep->sc_exiclist) + strlen(p) + 2;
RBUFCHK(&iclist, &len, needlen);
- (void) sprintf(iclist, "%s,%s", ep->sc_exiclist, p);
+ sprintf(iclist, "%s,%s", ep->sc_exiclist, p);
exiclist_set(ep, iclist);
}
@@ -1790,7 +1790,7 @@ int id;
case TET_JNL_TCC_END:
return("TCC End");
default:
- (void) sprintf(msg, "%s%d", text, id);
+ sprintf(msg, "%s%d", text, id);
return(msg);
}
}
diff --git a/src/tet3/tcc/scen1.c b/src/tet3/tcc/scen1.c
index 8abba13b..13ac318c 100644
--- a/src/tet3/tcc/scen1.c
+++ b/src/tet3/tcc/scen1.c
@@ -206,7 +206,7 @@ char *fname;
ifstp = ifstack;
while (ifstack) {
if (ifstack->if_next && ifstack->if_fp)
- (void) fclose(ifstack->if_fp);
+ fclose(ifstack->if_fp);
ifsfree(ifspop());
}
@@ -243,7 +243,7 @@ static int find1scen()
/* start of new scenario */
if (skipstart) {
n = ifstp->if_lcount - skipstart;
- (void) sprintf(msg, fmt, n, n == 1 ? "" : "s");
+ sprintf(msg, fmt, n, n == 1 ? "" : "s");
scenermsg(msg, (char *) 0, ifstp->if_lcount,
ifstp->if_fname);
}
@@ -470,7 +470,7 @@ int type, flags, lineno;
lsceninfo = 0;
RBUFCHK(&ep->sc_sceninfo, &lsceninfo,
(int) strlen(element) + 3);
- (void) sprintf(ep->sc_sceninfo, "\"%s\"", element);
+ sprintf(ep->sc_sceninfo, "\"%s\"", element);
break;
case SC_TESTCASE:
tcname = element;
@@ -574,7 +574,7 @@ int lineno;
for (dirp = dirs; dirp < &dirs[ndirs]; dirp++) {
/* count the number of comma-separated arguments
associated with this directive */
- (void) strcpy(buf, *dirp);
+ strcpy(buf, *dirp);
args[0] = "";
nargs = split(buf, args, MAXARGS, ',') - 1;
@@ -1035,7 +1035,7 @@ int currline;
}
/* finally, close the file and return (but don't free fname!) */
- (void) fclose(fp);
+ fclose(fp);
TRACE1(tet_Tscen, 4, "includefile(): return");
}
@@ -1188,7 +1188,7 @@ static char *getline_tcc()
** if there is one
*/
if ((lcp = lcpop()) != (struct lcache *) 0) {
- (void) strcpy(buf, lcp->lc_line);
+ strcpy(buf, lcp->lc_line);
lcfree(lcp);
TRACE2(tet_Tscen, 10, "getline_tcc(): line = <%s>", firstpart(buf));
return(buf);
@@ -1224,7 +1224,7 @@ static char *getline_tcc()
"getline_tcc(): encountered EOF on %s",
ifstp->if_fname);
if (ifstp->if_next) {
- (void) fclose(ifstp->if_fp);
+ fclose(ifstp->if_fp);
ifsfree(ifspop());
continue;
}
@@ -1525,7 +1525,7 @@ char *s;
static char dots[] = " ...";
static char buf[PLEN + sizeof dots];
- (void) sprintf(buf, "%.*s%s", PLEN, s,
+ sprintf(buf, "%.*s%s", PLEN, s,
(int) strlen(s) > PLEN ? dots : "");
return(buf);
diff --git a/src/tet3/tcc/scen2.c b/src/tet3/tcc/scen2.c
index 10645441..09150cca 100644
--- a/src/tet3/tcc/scen2.c
+++ b/src/tet3/tcc/scen2.c
@@ -270,7 +270,7 @@ int proc2sclist()
continue;
TRACE3(tet_Tscen, 4, "tloop check loop TOP: descend tree below scenario %s at %s",
ep->sc_scenario, tet_i2x(ep));
- (void) check_timed_loops(ep->sc_child);
+ check_timed_loops(ep->sc_child);
}
if (scenerrors)
return(0);
@@ -517,7 +517,7 @@ char *fname;
static char fmt[] = "found unmatched %.20s directive";
char msg[sizeof fmt + 20];
- (void) sprintf(msg, fmt, prscdir(directive));
+ sprintf(msg, fmt, prscdir(directive));
scenerror(msg, (char *) 0, lineno, fname);
}
@@ -1109,7 +1109,7 @@ register struct scentab *ep1;
s1 = prsctype(ep1->sc_type);
s2 = "element";
}
- (void) sprintf(msg, fmt, s1, s2);
+ sprintf(msg, fmt, s1, s2);
TRACESCELEM(tet_Tscen, 6, ep1, msg);
#endif
@@ -1294,7 +1294,7 @@ struct scentab **sctp;
if (edp >= dp->dt_enc + dp->dt_nenc) {
scenermsg(prscdir(q->sc_directive), "directive",
q->sc_lineno, q->sc_fname);
- (void) sprintf(msg, fmt, prscdir(ep->sc_directive));
+ sprintf(msg, fmt, prscdir(ep->sc_directive));
scenerror(msg, "directive", ep->sc_lineno,
ep->sc_fname);
}
@@ -1308,7 +1308,7 @@ struct scentab **sctp;
void check_empty_timed_loops()
{
- (void) check_timed_loops(sctree->sc_child);
+ check_timed_loops(sctree->sc_child);
if (scenerrors)
scengiveup();
}
diff --git a/src/tet3/tcc/scenario.c b/src/tet3/tcc/scenario.c
index 80dab87a..d5286f76 100644
--- a/src/tet3/tcc/scenario.c
+++ b/src/tet3/tcc/scenario.c
@@ -155,7 +155,7 @@ char *scenario, *sopt, *cwd;
else {
if (proc1scfile(fp, scenario_file) < 0)
tcc_exit(1);
- (void) fclose(fp);
+ fclose(fp);
}
if (scenerrors)
scengiveup();
diff --git a/src/tet3/tcc/scenpp.c b/src/tet3/tcc/scenpp.c
index e98f2727..8cd67813 100644
--- a/src/tet3/tcc/scenpp.c
+++ b/src/tet3/tcc/scenpp.c
@@ -205,7 +205,7 @@ char **argv;
error(errno, "can't open", *argv);
else {
rc = proc1scfile(ifp, *argv);
- (void) fclose(ifp);
+ fclose(ifp);
if (rc < 0)
tcc_exit(1);
}
@@ -242,13 +242,13 @@ char **argv;
ASSERT(ep->sc_magic == SC_MAGIC);
ASSERT(ep->sc_type == SC_SCENARIO);
printloc(ep->sc_lineno, ep->sc_fname, 0);
- (void) fprintf(ofp, "scenario%s(\"%s\")\n{\n",
+ fprintf(ofp, "scenario%s(\"%s\")\n{\n",
printaddr(ep), ep->sc_scenario);
lastlineno += 2;
printsctree(ep->sc_child, 1);
- (void) fprintf(ofp, "}\n\n");
+ fprintf(ofp, "}\n\n");
lastlineno += 2;
- (void) fflush(ofp);
+ fflush(ofp);
}
tcc_exit(0);
@@ -274,7 +274,7 @@ static void badusage()
char msg[1024];
register char *p = msg;
- (void) sprintf(p, "\t%s", tet_progname);
+ sprintf(p, "\t%s", tet_progname);
len = strlen(p);
p += len;
pos = len + 7;
@@ -286,7 +286,7 @@ static void badusage()
}
else
sep = " ";
- (void) sprintf(p, "%s[%s]", sep, options[n]);
+ sprintf(p, "%s[%s]", sep, options[n]);
len = strlen(p);
p += len;
pos += len;
@@ -307,19 +307,19 @@ int indent;
break;
case SC_TESTCASE:
printloc(ep->sc_lineno, ep->sc_fname, indent);
- (void) fprintf(ofp,
+ fprintf(ofp,
"testcase%s(\"%s\", \"%s\");\n",
printaddr(ep), ep->sc_tcname,
ep->sc_exiclist ? ep->sc_exiclist : "all");
break;
case SC_SCENINFO:
printloc(ep->sc_lineno, ep->sc_fname, indent);
- (void) fprintf(ofp, "sceninfo%s(%s);\n",
+ fprintf(ofp, "sceninfo%s(%s);\n",
printaddr(ep), ep->sc_sceninfo);
break;
case SC_SCEN_NAME:
printloc(ep->sc_lineno, ep->sc_fname, indent);
- (void) fprintf(ofp, "call%s(\"%s\");\n",
+ fprintf(ofp, "call%s(\"%s\");\n",
printaddr(ep), ep->sc_scen_name);
break;
default:
@@ -376,16 +376,16 @@ int indent;
#endif
case SD_VARIABLE:
doindent(indent);
- (void) fprintf(ofp, "{\n");
+ fprintf(ofp, "{\n");
lastlineno++;
for (vp = ep->sc_vars; vp < ep->sc_vars + ep->sc_nvars; vp++) {
printloc(ep->sc_lineno, ep->sc_fname, indent + 1);
- (void) fprintf(ofp, "variable%s %s\n",
+ fprintf(ofp, "variable%s %s\n",
printaddr(ep), *vp);
}
printsctree(ep->sc_child, indent + 1);
doindent(indent);
- (void) fprintf(ofp, "}\n");
+ fprintf(ofp, "}\n");
lastlineno++;
return;
default:
@@ -396,27 +396,27 @@ int indent;
}
printloc(ep->sc_lineno, ep->sc_fname, indent);
- (void) fprintf(ofp, "%s%s(", func, printaddr(ep));
+ fprintf(ofp, "%s%s(", func, printaddr(ep));
switch (ep->sc_directive) {
case SD_TIMED_LOOP:
- (void) fprintf(ofp, "%ld", ep->sc_seconds);
+ fprintf(ofp, "%ld", ep->sc_seconds);
break;
default:
for (ap = argv; ap < argv + argc; ap++) {
if (ap > argv)
- (void) fprintf(ofp, ", ");
- (void) fprintf(ofp, "%d", *ap);
+ fprintf(ofp, ", ");
+ fprintf(ofp, "%d", *ap);
}
break;
}
- (void) fprintf(ofp, ")\n");
+ fprintf(ofp, ")\n");
doindent(indent);
- (void) fprintf(ofp, "{\n");
+ fprintf(ofp, "{\n");
lastlineno++;
printsctree(ep->sc_child, indent + 1);
doindent(indent);
- (void) fprintf(ofp, "}\n");
+ fprintf(ofp, "}\n");
lastlineno++;
}
@@ -437,7 +437,7 @@ char *thisfname;
doit = 1;
}
if (doit)
- (void) fprintf(ofp, "# %d \"%s\"\n",
+ fprintf(ofp, "# %d \"%s\"\n",
thislineno, thisfname);
}
@@ -450,10 +450,10 @@ int indent;
register int space;
for (space = indent * tabwidth; space > 7; space -= 8)
- (void) putc('\t', ofp);
+ putc('\t', ofp);
while (space-- > 0)
- (void) putc(' ', ofp);
+ putc(' ', ofp);
}
static char *printaddr(ep)
@@ -465,13 +465,13 @@ struct scentab *ep;
buf[0] = '\0';
if (printscrefs) {
- (void) sprintf(p, "-%ld", ep->sc_ref);
+ sprintf(p, "-%ld", ep->sc_ref);
p += strlen(p);
}
#ifndef NOTRACE
if (tet_Tscen) {
- (void) sprintf(p, "@%#lx", (long) ep);
+ sprintf(p, "@%#lx", (long) ep);
p += strlen(p);
}
#endif
diff --git a/src/tet3/tcc/scentab.c b/src/tet3/tcc/scentab.c
index b5b5de02..135b7d65 100644
--- a/src/tet3/tcc/scentab.c
+++ b/src/tet3/tcc/scentab.c
@@ -412,7 +412,7 @@ int type;
case SC_SCEN_NAME:
return("REFERENCED SCENARIO NAME");
default:
- (void) sprintf(msg, fmt, type);
+ sprintf(msg, fmt, type);
return(msg);
}
}
@@ -459,7 +459,7 @@ int directive;
if (dp && dp->dt_name)
return(dp->dt_name);
else {
- (void) sprintf(msg, fmt, directive);
+ sprintf(msg, fmt, directive);
return(msg);
}
}
diff --git a/src/tet3/tcc/sigtrap.c b/src/tet3/tcc/sigtrap.c
index 552eef10..a6ba1aa6 100644
--- a/src/tet3/tcc/sigtrap.c
+++ b/src/tet3/tcc/sigtrap.c
@@ -106,7 +106,7 @@ int sig;
if (jnl_usable())
- (void) fprintf(stderr, "%s %d\n", text, sig);
+ fprintf(stderr, "%s %d\n", text, sig);
fatal(0, text, tet_i2a(sig));
}
@@ -118,10 +118,10 @@ int sig;
void execsigtrap()
{
exec_block_signals();
- (void) install_handler(SIGHUP, engine_sigterm);
- (void) install_handler(SIGQUIT, engine_abort);
- (void) install_handler(SIGPIPE, engine_sigterm);
- (void) install_handler(SIGTERM, engine_sigterm);
+ install_handler(SIGHUP, engine_sigterm);
+ install_handler(SIGQUIT, engine_abort);
+ install_handler(SIGPIPE, engine_sigterm);
+ install_handler(SIGTERM, engine_sigterm);
}
/*
@@ -151,11 +151,11 @@ int how;
{
sigset_t mask;
- (void) sigemptyset(&mask);
- (void) sigaddset(&mask, SIGHUP);
- (void) sigaddset(&mask, SIGQUIT);
- (void) sigaddset(&mask, SIGPIPE);
- (void) sigaddset(&mask, SIGTERM);
+ sigemptyset(&mask);
+ sigaddset(&mask, SIGHUP);
+ sigaddset(&mask, SIGQUIT);
+ sigaddset(&mask, SIGPIPE);
+ sigaddset(&mask, SIGTERM);
if (sigprocmask(how, &mask, (sigset_t *) 0) < 0)
fatal(errno, "sigprocmask() failed: how =", tet_i2a(how));
@@ -191,8 +191,8 @@ int sig;
register struct proctab *prp;
- (void) fprintf(stderr, "TCC: user abort called\n");
- (void) fflush(stderr);
+ fprintf(stderr, "TCC: user abort called\n");
+ fflush(stderr);
/*
** this flag tells the execution engine not to start processing
@@ -212,7 +212,7 @@ int sig;
** test cases have terminated and any save files and journal
** processing has completed
*/
- (void) engine_tcinterrupt(sig);
+ engine_tcinterrupt(sig);
}
@@ -247,7 +247,7 @@ int sig;
prp->pr_modes |= TCC_ABORT;
if (prp->pr_state == PRS_WAIT) {
count++;
- (void) RUN_PROCTABS(prp, eng1_tcinterrupt);
+ RUN_PROCTABS(prp, eng1_tcinterrupt);
prp->pr_flags |= PRF_ATTENTION;
}
}
@@ -316,7 +316,7 @@ void engine_shutdown()
for (prp = runq; prp; prp = prp->pr_rqforw)
if (prp->pr_scen->sc_type == SC_TESTCASE) {
count++;
- (void) RUN_PROCTABS(prp, quick_killtc);
+ RUN_PROCTABS(prp, quick_killtc);
}
/* give the tools a chance to terminate */
@@ -355,7 +355,7 @@ struct proctab *prp;
tet_i2x(prp), prtoolstate(prp->pr_toolstate));
if (prp->pr_toolstate == PTS_RUNNING) {
- (void) tcc_kill(*prp->pr_sys, prp->pr_remid, SIGTERM);
+ tcc_kill(*prp->pr_sys, prp->pr_remid, SIGTERM);
prp->pr_toolstate = PTS_EXITED;
}
@@ -381,7 +381,7 @@ void (*func) PROTOLIST((int));
if ((rc = sa.sa_handler) != SIG_IGN) {
sa.sa_handler = func;
sa.sa_flags = 0;
- (void) sigemptyset(&sa.sa_mask);
+ sigemptyset(&sa.sa_mask);
if (sigaction(sig, &sa, (struct sigaction *) 0) < 0)
fatal(errno, "can't install handler for signal",
tet_i2a(sig));
@@ -422,14 +422,14 @@ void (*func) PROTOLIST((int));
/* ignore the signal */
sa.sa_handler = SIG_IGN;
sa.sa_flags = 0;
- (void) sigemptyset(&sa.sa_mask);
+ sigemptyset(&sa.sa_mask);
if (sigaction(sig, &sa, (struct sigaction *) 0) < 0)
fatal(errno, "sigaction(SIG_IGN) failed for signal",
tet_i2a(sig));
/* unblock the signal */
- (void) sigemptyset(&sa.sa_mask);
- (void) sigaddset(&sa.sa_mask, sig);
+ sigemptyset(&sa.sa_mask);
+ sigaddset(&sa.sa_mask, sig);
if (sigprocmask(SIG_UNBLOCK, &sa.sa_mask, (sigset_t *) 0) < 0)
fatal(errno, "sigprocmask(SIG_UNBLOCK) failed for signal",
tet_i2a(sig));
@@ -438,7 +438,7 @@ void (*func) PROTOLIST((int));
if (func != SIG_IGN) {
sa.sa_handler = func;
sa.sa_flags = 0;
- (void) sigemptyset(&sa.sa_mask);
+ sigemptyset(&sa.sa_mask);
if (sigaction(sig, &sa, (struct sigaction *) 0) < 0)
fatal(errno, "sigaction() failed for signal",
tet_i2a(sig));
diff --git a/src/tet3/tcc/tcc.c b/src/tet3/tcc/tcc.c
index bdd05986..ec1b8693 100644
--- a/src/tet3/tcc/tcc.c
+++ b/src/tet3/tcc/tcc.c
@@ -240,7 +240,7 @@ char **argv;
if (*optarg)
nostr(optarg, YN_CMDLINE);
else {
- (void) fprintf(stderr,
+ fprintf(stderr,
"%s: no-string may not be empty\n",
tet_progname);
errors++;
@@ -259,7 +259,7 @@ char **argv;
case 't': /* timeout for test case processing and
lock acqusition */
if ((tcc_timeout = atoi(optarg)) <= 0) {
- (void) fprintf(stderr,
+ fprintf(stderr,
"%s: timeout must be +ve\n", tet_progname);
errors++;
}
@@ -275,7 +275,7 @@ char **argv;
if (*optarg)
yesstr(optarg, YN_CMDLINE);
else {
- (void) fprintf(stderr,
+ fprintf(stderr,
"%s: yes-string may not be empty\n",
tet_progname);
errors++;
@@ -299,7 +299,7 @@ char **argv;
*/
TRACE2(tet_Ttcc, 1, "tcc_modes = %s", prtccmode(tcc_modes));
if ((tcc_modes & (TCC_BUILD | TCC_EXEC | TCC_CLEAN)) == 0) {
- (void) fprintf(stderr,
+ fprintf(stderr,
"%s: at least one of -b, -c, -e and -V must be specified\n",
tet_progname);
errors++;
@@ -307,7 +307,7 @@ char **argv;
/* ensure that only one of rerun and resume mode has been specified */
if ((tcc_modes & TCC_RERUN) && (tcc_modes & TCC_RESUME)) {
- (void) fprintf(stderr,
+ fprintf(stderr,
"%s: only one of -m and -r may be specified\n",
tet_progname);
errors++;
@@ -323,7 +323,7 @@ char **argv;
codelist, old_journal_file);
}
else {
- (void) fprintf(stderr,
+ fprintf(stderr,
"%s: need an old journal file name when -m or -r is specified\n",
tet_progname);
errors++;
@@ -352,7 +352,7 @@ char **argv;
tet_tsname = cwd + strlen(tet_suite_root);
while (isdirsep(*tet_tsname))
tet_tsname++;
- (void) sprintf(fname, "%.*s",
+ sprintf(fname, "%.*s",
(int) sizeof fname - 1, tet_tsname);
for (p = fname; *p; p++)
if (isdirsep(*p)) {
@@ -502,7 +502,7 @@ char **argv;
jnl_init(jopt, cwd);
if (jnl_jfname())
printf("%s: journal file is %s\n", tet_progname, jnl_jfname());
- (void) fflush(stdout);
+ fflush(stdout);
jnl_tcc_start(argcsave, argvsave);
jnl_uname();
@@ -557,7 +557,7 @@ static void badusage()
options[0] = tet_progname;
- (void) fprintf(stderr, "\nusage:\t");
+ fprintf(stderr, "\nusage:\t");
pos = 8;
for (n = 0; n < sizeof options / sizeof options[0]; n++) {
if ((opt = options[n]) == (char *) 0)
@@ -568,10 +568,10 @@ static void badusage()
}
else
sep = n ? " " : "";
- (void) fprintf(stderr, "%s%s", sep, opt);
+ fprintf(stderr, "%s%s", sep, opt);
pos += strlen(opt) + 1;
}
- (void) fprintf(stderr, "\n\nor:\t");
+ fprintf(stderr, "\n\nor:\t");
pos = 8;
for (n = 0; n < sizeof options / sizeof options[0]; n++) {
if ((opt = options[n]) == (char *) 0)
@@ -589,10 +589,10 @@ static void badusage()
}
else
sep = n ? " " : "";
- (void) fprintf(stderr, "%s%s", sep, opt);
+ fprintf(stderr, "%s%s", sep, opt);
pos += strlen(opt) + 1;
}
- (void) fprintf(stderr, "\n\nor:\ttcc -V\n\n");
+ fprintf(stderr, "\n\nor:\ttcc -V\n\n");
tcc_exit(2);
/* NOTREACHED */
@@ -607,7 +607,7 @@ static void prversioninfo()
static char product_name[] =
"TET3";
- (void) fprintf(stderr, "%s: %s%s Release %s\n",
+ fprintf(stderr, "%s: %s%s Release %s\n",
tet_progname,
#ifdef TET_LITE /* -LITE-CUT-LINE */
product_name, "-Lite",
diff --git a/src/tet3/tcc/tcc_in.c b/src/tet3/tcc/tcc_in.c
index 2b2bc4dc..7043aa15 100644
--- a/src/tet3/tcc/tcc_in.c
+++ b/src/tet3/tcc/tcc_in.c
@@ -133,7 +133,7 @@ char **argv;
}
rc = ts_ss2(pp, argv, sd);
- (void) SOCKET_CLOSE(sd);
+ SOCKET_CLOSE(sd);
return(rc);
}
@@ -185,7 +185,7 @@ SOCKET sd;
** the value of the listen socket's handle is passed to the daemon
** using the -l command-line option
*/
- (void) sprintf(path, "%.*s/bin/%s",
+ sprintf(path, "%.*s/bin/%s",
(int) sizeof path - (int) strlen(*argv) - 6,
tet_root, *argv);
@@ -211,15 +211,15 @@ SOCKET sd;
** dup the socket on to fd 0 and close all other files
** except 1 and 2
*/
- (void) close(0);
+ close(0);
if ((rc = fcntl(sd, F_DUPFD, 0)) != 0) {
error(errno, "server socket: fcntl(F_DUPFD) returned",
tet_i2a(rc));
_exit(~0);
}
for (fd = tet_getdtablesize() - 1; fd > 2; fd--)
- (void) close(fd);
- (void) execv(path, argv);
+ close(fd);
+ execv(path, argv);
error(errno, "can't exec", path);
_exit(~0);
}
diff --git a/src/tet3/tcc/tcc_xt.c b/src/tet3/tcc/tcc_xt.c
index 152b23db..e34d26e8 100644
--- a/src/tet3/tcc/tcc_xt.c
+++ b/src/tet3/tcc/tcc_xt.c
@@ -195,7 +195,7 @@ char **argv;
rc = ts_ss3(pp, argv, fd);
- (void) t_close(fd);
+ t_close(fd);
return(rc);
}
@@ -237,7 +237,7 @@ int fd;
if ((ret = T_ALLOC_BIND(fd)) == (struct t_bind *)0) {
xt_error(t_errno, "can't allocate T_BIND", (char *) 0);
- (void) t_close(fd);
+ t_close(fd);
return(-1);
}
TRACE2(tet_Tbuf, 6, "t_alloc() = %s", tet_i2x(ret));
@@ -246,8 +246,8 @@ int fd;
xt_error(t_errno, "can't bind to server fd", (char *)0);
TRACE2(tet_Tbuf, 6, "t_free ret = %s", tet_i2x(ret));
- (void) t_free((char *)ret, T_BIND);
- (void) t_close(fd);
+ t_free((char *)ret, T_BIND);
+ t_close(fd);
return (-1);
}
@@ -255,8 +255,8 @@ int fd;
if (ret->addr.len == 0) {
xt_error(t_errno, "address not generated", (char *)0);
TRACE2(tet_Tbuf, 6, "t_free ret = %s", tet_i2x(ret));
- (void) t_free((char *)ret, T_BIND);
- (void) t_close(fd);
+ t_free((char *)ret, T_BIND);
+ t_close(fd);
return (-1);
}
@@ -284,7 +284,7 @@ int fd;
}
else if (pid == 0) {
/* in child */
- (void) sprintf(path, "%.*s/bin/%s",
+ sprintf(path, "%.*s/bin/%s",
(int) sizeof path - (int) strlen(*argv) - 6,
tet_root, *argv);
#ifndef NOTRACE
@@ -296,9 +296,9 @@ int fd;
#endif
/* dup the connection on to fd 0 and close all other
files except 1 and 2 */
- (void) close(0);
+ close(0);
TRACE2(tet_Tbuf, 6, "t_free ret = %s", tet_i2x(ret));
- (void) t_free((char *)ret, T_BIND);
+ t_free((char *)ret, T_BIND);
if ((rc = fcntl(fd, F_DUPFD, 0)) != 0) {
error(errno, "server socket: fcntl(F_DUPFD) returned",
@@ -306,8 +306,8 @@ int fd;
_exit(~0);
}
for (fd = tet_getdtablesize() - 1; fd > 2; fd--)
- (void) close(fd);
- (void) execv(path, argv);
+ close(fd);
+ execv(path, argv);
error(errno, "can't exec", path);
_exit(~0);
}
@@ -338,18 +338,18 @@ int fd;
if ((tp->tp_call.buf = (char *) malloc(tp->tp_call.maxlen)) == (char *) 0) {
error(errno, "can't malloc server address", (char *)0);
TRACE2(tet_Tbuf, 6, "t_free ret = %s", tet_i2x(ret));
- (void) t_free((char *)ret, T_BIND);
+ t_free((char *)ret, T_BIND);
return (-1);
}
TRACE2(tet_Tbuf, 6, "allocate tp_call.buf = %s",
tet_i2x(tp->tp_call.buf));
- (void) memcpy(tp->tp_call.buf, ret->addr.buf, ret->addr.len);
+ memcpy(tp->tp_call.buf, ret->addr.buf, ret->addr.len);
if (ret->addr.maxlen > ret->addr.len)
- (void) memset(tp->tp_call.buf + ret->addr.len, '\0',
+ memset(tp->tp_call.buf + ret->addr.len, '\0',
ret->addr.maxlen - ret->addr.len);
- (void) t_free((char *)ret, T_BIND);
+ t_free((char *)ret, T_BIND);
return (0);
}
@@ -441,7 +441,7 @@ register int ptype;
}
mp->ts.osico.ts_len = tp->tp_call.len;
- (void) memcpy(mp->ts.osico.ts_nsap, tp->tp_call.buf,
+ memcpy(mp->ts.osico.ts_nsap, tp->tp_call.buf,
tp->tp_call.len);
break;
diff --git a/src/tet3/tcc/tool.c b/src/tet3/tcc/tool.c
index 23da0f53..58ecba48 100644
--- a/src/tet3/tcc/tool.c
+++ b/src/tet3/tcc/tool.c
@@ -299,7 +299,7 @@ char *s;
*/
ap = *avp + *anp;
if (splitflds && nflds > 1) {
- (void) sprintf(buf, "%.*s", (int) sizeof buf - 1, s);
+ sprintf(buf, "%.*s", (int) sizeof buf - 1, s);
nflds = tet_getargs(buf, ap, nflds);
}
else
@@ -360,7 +360,7 @@ char *tcname, **argv, *ocfname;
case TCS_EXEC:
case TCS_CLEAN:
xresfilename(prp->pr_scen->sc_tcname, buf, sizeof buf);
- (void) tcc_unlink(*prp->pr_sys, buf);
+ tcc_unlink(*prp->pr_sys, buf);
prp->pr_tetxres = rstrstore(buf);
break;
}
@@ -391,7 +391,7 @@ char *tcname, **argv, *ocfname;
/* unlink an existing output capture file if one is specified */
if (ocfname)
- (void) tcc_unlink(*prp->pr_sys, ocfname);
+ tcc_unlink(*prp->pr_sys, ocfname);
/*
** do the exec:
@@ -715,7 +715,7 @@ char *ocfname;
}
if (getremfile(prp, ocfname, tet_basename(tfname)) == 0)
ocf2jnl2(prp, tfname);
- (void) UNLINK(tfname);
+ UNLINK(tfname);
}
else
#endif /* !TET_LITE */ /* -END-LITE-CUT- */
@@ -753,7 +753,7 @@ char *ocfname;
jnl_captured(prp, buf);
}
- (void) fclose(fp);
+ fclose(fp);
}
@@ -784,7 +784,7 @@ char *fromfile, *tofile;
** directory on the local system
*/
if (tet_tcrxfile(*prp->pr_sys, fromfile, tofile) < 0) {
- (void) sprintf(msg, fmt, sizeof msg - sizeof fmt, tofile);
+ sprintf(msg, fmt, sizeof msg - sizeof fmt, tofile);
prperror(prp, *prp->pr_sys, tet_tcerrno, msg, fromfile);
return(-1);
}
diff --git a/src/tet3/tcc/utils.c b/src/tet3/tcc/utils.c
index 906b4f63..d4d4e973 100644
--- a/src/tet3/tcc/utils.c
+++ b/src/tet3/tcc/utils.c
@@ -157,11 +157,11 @@ void scenermsg(s1, s2, lineno, fname)
char *s1, *s2, *fname;
int lineno;
{
- (void) fprintf(stderr, "%s: %s", tet_progname, s1);
+ fprintf(stderr, "%s: %s", tet_progname, s1);
if (s2 && *s2)
- (void) fprintf(stderr, " %s", s2);
- (void) fprintf(stderr, " at line %d in file %s\n", lineno, fname);
- (void) fflush(stderr);
+ fprintf(stderr, " %s", s2);
+ fprintf(stderr, " at line %d in file %s\n", lineno, fname);
+ fflush(stderr);
}
/*
@@ -170,7 +170,7 @@ int lineno;
void scengiveup()
{
- (void) fprintf(stderr,
+ fprintf(stderr,
"%s: giving up after finding %d scenario error%s\n",
tet_progname, scenerrors, scenerrors == 1 ? "" : "s");
tcc_exit(1);
@@ -196,7 +196,7 @@ int dirlen;
len = 1;
}
- (void) sprintf(dir, "%.*s", TET_MIN(len, dirlen - 1), path);
+ sprintf(dir, "%.*s", TET_MIN(len, dirlen - 1), path);
}
/*
@@ -240,7 +240,7 @@ void fullpath(const char *dir, const char *file, char path[], int pathlen, int r
ASSERT(isabspathrem(dir));
else
ASSERT(isabspathloc(dir));
- (void) sprintf(p, "%.*s", pathlen - 2, dir);
+ sprintf(p, "%.*s", pathlen - 2, dir);
len = strlen(p);
p += len;
pathlen -= len;
@@ -255,7 +255,7 @@ void fullpath(const char *dir, const char *file, char path[], int pathlen, int r
}
- (void) sprintf(p, "%.*s", pathlen - 1, file);
+ sprintf(p, "%.*s", pathlen - 1, file);
if ((dir ? (int) strlen(dir) : 0) + (int) strlen(file) > pathlen - 2)
error(0, "path name is too long and has been truncated:",
diff --git a/src/tet3/tccd/config.c b/src/tet3/tccd/config.c
index 0e749059..f83a400b 100644
--- a/src/tet3/tccd/config.c
+++ b/src/tet3/tccd/config.c
@@ -265,7 +265,7 @@ register struct ptab *pp;
rc = ER_ERR;
}
- (void) fclose(fp);
+ fclose(fp);
cflags = (cflags & ~CF_SINPROGRESS) | CF_SDONE;
pp->ptm_rc = rc;
}
@@ -413,7 +413,7 @@ int mode;
if ((rc = op_c3(fname)) == ER_OK) {
if (tet_config[mode]) {
- (void) UNLINK(tet_config[mode]);
+ UNLINK(tet_config[mode]);
TRACE3(tet_Tbuf, 6, "free tet_config[%s] = %s",
tet_i2a(mode), tet_i2x(tet_config[mode]));
free(tet_config[mode]);
@@ -457,7 +457,7 @@ char *fname;
/* remove the file if any of the above failed */
if (rc != ER_OK)
- (void) UNLINK(fname);
+ UNLINK(fname);
return(rc);
}
@@ -797,7 +797,7 @@ register struct ptab *pp;
pp->ptm_rc = ER_ERR;
return;
}
- (void) sprintf(var, "%s=%s", envname, tet_config[mode]);
+ sprintf(var, "%s=%s", envname, tet_config[mode]);
if (tet_putenv(var) < 0) {
pp->ptm_rc = ER_ERR;
return;
@@ -818,6 +818,6 @@ void config_cleanup()
for (n = 0; n < sizeof tet_config / sizeof tet_config[0]; n++)
if (tet_config[n])
- (void) UNLINK(tet_config[n]);
+ UNLINK(tet_config[n]);
}
diff --git a/src/tet3/tccd/etab.c b/src/tet3/tccd/etab.c
index 0fd67b43..83f76a9f 100644
--- a/src/tet3/tccd/etab.c
+++ b/src/tet3/tccd/etab.c
@@ -147,7 +147,7 @@ struct ptab *pp;
for (ep = etab; ep; ep = ep->et_next)
if (ep->et_ptab == pp) {
if (ep->et_state == ES_RUNNING)
- (void) KILL(ep->et_pid, SIGHUP);
+ KILL(ep->et_pid, SIGHUP);
etrm(ep);
etfree(ep);
done = 0;
diff --git a/src/tet3/tccd/exec.c b/src/tet3/tccd/exec.c
index 294bd11e..73a34ac7 100644
--- a/src/tet3/tccd/exec.c
+++ b/src/tet3/tccd/exec.c
@@ -268,12 +268,12 @@ struct etab *ep;
void tcc_exec_signals()
{
- (void) signal(SIGHUP, SIG_DFL);
- (void) signal(SIGINT, SIG_DFL);
- (void) signal(SIGQUIT, SIG_DFL);
- (void) signal(SIGTSTP, SIG_DFL);
- (void) signal(SIGTTIN, SIG_DFL);
- (void) signal(SIGTTOU, SIG_DFL);
+ signal(SIGHUP, SIG_DFL);
+ signal(SIGINT, SIG_DFL);
+ signal(SIGQUIT, SIG_DFL);
+ signal(SIGTSTP, SIG_DFL);
+ signal(SIGTTIN, SIG_DFL);
+ signal(SIGTTOU, SIG_DFL);
}
@@ -529,8 +529,8 @@ register int timeout;
else
alarm_save = 2;
}
- (void) alarm(alarm_save);
- (void) signal(SIGALRM, (SIG_FUNC_T (*)()) sig_save);
+ alarm(alarm_save);
+ signal(SIGALRM, (SIG_FUNC_T (*)()) sig_save);
}
return(rc);
@@ -558,11 +558,11 @@ time_t start;
for (;;) {
status = 0;
if (timeout > 0)
- (void) alarm((unsigned) TET_MAX(tleft, 2));
+ alarm((unsigned) TET_MAX(tleft, 2));
rc = tet_dowait3(&status, timeout ? 0 : WNOHANG);
save_errno = errno;
if (timeout > 0)
- (void) alarm(0);
+ alarm(0);
TRACE4(tet_Ttccd, 4,
"wait3 returned pid = %s, status = %s, signal %s",
tet_i2a(rc), tet_i2a((status >> 8) & 0xff),
@@ -605,7 +605,7 @@ time_t start;
static SIG_FUNC_T catchalarm(sig)
int sig;
{
- (void) signal(SIGALRM, SIG_IGN);
+ signal(SIGALRM, SIG_IGN);
wait_timedout = 1;
longjmp(wait_env, 1);
}
diff --git a/src/tet3/tccd/log.c b/src/tet3/tccd/log.c
index 7fd6b472..2598b38e 100644
--- a/src/tet3/tccd/log.c
+++ b/src/tet3/tccd/log.c
@@ -96,7 +96,7 @@ void loginit()
fatal(errno, "can't open log file", Logfile);
/* allow anyone to read/write to the logfile */
- (void) CHMOD(Logfile, (mode_t)S_IRUSR|S_IWUSR|S_IRGRP|S_IWGRP|S_IROTH|S_IWOTH);
+ CHMOD(Logfile, (mode_t)S_IRUSR|S_IWUSR|S_IRGRP|S_IWGRP|S_IROTH|S_IWOTH);
/* attach stderr to the logfile */
errno = 0;
@@ -105,7 +105,7 @@ void loginit()
fatal(errno, "can't reopen stderr as", Logfile);
}
- (void) fclose(fp);
+ fclose(fp);
setbuf(lfp, buf);
@@ -124,11 +124,11 @@ char *s1, *s2;
fp = getlogfp();
- (void) fprintf(fp, "%s: %s", loghdr(), s1);
+ fprintf(fp, "%s: %s", loghdr(), s1);
if (s2 && *s2)
- (void) fprintf(fp, " %s", s2);
- (void) putc('\n', fp);
- (void) fflush(fp);
+ fprintf(fp, " %s", s2);
+ putc('\n', fp);
+ fflush(fp);
}
/*
@@ -155,7 +155,7 @@ static char *loghdr()
t = time((time_t *) 0);
tp = localtime(&t);
- (void) sprintf(header, "%.16s (%d) %d %s %d:%02d:%02d",
+ sprintf(header, "%.16s (%d) %d %s %d:%02d:%02d",
tet_progname, tet_mypid, tp->tm_mday, month[tp->tm_mon],
tp->tm_hour, tp->tm_min, tp->tm_sec);
diff --git a/src/tet3/tccd/log.c.orig b/src/tet3/tccd/log.c.orig
index dd640439..8a245290 100644
--- a/src/tet3/tccd/log.c.orig
+++ b/src/tet3/tccd/log.c.orig
@@ -89,7 +89,7 @@ void loginit()
fatal(errno, "can't open log file", Logfile);
/* allow anyone to read/write to the logfile */
- (void) CHMOD(Logfile, (mode_t)S_IRUSR|S_IWUSR|S_IRGRP|S_IWGRP|S_IROTH|S_IWOTH);
+ CHMOD(Logfile, (mode_t)S_IRUSR|S_IWUSR|S_IRGRP|S_IWGRP|S_IROTH|S_IWOTH);
/* attach stderr to the logfile */
errno = 0;
@@ -98,7 +98,7 @@ void loginit()
fatal(errno, "can't reopen stderr as", Logfile);
}
- (void) fclose(fp);
+ fclose(fp);
setbuf(lfp, buf);
@@ -117,11 +117,11 @@ char *s1, *s2;
fp = getlogfp();
- (void) fprintf(fp, "%s: %s", loghdr(), s1);
+ fprintf(fp, "%s: %s", loghdr(), s1);
if (s2 && *s2)
- (void) fprintf(fp, " %s", s2);
- (void) putc('\n', fp);
- (void) fflush(fp);
+ fprintf(fp, " %s", s2);
+ putc('\n', fp);
+ fflush(fp);
}
/*
@@ -150,7 +150,7 @@ static char *loghdr()
t = time((time_t *) 0);
tp = localtime(&t);
- (void) sprintf(header, "%.16s (%d) %d %s %d:%02d:%02d",
+ sprintf(header, "%.16s (%d) %d %s %d:%02d:%02d",
tet_progname, tet_mypid, tp->tm_mday, month[tp->tm_mon],
tp->tm_hour, tp->tm_min, tp->tm_sec);
diff --git a/src/tet3/tccd/stcc.c b/src/tet3/tccd/stcc.c
index a3b91f88..3a58c1dd 100644
--- a/src/tet3/tccd/stcc.c
+++ b/src/tet3/tccd/stcc.c
@@ -126,7 +126,7 @@ struct ptab *pp;
for (n = 0; n < OP_PUTENV_NLINE(mp); n++) {
p1 = tet_equindex(AV_ENVAR(mp, n));
ASSERT(p1);
- (void) sprintf(buf, "%.*s",
+ sprintf(buf, "%.*s",
TET_MIN((int) (p1 - AV_ENVAR(mp, n)), (int) sizeof buf - 1),
AV_ENVAR(mp, n));
if (!strcmp(buf, "TET_ROOT") && tetrootset(p1 + 1) < 0)
diff --git a/src/tet3/tccd/tccd.c b/src/tet3/tccd/tccd.c
index 35c4179c..df1d5ba4 100644
--- a/src/tet3/tccd/tccd.c
+++ b/src/tet3/tccd/tccd.c
@@ -129,9 +129,9 @@ int argc;
char **argv;
{
/* ignore certain signals */
- (void) signal(SIGHUP, SIG_IGN);
- (void) signal(SIGINT, SIG_IGN);
- (void) signal(SIGQUIT, SIG_IGN);
+ signal(SIGHUP, SIG_IGN);
+ signal(SIGINT, SIG_IGN);
+ signal(SIGQUIT, SIG_IGN);
/* initialise the global variables for the library code */
tet_init_globals("tccd", PT_STCC, -1, logerror, tet_genfatal);
@@ -141,12 +141,12 @@ char **argv;
tet_init_blockable_sigs();
/* open the error log file */
- (void) umask((mode_t) 022);
+ umask((mode_t) 022);
loginit();
/* catch SIGTERM */
if (signal(SIGTERM, SIG_IGN) != SIG_IGN)
- (void) signal(SIGTERM, terminate);
+ signal(SIGTERM, terminate);
/* call the generic server */
return(tet_si_main(argc, argv, 0));
@@ -184,7 +184,7 @@ char *firstarg, *nextarg;
mask = 0;
while (*p >= '0' && *p <= '7')
mask = (mask << 3) | (*p++ & 07);
- (void) umask((mode_t)(mask & 077));
+ umask((mode_t)(mask & 077));
break;
case 'l':
if (*(firstarg + 2))
@@ -266,7 +266,7 @@ void tet_ss_initdaemon()
/* fix up HOME environment variable if necessary */
if ((p = getenv(home)) == (char *) 0 || strcmp(p, pw->pw_dir)) {
- (void) sprintf(buf, "%s=%.*s", home,
+ sprintf(buf, "%s=%.*s", home,
(int) sizeof buf - (int) sizeof home - 2, pw->pw_dir);
if ((p = tet_strstore(buf)) == (char *) 0 || tet_putenv(p) < 0)
exit(1);
@@ -274,7 +274,7 @@ void tet_ss_initdaemon()
/* provide a default PATH variable if necessary */
if ((p = getenv(path)) == (char *) 0) {
- (void) sprintf(buf, "%s=%.*s", path,
+ sprintf(buf, "%s=%.*s", path,
(int) sizeof buf - (int) sizeof path - 2, defpath);
TRACE2(tet_Ttccd, 4, "no PATH env var, using default: \"%s\"",
buf);
@@ -296,11 +296,11 @@ void tet_ss_initdaemon()
/* attach stdin to /dev/null and stdout to stderr (which goes
to the log file */
- (void) CLOSE(0);
+ CLOSE(0);
errno = 0;
if (OPEN(null, O_RDONLY, 0) != 0)
fatal(errno, "can't open", null);
- (void) CLOSE(1);
+ CLOSE(1);
errno = 0;
if (FCNTL_F_DUPFD(FILENO(stderr), 1) != 1)
fatal(errno, "can't attach stdout to stderr", (char *) 0);
@@ -351,7 +351,7 @@ register struct ptab *pp;
/* emit a diagnostic message if this is unexpected */
if ((pp->pt_flags & PF_LOGGEDOFF) == 0) {
- (void) sprintf(msg, fmt, (pp->pt_flags & PF_SERVER) ? se : cl);
+ sprintf(msg, fmt, (pp->pt_flags & PF_SERVER) ? se : cl);
error(0, msg, tet_r2a(&pp->pt_rid));
}
@@ -640,7 +640,7 @@ struct ptab *pp;
void tet_ss_cleanup()
{
config_cleanup();
- (void) tet_xdlogoff();
+ tet_xdlogoff();
tet_ts_cleanup();
exit(0);
}
@@ -689,7 +689,7 @@ int sig;
int tetrootset(s)
char *s;
{
- (void) sprintf(tet_root, "%.*s", (int) sizeof tet_root - 1, s);
+ sprintf(tet_root, "%.*s", (int) sizeof tet_root - 1, s);
return(0);
}
diff --git a/src/tet3/tccd/tccd_in.c b/src/tet3/tccd/tccd_in.c
index 15c820ba..9604dd76 100644
--- a/src/tet3/tccd/tccd_in.c
+++ b/src/tet3/tccd/tccd_in.c
@@ -160,7 +160,7 @@ void ss_tsinitb4fork()
errno = 0;
if ((sd = fcntl(0, F_DUPFD, 3)) < 3)
fatal(errno, "can't dup stdin socket", (char *) 0);
- (void) close(0);
+ close(0);
/* allocate a ptab entry for the incoming request */
@@ -176,7 +176,7 @@ void ss_tsinitb4fork()
(char *) 0);
/* log the connection */
- (void) tet_ss_tsafteraccept(pp);
+ tet_ss_tsafteraccept(pp);
/* register the ptab entry */
tet_ss_newptab(pp);
@@ -207,7 +207,7 @@ void ss_tsinitb4fork()
errno = 0;
if ((tet_listen_sd = fcntl(sd, F_DUPFD, 3)) < 3)
fatal(errno, "can't dup listen socket", (char *) 0);
- (void) close(sd);
+ close(sd);
}
else
tet_listen_sd = sd;
@@ -222,7 +222,7 @@ void ss_tsinitb4fork()
tet_ts_listen(tet_listen_sd);
/* arrange to reap child daemon processes */
- (void) signal(SIGCHLD, waitchild);
+ signal(SIGCHLD, waitchild);
#endif /* INETD */
}
@@ -327,7 +327,7 @@ struct ptab *pp;
p = hp->h_name;
else
p = inet_ntoa(tp->tp_sin.sin_addr);
- (void) sprintf(rhostname, "%.*s", (int) sizeof rhostname - 1, p);
+ sprintf(rhostname, "%.*s", (int) sizeof rhostname - 1, p);
logent("connection received from", rhostname);
#ifdef INETD
@@ -344,9 +344,9 @@ struct ptab *pp;
else if (!pid) {
/* in child */
tet_mypid = getpid();
- (void) close(tet_listen_sd);
+ close(tet_listen_sd);
tet_listen_sd = INVALID_SOCKET;
- (void) signal(SIGCHLD, SIG_DFL);
+ signal(SIGCHLD, SIG_DFL);
}
else {
/* in parent - return -1 to close the socket and
@@ -376,7 +376,7 @@ int ss_tslogon()
FILE *fp;
ASSERT(tet_root[0]);
- (void) sprintf(fname, "%.*s/%s",
+ sprintf(fname, "%.*s/%s",
(int) sizeof fname - (int) sizeof equiv - 1,
tet_root, equiv);
@@ -401,7 +401,7 @@ int ss_tslogon()
if (rc != ER_OK)
error(0, "refused login request from", rhostname);
- (void) fclose(fp);
+ fclose(fp);
return(rc);
}
@@ -424,7 +424,7 @@ int sig;
register int pid;
#endif
- (void) signal(SIGCHLD, SIG_DFL);
+ signal(SIGCHLD, SIG_DFL);
#ifdef NOTRACE
while (tet_dowait3(&status, WNOHANG) > 0)
@@ -437,7 +437,7 @@ int sig;
tet_i2a(status & 0xff));
#endif
- (void) signal(SIGCHLD, waitchild);
+ signal(SIGCHLD, waitchild);
}
#endif
diff --git a/src/tet3/tccd/tccd_xt.c b/src/tet3/tccd/tccd_xt.c
index 6d2775fa..2be28268 100644
--- a/src/tet3/tccd/tccd_xt.c
+++ b/src/tet3/tccd/tccd_xt.c
@@ -144,9 +144,9 @@ char *firstarg, *nextarg;
/* all ok - copy static data to safer place */
np.maxlen = p->maxlen;
np.len = p->len;
- (void) memcpy(np.buf, p->buf, p->len);
+ memcpy(np.buf, p->buf, p->len);
if (np.maxlen > np.len)
- (void) memset(np.buf + np.len, '\0',
+ memset(np.buf + np.len, '\0',
np.maxlen - np.len);
Tccdaddr = &np;
@@ -203,7 +203,7 @@ void ss_tsinitb4fork()
errno = 0;
if ((tet_listen_fd = fcntl(fd, F_DUPFD, 3)) < 3)
fatal(errno, "can't dup listen fd", (char *) 0);
- (void) close(fd);
+ close(fd);
}
else
tet_listen_fd = fd;
@@ -236,7 +236,7 @@ void ss_tsinitb4fork()
tet_ts_listen(tet_listen_fd);
/* arrange to reap child daemon processes */
- (void) signal(SIGCHLD, waitchild);
+ signal(SIGCHLD, waitchild);
}
/*
@@ -321,9 +321,9 @@ struct ptab *pp;
else if (!pid) {
/* in child */
tet_mypid = getpid();
- (void) close(tet_listen_fd);
+ close(tet_listen_fd);
tet_listen_fd = -1;
- (void) signal(SIGCHLD, SIG_DFL);
+ signal(SIGCHLD, SIG_DFL);
}
else {
/* in parent - return -1 to close the connection and
@@ -362,7 +362,7 @@ int sig;
register int pid;
#endif
- (void) signal(SIGCHLD, SIG_DFL);
+ signal(SIGCHLD, SIG_DFL);
#ifdef NOTRACE
while (tet_dowait3(&status, WNOHANG) > 0)
@@ -375,7 +375,7 @@ int sig;
tet_i2a(status & 0xff));
#endif
- (void) signal(SIGCHLD, waitchild);
+ signal(SIGCHLD, waitchild);
}
@@ -454,7 +454,7 @@ register struct ptab *pp;
}
TRACE2(tet_Tbuf, 6, "allocate TCP tsinfo buffer = %s",
tet_i2x(ap->buf));
- (void) memset((char *) ap->buf, '\0',
+ memset((char *) ap->buf, '\0',
sizeof (struct sockaddr_in));
((struct sockaddr_in *)ap->buf)->sin_family
@@ -488,7 +488,7 @@ register struct ptab *pp;
}
TRACE2(tet_Tbuf, 6, "allocate OSICO tsinfo buffer = %s",
tet_i2x(ap->buf));
- (void) memcpy(ap->buf, mp->ts.osico.ts_nsap, ap->len);
+ memcpy(ap->buf, mp->ts.osico.ts_nsap, ap->len);
TRACE4(tet_Ttccd, 2,
"received tsinfo for %s: len = %s, addr = %s",
diff --git a/src/tet3/tccd/tccdstart.c b/src/tet3/tccd/tccdstart.c
index 75bd6421..b6800cb9 100644
--- a/src/tet3/tccd/tccdstart.c
+++ b/src/tet3/tccd/tccdstart.c
@@ -63,7 +63,7 @@ int main()
char **tp;
for (tp = text; tp < &text[sizeof text / sizeof text[0]]; tp++)
- (void) fprintf(stderr, "%s\n", *tp);
+ fprintf(stderr, "%s\n", *tp);
return(1);
}
diff --git a/src/tet3/tccd/tsfile.c b/src/tet3/tccd/tsfile.c
index a480bb05..306fd850 100644
--- a/src/tet3/tccd/tsfile.c
+++ b/src/tet3/tccd/tsfile.c
@@ -113,7 +113,7 @@ register struct ptab *pp;
AV_DIR(mp), AV_SUFFIX(mp));
/* construct the specified directory path name */
- (void) sprintf(dir, "%.*s", (int) sizeof dir - 1, AV_DIR(mp));
+ sprintf(dir, "%.*s", (int) sizeof dir - 1, AV_DIR(mp));
/* open the directory */
if ((dirp = OPENDIR(dir)) == (DIR *) 0) {
@@ -129,7 +129,7 @@ register struct ptab *pp;
while ((dp = READDIR(dirp)) != (struct dirent *) 0)
if ((n = atoi(dp->d_name)) > nmax)
nmax = n;
- (void) CLOSEDIR(dirp);
+ CLOSEDIR(dirp);
/* make the directory first without the suffix (try a few times) */
for (n = 0; n < 5; n++) {
@@ -141,7 +141,7 @@ register struct ptab *pp;
pp->ptm_len = 0;
return;
}
- (void) sprintf(lokdir, "%s/%04d", dir, nmax);
+ sprintf(lokdir, "%s/%04d", dir, nmax);
TRACE2(tet_Ttccd, 6, "mksdir: try lokdir = \"%s\"", lokdir);
if (tet_mkdir(lokdir, DIRMODE) == 0 || errno != EEXIST)
break;
@@ -156,11 +156,11 @@ register struct ptab *pp;
/* then make the directory with the suffix
and remove the other one */
- (void) sprintf(savdir, "%s%.3s", lokdir, AV_SUFFIX(mp));
+ sprintf(savdir, "%s%.3s", lokdir, AV_SUFFIX(mp));
TRACE2(tet_Ttccd, 6, "mksdir: make savdir = \"%s\"", savdir);
if ((rc = tet_mkdir(savdir, DIRMODE)) < 0)
error(errno, errmsg, savdir);
- (void) tet_rmdir(lokdir);
+ tet_rmdir(lokdir);
if (rc < 0) {
pp->ptm_rc = ER_ERR;
pp->ptm_mtype = MT_NODATA;
@@ -174,7 +174,7 @@ register struct ptab *pp;
free(sfdir);
}
if ((sfdir = tet_strstore(savdir)) == (char *) 0) {
- (void) tet_rmdir(savdir);
+ tet_rmdir(savdir);
pp->ptm_rc = ER_ERR;
pp->ptm_mtype = MT_NODATA;
pp->ptm_len = 0;
@@ -253,7 +253,7 @@ struct ptab *pp;
todir = sfdir;
else {
len = (int) sizeof dir - (int) strlen(sfdir) - 2;
- (void) sprintf(dir, "%.*s/%.*s",
+ sprintf(dir, "%.*s/%.*s",
(int) sizeof dir - 2, sfdir,
TET_MAX(len, 0), AV_SUBDIR(mp));
todir = dir;
diff --git a/src/tet3/tcclib/lockfile.c b/src/tet3/tcclib/lockfile.c
index d5d34c01..dc51926e 100644
--- a/src/tet3/tcclib/lockfile.c
+++ b/src/tet3/tcclib/lockfile.c
@@ -88,7 +88,7 @@ int timeout;
errno = 0;
return(ER_TIMEDOUT);
}
- (void) SLEEP(2);
+ SLEEP(2);
}
/* handle unexpected errors */
@@ -100,7 +100,7 @@ int timeout;
}
/* all ok so close the file and return success */
- (void) CLOSE(fd);
+ CLOSE(fd);
return(ER_OK);
}
diff --git a/src/tet3/tcclib/lsdir.c b/src/tet3/tcclib/lsdir.c
index 86e7fcfe..75d114da 100644
--- a/src/tet3/tcclib/lsdir.c
+++ b/src/tet3/tcclib/lsdir.c
@@ -109,7 +109,7 @@ char *dir;
*++fip = (char *) 0;
nfiles++;
}
- (void) CLOSEDIR(dirp);
+ CLOSEDIR(dirp);
return(files);
}
diff --git a/src/tet3/tcclib/lsdir.c.orig b/src/tet3/tcclib/lsdir.c.orig
index 39a0e8aa..353eb479 100644
--- a/src/tet3/tcclib/lsdir.c.orig
+++ b/src/tet3/tcclib/lsdir.c.orig
@@ -94,7 +94,7 @@ char *dir;
*++fip = (char *) 0;
nfiles++;
}
- (void) CLOSEDIR(dirp);
+ CLOSEDIR(dirp);
return(files);
}
diff --git a/src/tet3/tcclib/mktmpdir.c b/src/tet3/tcclib/mktmpdir.c
index a9858d05..30bb6992 100644
--- a/src/tet3/tcclib/mktmpdir.c
+++ b/src/tet3/tcclib/mktmpdir.c
@@ -90,7 +90,7 @@ char *dir, **subdp;
ASSERT(dir && *dir);
/* format the pid string */
- (void) sprintf(pidstr, "%05u", tet_mypid);
+ sprintf(pidstr, "%05u", tet_mypid);
/* get a buffer for the tmp dir name */
needlen = strlen(dir) + strlen(pidstr) + 4;
@@ -100,7 +100,7 @@ char *dir, **subdp;
/* try to make the directory a few times */
for (salt1 = 'a'; salt1 <= 'z'; salt1++)
for (salt2 = 'a'; salt2 <= 'z'; salt2++) {
- (void) sprintf(subdir, "%s/%s%c%c",
+ sprintf(subdir, "%s/%s%c%c",
dir, pidstr, salt1, salt2);
if ((rc = tcf_mktd2(subdir)) < 0)
return(rc);
diff --git a/src/tet3/tcclib/procdir.c b/src/tet3/tcclib/procdir.c
index 17a2628e..8b052028 100644
--- a/src/tet3/tcclib/procdir.c
+++ b/src/tet3/tcclib/procdir.c
@@ -142,10 +142,10 @@ int flag;
/* construct the path name to this file */
if (!*fromdir || (*fromdir == '.' && !*(fromdir + 1)))
- (void) sprintf(path, "%.*s", (int) sizeof path - 1, fromfile);
+ sprintf(path, "%.*s", (int) sizeof path - 1, fromfile);
else {
len = (int) sizeof path - (int) strlen(fromdir) - 2;
- (void) sprintf(path, "%.*s/%.*s",
+ sprintf(path, "%.*s/%.*s",
(int) sizeof path - 2, fromdir,
TET_MAX(len, 0), fromfile);
}
@@ -227,7 +227,7 @@ int flag;
rc = ER_OK;
len = (int) sizeof path - (int) strlen(fromdir) - 2;
for (fip = fromfiles; *fip; fip++) {
- (void) sprintf(path, "%.*s/%.*s",
+ sprintf(path, "%.*s/%.*s",
(int) sizeof path - 2, fromdir,
TET_MAX(len, 0), *fip);
if (STAT(path, &stbuf) < 0) {
@@ -274,11 +274,11 @@ int flag;
return(ER_ERR);
p = tofile;
if (todir) {
- (void) sprintf(tofile, "%.*s/",
+ sprintf(tofile, "%.*s/",
(int) sizeof tofile - 2, todir);
p += strlen(tofile);
}
- (void) sprintf(p, "%.*s",
+ sprintf(p, "%.*s",
(int) sizeof tofile - (int) (p - tofile) - 1, fromfile);
TRACE3(Ttcclib, 8, "call xd_rxfile: from = \"%s\", to = \"%s\"",
fromfile, tofile);
@@ -311,7 +311,7 @@ char *fromfile, *todir;
/* construct the destination file name */
len = (int) sizeof tofile - (int) strlen(todir) - 2;
- (void) sprintf(tofile, "%.*s/%.*s",
+ sprintf(tofile, "%.*s/%.*s",
(int) sizeof tofile - 2, todir, TET_MAX(len, 0), fromfile);
TRACE3(Ttcclib, 8, "tscopy(): fromfile = \"%s\", tofile = \"%s\"",
@@ -340,7 +340,7 @@ char *fromfile, *todir;
}
else {
rc = tsc2(ifd, fromfile, tofile);
- (void) CLOSE(ifd);
+ CLOSE(ifd);
}
TRACE2(Ttcclib, 9, "tscopy() return %s", tet_ptrepcode(rc));
@@ -389,7 +389,7 @@ char *fromfile, *tofile;
else if (CHMOD(tofile, (mode_t) (stbuf.st_mode & MODEMASK)) < 0)
error(errno, "warning: can't chmod", tofile);
- (void) CLOSE(ofd);
+ CLOSE(ofd);
return(rc);
}
diff --git a/src/tet3/tcclib/rmrf.c b/src/tet3/tcclib/rmrf.c
index 8ea627d8..03b76b7d 100644
--- a/src/tet3/tcclib/rmrf.c
+++ b/src/tet3/tcclib/rmrf.c
@@ -98,12 +98,12 @@ char *path;
** otherwise, this is a file so just unlink it
*/
if (S_ISDIR(stbuf.st_mode)) {
- (void) sprintf(file, "%.*s/", (int) sizeof file - 2, path);
+ sprintf(file, "%.*s/", (int) sizeof file - 2, path);
p = file + strlen(file);
if ((files = tcf_lsdir(path)) == (char **) 0)
return(-1);
for (fip = files; *fip; fip++) {
- (void) sprintf(p, "%.*s",
+ sprintf(p, "%.*s",
(int) sizeof file - (int) (p - file) - 1, *fip);
if (tcf_rmrf(file) < 0)
rc = -1;
diff --git a/src/tet3/tcclib/sharlock.c b/src/tet3/tcclib/sharlock.c
index 24b067e6..88002a06 100644
--- a/src/tet3/tcclib/sharlock.c
+++ b/src/tet3/tcclib/sharlock.c
@@ -96,7 +96,7 @@ int timeout;
ASSERT(dir && *dir);
/* format the pid string */
- (void) sprintf(pidstr, "%05lu", pid);
+ sprintf(pidstr, "%05lu", pid);
/* allocate storage for the lock file name */
if (BUFCHK(&fname, &fnamelen, (int) (strlen(dir) + strlen(pidstr)) + 4) < 0)
@@ -119,7 +119,7 @@ int timeout;
}
for (salt1 = 'a'; salt1 <= 'z'; salt1++) {
for (salt2 = 'a'; salt2 <= 'z'; salt2++) {
- (void) sprintf(fname, "%s/%s%c%c",
+ sprintf(fname, "%s/%s%c%c",
dir, pidstr, salt1, salt2);
if ((fd = OPEN(fname, O_RDONLY | O_CREAT | O_EXCL, FILEMODE)) >= 0 || errno != EEXIST)
break;
@@ -149,11 +149,11 @@ int timeout;
}
if (timeout > 0 && time((time_t *) 0) > start + timeout)
return(ER_TIMEDOUT);
- (void) SLEEP(2);
+ SLEEP(2);
}
/* all ok so close the file and return success */
- (void) CLOSE(fd);
+ CLOSE(fd);
*lnp = fname;
return(ER_OK);
}
diff --git a/src/tet3/tcclib/tcfexec.c b/src/tet3/tcclib/tcfexec.c
index 5e847614..4b4e4049 100644
--- a/src/tet3/tcclib/tcfexec.c
+++ b/src/tet3/tcclib/tcfexec.c
@@ -137,7 +137,7 @@ int flag, *pidp;
return(ER_ERR);
}
else if (tet_fioclex(fd) < 0) {
- (void) close(fd);
+ close(fd);
return(ER_ERR);
}
}
@@ -154,14 +154,14 @@ int flag, *pidp;
if ((pid = tet_dofork()) == 0) {
/* in child */
if (fd >= 0) {
- (void) fflush(stdout);
- (void) close(1);
+ fflush(stdout);
+ close(1);
if (fcntl(fd, F_DUPFD, 1) != 1) {
error(errno, "can't dup stdout", (char *) 0);
_exit(~0);
}
- (void) fflush(stderr);
- (void) close(2);
+ fflush(stderr);
+ close(2);
if (fcntl(fd, F_DUPFD, 2) != 2) {
error(errno, "can't dup stderr", (char *) 0);
_exit(~0 - 1);
@@ -169,10 +169,10 @@ int flag, *pidp;
}
for (n = tet_getdtablesize() - 1; n > 2; n--) {
if (n != fd)
- (void) close(n);
+ close(n);
}
tcc_exec_signals();
- (void) execvp(path, argv);
+ execvp(path, argv);
error(errno, "can't exec", path);
switch (flag) {
case TCF_EXEC_TEST:
@@ -194,7 +194,7 @@ int flag, *pidp;
/* close outfile in the parent if one was specified */
if (fd >= 0)
- (void) close(fd);
+ close(fd);
TRACE3(Ttcclib, 4, "after exec: pid = %s, return %s",
@@ -242,7 +242,7 @@ char *file;
if (p2 > fname && p2 < &fname[sizeof fname - 2])
*p2++ = '/';
*p2 = '\0';
- (void) sprintf(p2, "%.*s",
+ sprintf(p2, "%.*s",
(int) (&fname[sizeof fname - 1] - p2), file);
TRACE2(Ttcclib, 6, "checkexec: try \"%s\"", fname);
if (tet_eaccess(fname, 01) == 0)
@@ -282,7 +282,7 @@ long snid;
tet_ptrepcode(tet_sderrno));
SLEEP(2);
- (void) tet_sdlogoff(0);
+ tet_sdlogoff(0);
#endif /* !TET_LITE */ /* -END-LITE-CUT- */
}
diff --git a/src/tet3/tcm/child.c b/src/tet3/tcm/child.c
index 379159d7..e4849958 100644
--- a/src/tet3/tcm/child.c
+++ b/src/tet3/tcm/child.c
@@ -117,7 +117,7 @@ char **argv;
TET_THR_KEYCREATE(&tet_sequence_key) != 0)
{
/* can't use tet_error() yet */
- (void) fprintf(stderr,
+ fprintf(stderr,
"%s: TET_THR_KEYCREATE() failed in TCM startup",
tet_progname);
exit(EXIT_FAILURE);
diff --git a/src/tet3/tcm/ckversion.c b/src/tet3/tcm/ckversion.c
index 86b98546..e6f3bdae 100644
--- a/src/tet3/tcm/ckversion.c
+++ b/src/tet3/tcm/ckversion.c
@@ -97,7 +97,7 @@ static void rptversion PROTOLIST((char *, char **));
void tet_check_apilib_version()
{
if (mstrcmp(tet_apilib_version, expected_apilib_version)) {
- (void) fprintf(stderr,
+ fprintf(stderr,
"%s: using wrong version of the API library\n",
tet_progname);
rptversion("expected", expected_apilib_version);
@@ -137,10 +137,10 @@ char **sp1, **sp2;
static void rptversion(s, sp)
char *s, **sp;
{
- (void) fprintf(stderr, "%s: %s version:", tet_progname, s);
+ fprintf(stderr, "%s: %s version:", tet_progname, s);
while (*sp)
- (void) fprintf(stderr, " %s", *sp++);
- (void) putc('\n', stderr);
- (void) fflush(stderr);
+ fprintf(stderr, " %s", *sp++);
+ putc('\n', stderr);
+ fflush(stderr);
}
diff --git a/src/tet3/tcm/dtcm.c b/src/tet3/tcm/dtcm.c
index 4e84ff63..331886d7 100644
--- a/src/tet3/tcm/dtcm.c
+++ b/src/tet3/tcm/dtcm.c
@@ -262,7 +262,7 @@ char **argv;
TET_THR_KEYCREATE(&tet_sequence_key) != 0)
{
/* can't use tet_error() yet */
- (void) fprintf(stderr,
+ fprintf(stderr,
"%s: TET_THR_KEYCREATE() failed in TCM startup",
tet_pname);
exit(EXIT_FAILURE);
@@ -449,13 +449,13 @@ int icnum, tpnum, testnum;
if (sigsetjmp(skipjmp, 1) != 0)
{
/* we've caught an unexpected signal! */
- (void) sprintf(buf, "unexpected signal %d (%s) received",
+ sprintf(buf, "unexpected signal %d (%s) received",
signum, tet_signame(signum));
tet_infoline(buf);
tet_result(TET_UNRESOLVED);
if (tet_child > 0)
{
- (void) tet_killw(tet_child, KILLWAIT);
+ tet_killw(tet_child, KILLWAIT);
tet_child = 0;
}
# ifdef TET_THREADS
@@ -523,7 +523,7 @@ int icnum, tpnum, testnum;
TRACE3(tet_Ttcm, 1,
"about to call tet_invoketp(%s, %s)",
tet_i2a(icnum), tet_i2a(tpnum));
- (void) tet_invoketp(icnum, tpnum);
+ tet_invoketp(icnum, tpnum);
#ifdef TET_THREADS
tet_cln_threads(0);
tet_mtx_destroy();
@@ -560,19 +560,19 @@ int sig;
# ifdef TET_THREADS
if (!TET_THR_EQUAL(TET_THR_SELF(), tet_start_tid))
{
- (void) TET_THR_KILL(tet_start_tid, sig);
+ TET_THR_KILL(tet_start_tid, sig);
TET_THR_EXIT((void *)0);
}
# endif /* TET_THREADS */
- (void) sprintf(mbuf,
+ sprintf(mbuf,
"Abandoning testset: caught unexpected signal %d (%s)",
sig, tet_signame(sig));
tet_error(0, mbuf);
# ifdef TET_LITE /* -LITE-CUT-LINE- */
if (tet_tmpresfile != NULL)
- (void) UNLINK(tet_tmpresfile);
+ UNLINK(tet_tmpresfile);
# endif /* -LITE-CUT-LINE- */
/* log off all the servers and exit */
@@ -589,14 +589,14 @@ sigterm()
/* terminate [per-thread] child, if any */
if (tet_child > 0)
{
- (void) tet_killw(tet_child, KILLWAIT);
+ tet_killw(tet_child, KILLWAIT);
tet_child = 0;
}
# ifdef TET_THREADS
if (!TET_THR_EQUAL(TET_THR_SELF(), tet_start_tid))
{
- (void) TET_THR_KILL(tet_start_tid, SIGTERM);
+ TET_THR_KILL(tet_start_tid, SIGTERM);
TET_THR_EXIT((void *)0);
}
@@ -608,7 +608,7 @@ sigterm()
# ifdef TET_LITE /* -LITE-CUT-LINE- */
if (tet_tmpresfile != NULL)
- (void) UNLINK(tet_tmpresfile);
+ UNLINK(tet_tmpresfile);
# endif /* TET_LITE */ /* -LITE-CUT-LINE- */
/* call user-supplied cleanup function */
@@ -648,7 +648,7 @@ int sig;
# ifdef TET_THREADS
if (!TET_THR_EQUAL(TET_THR_SELF(), tet_start_tid))
{
- (void) TET_THR_KILL(tet_start_tid, sig);
+ TET_THR_KILL(tet_start_tid, sig);
TET_THR_EXIT((void *)0);
}
# endif /* TET_THREADS */
@@ -671,7 +671,7 @@ sigset_t *set;
char *list, *sname;
int snum;
- (void) sigemptyset(set);
+ sigemptyset(set);
list = tet_getvar(var);
if (list == NULL)
@@ -685,14 +685,14 @@ sigset_t *set;
/* Check it's not a standard signal */
if (strncmp(tet_signame(snum), "SIG", (size_t)3) == 0)
{
- (void) sprintf(buf,
+ sprintf(buf,
"warning: illegal entry \"%s\" in %s ignored",
sname, var);
tet_error(0, buf);
}
else if (sigaddset(set, snum) == -1)
{
- (void) sprintf(buf,
+ sprintf(buf,
"warning: sigaddset() failed on entry \"%s\" in %s",
sname, var);
tet_error(0, buf);
@@ -725,7 +725,7 @@ void (*func)();
init_done = 1;
}
- (void) sigemptyset(&tet_blockable_sigs);
+ sigemptyset(&tet_blockable_sigs);
/* NSIG is not provided by POSIX.1: it must be defined via
an extra feature-test macro, or on the compiler command line */
@@ -740,13 +740,13 @@ void (*func)();
else
sig.sa_handler = func;
sig.sa_flags = 0;
- (void) sigemptyset(&sig.sa_mask);
+ sigemptyset(&sig.sa_mask);
if (sigaction(i, &sig, (struct sigaction *)NULL) == 0 &&
# ifdef SIGBUS
i != SIGBUS &&
# endif
i != SIGSEGV && i != SIGILL && i != SIGFPE)
- (void) sigaddset(&tet_blockable_sigs, i);
+ sigaddset(&tet_blockable_sigs, i);
}
}
@@ -823,7 +823,7 @@ char *functype;
case SS_SYNCYES:
break;
default:
- (void) sprintf(errmsg,
+ sprintf(errmsg,
"%s function Auto Sync error, sysid = %d, state = %s",
functype, sp->sy_sysid,
tet_systate(sp->sy_state));
@@ -879,12 +879,12 @@ int nicspec;
*/
err = 0;
if (!tet_isdefic(icmin)) {
- (void) sprintf(msg, fmt, "min", icmin, icmin);
+ sprintf(msg, fmt, "min", icmin, icmin);
tet_error(0, msg);
err = 1;
}
if (!tet_isdefic(icmax)) {
- (void) sprintf(msg, fmt, "max", icmax, icmax);
+ sprintf(msg, fmt, "max", icmax, icmax);
tet_error(0, msg);
icmax = 1;
err = 1;
@@ -934,7 +934,7 @@ int icmin, icmax;
for (p = icspec; *p; p++)
if (*p == ',')
break;
- (void) sprintf(buf, "%.*s",
+ sprintf(buf, "%.*s",
TET_MIN((int) (p - icspec), (int) sizeof buf - 1),
icspec);
build_icl3(buf, icmin, icmax);
@@ -1008,7 +1008,7 @@ int icmin, icmax;
** print a diagnostic if the specified start IC does not exist
*/
if (!tet_isdefic(icstart)) {
- (void) sprintf(msg, fmt, icstart);
+ sprintf(msg, fmt, icstart);
tet_error(0, msg);
while (++icstart <= icend)
if (tet_isdefic(icstart))
@@ -1032,7 +1032,7 @@ int icmin, icmax;
** print a diagnostic if the specified end IC does not exist
*/
if (icstart != icend && !tet_isdefic(icend)) {
- (void) sprintf(msg, fmt, icend);
+ sprintf(msg, fmt, icend);
tet_error(0, msg);
while (--icend > icstart)
if (tet_isdefic(icend))
diff --git a/src/tet3/tcm/ictp.c b/src/tet3/tcm/ictp.c
index f06b494c..57618510 100644
--- a/src/tet3/tcm/ictp.c
+++ b/src/tet3/tcm/ictp.c
@@ -212,7 +212,7 @@ int icno, tpcount;
{
char buf[128];
- (void) sprintf(buf, "%d %d %s", icno, tpcount, curtime());
+ sprintf(buf, "%d %d %s", icno, tpcount, curtime());
lite_output(TET_JNL_IC_START, buf, "IC Start");
return(0);
}
@@ -244,7 +244,7 @@ int icno, tpcount;
ASSERT(tet_synreq);
if (tet_tcm_async(MK_ASPNO(icno, 0, S_ICSTART), SV_YES, SV_SYNC_TIMEOUT,
tet_synreq, &nsys) < 0) {
- (void) sprintf(errmsg,
+ sprintf(errmsg,
"Auto Sync failed at start of IC %d", icno);
tet_error(tet_sderrno, errmsg);
tet_exit(EXIT_FAILURE);
@@ -267,7 +267,7 @@ int icno, tpcount;
break;
/* else fall through */
default:
- (void) sprintf(errmsg,
+ sprintf(errmsg,
"Auto sync error at start of IC %d, sysid = %d, state = %s",
icno, sp->sy_sysid, tet_systate(sp->sy_state));
tet_error(tet_sderrno, errmsg);
@@ -309,7 +309,7 @@ int icno, tpcount;
{
char buf[128];
- (void) sprintf(buf, "%d %d %s", icno, tpcount, curtime());
+ sprintf(buf, "%d %d %s", icno, tpcount, curtime());
lite_output(TET_JNL_IC_END, buf, "IC End");
}
@@ -358,17 +358,17 @@ int icno, tpno, testnum;
{
char buf[128];
- (void) sprintf(buf, "%d %s", testnum, curtime());
+ sprintf(buf, "%d %s", testnum, curtime());
lite_output(TET_JNL_TP_START, buf, "TP Start");
/* create temporary result file */
- (void) remove(tet_tmpresfile);
+ remove(tet_tmpresfile);
if ((tet_tmpresfp = fopen(tet_tmpresfile, "a+b")) == (FILE *) 0)
fatal(errno, "cannot create temporary result file:",
tet_tmpresfile);
/* override umask (must be writable by set-uid children) */
- (void) CHMOD(tet_tmpresfile, MODE666);
+ CHMOD(tet_tmpresfile, MODE666);
/*
** put pathname in environment to be picked up by tet_result() in
@@ -406,7 +406,7 @@ int icno, tpno, testnum;
ASSERT(tet_synreq);
if (tet_tcm_async(MK_ASPNO(icno, tpno, S_TPSTART), vote,
SV_SYNC_TIMEOUT, tet_synreq, &nsys) < 0) {
- (void) sprintf(errmsg,
+ sprintf(errmsg,
"Auto Sync failed at start of TP %d", testnum);
tet_error(tet_sderrno, errmsg);
tet_exit(EXIT_FAILURE);
@@ -428,7 +428,7 @@ int icno, tpno, testnum;
tet_XSync_del = 1;
break;
default:
- (void) sprintf(errmsg,
+ sprintf(errmsg,
"Auto Sync error at start of TP %d, sysid = %d, state = %s",
testnum, sp->sy_sysid,
tet_systate(sp->sy_state));
@@ -518,9 +518,9 @@ int icno, tpno, testnum;
have_result = 0;
}
- (void) fclose(tet_tmpresfp);
- (void) UNLINK(tet_tmpresfile);
- (void) tet_putenv("TET_TMPRESFILE=");
+ fclose(tet_tmpresfp);
+ UNLINK(tet_tmpresfile);
+ tet_putenv("TET_TMPRESFILE=");
if (!have_result)
{
@@ -542,7 +542,7 @@ int icno, tpno, testnum;
}
}
- (void) sprintf(buf, "%d %d %s", testnum, result, curtime());
+ sprintf(buf, "%d %d %s", testnum, result, curtime());
lite_output(TET_JNL_TP_RESULT, buf, res);
/*
@@ -558,7 +558,7 @@ int icno, tpno, testnum;
tet_mtx_destroy();
tet_mtx_init();
# endif
- (void) sprintf(buf, "ABORT on result code %d \"%s\"",
+ sprintf(buf, "ABORT on result code %d \"%s\"",
result, res);
lite_output(TET_JNL_TCM_INFO, "", buf);
return(-1);
@@ -588,7 +588,7 @@ int icno, tpno, testnum;
ASSERT(tet_synreq);
if (tet_tcm_async(MK_ASPNO(icno, tpno, S_TPEND), SV_YES,
SV_SYNC_TIMEOUT * 10, tet_synreq, &nsys) < 0) {
- (void) sprintf(errmsg,
+ sprintf(errmsg,
"Auto Sync failed at end of TP %d", testnum);
tet_error(tet_sderrno, errmsg);
tet_exit(EXIT_FAILURE);
@@ -612,7 +612,7 @@ int icno, tpno, testnum;
case SS_SYNCYES:
break;
default:
- (void) sprintf(errmsg,
+ sprintf(errmsg,
"Auto Sync error at end of TP %d, sysid = %d, state = %s",
testnum, sp->sy_sysid,
tet_systate(sp->sy_state));
@@ -641,7 +641,7 @@ static int mtcm_tpend2()
register struct synreq *sp;
/* signal TP end to XRESD */
- (void) tet_xdtpend(tet_xrid);
+ tet_xdtpend(tet_xrid);
switch (tet_xderrno) {
case ER_OK:
return(0);
@@ -689,7 +689,7 @@ static int mtcm_tpend2()
case SS_SYNCNO:
break;
default:
- (void) sprintf(errmsg,
+ sprintf(errmsg,
"Abort Auto Sync error, sysid = %d, state = %s",
sp->sy_sysid,
tet_systate(sp->sy_state));
@@ -720,7 +720,7 @@ int no_ics;
#ifdef TET_LITE /* -LITE-CUT-LINE- */
- (void) sprintf(buf, "%s %d", versn, no_ics);
+ sprintf(buf, "%s %d", versn, no_ics);
lite_output(TET_JNL_TCM_START, buf, "TCM Start");
#else /* -START-LITE-CUT- */
@@ -728,7 +728,7 @@ int no_ics;
if (!ismaster())
return;
- (void) sprintf(buf, "%d|%ld %s %d|TCM Start",
+ sprintf(buf, "%d|%ld %s %d|TCM Start",
TET_JNL_TCM_START, tet_activity, versn, no_ics);
if (tet_xdxres(tet_xrid, buf) < 0) {
@@ -835,13 +835,13 @@ char *progname;
/* create the execution results file and open in append mode */
- (void) remove(resfile);
+ remove(resfile);
tet_resfp = fopen(resfile, "a");
if (tet_resfp == NULL)
fatal(errno, "cannot create results file:", resfile);
/* override umask (must be writable by set-uid children) */
- (void) CHMOD(resfile, MODE666);
+ CHMOD(resfile, MODE666);
tet_combined_ok = 1;
}
@@ -863,7 +863,7 @@ char *data;
if (data == NULL)
data = "";
- (void) sprintf(header, fmt, mtype, tet_activity,
+ sprintf(header, fmt, mtype, tet_activity,
fields[0] == '\0' ? "" : " ", fields);
tet_msgform(header, data, outbuf);
obp = outbuf;
@@ -880,9 +880,9 @@ static char *curtime()
struct tm *tp;
static char s[10];
- (void) time(&t);
+ time(&t);
tp = localtime(&t);
- (void) sprintf(s, "%02d:%02d:%02d", tp->tm_hour,
+ sprintf(s, "%02d:%02d:%02d", tp->tm_hour,
tp->tm_min, tp->tm_sec);
return s;
diff --git a/src/tet3/tcm/tcm_xt.c b/src/tet3/tcm/tcm_xt.c
index 934167ef..5eb5e4ec 100644
--- a/src/tet3/tcm/tcm_xt.c
+++ b/src/tet3/tcm/tcm_xt.c
@@ -176,7 +176,7 @@ int ptype;
tp->tp_call.maxlen = np->maxlen;
tp->tp_call.len = np->len;
- (void) memcpy(tp->tp_call.buf, np->buf, np->len);
+ memcpy(tp->tp_call.buf, np->buf, np->len);
*paddr = pp;
}
@@ -268,7 +268,7 @@ register int ptype;
return (-1);
}
mp->ts.osico.ts_len = tp->tp_call.len;
- (void) memcpy(mp->ts.osico.ts_nsap, tp->tp_call.buf, tp->tp_call.len);
+ memcpy(mp->ts.osico.ts_nsap, tp->tp_call.buf, tp->tp_call.len);
break;
#endif
diff --git a/src/tet3/tcm/tcmfuncs.c b/src/tet3/tcm/tcmfuncs.c
index abfdb2f4..eb57cc99 100644
--- a/src/tet3/tcm/tcmfuncs.c
+++ b/src/tet3/tcm/tcmfuncs.c
@@ -149,7 +149,7 @@ char **argv;
/* get TET_ROOT out of the environment */
if ((envstring = getenv(tetroot_name)) == (char *) 0 || !*envstring)
envstring = strdup(".");
- (void) sprintf(tet_root, "%.*s", (int) sizeof tet_root - 1, envstring);
+ sprintf(tet_root, "%.*s", (int) sizeof tet_root - 1, envstring);
/* get the dtet ti args out of the environment and count them */
if ((envstring = getenv(tiargs_name)) == (char *) 0 || !*envstring) {
@@ -339,7 +339,7 @@ char **argv;
case SS_SYNCYES:
break;
default:
- (void) sprintf(errmsg,
+ sprintf(errmsg,
"initial sync error, sysid = %d, state = %s",
sp->sy_sysid,
tet_systate(sp->sy_state));
@@ -371,7 +371,7 @@ void tet_dtcmerror(int errnum, const char *file, int line,
int combined_save = 0;
/* start the buffer with filename and line number */
- (void) sprintf(p, "(%s, %d): ", tet_basename(file), line);
+ sprintf(p, "(%s, %d): ", tet_basename(file), line);
p += strlen(p);
/* append the first message string */
diff --git a/src/tet3/xresd/tfproc.c b/src/tet3/xresd/tfproc.c
index 5eac0601..ec7a4747 100644
--- a/src/tet3/xresd/tfproc.c
+++ b/src/tet3/xresd/tfproc.c
@@ -172,7 +172,7 @@ char *tfname;
/* construct the transfer file name and store it */
len = (int) sizeof tfpath - (int) strlen(Tet_savedir) - 2;
- (void) sprintf(tfpath, "%.*s/%.*s",
+ sprintf(tfpath, "%.*s/%.*s",
(int) sizeof tfpath - 2, Tet_savedir, TET_MAX(len, 0), tfname);
if ((tp->tf_name = tet_strstore(tfpath)) == (char *) 0)
return(ER_ERR);
@@ -288,7 +288,7 @@ register struct ptab *pp;
done = 1;
for (tp = tftab; tp; tp = tp->tf_next)
if (tp->tf_ptab == pp) {
- (void) dotfclose(tp);
+ dotfclose(tp);
done = 0;
break;
}
diff --git a/src/tet3/xresd/xresd.c b/src/tet3/xresd/xresd.c
index fe227bee..0e74c143 100644
--- a/src/tet3/xresd/xresd.c
+++ b/src/tet3/xresd/xresd.c
@@ -191,7 +191,7 @@ register struct ptab *pp;
/* emit a diagnostic message if this is unexpected */
if ((pp->pt_flags & PF_LOGGEDOFF) == 0) {
- (void) sprintf(msg, fmt, (pp->pt_flags & PF_SERVER) ? se : cl);
+ sprintf(msg, fmt, (pp->pt_flags & PF_SERVER) ? se : cl);
error(0, msg, tet_r2a(&pp->pt_rid));
}
diff --git a/src/tet3/xresd/xresproc.c b/src/tet3/xresd/xresproc.c
index a9c693ad..dfadd68b 100644
--- a/src/tet3/xresd/xresproc.c
+++ b/src/tet3/xresd/xresproc.c
@@ -725,7 +725,7 @@ register struct ptab *pp;
text = tet_getresname(result, &abflag);
if (abflag && (xp->xt_flags & XF_TCABORT) == 0) {
xp->xt_flags |= XF_TCABORT;
- (void) sprintf(buf, fmt, result);
+ sprintf(buf, fmt, result);
xrinfo(xp, buf, text ? text : gcerr);
}
}
@@ -830,19 +830,19 @@ register int code;
/* format the variable part of the message */
switch (code) {
case TET_JNL_IC_START:
- (void) sprintf(buf, "%d %d", xp->xt_icno, xp->xt_tpcount);
+ sprintf(buf, "%d %d", xp->xt_icno, xp->xt_tpcount);
text = "IC Start";
break;
case TET_JNL_IC_END:
- (void) sprintf(buf, "%d %d", xp->xt_icno, xp->xt_tpcount);
+ sprintf(buf, "%d %d", xp->xt_icno, xp->xt_tpcount);
text = "IC End";
break;
case TET_JNL_TP_START:
- (void) sprintf(buf, "%d", xp->xt_tpno);
+ sprintf(buf, "%d", xp->xt_tpno);
text = "TP Start";
break;
case TET_JNL_TP_RESULT:
- (void) sprintf(buf, "%d %d", xp->xt_tpno, xp->xt_result);
+ sprintf(buf, "%d %d", xp->xt_tpno, xp->xt_result);
if ((text = tet_getresname(xp->xt_result, (int *) 0)) == (char *) 0)
text = "(NO RESULT NAME)";
break;
@@ -938,7 +938,7 @@ int state;
case XS_DEAD:
return("DEAD");
default:
- (void) sprintf(msg, "%s%d", text, state);
+ sprintf(msg, "%s%d", text, state);
return(msg);
}
}
diff --git a/src/tet3/xresd/xtab.c b/src/tet3/xresd/xtab.c
index 207b1324..b7f6dd0c 100644
--- a/src/tet3/xresd/xtab.c
+++ b/src/tet3/xresd/xtab.c
@@ -104,7 +104,7 @@ struct xtab *xp;
if (xp) {
if (xp->xt_xfp)
- (void) fclose(xp->xt_xfp);
+ fclose(xp->xt_xfp);
if (xp->xt_xfname) {
TRACE2(tet_Tbuf, 6, "free xtab xfname = %s",
tet_i2x(xp->xt_xfname));
@@ -164,9 +164,9 @@ void xtrm(xp)
struct xtab *xp;
{
if (xp->xt_flags & XF_TPINPROGRESS)
- (void) tpend(xp);
+ tpend(xp);
if (xp->xt_flags & XF_ICINPROGRESS)
- (void) icend(xp);
+ icend(xp);
tet_listremove((struct llist **) &xtab, (struct llist *) xp);
}
@@ -219,9 +219,9 @@ register struct ptab *pp;
count++;
if (count == xp->xt_nud) {
if (xp->xt_flags & XF_TPINPROGRESS)
- (void) tpend(xp);
+ tpend(xp);
if (xp->xt_flags & XF_ICINPROGRESS)
- (void) icend(xp);
+ icend(xp);
if (!xp->xt_ptab) {
xtrm(xp);
xtfree(xp);
diff --git a/src/tet3/xtilib/accept.c b/src/tet3/xtilib/accept.c
index 24565160..d308f7d6 100644
--- a/src/tet3/xtilib/accept.c
+++ b/src/tet3/xtilib/accept.c
@@ -112,7 +112,7 @@ int lfd;
/* bind this endpoint to an arbitrary protocol address */
if (t_bind(nfd, (struct t_bind *) 0, (struct t_bind *) 0) < 0) {
xt_error(t_errno, "can't bind fd", tet_i2a(nfd));
- (void) t_close(nfd);
+ t_close(nfd);
tet_ptfree(pp);
return;
}
@@ -130,7 +130,7 @@ int lfd;
xt_error(t_errno,"unexpected event",
tet_xtev2a(c_event));
}
- (void) t_close(nfd);
+ t_close(nfd);
tet_ptfree(pp);
return;
}
@@ -152,12 +152,12 @@ int lfd;
TRACE2(tet_Tbuf, 6, "allocate tp_call.buf = %s",
tet_i2x(tp->tp_call.buf));
- (void) memcpy(tp->tp_call.buf, tet_calls[i]->addr.buf,
+ memcpy(tp->tp_call.buf, tet_calls[i]->addr.buf,
(size_t)tet_calls[i]->addr.len);
TRACE3(tet_Tbuf, 6, "t_free tet_calls[%s] = %s",
tet_i2a(i), tet_i2x(tet_calls[i]));
- (void) t_free((char *)tet_calls[i], T_CALL);
+ t_free((char *)tet_calls[i], T_CALL);
tet_calls[i] = (struct t_call *)0;
diff --git a/src/tet3/xtilib/addr2lname.c b/src/tet3/xtilib/addr2lname.c
index c1a5c05a..1479519e 100644
--- a/src/tet3/xtilib/addr2lname.c
+++ b/src/tet3/xtilib/addr2lname.c
@@ -67,7 +67,7 @@ struct netbuf *np;
return (char *)0;
while (len--) {
- (void) sprintf(p,"%02x", (unsigned char) *q++);
+ sprintf(p,"%02x", (unsigned char) *q++);
p += 2;
}
*p = '\0';
diff --git a/src/tet3/xtilib/connect.c b/src/tet3/xtilib/connect.c
index 044d2d06..006ab45f 100644
--- a/src/tet3/xtilib/connect.c
+++ b/src/tet3/xtilib/connect.c
@@ -101,14 +101,14 @@ register struct ptab *pp;
pp->pt_flags |= PF_ATTENTION;
return;
}
- (void) t_close(fd);
+ t_close(fd);
fd = nfd;
}
/* bind this endpoint to an arbitrary protocol address */
if (t_bind(fd, (struct t_bind *)0, (struct t_bind *)0) < 0) {
xt_error(t_errno, "can't bind fd", tet_i2a(fd));
- (void) t_close(fd);
+ t_close(fd);
pp->pt_state = PS_DEAD;
pp->pt_flags |= PF_ATTENTION;
return;
@@ -153,11 +153,11 @@ register struct ptab *pp;
default:
event = tet_xtev2a(t_look(fd));
TRACE2(tet_Tio, 6, "connect failed:%s", event);
- (void) sprintf(buf, "%s(%.*s)", "connect failed",
+ sprintf(buf, "%s(%.*s)", "connect failed",
(int) sizeof buf - (int) strlen(event) - 17,
event);
xt_error(t_errno, buf, tet_r2a(&pp->pt_rid));
- (void) t_close(fd);
+ t_close(fd);
pp->pt_state = PS_DEAD;
break;
}
diff --git a/src/tet3/xtilib/discon.c b/src/tet3/xtilib/discon.c
index 65b65b4c..5650d375 100644
--- a/src/tet3/xtilib/discon.c
+++ b/src/tet3/xtilib/discon.c
@@ -70,7 +70,7 @@ struct ptab *pp;
tet_i2a(tp->tp_fd));
if (tp->tp_fd >= 0) {
- (void) t_close(tp->tp_fd);
+ t_close(tp->tp_fd);
tp->tp_fd = -1;
}
diff --git a/src/tet3/xtilib/poll.c b/src/tet3/xtilib/poll.c
index 3e4c0bdd..38b74715 100644
--- a/src/tet3/xtilib/poll.c
+++ b/src/tet3/xtilib/poll.c
@@ -115,7 +115,7 @@ int timeout;
while ((rc = ts_poll2(pp)) == 0) {
if (timeout >= 0 && time((time_t *) 0) >= start + timeout)
break;
- (void) sleep((unsigned) 1);
+ sleep((unsigned) 1);
}
return (rc);
#else
@@ -310,7 +310,7 @@ static int doaccept()
}
TRACE3(tet_Tbuf, 6, "t_free tet_calls[%s] = %s",
tet_i2a(i), tet_i2x(tet_calls[i]));
- (void) t_free((char *) tet_calls[i], T_CALL);
+ t_free((char *) tet_calls[i], T_CALL);
tet_calls[i] = (struct t_call *) 0;
return (rc);
}
@@ -330,7 +330,7 @@ static int doaccept()
if (t_rcvdis(tet_listen_fd, discon) < 0) {
xt_error(t_errno, "t_rcvdis() failed", (char *) 0);
TRACE2(tet_Tbuf, 6, "free discon = %s", tet_i2x(discon));
- (void) t_free((char *) discon, T_DIS);
+ t_free((char *) discon, T_DIS);
return(-1);
}
@@ -341,10 +341,10 @@ static int doaccept()
) {
TRACE3(tet_Tbuf, 6, "t_free tet_calls[%s] = %s",
tet_i2a(i), tet_i2x(tet_calls[i]));
- (void) t_free((char *) tet_calls[i], T_CALL);
+ t_free((char *) tet_calls[i], T_CALL);
TRACE2(tet_Tbuf, 6, "free discon = %s",
tet_i2x(discon));
- (void) t_free((char *) discon, T_DIS);
+ t_free((char *) discon, T_DIS);
tet_calls[i] = (struct t_call *) 0;
}
}
diff --git a/src/tet3/xtilib/rdwr.c b/src/tet3/xtilib/rdwr.c
index 3a9a3d66..b4687d07 100644
--- a/src/tet3/xtilib/rdwr.c
+++ b/src/tet3/xtilib/rdwr.c
@@ -112,7 +112,7 @@ register struct ptab *pp;
}
TDUMP(tet_Tio, 10, tp->tp_buf, DM_HDRSZ, msghdr);
pp->pt_flags &= ~PF_RCVHDR;
- (void) tet_bs2dtmhdr(tp->tp_buf, &pp->ptm_hdr, DM_HDRSZ);
+ tet_bs2dtmhdr(tp->tp_buf, &pp->ptm_hdr, DM_HDRSZ);
if (pp->ptm_magic != DTM_MAGIC && pp->ptm_len) {
/* we are probably out of sync with sender */
error(0, "received bad message header,",
@@ -271,7 +271,7 @@ register struct ptab *pp;
rc, msgdata);
tp->tp_cnt += rc;
}
- (void) tet_dmlen2bs(rc, tp->tp_buf);
+ tet_dmlen2bs(rc, tp->tp_buf);
} while (err);
tp->tp_ptr = tp->tp_buf;
pp->pt_flags |= PF_INPROGRESS;
@@ -428,7 +428,7 @@ register struct ptab *pp;
TRACE2(tet_Tio, 4, "tet_ts_dead: close fd %s", tet_i2a(tp->tp_fd));
- (void) t_close(tp->tp_fd);
+ t_close(tp->tp_fd);
tp->tp_fd = -1;
pp->pt_flags &= ~(PF_CONNECTED | PF_INPROGRESS);
}
diff --git a/src/tet3/xtilib/tccdaddr.c b/src/tet3/xtilib/tccdaddr.c
index 562eddb0..82562c82 100644
--- a/src/tet3/xtilib/tccdaddr.c
+++ b/src/tet3/xtilib/tccdaddr.c
@@ -95,7 +95,7 @@ struct ptab *pp;
/* all ok so fill in the address details */
tp->tp_call.maxlen = np->maxlen;
tp->tp_call.len = np->len;
- (void) memcpy(tp->tp_call.buf, np->buf, (size_t)np->len);
+ memcpy(tp->tp_call.buf, np->buf, (size_t)np->len);
return(0);
}
diff --git a/src/tet3/xtilib/xtierror.c b/src/tet3/xtilib/xtierror.c
index 2d63f352..9ed5204a 100644
--- a/src/tet3/xtilib/xtierror.c
+++ b/src/tet3/xtilib/xtierror.c
@@ -72,24 +72,24 @@ void tet_xtierror(int errnum, const char *file, int line, const char *s1,
const char *s3;
int save_errno = errno;
- (void) fprintf(stderr, "%s (%s, %d): %s",
+ fprintf(stderr, "%s (%s, %d): %s",
tet_progname, tet_basename(file), line, s1);
if (s2 && *s2)
- (void) fprintf(stderr, " %s", s2);
+ fprintf(stderr, " %s", s2);
if (errnum > 0) {
if (errnum == TSYSERR) {
if ((s3 = strerror(save_errno)) == (char *) 0)
- (void) fprintf(stderr, ", errno = %s",
+ fprintf(stderr, ", errno = %s",
tet_errname(save_errno));
else
- (void) fprintf(stderr, ": %s", s3);
+ fprintf(stderr, ": %s", s3);
}
else
- (void) fprintf(stderr, ": %s", tet_xterrno2a(errnum));
+ fprintf(stderr, ": %s", tet_xterrno2a(errnum));
}
- (void) putc('\n', stderr);
- (void) fflush(stderr);
+ putc('\n', stderr);
+ fflush(stderr);
errno = 0;
t_errno = 0;
@@ -195,7 +195,7 @@ int n;
#endif
default :
- (void) sprintf(buf, fmt, n);
+ sprintf(buf, fmt, n);
return (buf);
}
}
@@ -243,7 +243,7 @@ int n;
#endif
default :
- (void) sprintf(buf, fmt, n);
+ sprintf(buf, fmt, n);
return (buf);
}
diff --git a/xts5/Xlib4/XCreateWindow/commattr.mc b/xts5/Xlib4/XCreateWindow/commattr.mc
index 113312e6..6c11abbe 100644
--- a/xts5/Xlib4/XCreateWindow/commattr.mc
+++ b/xts5/Xlib4/XCreateWindow/commattr.mc
@@ -613,7 +613,7 @@ Cursor pcur;
#endif
/* Warp the pointer to the child window. */
- (void) warppointer(display, w, 0,0);
+ warppointer(display, w, 0,0);
/* Verify that the current cursor is that of the parent. */
if(spriteiswin(display, parent) == False) {
@@ -1263,7 +1263,7 @@ static unsigned long validbits[] = {
attributes->bit_gravity = vals[i];
- (void) XCALL;
+ XCALL;
if(geterr() == BadValue)
CHECK;
@@ -1329,7 +1329,7 @@ static unsigned long validbits[] = {
attributes->win_gravity = vals[i];
- (void) XCALL;
+ XCALL;
if(geterr() == BadValue)
CHECK;
@@ -1380,7 +1380,7 @@ static int validvalues[] = {
attributes->backing_store = vals[i];
- (void) XCALL;
+ XCALL;
if(geterr() == BadValue)
CHECK;
@@ -1428,7 +1428,7 @@ static int validvalues[] = {
attributes->save_under= vals[i];
- (void) XCALL;
+ XCALL;
if(geterr() == BadValue)
CHECK;
@@ -1525,7 +1525,7 @@ static unsigned long validbits[] = {
attributes->event_mask = vals[i];
- (void) XCALL;
+ XCALL;
if(geterr() == BadValue)
CHECK;
@@ -1622,7 +1622,7 @@ static unsigned long validbits[] = {
attributes->do_not_propagate_mask = vals[i];
- (void) XCALL;
+ XCALL;
if(geterr() == BadValue)
CHECK;
@@ -1670,7 +1670,7 @@ static int validvalues[] = {
attributes->override_redirect= vals[i];
- (void) XCALL;
+ XCALL;
if(geterr() == BadValue)
CHECK;
@@ -1759,7 +1759,7 @@ static int validvalues[] = {
>>#
>># valuemask = vals[i];
>>#
->># (void) XCALL;
+>># XCALL;
>>#
>># if(geterr() == BadValue)
>># CHECK;
diff --git a/xts5/lib/gc/subwindow.mc b/xts5/lib/gc/subwindow.mc
index e6d6b7b0..f0162afe 100644
--- a/xts5/lib/gc/subwindow.mc
+++ b/xts5/lib/gc/subwindow.mc
@@ -242,7 +242,7 @@ int i, j;
subwins[i] = crechild(A_DISPLAY, A_DRAW, &area);
for (j = 0; j < swmheight; j += 10) {
setarea(&area, 0, j, swmwidth, 6);
- (void) crechild(A_DISPLAY, subwins[i], &area);
+ crechild(A_DISPLAY, subwins[i], &area);
}
}
diff --git a/xts5/src/bin/mc/code.c b/xts5/src/bin/mc/code.c
index 7d4037d6..9c483fb0 100644
--- a/xts5/src/bin/mc/code.c
+++ b/xts5/src/bin/mc/code.c
@@ -203,7 +203,7 @@ char *buf;
FpAssertion = (FILE *)-1;
FpStrategy = (FILE *)-1;
setoutline();
- (void) fprintf(FpCode, "%sint tet_thistest;\n\n", (lflag)? "extern ": "");
+ fprintf(FpCode, "%sint tet_thistest;\n\n", (lflag)? "extern ": "");
}
/*ARGSUSED*/
@@ -214,13 +214,13 @@ char *buf;
int i;
/* Finish the copyright banner */
- (void) fprintf(FpBanner, "*/\n");
+ fprintf(FpBanner, "*/\n");
/* Finish the code section */
- (void) fprintf(FpCode, "/* End of Test Cases */\n\n\n");
+ fprintf(FpCode, "/* End of Test Cases */\n\n\n");
setoutline();
- (void) fprintf(FpCode, "%sstruct tet_testlist tet_testlist[] = {\n",
+ fprintf(FpCode, "%sstruct tet_testlist tet_testlist[] = {\n",
(lflag)? "static ": "");
/*
@@ -228,12 +228,12 @@ char *buf;
*/
for (i = 1; i <= Testnum; i++) {
if (!gbflag)
- (void) fprintf(FpCode, "\t{ t%03d, %d },\n", Icnum[i], Icnum[i]);
+ fprintf(FpCode, "\t{ t%03d, %d },\n", Icnum[i], Icnum[i]);
else
- (void) fprintf(FpCode, "\t{ t%03d, %s },\n", Icnum[i], Ictype[i]);
+ fprintf(FpCode, "\t{ t%03d, %s },\n", Icnum[i], Ictype[i]);
}
- (void) fprintf(FpCode, "\t{ NULL, 0 }\n};\n\n");
- (void) fprintf(FpCode, "%sint \tntests = sizeof(tet_testlist)/sizeof(struct tet_testlist)-1;\n\n",
+ fprintf(FpCode, "\t{ NULL, 0 }\n};\n\n");
+ fprintf(FpCode, "%sint \tntests = sizeof(tet_testlist)/sizeof(struct tet_testlist)-1;\n\n",
(lflag)?"static ": "");
/*
@@ -241,22 +241,22 @@ char *buf;
* entry.
*/
if (lflag) {
- (void) fprintf(FpCode, "struct linkinfo E%s = {\n", name12(State.name));
- (void) fprintf(FpCode, "\t\"%s%s\",\n",
+ fprintf(FpCode, "struct linkinfo E%s = {\n", name12(State.name));
+ fprintf(FpCode, "\t\"%s%s\",\n",
(mflag)? "m": "",name10lc(State.name));
- (void) fprintf(FpCode, "\t\"%s\",\n", State.name);
- (void) fprintf(FpCode, "\t&ntests,\n");
- (void) fprintf(FpCode, "\ttet_testlist,\n");
+ fprintf(FpCode, "\t\"%s\",\n", State.name);
+ fprintf(FpCode, "\t&ntests,\n");
+ fprintf(FpCode, "\ttet_testlist,\n");
if (Settings.startup)
- (void) fprintf(FpCode, "\t%s,\n", Settings.startup);
+ fprintf(FpCode, "\t%s,\n", Settings.startup);
else
- (void) fprintf(FpCode, "\t0,\n");
+ fprintf(FpCode, "\t0,\n");
if (Settings.cleanup)
- (void) fprintf(FpCode, "\t%s,\n", Settings.cleanup);
+ fprintf(FpCode, "\t%s,\n", Settings.cleanup);
else
- (void) fprintf(FpCode, "\t0,\n");
- (void) fprintf(FpCode, "};\n\n");
+ fprintf(FpCode, "\t0,\n");
+ fprintf(FpCode, "};\n\n");
}
/*
@@ -264,28 +264,28 @@ char *buf;
* is a linked binary or not.
*/
if (lflag) {
- (void) fprintf(FpCode, "extern void (*tet_startup)();\n");
- (void) fprintf(FpCode, "extern void (*tet_cleanup)();\n");
+ fprintf(FpCode, "extern void (*tet_startup)();\n");
+ fprintf(FpCode, "extern void (*tet_cleanup)();\n");
} else {
if (State.xtoolkit != 0)
{
- (void) fprintf(FpCode, "void (*tet_startup)() = %s;\n"
+ fprintf(FpCode, "void (*tet_startup)() = %s;\n"
, Settings.startup? Settings.startup: "NULL" );
- (void) fprintf(FpCode, "void (*tet_cleanup)() = %s;\n"
+ fprintf(FpCode, "void (*tet_cleanup)() = %s;\n"
, Settings.cleanup? Settings.cleanup: "NULL");
}
else if (State.xcms != 0)
{
- (void) fprintf(FpCode, "void (*tet_startup)() = %s;\n"
+ fprintf(FpCode, "void (*tet_startup)() = %s;\n"
, Settings.startup? Settings.startup: "r5_startup" );
- (void) fprintf(FpCode, "void (*tet_cleanup)() = %s;\n"
+ fprintf(FpCode, "void (*tet_cleanup)() = %s;\n"
, Settings.cleanup? Settings.cleanup: "r5_cleanup");
}
else
{
- (void) fprintf(FpCode, "void (*tet_startup)() = %s;\n"
+ fprintf(FpCode, "void (*tet_startup)() = %s;\n"
, Settings.startup? Settings.startup: "startup");
- (void) fprintf(FpCode, "void (*tet_cleanup)() = %s;\n"
+ fprintf(FpCode, "void (*tet_cleanup)() = %s;\n"
, Settings.cleanup? Settings.cleanup: "cleanup");
}
}
@@ -373,8 +373,8 @@ static int oncethrough;
oncethrough = 1;
setoutline();
- (void) fprintf(FpExtern, "\n#define T_%s\t1\n", State.name);
- (void) fprintf(FpExtern, "%schar *TestName = \"%s\";\n\n",
+ fprintf(FpExtern, "\n#define T_%s\t1\n", State.name);
+ fprintf(FpExtern, "%schar *TestName = \"%s\";\n\n",
(lflag)? "static ": "", State.name);
Nargs = 0;
@@ -435,39 +435,39 @@ static int oncethrough;
* here.
*/
if (Nargs > 2)
- (void) fprintf(FpExtern, "/*\n * Arguments to the %s %s\n */\n",
+ fprintf(FpExtern, "/*\n * Arguments to the %s %s\n */\n",
State.name, (mflag)? "macro": "function");
for (i = 2; i < Nargs; i++) {
- (void) fprintf(FpExtern, "static ");
+ fprintf(FpExtern, "static ");
for (cp = Arglines[i]; *cp; cp++) {
if ((*cp == ' ' && cp[1] == '=') || *cp == '=') {
- (void) fprintf(FpExtern, ";\n");
+ fprintf(FpExtern, ";\n");
break;
}
- (void) fputc(*cp, FpExtern);
+ fputc(*cp, FpExtern);
}
}
if (Nargs > 2)
- (void) fprintf(FpExtern, "\n\n");
+ fprintf(FpExtern, "\n\n");
if (NeedStatus)
- (void) fprintf(FpExtern, "static int StatusReturn;\n");
+ fprintf(FpExtern, "static int StatusReturn;\n");
if (NeedValue)
- (void) fprintf(FpExtern, "static int ValueReturn;\n");
+ fprintf(FpExtern, "static int ValueReturn;\n");
if (NeedStatus || NeedValue)
- (void) fprintf(FpExtern, "\n");
+ fprintf(FpExtern, "\n");
if (Nargs > 2) {
- (void) fprintf(FpCode, "/*\n * Called at the beginning of each test purpose to reset the\n * arguments to their initial values\n */\n");
- (void) fprintf(FpCode, "static void\nsetargs()\n{\n");
+ fprintf(FpCode, "/*\n * Called at the beginning of each test purpose to reset the\n * arguments to their initial values\n */\n");
+ fprintf(FpCode, "static void\nsetargs()\n{\n");
for (i = 2; i < Nargs; i++) {
if (Arginit[i])
- (void) fprintf(FpCode, "\t%s = %s", Argnames[i], Arginit[i]);
+ fprintf(FpCode, "\t%s = %s", Argnames[i], Arginit[i]);
else
- (void) fprintf(FpCode, "\t%s = 0;\n", Argnames[i]);
+ fprintf(FpCode, "\t%s = 0;\n", Argnames[i]);
}
- (void) fprintf(FpCode, "}\n\n");
+ fprintf(FpCode, "}\n\n");
}
/*
@@ -475,8 +475,8 @@ static int oncethrough;
* for the server resources for testing error funtcions.
*/
if (Nargs) {
- (void) fprintf(FpCode, "/*\n * Set the arguments to default values for error tests\n */\n");
- (void) fprintf(FpCode, "static void\nseterrdef()\n{\n");
+ fprintf(FpCode, "/*\n * Set the arguments to default values for error tests\n */\n");
+ fprintf(FpCode, "static void\nseterrdef()\n{\n");
}
for (i = 2; i < Nargs; i++) {
@@ -498,35 +498,35 @@ static int oncethrough;
for (cp = errdeftypes; *cp; cp++) {
if (strncmp(Arglines[i], *cp, strlen(*cp)) == 0)
- (void) fprintf(FpCode, "\t%s = Errdef%s;\n", Argnames[i], *cp);
+ fprintf(FpCode, "\t%s = Errdef%s;\n", Argnames[i], *cp);
}
}
if (Nargs)
- (void) fprintf(FpCode, "}\n\n");
+ fprintf(FpCode, "}\n\n");
/*
* If this is testing a particular function then put out a
* synopsis in the header.
*/
if (Nargs > 1) {
- (void) fprintf(FpSynopsis, "/*\n * SYNOPSIS:\n");
- (void) fprintf(FpSynopsis, " * %s", Arglines[0]); /* return type */
- (void) fprintf(FpSynopsis, " * %s(", State.name);
+ fprintf(FpSynopsis, "/*\n * SYNOPSIS:\n");
+ fprintf(FpSynopsis, " * %s", Arglines[0]); /* return type */
+ fprintf(FpSynopsis, " * %s(", State.name);
for (i = 2; i < Nargs; i++) {
- (void) fprintf(FpSynopsis, "%s%s", Argnames[i], (i == Nargs-1)? "": ", ");
+ fprintf(FpSynopsis, "%s%s", Argnames[i], (i == Nargs-1)? "": ", ");
}
- (void) fprintf(FpSynopsis, ")\n");
+ fprintf(FpSynopsis, ")\n");
for (i = 2; i < Nargs; i++) {
- (void) fprintf(FpSynopsis, " * ");
+ fprintf(FpSynopsis, " * ");
for (cp = Arglines[i]; *cp; cp++) {
if ((*cp == ' ' && cp[1] == '=') || *cp == '=') {
- (void) fprintf(FpSynopsis, ";\n");
+ fprintf(FpSynopsis, ";\n");
break;
}
- (void) fputc(*cp, FpSynopsis);
+ fputc(*cp, FpSynopsis);
}
}
- (void) fprintf(FpSynopsis, " */\n\n");
+ fprintf(FpSynopsis, " */\n\n");
}
}
@@ -551,7 +551,7 @@ int window = 0;
int image = 0;
if (Nargs > 2)
- (void) fprintf(FpDefines, "/*\n * Defines for different argument types\n */\n");
+ fprintf(FpDefines, "/*\n * Defines for different argument types\n */\n");
for (i = 2; i < Nargs; i++) {
@@ -566,17 +566,17 @@ int image = 0;
if (STRPRECMP(Arglines[i], "Atom") == 0) {
if (atom == 0)
- (void) fprintf(FpDefines, "#define A_ATOM %s\n", Argnames[i]);
+ fprintf(FpDefines, "#define A_ATOM %s\n", Argnames[i]);
atom++;
defargtype("A_ATOM", atom);
} else if (STRPRECMP(Arglines[i], "Colormap") == 0) {
if (colormap == 0)
- (void) fprintf(FpDefines, "#define A_COLORMAP %s\n", Argnames[i]);
+ fprintf(FpDefines, "#define A_COLORMAP %s\n", Argnames[i]);
colormap++;
defargtype("A_COLORMAP", colormap);
} else if (STRPRECMP(Arglines[i], "Cursor") == 0) {
if (cursor == 0)
- (void) fprintf(FpDefines, "#define A_CURSOR %s\n", Argnames[i]);
+ fprintf(FpDefines, "#define A_CURSOR %s\n", Argnames[i]);
cursor++;
defargtype("A_CURSOR", cursor);
} else if (STRPRECMP(Arglines[i], "Display") == 0) {
@@ -585,23 +585,23 @@ int image = 0;
errexit();
}
defargtype("A_DISPLAY", display);
- (void) fprintf(FpDefines, "#define A_DISPLAY %s\n", Argnames[i]);
+ fprintf(FpDefines, "#define A_DISPLAY %s\n", Argnames[i]);
} else if (STRPRECMP(Arglines[i], "Drawable") == 0) {
if (drawable > 0)
- (void) fprintf(FpDefines, "#define A_DRAWABLE%d %s\n",
+ fprintf(FpDefines, "#define A_DRAWABLE%d %s\n",
drawable+1, Argnames[i]);
else
- (void) fprintf(FpDefines, "#define A_DRAWABLE %s\n", Argnames[i]);
+ fprintf(FpDefines, "#define A_DRAWABLE %s\n", Argnames[i]);
drawable++;
defargtype("A_DRAWABLE", drawable);
} else if (STRPRECMP(Arglines[i], "Font") == 0) {
if (font == 0)
- (void) fprintf(FpDefines, "#define A_FONT %s\n", Argnames[i]);
+ fprintf(FpDefines, "#define A_FONT %s\n", Argnames[i]);
font++;
defargtype("A_FONT", font);
} else if (STRPRECMP(Arglines[i], "GC") == 0) {
if (gc == 0)
- (void) fprintf(FpDefines, "#define A_GC %s\n", Argnames[i]);
+ fprintf(FpDefines, "#define A_GC %s\n", Argnames[i]);
gc++;
defargtype("A_GC", gc);
} else if (STRPRECMP(Arglines[i], "XImage") == 0) {
@@ -614,35 +614,35 @@ int image = 0;
defargtype("A_IMAGE", image);
} else if (STRPRECMP(Arglines[i], "Pixmap") == 0) {
if (pixmap == 0)
- (void) fprintf(FpDefines, "#define A_PIXMAP %s\n", Argnames[i]);
+ fprintf(FpDefines, "#define A_PIXMAP %s\n", Argnames[i]);
else
- (void) fprintf(FpDefines, "#define A_PIXMAP%d %s\n", pixmap+1, Argnames[i]);
+ fprintf(FpDefines, "#define A_PIXMAP%d %s\n", pixmap+1, Argnames[i]);
if (drawable > 0)
- (void) fprintf(FpDefines, "#define A_DRAWABLE%d %s\n",
+ fprintf(FpDefines, "#define A_DRAWABLE%d %s\n",
drawable+1, Argnames[i]);
else
- (void) fprintf(FpDefines, "#define A_DRAWABLE %s\n", Argnames[i]);
+ fprintf(FpDefines, "#define A_DRAWABLE %s\n", Argnames[i]);
drawable++;
defargtype("A_DRAWABLE", drawable);
pixmap++;
defargtype("A_PIXMAP", pixmap);
} else if (STRPRECMP(Arglines[i], "Window") == 0) {
if (window == 0)
- (void) fprintf(FpDefines, "#define A_WINDOW %s\n", Argnames[i]);
+ fprintf(FpDefines, "#define A_WINDOW %s\n", Argnames[i]);
else
- (void) fprintf(FpDefines, "#define A_WINDOW%d %s\n", window+1, Argnames[i]);
+ fprintf(FpDefines, "#define A_WINDOW%d %s\n", window+1, Argnames[i]);
if (drawable > 0)
- (void) fprintf(FpDefines, "#define A_DRAWABLE%d %s\n",
+ fprintf(FpDefines, "#define A_DRAWABLE%d %s\n",
drawable+1, Argnames[i]);
else
- (void) fprintf(FpDefines, "#define A_DRAWABLE %s\n", Argnames[i]);
+ fprintf(FpDefines, "#define A_DRAWABLE %s\n", Argnames[i]);
drawable++;
defargtype("A_DRAWABLE", drawable);
window++;
defargtype("A_WINDOW", window);
}
}
- (void) fprintf(FpDefines, "\n\n");
+ fprintf(FpDefines, "\n\n");
}
/*
@@ -680,7 +680,7 @@ char **cpp;
errexit();
}
- (void) fprintf(FpAssertion, "Assertion %s-%d.(%c)\n", State.name,
+ fprintf(FpAssertion, "Assertion %s-%d.(%c)\n", State.name,
State.assertion, State.category);
Testnum++;
@@ -695,7 +695,7 @@ char **cpp;
State.reason = "No reason code supplied";
}
- (void) fprintf(FpAssertion, "\nReason for omission: %s\n", State.reason);
+ fprintf(FpAssertion, "\nReason for omission: %s\n", State.reason);
}
@@ -737,7 +737,7 @@ char *endl;
if (strcmp(tok, ".tL") == 0) {
break; /* ie. skip this line altogether. */
#if 0
- (void) fprintf(outfp, "\n%s", prefix);
+ fprintf(outfp, "\n%s", prefix);
assertpos = 0;
inmacro = 1;
#endif
@@ -769,10 +769,10 @@ char *endl;
assertpos += strlen(tok) + 1;
if (assertpos > ASLENGTH && !joinpunct(*tok)) {
assertpos = strlen(tok);
- (void) fprintf(outfp, "\n%s", prefix);
+ fprintf(outfp, "\n%s", prefix);
} else if (oldpos > 0 && needscrunch < 2 && !joinpunct(*tok))
- (void) fputc(' ', outfp);
- (void) fprintf(outfp, "%s", tok);
+ fputc(' ', outfp);
+ fprintf(outfp, "%s", tok);
if (needscrunch)
needscrunch++;
}
@@ -836,7 +836,7 @@ char *buf;
}
FpStrategy = cretmpfile(F_STRATEGY, NULL);
while (newline(fp, buf) != NULL && !SECSTART(buf)) {
- (void) fprintf(FpStrategy, "%s", buf);
+ fprintf(FpStrategy, "%s", buf);
}
return;
@@ -868,16 +868,16 @@ int indecs = 1;
indecs = 0;
setoutline();
if (State.xtoolkit != 0)
- (void) fprintf(FpCode, "pid_t pid;\n");
+ fprintf(FpCode, "pid_t pid;\n");
else if (State.xcms == 0)
- (void) fprintf(FpCode, "int pass = 0, fail = 0;\n");
- (void) fprintf(FpCode, "\n report_purpose(%d);\n\n", State.assertion);
+ fprintf(FpCode, "int pass = 0, fail = 0;\n");
+ fprintf(FpCode, "\n report_purpose(%d);\n\n", State.assertion);
(void)fseek(FpAssertion, 0 , SEEK_SET);
while (newline(FpAssertion, buf) != NULL && !SECSTART(buf)) {
/*strip newlines*/
if (buf[strlen(buf)-1] == '\n')
buf[strlen(buf)-1] = 0;
- (void) fprintf(FpCode, " report_assertion(\"%s\");\n", buf);
+ fprintf(FpCode, " report_assertion(\"%s\");\n", buf);
}
buf[0] = 0;
@@ -889,24 +889,24 @@ int indecs = 1;
/*strip newlines*/
if (buf[strlen(buf)-1] == '\n')
buf[strlen(buf)-1] = 0;
- (void) fprintf(FpCode, " report_strategy(\"%s\");\n", buf);
+ fprintf(FpCode, " report_strategy(\"%s\");\n", buf);
}
buf[0] = 0;
}
if ((Settings.tpstartup != NULL) && (strlen(Settings.tpstartup) != 0))
- (void) fprintf(FpCode, "\n %s();\n", Settings.tpstartup);
+ fprintf(FpCode, "\n %s();\n", Settings.tpstartup);
if ((State.xtoolkit == 0) && (State.xcms == 0))
{
if (Nargs > 2)
- (void) fprintf(FpCode, " setargs();\n");
+ fprintf(FpCode, " setargs();\n");
}
if (Settings.beginfunc)
- (void) fprintf(FpCode, " %s();\n", Settings.beginfunc);
+ fprintf(FpCode, " %s();\n", Settings.beginfunc);
if (State.xtoolkit != 0)
{
- (void) fprintf(FpCode, " FORK(pid);\n");
- (void) fprintf(FpCode, " initconfig();\n\n");
+ fprintf(FpCode, " FORK(pid);\n");
+ fprintf(FpCode, " initconfig();\n\n");
}
NeedTpcleanup = 1;
Resyncline = 1;
@@ -948,14 +948,14 @@ char *buf;
}
}
- (void) fputc('\n', FpExtern);
+ fputc('\n', FpExtern);
}
funcstart()
{
- (void) fprintf(FpCode, "%svoid t%03d(){\n\n", (dflag)?"" : "static ", State.assertion);
+ fprintf(FpCode, "%svoid t%03d(){\n\n", (dflag)?"" : "static ", State.assertion);
NeedTpcleanup = 0;
Resyncline = 1;
}
@@ -963,20 +963,20 @@ funcstart()
funcend()
{
if (NeedTpcleanup && Settings.endfunc)
- (void) fprintf(FpCode, "\t%s();\n", Settings.endfunc);
+ fprintf(FpCode, "\t%s();\n", Settings.endfunc);
if (NeedTpcleanup)
{
if (State.xtoolkit != 0)
- (void) fprintf(FpCode, "\n LKROF(pid, AVSXTTIMEOUT*xt_tomultiple);\n");
+ fprintf(FpCode, "\n LKROF(pid, AVSXTTIMEOUT*xt_tomultiple);\n");
if ((Settings.tpcleanup != NULL) && (strlen(Settings.tpcleanup) != 0))
- (void) fprintf(FpCode, "\t%s();\n", Settings.tpcleanup);
+ fprintf(FpCode, "\t%s();\n", Settings.tpcleanup);
if ((State.xtoolkit == 0) && (State.xcms == 0))
- (void) fprintf(FpCode, "\tpfcount(pass, fail);\n");
+ fprintf(FpCode, "\tpfcount(pass, fail);\n");
}
/*
}
*/
- (void) fprintf(FpCode, "}\n\n");
+ fprintf(FpCode, "}\n\n");
}
@@ -1002,10 +1002,10 @@ int insertval = 0;
fputs(prefix, fp);
if (Settings.display)
- (void) fprintf(fp, "startcall(%s);\n", Settings.display);
+ fprintf(fp, "startcall(%s);\n", Settings.display);
else
fputs("startcall(Dsp);\n", fp);
- (void) fprintf(fp, "%sif (isdeleted())\n%s\treturn;\n",
+ fprintf(fp, "%sif (isdeleted())\n%s\treturn;\n",
prefix, prefix);
setline(fp);
@@ -1030,22 +1030,22 @@ int insertval = 0;
insertval = 1;
fputs("ValueReturn = ", fp);
}
- (void) fprintf(fp, "%s(", State.name);
+ fprintf(fp, "%s(", State.name);
for (i = 2; i < Nargs; i++) {
- (void) fprintf(fp, "%s%s", Argnames[i], (i == Nargs-1)? "": ", ");
+ fprintf(fp, "%s%s", Argnames[i], (i == Nargs-1)? "": ", ");
}
- (void) fprintf(fp, ")");
+ fprintf(fp, ")");
cp += strlen(XCALLSYM);
fputs(cp, fp);
setoutline();
if (Settings.needgcflush)
- (void) fprintf(fp, "%sgcflush(A_DISPLAY, A_GC);\n", prefix);
+ fprintf(fp, "%sgcflush(A_DISPLAY, A_GC);\n", prefix);
if (Settings.display)
- (void) fprintf(fp, "%sendcall(%s);\n", prefix, Settings.display);
+ fprintf(fp, "%sendcall(%s);\n", prefix, Settings.display);
else
- (void) fprintf(fp, "%sendcall(Dsp);\n", prefix);
+ fprintf(fp, "%sendcall(Dsp);\n", prefix);
/*
* If we are generating code to check for the Status return, then
@@ -1054,54 +1054,54 @@ int insertval = 0;
* on failure. Also need to use tpcleanup if returning.
*/
if (insertstat) {
- (void) fprintf(fp, "%sif (StatusReturn %s 0) {\n", prefix,
+ fprintf(fp, "%sif (StatusReturn %s 0) {\n", prefix,
(strcmp(Ictype[Testnum], "Good") == 0)? "==": "!=");
- (void) fprintf(fp, "%s\treport(\"Status returned was %%d\", StatusReturn);\n",
+ fprintf(fp, "%s\treport(\"Status returned was %%d\", StatusReturn);\n",
prefix);
- (void) fprintf(fp, "%s\tFAIL;\n", prefix);
+ fprintf(fp, "%s\tFAIL;\n", prefix);
if (Settings.failreturn) {
if (NeedTpcleanup && Settings.endfunc)
- (void) fprintf(fp, "%s\t%s();\n", prefix, Settings.endfunc);
+ fprintf(fp, "%s\t%s();\n", prefix, Settings.endfunc);
if (NeedTpcleanup)
- (void) fprintf(fp, "%s\t%s();\n", prefix, Settings.tpcleanup);
- (void) fprintf(fp, "%s\treturn;\n", prefix);
+ fprintf(fp, "%s\t%s();\n", prefix, Settings.tpcleanup);
+ fprintf(fp, "%s\treturn;\n", prefix);
}
- (void) fprintf(fp, "%s}\n", prefix);
+ fprintf(fp, "%s}\n", prefix);
}
/* As above, but for a value return */
if (insertval && Settings.valreturn && *Settings.valreturn) {
- (void) fprintf(fp, "%sif (ValueReturn != %s) {\n", prefix,
+ fprintf(fp, "%sif (ValueReturn != %s) {\n", prefix,
Settings.valreturn);
- (void) fprintf(fp,
+ fprintf(fp,
"%s\treport(\"Returned value was %%d, expecting %s\", ValueReturn);\n"
, prefix, Settings.valreturn);
- (void) fprintf(fp, "%s\tFAIL;\n", prefix);
+ fprintf(fp, "%s\tFAIL;\n", prefix);
if (Settings.failreturn) {
if (NeedTpcleanup && Settings.endfunc)
- (void) fprintf(fp, "%s\t%s();\n", prefix, Settings.endfunc);
+ fprintf(fp, "%s\t%s();\n", prefix, Settings.endfunc);
if (NeedTpcleanup)
- (void) fprintf(fp, "%s\t%s();\n", prefix, Settings.tpcleanup);
- (void) fprintf(fp, "%s\treturn;\n", prefix);
+ fprintf(fp, "%s\t%s();\n", prefix, Settings.tpcleanup);
+ fprintf(fp, "%s\treturn;\n", prefix);
}
- (void) fprintf(fp, "%s}\n", prefix);
+ fprintf(fp, "%s}\n", prefix);
}
/*
* If wanted check the error status.
*/
if (Settings.noerrcheck == 0) {
- (void) fprintf(fp, "%sif (geterr() != %s) {\n", prefix, ExpectError);
- (void) fprintf(fp, "%s\treport(\"Got %%s, Expecting %s\", errorname(geterr()));\n", prefix, ExpectError);
- (void) fprintf(fp, "%s\tFAIL;\n", prefix);
+ fprintf(fp, "%sif (geterr() != %s) {\n", prefix, ExpectError);
+ fprintf(fp, "%s\treport(\"Got %%s, Expecting %s\", errorname(geterr()));\n", prefix, ExpectError);
+ fprintf(fp, "%s\tFAIL;\n", prefix);
if (Settings.failreturn) {
if (NeedTpcleanup && Settings.endfunc)
- (void) fprintf(fp, "%s\t%s();\n", prefix, Settings.endfunc);
+ fprintf(fp, "%s\t%s();\n", prefix, Settings.endfunc);
if (NeedTpcleanup)
- (void) fprintf(fp, "%s\t%s();\n", prefix, Settings.tpcleanup);
- (void) fprintf(fp, "%s\treturn;\n", prefix);
+ fprintf(fp, "%s\t%s();\n", prefix, Settings.tpcleanup);
+ fprintf(fp, "%s\treturn;\n", prefix);
}
- (void) fprintf(fp, "%s}\n", prefix);
+ fprintf(fp, "%s}\n", prefix);
}
/* These settings only apply for one xcall */
@@ -1120,13 +1120,13 @@ char *buf;
memset(buf2, 0, sizeof(buf2));
mcassertion(fp, buf);
funcstart();
- (void) fprintf(FpCode, "\n report_purpose(%d);\n\n", State.assertion);
+ fprintf(FpCode, "\n report_purpose(%d);\n\n", State.assertion);
(void)fseek(FpAssertion, 0 , SEEK_SET);
while (newline(FpAssertion, buf2)) {
if (buf2[strlen(buf2)-1] == '\n')
buf2[strlen(buf2)-1] = 0;
- (void) fprintf(FpCode, " report_assertion(\"%s\");\n", buf2);
+ fprintf(FpCode, " report_assertion(\"%s\");\n", buf2);
}
fprintf(FpCode, "\treport_assertion(\"The assertion is descriptive or is tested elsewhere.\");\n");
@@ -1143,7 +1143,7 @@ mcincstart(buf)
char *buf;
{
if (strcmp(buf+strlen(buf)-4, ".tmc") != 0)
- (void) fprintf(FpCode, "/* Including from file %s */\n", buf);
+ fprintf(FpCode, "/* Including from file %s */\n", buf);
}
void
@@ -1151,7 +1151,7 @@ mcincend(buf)
char *buf;
{
if (strcmp(buf+strlen(buf)-4, ".tmc") != 0)
- (void) fprintf(FpCode, "/* End of included file %s */\n\n", buf);
+ fprintf(FpCode, "/* End of included file %s */\n\n", buf);
}
static void
@@ -1162,7 +1162,7 @@ static int lastline;
if (pflag) {
if (Resyncline || lastline+1 != Lineno) {
- (void) fprintf(fp, "#line %d \"%s\"\n",
+ fprintf(fp, "#line %d \"%s\"\n",
Lineno, Filename? Filename: "stdin");
Resyncline = 0;
}
@@ -1174,7 +1174,7 @@ static void
setoutline()
{
if (pflag) {
- (void) fprintf(FpCode, ">>G\n");
+ fprintf(FpCode, ">>G\n");
Resyncline = 1;
}
}
diff --git a/xts5/src/bin/mc/error.c b/xts5/src/bin/mc/error.c
index c7835346..dff5c7d0 100644
--- a/xts5/src/bin/mc/error.c
+++ b/xts5/src/bin/mc/error.c
@@ -175,7 +175,7 @@ static char *sep = " ,\t";
if (*mp == NULL) {
err("Bad .ER error code");
- (void) fprintf(stderr, " (%s)\n", type);
+ fprintf(stderr, " (%s)\n", type);
errexit();
}
@@ -190,8 +190,8 @@ static char *sep = " ,\t";
break;
}
- (void) strcpy(errfile, "error/");
- (void) strcat(errfile, *(mp+1));
+ strcpy(errfile, "error/");
+ strcat(errfile, *(mp+1));
/* BadValue is a special case to be dealt with */
if (strncmp(type, "Value", 5) == 0) {
@@ -215,8 +215,8 @@ char *tmpfile;
fp = cretmpfile(F_TVAL, &tmpfile);
- (void) fprintf(fp, ">>ASSERTION Bad A\n");
- (void) fprintf(fp, "When the value of\n.A %s\n", Alts[1]);
+ fprintf(fp, ">>ASSERTION Bad A\n");
+ fprintf(fp, "When the value of\n.A %s\n", Alts[1]);
i = 2;
if (strcmp(Alts[i], "mask") == 0) {
@@ -226,32 +226,32 @@ char *tmpfile;
wasmasktype = 0;
if (wasmasktype)
- (void) fprintf(fp, "is not a bitwise combination of\n");
+ fprintf(fp, "is not a bitwise combination of\n");
else
- (void) fprintf(fp, "is other than\n");
+ fprintf(fp, "is other than\n");
for (; i < Nalts; i++) {
- (void) fprintf(fp, ".S %s", Alts[i]);
+ fprintf(fp, ".S %s", Alts[i]);
if (i == Nalts-2)
- (void) fprintf(fp, "%s", "\nor\n");
+ fprintf(fp, "%s", "\nor\n");
else
- (void) fprintf(fp, "%s", " ,\n");
+ fprintf(fp, "%s", " ,\n");
}
- (void) fprintf(fp, "then a\n.S BadValue\nerror occurs.\n");
+ fprintf(fp, "then a\n.S BadValue\nerror occurs.\n");
- (void) fprintf(fp, ">>EXTERN\n\n");
- (void) fprintf(fp, "/* Value list for use in test t%03d */\n", State.assertion+1);
- (void) fprintf(fp, "static %s %svallist[] = {\n",
+ fprintf(fp, ">>EXTERN\n\n");
+ fprintf(fp, "/* Value list for use in test t%03d */\n", State.assertion+1);
+ fprintf(fp, "static %s %svallist[] = {\n",
wasmasktype? "unsigned long": "int ", Alts[1]);
for (i = (wasmasktype)? 3: 2; i < Nalts; i++) {
- (void) fprintf(fp, "\t%s,\n", Alts[i]);
+ fprintf(fp, "\t%s,\n", Alts[i]);
}
- (void) fprintf(fp, "};\n\n");
- (void) fclose(fp);
+ fprintf(fp, "};\n\n");
+ fclose(fp);
includefile(tmpfile, buf);
}
@@ -264,18 +264,18 @@ char line[MAXLINE];
* Do the define bits.
*/
line[0] = '\0';
- (void) strcat(line, "#undef\tVALUE_ARG\n");
- (void) sprintf(line+strlen(line), "#define\tVALUE_ARG %s\n", Alts[1]);
- (void) strcat(line, "#undef\tVALUE_LIST\n");
- (void) sprintf(line+strlen(line), "#define\tVALUE_LIST %svallist\n", Alts[1]);
- (void) sprintf(line+strlen(line), "#undef NOTMEMTYPE\n");
- (void) sprintf(line+strlen(line), "#define NOTMEMTYPE %s\n",
+ strcat(line, "#undef\tVALUE_ARG\n");
+ sprintf(line+strlen(line), "#define\tVALUE_ARG %s\n", Alts[1]);
+ strcat(line, "#undef\tVALUE_LIST\n");
+ sprintf(line+strlen(line), "#define\tVALUE_LIST %svallist\n", Alts[1]);
+ sprintf(line+strlen(line), "#undef NOTMEMTYPE\n");
+ sprintf(line+strlen(line), "#define NOTMEMTYPE %s\n",
(wasmasktype)? "unsigned": "");
- (void) strcat(line, "#undef\tNOTMEMBER\n");
+ strcat(line, "#undef\tNOTMEMBER\n");
if (wasmasktype)
- (void) strcat(line, "#define\tNOTMEMBER notmaskmember\n");
+ strcat(line, "#define\tNOTMEMBER notmaskmember\n");
else
- (void) strcat(line, "#define\tNOTMEMBER notmember\n");
+ strcat(line, "#define\tNOTMEMBER notmember\n");
putbackline(line);
}
@@ -294,16 +294,16 @@ char *word;
*out = '\0';
for (i = 0; i < Nalts; i++) {
word = Alts[i];
- (void) strcat(out, word);
+ strcat(out, word);
if (i < Nalts-2)
- (void) strcat(out, ",\n.S ");
+ strcat(out, ",\n.S ");
if (i == Nalts-2)
- (void) strcat(out, "\nor\n.S ");
+ strcat(out, "\nor\n.S ");
}
if (Nalts > 1)
- (void) strcat(out, " ");
- (void) strcat(out, ",\n");
+ strcat(out, " ");
+ strcat(out, ",\n");
return(strlen(out));
}
diff --git a/xts5/src/bin/mc/expand.c b/xts5/src/bin/mc/expand.c
index 47aeab00..311fef0e 100644
--- a/xts5/src/bin/mc/expand.c
+++ b/xts5/src/bin/mc/expand.c
@@ -155,7 +155,7 @@ void
mepend(buf)
char *buf;
{
- (void) fprintf(FpBanner, " */\n");
+ fprintf(FpBanner, " */\n");
outfile(FpBanner);
outfile(FpExp);
fclose(FpExp);
diff --git a/xts5/src/bin/mc/files.c b/xts5/src/bin/mc/files.c
index d1bdcfed..ee88a400 100644
--- a/xts5/src/bin/mc/files.c
+++ b/xts5/src/bin/mc/files.c
@@ -156,7 +156,7 @@ static int firsttime = 1;
fp = NULL;
} else {
if ((fp = fopen(Filename, "r")) == NULL) {
- (void) fprintf(stderr, "Could not open %s\n", Filename);
+ fprintf(stderr, "Could not open %s\n", Filename);
errexit();
}
}
@@ -179,7 +179,7 @@ char buf[BUFSIZ];
/*
* Look for a corresponding file with name lib/mc/*.mc .
*/
- (void) sprintf(buf, "mc/%s", file);
+ sprintf(buf, "mc/%s", file);
file = buf;
if (strcmp(file+strlen(file)-3, ".mc") != 0) {
/*
@@ -220,7 +220,7 @@ char *tmpfile;
snprintf(tmpfile, PATH_MAX, "%s.%d", file, (int)getpid());
if ((fp = fopen(tmpfile, "w+")) == NULL) {
- (void) fprintf(stderr, "Could not open %s\n", tmpfile);
+ fprintf(stderr, "Could not open %s\n", tmpfile);
errexit();
}
@@ -251,7 +251,7 @@ extern int Cmdname;
if (!fout) {
if (OutFileName) {
if ((fout = fopen(OutFileName, "w")) == NULL) {
- (void) fprintf(stderr, "Could not open %s for output\n", OutFileName);
+ fprintf(stderr, "Could not open %s for output\n", OutFileName);
errexit();
}
ofilename = OutFileName;
@@ -272,12 +272,12 @@ extern int Cmdname;
while (fgets(buf, BUFSIZ, fp) != NULL) {
olineno++;
if (buf[0] == '>' && buf[1] == '>' && buf[2] == 'G')
- (void) sprintf(buf, "#line %d \"%s\"\n", olineno+1, ofilename);
+ sprintf(buf, "#line %d \"%s\"\n", olineno+1, ofilename);
fputs(buf, fout);
}
} else {
while ((n = fread(buf, sizeof(char), BUFSIZ, fp)) > 0)
- (void) fwrite(buf, n, 1, fout);
+ fwrite(buf, n, 1, fout);
}
}
@@ -286,7 +286,7 @@ remfiles()
int i;
for (i = 0; i < Filetind; i++) {
- (void) unlink(Filetemp[i]);
+ unlink(Filetemp[i]);
free(Filetemp[i]);
Filetemp[i] = NULL;
}
@@ -318,7 +318,7 @@ int savlineno;
path = mcpath(name);
if ((fp = fopen(path, "r")) == NULL) {
err("");
- (void) fprintf(stderr, "Cannot open include file %s\n", name);
+ fprintf(stderr, "Cannot open include file %s\n", name);
errexit();
}
}
@@ -330,7 +330,7 @@ int savlineno;
dohook(name, HOOK_INCSTART);
dosections(fp, bp);
- (void) fclose(fp);
+ fclose(fp);
dohook(name, HOOK_INCEND);
Filename = savfilename;
@@ -370,18 +370,18 @@ int size;
rp = getenv("TET_ROOT");
if (rp == NULL) {
- (void) fprintf(stderr, "TET_ROOT not set in environment\n");
+ fprintf(stderr, "TET_ROOT not set in environment\n");
errexit();
}
size = strlen(rp)+strlen(MC_LOC)+strlen(file)+1;
path = malloc((size_t)size);
if (path == NULL) {
- (void) fprintf(stderr, "Out of memory\n");
+ fprintf(stderr, "Out of memory\n");
errexit();
}
- (void) strcpy(path, rp);
- (void) strcat(path, MC_LOC);
- (void) strcat(path, file);
+ strcpy(path, rp);
+ strcat(path, MC_LOC);
+ strcat(path, file);
return(path);
}
diff --git a/xts5/src/bin/mc/gccomps.c b/xts5/src/bin/mc/gccomps.c
index 77c02c4d..75cd98cc 100644
--- a/xts5/src/bin/mc/gccomps.c
+++ b/xts5/src/bin/mc/gccomps.c
@@ -172,11 +172,11 @@ char *cp;
if (lp == gclookup+NGCCOMP) {
err("");
- (void) fprintf(stderr, "Unrecognised gc component name %s\n", cp);
+ fprintf(stderr, "Unrecognised gc component name %s\n", cp);
errexit();
}
- (void) sprintf(buf, "gc/%.9s.mc\n", lp->include);
+ sprintf(buf, "gc/%.9s.mc\n", lp->include);
includefile(buf, buf);
}
}
diff --git a/xts5/src/bin/mc/ma.c b/xts5/src/bin/mc/ma.c
index b3448bc0..8e7eec6b 100644
--- a/xts5/src/bin/mc/ma.c
+++ b/xts5/src/bin/mc/ma.c
@@ -149,7 +149,7 @@ maheader(fp, buf)
FILE *fp;
char *buf;
{
- (void) fprintf(FpText, ".TH %s %s\n", State.name, State.chap);
+ fprintf(FpText, ".TH %s %s\n", State.name, State.chap);
skip(fp, buf);
}
@@ -158,10 +158,10 @@ maassertion(fp, buf)
FILE *fp;
char *buf;
{
- (void) fprintf(FpText, ".TI ");
+ fprintf(FpText, ".TI ");
if (State.category != CAT_NONE)
- (void) fprintf(FpText, "%c ", (char)State.category);
- (void) fprintf(FpText, "\\\" %s-%d\n",
+ fprintf(FpText, "%c ", (char)State.category);
+ fprintf(FpText, "\\\" %s-%d\n",
State.name, State.assertion);
echon(fp, buf, FpText);
if (State.category == CAT_B || State.category == CAT_D) {
@@ -175,7 +175,7 @@ madefassertion(fp, buf)
FILE *fp;
char *buf;
{
- (void) fprintf(FpText, ".TI def \\\" %s-%d\n", State.name, State.assertion);
+ fprintf(FpText, ".TI def \\\" %s-%d\n", State.name, State.assertion);
echon(fp, buf, FpText);
}
@@ -199,7 +199,7 @@ char *buf;
if (hflag) {
if (sflag) {
FpHeader = cretmpfile(F_HEADER, NULL);
- (void) fprintf(FpHeader, ".so head.t\n");
+ fprintf(FpHeader, ".so head.t\n");
outfile(FpHeader);
} else {
outcopy(F_STDHEADER);
diff --git a/xts5/src/bin/mc/main.c b/xts5/src/bin/mc/main.c
index 91e90eeb..45a502da 100644
--- a/xts5/src/bin/mc/main.c
+++ b/xts5/src/bin/mc/main.c
@@ -257,8 +257,8 @@ newcmd:
argv[0] = optarg;
goto newcmd;
case '?':
- (void) fprintf(stderr, "Invalid option\n");
- (void) fprintf(stderr, "%s\n", cip->usage);
+ fprintf(stderr, "Invalid option\n");
+ fprintf(stderr, "%s\n", cip->usage);
errexit();
break;
}
@@ -302,7 +302,7 @@ newcmd:
dosections(FpSource, Ibuf);
dodefaults(Ibuf);
- (void) fclose(FpSource);
+ fclose(FpSource);
dohook((char*)0, HOOK_END);
remfiles();
@@ -375,7 +375,7 @@ char *line;
err("Internal error: one line already pushed back\n");
errexit();
}
- (void) strcpy(putbackbuf, line);
+ strcpy(putbackbuf, line);
}
/*
@@ -406,9 +406,9 @@ char *np;
State.sectype == SEC_DEFASSERT) {
if (cp != line)
*np++ = '\n';
- (void) strcpy(np, ".F "); np += 3;
+ strcpy(np, ".F "); np += 3;
}
- (void) strcpy(np, State.name); np += strlen(State.name);
+ strcpy(np, State.name); np += strlen(State.name);
cp += 5;/* len of xname XXX */
if (State.sectype == SEC_ASSERTION ||
State.sectype == SEC_DEFASSERT) {
@@ -436,7 +436,7 @@ char *np;
}
}
*np++ = '\0';
- (void) strcpy(line, buf);
+ strcpy(line, buf);
}
/*
@@ -483,7 +483,7 @@ char *bp;
bp = malloc((size_t)(strlen(s)+1));
if (bp)
- (void) strcpy(bp, s);
+ strcpy(bp, s);
return(bp);
}
diff --git a/xts5/src/bin/mc/make.c b/xts5/src/bin/mc/make.c
index 2b7d980e..1239be9a 100644
--- a/xts5/src/bin/mc/make.c
+++ b/xts5/src/bin/mc/make.c
@@ -197,84 +197,84 @@ char *lp;
int i;
int linepos;
- (void) fprintf(FpDefines, "SOURCES=");
+ fprintf(FpDefines, "SOURCES=");
linepos = strlen("SOURCES=");
for (i = 0; lp = getmclistitem(Sources, i); i++) {
linepos += strlen(lp);
if (linepos > CFILELINELEN) {
- (void) fprintf(FpDefines, "\\\n\t");
+ fprintf(FpDefines, "\\\n\t");
linepos = 8;
}
- (void) fprintf(FpDefines, "%s ", lp);
+ fprintf(FpDefines, "%s ", lp);
}
- (void) fprintf(FpDefines, "\n");
- (void) fprintf(FpDefines, "CFILES=Test.c ");
+ fprintf(FpDefines, "\n");
+ fprintf(FpDefines, "CFILES=Test.c ");
linepos = strlen("CFILES=Test.c ");
for (i = 0; lp = getmclistitem(filenames, i); i++) {
linepos += strlen(lp);
if (linepos > CFILELINELEN) {
- (void) fprintf(FpDefines, "\\\n\t");
+ fprintf(FpDefines, "\\\n\t");
linepos = 8;
}
- (void) fprintf(FpDefines, "%s ", lp);
+ fprintf(FpDefines, "%s ", lp);
}
- (void) fprintf(FpDefines, "\n");
+ fprintf(FpDefines, "\n");
- (void) fprintf(FpDefines, "OFILES=Test.o ");
+ fprintf(FpDefines, "OFILES=Test.o ");
linepos = strlen("OFILES=Test.o ");
for (i = 0; lp = getmclistitem(filenames, i); i++) {
linepos += strlen(lp);
if (linepos > CFILELINELEN) {
- (void) fprintf(FpDefines, "\\\n\t");
+ fprintf(FpDefines, "\\\n\t");
linepos = 8;
}
/* Convert to dot-o */
lp[strlen(lp)-1] = 'o';
- (void) fprintf(FpDefines, "%s ", lp);
+ fprintf(FpDefines, "%s ", lp);
}
- (void) fprintf(FpDefines, "\n");
+ fprintf(FpDefines, "\n");
if (Settings.macro) {
- (void) fprintf(FpDefines, "MOFILES=MTest.o ");
+ fprintf(FpDefines, "MOFILES=MTest.o ");
linepos = strlen("OFILES=MTest.o ");
for (i = 0; lp = getmclistitem(filenames, i); i++) {
linepos += strlen(lp);
if (linepos > CFILELINELEN) {
- (void) fprintf(FpDefines, "\\\n\t");
+ fprintf(FpDefines, "\\\n\t");
linepos = 8;
}
/* Convert to dot-o */
lp[strlen(lp)-1] = 'o';
- (void) fprintf(FpDefines, "%s ", lp);
+ fprintf(FpDefines, "%s ", lp);
}
- (void) fprintf(FpDefines, "\n");
+ fprintf(FpDefines, "\n");
}
- (void) fprintf(FpDefines, "LOFILES=link.o ");
+ fprintf(FpDefines, "LOFILES=link.o ");
if (Settings.macro)
fprintf(FpDefines, "mlink.o ");
linepos = strlen("LOFILES=link.o ");
for (i = 0; lp = getmclistitem(filenames, i); i++) {
linepos += strlen(lp);
if (linepos > CFILELINELEN) {
- (void) fprintf(FpDefines, "\\\n\t");
+ fprintf(FpDefines, "\\\n\t");
linepos = 8;
}
/* Convert to dot-o */
lp[strlen(lp)-1] = 'o';
- (void) fprintf(FpDefines, "%s ", lp);
+ fprintf(FpDefines, "%s ", lp);
}
- (void) fprintf(FpDefines, "\n");
+ fprintf(FpDefines, "\n");
- (void) fprintf(FpDefines, "LINKOBJ=%s.o\n", name10lc(State.name));
- (void) fprintf(FpDefines, "LINKEXEC=%s\n", name10lc(State.name));
+ fprintf(FpDefines, "LINKOBJ=%s.o\n", name10lc(State.name));
+ fprintf(FpDefines, "LINKEXEC=%s\n", name10lc(State.name));
- (void) fprintf(FpDefines, "\n\n");
+ fprintf(FpDefines, "\n\n");
/*
* Now the makefile is output using the saved information and
@@ -378,8 +378,8 @@ char *buf;
* built for.
*/
if (State.name) {
- (void) fprintf(FpDefines, "#\n# Makefile for %s\n", State.name);
- (void) fprintf(FpDefines, "#\n\n");
+ fprintf(FpDefines, "#\n# Makefile for %s\n", State.name);
+ fprintf(FpDefines, "#\n\n");
}
skip(fp, buf);
}
@@ -436,7 +436,7 @@ struct mclist *mclp;
mclp = (struct mclist *)malloc(sizeof(struct mclist)+MCLINIT*sizeof(char*));
if (mclp == NULL) {
- (void) fprintf(stderr, "Out of memory\n");
+ fprintf(stderr, "Out of memory\n");
errexit();
}
@@ -464,7 +464,7 @@ int size;
size = sizeof(struct mclist) + (list->size-1)*sizeof(char*);
list = (struct mclist *)realloc((char*)list, (unsigned)size);
if (list == NULL) {
- (void) fprintf(stderr, "Out of memory\n");
+ fprintf(stderr, "Out of memory\n");
errexit();
}
}
diff --git a/xts5/src/bin/mc/mas.c b/xts5/src/bin/mc/mas.c
index 491d93ac..3621a00b 100644
--- a/xts5/src/bin/mc/mas.c
+++ b/xts5/src/bin/mc/mas.c
@@ -153,7 +153,7 @@ masheader(fp, buf)
FILE *fp;
char *buf;
{
- (void) fprintf(FpText, ">>TITLE %s %s\n", State.name, State.chap);
+ fprintf(FpText, ">>TITLE %s %s\n", State.name, State.chap);
skip(fp, buf);
}
@@ -162,13 +162,13 @@ masassertion(fp, buf)
FILE *fp;
char *buf;
{
- (void) fprintf(FpText, ">>ASSERTION ");
+ fprintf(FpText, ">>ASSERTION ");
if (State.category != CAT_NONE)
- (void) fprintf(FpText, "%c ", (char)State.category);
- (void) fprintf(FpText, "%s-%d\n",
+ fprintf(FpText, "%c ", (char)State.category);
+ fprintf(FpText, "%s-%d\n",
State.name, State.assertion);
assertfill(fp, buf, FpText, "");
- (void) fprintf(FpText, "\n");
+ fprintf(FpText, "\n");
}
void
@@ -176,7 +176,7 @@ masstrategy(fp, buf)
FILE *fp;
char *buf;
{
- (void) fprintf(FpText, ">>STRATEGY\n");
+ fprintf(FpText, ">>STRATEGY\n");
echon(fp, buf, FpText);
}
@@ -185,7 +185,7 @@ masdefassertion(fp, buf)
FILE *fp;
char *buf;
{
- (void) fprintf(FpText, ">>ASSERTION def %s-%d\n",
+ fprintf(FpText, ">>ASSERTION def %s-%d\n",
State.name, State.assertion);
echon(fp, buf, FpText);
}
diff --git a/xts5/src/bin/mc/sections.c b/xts5/src/bin/mc/sections.c
index 047ffbff..5633a388 100644
--- a/xts5/src/bin/mc/sections.c
+++ b/xts5/src/bin/mc/sections.c
@@ -408,7 +408,7 @@ static char *reasons[] = {
newline(fp, buf);
} else {
putbackline(buf);
- (void) strcpy(buf, line);
+ strcpy(buf, line);
State.defaultreq = NEED_STRAT|NEED_CODE;
do1sec(fp, buf, SEC_ASSERTION);
}
@@ -431,7 +431,7 @@ int i;
State.sectype = sec;
if (sec >= NSEC) {
- (void) fprintf(stderr, "Internal error: invalid command\n");
+ fprintf(stderr, "Internal error: invalid command\n");
errexit();
}
@@ -537,11 +537,11 @@ char *buf;
int hook;
{
if (hook >= NHOOK) {
- (void) fprintf(stderr, "Internal error: invalid hook\n");
+ fprintf(stderr, "Internal error: invalid hook\n");
errexit();
}
if (Cmdname >= NCMDS) {
- (void) fprintf(stderr, "Internal error: command not implemented\n");
+ fprintf(stderr, "Internal error: command not implemented\n");
errexit();
}
@@ -619,28 +619,28 @@ char *tmpfile;
switch (State.category) {
case CAT_B: case CAT_D: /* Untested */
if (needed & NEED_STRAT) {
- (void) fprintf(fp, ">>STRATEGY\n");
- (void) fprintf(fp, "Report UNTESTED\n");
+ fprintf(fp, ">>STRATEGY\n");
+ fprintf(fp, "Report UNTESTED\n");
}
if (needed & NEED_CODE) {
- (void) fprintf(fp, ">>CODE\n\n");
+ fprintf(fp, ">>CODE\n\n");
/*
- (void) fprintf(fp, "\treport(\"%s\");\n", State.reason);
+ fprintf(fp, "\treport(\"%s\");\n", State.reason);
*/
- (void) fprintf(fp, "\tUNTESTED;\n");
+ fprintf(fp, "\tUNTESTED;\n");
}
break;
default: /* No code written */
if (needed & NEED_STRAT) {
- (void) fprintf(fp, ">>STRATEGY\n");
+ fprintf(fp, ">>STRATEGY\n");
if (needed & NEED_CODE)
- (void) fprintf(fp, "Report that no code has been written for this test.\n");
+ fprintf(fp, "Report that no code has been written for this test.\n");
else
- (void) fprintf(fp, "No strategy has been written for this test\n");
+ fprintf(fp, "No strategy has been written for this test\n");
}
if (needed & NEED_CODE) {
- (void) fprintf(fp, ">>CODE\n");
- (void) fprintf(fp, "\treport(\"No code written for this assertion.\");\n");
+ fprintf(fp, ">>CODE\n");
+ fprintf(fp, "\treport(\"No code written for this assertion.\");\n");
}
break;
}
diff --git a/xts5/src/bin/mc/set.c b/xts5/src/bin/mc/set.c
index 3271ff62..8a0d82a6 100644
--- a/xts5/src/bin/mc/set.c
+++ b/xts5/src/bin/mc/set.c
@@ -118,7 +118,7 @@ char *bp;
char *tok;
char *arg1;
- (void) strtok(bp, SEPS);
+ strtok(bp, SEPS);
tok = strtok((char *)0, SEPS);
arg1 = strtok((char *)0, SEPS);
diff --git a/xts5/src/bin/mc/shortname.c b/xts5/src/bin/mc/shortname.c
index 1ba22b1a..ed394d61 100644
--- a/xts5/src/bin/mc/shortname.c
+++ b/xts5/src/bin/mc/shortname.c
@@ -150,23 +150,23 @@ int n;
cp = strinstr(name, "Background");
if (cp) {
- (void) strcpy(cp, "Bg");
- (void) strcpy(cp+2, cp+10);
+ strcpy(cp, "Bg");
+ strcpy(cp+2, cp+10);
}
cp = strinstr(name, "Subwindow");
if (cp) {
- (void) strcpy(cp, "Sbw");
- (void) strcpy(cp+3, cp+9);
+ strcpy(cp, "Sbw");
+ strcpy(cp+3, cp+9);
}
cp = strinstr(name, "String");
if (cp) {
- (void) strcpy(cp, "Str");
- (void) strcpy(cp+3, cp+6);
+ strcpy(cp, "Str");
+ strcpy(cp+3, cp+6);
}
cp = strinstr(name, "Window");
if (cp) {
- (void) strcpy(cp, "Wdw");
- (void) strcpy(cp+3, cp+6);
+ strcpy(cp, "Wdw");
+ strcpy(cp+3, cp+6);
}
/*
diff --git a/xts5/src/lib/block.c b/xts5/src/lib/block.c
index f34ee53d..a65177ed 100644
--- a/xts5/src/lib/block.c
+++ b/xts5/src/lib/block.c
@@ -193,7 +193,7 @@ Block_Info *info;
}
if (setjmp(jumptohere)) {
delete("Timeout in block routine");
- (void) unlink(block_file);
+ unlink(block_file);
return(-1);
}
parent_status = 1;
@@ -201,7 +201,7 @@ Block_Info *info;
/*
* try removing block file just in case it still exists...
*/
- (void) unlink(block_file);
+ unlink(block_file);
/*
* check for problems in block_parent_proc
*/
@@ -292,7 +292,7 @@ block_child_proc()
static void
block_parent_proc()
{
- (void) signal(SIGALRM, block_alarm);
+ signal(SIGALRM, block_alarm);
alarm(TIMEOUT_TIME);
parent_status = blocker(gdisplay, ginfo);
alarm(0);
diff --git a/xts5/src/lib/checkarea.c b/xts5/src/lib/checkarea.c
index 0cd23a2f..5b3041ae 100644
--- a/xts5/src/lib/checkarea.c
+++ b/xts5/src/lib/checkarea.c
@@ -293,7 +293,7 @@ extern int Errnum;
/* Making up an error file should be a subroutine.. */
sprintf(name, "Err%04d.err", Errnum++);
report("See file %s for details", name);
- (void) unlink(name);
+ unlink(name);
dumpimage(bad, name, (struct area *)0);
dumpimage(good, name, (struct area *)0);
diff --git a/xts5/src/lib/delete.c b/xts5/src/lib/delete.c
index cdddc7a7..e5bcefcd 100644
--- a/xts5/src/lib/delete.c
+++ b/xts5/src/lib/delete.c
@@ -168,7 +168,7 @@ va_list args;
if (mess && *mess) {
- (void) vsprintf(buf, mess, args);
+ vsprintf(buf, mess, args);
report(buf);
} else
report("Test deleted");
diff --git a/xts5/src/lib/events.c b/xts5/src/lib/events.c
index 99f473a6..add496a1 100644
--- a/xts5/src/lib/events.c
+++ b/xts5/src/lib/events.c
@@ -141,7 +141,7 @@ int *dest_y_return;
{
Window window;
- (void) XTranslateCoordinates(display, src_w, dest_w, src_x, src_y, dest_x_return, dest_y_return, &window);
+ XTranslateCoordinates(display, src_w, dest_w, src_x, src_y, dest_x_return, dest_y_return, &window);
}
/*
diff --git a/xts5/src/lib/ex_startup.c b/xts5/src/lib/ex_startup.c
index 58358c6c..b077ff75 100644
--- a/xts5/src/lib/ex_startup.c
+++ b/xts5/src/lib/ex_startup.c
@@ -197,8 +197,8 @@ extern int io_err();
/*
* Set up the error handlers.
*/
- (void) XSetErrorHandler(unexp_err);
- (void) XSetIOErrorHandler(io_err);
+ XSetErrorHandler(unexp_err);
+ XSetIOErrorHandler(io_err);
/*
* Set up the default resources for error tests. At present
diff --git a/xts5/src/lib/makeimg.c b/xts5/src/lib/makeimg.c
index f3917e85..253b5dda 100644
--- a/xts5/src/lib/makeimg.c
+++ b/xts5/src/lib/makeimg.c
@@ -182,7 +182,7 @@ unsigned long pixel;
for (x = 0; x < ximage->width; x++)
for (y = 0; y < ximage->height; y++)
- (void) XPutPixel(ximage, x, y, pixel);
+ XPutPixel(ximage, x, y, pixel);
}
/*
@@ -200,5 +200,5 @@ unsigned long pixel;
for (x = 0; x < ximage->width; x += 5)
for (y = 0; y < ximage->height; y++)
- (void) XPutPixel(ximage, x, y, pixel);
+ XPutPixel(ximage, x, y, pixel);
}
diff --git a/xts5/src/lib/pointer.c b/xts5/src/lib/pointer.c
index d48be251..ea364d87 100644
--- a/xts5/src/lib/pointer.c
+++ b/xts5/src/lib/pointer.c
@@ -150,11 +150,11 @@ int dest_y;
}
/* Save initial pointer location. */
- (void) XQueryPointer(display, DRW(display), &(ptr->oroot), &wtmp, &(ptr->ox), &(ptr->oy), &itmp, &itmp, &uitmp);
+ XQueryPointer(display, DRW(display), &(ptr->oroot), &wtmp, &(ptr->ox), &(ptr->oy), &itmp, &itmp, &uitmp);
/* Warp pointer to window. */
XWarpPointer(display, None, dest_w, 0, 0, 0, 0, dest_x, dest_y);
/* Get new pointer location. */
- (void) XQueryPointer(display, DRW(display), &(ptr->nroot), &wtmp, &(ptr->nx), &(ptr->ny), &itmp, &itmp, &uitmp);
+ XQueryPointer(display, DRW(display), &(ptr->nroot), &wtmp, &(ptr->nx), &(ptr->ny), &itmp, &itmp, &uitmp);
regid(display, (union regtypes *)&ptr, REG_POINTER);
return(ptr);
@@ -175,7 +175,7 @@ PointerPlace *ptr;
int itmp;
unsigned int uitmp;
- (void) XQueryPointer(display, DRW(display), &root, &wtmp, &x, &y, &itmp, &itmp, &uitmp);
+ XQueryPointer(display, DRW(display), &root, &wtmp, &x, &y, &itmp, &itmp, &uitmp);
if (root != ptr->nroot || x != ptr->nx || y != ptr->ny)
return(True);
else
@@ -209,7 +209,7 @@ PointerPlace *ptr;
int itmp;
unsigned int uitmp;
- (void) XQueryPointer(display, DRW(display), &root, &wtmp, &x, &y, &itmp, &itmp, &uitmp);
+ XQueryPointer(display, DRW(display), &root, &wtmp, &x, &y, &itmp, &itmp, &uitmp);
ptr->nx = x;
ptr->ny = y;
}
diff --git a/xts5/src/lib/report.c b/xts5/src/lib/report.c
index 43b24934..669ed905 100644
--- a/xts5/src/lib/report.c
+++ b/xts5/src/lib/report.c
@@ -174,8 +174,8 @@ va_list args;
va_start(args);
#endif
- (void) strcpy(buf, "REPORT: ");
- (void) vsprintf(buf+strlen("REPORT: "), fmt, args);
+ strcpy(buf, "REPORT: ");
+ vsprintf(buf+strlen("REPORT: "), fmt, args);
tet_infoline(buf);
va_end(args);
@@ -243,8 +243,8 @@ va_list args;
va_start(args);
#endif
- (void) strcpy(buf, "TRACE: ");
- (void) vsprintf(buf+strlen("TRACE: "), fmt, args);
+ strcpy(buf, "TRACE: ");
+ vsprintf(buf+strlen("TRACE: "), fmt, args);
tet_infoline(buf);
va_end(args);
@@ -273,8 +273,8 @@ va_list args;
va_start(args);
#endif
- (void) strcpy(buf, "CHECK: ");
- (void) vsprintf(buf+strlen("CHECK: "), fmt, args);
+ strcpy(buf, "CHECK: ");
+ vsprintf(buf+strlen("CHECK: "), fmt, args);
tet_infoline(buf);
va_end(args);
@@ -304,8 +304,8 @@ va_list args;
va_start(args);
#endif
- (void) strcpy(buf, "DEBUG: ");
- (void) vsprintf(buf+strlen("DEBUG: "), fmt, args);
+ strcpy(buf, "DEBUG: ");
+ vsprintf(buf+strlen("DEBUG: "), fmt, args);
tet_infoline(buf);
va_end(args);
@@ -340,8 +340,8 @@ va_list args;
if (purpose_reported == 0)
report_purpose((tet_thistest == 0) ? 1: tet_thistest);
- (void) strcpy(buf, "REPORT: ");
- (void) vsprintf(buf+strlen("REPORT: "), fmt, args);
+ strcpy(buf, "REPORT: ");
+ vsprintf(buf+strlen("REPORT: "), fmt, args);
tet_infoline(buf);
va_end(args);
diff --git a/xts5/src/lib/rpt.c b/xts5/src/lib/rpt.c
index d74053a3..bbf49ade 100644
--- a/xts5/src/lib/rpt.c
+++ b/xts5/src/lib/rpt.c
@@ -163,7 +163,7 @@ va_list args;
if (mess && *mess) {
- (void) vsprintf(buf, mess, args);
+ vsprintf(buf, mess, args);
report(buf);
} else
report("Test unsupported");
@@ -196,7 +196,7 @@ va_list args;
if (mess && *mess) {
- (void) vsprintf(buf, mess, args);
+ vsprintf(buf, mess, args);
report(buf);
} else
report("Test not in use");
@@ -229,7 +229,7 @@ va_list args;
if (mess && *mess) {
- (void) vsprintf(buf, mess, args);
+ vsprintf(buf, mess, args);
report(buf);
} else
report("Test is untested");
diff --git a/xts5/src/lib/savimage.c b/xts5/src/lib/savimage.c
index 3a43550a..239d172f 100644
--- a/xts5/src/lib/savimage.c
+++ b/xts5/src/lib/savimage.c
@@ -184,7 +184,7 @@ unsigned long pix1, pix2;
, x, y, pix1, pix2);
sprintf(name, "Err%04d.err", Errnum++);
report("See file %s for details", name);
- (void) unlink(name);
+ unlink(name);
dumpimage(newim, name, (struct area *)0);
dumpimage(im, name, (struct area *)0);
XDestroyImage(newim);
diff --git a/xts5/src/lib/settimeout.c b/xts5/src/lib/settimeout.c
index 76c50706..621f7f09 100644
--- a/xts5/src/lib/settimeout.c
+++ b/xts5/src/lib/settimeout.c
@@ -147,12 +147,12 @@ struct sigaction act;
#else
act.sa_handler = alrm_exit;
act.sa_flags = 0;
- (void) sigemptyset(&act.sa_mask);
+ sigemptyset(&act.sa_mask);
if (sigaction(SIGALRM, &act, &oact) == -1)
delete("Could not set signal handler in settimeout");
#endif
- (void) alarm((unsigned long)to);
+ alarm((unsigned long)to);
}
/*
@@ -168,7 +168,7 @@ unsigned long timeleft;
timeleft = alarm(0);
#if OLDSIGNALS
- (void) signal(SIGALRM, osig);
+ signal(SIGALRM, osig);
#else
if (sigaction(SIGALRM, &oact, (struct sigaction *)0) == -1)
delete("Could not reset signal handler in cleartimeout");
diff --git a/xts5/src/lib/startup.c b/xts5/src/lib/startup.c
index 54744c5d..8f3bcb18 100644
--- a/xts5/src/lib/startup.c
+++ b/xts5/src/lib/startup.c
@@ -210,7 +210,7 @@ extern int io_err();
* Put out the NAME info line for the report generator.
*/
/*APTEST
- (void) sprintf(buf, "TRACE:NAME: %s", TestName);
+ sprintf(buf, "TRACE:NAME: %s", TestName);
tet_infoline(buf);
*/
@@ -258,15 +258,15 @@ extern int io_err();
/*
* Set up the error handlers.
*/
- (void) XSetErrorHandler(unexp_err);
- (void) XSetIOErrorHandler(io_err);
+ XSetErrorHandler(unexp_err);
+ XSetIOErrorHandler(io_err);
/*
* Initialize the errors for the input device extension.
*/
#ifdef INPUTEXTENSION
- (void) init_xinput(Dsp);
+ init_xinput(Dsp);
#endif
/*
diff --git a/xts5/src/lib/tpstartup.c b/xts5/src/lib/tpstartup.c
index 6ef0785b..d233a9c2 100644
--- a/xts5/src/lib/tpstartup.c
+++ b/xts5/src/lib/tpstartup.c
@@ -141,8 +141,8 @@ extern int unexp_err();
extern int io_err();
#endif
- (void) XSetErrorHandler(unexp_err);
- (void) XSetIOErrorHandler(io_err);
+ XSetErrorHandler(unexp_err);
+ XSetIOErrorHandler(io_err);
resetdelete();
diff --git a/xts5/src/lib/verimage.c b/xts5/src/lib/verimage.c
index 165cb7b0..0db947e4 100644
--- a/xts5/src/lib/verimage.c
+++ b/xts5/src/lib/verimage.c
@@ -181,7 +181,7 @@ extern int CurVinf;
}
ic = tet_testlist[tet_thistest-1].icref;
- (void) sprintf(name, "a%d.dat", ic);
+ sprintf(name, "a%d.dat", ic);
#ifdef GENERATE_PIXMAPS
if (tet_thistest != lasttest || CurVinf == lastvinf) {
@@ -207,7 +207,7 @@ extern int CurVinf;
* here.
*/
if (config.save_server_image) {
- (void) sprintf(name, "a%d.sav", ic);
+ sprintf(name, "a%d.sav", ic);
dumpimage(imp, name, ap);
trace("Created server image file %s", name);
}
@@ -303,8 +303,8 @@ ok:
FILE *errfp;
report("A total of %d out of %d pixels were bad", bad, good+bad);
- (void) sprintf(errfile, "Err%04d.err", Errnum);
- (void) unlink(errfile);
+ sprintf(errfile, "Err%04d.err", Errnum);
+ unlink(errfile);
dumpimage(imp, errfile, ap);
newpos = ftell(fp);
diff --git a/xts5/src/lib/winh.c b/xts5/src/lib/winh.c
index d57ff2fa..a58f3c3e 100644
--- a/xts5/src/lib/winh.c
+++ b/xts5/src/lib/winh.c
@@ -446,7 +446,7 @@ long winhmask;
Winh *winh;
if (winh_qdel != (Winhe *) NULL)
- (void) free_eventlist();
+ free_eventlist();
if (event == (XEvent *) NULL)
return(0);
if ((_eindex_ = winh_eventindex(event->type)) == -1)
@@ -874,7 +874,7 @@ Display *display;
Winh *winh;
Winh *awinh;
- (void) free_eventlist();
+ free_eventlist();
if ((winh = (Winh *) winhmalloc(sizeof(*winh), "initguardian")) == (Winh *) NULL)
return((Winh *) NULL);
winh->window = DRW(display);
@@ -987,12 +987,12 @@ void
winh_free(winh)
Winh *winh;
{
- (void) free_eventlist();
+ free_eventlist();
if (winh == (Winh *) NULL)
winh = guardian;
if (winh == (Winh *) NULL)
return;
- (void) winh_walk(winh, 1, _winh_free);
+ winh_walk(winh, 1, _winh_free);
guardian = (Winh *) NULL;
}
@@ -1272,7 +1272,7 @@ Winh *winh;
if (_winh_walk_first_time_) {
_winh_walk_first_time_ = 0;
- (void) fprintf(stderr, "\n\n\n");
+ fprintf(stderr, "\n\n\n");
}
if (winh == (Winh *) NULL)
return(-1);
@@ -1280,52 +1280,52 @@ Winh *winh;
for (i = 0; i < (NELEM(in)-1) && i < winh->depth; i++)
in[i] = '\t';
in[i] = '\0';
- (void) fprintf(stderr, "%s========================================\n",
+ fprintf(stderr, "%s========================================\n",
in);
if (winh->window == WINH_BAD)
- (void) fprintf(stderr, "%sWindow: None",
+ fprintf(stderr, "%sWindow: None",
in);
else
- (void) fprintf(stderr, "%sWindow: 0x%lx",
+ fprintf(stderr, "%sWindow: 0x%lx",
in, (unsigned long)winh->window);
if (winh->parent == (Winh *) NULL)
- (void) fprintf(stderr, ", Parent: None\n");
+ fprintf(stderr, ", Parent: None\n");
else
- (void) fprintf(stderr, ", Parent: 0x%lx\n", (unsigned long)winh->parent->window);
- (void) fprintf(stderr, "%sFirstborn: %s, Children: %2d\n",
+ fprintf(stderr, ", Parent: 0x%lx\n", (unsigned long)winh->parent->window);
+ fprintf(stderr, "%sFirstborn: %s, Children: %2d\n",
in,
(FIRSTBORN(winh) ? "Yes" : "No "), winh->numchildren);
- (void) fprintf(stderr, "%sValuemask: 0x%04lx, Winhmask: 0x%04lx\n",
+ fprintf(stderr, "%sValuemask: 0x%04lx, Winhmask: 0x%04lx\n",
in,
winh->valuemask, winh->winhmask);
if (winh->valuemask != 0) {
- (void) fprintf(stderr, "%sValuemask strings:\n",
+ fprintf(stderr, "%sValuemask strings:\n",
in);
for (i = 0; i<NELEM(attrinfo); i++)
if (winh->valuemask & attrinfo[i].value)
- (void) fprintf(stderr, "%s %s\n",
+ fprintf(stderr, "%s %s\n",
in,
attrinfo[i].name);
}
if (winh->winhmask != WINH_NOMASK) {
- (void) fprintf(stderr, "%sWinhmask strings:\n",
+ fprintf(stderr, "%sWinhmask strings:\n",
in);
for (i = 0; i<NELEM(winhmaskinfo); i++)
if (winh->winhmask & winhmaskinfo[i].value)
- (void) fprintf(stderr, "%s %s\n",
+ fprintf(stderr, "%s %s\n",
in,
winhmaskinfo[i].name);
}
- (void) fprintf(stderr, "%sClients: %s, Expected: %s, Delivered: %s\n",
+ fprintf(stderr, "%sClients: %s, Expected: %s, Delivered: %s\n",
in,
((winh->clients == (Winhc *) NULL) ? "No " : "Yes"),
((winh->expected == (Winhe *) NULL) ? "No " : "Yes"),
((winh->delivered == (Winhe *) NULL) ? "No " : "Yes"));
- (void) fprintf(stderr, "%sDepth: %2d, Screen: %2d\n",
+ fprintf(stderr, "%sDepth: %2d, Screen: %2d\n",
in,
winh->depth, winh->screen);
if (!(winh->winhmask & WINH_IGNORE_GEOMETRY)) {
- (void) fprintf(stderr, "%s%dx%d (%d,%d) border width: %d\n",
+ fprintf(stderr, "%s%dx%d (%d,%d) border width: %d\n",
in,
winh->winhg.area.width, winh->winhg.area.height,
winh->winhg.area.x, winh->winhg.area.y,
diff --git a/xts5/src/libXR5/r5startup.c b/xts5/src/libXR5/r5startup.c
index 49ba7676..50ea36e7 100644
--- a/xts5/src/libXR5/r5startup.c
+++ b/xts5/src/libXR5/r5startup.c
@@ -207,7 +207,7 @@ extern int io_err();
* Put out the NAME info line for the report generator.
*/
/*APTEST
- (void) sprintf(buf, "TRACE:NAME: %s", TestName);
+ sprintf(buf, "TRACE:NAME: %s", TestName);
tet_infoline(buf);
*/
@@ -256,15 +256,15 @@ extern int io_err();
/*
* Set up the error handlers.
*/
- (void) XSetErrorHandler(unexp_err);
- (void) XSetIOErrorHandler(io_err);
+ XSetErrorHandler(unexp_err);
+ XSetIOErrorHandler(io_err);
/*
* Initialize the errors for the input device extension.
*/
#ifdef INPUTEXTENSION
- (void) init_xinput(Dsp);
+ init_xinput(Dsp);
#endif
/*
diff --git a/xts5/src/libXtTest/AvsForm.c b/xts5/src/libXtTest/AvsForm.c
index bd508b26..40d63ec7 100644
--- a/xts5/src/libXtTest/AvsForm.c
+++ b/xts5/src/libXtTest/AvsForm.c
@@ -341,7 +341,7 @@ Dimension *ret_width, *ret_height;
result = XtMakeGeometryRequest(w, &request, &return_request);
if (result == XtGeometryAlmost) {
request = return_request;
- (void) XtMakeGeometryRequest(w, &request, &return_request);
+ XtMakeGeometryRequest(w, &request, &return_request);
always_resize_children = FALSE;
}
else
diff --git a/xts5/src/libXtTest/AvsForm2.c b/xts5/src/libXtTest/AvsForm2.c
index ccb73a89..b5820a19 100644
--- a/xts5/src/libXtTest/AvsForm2.c
+++ b/xts5/src/libXtTest/AvsForm2.c
@@ -310,7 +310,7 @@ Dimension *ret_width, *ret_height;
result = XtMakeGeometryRequest(w, &request, &return_request);
if (result == XtGeometryAlmost) {
request = return_request;
- (void) XtMakeGeometryRequest(w, &request, &return_request);
+ XtMakeGeometryRequest(w, &request, &return_request);
always_resize_children = FALSE;
}
else
diff --git a/xts5/src/libXtTest/AvsForm3.c b/xts5/src/libXtTest/AvsForm3.c
index 2af7875b..41d0af91 100644
--- a/xts5/src/libXtTest/AvsForm3.c
+++ b/xts5/src/libXtTest/AvsForm3.c
@@ -303,7 +303,7 @@ Dimension *ret_width, *ret_height;
result = XtMakeGeometryRequest(w, &request, &return_request);
if (result == XtGeometryAlmost) {
request = return_request;
- (void) XtMakeGeometryRequest(w, &request, &return_request);
+ XtMakeGeometryRequest(w, &request, &return_request);
always_resize_children = FALSE;
}
else
diff --git a/xts5/src/libXtTest/avs_hier.c b/xts5/src/libXtTest/avs_hier.c
index 0c1f85c9..358a0032 100644
--- a/xts5/src/libXtTest/avs_hier.c
+++ b/xts5/src/libXtTest/avs_hier.c
@@ -111,7 +111,7 @@ char *stitle, *slabel;
trace("Create boxw2 widget in panedw widget");
boxw2 = (Widget) CreateBoxWidget(panedw);
trace("Set the height and width of boxw2 widget");
- (void) ConfigureDimension(topLevel, boxw2);
+ ConfigureDimension(topLevel, boxw2);
return topLevel;
}
@@ -152,7 +152,7 @@ char *stitle, *slabel;
trace("Create boxw2 widget in panedw widget");
boxw2 = (Widget) CreateBoxWidget(panedw);
trace("Set the height and width of boxw2 widget");
- (void) ConfigureDimension(topLevel, boxw2);
+ ConfigureDimension(topLevel, boxw2);
return topLevel;
}
@@ -196,6 +196,6 @@ int argcount;
trace("Create boxw2 widget in panedw widget");
boxw2 = (Widget) CreateBoxWidget(panedw);
trace("Set the height and width of boxw2 widget");
- (void) ConfigureDimension(topLevel, boxw2);
+ ConfigureDimension(topLevel, boxw2);
return topLevel;
}
diff --git a/xts5/src/libXtTest/avs_hierd.c b/xts5/src/libXtTest/avs_hierd.c
index 9ef70849..0f6d607d 100644
--- a/xts5/src/libXtTest/avs_hierd.c
+++ b/xts5/src/libXtTest/avs_hierd.c
@@ -115,6 +115,6 @@ char *stitle, *slabel;
trace("Create boxw2 widget in panedw widget");
boxw2 = (Widget) CreateBoxWidget(panedw);
trace("Set the height and width of boxw2 widget");
- (void) ConfigureDimension(topLevel, boxw2);
+ ConfigureDimension(topLevel, boxw2);
return topLevel;
}
diff --git a/xts5/src/libXtTest/box.c b/xts5/src/libXtTest/box.c
index 3613b439..6383e593 100644
--- a/xts5/src/libXtTest/box.c
+++ b/xts5/src/libXtTest/box.c
@@ -474,7 +474,7 @@ static Boolean TryNewLayout(bbw)
* almost.
*
*/
- (void) XtMakeResizeRequest( (Widget)bbw,
+ XtMakeResizeRequest( (Widget)bbw,
proposed_width, proposed_height,
&proposed_width, &proposed_height);
return(TRUE);
@@ -575,7 +575,7 @@ static void ChangeManaged(w)
Widget w;
{
/* Reconfigure the box */
- (void) TryNewLayout((BoxWidget)w);
+ TryNewLayout((BoxWidget)w);
Resize(w);
}
diff --git a/xts5/src/libXtTest/errlook.c b/xts5/src/libXtTest/errlook.c
index 888462e2..613dfb61 100644
--- a/xts5/src/libXtTest/errlook.c
+++ b/xts5/src/libXtTest/errlook.c
@@ -323,10 +323,10 @@ int num;
for(i=0; i<NERRS; i++) {
if(errz[i].err == num) {
- (void) sprintf(foo, "%d(%s)", num, errz[i].errname);
+ sprintf(foo, "%d(%s)", num, errz[i].errname);
return foo;
}
}
- (void) sprintf(foo, "%d(error definition not known)", num);
+ sprintf(foo, "%d(error definition not known)", num);
return foo;
}
diff --git a/xts5/src/libXtTest/event.c b/xts5/src/libXtTest/event.c
index 4764a9b7..07b5d2dd 100644
--- a/xts5/src/libXtTest/event.c
+++ b/xts5/src/libXtTest/event.c
@@ -115,7 +115,7 @@ void avs_free_sem()
vsw_debug_enter("libXtTest/event.c:avs_free_sem()",0);
if(semid != -1) {
- (void) semctl(semid, 0, IPC_RMID, NULL);
+ semctl(semid, 0, IPC_RMID, NULL);
semid = -1;
}
@@ -183,7 +183,7 @@ int t;
return -1;
}
#endif
- (void) alarm((unsigned int)t);
+ alarm((unsigned int)t);
}
s2 = semop(semid, &mysembuf, 1);
diff --git a/xts5/src/libXtTest/pshpop.c b/xts5/src/libXtTest/pshpop.c
index 473c0e05..8051f61e 100644
--- a/xts5/src/libXtTest/pshpop.c
+++ b/xts5/src/libXtTest/pshpop.c
@@ -162,7 +162,7 @@ void pop_stdout()
return;
}
- (void) fflush(stdout);
+ fflush(stdout);
if (dup2(Dup_stdout,fileno(stdout)) == -1) {
sprintf(ebuf, "ERROR: pop_stdout: could not restore stdout");
tet_infoline(ebuf);
@@ -237,7 +237,7 @@ void pop_stderr()
return;
}
- (void) fflush(stderr);
+ fflush(stderr);
if (dup2(Dup_stderr,fileno(stderr)) == -1) {
sprintf(ebuf, "ERROR: pop_stderr: could not restore stderr");
tet_infoline(ebuf);
@@ -305,7 +305,7 @@ int restore_from_devnull()
return -1;
}
- (void) fflush(stdout);
+ fflush(stdout);
if (dup2(Dup_stdout,fileno(stdout)) == -1) {
sprintf(ebuf, "ERROR: restore_from_devnull: could not restore stdout");
tet_infoline(ebuf);
@@ -323,7 +323,7 @@ int restore_from_devnull()
return -1;
}
- (void) fflush(stderr);
+ fflush(stderr);
if (dup2(Dup_stderr,fileno(stderr)) == -1) {
sprintf(ebuf, "ERROR: restore_from_devnull: could not restore stderr");
tet_infoline(ebuf);
diff --git a/xts5/src/libXtTest/waitfor.c b/xts5/src/libXtTest/waitfor.c
index 2f0d36cd..2667ac4e 100644
--- a/xts5/src/libXtTest/waitfor.c
+++ b/xts5/src/libXtTest/waitfor.c
@@ -110,11 +110,11 @@ int timeout;
SIGNAL_RET(SIGALRM, SIG_DFL);
if (got_sigalrm) {
- (void) kill(pid, SIGKILL);
+ kill(pid, SIGKILL);
sleep(2);
- (void) waitpid(pid, &child, WNOHANG);
+ waitpid(pid, &child, WNOHANG);
sprintf(ebuf, "ERROR: wait_for: Timed-out waiting for child to exit.");
tet_infoline(ebuf);
tet_result(TET_FAIL);
diff --git a/xts5/src/libXtaw/Box.c b/xts5/src/libXtaw/Box.c
index f48082ee..feecbc3a 100644
--- a/xts5/src/libXtaw/Box.c
+++ b/xts5/src/libXtaw/Box.c
@@ -488,7 +488,7 @@ static Boolean TryNewLayout(bbw)
* almost.
*
*/
- (void) XtMakeResizeRequest( (Widget)bbw,
+ XtMakeResizeRequest( (Widget)bbw,
proposed_width, proposed_height,
&proposed_width, &proposed_height);
return(TRUE);
@@ -589,7 +589,7 @@ static void ChangeManaged(w)
Widget w;
{
/* Reconfigure the box */
- (void) TryNewLayout((BoxWidget)w);
+ TryNewLayout((BoxWidget)w);
Resize(w);
}
diff --git a/xts5/src/libXtaw/Form.c b/xts5/src/libXtaw/Form.c
index 17855a7a..fd88f909 100644
--- a/xts5/src/libXtaw/Form.c
+++ b/xts5/src/libXtaw/Form.c
@@ -343,7 +343,7 @@ Dimension *ret_width, *ret_height;
result = XtMakeGeometryRequest(w, &request, &return_request);
if (result == XtGeometryAlmost) {
request = return_request;
- (void) XtMakeGeometryRequest(w, &request, &return_request);
+ XtMakeGeometryRequest(w, &request, &return_request);
always_resize_children = FALSE;
}
else
diff --git a/xts5/src/libXtaw/Paned.c b/xts5/src/libXtaw/Paned.c
index 8763151c..4c2f78ed 100644
--- a/xts5/src/libXtaw/Paned.c
+++ b/xts5/src/libXtaw/Paned.c
@@ -590,7 +590,7 @@ Direction dir;
else
AssignMin(pane->size, start_size);
- if (pane->size == start_size) (void) PopPaneStack(pw);
+ if (pane->size == start_size) PopPaneStack(pw);
}
else if (rule3_ok) {
if (shrink) {
diff --git a/xts5/src/libXtaw/Viewport.c b/xts5/src/libXtaw/Viewport.c
index 88457369..22ac4166 100644
--- a/xts5/src/libXtaw/Viewport.c
+++ b/xts5/src/libXtaw/Viewport.c
@@ -277,9 +277,9 @@ static void Initialize(request, new)
return; /* If we are not forcing the bars then we are done. */
if (w->viewport.allowhoriz)
- (void) CreateScrollbar(w, True);
+ CreateScrollbar(w, True);
if (w->viewport.allowvert)
- (void) CreateScrollbar(w, False);
+ CreateScrollbar(w, False);
h_bar = w->viewport.horiz_bar;
v_bar = w->viewport.vert_bar;
@@ -564,7 +564,7 @@ static void ComputeLayout(widget, query, destroy_scrollbars)
do { /* while intended != prev */
if (query) {
- (void) XtQueryGeometry( child, &intended, &preferred );
+ XtQueryGeometry( child, &intended, &preferred );
if ( !(preferred.request_mode & CWWidth) )
preferred.width = intended.width;
if ( !(preferred.request_mode & CWHeight) )
diff --git a/xts5/src/libXtmu/CloseHook.c b/xts5/src/libXtmu/CloseHook.c
index 969cf14a..907a0e37 100644
--- a/xts5/src/libXtmu/CloseHook.c
+++ b/xts5/src/libXtmu/CloseHook.c
@@ -352,7 +352,7 @@ static Bool _MakeExtension (dpy, extensionp)
codes = XAddExtension (dpy);
if (!codes) return False;
- (void) XESetCloseDisplay (dpy, codes->extension, _DoCallbacks);
+ XESetCloseDisplay (dpy, codes->extension, _DoCallbacks);
*extensionp = codes->extension;
return True;
diff --git a/xts5/src/libXtmu/DisplayQue.c b/xts5/src/libXtmu/DisplayQue.c
index e87255be..50c22113 100644
--- a/xts5/src/libXtmu/DisplayQue.c
+++ b/xts5/src/libXtmu/DisplayQue.c
@@ -98,8 +98,8 @@ SOFTWARE.
static int _DQCloseDisplay();
-#define CallCloseCallback(q,e) (void) (*((q)->closefunc)) ((q), (e))
-#define CallFreeCallback(q) (void) (*((q)->freefunc)) ((q))
+#define CallCloseCallback(q,e) (*((q)->closefunc)) ((q), (e))
+#define CallFreeCallback(q) (*((q)->freefunc)) ((q))
/*
* XmuDQCreate - create a display queue
@@ -215,7 +215,7 @@ Bool XmuDQRemoveDisplay (q, dpy)
q->tail = e->prev; /* if at tail, then bump tail */
else
e->next->prev = e->prev; /* else splice out */
- (void) XmuRemoveCloseDisplayHook (dpy, e->closehook,
+ XmuRemoveCloseDisplayHook (dpy, e->closehook,
_DQCloseDisplay, (caddr_t) q);
free ((char *) e);
q->nentries--;
@@ -244,7 +244,7 @@ static int _DQCloseDisplay (dpy, arg)
for (e = q->head; e; e = e->next) {
if (e->display == dpy) {
if (q->closefunc) CallCloseCallback (q, e);
- (void) XmuDQRemoveDisplay (q, dpy);
+ XmuDQRemoveDisplay (q, dpy);
if (q->nentries == 0 && q->freefunc) CallFreeCallback (q);
return 1;
}
diff --git a/xts5/src/libXtmu/LocBitmap.c b/xts5/src/libXtmu/LocBitmap.c
index 55abbd66..5d57ea98 100644
--- a/xts5/src/libXtmu/LocBitmap.c
+++ b/xts5/src/libXtmu/LocBitmap.c
@@ -189,7 +189,7 @@ Pixmap XmuLocatePixmapFile (screen, name, fore, back, depth,
xrm_class[1] = NULLQUARK;
if (!XrmGetDatabase(dpy)) {
/* what a hack; need to initialize it */
- (void) XGetDefault (dpy, "", "");
+ XGetDefault (dpy, "", "");
}
if (XrmQGetResource (XrmGetDatabase(dpy), xrm_name, xrm_class,
&rep_type, &value) &&
diff --git a/xts5/src/libproto/ClientMng.c b/xts5/src/libproto/ClientMng.c
index 833e418b..c22afcf2 100644
--- a/xts5/src/libproto/ClientMng.c
+++ b/xts5/src/libproto/ClientMng.c
@@ -607,7 +607,7 @@ int cl; /* client number */
vendorlen = u.setup -> nbytesVendor;
u.setup += 1; /* can't touch information in XConnSetup
anymore.. */
- (void) strncpy (dpy -> vendor, u.vendor, vendorlen);
+ strncpy (dpy -> vendor, u.vendor, vendorlen);
u.vendor += (vendorlen + 3) & ~3;
/*
* Now iterate down setup information.....
@@ -727,7 +727,7 @@ int cl; /* client number */
OutOfMemory (dpy, setup);
return (NULL);
}
- (void) strcpy (dpy -> display_name, displaybuf);
+ strcpy (dpy -> display_name, displaybuf);
/* Set up the output buffers. */
if ((dpy -> bufptr = dpy -> buffer = (char *) Xstmalloc (OBUFSIZE)) == NULL) {
@@ -840,7 +840,7 @@ register XstDisplay * dpy;
free (dpy -> xdefaults);
- (void) free ((char *) dpy);
+ free ((char *) dpy);
}
static
@@ -872,5 +872,5 @@ int client;
XstFreeDisplayStructure(dpy);
if (tmpfd != -1)
- (void) close(tmpfd);
+ close(tmpfd);
}
diff --git a/xts5/src/libproto/ConnDis.c b/xts5/src/libproto/ConnDis.c
index 8d1513b5..9cc0dd8c 100644
--- a/xts5/src/libproto/ConnDis.c
+++ b/xts5/src/libproto/ConnDis.c
@@ -700,7 +700,7 @@ void XSetAuthorization (name, namelen, data, datalen)
if (datalen > 0) {
tmpdata = Xmalloc ((unsigned) datalen);
if (!tmpdata) {
- if (tmpname) (void) Xfree (tmpname);
+ if (tmpname) Xfree (tmpname);
return;
}
memcpy (tmpdata, data, datalen);
@@ -1054,7 +1054,7 @@ GetAuthorization(
auth_data = (unsigned char *) xauth_data;
} else {
char dpynumbuf[40]; /* big enough to hold 2^64 and more */
- (void) sprintf (dpynumbuf, "%d", idisplay);
+ sprintf (dpynumbuf, "%d", idisplay);
authptr = XauGetBestAuthByAddr ((unsigned short) family,
(unsigned short) saddrlen,
diff --git a/xts5/src/libproto/Expect.c b/xts5/src/libproto/Expect.c
index dff5bc02..6c738fad 100644
--- a/xts5/src/libproto/Expect.c
+++ b/xts5/src/libproto/Expect.c
@@ -570,7 +570,7 @@ unsigned long size;
continue;
}
else {
- (void) strcpy (emsg, strerror(errno));
+ strcpy (emsg, strerror(errno));
Log_Msg ("Expect: wanted %s, got SYSTEM ERROR - %s\n", wanted, emsg);
Finish (client);
}
diff --git a/xts5/src/libproto/TestSup.c b/xts5/src/libproto/TestSup.c
index 51a07e98..42ae7b20 100644
--- a/xts5/src/libproto/TestSup.c
+++ b/xts5/src/libproto/TestSup.c
@@ -169,7 +169,7 @@ Map_a_Window(client, win) /* use when no expose events are expected */
req->id = win;
Send_Req(client, (xReq *) req);
Log_Trace("client %d MapWindow request on window %d\n", client, win);
- (void) Expect_Nothing(client);
+ Expect_Nothing(client);
Free_Req(req);
}
@@ -194,7 +194,7 @@ Unmap_Window(client, win)
/* do any event checking here */
Free_Event(ev);
}
- (void) Expect_Nothing(client);
+ Expect_Nothing(client);
Free_Req(req);
}
@@ -209,7 +209,7 @@ Unmap_a_Window(client, win)
req->id = win;
Send_Req(client, (xReq *) req);
Log_Trace("client %d UnmapWindow request on window %d\n", client, win);
- (void) Expect_Nothing(client);
+ Expect_Nothing(client);
Free_Req(req);
}
@@ -244,6 +244,6 @@ Destroy_Window(client, win)
req->id = win;
Send_Req(client, (xReq *) req);
Log_Trace("client %d DestroyWindow request on window %d\n", client, win);
- (void) Expect_Nothing(client);
+ Expect_Nothing(client);
Free_Req(req);
}
diff --git a/xts5/src/libproto/XlibNoXtst.c b/xts5/src/libproto/XlibNoXtst.c
index f7b050e0..e8654b49 100644
--- a/xts5/src/libproto/XlibNoXtst.c
+++ b/xts5/src/libproto/XlibNoXtst.c
@@ -241,7 +241,7 @@ int XstConnectDisplay (display_name, expanded_name, screen_num,
* NOTE - if DECnet is to be used, the display name is formatted
* as "host::number"
*/
- (void) strncpy(displaybuf, display_name, sizeof(displaybuf));
+ strncpy(displaybuf, display_name, sizeof(displaybuf));
if ((display_ptr = SearchString(displaybuf,':')) == (char *)NULL)
return (-1);
#ifdef DNETCONN
@@ -304,13 +304,13 @@ int XstConnectDisplay (display_name, expanded_name, screen_num,
if (displaybuf[0] == '\0')
#ifdef DNETCONN
if (dnet)
- (void) strcpy (displaybuf, "0");
+ strcpy (displaybuf, "0");
else
#endif
#ifdef UNIXCONN
; /* Do nothing if UNIX DOMAIN. Will be handled below. */
#else
- (void) gethostname (displaybuf, sizeof(displaybuf));
+ gethostname (displaybuf, sizeof(displaybuf));
#endif
#ifdef DNETCONN
@@ -333,7 +333,7 @@ int XstConnectDisplay (display_name, expanded_name, screen_num,
(strcmp("unix", displaybuf) == 0)) {
/* Connect locally using Unix domain. */
unaddr.sun_family = AF_UNIX;
- (void) strcpy(unaddr.sun_path, X_UNIX_PATH);
+ strcpy(unaddr.sun_path, X_UNIX_PATH);
strcat(unaddr.sun_path, display_ptr);
addr = (struct sockaddr *) &unaddr;
addrlen = strlen(unaddr.sun_path) + 2;
@@ -389,7 +389,7 @@ int XstConnectDisplay (display_name, expanded_name, screen_num,
if (connect(fd, addr, addrlen) == -1) {
- (void) close (fd);
+ close (fd);
return(-1); /* errno set by system call. */
}
#ifdef FIOSNBIO
@@ -398,7 +398,7 @@ int XstConnectDisplay (display_name, expanded_name, screen_num,
ioctl (fd, FIOSNBIO, &arg);
}
#else
- (void) fcntl (fd, F_SETFL, FNDELAY);
+ fcntl (fd, F_SETFL, FNDELAY);
#endif /* FIOSNBIO */
}
@@ -418,7 +418,7 @@ int XstConnectDisplay (display_name, expanded_name, screen_num,
while (*numbuf_ptr != '\0')
*(display_ptr++) = *(numbuf_ptr++);
*display_ptr = '\0';
- (void) strcpy(expanded_name, displaybuf);
+ strcpy(expanded_name, displaybuf);
return(fd);
}
@@ -526,7 +526,7 @@ XstSendClientPrefix (dpy, client, auth_proto, auth_string, needswap)
BPRINTF2 ("\tTotal OpenDisplay message length = %d bytes\n", bytes);
BPRINTF2 ("\t\ton fd %d\n", dpy->fd);
BPRINTF2 ("\t\t%d bytes used of buffer\n", bptr - buffer);
- (void) WriteToServer(dpy->fd, buffer, bytes);
+ WriteToServer(dpy->fd, buffer, bytes);
return;
}
diff --git a/xts5/src/libproto/XlibXtst.c b/xts5/src/libproto/XlibXtst.c
index f9906a93..c7da875e 100644
--- a/xts5/src/libproto/XlibXtst.c
+++ b/xts5/src/libproto/XlibXtst.c
@@ -366,7 +366,7 @@ void XstSendClientPrefix (dpy, client, auth_proto, auth_string, needswap)
BPRINTF2 ("\tTotal OpenDisplay message length = %d bytes\n", bytes);
BPRINTF2 ("\t\ton fd %d\n", dpy->fd);
BPRINTF2 ("\t\t%d bytes used of buffer\n", bptr - buffer);
- (void) WriteToServer(dpy->fd, buffer, bytes);
+ WriteToServer(dpy->fd, buffer, bytes);
return;
}
@@ -707,7 +707,7 @@ int needswap;
BPRINTF2 ("\t\ton fd %d\n", dpy->fd);
BPRINTF2 ("\t\t%d bytes used of buffer\n", bptr - buffer);
dpy->request++; /* increment sequence counter */
- (void) WriteToServer(dpy->fd, buffer, bytes);
+ WriteToServer(dpy->fd, buffer, bytes);
if (Get_Req_Type(client) == OPEN_DISPLAY_REQUEST_TYPE) {
if (Get_Test_Type(client) == OPEN_DISPLAY) {
Log_Msg ("INTERNAL ERROR: should not be getting QueryExtensionReply with TestType == OPEN_DISPLAY.");
@@ -765,7 +765,7 @@ int needswap;
BPRINTF2 ("\t\ton fd %d\n", dpy->fd);
BPRINTF2 ("\t\t%d bytes used of buffer\n", bptr - buffer);
dpy->request++; /* increment sequence counter */
- (void) WriteToServer(dpy->fd, buffer, bytes);
+ WriteToServer(dpy->fd, buffer, bytes);
/* time_proc already set */
Set_Timer (CONNECT_TIMER_ID, Xst_timeout_value, time_proc);
diff --git a/xts5/src/libproto/XstIO.c b/xts5/src/libproto/XstIO.c
index e538abcf..05118188 100644
--- a/xts5/src/libproto/XstIO.c
+++ b/xts5/src/libproto/XstIO.c
@@ -249,7 +249,7 @@ int incperror; /* include system error info */
char emsg[132];
if (incperror)
- (void) strcpy(emsg,strerror(errno));
+ strcpy(emsg,strerror(errno));
else {
emsg[0]='\0';
}
diff --git a/xts5/src/libproto/delete.c b/xts5/src/libproto/delete.c
index 51876e31..e5e55b4c 100644
--- a/xts5/src/libproto/delete.c
+++ b/xts5/src/libproto/delete.c
@@ -173,7 +173,7 @@ va_list args;
Xst_delete_count++;
if (mess && *mess) {
- (void) vsprintf(buf, mess, args);
+ vsprintf(buf, mess, args);
report(buf);
} else
report("Test deleted");
diff --git a/xts5/src/libproto/startup.c b/xts5/src/libproto/startup.c
index 0718d5cb..8a2bb347 100644
--- a/xts5/src/libproto/startup.c
+++ b/xts5/src/libproto/startup.c
@@ -191,7 +191,7 @@ extern int io_err(), unexp_err();
* Put out the NAME info line for the report generator.
*/
/* VSW5 does not need this
- (void) sprintf(buf, "TRACE:NAME: %s", TestName);
+ sprintf(buf, "TRACE:NAME: %s", TestName);
tet_infoline(buf);
*/
@@ -215,9 +215,9 @@ extern int io_err(), unexp_err();
* opening a connection here is to prevent further server resets
* between test purposes.
*/
- (void) XSetErrorHandler(unexp_err); /* unexp_err() can rely
+ XSetErrorHandler(unexp_err); /* unexp_err() can rely
on Dsp as not called unless set */
- (void) XSetIOErrorHandler(io_err); /* io_err() mustn't & doesn't.... */
+ XSetIOErrorHandler(io_err); /* io_err() mustn't & doesn't.... */
Dsp = XOpenDisplay(disp);
if (Dsp == (Display *)0) {
@@ -247,7 +247,7 @@ protocleanup()
/* At present this causes needless problems... */
#ifndef GENERATE_PIXMAPS
/* about to exit anyway... */
- (void) close(ConnectionNumber(Dsp));
+ close(ConnectionNumber(Dsp));
#endif
}
}
diff --git a/xts5/src/libproto/tpstartup.c b/xts5/src/libproto/tpstartup.c
index d7a06529..620b927d 100644
--- a/xts5/src/libproto/tpstartup.c
+++ b/xts5/src/libproto/tpstartup.c
@@ -231,7 +231,7 @@ int client;
} else {
Log_Trace("client %d received startup GetFontPath reply\n", client);
}
- (void) Expect_Nothing(client);
+ Expect_Nothing(client);
Free_Req(req);
return put_in_commas(rep);
@@ -283,7 +283,7 @@ char *prevpath;
Send_Req(client, (xReq *) req);
Log_Trace("client %d sent startup SetFontPath request\n", client);
- (void) Expect_Nothing(client);
+ Expect_Nothing(client);
Free_Req(req);
}
diff --git a/xts5/src/xim/linklocale.c b/xts5/src/xim/linklocale.c
index 1debcf11..5b2fd728 100644
--- a/xts5/src/xim/linklocale.c
+++ b/xts5/src/xim/linklocale.c
@@ -154,8 +154,8 @@ char buf[BUF_LEN];
return(True);
ic = tet_testlist[tet_thistest-1].icref;
- (void) sprintf(name1, "a%d.%s.dat", ic, plocale);
- (void) sprintf(name2, "a%d.dat", ic);
+ sprintf(name1, "a%d.%s.dat", ic, plocale);
+ sprintf(name2, "a%d.dat", ic);
fp1 = fopen(name1, "r");
if (fp1 == NULL)
@@ -189,7 +189,7 @@ char name[128];
if(config.debug_no_pixcheck) return;
ic = tet_testlist[tet_thistest-1].icref;
- (void) sprintf(name, "a%d.dat", ic);
+ sprintf(name, "a%d.dat", ic);
- (void) unlink(name);
+ unlink(name);
}