mirror of
https://github.com/rcornwell/sims.git
synced 2026-01-11 23:52:48 +00:00
SCP: Updated to current.
This commit is contained in:
parent
4c18051018
commit
c0339c4c60
11
makefile
11
makefile
@ -354,9 +354,14 @@ ifeq (${WIN32},) #*nix Environments (&& cygwin)
|
||||
LIBPATH += /opt/local/lib
|
||||
OS_LDFLAGS += -L/opt/local/lib
|
||||
endif
|
||||
ifeq (HomeBrew,$(shell if ${TEST} -d /usr/local/Cellar; then echo HomeBrew; fi))
|
||||
INCPATH += $(foreach dir,$(wildcard /usr/local/Cellar/*/*),$(dir)/include)
|
||||
LIBPATH += $(foreach dir,$(wildcard /usr/local/Cellar/*/*),$(dir)/lib)
|
||||
ifeq (HomeBrew,$(or $(shell if ${TEST} -d /usr/local/Cellar; then echo HomeBrew; fi),$(shell if ${TEST} -d /opt/homebrew/Cellar; then echo HomeBrew; fi)))
|
||||
ifeq (local,$(shell if $(TEST) -d /usr/local/Cellar; then echo local; fi))
|
||||
HBPATH = /usr/local
|
||||
else
|
||||
HBPATH = /opt/homebrew
|
||||
endif
|
||||
INCPATH += $(foreach dir,$(wildcard $(HBPATH)/Cellar/*/*),$(realpath $(dir)/include))
|
||||
LIBPATH += $(foreach dir,$(wildcard $(HBPATH)/Cellar/*/*),$(realpath $(dir)/lib))
|
||||
endif
|
||||
else
|
||||
ifeq (Linux,$(OSTYPE))
|
||||
|
||||
@ -868,7 +868,7 @@ char* eth_getdesc_byname(char* name, char* temp)
|
||||
static ETH_DEV **eth_open_devices = NULL;
|
||||
static int eth_open_device_count = 0;
|
||||
|
||||
static char* (*p_pcap_lib_version) (void);
|
||||
static char *(*p_pcap_lib_version) (void);
|
||||
|
||||
static void _eth_add_to_open_list (ETH_DEV* dev)
|
||||
{
|
||||
@ -1046,12 +1046,13 @@ typedef void * pcap_t; /* Pseudo Type to avoid compiler errors */
|
||||
*/
|
||||
static int eth_host_pcap_devices(int used, int max, ETH_LIST* list)
|
||||
{
|
||||
pcap_t* conn = NULL;
|
||||
int i, j, datalink = 0;
|
||||
int i;
|
||||
|
||||
for (i=0; i<used; ++i) {
|
||||
/* Cull any non-ethernet interface types */
|
||||
#if defined(HAVE_PCAP_NETWORK)
|
||||
int j, datalink = 0;
|
||||
pcap_t* conn = NULL;
|
||||
char errbuf[PCAP_ERRBUF_SIZE];
|
||||
|
||||
conn = pcap_open_live(list[i].name, ETH_MAX_PACKET, ETH_PROMISC, PCAP_READ_TIMEOUT, errbuf);
|
||||
|
||||
10
sim_tmxr.c
10
sim_tmxr.c
@ -5247,8 +5247,8 @@ idx = 0; /* initialize the index
|
||||
|
||||
while (*cptr != '\0') { /* while characters remain in the command string */
|
||||
if (strncasecmp (cptr, "ALL;", 4) == 0) { /* if the parameter is "ALL" */
|
||||
if (val != 0 || idx > 0 && idx <= max) /* then if some lines are restrictied or unspecified */
|
||||
for (line = (uint32) min; line <= max; line++) /* then fill them in sequentially */
|
||||
if ((val != 0) || ((idx > 0) && (idx <= max))) /* then if some lines are restrictied or unspecified */
|
||||
for (line = (uint32)min; line <= (uint32)max; line++)/* then fill them in sequentially */
|
||||
if (set [line] == FALSE) /* setting each unspecified line */
|
||||
list [idx++] = line; /* into the line order */
|
||||
|
||||
@ -5268,13 +5268,15 @@ while (*cptr != '\0') { /* while characters
|
||||
break; /* and terminate the parse */
|
||||
}
|
||||
|
||||
else if (low < min || low > max || high > max) { /* otherwise if the line number is invalid */
|
||||
else if ((low < min) ||
|
||||
(low > max) ||
|
||||
(high > max)) { /* otherwise if the line number is invalid */
|
||||
result = SCPE_SUB; /* then report the subscript is out of range */
|
||||
break; /* and terminate the parse */
|
||||
}
|
||||
|
||||
else /* otherwise it's a valid range */
|
||||
for (line = (uint32) low; line <= high; line++) /* so add the line(s) to the order */
|
||||
for (line = (uint32)low; line <= (uint32)high; line++)/* so add the line(s) to the order */
|
||||
if (set [line] == FALSE) { /* if the line number has not been specified */
|
||||
set [line] = TRUE; /* then now it is */
|
||||
list [idx++] = line; /* and add it to the connection order */
|
||||
|
||||
Loading…
x
Reference in New Issue
Block a user