Kill most warnings in lib/DtTerm.
Mostly missing headers, explicit parentheses and new prototypes. Some Caveats: * I haven't compile-tested the SVR4 getpty file, it might need another tweak * There were operator precedence bugs in TermPrimCursor.c and TermPrimRender.c (^ vs. !=). This might change behaviour, but at least I haven't experienced any crashes ... * This adds a little more dependencies for include ordering, but unless we want to play the "headers that include headers that include headers..." game, this is unavoidable.
This commit is contained in:
committed by
Jon Trulson
parent
8f98ac92cd
commit
dc0e8ea74d
@@ -65,6 +65,7 @@ static char rcs_id[] = "$TOG: TermPrimSubproc.c /main/11 1998/04/20 12:45:57 mgr
|
||||
#include "TermPrimSetPty.h"
|
||||
#include "TermPrimSubproc.h"
|
||||
#include "TermPrimDebug.h"
|
||||
#include "TermPrimSetUtmp.h"
|
||||
#include "TermPrimUtil.h"
|
||||
|
||||
typedef struct _subprocInfo {
|
||||
@@ -94,7 +95,7 @@ FakeFork (void)
|
||||
#endif /*BBA*/
|
||||
_DtTermProcessLock();
|
||||
if (debugInit) {
|
||||
if (c = getenv("dttermDebugForkFailures")) {
|
||||
if ((c = getenv("dttermDebugForkFailures"))) {
|
||||
debugForkFailures = strtol(c, (char **) 0, 0);
|
||||
debugInit = 0;
|
||||
}
|
||||
@@ -382,7 +383,7 @@ _DtTermPrimSubprocExec(Widget w,
|
||||
if (loginShell) {
|
||||
/* pre-pend an '-' for loginShell... */
|
||||
(void) strcat(argv[0], "-");
|
||||
if (c = strrchr(cmd, '/')) {
|
||||
if ((c = strrchr(cmd, '/'))) {
|
||||
strcat(argv[0], ++c);
|
||||
} else {
|
||||
strcat(argv[0], cmd);
|
||||
|
||||
Reference in New Issue
Block a user