sync code with last improvements from OpenBSD
This commit is contained in:
parent
010ec4e74c
commit
2a511f7966
2
gnu/share/config.guess
vendored
2
gnu/share/config.guess
vendored
@ -858,7 +858,7 @@ EOF
|
||||
;;
|
||||
a.out-i386-linux)
|
||||
echo "${UNAME_MACHINE}-pc-linux-gnuaout"
|
||||
exit 0 ;;
|
||||
exit 0 ;;
|
||||
coff-i386)
|
||||
echo "${UNAME_MACHINE}-pc-linux-gnucoff"
|
||||
exit 0 ;;
|
||||
|
@ -55,9 +55,9 @@ then
|
||||
then
|
||||
dummy=if$$
|
||||
cat >$dummy.c <<EOF
|
||||
#include <features.h>
|
||||
#include <features.h>
|
||||
main(argc, argv)
|
||||
int argc;
|
||||
int argc;
|
||||
char *argv[];
|
||||
{
|
||||
printf("%d\n", __GLIBC_MINOR__);
|
||||
|
22
gnu/share/configure
vendored
22
gnu/share/configure
vendored
@ -10,12 +10,12 @@
|
||||
# it under the terms of the GNU General Public License as published by
|
||||
# the Free Software Foundation; either version 2 of the License, or
|
||||
# (at your option) any later version.
|
||||
#
|
||||
#
|
||||
# This program is distributed in the hope that it will be useful,
|
||||
# but WITHOUT ANY WARRANTY; without even the implied warranty of
|
||||
# MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the
|
||||
# GNU General Public License for more details.
|
||||
#
|
||||
#
|
||||
# You should have received a copy of the GNU General Public License
|
||||
# along with this program; if not, write to the Free Software
|
||||
# Foundation, Inc., 59 Temple Place - Suite 330, Boston, MA 02111-1307, USA.
|
||||
@ -27,7 +27,7 @@
|
||||
# preparation for compilation.
|
||||
#
|
||||
# If configure succeeds, it leaves its status in config.status.
|
||||
# If configure fails after disturbing the status quo,
|
||||
# If configure fails after disturbing the status quo,
|
||||
# config.status is removed.
|
||||
#
|
||||
|
||||
@ -188,7 +188,7 @@ do
|
||||
--*) ;;
|
||||
-*) option=-$option ;;
|
||||
esac
|
||||
|
||||
|
||||
# Split out the argument for options that take them
|
||||
case $option in
|
||||
--*=*)
|
||||
@ -790,7 +790,7 @@ tooldir='$(exec_prefix)'/${target_alias}
|
||||
|
||||
if [ "${host_alias}" != "${target_alias}" ] ; then
|
||||
if [ "${program_prefixoption}" = "" ] ; then
|
||||
if [ "${program_suffixoption}" = "" ] ; then
|
||||
if [ "${program_suffixoption}" = "" ] ; then
|
||||
if [ "${program_transform_nameoption}" = "" ] ; then
|
||||
program_prefix=${target_alias}- ;
|
||||
fi
|
||||
@ -1144,7 +1144,7 @@ for subdir in . ${subdirs} ; do
|
||||
|
||||
if [ ! -r ${srcdir}/${file} ] ; then
|
||||
if [ ! -r ${file} ] ; then
|
||||
|
||||
|
||||
echo '***' "${progname}: cannot create a link \"${link}\"," 1>&2
|
||||
echo '***' "since the file \"${srcdir}/${file}\" does not exist." 1>&2
|
||||
exit 1
|
||||
@ -1160,7 +1160,7 @@ for subdir in . ${subdirs} ; do
|
||||
if ${symbolic_link} ${srcfile} ${link} >/dev/null 2>&1 ; then
|
||||
true
|
||||
else
|
||||
# We need to re-remove the file because Lynx leaves a
|
||||
# We need to re-remove the file because Lynx leaves a
|
||||
# very strange directory there when it fails an NFS symlink.
|
||||
${remove} -r -f ${link}
|
||||
${hard_link} ${srcfile} ${link}
|
||||
@ -1198,7 +1198,7 @@ EOF
|
||||
# code is order so as to try to sed the smallest input files we know.
|
||||
# so do these separately because I don't trust the order of sed -e expressions.
|
||||
|
||||
# the five makefile fragments MUST end up in the resulting Makefile in this order:
|
||||
# the five makefile fragments MUST end up in the resulting Makefile in this order:
|
||||
# package macros, target, host, site, and package rules.
|
||||
|
||||
if [ -f ${srcdir}/${subdir}/${Makefile_in} ] ; then
|
||||
@ -1422,7 +1422,7 @@ EOF
|
||||
-e "s:^DEFAULT_LEX[ ]*=.*$:DEFAULT_LEX = ${DEFAULT_LEX}:" \
|
||||
-e "s:^DEFAULT_M4[ ]*=.*$:DEFAULT_M4 = ${DEFAULT_M4}:" \
|
||||
${subdir}/Makefile.tem >> ${Makefile}
|
||||
|
||||
|
||||
sed -e "s:^GDB_TK[ ]*=.*$:GDB_TK = ${GDB_TK}:" ${Makefile} >${Makefile}.tem
|
||||
mv -f ${Makefile}.tem ${Makefile}
|
||||
|
||||
@ -1507,7 +1507,7 @@ ${progname}" ${arguments} "
|
||||
done
|
||||
|
||||
# If there are subdirectories, then recur.
|
||||
if [ -z "${norecursion}" ] && [ -n "${configdirs}" ] ; then
|
||||
if [ -z "${norecursion}" ] && [ -n "${configdirs}" ] ; then
|
||||
for configdir in ${configdirs} ${extraconfigdirs} ; do
|
||||
|
||||
# If configdir contains ',' it is
|
||||
@ -1541,7 +1541,7 @@ if [ -z "${norecursion}" ] && [ -n "${configdirs}" ] ; then
|
||||
esac
|
||||
|
||||
POPDIR=${PWD=`pwd`}
|
||||
cd ${bld_dir}
|
||||
cd ${bld_dir}
|
||||
|
||||
### figure out what to do with srcdir
|
||||
case "${srcdir}" in
|
||||
|
@ -115,7 +115,7 @@ fi
|
||||
if [ x"$dir_arg" != x ]; then
|
||||
dst=$src
|
||||
src=""
|
||||
|
||||
|
||||
if [ -d $dst ]; then
|
||||
instcmd=:
|
||||
chmodcmd=""
|
||||
@ -125,7 +125,7 @@ if [ x"$dir_arg" != x ]; then
|
||||
else
|
||||
|
||||
# Waiting for this to be detected by the "$instcmd $src $dsttmp" command
|
||||
# might cause directories to be created, which would be especially bad
|
||||
# might cause directories to be created, which would be especially bad
|
||||
# if $src (and thus $dsttmp) contains '*'.
|
||||
|
||||
if [ -f $src -o -d $src ]
|
||||
@ -135,7 +135,7 @@ else
|
||||
echo "install: $src does not exist"
|
||||
exit 1
|
||||
fi
|
||||
|
||||
|
||||
if [ x"$dst" = x ]
|
||||
then
|
||||
echo "install: no destination specified"
|
||||
@ -202,17 +202,17 @@ else
|
||||
|
||||
# If we're going to rename the final executable, determine the name now.
|
||||
|
||||
if [ x"$transformarg" = x ]
|
||||
if [ x"$transformarg" = x ]
|
||||
then
|
||||
dstfile=`basename $dst`
|
||||
else
|
||||
dstfile=`basename $dst $transformbasename |
|
||||
dstfile=`basename $dst $transformbasename |
|
||||
sed $transformarg`$transformbasename
|
||||
fi
|
||||
|
||||
# don't allow the sed command to completely eliminate the filename
|
||||
|
||||
if [ x"$dstfile" = x ]
|
||||
if [ x"$dstfile" = x ]
|
||||
then
|
||||
dstfile=`basename $dst`
|
||||
else
|
||||
@ -243,7 +243,7 @@ else
|
||||
# Now rename the file to the real destination.
|
||||
|
||||
$doit $rmcmd -f $dstdir/$dstfile &&
|
||||
$doit $mvcmd $dsttmp $dstdir/$dstfile
|
||||
$doit $mvcmd $dsttmp $dstdir/$dstfile
|
||||
|
||||
fi &&
|
||||
|
||||
|
@ -777,7 +777,7 @@ if test -n "$pic_flag"; then
|
||||
if { (eval echo $progname:777: \"$ac_compile\") 1>&5; (eval $ac_compile) 2>conftest.err; } && test -s conftest.$objext; then
|
||||
# Append any warnings to the config.log.
|
||||
cat conftest.err 1>&5
|
||||
|
||||
|
||||
case "$host_os" in
|
||||
hpux9* | hpux10* | hpux11*)
|
||||
# On HP-UX, both CC and GCC only warn that PIC is supported... then they
|
||||
@ -937,7 +937,7 @@ if test "$with_gcc" = yes; then
|
||||
else
|
||||
no_builtin_flag=' -fno-builtin'
|
||||
fi
|
||||
|
||||
|
||||
fi
|
||||
|
||||
# Check for any special shared library compilation flags.
|
||||
@ -1183,7 +1183,7 @@ EOF
|
||||
$DLLTOOL --as=$AS --dllname $soname --exclude-symbols DllMain@12,_cygwin_dll_entry@12,_cygwin_noncygwin_dll_entry@12 --def $objdir/$soname-def --base-file $objdir/$soname-base --output-exp $objdir/$soname-exp~
|
||||
$CC $objdir/$soname-exp -Wl,--dll -nostartfiles -Wl,-e,__cygwin_dll_entry@12 -o $lib $objdir/$soname-ltdll.$objext $libobjs $deplibs $linkopts'
|
||||
|
||||
old_archive_from_new_cmds='$DLLTOOL --as=$AS --dllname $soname --def $objdir/$soname-def --output-lib $objdir/$libname.a'
|
||||
old_archive_from_new_cmds='$DLLTOOL --as=$AS --dllname $soname --def $objdir/$soname-def --output-lib $objdir/$libname.a'
|
||||
;;
|
||||
|
||||
netbsd*)
|
||||
@ -1215,7 +1215,7 @@ EOF
|
||||
else
|
||||
ld_shlibs=no
|
||||
fi
|
||||
;;
|
||||
;;
|
||||
|
||||
sunos4*)
|
||||
archive_cmds='$LD -assert pure-text -Bshareable -o $lib $libobjs $deplibs $linkopts'
|
||||
@ -1469,8 +1469,8 @@ else
|
||||
archive_cmds='$LD -G -h $soname -o $lib $libobjs $deplibs $linkopts'
|
||||
runpath_var='LD_RUN_PATH'
|
||||
hardcode_shlibpath_var=no
|
||||
hardcode_direct=no #Motorola manual says yes, but my tests say they lie
|
||||
;;
|
||||
hardcode_direct=no #Motorola manual says yes, but my tests say they lie
|
||||
;;
|
||||
|
||||
sysv4.3*)
|
||||
archive_cmds='$LD -G -h $soname -o $lib $libobjs $deplibs $linkopts'
|
||||
@ -1867,7 +1867,7 @@ cygwin* | mingw*)
|
||||
freebsd1*)
|
||||
dynamic_linker=no
|
||||
;;
|
||||
|
||||
|
||||
freebsd*)
|
||||
objformat=`test -x /usr/bin/objformat && /usr/bin/objformat || echo aout`
|
||||
version_type=freebsd-$objformat
|
||||
@ -2429,10 +2429,10 @@ fi
|
||||
|
||||
fi
|
||||
|
||||
|
||||
|
||||
fi
|
||||
|
||||
|
||||
|
||||
fi
|
||||
|
||||
|
||||
@ -2538,7 +2538,7 @@ else
|
||||
fnord() { int i=42;}
|
||||
main() { void *self, *ptr1, *ptr2; self=dlopen(0,LTDL_GLOBAL|LTDL_LAZY_OR_NOW);
|
||||
if(self) { ptr1=dlsym(self,"fnord"); ptr2=dlsym(self,"_fnord");
|
||||
if(ptr1 || ptr2) { dlclose(self); exit(0); } } exit(1); }
|
||||
if(ptr1 || ptr2) { dlclose(self); exit(0); } } exit(1); }
|
||||
|
||||
EOF
|
||||
if { (eval echo $progname:2544: \"$ac_link\") 1>&5; (eval $ac_link) 2>&5; } && test -s conftest && (./conftest; exit) 2>/dev/null
|
||||
@ -2611,7 +2611,7 @@ else
|
||||
fnord() { int i=42;}
|
||||
main() { void *self, *ptr1, *ptr2; self=dlopen(0,LTDL_GLOBAL|LTDL_LAZY_OR_NOW);
|
||||
if(self) { ptr1=dlsym(self,"fnord"); ptr2=dlsym(self,"_fnord");
|
||||
if(ptr1 || ptr2) { dlclose(self); exit(0); } } exit(1); }
|
||||
if(ptr1 || ptr2) { dlclose(self); exit(0); } } exit(1); }
|
||||
|
||||
EOF
|
||||
if { (eval echo $progname:2617: \"$ac_link\") 1>&5; (eval $ac_link) 2>&5; } && test -s conftest && (./conftest; exit) 2>/dev/null
|
||||
|
@ -696,29 +696,29 @@ compiler."
|
||||
# starting and closing comments
|
||||
# /* impgen.c starts here */
|
||||
# /* Copyright (C) 1999 Free Software Foundation, Inc.
|
||||
#
|
||||
#
|
||||
# This file is part of GNU libtool.
|
||||
#
|
||||
#
|
||||
# This program is free software; you can redistribute it and/or modify
|
||||
# it under the terms of the GNU General Public License as published by
|
||||
# the Free Software Foundation; either version 2 of the License, or
|
||||
# (at your option) any later version.
|
||||
#
|
||||
#
|
||||
# This program is distributed in the hope that it will be useful,
|
||||
# but WITHOUT ANY WARRANTY; without even the implied warranty of
|
||||
# MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the
|
||||
# GNU General Public License for more details.
|
||||
#
|
||||
#
|
||||
# You should have received a copy of the GNU General Public License
|
||||
# along with this program; if not, write to the Free Software
|
||||
# Foundation, Inc., 59 Temple Place - Suite 330, Boston, MA 02111-1307, USA.
|
||||
# */
|
||||
#
|
||||
#
|
||||
# #include <stdio.h> /* for printf() */
|
||||
# #include <unistd.h> /* for open(), lseek(), read() */
|
||||
# #include <fcntl.h> /* for O_RDONLY, O_BINARY */
|
||||
# #include <string.h> /* for strdup() */
|
||||
#
|
||||
#
|
||||
# static unsigned int
|
||||
# pe_get16 (fd, offset)
|
||||
# int fd;
|
||||
@ -729,7 +729,7 @@ compiler."
|
||||
# read (fd, b, 2);
|
||||
# return b[0] + (b[1]<<8);
|
||||
# }
|
||||
#
|
||||
#
|
||||
# static unsigned int
|
||||
# pe_get32 (fd, offset)
|
||||
# int fd;
|
||||
@ -740,7 +740,7 @@ compiler."
|
||||
# read (fd, b, 4);
|
||||
# return b[0] + (b[1]<<8) + (b[2]<<16) + (b[3]<<24);
|
||||
# }
|
||||
#
|
||||
#
|
||||
# static unsigned int
|
||||
# pe_as32 (ptr)
|
||||
# void *ptr;
|
||||
@ -748,7 +748,7 @@ compiler."
|
||||
# unsigned char *b = ptr;
|
||||
# return b[0] + (b[1]<<8) + (b[2]<<16) + (b[3]<<24);
|
||||
# }
|
||||
#
|
||||
#
|
||||
# int
|
||||
# main (argc, argv)
|
||||
# int argc;
|
||||
@ -760,32 +760,32 @@ compiler."
|
||||
# unsigned long name_rvas, nexp;
|
||||
# unsigned char *expdata, *erva;
|
||||
# char *filename, *dll_name;
|
||||
#
|
||||
#
|
||||
# filename = argv[1];
|
||||
#
|
||||
#
|
||||
# dll = open(filename, O_RDONLY|O_BINARY);
|
||||
# if (!dll)
|
||||
# return 1;
|
||||
#
|
||||
#
|
||||
# dll_name = filename;
|
||||
#
|
||||
#
|
||||
# for (i=0; filename[i]; i++)
|
||||
# if (filename[i] == '/' || filename[i] == '\\' || filename[i] == ':')
|
||||
# dll_name = filename + i +1;
|
||||
#
|
||||
#
|
||||
# pe_header_offset = pe_get32 (dll, 0x3c);
|
||||
# opthdr_ofs = pe_header_offset + 4 + 20;
|
||||
# num_entries = pe_get32 (dll, opthdr_ofs + 92);
|
||||
#
|
||||
#
|
||||
# if (num_entries < 1) /* no exports */
|
||||
# return 1;
|
||||
#
|
||||
#
|
||||
# export_rva = pe_get32 (dll, opthdr_ofs + 96);
|
||||
# export_size = pe_get32 (dll, opthdr_ofs + 100);
|
||||
# nsections = pe_get16 (dll, pe_header_offset + 4 +2);
|
||||
# secptr = (pe_header_offset + 4 + 20 +
|
||||
# pe_get16 (dll, pe_header_offset + 4 + 16));
|
||||
#
|
||||
#
|
||||
# expptr = 0;
|
||||
# for (i = 0; i < nsections; i++)
|
||||
# {
|
||||
@ -804,22 +804,22 @@ compiler."
|
||||
# break;
|
||||
# }
|
||||
# }
|
||||
#
|
||||
#
|
||||
# expdata = (unsigned char*)malloc(export_size);
|
||||
# lseek (dll, expptr, SEEK_SET);
|
||||
# read (dll, expdata, export_size);
|
||||
# erva = expdata - export_rva;
|
||||
#
|
||||
#
|
||||
# nexp = pe_as32 (expdata+24);
|
||||
# name_rvas = pe_as32 (expdata+32);
|
||||
#
|
||||
#
|
||||
# printf ("EXPORTS\n");
|
||||
# for (i = 0; i<nexp; i++)
|
||||
# {
|
||||
# unsigned long name_rva = pe_as32 (erva+name_rvas+i*4);
|
||||
# printf ("\t%s @ %ld ;\n", erva+name_rva, 1+ i);
|
||||
# }
|
||||
#
|
||||
#
|
||||
# return 0;
|
||||
# }
|
||||
# /* impgen.c ends here */
|
||||
@ -849,7 +849,7 @@ compiler."
|
||||
# now prepend the system-specific ones
|
||||
eval lib_search_path=\"$sys_lib_search_path_spec\$lib_search_path\"
|
||||
eval sys_lib_dlsearch_path=\"$sys_lib_dlsearch_path_spec\"
|
||||
|
||||
|
||||
avoid_version=no
|
||||
dlfiles=
|
||||
dlprefiles=
|
||||
@ -1351,7 +1351,7 @@ compiler."
|
||||
fi
|
||||
;;
|
||||
esac
|
||||
|
||||
|
||||
# This is the magic to use -rpath.
|
||||
# Skip directories that are in the system default run-time
|
||||
# search path, unless they have been requested with -R.
|
||||
@ -1360,7 +1360,7 @@ compiler."
|
||||
*)
|
||||
case "$compile_rpath " in
|
||||
*" $absdir "*) ;;
|
||||
*) compile_rpath="$compile_rpath $absdir"
|
||||
*) compile_rpath="$compile_rpath $absdir"
|
||||
esac
|
||||
;;
|
||||
esac
|
||||
@ -1797,7 +1797,7 @@ compiler."
|
||||
versuffix=
|
||||
verstring=""
|
||||
fi
|
||||
|
||||
|
||||
# Check to see if the archive will have undefined symbols.
|
||||
if test "$allow_undefined" = yes; then
|
||||
if test "$allow_undefined_flag" = unsupported; then
|
||||
@ -1956,7 +1956,7 @@ EOF
|
||||
# Follow soft links.
|
||||
if ls -lLd "$potent_lib" 2>/dev/null \
|
||||
| grep " -> " >/dev/null; then
|
||||
continue
|
||||
continue
|
||||
fi
|
||||
# The statement above tries to avoid entering an
|
||||
# endless loop below, in case of cyclic links.
|
||||
@ -2051,7 +2051,7 @@ EOF
|
||||
library_names=
|
||||
old_library=
|
||||
dlname=
|
||||
|
||||
|
||||
# Test again, we may have decided not to build it any more
|
||||
if test "$build_libtool_libs" = yes; then
|
||||
# Get the real and link names of the library.
|
||||
@ -2250,7 +2250,7 @@ EOF
|
||||
gentop=
|
||||
# reload_cmds runs $LD directly, so let us get rid of
|
||||
# -Wl from whole_archive_flag_spec
|
||||
wl=
|
||||
wl=
|
||||
|
||||
if test -n "$convenience"; then
|
||||
if test -n "$whole_archive_flag_spec"; then
|
||||
@ -2378,9 +2378,9 @@ EOF
|
||||
if test "$dlopen" = unknown && test "$dlopen_self" = unknown &&
|
||||
test "$dlopen_self_static" = unknown; then
|
||||
$echo "$modename: warning: \`AC_LIBTOOL_DLOPEN' not used. Assuming no dlopen support."
|
||||
fi
|
||||
fi
|
||||
fi
|
||||
|
||||
|
||||
if test -n "$rpath$xrpath"; then
|
||||
# If the user specified any rpath flags, then add them.
|
||||
for libdir in $rpath $xrpath; do
|
||||
@ -2544,7 +2544,7 @@ extern \"C\" {
|
||||
$run eval 'egrep -v " ($exclude_expsyms)$" "$nlist" > "$nlist"T'
|
||||
$run eval '$mv "$nlist"T "$nlist"'
|
||||
fi
|
||||
|
||||
|
||||
if test -n "$export_symbols_regex"; then
|
||||
$run eval 'egrep -e "$export_symbols_regex" "$nlist" > "$nlist"T'
|
||||
$run eval '$mv "$nlist"T "$nlist"'
|
||||
@ -2687,7 +2687,7 @@ static const void *lt_preloaded_setup() {
|
||||
$show "$link_command"
|
||||
$run eval "$link_command"
|
||||
status=$?
|
||||
|
||||
|
||||
# Delete the generated files.
|
||||
if test -n "$dlsyms"; then
|
||||
$show "$rm $output_objdir/${outputname}S.${objext}"
|
||||
@ -2747,7 +2747,7 @@ static const void *lt_preloaded_setup() {
|
||||
# Fast installation is not supported
|
||||
link_command="$compile_var$compile_command$compile_rpath"
|
||||
relink_command="$finalize_var$finalize_command$finalize_rpath"
|
||||
|
||||
|
||||
$echo "$modename: warning: this platform does not like uninstalled shared libraries" 1>&2
|
||||
$echo "$modename: \`$output' will be relinked during installation" 1>&2
|
||||
else
|
||||
@ -2767,7 +2767,7 @@ static const void *lt_preloaded_setup() {
|
||||
|
||||
# Replace the output file specification.
|
||||
link_command=`$echo "X$link_command" | $Xsed -e 's%@OUTPUT@%'"$output_objdir/$outputname"'%g'`
|
||||
|
||||
|
||||
# Delete the old output files.
|
||||
$run $rm $output $output_objdir/$outputname $output_objdir/lt-$outputname
|
||||
|
||||
@ -2880,7 +2880,7 @@ else
|
||||
echo >> $output "\
|
||||
program=lt-'$outputname'
|
||||
progdir=\"\$thisdir/$objdir\"
|
||||
|
||||
|
||||
if test ! -f \"\$progdir/\$program\" || \\
|
||||
{ file=\`ls -1dt \"\$progdir/\$program\" \"\$progdir/../\$program\" 2>/dev/null | sed 1q\`; \\
|
||||
test \"X\$file\" != \"X\$progdir/\$program\"; }; then
|
||||
@ -3011,7 +3011,7 @@ fi\
|
||||
exit $status
|
||||
fi
|
||||
generated="$generated $gentop"
|
||||
|
||||
|
||||
# Add in members from convenience archives.
|
||||
for xlib in $addlibs; do
|
||||
# Extract the objects.
|
||||
|
@ -4100,7 +4100,7 @@ while test "$type"; do
|
||||
for fp in $gfpth; do
|
||||
if test "X$fp" = X.; then
|
||||
pf="$ansexp"
|
||||
else
|
||||
else
|
||||
pf="$fp/$ansexp"
|
||||
fi
|
||||
if test -f "$pf"; then
|
||||
@ -4121,7 +4121,7 @@ while test "$type"; do
|
||||
if test "X$fp" = X.; then
|
||||
dir="$ans"
|
||||
direxp="$ansexp"
|
||||
else
|
||||
else
|
||||
dir="$fp/$ansexp"
|
||||
direxp="$fp/$ansexp"
|
||||
fi
|
||||
@ -15773,7 +15773,7 @@ set gettimeofday d_gettimeod
|
||||
eval $inlibc
|
||||
case "$d_gettimeod" in
|
||||
"$undef")
|
||||
set ftime d_ftime
|
||||
set ftime d_ftime
|
||||
eval $inlibc
|
||||
;;
|
||||
*)
|
||||
|
@ -1,4 +1,4 @@
|
||||
/* $OpenBSD: cms_sd.c,v 1.26 2023/07/08 08:26:26 beck Exp $ */
|
||||
/* $OpenBSD: cms_sd.c,v 1.28 2023/09/11 09:29:30 tb Exp $ */
|
||||
/*
|
||||
* Written by Dr Stephen N Henson (steve@openssl.org) for the OpenSSL
|
||||
* project.
|
||||
@ -256,16 +256,16 @@ static int
|
||||
cms_sd_asn1_ctrl(CMS_SignerInfo *si, int cmd)
|
||||
{
|
||||
EVP_PKEY *pkey = si->pkey;
|
||||
int i;
|
||||
int ret;
|
||||
|
||||
if (!pkey->ameth || !pkey->ameth->pkey_ctrl)
|
||||
if (pkey->ameth == NULL || pkey->ameth->pkey_ctrl == NULL)
|
||||
return 1;
|
||||
i = pkey->ameth->pkey_ctrl(pkey, ASN1_PKEY_CTRL_CMS_SIGN, cmd, si);
|
||||
if (i == -2) {
|
||||
ret = pkey->ameth->pkey_ctrl(pkey, ASN1_PKEY_CTRL_CMS_SIGN, cmd, si);
|
||||
if (ret == -2) {
|
||||
CMSerror(CMS_R_NOT_SUPPORTED_FOR_THIS_KEY_TYPE);
|
||||
return 0;
|
||||
}
|
||||
if (i <= 0) {
|
||||
if (ret <= 0) {
|
||||
CMSerror(CMS_R_CTRL_FAILURE);
|
||||
return 0;
|
||||
}
|
||||
@ -721,119 +721,113 @@ cms_SignedData_final(CMS_ContentInfo *cms, BIO *chain)
|
||||
int
|
||||
CMS_SignerInfo_sign(CMS_SignerInfo *si)
|
||||
{
|
||||
EVP_MD_CTX *mctx = si->mctx;
|
||||
EVP_PKEY_CTX *pctx = NULL;
|
||||
unsigned char *abuf = NULL;
|
||||
int alen;
|
||||
size_t siglen;
|
||||
const EVP_MD *md = NULL;
|
||||
const EVP_MD *md;
|
||||
unsigned char *buf = NULL, *sig = NULL;
|
||||
int buf_len = 0;
|
||||
size_t sig_len = 0;
|
||||
int ret = 0;
|
||||
|
||||
md = EVP_get_digestbyobj(si->digestAlgorithm->algorithm);
|
||||
if (md == NULL)
|
||||
return 0;
|
||||
if ((md = EVP_get_digestbyobj(si->digestAlgorithm->algorithm)) == NULL)
|
||||
goto err;
|
||||
|
||||
if (CMS_signed_get_attr_by_NID(si, NID_pkcs9_signingTime, -1) < 0) {
|
||||
if (!cms_add1_signingTime(si, NULL))
|
||||
goto err;
|
||||
}
|
||||
|
||||
if (si->pctx)
|
||||
pctx = si->pctx;
|
||||
else {
|
||||
EVP_MD_CTX_reset(mctx);
|
||||
if (EVP_DigestSignInit(mctx, &pctx, md, NULL, si->pkey) <= 0)
|
||||
if (si->pctx == NULL) {
|
||||
EVP_MD_CTX_reset(si->mctx);
|
||||
if (!EVP_DigestSignInit(si->mctx, &si->pctx, md, NULL, si->pkey))
|
||||
goto err;
|
||||
si->pctx = pctx;
|
||||
}
|
||||
|
||||
if (EVP_PKEY_CTX_ctrl(pctx, -1, EVP_PKEY_OP_SIGN,
|
||||
if (EVP_PKEY_CTX_ctrl(si->pctx, -1, EVP_PKEY_OP_SIGN,
|
||||
EVP_PKEY_CTRL_CMS_SIGN, 0, si) <= 0) {
|
||||
CMSerror(CMS_R_CTRL_ERROR);
|
||||
goto err;
|
||||
}
|
||||
|
||||
alen = ASN1_item_i2d((ASN1_VALUE *)si->signedAttrs, &abuf,
|
||||
&CMS_Attributes_Sign_it);
|
||||
if (!abuf)
|
||||
if ((buf_len = ASN1_item_i2d((ASN1_VALUE *)si->signedAttrs, &buf,
|
||||
&CMS_Attributes_Sign_it)) <= 0) {
|
||||
buf_len = 0;
|
||||
goto err;
|
||||
if (EVP_DigestSignUpdate(mctx, abuf, alen) <= 0)
|
||||
}
|
||||
if (!EVP_DigestSign(si->mctx, NULL, &sig_len, buf, buf_len))
|
||||
goto err;
|
||||
if (EVP_DigestSignFinal(mctx, NULL, &siglen) <= 0)
|
||||
if ((sig = calloc(1, sig_len)) == NULL)
|
||||
goto err;
|
||||
free(abuf);
|
||||
abuf = malloc(siglen);
|
||||
if (abuf == NULL)
|
||||
goto err;
|
||||
if (EVP_DigestSignFinal(mctx, abuf, &siglen) <= 0)
|
||||
if (!EVP_DigestSign(si->mctx, sig, &sig_len, buf, buf_len))
|
||||
goto err;
|
||||
|
||||
if (EVP_PKEY_CTX_ctrl(pctx, -1, EVP_PKEY_OP_SIGN,
|
||||
if (EVP_PKEY_CTX_ctrl(si->pctx, -1, EVP_PKEY_OP_SIGN,
|
||||
EVP_PKEY_CTRL_CMS_SIGN, 1, si) <= 0) {
|
||||
CMSerror(CMS_R_CTRL_ERROR);
|
||||
goto err;
|
||||
}
|
||||
|
||||
EVP_MD_CTX_reset(mctx);
|
||||
ASN1_STRING_set0(si->signature, sig, sig_len);
|
||||
sig = NULL;
|
||||
|
||||
ASN1_STRING_set0(si->signature, abuf, siglen);
|
||||
|
||||
return 1;
|
||||
ret = 1;
|
||||
|
||||
err:
|
||||
free(abuf);
|
||||
EVP_MD_CTX_reset(mctx);
|
||||
if (si->mctx != NULL)
|
||||
EVP_MD_CTX_reset(si->mctx);
|
||||
freezero(buf, buf_len);
|
||||
freezero(sig, sig_len);
|
||||
|
||||
return 0;
|
||||
return ret;
|
||||
}
|
||||
LCRYPTO_ALIAS(CMS_SignerInfo_sign);
|
||||
|
||||
int
|
||||
CMS_SignerInfo_verify(CMS_SignerInfo *si)
|
||||
{
|
||||
EVP_MD_CTX *mctx = NULL;
|
||||
unsigned char *abuf = NULL;
|
||||
int alen, r = -1;
|
||||
const EVP_MD *md = NULL;
|
||||
const EVP_MD *md;
|
||||
unsigned char *buf = NULL;
|
||||
int buf_len = 0;
|
||||
int ret = -1;
|
||||
|
||||
if (!si->pkey) {
|
||||
if ((md = EVP_get_digestbyobj(si->digestAlgorithm->algorithm)) == NULL)
|
||||
goto err;
|
||||
|
||||
if (si->pkey == NULL) {
|
||||
CMSerror(CMS_R_NO_PUBLIC_KEY);
|
||||
return -1;
|
||||
goto err;
|
||||
}
|
||||
|
||||
md = EVP_get_digestbyobj(si->digestAlgorithm->algorithm);
|
||||
if (md == NULL)
|
||||
return -1;
|
||||
if (si->mctx == NULL && (si->mctx = EVP_MD_CTX_new()) == NULL) {
|
||||
if (si->mctx == NULL)
|
||||
si->mctx = EVP_MD_CTX_new();
|
||||
if (si->mctx == NULL) {
|
||||
CMSerror(ERR_R_MALLOC_FAILURE);
|
||||
return -1;
|
||||
goto err;
|
||||
}
|
||||
mctx = si->mctx;
|
||||
if (EVP_DigestVerifyInit(mctx, &si->pctx, md, NULL, si->pkey) <= 0)
|
||||
|
||||
if (EVP_DigestVerifyInit(si->mctx, &si->pctx, md, NULL, si->pkey) <= 0)
|
||||
goto err;
|
||||
|
||||
if (!cms_sd_asn1_ctrl(si, 1))
|
||||
goto err;
|
||||
|
||||
alen = ASN1_item_i2d((ASN1_VALUE *)si->signedAttrs, &abuf,
|
||||
&CMS_Attributes_Verify_it);
|
||||
if (!abuf)
|
||||
goto err;
|
||||
r = EVP_DigestVerifyUpdate(mctx, abuf, alen);
|
||||
free(abuf);
|
||||
if (r <= 0) {
|
||||
r = -1;
|
||||
if ((buf_len = ASN1_item_i2d((ASN1_VALUE *)si->signedAttrs, &buf,
|
||||
&CMS_Attributes_Verify_it)) <= 0) {
|
||||
buf_len = 0;
|
||||
goto err;
|
||||
}
|
||||
|
||||
r = EVP_DigestVerifyFinal(mctx, si->signature->data,
|
||||
si->signature->length);
|
||||
if (r <= 0)
|
||||
ret = EVP_DigestVerify(si->mctx, si->signature->data, si->signature->length,
|
||||
buf, buf_len);
|
||||
if (ret <= 0) {
|
||||
CMSerror(CMS_R_VERIFICATION_FAILURE);
|
||||
goto err;
|
||||
}
|
||||
|
||||
err:
|
||||
EVP_MD_CTX_reset(mctx);
|
||||
if (si->mctx != NULL)
|
||||
EVP_MD_CTX_reset(si->mctx);
|
||||
freezero(buf, buf_len);
|
||||
|
||||
return r;
|
||||
return ret;
|
||||
}
|
||||
LCRYPTO_ALIAS(CMS_SignerInfo_verify);
|
||||
|
||||
|
@ -1,4 +1,4 @@
|
||||
/* $OpenBSD: evp_enc.c,v 1.52 2023/07/07 19:37:53 beck Exp $ */
|
||||
/* $OpenBSD: evp_enc.c,v 1.53 2023/09/10 16:53:56 tb Exp $ */
|
||||
/* Copyright (C) 1995-1998 Eric Young (eay@cryptsoft.com)
|
||||
* All rights reserved.
|
||||
*
|
||||
@ -78,8 +78,8 @@ int
|
||||
EVP_CipherInit(EVP_CIPHER_CTX *ctx, const EVP_CIPHER *cipher,
|
||||
const unsigned char *key, const unsigned char *iv, int enc)
|
||||
{
|
||||
if (cipher)
|
||||
EVP_CIPHER_CTX_init(ctx);
|
||||
if (cipher != NULL)
|
||||
EVP_CIPHER_CTX_cleanup(ctx);
|
||||
return EVP_CipherInit_ex(ctx, cipher, NULL, key, iv, enc);
|
||||
}
|
||||
|
||||
|
@ -1,4 +1,4 @@
|
||||
/* $OpenBSD: p_lib.c,v 1.36 2023/09/02 04:15:39 tb Exp $ */
|
||||
/* $OpenBSD: p_lib.c,v 1.37 2023/09/10 17:32:17 tb Exp $ */
|
||||
/* Copyright (C) 1995-1998 Eric Young (eay@cryptsoft.com)
|
||||
* All rights reserved.
|
||||
*
|
||||
@ -449,13 +449,14 @@ EVP_PKEY_get0_RSA(EVP_PKEY *pkey)
|
||||
RSA *
|
||||
EVP_PKEY_get1_RSA(EVP_PKEY *pkey)
|
||||
{
|
||||
if (pkey->type == EVP_PKEY_RSA || pkey->type == EVP_PKEY_RSA_PSS) {
|
||||
RSA_up_ref(pkey->pkey.rsa);
|
||||
return pkey->pkey.rsa;
|
||||
}
|
||||
RSA *rsa;
|
||||
|
||||
EVPerror(EVP_R_EXPECTING_AN_RSA_KEY);
|
||||
return NULL;
|
||||
if ((rsa = EVP_PKEY_get0_RSA(pkey)) == NULL)
|
||||
return NULL;
|
||||
|
||||
RSA_up_ref(rsa);
|
||||
|
||||
return rsa;
|
||||
}
|
||||
|
||||
int
|
||||
@ -482,12 +483,14 @@ EVP_PKEY_get0_DSA(EVP_PKEY *pkey)
|
||||
DSA *
|
||||
EVP_PKEY_get1_DSA(EVP_PKEY *pkey)
|
||||
{
|
||||
if (pkey->type != EVP_PKEY_DSA) {
|
||||
EVPerror(EVP_R_EXPECTING_A_DSA_KEY);
|
||||
DSA *dsa;
|
||||
|
||||
if ((dsa = EVP_PKEY_get0_DSA(pkey)) == NULL)
|
||||
return NULL;
|
||||
}
|
||||
DSA_up_ref(pkey->pkey.dsa);
|
||||
return pkey->pkey.dsa;
|
||||
|
||||
DSA_up_ref(dsa);
|
||||
|
||||
return dsa;
|
||||
}
|
||||
|
||||
int
|
||||
@ -514,12 +517,14 @@ EVP_PKEY_get0_EC_KEY(EVP_PKEY *pkey)
|
||||
EC_KEY *
|
||||
EVP_PKEY_get1_EC_KEY(EVP_PKEY *pkey)
|
||||
{
|
||||
if (pkey->type != EVP_PKEY_EC) {
|
||||
EVPerror(EVP_R_EXPECTING_A_EC_KEY);
|
||||
EC_KEY *key;
|
||||
|
||||
if ((key = EVP_PKEY_get0_EC_KEY(pkey)) == NULL)
|
||||
return NULL;
|
||||
}
|
||||
EC_KEY_up_ref(pkey->pkey.ec);
|
||||
return pkey->pkey.ec;
|
||||
|
||||
EC_KEY_up_ref(key);
|
||||
|
||||
return key;
|
||||
}
|
||||
|
||||
int
|
||||
@ -547,12 +552,14 @@ EVP_PKEY_get0_DH(EVP_PKEY *pkey)
|
||||
DH *
|
||||
EVP_PKEY_get1_DH(EVP_PKEY *pkey)
|
||||
{
|
||||
if (pkey->type != EVP_PKEY_DH) {
|
||||
EVPerror(EVP_R_EXPECTING_A_DH_KEY);
|
||||
DH *dh;
|
||||
|
||||
if ((dh = EVP_PKEY_get0_DH(pkey)) == NULL)
|
||||
return NULL;
|
||||
}
|
||||
DH_up_ref(pkey->pkey.dh);
|
||||
return pkey->pkey.dh;
|
||||
|
||||
DH_up_ref(dh);
|
||||
|
||||
return dh;
|
||||
}
|
||||
|
||||
int
|
||||
|
@ -1,4 +1,4 @@
|
||||
.\" $OpenBSD: BIO_f_base64.3,v 1.14 2023/09/10 11:20:52 schwarze Exp $
|
||||
.\" $OpenBSD: BIO_f_base64.3,v 1.15 2023/09/11 04:00:40 jsg Exp $
|
||||
.\" OpenSSL fc1d88f0 Wed Jul 2 22:42:40 2014 -0400
|
||||
.\"
|
||||
.\" This file was written by Dr. Stephen Henson <steve@openssl.org>.
|
||||
@ -49,14 +49,14 @@
|
||||
.\" ARISING IN ANY WAY OUT OF THE USE OF THIS SOFTWARE, EVEN IF ADVISED
|
||||
.\" OF THE POSSIBILITY OF SUCH DAMAGE.
|
||||
.\"
|
||||
.Dd $Mdocdate: September 10 2023 $
|
||||
.Dd $Mdocdate: September 11 2023 $
|
||||
.Dt BIO_F_BASE64 3
|
||||
.Os
|
||||
.Sh NAME
|
||||
.Nm BIO_f_base64
|
||||
.\" .Nm EVP_ENCODE_LENGTH and
|
||||
.\" .Nm EVP_DECODE_LENGTH are intentionally undocumented
|
||||
.\" because they are internal implemention details of BIO_f_base64(3)
|
||||
.\" because they are internal implementation details of BIO_f_base64(3)
|
||||
.\" and practically unused outside evp/bio_b64.c.
|
||||
.Nd base64 BIO filter
|
||||
.Sh SYNOPSIS
|
||||
|
@ -1,4 +1,4 @@
|
||||
/* $OpenBSD: x509_addr.c,v 1.88 2023/09/06 15:53:07 job Exp $ */
|
||||
/* $OpenBSD: x509_addr.c,v 1.89 2023/09/11 00:50:47 job Exp $ */
|
||||
/*
|
||||
* Contributed to the OpenSSL Project by the American Registry for
|
||||
* Internet Numbers ("ARIN").
|
||||
@ -676,10 +676,9 @@ i2r_IPAddrBlocks(const X509V3_EXT_METHOD *method, void *ext, BIO *out,
|
||||
{
|
||||
const IPAddrBlocks *addr = ext;
|
||||
IPAddressFamily *af;
|
||||
uint16_t afi = 0;
|
||||
uint8_t safi = 0;
|
||||
int safi_is_set = 0;
|
||||
int i;
|
||||
uint16_t afi;
|
||||
uint8_t safi;
|
||||
int i, safi_is_set;
|
||||
|
||||
for (i = 0; i < sk_IPAddressFamily_num(addr); i++) {
|
||||
af = sk_IPAddressFamily_value(addr, i);
|
||||
|
@ -1,4 +1,4 @@
|
||||
/* $OpenBSD: resolver.c,v 1.160 2023/04/18 09:57:51 florian Exp $ */
|
||||
/* $OpenBSD: resolver.c,v 1.161 2023/09/11 06:00:23 florian Exp $ */
|
||||
|
||||
|
||||
/*
|
||||
@ -920,6 +920,8 @@ resolve_done(struct uw_resolver *res, void *arg, int rcode,
|
||||
uint8_t *p, *data;
|
||||
uint8_t answer_imsg[MAX_IMSGSIZE - IMSG_HEADER_SIZE];
|
||||
|
||||
log_debug("%s: %d", __func__, rcode);
|
||||
|
||||
clock_gettime(CLOCK_MONOTONIC, &tp);
|
||||
|
||||
query_imsg = (struct query_imsg *)arg;
|
||||
@ -1074,14 +1076,17 @@ resolve_done(struct uw_resolver *res, void *arg, int rcode,
|
||||
goto out;
|
||||
|
||||
servfail:
|
||||
log_debug("%s: foo: 1", __func__);
|
||||
/* try_next_resolver() might free rq */
|
||||
if (try_next_resolver(rq) != 0 && running_res == 0) {
|
||||
/* we are the last one, send SERVFAIL */
|
||||
answer_header->srvfail = 1;
|
||||
log_debug("%s: foo: 2", __func__);
|
||||
resolver_imsg_compose_frontend(IMSG_ANSWER, 0,
|
||||
answer_imsg, sizeof(*answer_header));
|
||||
}
|
||||
out:
|
||||
log_debug("%s: foo: 3", __func__);
|
||||
free(query_imsg);
|
||||
sldns_buffer_free(buf);
|
||||
regional_destroy(region);
|
||||
|
@ -1,4 +1,4 @@
|
||||
.\" $OpenBSD: aplns.4,v 1.1 2021/05/28 04:49:44 dlg Exp $
|
||||
.\" $OpenBSD: aplns.4,v 1.2 2023/09/11 04:21:30 jsg Exp $
|
||||
.\"
|
||||
.\" Copyright (c) 2021 David Gwynne <dlg@openbsd.org>
|
||||
.\"
|
||||
@ -14,19 +14,19 @@
|
||||
.\" ACTION OF CONTRACT, NEGLIGENCE OR OTHER TORTIOUS ACTION, ARISING OUT OF
|
||||
.\" OR IN CONNECTION WITH THE USE OR PERFORMANCE OF THIS SOFTWARE.
|
||||
.\"
|
||||
.Dd $Mdocdate: May 28 2021 $
|
||||
.Dd $Mdocdate: September 11 2023 $
|
||||
.Dt APLNS 4 arm64
|
||||
.Os
|
||||
.Sh NAME
|
||||
.Nm aplns
|
||||
.Nd Apple NVME Storage controller
|
||||
.Nd Apple NVMe Storage controller
|
||||
.Sh SYNOPSIS
|
||||
.Cd "aplns* at fdt?"
|
||||
.Cd "nvme* at aplns?"
|
||||
.Sh DESCRIPTION
|
||||
The
|
||||
.Nm
|
||||
driver provides support for the NVME Storage controller found on
|
||||
driver provides support for the NVMe Storage controller found on
|
||||
various Apple SoCs.
|
||||
.Sh SEE ALSO
|
||||
.Xr intro 4 ,
|
||||
|
@ -1,4 +1,4 @@
|
||||
.\" $OpenBSD: ie.4,v 1.16 2008/09/07 06:55:35 jmc Exp $
|
||||
.\" $OpenBSD: ie.4,v 1.17 2023/09/11 04:56:31 jsg Exp $
|
||||
.\"
|
||||
.\" Copyright (c) 1994 James A. Jegers
|
||||
.\" All rights reserved.
|
||||
@ -22,7 +22,7 @@
|
||||
.\" (INCLUDING NEGLIGENCE OR OTHERWISE) ARISING IN ANY WAY OUT OF THE USE OF
|
||||
.\" THIS SOFTWARE, EVEN IF ADVISED OF THE POSSIBILITY OF SUCH DAMAGE.
|
||||
.\"
|
||||
.Dd $Mdocdate: September 7 2008 $
|
||||
.Dd $Mdocdate: September 11 2023 $
|
||||
.Dt IE 4 i386
|
||||
.Os
|
||||
.Sh NAME
|
||||
@ -41,7 +41,7 @@ This includes the following network adapters:
|
||||
.It 3Com 3C507
|
||||
.It AT&T StarLAN 10
|
||||
.It AT&T EN100
|
||||
.It AT&T StarLan Fiber
|
||||
.It AT&T StarLAN Fiber
|
||||
.It Intel EtherExpress 16
|
||||
.El
|
||||
.Pp
|
||||
|
@ -1,4 +1,4 @@
|
||||
.\" $OpenBSD: neo.4,v 1.13 2007/05/31 19:19:51 jmc Exp $
|
||||
.\" $OpenBSD: neo.4,v 1.14 2023/09/11 05:07:34 jsg Exp $
|
||||
.\"
|
||||
.\" Copyright (c) 1998 Constantine Paul Sapuntzakis
|
||||
.\" All rights reserved
|
||||
@ -29,7 +29,7 @@
|
||||
.\" ARISING IN ANY WAY OUT OF THE USE OF THIS SOFTWARE, EVEN IF ADVISED OF THE
|
||||
.\" POSSIBILITY OF SUCH DAMAGE.
|
||||
.\"
|
||||
.Dd $Mdocdate: May 31 2007 $
|
||||
.Dd $Mdocdate: September 11 2023 $
|
||||
.Dt NEO 4
|
||||
.Os
|
||||
.Sh NAME
|
||||
@ -61,7 +61,7 @@ The
|
||||
device driver appeared in
|
||||
.Ox 2.7 .
|
||||
.Sh BUGS
|
||||
This driver has some bugs because Neomagic refuses to provide documentation,
|
||||
This driver has some bugs because NeoMagic refuses to provide documentation,
|
||||
even though they are discontinuing their products.
|
||||
At the time of contact, all persons working at the company were hiding
|
||||
behind their receptionist as if in a stage of siege.
|
||||
|
@ -36,7 +36,7 @@ umask 007
|
||||
|
||||
if [ ! -r version -o ! -s version ]
|
||||
then
|
||||
echo 1337 > version
|
||||
echo 0 > version
|
||||
fi
|
||||
|
||||
touch version
|
||||
|
@ -1,4 +1,4 @@
|
||||
/* $OpenBSD: if_ep_eisa.c,v 1.28 2022/04/06 18:59:28 naddy Exp $ */
|
||||
/* $OpenBSD: if_ep_eisa.c,v 1.29 2023/09/11 08:41:26 mvs Exp $ */
|
||||
/* $NetBSD: if_ep_eisa.c,v 1.13 1997/04/18 00:50:33 cgd Exp $ */
|
||||
|
||||
/*
|
||||
@ -41,7 +41,6 @@
|
||||
#include <sys/ioctl.h>
|
||||
#include <sys/errno.h>
|
||||
#include <sys/syslog.h>
|
||||
#include <sys/selinfo.h>
|
||||
#include <sys/timeout.h>
|
||||
#include <sys/device.h>
|
||||
|
||||
|
@ -1,4 +1,4 @@
|
||||
/* $OpenBSD: rkdrm.c,v 1.16 2023/09/10 06:25:09 jsg Exp $ */
|
||||
/* $OpenBSD: rkdrm.c,v 1.17 2023/09/11 04:51:24 jsg Exp $ */
|
||||
/* $NetBSD: rk_drm.c,v 1.3 2019/12/15 01:00:58 mrg Exp $ */
|
||||
/*-
|
||||
* Copyright (c) 2019 Jared D. McNeill <jmcneill@invisible.ca>
|
||||
@ -47,9 +47,6 @@
|
||||
#define RK_DRM_MAX_WIDTH 3840
|
||||
#define RK_DRM_MAX_HEIGHT 2160
|
||||
|
||||
TAILQ_HEAD(, rkdrm_ports) rkdrm_ports =
|
||||
TAILQ_HEAD_INITIALIZER(rkdrm_ports);
|
||||
|
||||
int rkdrm_match(struct device *, void *, void *);
|
||||
void rkdrm_attach(struct device *, struct device *, void *);
|
||||
void rkdrm_attachhook(struct device *);
|
||||
|
@ -1,4 +1,4 @@
|
||||
/* $OpenBSD: rkdrm.h,v 1.3 2023/01/01 01:34:33 jsg Exp $ */
|
||||
/* $OpenBSD: rkdrm.h,v 1.4 2023/09/11 04:51:24 jsg Exp $ */
|
||||
/* $NetBSD: rk_drm.h,v 1.1 2019/11/09 23:30:14 jmcneill Exp $ */
|
||||
/*-
|
||||
* Copyright (c) 2019 Jared D. McNeill <jmcneill@invisible.ca>
|
||||
@ -86,12 +86,6 @@ struct rkdrm_framebuffer {
|
||||
struct drm_gem_dma_object *obj;
|
||||
};
|
||||
|
||||
struct rkdrm_ports {
|
||||
int phandle;
|
||||
struct drm_device *ddev;
|
||||
TAILQ_ENTRY(rkdrm_ports) entries;
|
||||
};
|
||||
|
||||
struct rkdrm_fbdev {
|
||||
struct drm_fb_helper helper;
|
||||
};
|
||||
|
@ -1,4 +1,4 @@
|
||||
/* $OpenBSD: aac.c,v 1.95 2023/07/13 07:31:12 jsg Exp $ */
|
||||
/* $OpenBSD: aac.c,v 1.96 2023/09/11 12:10:47 mvs Exp $ */
|
||||
|
||||
/*-
|
||||
* Copyright (c) 2000 Michael Smith
|
||||
@ -53,7 +53,6 @@
|
||||
#include <sys/kthread.h>
|
||||
#include <sys/malloc.h>
|
||||
#include <sys/rwlock.h>
|
||||
#include <sys/selinfo.h>
|
||||
#include <sys/time.h>
|
||||
|
||||
#include <machine/bus.h>
|
||||
|
@ -1,4 +1,4 @@
|
||||
/* $OpenBSD: aacvar.h,v 1.17 2023/07/13 07:31:12 jsg Exp $ */
|
||||
/* $OpenBSD: aacvar.h,v 1.18 2023/09/11 08:40:25 mvs Exp $ */
|
||||
|
||||
/*-
|
||||
* Copyright (c) 2000 Michael Smith
|
||||
@ -395,7 +395,6 @@ struct aac_softc
|
||||
struct aac_aif_command aac_aifq[AAC_AIFQ_LENGTH];
|
||||
int aac_aifq_head;
|
||||
int aac_aifq_tail;
|
||||
struct selinfo aac_select;
|
||||
struct proc *aifthread;
|
||||
int aifflags;
|
||||
#define AAC_AIFFLAGS_RUNNING (1 << 0)
|
||||
|
@ -1,4 +1,4 @@
|
||||
/* $OpenBSD: com.c,v 1.177 2023/05/23 16:39:29 denis Exp $ */
|
||||
/* $OpenBSD: com.c,v 1.178 2023/09/11 08:41:26 mvs Exp $ */
|
||||
/* $NetBSD: com.c,v 1.82.4.1 1996/06/02 09:08:00 mrg Exp $ */
|
||||
|
||||
/*
|
||||
@ -65,7 +65,6 @@
|
||||
#include <sys/param.h>
|
||||
#include <sys/systm.h>
|
||||
#include <sys/ioctl.h>
|
||||
#include <sys/selinfo.h>
|
||||
#include <sys/tty.h>
|
||||
#include <sys/conf.h>
|
||||
#include <sys/fcntl.h>
|
||||
|
@ -1,4 +1,4 @@
|
||||
/* $OpenBSD: cy.c,v 1.41 2021/09/01 16:10:39 jan Exp $ */
|
||||
/* $OpenBSD: cy.c,v 1.42 2023/09/11 08:41:26 mvs Exp $ */
|
||||
/*
|
||||
* Copyright (c) 1996 Timo Rossi.
|
||||
* All rights reserved.
|
||||
@ -56,7 +56,6 @@
|
||||
#include <sys/fcntl.h>
|
||||
#include <sys/tty.h>
|
||||
#include <sys/conf.h>
|
||||
#include <sys/selinfo.h>
|
||||
#include <sys/device.h>
|
||||
#include <sys/malloc.h>
|
||||
#include <sys/systm.h>
|
||||
|
@ -1,4 +1,4 @@
|
||||
/* $OpenBSD: elink3.c,v 1.99 2023/04/11 00:45:08 jsg Exp $ */
|
||||
/* $OpenBSD: elink3.c,v 1.100 2023/09/11 08:41:26 mvs Exp $ */
|
||||
/* $NetBSD: elink3.c,v 1.32 1997/05/14 00:22:00 thorpej Exp $ */
|
||||
|
||||
/*
|
||||
@ -41,7 +41,6 @@
|
||||
#include <sys/ioctl.h>
|
||||
#include <sys/errno.h>
|
||||
#include <sys/syslog.h>
|
||||
#include <sys/selinfo.h>
|
||||
#include <sys/timeout.h>
|
||||
#include <sys/device.h>
|
||||
|
||||
|
@ -1,4 +1,4 @@
|
||||
/* $OpenBSD: if_ef_isapnp.c,v 1.41 2022/04/06 18:59:28 naddy Exp $ */
|
||||
/* $OpenBSD: if_ef_isapnp.c,v 1.42 2023/09/11 08:41:26 mvs Exp $ */
|
||||
|
||||
/*
|
||||
* Copyright (c) 1999 Jason L. Wright (jason@thought.net)
|
||||
@ -35,7 +35,6 @@
|
||||
#include <sys/ioctl.h>
|
||||
#include <sys/errno.h>
|
||||
#include <sys/syslog.h>
|
||||
#include <sys/selinfo.h>
|
||||
#include <sys/device.h>
|
||||
#include <sys/queue.h>
|
||||
#include <sys/kernel.h>
|
||||
|
@ -1,4 +1,4 @@
|
||||
/* $OpenBSD: if_eg.c,v 1.51 2022/04/06 18:59:28 naddy Exp $ */
|
||||
/* $OpenBSD: if_eg.c,v 1.52 2023/09/11 08:41:26 mvs Exp $ */
|
||||
/* $NetBSD: if_eg.c,v 1.26 1996/05/12 23:52:27 mycroft Exp $ */
|
||||
|
||||
/*
|
||||
@ -47,7 +47,6 @@
|
||||
#include <sys/errno.h>
|
||||
#include <sys/syslog.h>
|
||||
#include <sys/systm.h>
|
||||
#include <sys/selinfo.h>
|
||||
#include <sys/device.h>
|
||||
|
||||
#include <net/if.h>
|
||||
|
@ -1,4 +1,4 @@
|
||||
/* $OpenBSD: if_ep_isa.c,v 1.32 2022/04/06 18:59:28 naddy Exp $ */
|
||||
/* $OpenBSD: if_ep_isa.c,v 1.33 2023/09/11 08:41:26 mvs Exp $ */
|
||||
/* $NetBSD: if_ep_isa.c,v 1.5 1996/05/12 23:52:36 mycroft Exp $ */
|
||||
|
||||
/*
|
||||
@ -45,7 +45,6 @@
|
||||
#include <sys/ioctl.h>
|
||||
#include <sys/errno.h>
|
||||
#include <sys/syslog.h>
|
||||
#include <sys/selinfo.h>
|
||||
#include <sys/timeout.h>
|
||||
#include <sys/device.h>
|
||||
#include <sys/queue.h>
|
||||
|
@ -1,4 +1,4 @@
|
||||
/* $OpenBSD: if_ep_isapnp.c,v 1.17 2022/04/06 18:59:28 naddy Exp $ */
|
||||
/* $OpenBSD: if_ep_isapnp.c,v 1.18 2023/09/11 08:41:26 mvs Exp $ */
|
||||
/* $NetBSD: if_ep_isapnp.c,v 1.5 1996/05/12 23:52:36 mycroft Exp $ */
|
||||
|
||||
/*
|
||||
@ -45,7 +45,6 @@
|
||||
#include <sys/ioctl.h>
|
||||
#include <sys/errno.h>
|
||||
#include <sys/syslog.h>
|
||||
#include <sys/selinfo.h>
|
||||
#include <sys/device.h>
|
||||
#include <sys/timeout.h>
|
||||
#include <sys/queue.h>
|
||||
|
@ -1,4 +1,4 @@
|
||||
/* $OpenBSD: if_lc_isa.c,v 1.14 2022/04/06 18:59:28 naddy Exp $ */
|
||||
/* $OpenBSD: if_lc_isa.c,v 1.15 2023/09/11 08:41:26 mvs Exp $ */
|
||||
/* $NetBSD: if_lc_isa.c,v 1.10 2001/06/13 10:46:03 wiz Exp $ */
|
||||
|
||||
/*-
|
||||
@ -42,7 +42,6 @@
|
||||
#include <sys/ioctl.h>
|
||||
#include <sys/errno.h>
|
||||
#include <sys/syslog.h>
|
||||
#include <sys/selinfo.h>
|
||||
#include <sys/device.h>
|
||||
#include <sys/queue.h>
|
||||
|
||||
|
@ -1,4 +1,4 @@
|
||||
/* $OpenBSD: if_ne_isa.c,v 1.18 2022/04/06 18:59:28 naddy Exp $ */
|
||||
/* $OpenBSD: if_ne_isa.c,v 1.19 2023/09/11 08:41:26 mvs Exp $ */
|
||||
/* $NetBSD: if_ne_isa.c,v 1.6 1998/07/05 06:49:13 jonathan Exp $ */
|
||||
|
||||
/*-
|
||||
@ -40,7 +40,6 @@
|
||||
#include <sys/ioctl.h>
|
||||
#include <sys/errno.h>
|
||||
#include <sys/syslog.h>
|
||||
#include <sys/selinfo.h>
|
||||
#include <sys/device.h>
|
||||
|
||||
#include <net/if.h>
|
||||
|
@ -1,4 +1,4 @@
|
||||
/* $OpenBSD: if_ne_isapnp.c,v 1.17 2022/04/06 18:59:28 naddy Exp $ */
|
||||
/* $OpenBSD: if_ne_isapnp.c,v 1.18 2023/09/11 08:41:26 mvs Exp $ */
|
||||
/* $NetBSD: if_ne_isapnp.c,v 1.7 1998/07/23 19:30:45 christos Exp $ */
|
||||
|
||||
/*-
|
||||
@ -40,7 +40,6 @@
|
||||
#include <sys/ioctl.h>
|
||||
#include <sys/errno.h>
|
||||
#include <sys/syslog.h>
|
||||
#include <sys/selinfo.h>
|
||||
#include <sys/device.h>
|
||||
|
||||
#include <net/if.h>
|
||||
|
@ -1,4 +1,4 @@
|
||||
/* $OpenBSD: if_sm_isa.c,v 1.16 2022/04/06 18:59:28 naddy Exp $ */
|
||||
/* $OpenBSD: if_sm_isa.c,v 1.17 2023/09/11 08:41:26 mvs Exp $ */
|
||||
/* $NetBSD: if_sm_isa.c,v 1.4 1998/07/05 06:49:14 jonathan Exp $ */
|
||||
|
||||
/*-
|
||||
@ -40,7 +40,6 @@
|
||||
#include <sys/ioctl.h>
|
||||
#include <sys/errno.h>
|
||||
#include <sys/syslog.h>
|
||||
#include <sys/selinfo.h>
|
||||
#include <sys/timeout.h>
|
||||
#include <sys/device.h>
|
||||
|
||||
|
@ -1,4 +1,4 @@
|
||||
/* $OpenBSD: aac_pci.c,v 1.27 2023/07/13 07:31:12 jsg Exp $ */
|
||||
/* $OpenBSD: aac_pci.c,v 1.28 2023/09/11 08:40:25 mvs Exp $ */
|
||||
|
||||
/*-
|
||||
* Copyright (c) 2000 Michael Smith
|
||||
@ -44,7 +44,6 @@
|
||||
#include <sys/kernel.h>
|
||||
#include <sys/malloc.h>
|
||||
#include <sys/queue.h>
|
||||
#include <sys/selinfo.h>
|
||||
#include <sys/rwlock.h>
|
||||
#include <sys/endian.h>
|
||||
|
||||
|
@ -1,4 +1,4 @@
|
||||
/* $OpenBSD: auixp.c,v 1.51 2022/10/26 20:19:08 kn Exp $ */
|
||||
/* $OpenBSD: auixp.c,v 1.52 2023/09/11 08:41:26 mvs Exp $ */
|
||||
/* $NetBSD: auixp.c,v 1.9 2005/06/27 21:13:09 thorpej Exp $ */
|
||||
|
||||
/*
|
||||
@ -50,7 +50,6 @@
|
||||
#include <sys/device.h>
|
||||
#include <sys/conf.h>
|
||||
#include <sys/exec.h>
|
||||
#include <sys/selinfo.h>
|
||||
#include <sys/audioio.h>
|
||||
#include <sys/queue.h>
|
||||
|
||||
|
@ -1,4 +1,4 @@
|
||||
/* $OpenBSD: com_pci.c,v 1.2 2022/04/06 18:59:29 naddy Exp $ */
|
||||
/* $OpenBSD: com_pci.c,v 1.3 2023/09/11 08:41:26 mvs Exp $ */
|
||||
/*
|
||||
* Copyright (c) 2020 Patrick Wildt <patrick@blueri.se>
|
||||
*
|
||||
@ -18,7 +18,6 @@
|
||||
#include <sys/param.h>
|
||||
#include <sys/systm.h>
|
||||
#include <sys/kernel.h>
|
||||
#include <sys/selinfo.h>
|
||||
#include <sys/tty.h>
|
||||
|
||||
#include <dev/pci/pcidevs.h>
|
||||
|
@ -1,4 +1,4 @@
|
||||
/* $OpenBSD: esa.c,v 1.41 2022/10/26 20:19:08 kn Exp $ */
|
||||
/* $OpenBSD: esa.c,v 1.42 2023/09/11 08:41:26 mvs Exp $ */
|
||||
/* $NetBSD: esa.c,v 1.12 2002/03/24 14:17:35 jmcneill Exp $ */
|
||||
|
||||
/*
|
||||
@ -50,7 +50,6 @@
|
||||
#include <sys/device.h>
|
||||
#include <sys/conf.h>
|
||||
#include <sys/exec.h>
|
||||
#include <sys/selinfo.h>
|
||||
#include <sys/audioio.h>
|
||||
|
||||
#include <machine/bus.h>
|
||||
|
@ -1,4 +1,4 @@
|
||||
/* $OpenBSD: if_ep_pci.c,v 1.36 2022/03/11 18:00:45 mpi Exp $ */
|
||||
/* $OpenBSD: if_ep_pci.c,v 1.37 2023/09/11 08:41:26 mvs Exp $ */
|
||||
/* $NetBSD: if_ep_pci.c,v 1.13 1996/10/21 22:56:38 thorpej Exp $ */
|
||||
|
||||
/*
|
||||
@ -41,7 +41,6 @@
|
||||
#include <sys/errno.h>
|
||||
#include <sys/timeout.h>
|
||||
#include <sys/syslog.h>
|
||||
#include <sys/selinfo.h>
|
||||
#include <sys/device.h>
|
||||
|
||||
#include <net/if.h>
|
||||
|
@ -1,4 +1,4 @@
|
||||
/* $OpenBSD: aic_pcmcia.c,v 1.19 2022/04/06 18:59:30 naddy Exp $ */
|
||||
/* $OpenBSD: aic_pcmcia.c,v 1.20 2023/09/11 08:41:27 mvs Exp $ */
|
||||
/* $NetBSD: aic_pcmcia.c,v 1.6 1998/07/19 17:28:15 christos Exp $ */
|
||||
|
||||
/*
|
||||
@ -32,7 +32,6 @@
|
||||
|
||||
#include <sys/param.h>
|
||||
#include <sys/systm.h>
|
||||
#include <sys/selinfo.h>
|
||||
#include <sys/device.h>
|
||||
|
||||
#include <machine/cpu.h>
|
||||
|
@ -1,4 +1,4 @@
|
||||
/* $OpenBSD: com_pcmcia.c,v 1.59 2022/04/06 18:59:30 naddy Exp $ */
|
||||
/* $OpenBSD: com_pcmcia.c,v 1.60 2023/09/11 08:41:27 mvs Exp $ */
|
||||
/* $NetBSD: com_pcmcia.c,v 1.15 1998/08/22 17:47:58 msaitoh Exp $ */
|
||||
|
||||
/*
|
||||
@ -91,7 +91,6 @@
|
||||
#include <sys/param.h>
|
||||
#include <sys/systm.h>
|
||||
#include <sys/ioctl.h>
|
||||
#include <sys/selinfo.h>
|
||||
#include <sys/tty.h>
|
||||
#include <sys/conf.h>
|
||||
#include <sys/uio.h>
|
||||
|
@ -1,4 +1,4 @@
|
||||
/* $OpenBSD: if_ep_pcmcia.c,v 1.50 2022/04/06 18:59:30 naddy Exp $ */
|
||||
/* $OpenBSD: if_ep_pcmcia.c,v 1.51 2023/09/11 08:41:27 mvs Exp $ */
|
||||
/* $NetBSD: if_ep_pcmcia.c,v 1.16 1998/08/17 23:20:40 thorpej Exp $ */
|
||||
|
||||
/*-
|
||||
@ -69,7 +69,6 @@
|
||||
#include <sys/ioctl.h>
|
||||
#include <sys/errno.h>
|
||||
#include <sys/syslog.h>
|
||||
#include <sys/selinfo.h>
|
||||
#include <sys/timeout.h>
|
||||
#include <sys/device.h>
|
||||
|
||||
|
@ -1,4 +1,4 @@
|
||||
/* $OpenBSD: if_ne_pcmcia.c,v 1.101 2022/04/06 18:59:30 naddy Exp $ */
|
||||
/* $OpenBSD: if_ne_pcmcia.c,v 1.102 2023/09/11 08:41:27 mvs Exp $ */
|
||||
/* $NetBSD: if_ne_pcmcia.c,v 1.17 1998/08/15 19:00:04 thorpej Exp $ */
|
||||
|
||||
/*
|
||||
@ -32,7 +32,6 @@
|
||||
|
||||
#include <sys/param.h>
|
||||
#include <sys/systm.h>
|
||||
#include <sys/selinfo.h>
|
||||
#include <sys/device.h>
|
||||
#include <sys/socket.h>
|
||||
|
||||
|
@ -1,4 +1,4 @@
|
||||
/* $OpenBSD: if_sm_pcmcia.c,v 1.39 2022/04/06 18:59:30 naddy Exp $ */
|
||||
/* $OpenBSD: if_sm_pcmcia.c,v 1.40 2023/09/11 08:41:27 mvs Exp $ */
|
||||
/* $NetBSD: if_sm_pcmcia.c,v 1.11 1998/08/15 20:47:32 thorpej Exp $ */
|
||||
|
||||
/*-
|
||||
@ -40,7 +40,6 @@
|
||||
#include <sys/ioctl.h>
|
||||
#include <sys/errno.h>
|
||||
#include <sys/syslog.h>
|
||||
#include <sys/selinfo.h>
|
||||
#include <sys/timeout.h>
|
||||
#include <sys/device.h>
|
||||
|
||||
|
@ -1,4 +1,4 @@
|
||||
/* $OpenBSD: com_puc.c,v 1.27 2022/04/06 18:59:30 naddy Exp $ */
|
||||
/* $OpenBSD: com_puc.c,v 1.28 2023/09/11 08:41:27 mvs Exp $ */
|
||||
|
||||
/*
|
||||
* Copyright (c) 1997 - 1999, Jason Downs. All rights reserved.
|
||||
@ -31,7 +31,6 @@
|
||||
#include <sys/param.h>
|
||||
#include <sys/systm.h>
|
||||
#include <sys/ioctl.h>
|
||||
#include <sys/selinfo.h>
|
||||
#include <sys/tty.h>
|
||||
#include <sys/conf.h>
|
||||
#include <sys/uio.h>
|
||||
|
@ -1,4 +1,4 @@
|
||||
/* $OpenBSD: usb_subr.c,v 1.158 2022/02/16 06:23:42 anton Exp $ */
|
||||
/* $OpenBSD: usb_subr.c,v 1.159 2023/09/11 08:41:27 mvs Exp $ */
|
||||
/* $NetBSD: usb_subr.c,v 1.103 2003/01/10 11:19:13 augustss Exp $ */
|
||||
/* $FreeBSD: src/sys/dev/usb/usb_subr.c,v 1.18 1999/11/17 22:33:47 n_hibma Exp $ */
|
||||
|
||||
@ -37,7 +37,6 @@
|
||||
#include <sys/kernel.h>
|
||||
#include <sys/malloc.h>
|
||||
#include <sys/device.h>
|
||||
#include <sys/selinfo.h>
|
||||
#include <sys/rwlock.h>
|
||||
|
||||
#include <machine/bus.h>
|
||||
|
@ -1,4 +1,4 @@
|
||||
/* $OpenBSD: scp.c,v 1.258 2023/09/08 05:56:13 djm Exp $ */
|
||||
/* $OpenBSD: scp.c,v 1.259 2023/09/10 23:12:32 djm Exp $ */
|
||||
/*
|
||||
* scp - secure remote copy. This is basically patched BSD rcp which
|
||||
* uses ssh to do the data transfer (instead of using rcmd).
|
||||
@ -158,7 +158,7 @@ size_t sftp_nrequests;
|
||||
/* Needed for sftp */
|
||||
volatile sig_atomic_t interrupted = 0;
|
||||
|
||||
int remote_glob(struct sftp_conn *, const char *, int,
|
||||
int sftp_glob(struct sftp_conn *, const char *, int,
|
||||
int (*)(const char *, int), glob_t *); /* proto for sftp-glob.c */
|
||||
|
||||
static void
|
||||
@ -1507,7 +1507,7 @@ sink_sftp(int argc, char *dst, const char *src, struct sftp_conn *conn)
|
||||
}
|
||||
|
||||
debug3_f("copying remote %s to local %s", abs_src, dst);
|
||||
if ((r = remote_glob(conn, abs_src, GLOB_NOCHECK|GLOB_MARK,
|
||||
if ((r = sftp_glob(conn, abs_src, GLOB_NOCHECK|GLOB_MARK,
|
||||
NULL, &g)) != 0) {
|
||||
if (r == GLOB_NOSPACE)
|
||||
error("%s: too many glob matches", src);
|
||||
@ -1932,7 +1932,7 @@ throughlocal_sftp(struct sftp_conn *from, struct sftp_conn *to,
|
||||
}
|
||||
|
||||
debug3_f("copying remote %s to remote %s", abs_src, target);
|
||||
if ((r = remote_glob(from, abs_src, GLOB_NOCHECK|GLOB_MARK,
|
||||
if ((r = sftp_glob(from, abs_src, GLOB_NOCHECK|GLOB_MARK,
|
||||
NULL, &g)) != 0) {
|
||||
if (r == GLOB_NOSPACE)
|
||||
error("%s: too many glob matches", src);
|
||||
|
@ -1,4 +1,4 @@
|
||||
/* $OpenBSD: sftp-glob.c,v 1.32 2023/09/08 05:56:13 djm Exp $ */
|
||||
/* $OpenBSD: sftp-glob.c,v 1.33 2023/09/10 23:12:32 djm Exp $ */
|
||||
/*
|
||||
* Copyright (c) 2001-2004 Damien Miller <djm@openbsd.org>
|
||||
*
|
||||
@ -29,7 +29,7 @@
|
||||
#include "sftp-common.h"
|
||||
#include "sftp-client.h"
|
||||
|
||||
int remote_glob(struct sftp_conn *, const char *, int,
|
||||
int sftp_glob(struct sftp_conn *, const char *, int,
|
||||
int (*)(const char *, int), glob_t *);
|
||||
|
||||
struct SFTP_OPENDIR {
|
||||
@ -107,7 +107,7 @@ fudge_stat(const char *path, struct stat *st)
|
||||
}
|
||||
|
||||
int
|
||||
remote_glob(struct sftp_conn *conn, const char *pattern, int flags,
|
||||
sftp_glob(struct sftp_conn *conn, const char *pattern, int flags,
|
||||
int (*errfunc)(const char *, int), glob_t *pglob)
|
||||
{
|
||||
int r;
|
||||
|
@ -1,4 +1,4 @@
|
||||
/* $OpenBSD: sftp.c,v 1.235 2023/09/08 05:56:13 djm Exp $ */
|
||||
/* $OpenBSD: sftp.c,v 1.236 2023/09/10 23:12:32 djm Exp $ */
|
||||
/*
|
||||
* Copyright (c) 2001-2004 Damien Miller <djm@openbsd.org>
|
||||
*
|
||||
@ -91,7 +91,7 @@ struct complete_ctx {
|
||||
char **remote_pathp;
|
||||
};
|
||||
|
||||
int remote_glob(struct sftp_conn *, const char *, int,
|
||||
int sftp_glob(struct sftp_conn *, const char *, int,
|
||||
int (*)(const char *, int), glob_t *); /* proto for sftp-glob.c */
|
||||
|
||||
/* Separators for interactive commands */
|
||||
@ -634,7 +634,7 @@ process_get(struct sftp_conn *conn, const char *src, const char *dst,
|
||||
memset(&g, 0, sizeof(g));
|
||||
|
||||
debug3("Looking up %s", abs_src);
|
||||
if ((r = remote_glob(conn, abs_src, GLOB_MARK, NULL, &g)) != 0) {
|
||||
if ((r = sftp_glob(conn, abs_src, GLOB_MARK, NULL, &g)) != 0) {
|
||||
if (r == GLOB_NOSPACE) {
|
||||
error("Too many matches for \"%s\".", abs_src);
|
||||
} else {
|
||||
@ -950,7 +950,7 @@ do_globbed_ls(struct sftp_conn *conn, const char *path,
|
||||
|
||||
memset(&g, 0, sizeof(g));
|
||||
|
||||
if ((r = remote_glob(conn, path,
|
||||
if ((r = sftp_glob(conn, path,
|
||||
GLOB_MARK|GLOB_NOCHECK|GLOB_BRACE|GLOB_KEEPSTAT|GLOB_NOSORT,
|
||||
NULL, &g)) != 0 ||
|
||||
(g.gl_pathc && !g.gl_matchc)) {
|
||||
@ -1591,7 +1591,7 @@ parse_dispatch_command(struct sftp_conn *conn, const char *cmd, char **pwd,
|
||||
break;
|
||||
case I_RM:
|
||||
path1 = make_absolute_pwd_glob(path1, *pwd);
|
||||
remote_glob(conn, path1, GLOB_NOCHECK, NULL, &g);
|
||||
sftp_glob(conn, path1, GLOB_NOCHECK, NULL, &g);
|
||||
for (i = 0; g.gl_pathv[i] && !interrupted; i++) {
|
||||
if (!quiet)
|
||||
mprintf("Removing %s\n", g.gl_pathv[i]);
|
||||
@ -1695,7 +1695,7 @@ parse_dispatch_command(struct sftp_conn *conn, const char *cmd, char **pwd,
|
||||
attrib_clear(&a);
|
||||
a.flags |= SSH2_FILEXFER_ATTR_PERMISSIONS;
|
||||
a.perm = n_arg;
|
||||
remote_glob(conn, path1, GLOB_NOCHECK, NULL, &g);
|
||||
sftp_glob(conn, path1, GLOB_NOCHECK, NULL, &g);
|
||||
for (i = 0; g.gl_pathv[i] && !interrupted; i++) {
|
||||
if (!quiet)
|
||||
mprintf("Changing mode on %s\n",
|
||||
@ -1709,7 +1709,7 @@ parse_dispatch_command(struct sftp_conn *conn, const char *cmd, char **pwd,
|
||||
case I_CHOWN:
|
||||
case I_CHGRP:
|
||||
path1 = make_absolute_pwd_glob(path1, *pwd);
|
||||
remote_glob(conn, path1, GLOB_NOCHECK, NULL, &g);
|
||||
sftp_glob(conn, path1, GLOB_NOCHECK, NULL, &g);
|
||||
for (i = 0; g.gl_pathv[i] && !interrupted; i++) {
|
||||
if ((hflag ? sftp_lstat : sftp_stat)(conn,
|
||||
g.gl_pathv[i], 0, &aa) != 0) {
|
||||
@ -1989,7 +1989,7 @@ complete_match(EditLine *el, struct sftp_conn *conn, char *remote_path,
|
||||
memset(&g, 0, sizeof(g));
|
||||
if (remote != LOCAL) {
|
||||
tmp = make_absolute_pwd_glob(tmp, remote_path);
|
||||
remote_glob(conn, tmp, GLOB_DOOFFS|GLOB_MARK, NULL, &g);
|
||||
sftp_glob(conn, tmp, GLOB_DOOFFS|GLOB_MARK, NULL, &g);
|
||||
} else
|
||||
(void)glob(tmp, GLOB_DOOFFS|GLOB_MARK, NULL, &g);
|
||||
|
||||
|
@ -1,4 +1,4 @@
|
||||
/* $OpenBSD: l2tp_subr.c,v 1.4 2012/05/08 13:15:11 yasuoka Exp $ */
|
||||
/* $OpenBSD: l2tp_subr.c,v 1.5 2023/09/11 07:33:07 yasuoka Exp $ */
|
||||
|
||||
/*-
|
||||
* Copyright (c) 2009 Internet Initiative Japan Inc.
|
||||
@ -25,7 +25,7 @@
|
||||
* OUT OF THE USE OF THIS SOFTWARE, EVEN IF ADVISED OF THE POSSIBILITY OF
|
||||
* SUCH DAMAGE.
|
||||
*/
|
||||
/* $Id: l2tp_subr.c,v 1.4 2012/05/08 13:15:11 yasuoka Exp $ */
|
||||
/* $Id: l2tp_subr.c,v 1.5 2023/09/11 07:33:07 yasuoka Exp $ */
|
||||
/**@file L2TP related sub-routines */
|
||||
#include <sys/types.h>
|
||||
#include <sys/time.h>
|
||||
@ -80,10 +80,10 @@ avp_enum(struct l2tp_avp *avp, const u_char *pkt, int pktlen, int filldata)
|
||||
avp->attr_type |= *(pkt + 1);
|
||||
pkt += 2;
|
||||
|
||||
if (avp->length > pktlen)
|
||||
if (avp->length < 6 || avp->length > pktlen)
|
||||
return -1;
|
||||
|
||||
if (filldata != 0)
|
||||
if (avp->length > 6 && filldata != 0)
|
||||
memcpy(avp->attr_value, pkt, avp->length - 6);
|
||||
|
||||
return avp->length;
|
||||
@ -285,9 +285,8 @@ avp_find(struct l2tp_avp *avp, const u_char *pkt, int pktlen,
|
||||
|
||||
while (pktlen >= 6 &&
|
||||
(avpsz = avp_enum(avp, pkt, pktlen, fill_data)) > 0) {
|
||||
L2TP_SUBR_ASSERT(avpsz >= 6);
|
||||
if (avp->vendor_id != vendor_id || avp->attr_type != attr_type) {
|
||||
if (avpsz < 6)
|
||||
return NULL;
|
||||
pkt += avpsz;
|
||||
pktlen -= avpsz;
|
||||
continue;
|
||||
|
@ -1,3 +1,8 @@
|
||||
8 September 2023: Wouter
|
||||
- Fix send of udp retries when ENOBUFS is returned. It stops looping
|
||||
and also waits for the condition to go away. Reported by Florian
|
||||
Obser.
|
||||
|
||||
25 August 2023: Wouter
|
||||
- Fix compile error on NetBSD in util/netevent.h.
|
||||
|
||||
|
@ -116,6 +116,8 @@
|
||||
|
||||
/** timeout in millisec to wait for write to unblock, packets dropped after.*/
|
||||
#define SEND_BLOCKED_WAIT_TIMEOUT 200
|
||||
/** max number of times to wait for write to unblock, packets dropped after.*/
|
||||
#define SEND_BLOCKED_MAX_RETRY 5
|
||||
|
||||
/** Let's make timestamping code cleaner and redefine SO_TIMESTAMP* */
|
||||
#ifndef SO_TIMESTAMP
|
||||
@ -402,9 +404,10 @@ comm_point_send_udp_msg(struct comm_point *c, sldns_buffer* packet,
|
||||
WSAGetLastError() == WSAENOBUFS ||
|
||||
WSAGetLastError() == WSAEWOULDBLOCK) {
|
||||
#endif
|
||||
int retries = 0;
|
||||
/* if we set the fd blocking, other threads suddenly
|
||||
* have a blocking fd that they operate on */
|
||||
while(sent == -1 && (
|
||||
while(sent == -1 && retries < SEND_BLOCKED_MAX_RETRY && (
|
||||
#ifndef USE_WINSOCK
|
||||
errno == EAGAIN || errno == EINTR ||
|
||||
# ifdef EWOULDBLOCK
|
||||
@ -419,6 +422,13 @@ comm_point_send_udp_msg(struct comm_point *c, sldns_buffer* packet,
|
||||
#endif
|
||||
)) {
|
||||
#if defined(HAVE_POLL) || defined(USE_WINSOCK)
|
||||
int send_nobufs = (
|
||||
#ifndef USE_WINSOCK
|
||||
errno == ENOBUFS
|
||||
#else
|
||||
WSAGetLastError() == WSAENOBUFS
|
||||
#endif
|
||||
);
|
||||
struct pollfd p;
|
||||
int pret;
|
||||
memset(&p, 0, sizeof(p));
|
||||
@ -457,8 +467,48 @@ comm_point_send_udp_msg(struct comm_point *c, sldns_buffer* packet,
|
||||
log_err("poll udp out failed: %s",
|
||||
sock_strerror(errno));
|
||||
return 0;
|
||||
} else if((pret < 0 &&
|
||||
#ifndef USE_WINSOCK
|
||||
errno == ENOBUFS
|
||||
#else
|
||||
WSAGetLastError() == WSAENOBUFS
|
||||
#endif
|
||||
) || (send_nobufs && retries > 0)) {
|
||||
/* ENOBUFS, and poll returned without
|
||||
* a timeout. Or the retried send call
|
||||
* returned ENOBUFS. It is good to
|
||||
* wait a bit for the error to clear. */
|
||||
/* The timeout is 20*(2^(retries+1)),
|
||||
* it increases exponentially, starting
|
||||
* at 40 msec. After 5 tries, 1240 msec
|
||||
* have passed in total, when poll
|
||||
* returned the error, and 1200 msec
|
||||
* when send returned the errors. */
|
||||
#ifndef USE_WINSOCK
|
||||
pret = poll(NULL, 0, (SEND_BLOCKED_WAIT_TIMEOUT/10)<<(retries+1));
|
||||
#else
|
||||
pret = WSAPoll(NULL, 0, (SEND_BLOCKED_WAIT_TIMEOUT/10)<<(retries+1));
|
||||
#endif
|
||||
if(pret < 0 &&
|
||||
#ifndef USE_WINSOCK
|
||||
errno != EAGAIN && errno != EINTR &&
|
||||
# ifdef EWOULDBLOCK
|
||||
errno != EWOULDBLOCK &&
|
||||
# endif
|
||||
errno != ENOBUFS
|
||||
#else
|
||||
WSAGetLastError() != WSAEINPROGRESS &&
|
||||
WSAGetLastError() != WSAEINTR &&
|
||||
WSAGetLastError() != WSAENOBUFS &&
|
||||
WSAGetLastError() != WSAEWOULDBLOCK
|
||||
#endif
|
||||
) {
|
||||
log_err("poll udp out timer failed: %s",
|
||||
sock_strerror(errno));
|
||||
}
|
||||
}
|
||||
#endif /* defined(HAVE_POLL) || defined(USE_WINSOCK) */
|
||||
retries++;
|
||||
if (!is_connected) {
|
||||
sent = sendto(c->fd, (void*)sldns_buffer_begin(packet),
|
||||
sldns_buffer_remaining(packet), 0,
|
||||
@ -665,7 +715,8 @@ comm_point_send_udp_msg_if(struct comm_point *c, sldns_buffer* packet,
|
||||
WSAGetLastError() == WSAENOBUFS ||
|
||||
WSAGetLastError() == WSAEWOULDBLOCK) {
|
||||
#endif
|
||||
while(sent == -1 && (
|
||||
int retries = 0;
|
||||
while(sent == -1 && retries < SEND_BLOCKED_MAX_RETRY && (
|
||||
#ifndef USE_WINSOCK
|
||||
errno == EAGAIN || errno == EINTR ||
|
||||
# ifdef EWOULDBLOCK
|
||||
@ -680,6 +731,13 @@ comm_point_send_udp_msg_if(struct comm_point *c, sldns_buffer* packet,
|
||||
#endif
|
||||
)) {
|
||||
#if defined(HAVE_POLL) || defined(USE_WINSOCK)
|
||||
int send_nobufs = (
|
||||
#ifndef USE_WINSOCK
|
||||
errno == ENOBUFS
|
||||
#else
|
||||
WSAGetLastError() == WSAENOBUFS
|
||||
#endif
|
||||
);
|
||||
struct pollfd p;
|
||||
int pret;
|
||||
memset(&p, 0, sizeof(p));
|
||||
@ -718,8 +776,48 @@ comm_point_send_udp_msg_if(struct comm_point *c, sldns_buffer* packet,
|
||||
log_err("poll udp out failed: %s",
|
||||
sock_strerror(errno));
|
||||
return 0;
|
||||
} else if((pret < 0 &&
|
||||
#ifndef USE_WINSOCK
|
||||
errno == ENOBUFS
|
||||
#else
|
||||
WSAGetLastError() == WSAENOBUFS
|
||||
#endif
|
||||
) || (send_nobufs && retries > 0)) {
|
||||
/* ENOBUFS, and poll returned without
|
||||
* a timeout. Or the retried send call
|
||||
* returned ENOBUFS. It is good to
|
||||
* wait a bit for the error to clear. */
|
||||
/* The timeout is 20*(2^(retries+1)),
|
||||
* it increases exponentially, starting
|
||||
* at 40 msec. After 5 tries, 1240 msec
|
||||
* have passed in total, when poll
|
||||
* returned the error, and 1200 msec
|
||||
* when send returned the errors. */
|
||||
#ifndef USE_WINSOCK
|
||||
pret = poll(NULL, 0, (SEND_BLOCKED_WAIT_TIMEOUT/10)<<(retries+1));
|
||||
#else
|
||||
pret = WSAPoll(NULL, 0, (SEND_BLOCKED_WAIT_TIMEOUT/10)<<(retries+1));
|
||||
#endif
|
||||
if(pret < 0 &&
|
||||
#ifndef USE_WINSOCK
|
||||
errno != EAGAIN && errno != EINTR &&
|
||||
# ifdef EWOULDBLOCK
|
||||
errno != EWOULDBLOCK &&
|
||||
# endif
|
||||
errno != ENOBUFS
|
||||
#else
|
||||
WSAGetLastError() != WSAEINPROGRESS &&
|
||||
WSAGetLastError() != WSAEINTR &&
|
||||
WSAGetLastError() != WSAENOBUFS &&
|
||||
WSAGetLastError() != WSAEWOULDBLOCK
|
||||
#endif
|
||||
) {
|
||||
log_err("poll udp out timer failed: %s",
|
||||
sock_strerror(errno));
|
||||
}
|
||||
}
|
||||
#endif /* defined(HAVE_POLL) || defined(USE_WINSOCK) */
|
||||
retries++;
|
||||
sent = sendmsg(c->fd, &msg, 0);
|
||||
}
|
||||
}
|
||||
|
Loading…
Reference in New Issue
Block a user