Skip to content
Merged
Show file tree
Hide file tree
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
3 changes: 1 addition & 2 deletions src/initkbd.c
Original file line number Diff line number Diff line change
Expand Up @@ -12,6 +12,7 @@

#include <errno.h>
#include <stdio.h>
#include <stdlib.h>
#include <string.h>
#include <sys/types.h>
#ifndef DOS
Expand Down Expand Up @@ -383,8 +384,6 @@ void seteventmask(struct inputmask *eventmask)
}
#endif /* SUNDISPLAY */

char *getenv(); /* ---- external entry points --------*/

#define MIN_KEYTYPE 3
#define KB_AS3000J (7 + MIN_KEYTYPE)
#define KB_RS6000 (8 + MIN_KEYTYPE) /* TODO: Can we remove this? */
Expand Down
3 changes: 2 additions & 1 deletion src/ldeether.c
Original file line number Diff line number Diff line change
Expand Up @@ -63,6 +63,7 @@ char *devices[] = {"le0", "le1", "le2", "le3", "le4", "ie0", "ie1", "i
#include <nlist.h>
#include <fcntl.h>
#include <malloc.h>
#include <stdlib.h>

#endif /* NOETHER */

Expand Down Expand Up @@ -103,7 +104,7 @@ int main(int argc, char *argv[]) {
/* Use DLPI to connect to the ethernet. This code is stolen
from NFSWATCH4.3
*/
char *etherdev = (char *)getenv("LDEETHERDEV");
char *etherdev = getenv("LDEETHERDEV");
ether_fd = setup_dlpi_dev(etherdev);
if (ether_fd >= 0) { /* Open an ether interface */
ether_intf_type = dlpi_devtype(ether_fd);
Expand Down
2 changes: 1 addition & 1 deletion src/main.c
Original file line number Diff line number Diff line change
Expand Up @@ -20,6 +20,7 @@
#include <errno.h>
#include <setjmp.h>
#include <stdio.h>
#include <stdlib.h>
#include <string.h>
#include <sys/types.h>
#include <time.h>
Expand Down Expand Up @@ -248,7 +249,6 @@ char keystring[128] = {""};
#define FALSE 0
#define TRUE !FALSE

char *getenv();
int Lisp_Xinitialized = FALSE;
char sysout_name[MAXPATHLEN]; /* Set by read_Xoption, in the X version. */
int sysout_size = 0; /* ditto */
Expand Down
2 changes: 1 addition & 1 deletion src/timer.c
Original file line number Diff line number Diff line change
Expand Up @@ -44,6 +44,7 @@ unsigned long tick_count = 0; /* approx 18 ticks per sec */
#endif /* DOS */
#include <sys/types.h>
#include <stdio.h>
#include <stdlib.h>
#include <signal.h>
#include <unistd.h>
#include <fcntl.h>
Expand Down Expand Up @@ -102,7 +103,6 @@ extern DspInterface currentdsp;
*/

int TIMEOUT_TIME; /* For file system timeout */
char *getenv();

#ifdef XWINDOW
#define FALSE 0
Expand Down
3 changes: 2 additions & 1 deletion src/unixcomm.c
Original file line number Diff line number Diff line change
Expand Up @@ -31,6 +31,7 @@ Unix Interface Communications
#include <setjmp.h> /* JRB - timeout.h needs setjmp.h */
#include <signal.h>
#include <stdio.h>
#include <stdlib.h>
#include <string.h>
#include <sys/file.h>
#include <sys/ioctl.h>
Expand Down Expand Up @@ -258,7 +259,7 @@ void close_unix_descriptors(void) /* Get ready to shut Maiko down */
/************************************************************************/

int FindUnixPipes(void) {
char *envtmp, *getenv(const char *);
char *envtmp;
register int i;
struct unixjob cleareduj;

Expand Down
3 changes: 1 addition & 2 deletions src/uutils.c
Original file line number Diff line number Diff line change
Expand Up @@ -20,6 +20,7 @@

#include <signal.h>
#include <stdio.h>
#include <stdlib.h>
#include <string.h>
#include <time.h>
#include <unistd.h>
Expand Down Expand Up @@ -220,8 +221,6 @@ LispPTR unix_username(LispPTR *args) {
* The only usage seems to be checking "ARCH" == "dos" and for the existance
* of *any* result from the call, which indicates it's an emulated system.
*/
char *getenv(const char *);

LispPTR unix_getparm(LispPTR *args) {
char envname[20], result[128], *envvalue;
if (lisp_string_to_c_string(args[0], envname, sizeof envname)) return NIL;
Expand Down
1 change: 0 additions & 1 deletion src/xmkicon.c
Original file line number Diff line number Diff line change
Expand Up @@ -43,7 +43,6 @@ Pixmap make_Xicon(DspInterface dsp)
{
unsigned int width, height;
int value, x_hot, y_hot;
char *getenv();

#ifdef TRACE
printf("In make_Xicon().\n");
Expand Down
10 changes: 5 additions & 5 deletions src/xrdopt.c
Original file line number Diff line number Diff line change
Expand Up @@ -205,12 +205,12 @@ void read_Xoption(int *argc, char *argv[])
if (*argc == 2) /* There was probably a sysoutarg */
{
(void)strcpy(sysout_name, argv[1]);
} else if ((envname = (char *)getenv("LDESRCESYSOUT")) != NULL) {
} else if ((envname = getenv("LDESRCESYSOUT")) != NULL) {
strcpy(sysout_name, envname);
} else if ((envname = (char *)getenv("LDESOURCESYSOUT")) != NULL)
} else if ((envname = getenv("LDESOURCESYSOUT")) != NULL)
strcpy(sysout_name, envname);
else {
envname = (char *)getenv("HOME");
envname = getenv("HOME");
(void)strcat(sysout_name, envname);
(void)strcat(sysout_name, "/lisp.virtualmem");

Expand All @@ -231,7 +231,7 @@ void read_Xoption(int *argc, char *argv[])
fprintf(stderr, "or provide a -display argument.\n");
print_Xusage(argv[0]);
} else {
envname = (char *)getenv("DISPLAY");
envname = getenv("DISPLAY");
(void)strcpy(Display_Name, envname);
}
if ((xdisplay = XOpenDisplay(Display_Name)) != NULL) {
Expand All @@ -252,7 +252,7 @@ void read_Xoption(int *argc, char *argv[])
exit(-1);
}

envname = (char *)getenv("HOME");
envname = getenv("HOME");
(void)strcat(tmp, envname);
(void)strcat(tmp, "/.Xdefaults");
if (access(tmp, R_OK) != 0) {
Expand Down