This commit is contained in:
purplerain 2023-07-10 00:10:46 +00:00
parent 2a351e0cdc
commit f57be82572
Signed by: purplerain
GPG key ID: F42C07F07E2E35B7
704 changed files with 20524 additions and 10572 deletions

View file

View file

@ -1,4 +1,4 @@
# $OpenBSD: Makefile,v 1.84 2023/02/18 01:22:50 deraadt Exp $
# $OpenBSD: Makefile,v 1.85 2023/07/08 11:03:45 jasper Exp $
SUBDIR=ldconfig ldd
MAN= ld.so.1
@ -29,7 +29,7 @@ SRCS+= malloc.c reallocarray.c tib.c ffs.c
syscall=close exit fstat getdents getentropy getthrid issetugid kbind \
mimmutable mmap mprotect munmap msyscall open pledge pinsyscall \
read __realpath sendsyslog __set_tcb sysctl thrkill utrace write \
read __realpath sendsyslog __set_tcb sysctl thrkill utrace write
.if (${MACHINE_ARCH} == "i386")
syscall+=mquery

View file

@ -1,4 +1,4 @@
/* $OpenBSD: ldasm.S,v 1.10 2023/04/24 22:06:05 kettenis Exp $ */
/* $OpenBSD: ldasm.S,v 1.11 2023/07/08 14:09:43 jasper Exp $ */
/*
* Copyright (c) 2016 Dale Rahn

View file

@ -1,4 +1,4 @@
/* $OpenBSD: dlfcn.c,v 1.113 2022/11/09 18:44:11 deraadt Exp $ */
/* $OpenBSD: dlfcn.c,v 1.114 2023/07/08 14:09:43 jasper Exp $ */
/*
* Copyright (c) 1998 Per Fogelstrom, Opsycon AB

View file

@ -1,4 +1,4 @@
/* $OpenBSD: loader.c,v 1.212 2023/02/20 00:51:57 gnezdo Exp $ */
/* $OpenBSD: loader.c,v 1.213 2023/07/08 14:09:43 jasper Exp $ */
/*
* Copyright (c) 1998 Per Fogelstrom, Opsycon AB

View file

@ -1,4 +1,4 @@
/* $OpenBSD: resolve.c,v 1.99 2023/04/13 19:57:30 millert Exp $ */
/* $OpenBSD: resolve.c,v 1.100 2023/07/08 14:09:43 jasper Exp $ */
/*
* Copyright (c) 1998 Per Fogelstrom, Opsycon AB
@ -275,10 +275,9 @@ _dl_finalize_object(const char *objname, Elf_Dyn *dynp, Elf_Phdr *phdrp,
elf_object_t *object;
Elf_Addr gnu_hash = 0;
#if 0
_dl_printf("objname [%s], dynp %p, objtype %x lbase %lx, obase %lx\n",
objname, dynp, objtype, lbase, obase);
#endif
DL_DEB(("objname [%s], dynp %p, objtype %x lbase %lx, obase %lx\n",
objname, dynp, objtype, lbase, obase));
object = _dl_calloc(1, sizeof(elf_object_t));
if (object == NULL)
_dl_oom();

View file

@ -265,9 +265,9 @@ aldap_search(struct aldap *ldap, char *basedn, enum scope scope, char *filter,
goto fail;
}
c = ber;
c = ber;
ber = ober_printf_elements(ber, "sEEddb", basedn, (long long)scope,
(long long)LDAP_DEREF_NEVER, sizelimit,
(long long)LDAP_DEREF_NEVER, sizelimit,
timelimit, typesonly);
if (ber == NULL) {
ldap->err = ALDAP_ERR_OPERATION_FAILED;
@ -339,7 +339,7 @@ aldap_create_page_control(struct ber_element *elm, int size,
fail:
if (ber != NULL)
ober_free_elements(ber);
ober_free(&c);
ober_free(&c);
return (-1);
}
@ -451,7 +451,7 @@ parsefail:
}
struct aldap_page_control *
aldap_parse_page_control(struct ber_element *control, size_t len)
aldap_parse_page_control(struct ber_element *control, size_t len)
{
char *oid, *s;
char *encoded;

View file

@ -77,7 +77,7 @@ struct aldap_message {
} search;
} body;
struct ber_element *references;
struct aldap_page_control *page;
struct aldap_page_control *page;
};
enum aldap_protocol {

View file

@ -246,7 +246,7 @@ auth_ldap(char *user, char *class, char *pass)
}
dlog(1, "group filter matched!");
}
if (ctx.basedn != NULL) {
if (!bind_password(&ctx, ctx.userdn, pass)) {

View file

@ -35,7 +35,7 @@
*/
/*
* Structure defining a record for a user. All fields
* Structure defining a record for a user. All fields
* stored in ascii to facilitate backup/reconstruction.
* A null byte is required after the share secret field.
*/
@ -68,7 +68,7 @@ typedef struct {
#define TOKEN_GROUP "_token" /* group that owns token database */
/*
* Function prototypes for routines which manipulate the
* Function prototypes for routines which manipulate the
* database for the token. These routines have no knowledge
* of DES or encryption. However, they will manipulate the
* flags field of the database record with complete abandon.

View file

@ -1170,12 +1170,12 @@ mib_ifrcvtable(struct agentx_varbind *vb)
}
/*
* Defined in
* Defined in
* - OPENBSD-PF-MIB.txt
* - OPENBSD-SENSORS-MIB.txt
* - OPENBSD-CARP-MIB.txt
* (http://www.packetmischief.ca/openbsd-snmp-mibs/)
*/
*/
#define OIDVER_OPENBSD_MEM 1
struct carpif {
@ -1466,7 +1466,7 @@ mib_pftimeouts(struct agentx_varbind *vb)
pt.timeout = PFTM_SRC_NODE;
else
fatal("%s: Unexpected object", __func__);
if (ioctl(devpf, DIOCGETTIMEOUT, &pt) == -1) {
log_warn("DIOCGETTIMEOUT");
agentx_varbind_error(vb);
@ -1699,7 +1699,7 @@ mib_pftableaddrs(struct agentx_varbind *vb)
as.pfras_a.pfra_net = agentx_varbind_get_index_integer(vb,
pfTblAddrMaskIdx);
if (pfta_get_nextaddr(&as, &tblidx)){
if (pfta_get_nextaddr(&as, &tblidx)){
agentx_varbind_notfound(vb);
return;
}
@ -2063,7 +2063,7 @@ static const char * const sensor_drive_s[SENSOR_DRIVE_STATES] = {
static const char * const sensor_unit_s[SENSOR_MAX_TYPES + 1] = {
"degC", "RPM", "V DC", "V AC", "Ohm", "W", "A", "Wh", "Ah",
"", "", "%", "lx", "", "sec", "%RH", "Hz", "degree",
"", "", "%", "lx", "", "sec", "%RH", "Hz", "degree",
"m", "Pa", "m/s^2", "m/s", ""
};
@ -3086,16 +3086,16 @@ mib_diskio(struct agentx_varbind *vb)
else if (obj == diskIODevice)
agentx_varbind_string(vb, stats[idx - 1].ds_name);
else if (obj == diskIONRead)
agentx_varbind_counter32(vb,
agentx_varbind_counter32(vb,
(u_int32_t)stats[idx - 1].ds_rbytes);
else if (obj == diskIONWritten)
agentx_varbind_counter32(vb,
agentx_varbind_counter32(vb,
(u_int32_t)stats[idx - 1].ds_wbytes);
else if (obj == diskIOReads)
agentx_varbind_counter32(vb,
agentx_varbind_counter32(vb,
(u_int32_t)stats[idx - 1].ds_rxfer);
else if (obj == diskIOWrites)
agentx_varbind_counter32(vb,
agentx_varbind_counter32(vb,
(u_int32_t)stats[idx - 1].ds_wxfer);
else if (obj == diskIONReadX)
agentx_varbind_counter64(vb, stats[idx - 1].ds_rbytes);
@ -4339,7 +4339,7 @@ snmp_connect(struct agentx *sa, void *cookie, int close)
snmp_read, sa);
event_add(&connev, NULL);
init = 1;
} else
} else
snmp_tryconnect(-1, 0, sa);
}

View file

@ -89,7 +89,7 @@ pfr_get_astats(struct pfr_table *tbl, struct pfr_astats *addr, int *size,
extern int devpf;
if (tbl == NULL || size == NULL || *size < 0 ||
(*size && addr == NULL))
(*size && addr == NULL))
return (-1);
bzero(&io, sizeof io);
@ -98,7 +98,7 @@ pfr_get_astats(struct pfr_table *tbl, struct pfr_astats *addr, int *size,
io.pfrio_buffer = addr;
io.pfrio_esize = sizeof(*addr);
io.pfrio_size = *size;
if (ioctl(devpf, DIOCRGETASTATS, &io) == -1)
if (ioctl(devpf, DIOCRGETASTATS, &io) == -1)
return (-1);
*size = io.pfrio_size;
return (0);
@ -168,7 +168,7 @@ pfr_buf_next(struct pfr_buffer *b, const void *prev)
return (NULL);
if (b->pfrb_size == 0)
return (NULL);
if (prev == NULL)
if (prev == NULL)
return (b->pfrb_caddr);
bs = buf_esize[b->pfrb_type];
if ((((const char *)prev)-((char *)b->pfrb_caddr)) / bs >=
@ -274,7 +274,7 @@ pft_get(struct pfr_buffer *b, struct pfr_table *filter)
{
bzero(b, sizeof(struct pfr_buffer));
b->pfrb_type = PFRB_TSTATS;
for (;;) {
pfr_buf_grow(b, b->pfrb_size);
b->pfrb_size = b->pfrb_msize;
@ -298,7 +298,7 @@ pft_get_table(struct pfr_tstats *rts, int idx)
free(b.pfrb_caddr);
return (-1);
}
PFRB_FOREACH(ts, &b) {
if (!(ts->pfrts_flags & PFR_TFLAG_ACTIVE))
continue;
@ -355,7 +355,7 @@ pfta_get(struct pfr_buffer *b, struct pfr_table *filter)
if (b->pfrb_size <= b->pfrb_msize)
break;
}
return (0);
}

View file

@ -395,7 +395,7 @@ void
do_message(FILE *sdc, char *msg)
{
size_t i, bs = 0, bu = 0, len;
ssize_t n;
ssize_t n;
char *buf = NULL, last, *tmp;
int fd;

View file

@ -1093,7 +1093,7 @@ greywatcher(void)
syslog_r(LOG_ERR, &sdata, "pledge failed (%m)");
exit(1);
}
startup = time(NULL);
db_pid = fork();
switch (db_pid) {

View file

@ -277,7 +277,7 @@ logpkt_handler(u_char *user, const struct pcap_pkthdr *h, const u_char *sp)
if (ipstraddr[0] != '\0') {
if (hdr->dir == PF_IN)
logmsg(LOG_DEBUG,"inbound %s", ipstraddr);
else
else
logmsg(LOG_DEBUG,"outbound %s", ipstraddr);
dbupdate(PATH_SPAMD_DB, ipstraddr);
}

View file

@ -475,7 +475,7 @@ tryreduce(void)
continue;
}
t4 = (num >= 4) ? tokenarray_get(&tokens, num-4) : NULL;
if (num >= 4 &&

View file

@ -890,7 +890,7 @@ expand_domacro(struct expstate *es, struct place *p)
name = stringarray_get(&es->args, 0);
m = macrotable_find(name, false);
val = (m != NULL) ? "1" : "0";
debuglog(p, "defined(%s): %s", name, val);
debuglog(p, "defined(%s): %s", name, val);
expand_send(es, p, val, 1);
expstate_destroyargs(es);
return;

View file

@ -116,7 +116,7 @@ commandline_macros_cleanup(void)
dofree(cm, sizeof(*cm));
}
array_setsize(&commandline_macros, 0);
array_cleanup(&commandline_macros);
}

View file

@ -39,7 +39,7 @@
const char ws[] =
" \t\f\v"
;
const char alnum[] =
const char alnum[] =
"0123456789"
"abcdefghijklmnopqrstuvwxyz"
"ABCDEFGHIJKLMNOPQRSTUVWXYZ"