aboutsummaryrefslogtreecommitdiff
diff options
context:
space:
mode:
-rw-r--r--.git-blame-ignore-revs2
-rw-r--r--Makefile.inc15
-rw-r--r--UPDATING7
-rw-r--r--contrib/libucl/CMakeLists.txt314
-rw-r--r--contrib/libucl/ChangeLog.md103
-rw-r--r--contrib/libucl/FREEBSD-Xlist40
-rw-r--r--contrib/libucl/FREEBSD-upgrade39
-rw-r--r--contrib/libucl/Makefile.am81
-rw-r--r--contrib/libucl/Makefile.unix89
-rw-r--r--contrib/libucl/Makefile.w3292
-rw-r--r--contrib/libucl/README.md418
-rwxr-xr-xcontrib/libucl/autogen.sh2
-rw-r--r--contrib/libucl/configure.ac188
-rw-r--r--contrib/libucl/doc/Makefile.am9
-rw-r--r--contrib/libucl/doc/api.md506
-rw-r--r--contrib/libucl/doc/lua_api.md196
-rw-r--r--contrib/libucl/doc/pandoc.template12
-rw-r--r--contrib/libucl/examples/ucl_cpp.cc26
-rw-r--r--contrib/libucl/haskell/hucl.hs123
-rw-r--r--contrib/libucl/include/ucl.h4
-rw-r--r--contrib/libucl/libucl.pc11
-rw-r--r--contrib/libucl/libucl.pc.in11
-rw-r--r--contrib/libucl/lua/Makefile.am26
-rw-r--r--contrib/libucl/lua/libucl.rockspec.in26
-rw-r--r--contrib/libucl/lua/lua_ucl.c83
-rw-r--r--contrib/libucl/m4/ax_lua.m4664
-rw-r--r--contrib/libucl/m4/gcov.m489
-rw-r--r--contrib/libucl/python/MANIFEST.in5
-rw-r--r--contrib/libucl/python/setup.py75
-rw-r--r--contrib/libucl/python/src/uclmodule.c335
-rw-r--r--contrib/libucl/python/tests/__init__.py0
-rw-r--r--contrib/libucl/python/tests/compat.py8
-rw-r--r--contrib/libucl/python/tests/test_dump.py66
-rw-r--r--contrib/libucl/python/tests/test_example.py59
-rw-r--r--contrib/libucl/python/tests/test_load.py122
-rw-r--r--contrib/libucl/python/tests/test_validation.py50
-rw-r--r--contrib/libucl/python/ucl.pyi15
-rw-r--r--contrib/libucl/src/Makefile.am30
-rw-r--r--contrib/libucl/src/mum.h2
-rw-r--r--contrib/libucl/src/ucl_emitter.c80
-rw-r--r--contrib/libucl/src/ucl_emitter_streamline.c9
-rw-r--r--contrib/libucl/src/ucl_hash.c146
-rw-r--r--contrib/libucl/src/ucl_msgpack.c4
-rw-r--r--contrib/libucl/src/ucl_parser.c214
-rw-r--r--contrib/libucl/src/ucl_schema.c1
-rw-r--r--contrib/libucl/src/ucl_util.c87
-rw-r--r--contrib/libucl/stamp-h.in1
-rw-r--r--contrib/libucl/tests/.gitignore10
-rw-r--r--contrib/libucl/tests/Makefile.am45
-rw-r--r--contrib/libucl/tests/schema/definitions.json32
-rw-r--r--contrib/libucl/tests/schema/ref.json16
-rw-r--r--contrib/libucl/tests/schema/refRemote.json76
-rw-r--r--contrib/libucl/tests/test_speed.c2
-rw-r--r--contrib/libucl/tests/test_streamline.c43
-rw-r--r--contrib/libucl/uthash/utlist.h749
-rw-r--r--contrib/libucl/utils/CMakeLists.txt12
-rw-r--r--contrib/libucl/utils/Makefile.am23
-rw-r--r--contrib/libucl/utils/chargen.c128
-rw-r--r--contrib/libucl/utils/objdump.c185
-rw-r--r--contrib/libucl/utils/ucl-tool.c170
-rw-r--r--contrib/llvm-project/llvm/lib/ObjCopy/ELF/ELFObjcopy.cpp25
-rw-r--r--contrib/llvm-project/llvm/lib/Target/PowerPC/PPCMergeStringPool.cpp5
-rw-r--r--contrib/tzcode/Makefile32
-rw-r--r--contrib/tzcode/NEWS109
-rw-r--r--contrib/tzcode/asctime.c122
-rw-r--r--contrib/tzcode/date.1122
-rw-r--r--contrib/tzcode/localtime.c585
-rw-r--r--contrib/tzcode/newctime.3152
-rw-r--r--contrib/tzcode/newstrftime.386
-rw-r--r--contrib/tzcode/newtzset.324
-rw-r--r--contrib/tzcode/private.h119
-rw-r--r--contrib/tzcode/strftime.c83
-rw-r--r--contrib/tzcode/theory.html40
-rw-r--r--contrib/tzcode/tz-link.html45
-rw-r--r--contrib/tzcode/tzfile.570
-rw-r--r--contrib/tzcode/tzfile.h2
-rw-r--r--contrib/tzcode/tzselect.826
-rw-r--r--contrib/tzcode/version2
-rw-r--r--contrib/tzcode/zdump.814
-rw-r--r--contrib/tzcode/zdump.c62
-rw-r--r--contrib/tzcode/zic.827
-rw-r--r--contrib/tzcode/zic.c142
-rw-r--r--lib/libc/tests/stdtime/detect_tz_changes_test.c43
-rw-r--r--lib/libifconfig/Makefile1
-rw-r--r--lib/libifconfig/libifconfig.h11
-rw-r--r--lib/libifconfig/libifconfig_nl.c72
-rwxr-xr-xlibexec/rc/rc.d/bluetooth13
-rw-r--r--release/tools/azure.conf3
-rw-r--r--release/tools/ec2.conf3
-rw-r--r--release/tools/vagrant.conf3
-rw-r--r--sbin/pfctl/parse.y50
-rw-r--r--sbin/pfctl/pfctl_parser.c6
-rw-r--r--sbin/pfctl/tests/files/pf1073.in1
-rw-r--r--sbin/pfctl/tests/files/pf1073.ok1
-rw-r--r--sbin/pfctl/tests/files/pf1074.fail1
-rw-r--r--sbin/pfctl/tests/files/pf1074.in1
-rw-r--r--sbin/pfctl/tests/pfctl_test_list.inc2
-rw-r--r--sbin/veriexec/veriexec.82
-rw-r--r--share/man/man4/Makefile3
-rw-r--r--share/man/man4/gpio.46
-rw-r--r--share/man/man4/syncache.429
-rw-r--r--share/man/man5/pf.conf.518
-rw-r--r--share/man/man9/VFS.91
-rw-r--r--share/mk/bsd.man.mk13
-rw-r--r--share/vt/fonts/gallant.hex4121
-rw-r--r--sys/arm64/arm64/elf32_machdep.c2
-rw-r--r--sys/compat/linuxkpi/common/include/linux/ieee80211.h28
-rw-r--r--sys/compat/linuxkpi/common/include/linux/skbuff.h4
-rw-r--r--sys/compat/linuxkpi/common/include/linux/string_helpers.h2
-rw-r--r--sys/compat/linuxkpi/common/include/net/mac80211.h2
-rw-r--r--sys/compat/linuxkpi/common/src/linux_80211.c539
-rw-r--r--sys/compat/linuxkpi/common/src/linux_80211.h21
-rw-r--r--sys/contrib/dev/rtw88/main.c57
-rw-r--r--sys/dev/ath/ath_rate/sample/sample.c8
-rw-r--r--sys/dev/ath/if_ath_tx_ht.c6
-rw-r--r--sys/dev/cxgbe/t4_main.c2
-rw-r--r--sys/dev/gpio/gpio_if.m26
-rw-r--r--sys/dev/gpio/gpiobus.c101
-rw-r--r--sys/dev/gpio/gpiobus_if.m30
-rw-r--r--sys/dev/gpio/gpiobus_internal.h1
-rw-r--r--sys/dev/gpio/gpioc.c157
-rw-r--r--sys/dev/gpio/ofw_gpiobus.c3
-rw-r--r--sys/dev/mwl/if_mwl.c2
-rw-r--r--sys/dev/nvme/nvme.c1
-rw-r--r--sys/dev/nvme/nvme_ahci.c1
-rw-r--r--sys/dev/nvme/nvme_ctrlr.c11
-rw-r--r--sys/dev/nvme/nvme_ctrlr_cmd.c3
-rw-r--r--sys/dev/nvme/nvme_ns.c3
-rw-r--r--sys/dev/nvme/nvme_pci.c1
-rw-r--r--sys/dev/nvme/nvme_private.h3
-rw-r--r--sys/dev/nvme/nvme_qpair.c3
-rw-r--r--sys/dev/nvme/nvme_sim.c1
-rw-r--r--sys/dev/nvme/nvme_sysctl.c1
-rw-r--r--sys/dev/rtwn/rtl8812a/r12a_tx.c4
-rw-r--r--sys/dev/tpm/tpm_tis_core.c7
-rw-r--r--sys/dev/usb/usb_hub.c3
-rw-r--r--sys/dev/virtio/network/if_vtnet.c205
-rw-r--r--sys/fs/nfsclient/nfs_clvnops.c7
-rw-r--r--sys/fs/tarfs/tarfs_vnops.c4
-rw-r--r--sys/kern/kern_thread.c6
-rw-r--r--sys/kern/subr_witness.c134
-rw-r--r--sys/kern/vfs_init.c16
-rw-r--r--sys/kern/vfs_mount.c7
-rw-r--r--sys/kern/vfs_subr.c8
-rw-r--r--sys/modules/irdma/Makefile6
-rw-r--r--sys/net/if.c1
-rw-r--r--sys/net/iflib.c13
-rw-r--r--sys/net/pfvar.h3
-rw-r--r--sys/net80211/ieee80211_ddb.c2
-rw-r--r--sys/net80211/ieee80211_ht.c16
-rw-r--r--sys/net80211/ieee80211_node.c4
-rw-r--r--sys/net80211/ieee80211_node.h34
-rw-r--r--sys/net80211/ieee80211_phy.c30
-rw-r--r--sys/net80211/ieee80211_phy.h8
-rw-r--r--sys/net80211/ieee80211_sta.c2
-rw-r--r--sys/net80211/ieee80211_vht.c20
-rw-r--r--sys/net80211/ieee80211_vht.h4
-rw-r--r--sys/netinet/tcp_syncache.c90
-rw-r--r--sys/netpfil/pf/if_pfsync.c8
-rw-r--r--sys/netpfil/pf/pf.c63
-rw-r--r--sys/netpfil/pf/pf.h1
-rw-r--r--sys/netpfil/pf/pf_ioctl.c1
-rw-r--r--sys/netpfil/pf/pf_lb.c151
-rw-r--r--sys/sys/mount.h1
-rw-r--r--sys/vm/vm_extern.h2
-rw-r--r--sys/vm/vm_fault.c81
-rw-r--r--tests/sys/netpfil/pf/route_to.sh716
-rwxr-xr-xtests/sys/netpfil/pf/src_track.sh36
-rw-r--r--tests/sys/netpfil/pf/utils.subr4
-rw-r--r--tools/build/mk/OptionalObsoleteFiles.inc2
-rw-r--r--tools/tools/sysbuild/sysbuild.sh2
-rw-r--r--usr.bin/patch/pch.c2
-rwxr-xr-xusr.bin/patch/tests/unified_patch_test.sh39
-rw-r--r--usr.bin/w/pr_time.c26
-rwxr-xr-xusr.sbin/bsdinstall/scripts/jail2
-rw-r--r--usr.sbin/devinfo/devinfo.843
-rw-r--r--usr.sbin/makefs/ffs.c94
-rw-r--r--usr.sbin/ngctl/Makefile5
-rw-r--r--usr.sbin/ngctl/main.c41
-rw-r--r--usr.sbin/ngctl/ngctl.825
-rw-r--r--usr.sbin/pkg/FreeBSD.conf.latest4
-rw-r--r--usr.sbin/pkg/FreeBSD.conf.quarterly4
-rw-r--r--usr.sbin/pkg/FreeBSD.conf.quarterly-release4
183 files changed, 8963 insertions, 6311 deletions
diff --git a/.git-blame-ignore-revs b/.git-blame-ignore-revs
index 31b6fb8eb33f..7b832c253b56 100644
--- a/.git-blame-ignore-revs
+++ b/.git-blame-ignore-revs
@@ -8,6 +8,8 @@
#
# This file is sorted in git log order (newest commits first).
+# witness white space cleanup and style(9) tweeks
+f5377665253b2b107ee8a4690ad2e6682375b304
# style fixes for device_if.m
ab43dbe0187ecdf1697726170fd4e19c373effcc
# iflib style tweaks
diff --git a/Makefile.inc1 b/Makefile.inc1
index c6cbc411be80..3bbc4afed3fd 100644
--- a/Makefile.inc1
+++ b/Makefile.inc1
@@ -644,7 +644,10 @@ XPATH= ${WORLDTMP}/bin:${WORLDTMP}/usr/sbin:${WORLDTMP}/usr/bin
# When building we want to find the cross tools before the host tools in ${BPATH}.
# We also need to add UNIVERSE_TOOLCHAIN_PATH so that we can find the shared
# toolchain files (clang, lld, etc.) during make universe/tinderbox
-STRICTTMPPATH= ${XPATH}:${BPATH}:${UNIVERSE_TOOLCHAIN_PATH}
+STRICTTMPPATH= ${XPATH}:${BPATH}
+.if defined(UNIVERSE_TOOLCHAIN_PATH)
+STRICTTMPPATH:=${STRICTTMPPATH}:${UNIVERSE_TOOLCHAIN_PATH}
+.endif
# We should not be using tools from /usr/bin accidentally since this could cause
# the build to break on other systems that don't have that tool. For now we
# still allow using the old behaviour (inheriting $PATH) if
diff --git a/UPDATING b/UPDATING
index 8a0930b20123..34f71af5464e 100644
--- a/UPDATING
+++ b/UPDATING
@@ -27,6 +27,13 @@ NOTE TO PEOPLE WHO THINK THAT FreeBSD 15.x IS SLOW:
world, or to merely disable the most expensive debugging functionality
at runtime, run "ln -s 'abort:false,junk:false' /etc/malloc.conf".)
+20250827:
+ The names of pkg repositories defined in /etc/pkg/FreeBSD.conf have
+ changed: "FreeBSD" is now "FreeBSD-ports", and "FreeBSD-kmods" is now
+ "FreeBSD-ports-kmods". Users with /usr/local/etc/pkg/repos files
+ which override these will need to adjust their configuration to match
+ the new names.
+
20250823:
The set of pkgbase packages for Kerberos and OpenSSL has changed.
After updating past 250e77d4f0a5, you should check 'pkg orphans'
diff --git a/contrib/libucl/CMakeLists.txt b/contrib/libucl/CMakeLists.txt
deleted file mode 100644
index 5fe772a30f88..000000000000
--- a/contrib/libucl/CMakeLists.txt
+++ /dev/null
@@ -1,314 +0,0 @@
-PROJECT(libucl C)
-CMAKE_MINIMUM_REQUIRED(VERSION 2.6.0 FATAL_ERROR)
-
-SET(LIBUCL_VERSION_MAJOR 0)
-SET(LIBUCL_VERSION_MINOR 5)
-SET(LIBUCL_VERSION_PATCH 0)
-
-SET(LIBUCL_VERSION
- "${LIBUCL_VERSION_MAJOR}.${LIBUCL_VERSION_MINOR}.${LIBUCL_VERSION_PATCH}")
-
-INCLUDE(CheckCCompilerFlag)
-INCLUDE(CheckCSourceCompiles)
-INCLUDE(FindOpenSSL)
-INCLUDE(GNUInstallDirs)
-
-OPTION(ENABLE_URL_INCLUDE "Enable urls in ucl includes (requires libcurl or libfetch) [default: OFF]" OFF)
-OPTION(ENABLE_URL_SIGN "Enable signatures check in ucl includes (requires openssl) [default: OFF]" OFF)
-OPTION(BUILD_SHARED_LIBS "Build Shared Libraries [default: OFF]" OFF)
-OPTION(ENABLE_LUA "Enable lua support [default: OFF]" OFF)
-OPTION(ENABLE_LUAJIT "Enable luajit support [default: OFF]" OFF)
-OPTION(ENABLE_UTILS "Enable building utility binaries [default: OFF]" OFF)
-
-# Find lua installation
-MACRO(FindLua)
- # Find lua libraries
- UNSET(LUA_INCLUDE_DIR CACHE)
- UNSET(LUA_LIBRARY CACHE)
- CMAKE_PARSE_ARGUMENTS(LUA "" "VERSION_MAJOR;VERSION_MINOR;ROOT" "" ${ARGN})
-
- IF(NOT LUA_VERSION_MAJOR OR NOT LUA_VERSION_MINOR)
- MESSAGE(FATAL_ERROR "Invalid FindLua invocation: ${ARGN}")
- ENDIF()
-
- IF(ENABLE_LUAJIT MATCHES "ON")
- MESSAGE(STATUS "Check for luajit ${LUA_VERSION_MAJOR}.${LUA_VERSION_MINOR}")
- FIND_PATH(LUA_INCLUDE_DIR luajit.h
- HINTS
- "${RSPAMD_SEARCH_PATH}" "${LUA_ROOT}"
- $ENV{LUA_DIR}
- PATH_SUFFIXES "include/luajit-2.0"
- "include/luajit${LUA_VERSION_MAJOR}${LUA_VERSION_MINOR}"
- "include/luajit${LUA_VERSION_MAJOR}.${LUA_VERSION_MINOR}"
- "include/luajit-${LUA_VERSION_MAJOR}.${LUA_VERSION_MINOR}"
- "include/luajit"
- "include/lua${LUA_VERSION_MAJOR}${LUA_VERSION_MINOR}"
- "include/lua${LUA_VERSION_MAJOR}.${LUA_VERSION_MINOR}"
- "include/lua-${LUA_VERSION_MAJOR}.${LUA_VERSION_MINOR}"
- include/lua include
- PATHS ${RSPAMD_DEFAULT_INCLUDE_PATHS}
- )
- FIND_LIBRARY(LUA_LIBRARY
- NAMES luajit
- "luajit-2.0"
- "luajit2.0"
- "luajit${LUA_VERSION_MAJOR}${LUA_VERSION_MINOR}"
- "luajit${LUA_VERSION_MAJOR}.${LUA_VERSION_MINOR}"
- "luajit-${LUA_VERSION_MAJOR}.${LUA_VERSION_MINOR}"
- HINTS
- "${RSPAMD_SEARCH_PATH}" "${LUA_ROOT}"
- $ENV{LUA_DIR}
- PATH_SUFFIXES lib64 lib
- PATHS ${RSPAMD_DEFAULT_LIBRARY_PATHS}
- DOC "Lua library"
- )
-
- IF(NOT LUA_LIBRARY OR NOT LUA_INCLUDE_DIR)
- MESSAGE(STATUS "Fallback from luajit to plain lua")
- SET(ENABLE_LUAJIT "OFF")
- MESSAGE(STATUS "Check for lua ${LUA_VERSION_MAJOR}.${LUA_VERSION_MINOR}")
- FIND_PATH(LUA_INCLUDE_DIR lua.h
- HINTS
- "${RSPAMD_SEARCH_PATH}" "${LUA_ROOT}"
- $ENV{LUA_DIR}
- PATH_SUFFIXES "include/lua${LUA_VERSION_MAJOR}${LUA_VERSION_MINOR}"
- "include/lua${LUA_VERSION_MAJOR}.${LUA_VERSION_MINOR}"
- "include/lua-${LUA_VERSION_MAJOR}.${LUA_VERSION_MINOR}"
- include/lua include
- PATHS ${RSPAMD_DEFAULT_INCLUDE_PATHS}
- )
- FIND_LIBRARY(LUA_LIBRARY
- NAMES lua
- "lua${LUA_VERSION_MAJOR}${LUA_VERSION_MINOR}"
- "lua${LUA_VERSION_MAJOR}.${LUA_VERSION_MINOR}"
- "lua-${LUA_VERSION_MAJOR}.${LUA_VERSION_MINOR}"
- HINTS
- "${RSPAMD_SEARCH_PATH}" "${LUA_ROOT}"
- $ENV{LUA_DIR}
- PATH_SUFFIXES lib64 lib
- PATHS ${RSPAMD_DEFAULT_LIBRARY_PATHS}
- DOC "Lua library"
- )
- ENDIF()
- ELSE(ENABLE_LUAJIT MATCHES "ON")
- MESSAGE(STATUS "Check for lua ${LUA_VERSION_MAJOR}.${LUA_VERSION_MINOR}")
- FIND_PATH(LUA_INCLUDE_DIR lua.h
- HINTS
- "${RSPAMD_SEARCH_PATH}" "${LUA_ROOT}"
- $ENV{LUA_DIR}
- PATH_SUFFIXES "include/lua${LUA_VERSION_MAJOR}${LUA_VERSION_MINOR}"
- "include/lua${LUA_VERSION_MAJOR}.${LUA_VERSION_MINOR}"
- "include/lua-${LUA_VERSION_MAJOR}.${LUA_VERSION_MINOR}"
- include/lua include
- PATHS ${RSPAMD_DEFAULT_INCLUDE_PATHS}
- )
- FIND_LIBRARY(LUA_LIBRARY
- NAMES lua
- "lua${LUA_VERSION_MAJOR}${LUA_VERSION_MINOR}"
- "lua${LUA_VERSION_MAJOR}.${LUA_VERSION_MINOR}"
- "lua-${LUA_VERSION_MAJOR}.${LUA_VERSION_MINOR}"
- HINTS
- "${RSPAMD_SEARCH_PATH}" "${LUA_ROOT}"
- $ENV{LUA_DIR}
- PATH_SUFFIXES lib64 lib
- PATHS ${RSPAMD_DEFAULT_LIBRARY_PATHS}
- DOC "Lua library"
- )
- ENDIF(ENABLE_LUAJIT MATCHES "ON")
-
- IF(LUA_LIBRARY AND LUA_INCLUDE_DIR)
- SET(LUA_FOUND 1)
- IF(NOT LUA_VERSION_MAJOR OR NOT LUA_VERSION_MINOR)
- SET(LUA_VERSION_MAJOR ${LUA_VERSION_MAJOR})
- SET(LUA_VERSION_MINOR ${LUA_VERSION_MINOR})
- ENDIF(NOT LUA_VERSION_MAJOR OR NOT LUA_VERSION_MINOR)
- IF(ENABLE_LUAJIT MATCHES "ON")
- MESSAGE(STATUS "Found luajit ${LUA_VERSION_MAJOR}.${LUA_VERSION_MINOR}")
- ELSE(ENABLE_LUAJIT MATCHES "ON")
- MESSAGE(STATUS "Found lua ${LUA_VERSION_MAJOR}.${LUA_VERSION_MINOR}")
- ENDIF(ENABLE_LUAJIT MATCHES "ON")
- ENDIF(LUA_LIBRARY AND LUA_INCLUDE_DIR)
-ENDMACRO()
-
-IF(CMAKE_SYSTEM_NAME STREQUAL "Linux")
- LIST(APPEND CMAKE_REQUIRED_LIBRARIES rt)
-ENDIF(CMAKE_SYSTEM_NAME STREQUAL "Linux")
-
-IF(ENABLE_URL_INCLUDE MATCHES "ON")
- FIND_LIBRARY(LIBFETCH_LIBRARY NAMES fetch PATHS PATH_SUFFIXES lib64 lib
- PATHS
- ~/Library/Frameworks
- /Library/Frameworks
- /usr/local
- /usr
- /sw
- /opt/local
- /opt/csw
- /opt
- DOC "Path where the libfetch library can be found")
- IF(LIBFETCH_LIBRARY)
- FIND_FILE(HAVE_FETCH_H NAMES fetch.h PATHS /usr/include
- /opt/include
- /usr/local/include
- DOC "Path to libfetch header")
- ELSE(LIBFETCH_LIBRARY)
- # Try to find libcurl
- FIND_PACKAGE(CURL)
- IF(NOT CURL_FOUND)
- MESSAGE(WARNING "Neither libcurl nor libfetch were found, no support of URL includes in configuration")
- ENDIF(NOT CURL_FOUND)
- ENDIF(LIBFETCH_LIBRARY)
-ENDIF(ENABLE_URL_INCLUDE MATCHES "ON")
-
-set(SYNC_BUILTINS_TEST_SOURCE [====[
-int main()
-{
- unsigned long val;
-
- __sync_bool_compare_and_swap(&val, 0, 1);
- __sync_add_and_fetch(&val, 1);
- __sync_fetch_and_add(&val, 0);
- __sync_sub_and_fetch(&val, 1);
-
- return 0;
-}
-]====])
-
-CHECK_C_SOURCE_COMPILES("${SYNC_BUILTINS_TEST_SOURCE}" HAVE_ATOMIC_BUILTINS)
-IF(NOT HAVE_ATOMIC_BUILTINS)
- MESSAGE(WARNING "Libucl references could be thread-unsafe because atomic builtins are missing")
-ENDIF(NOT HAVE_ATOMIC_BUILTINS)
-
-SET(CMAKE_C_WARN_FLAGS "")
-CHECK_C_COMPILER_FLAG(-W SUPPORT_W)
-CHECK_C_COMPILER_FLAG(-Wno-pointer-sign SUPPORT_WPOINTER_SIGN)
-CHECK_C_COMPILER_FLAG(-Wno-unused-parameter SUPPORT_WUNUSED_PARAMETER)
-IF(SUPPORT_W)
- SET(CMAKE_C_WARN_FLAGS "${CMAKE_C_WARN_FLAGS} -W")
-ENDIF(SUPPORT_W)
-IF(SUPPORT_WPOINTER_SIGN)
- SET(CMAKE_C_WARN_FLAGS "${CMAKE_C_WARN_FLAGS} -Wno-pointer-sign")
-ENDIF(SUPPORT_WPOINTER_SIGN)
-IF(SUPPORT_WUNUSED_PARAMETER)
- SET(CMAKE_C_WARN_FLAGS "${CMAKE_C_WARN_FLAGS} -Wno-unused-parameter")
-ENDIF(SUPPORT_WUNUSED_PARAMETER)
-
-SET( CMAKE_C_FLAGS "${CMAKE_C_FLAGS} ${CMAKE_C_WARN_FLAGS}" )
-
-IF(ENABLE_URL_SIGN MATCHES "ON")
- IF(OPENSSL_FOUND)
- SET(HAVE_OPENSSL 1)
- INCLUDE_DIRECTORIES("${OPENSSL_INCLUDE_DIR}")
- ENDIF(OPENSSL_FOUND)
-ENDIF(ENABLE_URL_SIGN MATCHES "ON")
-
-SET(UCL_COMPILE_DEFS)
-IF(HAVE_FETCH_H)
- LIST(APPEND UCL_COMPILE_DEFS -DHAVE_FETCH_H=1)
-ENDIF(HAVE_FETCH_H)
-IF(CURL_FOUND)
- LIST(APPEND UCL_COMPILE_DEFS -DCURL_FOUND=1)
-ENDIF(CURL_FOUND)
-IF(HAVE_OPENSSL)
- LIST(APPEND UCL_COMPILE_DEFS -DHAVE_OPENSSL=1)
-ENDIF(HAVE_OPENSSL)
-IF(HAVE_ATOMIC_BUILTINS)
- LIST(APPEND UCL_COMPILE_DEFS -DHAVE_ATOMIC_BUILTINS=1)
-ENDIF(HAVE_ATOMIC_BUILTINS)
-
-SET(UCLSRC src/ucl_util.c
- src/ucl_parser.c
- src/ucl_emitter.c
- src/ucl_emitter_streamline.c
- src/ucl_emitter_utils.c
- src/ucl_hash.c
- src/ucl_schema.c
- src/ucl_msgpack.c
- src/ucl_sexp.c)
-
-SET(UCLHDR include/ucl.h
- include/ucl++.h)
-
-SET (LIB_TYPE STATIC)
-IF (BUILD_SHARED_LIBS)
- SET (LIB_TYPE SHARED)
-ENDIF (BUILD_SHARED_LIBS)
-ADD_LIBRARY(ucl ${LIB_TYPE} ${UCLSRC})
-ADD_LIBRARY(ucl::ucl ALIAS ucl)
-SET_TARGET_PROPERTIES(ucl PROPERTIES VERSION ${LIBUCL_VERSION} SOVERSION ${LIBUCL_VERSION_MAJOR})
-TARGET_INCLUDE_DIRECTORIES(ucl
- PUBLIC
- include
- PRIVATE
- src
- uthash
- klib)
-TARGET_COMPILE_DEFINITIONS(ucl
- PRIVATE
- ${UCL_COMPILE_DEFS}
-)
-
-IF(ENABLE_LUA MATCHES "ON")
- IF(ENABLE_LUAJIT MATCHES "ON")
- FindLua(VERSION_MAJOR "5" VERSION_MINOR "1" ROOT "${LUA_ROOT}")
- IF(NOT LUA_FOUND)
- MESSAGE(FATAL_ERROR "Lua not found, lua support is required")
- ELSE(NOT LUA_FOUND)
- INCLUDE_DIRECTORIES("${LUA_INCLUDE_DIR}")
- ENDIF(NOT LUA_FOUND)
- ELSE(ENABLE_LUAJIT MATCHES "ON")
- FindLua(VERSION_MAJOR "5" VERSION_MINOR "2" ROOT "${LUA_ROOT}")
- IF(NOT LUA_FOUND)
- FindLua(VERSION_MAJOR "5" VERSION_MINOR "1" ROOT "${LUA_ROOT}")
- ENDIF(NOT LUA_FOUND)
- IF(NOT LUA_FOUND)
- MESSAGE(FATAL_ERROR "Lua not found, lua support is required")
- ELSE(NOT LUA_FOUND)
- INCLUDE_DIRECTORIES("${LUA_INCLUDE_DIR}")
- ENDIF(NOT LUA_FOUND)
- ENDIF(ENABLE_LUAJIT MATCHES "ON")
- SET(UCL_LUA_SRC lua/lua_ucl.c)
- ADD_LIBRARY(lua-ucl ${LIB_TYPE} ${UCL_LUA_SRC})
- ADD_LIBRARY(ucl::lua ALIAS lua-ucl)
- IF(ENABLE_LUAJIT MATCHES "ON")
- TARGET_LINK_LIBRARIES(lua-ucl "${LUAJIT_LIBRARY}")
- ELSE(ENABLE_LUAJIT MATCHES "ON")
- TARGET_LINK_LIBRARIES(lua-ucl "${LUA_LIBRARY}")
- ENDIF(ENABLE_LUAJIT MATCHES "ON")
- TARGET_LINK_LIBRARIES(lua-ucl ucl)
- TARGET_INCLUDE_DIRECTORIES(lua-ucl PUBLIC include PRIVATE src uthash)
- SET_TARGET_PROPERTIES(lua-ucl PROPERTIES
- VERSION ${LIBUCL_VERSION}
- SOVERSION ${LIBUCL_VERSION_MAJOR}
- PUBLIC_HEADER include/lua_ucl.h)
- INSTALL(TARGETS lua-ucl DESTINATION ${CMAKE_INSTALL_LIBDIR}
- PUBLIC_HEADER DESTINATION ${CMAKE_INSTALL_INCLUDEDIR})
-ENDIF()
-
-IF(HAVE_FETCH_H)
- TARGET_LINK_LIBRARIES(ucl fetch)
-ELSE(HAVE_FETCH_H)
- IF(CURL_FOUND)
- TARGET_LINK_LIBRARIES(ucl ${CURL_LIBRARIES})
- ENDIF(CURL_FOUND)
-ENDIF(HAVE_FETCH_H)
-IF(ENABLE_URL_SIGN MATCHES "ON")
- IF(OPENSSL_FOUND)
- TARGET_LINK_LIBRARIES(ucl ${OPENSSL_LIBRARIES})
- ENDIF(OPENSSL_FOUND)
-ENDIF(ENABLE_URL_SIGN MATCHES "ON")
-
-IF(UNIX)
- TARGET_LINK_LIBRARIES(ucl -lm)
-ENDIF(UNIX)
-
-SET_TARGET_PROPERTIES(ucl PROPERTIES
- PUBLIC_HEADER "${UCLHDR}")
-
-INSTALL(TARGETS ucl DESTINATION ${CMAKE_INSTALL_LIBDIR}
- PUBLIC_HEADER DESTINATION ${CMAKE_INSTALL_INCLUDEDIR})
-
-IF(ENABLE_UTILS MATCHES "ON")
- ADD_SUBDIRECTORY(utils)
-ENDIF()
-
diff --git a/contrib/libucl/ChangeLog.md b/contrib/libucl/ChangeLog.md
deleted file mode 100644
index cba29aa9a7b5..000000000000
--- a/contrib/libucl/ChangeLog.md
+++ /dev/null
@@ -1,103 +0,0 @@
-# Version history
-
-## Libucl 0.5
-
-- Streamline emitter has been added, so it is now possible to output partial `ucl` objects
-- Emitter now is more flexible due to emitter_context structure
-
-### 0.5.1
-- Fixed number of bugs and memory leaks
-
-### 0.5.2
-
-- Allow userdata objects to be emitted and destructed
-- Use userdata objects to store lua function references
-
-### Libucl 0.6
-
-- Reworked macro interface
-
-### Libucl 0.6.1
-
-- Various utilities fixes
-
-### Libucl 0.7.0
-
-- Move to klib library from uthash to reduce memory overhead and increase performance
-
-### Libucl 0.7.1
-
-- Added safe iterators API
-
-### Libucl 0.7.2
-
-- Fixed serious bugs in schema and arrays iteration
-
-### Libucl 0.7.3
-
-- Fixed a bug with macros that come after an empty object
-- Fixed a bug in include processing when an incorrect variable has been destroyed (use-after-free)
-
-### Libucl 0.8.0
-
-- Allow to save comments and macros when parsing UCL documents
-- C++ API
-- Python bindings (by Eitan Adler)
-- Add msgpack support for parser and emitter
-- Add Canonical S-expressions parser for libucl
-- CLI interface for parsing and validation (by Maxim Ignatenko)
-- Implement include with priority
-- Add 'nested' functionality to .include macro (by Allan Jude)
-- Allow searching an array of paths for includes (by Allan Jude)
-- Add new .load macro (by Allan Jude)
-- Implement .inherit macro (#100)
-- Add merge strategies
-- Add schema validation to lua API
-- Add support for external references to schema validation
-- Add coveralls integration to libucl
-- Implement tests for 80% of libucl code lines
-- Fix tonns of minor and major bugs
-- Improve documentation
-- Rework function names to the common conventions (old names are preserved for backwards compatibility)
-- Add Coverity scan integration
-- Add fuzz tests
-
-**Incompatible changes**:
-
-- `ucl_object_emit_full` now accepts additional argument `comments` that could be used to emit comments with UCL output
-
-### Libucl 0.8.1
-
-- Create ucl_parser_add_file_full() to be able to specify merge mode and parser type (by Allan Jude)
-- C++ wrapper improvements (by @ftilde)
-- C++ wrapper: add convenience method at() and lookup() (by Yonghee Kim)
-- C++ wrapper: add assignment operator to Ucl class (by Yonghee Kim)
-- C++ wrapper: support variables in parser (by Yonghee Kim)
-- C++ wrapper: refactoring C++ interface (by Yonghee Kim):
- - use auto variables (if possible)
- - remove dangling expressions
- - use std::set::emplace instead of std::set::insert
- - not use std::move in return statement; considering copy elision
-- C++ wrapper: fix compilation error and warnings (by Zhe Wang)
-- C++ wrapper: fix iteration over objects in which the first value is `false` (by Zhe Wang)
-- C++ wrapper: Macro helper functions (by Chris Meacham)
-- C++ wrapper: Changing the duplicate strategy in the C++ API (by Chris Meacham)
-- C++ wrapper: Added access functions for the size of a UCL_ARRAY (by Chris Meacham)
-- Fix caseless comparison
-- Fix include when EPERM is issued
-- Fix Windows build
-- Allow to reserve space in arrays and hashes
-- Fix bug with including of empty files
-- Move to mum_hash from xxhash
-- Fix msgpack on non-x86
-- python: Add support to Python 3 (by Denis Volpato Martins)
-- python: Add support for Python 2.6 tests (by Denis Volpato Martins)
-- python: Implement validation function and tests (by Denis Volpato Martins)
-- python: Added UCL_NULL handling and tests (by Denis Volpato Martins)
-- Fix schema validation for patternProperties with object data (by Denis Volpato Martins)
-- Remove the dependency on NBBY, add missing <strings.h> include (by Ed Schouten)
-- Allow to emit msgpack from Lua
-- Performance improvements in Lua API
-- Allow to pass opaque objects in Lua API for transparent C passthrough
-- Various bugs fixed
-- Couple of memory leaks plugged \ No newline at end of file
diff --git a/contrib/libucl/FREEBSD-Xlist b/contrib/libucl/FREEBSD-Xlist
new file mode 100644
index 000000000000..6d8cb4ff8f5b
--- /dev/null
+++ b/contrib/libucl/FREEBSD-Xlist
@@ -0,0 +1,40 @@
+.github
+.gitignore
+CMakeLists.txt
+ChangeLog.md
+Makefile.am
+Makefile.unix
+Makefile.w32
+README.md
+autogen.sh
+configure.ac
+doc/Makefile.am
+doc/api.md
+doc/lua_api.md
+doc/pandoc.template
+examples/ucl_cpp.cc
+haskell/hucl.hs
+libucl.pc.in
+lua/Makefile.am
+lua/libucl.rockspec.in
+m4/.gitignore
+m4/ax_lua.m4
+m4/gcov.m4
+python/MANIFEST.in
+python/setup.py
+python/src/uclmodule.c
+python/tests/__init__.py
+python/tests/compat.py
+python/tests/test_dump.py
+python/tests/test_example.py
+python/tests/test_load.py
+python/tests/test_validation.py
+python/ucl.pyi
+src/Makefile.am
+stamp-h.in
+tests/Makefile.am
+utils/CMakeLists.txt
+utils/Makefile.am
+utils/chargen.c
+utils/objdump.c
+utils/ucl-tool.c
diff --git a/contrib/libucl/FREEBSD-upgrade b/contrib/libucl/FREEBSD-upgrade
new file mode 100644
index 000000000000..b80736d7877b
--- /dev/null
+++ b/contrib/libucl/FREEBSD-upgrade
@@ -0,0 +1,39 @@
+# FreeBSD libucl import instruction
+#
+# At least the following ports are required when importing libucl:
+# - devel/autoconf
+# - devel/automake
+# - devel/git
+# - devel/gmake
+# - devel/libtool
+#
+# 1. Vendor import
+#
+# $ git clone https://github.com/vstakhov/libucl.git /tmp/libucl
+# $ cd /tmp/libucl
+# $ git checkout <REF_BRANCH_TO_BE_IMPORTED>
+# $ cd /usr/src
+# $ git checkout vendor/libucl
+# $ rsync -va --delete --exclude=.git /tmp/libucl/ /usr/src/contrib/libucl/
+# $ git add .
+# $ git commit -m "vendor import libucl <REF_BRANCH_TO_BE_IMPORTED>"
+# $ git tag -a vendor/libucl/<REF_BRANCH_TO_BE_IMPORTED> -m "vendor import libucl <REF_BRANCH_TO_BE_IMPORTED>"
+# $ git push --follow-tags freebsd vendor/libucl/<REF_BRANCH_TO_BE_IMPORTED>
+#
+# 2. Test
+#
+# $ cd /usr/src
+# $ git checkout vendor/libucl/<REF_BRANCH_TO_BE_IMPORTED>
+# $ ./autogen.sh
+# $ ./configure
+# $ gmake
+# $ gmake check
+# $ gmake clean
+#
+# 3. Merge vendor tree
+#
+# $ git subtree merge -P contrib/libucl vendor/libucl/<REF_BRANCH_TO_BE_IMPORTED>
+# $ sh -c 'for F in `cat FREEBSD-Xlist | grep -v FreeBSD`; do rm -rf ./$F ; done'
+#
+# Recheck if there were any new files were added which are not necessary in the
+# contrib tree. If so, remove them and also add them to the FREEBSD-Xlist file.
diff --git a/contrib/libucl/Makefile.am b/contrib/libucl/Makefile.am
deleted file mode 100644
index 5b51bcc3b468..000000000000
--- a/contrib/libucl/Makefile.am
+++ /dev/null
@@ -1,81 +0,0 @@
-ACLOCAL_AMFLAGS = -I m4
-EXTRA_DIST = uthash klib README.md
-
-pkgconfigdir = $(libdir)/pkgconfig
-pkgconfig_DATA = libucl.pc
-
-if LUA_SUB
- LUA_SUBDIR = lua
-endif
-
-COVERAGE_INFO_FILE = $(top_builddir)/coverage.info
-COVERAGE_REPORT_DIR = $(top_builddir)/coverage
-
-.PHONY = coverage-requirement-check clean-coverage-report
-
-coverage-requirement-check:
- @if test ! -e $(GCOV); then \
- echo "Cannot find $(GCOV). Please install gcov."; \
- exit 1; \
- fi
-
-coverage: coverage-requirement-check clean-coverage coverage-build coverage-check coverage-report
- @echo "Please execute 'make clean' before 'make' or 'make check' to remove instrumented object files(compiled with -O0 etc.). Note that 'make clean' also remove coverage data."
-
-coverage-build: coverage-requirement-check
- @if test `find $(top_builddir) -name "*.gcno" | wc -l` -eq 0; then \
- echo "Start to remove old non-instrumented object files..."; \
- $(MAKE) $(AM_MAKEFLAGS) clean; \
- echo "Successfully removed old non-instrumented object files."; \
- fi
- @echo "Start to build libraries with coverage options..."
- $(MAKE) $(AM_MAKEFLAGS) \
- CFLAGS="$(CFLAGS) $(COVERAGE_CFLAGS) $(COVERAGE_OPTFLAGS)" \
- CXXFLAGS="$(CXXFLAGS) $(COVERAGE_CXXFLAGS) $(COVERAGE_OPTFLAGS)" \
- LDFLAGS="$(LDFLAGS) $(COVERAGE_LDFLAGS)" \
- LIBS="$(LIBS) $(COVERAGE_LIBS)"
- @echo "Successfully built libraries with coverage options."
-
-coverage-check: coverage-requirement-check
- @echo "Start to run tests with instrumented libraries..."
- $(MAKE) $(AM_MAKEFLAGS) check \
- CFLAGS="$(CFLAGS) $(COVERAGE_CFLAGS) $(COVERAGE_OPTFLAGS)" \
- CXXFLAGS="$(CXXFLAGS) $(COVERAGE_CXXFLAGS) $(COVERAGE_OPTFLAGS)" \
- LDFLAGS="$(LDFLAGS) $(COVERAGE_LDFLAGS)" \
- LIBS="$(LIBS) $(COVERAGE_LIBS)"
- @echo "Successfully run tests with instrumented libraries."
-
-coverage-lcov: coverage-check coverage-requirement-check
- $(LCOV) --capture \
- --directory "$(top_builddir)/" \
- --output-file $(COVERAGE_INFO_FILE) \
- --gcov-tool $(GCOV) \
- --compat-libtool --checksum
- $(LCOV) --extract $(COVERAGE_INFO_FILE) `pwd`/src/ucl_\* \
- --output-file $(COVERAGE_INFO_FILE)
-
-coverage-report: coverage-lcov
- @echo "Start to create coverage reports..."
- $(GENHTML) --prefix "$(top_srcdir)" \
- --output-directory $(COVERAGE_REPORT_DIR) \
- --title $(PACKAGE_NAME) \
- --legend --show-details \
- $(GENHTML_OPTIONS) \
- $(COVERAGE_INFO_FILE)
- @echo "Successfully created coverage reports into $(COVERAGE_REPORT_DIR) directory."
-
-clean-coverage-report:
- -rm -rf $(COVERAGE_INFO_FILE)
- -rm -rf $(COVERAGE_REPORT_DIR)
-
-clean-coverage: clean-coverage-report
- -$(LCOV) --gcov-tool $(GCOV) --zerocounters --directory $(top_builddir)
- @if xargs --version 2>/dev/null; then \
- find $(top_builddir) -name "*.gcno" | xargs --no-run-if-empty rm; \
- else \
- find $(top_builddir) -name "*.gcno" | xargs rm; \
- fi
-
-clean-local: clean-coverage
-
-SUBDIRS = src tests utils doc $(LUA_SUBDIR)
diff --git a/contrib/libucl/Makefile.unix b/contrib/libucl/Makefile.unix
deleted file mode 100644
index 0653d4843f7e..000000000000
--- a/contrib/libucl/Makefile.unix
+++ /dev/null
@@ -1,89 +0,0 @@
-CC ?= gcc
-DESTDIR ?= /usr/local
-LD ?= gcc
-C_COMMON_FLAGS ?= -fPIC -Wall -W -Wno-unused-parameter -Wno-pointer-sign -I./include -I./uthash -I./src -I./klib
-MAJOR_VERSION = 0
-MINOR_VERSION = 2
-PATCH_VERSION = 9
-VERSION = "$(MAJOR_VERSION).$(MINOR_VERSION).$(PATCH_VERSION)"
-SONAME = libucl.so
-SONAME_FULL = $(SONAME).$(MAJOR_VERSION)
-OBJDIR ?= .obj
-TESTDIR ?= tests
-SRCDIR ?= src
-INCLUDEDIR ?= include
-MKDIR ?= mkdir
-INSTALL ?= install
-RM ?= rm
-RMDIR ?= rmdir
-LN ?= ln
-LD_SHARED_FLAGS ?= -Wl,-soname,$(SONAME) -shared -lm
-LD_UCL_FLAGS ?= -L$(OBJDIR) -Wl,-rpath,$(OBJDIR) -lucl
-LD_ADD ?= -lrt
-COPT_FLAGS ?= -O2
-HDEPS = $(SRCDIR)/ucl_hash.h \
- $(SRCDIR)/ucl_chartable.h \
- $(SRCDIR)/ucl_internal.h \
- $(INCLUDEDIR)/ucl.h \
- $(SRCDIR)/mum.h
-OBJECTS = $(OBJDIR)/ucl_hash.o \
- $(OBJDIR)/ucl_util.o \
- $(OBJDIR)/ucl_parser.o \
- $(OBJDIR)/ucl_emitter.o \
- $(OBJDIR)/ucl_schema.o
-
-all: $(OBJDIR) $(OBJDIR)/$(SONAME)
-
-$(OBJDIR)/$(SONAME): $(OBJDIR)/$(SONAME_FULL)
- $(LN) -sf $(SONAME_FULL) $(OBJDIR)/$(SONAME)
-
-$(OBJDIR)/$(SONAME_FULL): $(OBJECTS)
- $(CC) -o $(OBJDIR)/$(SONAME_FULL) $(OBJECTS) $(LD_SHARED_FLAGS) $(LDFLAGS) $(SSL_LIBS) $(FETCH_LIBS)
-
-$(OBJDIR):
- @$(MKDIR) -p $(OBJDIR)
-
-# Compile rules
-$(OBJDIR)/ucl_util.o: $(SRCDIR)/ucl_util.c $(HDEPS)
- $(CC) -o $(OBJDIR)/ucl_util.o $(CPPFLAGS) $(COPT_FLAGS) $(CFLAGS) $(C_COMMON_FLAGS) $(SSL_CFLAGS) $(FETCH_FLAGS) -c $(SRCDIR)/ucl_util.c
-$(OBJDIR)/ucl_parser.o: $(SRCDIR)/ucl_parser.c $(HDEPS)
- $(CC) -o $(OBJDIR)/ucl_parser.o $(CPPFLAGS) $(COPT_FLAGS) $(CFLAGS) $(C_COMMON_FLAGS) $(SSL_CFLAGS) $(FETCH_FLAGS) -c $(SRCDIR)/ucl_parser.c
-$(OBJDIR)/ucl_emitter.o: $(SRCDIR)/ucl_emitter.c $(HDEPS)
- $(CC) -o $(OBJDIR)/ucl_emitter.o $(CPPFLAGS) $(COPT_FLAGS) $(CFLAGS) $(C_COMMON_FLAGS) $(SSL_CFLAGS) $(FETCH_FLAGS) -c $(SRCDIR)/ucl_emitter.c
-$(OBJDIR)/ucl_hash.o: $(SRCDIR)/ucl_hash.c $(HDEPS)
- $(CC) -o $(OBJDIR)/ucl_hash.o $(CPPFLAGS) $(COPT_FLAGS) $(CFLAGS) $(C_COMMON_FLAGS) $(SSL_CFLAGS) $(FETCH_FLAGS) -c $(SRCDIR)/ucl_hash.c
-$(OBJDIR)/ucl_schema.o: $(SRCDIR)/ucl_schema.c $(HDEPS)
- $(CC) -o $(OBJDIR)/ucl_schema.o $(CPPFLAGS) $(COPT_FLAGS) $(CFLAGS) $(C_COMMON_FLAGS) $(SSL_CFLAGS) $(FETCH_FLAGS) -c $(SRCDIR)/ucl_schema.c
-
-clean:
- $(RM) $(OBJDIR)/*.o $(OBJDIR)/$(SONAME_FULL) $(OBJDIR)/$(SONAME) $(OBJDIR)/chargen $(OBJDIR)/test_basic $(OBJDIR)/test_speed $(OBJDIR)/objdump $(OBJDIR)/test_generate $(OBJDIR)/test_schema || true
- $(RMDIR) $(OBJDIR)
-
-# Utils
-
-chargen: utils/chargen.c $(OBJDIR)/$(SONAME)
- $(CC) -o $(OBJDIR)/chargen $(CPPFLAGS) $(COPT_FLAGS) $(CFLAGS) $(C_COMMON_FLAGS) $(SSL_CFLAGS) $(FETCH_FLAGS) $(LDFLAGS) utils/chargen.c
-objdump: utils/objdump.c $(OBJDIR)/$(SONAME)
- $(CC) -o $(OBJDIR)/objdump $(CPPFLAGS) $(COPT_FLAGS) $(CFLAGS) $(C_COMMON_FLAGS) $(SSL_CFLAGS) $(FETCH_FLAGS) $(LDFLAGS) utils/objdump.c $(LD_UCL_FLAGS)
-
-# Tests
-
-test: $(OBJDIR) $(OBJDIR)/$(SONAME) $(OBJDIR)/test_basic $(OBJDIR)/test_speed $(OBJDIR)/test_generate $(OBJDIR)/test_schema
-
-run-test: test
- TEST_DIR=$(TESTDIR) $(TESTDIR)/run_tests.sh $(OBJDIR)/test_basic $(OBJDIR)/test_speed $(OBJDIR)/test_generate $(OBJDIR)/test_schema
-
-$(OBJDIR)/test_basic: $(TESTDIR)/test_basic.c $(OBJDIR)/$(SONAME)
- $(CC) -o $(OBJDIR)/test_basic $(CPPFLAGS) $(COPT_FLAGS) $(CFLAGS) $(C_COMMON_FLAGS) $(SSL_CFLAGS) $(FETCH_FLAGS) $(LDFLAGS) $(TESTDIR)/test_basic.c $(LD_UCL_FLAGS)
-$(OBJDIR)/test_schema: $(TESTDIR)/test_schema.c $(OBJDIR)/$(SONAME)
- $(CC) -o $(OBJDIR)/test_schema $(CPPFLAGS) $(COPT_FLAGS) $(CFLAGS) $(C_COMMON_FLAGS) $(SSL_CFLAGS) $(FETCH_FLAGS) $(LDFLAGS) $(TESTDIR)/test_schema.c $(LD_UCL_FLAGS)
-$(OBJDIR)/test_speed: $(TESTDIR)/test_speed.c $(OBJDIR)/$(SONAME)
- $(CC) -o $(OBJDIR)/test_speed $(CPPFLAGS) $(COPT_FLAGS) $(CFLAGS) $(C_COMMON_FLAGS) $(SSL_CFLAGS) $(FETCH_FLAGS) $(LDFLAGS) $(TESTDIR)/test_speed.c $(LD_UCL_FLAGS) $(LD_ADD)
-$(OBJDIR)/test_generate: $(TESTDIR)/test_generate.c $(OBJDIR)/$(SONAME)
- $(CC) -o $(OBJDIR)/test_generate $(CPPFLAGS) $(COPT_FLAGS) $(CFLAGS) $(C_COMMON_FLAGS) $(SSL_CFLAGS) $(FETCH_FLAGS) $(LDFLAGS) $(TESTDIR)/test_generate.c $(LD_UCL_FLAGS) $(LD_ADD)
-
-install: $(OBJDIR)/$(SONAME)
- $(INSTALL) -m0755 $(SONAME) $(DESTDIR)/lib/$(SONAME)
- $(INSTALL) -m0644 include/ucl.h $(DESTDIR)/include/ucl.h
-
-.PHONY: clean $(OBJDIR)
diff --git a/contrib/libucl/Makefile.w32 b/contrib/libucl/Makefile.w32
deleted file mode 100644
index 5d9398bf1988..000000000000
--- a/contrib/libucl/Makefile.w32
+++ /dev/null
@@ -1,92 +0,0 @@
-CC ?= gcc
-DESTDIR ?= /usr/local
-LD ?= gcc
-C_COMMON_FLAGS ?= -fPIC -Wall -W -Wno-unused-parameter -Wno-pointer-sign -I./include -I./uthash -I./src
-MAJOR_VERSION = 0
-MINOR_VERSION = 2
-PATCH_VERSION = 9
-VERSION = "$(MAJOR_VERSION).$(MINOR_VERSION).$(PATCH_VERSION)"
-SONAME = libucl.dll
-OBJDIR ?= .obj
-TESTDIR ?= tests
-SRCDIR ?= src
-INCLUDEDIR ?= include
-MKDIR ?= mkdir
-INSTALL ?= install
-RM ?= rm
-RMDIR ?= rmdir
-ifeq (Windows_NT, $(OS))
-LN ?= ln
-else
-LN ?= rem ln
-endif
-LD_SHARED_FLAGS ?= -Wl,-soname,$(SONAME) -shared -lm
-LD_UCL_FLAGS ?= -L$(OBJDIR) -Wl,-rpath,$(OBJDIR) -lucl
-LD_ADD ?= -lrt
-COPT_FLAGS ?= -O2
-HDEPS = $(SRCDIR)/ucl_hash.h \
- $(SRCDIR)/ucl_chartable.h \
- $(SRCDIR)/ucl_internal.h \
- $(INCLUDEDIR)/ucl.h \
- $(SRCDIR)/mum.h
-OBJECTS = $(OBJDIR)/ucl_hash.o \
- $(OBJDIR)/ucl_util.o \
- $(OBJDIR)/ucl_parser.o \
- $(OBJDIR)/ucl_emitter.o \
- $(OBJDIR)/ucl_emitter_utils.o \
- $(OBJDIR)/ucl_schema.o
-
-all: $(OBJDIR) $(OBJDIR)/$(SONAME)
-
-$(OBJDIR)/$(SONAME): $(OBJECTS)
- $(CC) -o $(OBJDIR)/$(SONAME) $(OBJECTS) $(LD_SHARED_FLAGS) $(LDFLAGS) $(SSL_LIBS) $(FETCH_LIBS)
-
-$(OBJDIR):
- @$(MKDIR) -p $(OBJDIR)
-
-# Compile rules
-$(OBJDIR)/ucl_util.o: $(SRCDIR)/ucl_util.c $(HDEPS)
- $(CC) -o $(OBJDIR)/ucl_util.o $(CPPFLAGS) $(COPT_FLAGS) $(CFLAGS) $(C_COMMON_FLAGS) $(SSL_CFLAGS) $(FETCH_FLAGS) -c $(SRCDIR)/ucl_util.c
-$(OBJDIR)/ucl_parser.o: $(SRCDIR)/ucl_parser.c $(HDEPS)
- $(CC) -o $(OBJDIR)/ucl_parser.o $(CPPFLAGS) $(COPT_FLAGS) $(CFLAGS) $(C_COMMON_FLAGS) $(SSL_CFLAGS) $(FETCH_FLAGS) -c $(SRCDIR)/ucl_parser.c
-$(OBJDIR)/ucl_emitter.o: $(SRCDIR)/ucl_emitter.c $(HDEPS)
- $(CC) -o $(OBJDIR)/ucl_emitter.o $(CPPFLAGS) $(COPT_FLAGS) $(CFLAGS) $(C_COMMON_FLAGS) $(SSL_CFLAGS) $(FETCH_FLAGS) -c $(SRCDIR)/ucl_emitter.c
-$(OBJDIR)/ucl_emitter_utils.o: $(SRCDIR)/ucl_emitter_utils.c $(HDEPS)
- $(CC) -o $(OBJDIR)/ucl_emitter_utils.o $(CPPFLAGS) $(COPT_FLAGS) $(CFLAGS) $(C_COMMON_FLAGS) $(SSL_CFLAGS) $(FETCH_FLAGS) -c $(SRCDIR)/ucl_emitter_utils.c
-$(OBJDIR)/ucl_hash.o: $(SRCDIR)/ucl_hash.c $(HDEPS)
- $(CC) -o $(OBJDIR)/ucl_hash.o $(CPPFLAGS) $(COPT_FLAGS) $(CFLAGS) $(C_COMMON_FLAGS) $(SSL_CFLAGS) $(FETCH_FLAGS) -c $(SRCDIR)/ucl_hash.c
-$(OBJDIR)/ucl_schema.o: $(SRCDIR)/ucl_schema.c $(HDEPS)
- $(CC) -o $(OBJDIR)/ucl_schema.o $(CPPFLAGS) $(COPT_FLAGS) $(CFLAGS) $(C_COMMON_FLAGS) $(SSL_CFLAGS) $(FETCH_FLAGS) -c $(SRCDIR)/ucl_schema.c
-$(OBJDIR)/xxhash.o: $(SRCDIR)/xxhash.c $(HDEPS)
- $(CC) -o $(OBJDIR)/xxhash.o $(CPPFLAGS) $(COPT_FLAGS) $(CFLAGS) $(C_COMMON_FLAGS) $(SSL_CFLAGS) $(FETCH_FLAGS) -c $(SRCDIR)/xxhash.c
-
-clean:
- $(RM) $(OBJDIR)/*.o $(OBJDIR)/$(SONAME) $(OBJDIR)/$(SONAME) $(OBJDIR)/chargen $(OBJDIR)/test_basic $(OBJDIR)/test_speed $(OBJDIR)/objdump $(OBJDIR)/test_generate
- $(RMDIR) $(OBJDIR)
-
-# Utils
-
-chargen: utils/chargen.c $(OBJDIR)/$(SONAME)
- $(CC) -o $(OBJDIR)/chargen $(CPPFLAGS) $(COPT_FLAGS) $(CFLAGS) $(C_COMMON_FLAGS) $(SSL_CFLAGS) $(FETCH_FLAGS) $(LDFLAGS) utils/chargen.c
-objdump: utils/objdump.c $(OBJDIR)/$(SONAME)
- $(CC) -o $(OBJDIR)/objdump $(CPPFLAGS) $(COPT_FLAGS) $(CFLAGS) $(C_COMMON_FLAGS) $(SSL_CFLAGS) $(FETCH_FLAGS) $(LDFLAGS) utils/objdump.c $(LD_UCL_FLAGS)
-
-# Tests
-
-test: $(OBJDIR) $(OBJDIR)/$(SONAME) $(OBJDIR)/test_basic $(OBJDIR)/test_speed $(OBJDIR)/test_generate
-
-run-test: test
- TEST_DIR=$(TESTDIR) $(TESTDIR)/run_tests.sh $(OBJDIR)/test_basic $(OBJDIR)/test_speed $(OBJDIR)/test_generate
-
-$(OBJDIR)/test_basic: $(TESTDIR)/test_basic.c $(OBJDIR)/$(SONAME)
- $(CC) -o $(OBJDIR)/test_basic $(CPPFLAGS) $(COPT_FLAGS) $(CFLAGS) $(C_COMMON_FLAGS) $(SSL_CFLAGS) $(FETCH_FLAGS) $(LDFLAGS) $(TESTDIR)/test_basic.c $(LD_UCL_FLAGS)
-$(OBJDIR)/test_speed: $(TESTDIR)/test_speed.c $(OBJDIR)/$(SONAME)
- $(CC) -o $(OBJDIR)/test_speed $(CPPFLAGS) $(COPT_FLAGS) $(CFLAGS) $(C_COMMON_FLAGS) $(SSL_CFLAGS) $(FETCH_FLAGS) $(LDFLAGS) $(TESTDIR)/test_speed.c $(LD_UCL_FLAGS) $(LD_ADD)
-$(OBJDIR)/test_generate: $(TESTDIR)/test_generate.c $(OBJDIR)/$(SONAME)
- $(CC) -o $(OBJDIR)/test_generate $(CPPFLAGS) $(COPT_FLAGS) $(CFLAGS) $(C_COMMON_FLAGS) $(SSL_CFLAGS) $(FETCH_FLAGS) $(LDFLAGS) $(TESTDIR)/test_generate.c $(LD_UCL_FLAGS) $(LD_ADD)
-
-install: $(OBJDIR)/$(SONAME)
- $(INSTALL) -m0755 $(SONAME) $(DESTDIR)/lib/$(SONAME)
- $(INSTALL) -m0644 include/ucl.h $(DESTDIR)/include/ucl.h
-
-.PHONY: clean $(OBJDIR)
diff --git a/contrib/libucl/README.md b/contrib/libucl/README.md
deleted file mode 100644
index 53d8a651d73b..000000000000
--- a/contrib/libucl/README.md
+++ /dev/null
@@ -1,418 +0,0 @@
-# LIBUCL
-
-[![CircleCI](https://circleci.com/gh/vstakhov/libucl.svg?style=svg)](https://circleci.com/gh/vstakhov/libucl)
-[![Coverity](https://scan.coverity.com/projects/4138/badge.svg)](https://scan.coverity.com/projects/4138)
-[![Coverage Status](https://coveralls.io/repos/github/vstakhov/libucl/badge.svg?branch=master)](https://coveralls.io/github/vstakhov/libucl?branch=master)
-
-**Table of Contents** *generated with [DocToc](http://doctoc.herokuapp.com/)*
-
-- [Introduction](#introduction)
-- [Basic structure](#basic-structure)
-- [Improvements to the json notation](#improvements-to-the-json-notation)
- - [General syntax sugar](#general-syntax-sugar)
- - [Automatic arrays creation](#automatic-arrays-creation)
- - [Named keys hierarchy](#named-keys-hierarchy)
- - [Convenient numbers and booleans](#convenient-numbers-and-booleans)
-- [General improvements](#general-improvements)
- - [Comments](#comments)
- - [Macros support](#macros-support)
- - [Variables support](#variables-support)
- - [Multiline strings](#multiline-strings)
- - [Single quoted strings](#single-quoted-strings)
-- [Emitter](#emitter)
-- [Validation](#validation)
-- [Performance](#performance)
-- [Conclusion](#conclusion)
-
-## Introduction
-
-This document describes the main features and principles of the configuration
-language called `UCL` - universal configuration language.
-
-If you are looking for the libucl API documentation you can find it at [this page](doc/api.md).
-
-## Basic structure
-
-UCL is heavily infused by `nginx` configuration as the example of a convenient configuration
-system. However, UCL is fully compatible with `JSON` format and is able to parse json files.
-For example, you can write the same configuration in the following ways:
-
-* in nginx like:
-
-```nginx
-param = value;
-section {
- param = value;
- param1 = value1;
- flag = true;
- number = 10k;
- time = 0.2s;
- string = "something";
- subsection {
- host = {
- host = "hostname";
- port = 900;
- }
- host = {
- host = "hostname";
- port = 901;
- }
- }
-}
-```
-
-* or in JSON:
-
-```json
-{
- "param": "value",
- "section": {
- "param": "value",
- "param1": "value1",
- "flag": true,
- "number": 10000,
- "time": "0.2s",
- "string": "something",
- "subsection": {
- "host": [
- {
- "host": "hostname",
- "port": 900
- },
- {
- "host": "hostname",
- "port": 901
- }
- ]
- }
- }
-}
-```
-
-## Improvements to the json notation.
-
-There are various things that make ucl configuration more convenient for editing than strict json:
-
-### General syntax sugar
-
-* Braces are not necessary to enclose a top object: it is automatically treated as an object:
-
-```json
-"key": "value"
-```
-is equal to:
-```json
-{"key": "value"}
-```
-
-* There is no requirement of quotes for strings and keys, moreover, `:` may be replaced `=` or even be skipped for objects:
-
-```nginx
-key = value;
-section {
- key = value;
-}
-```
-is equal to:
-```json
-{
- "key": "value",
- "section": {
- "key": "value"
- }
-}
-```
-
-* No commas mess: you can safely place a comma or semicolon for the last element in an array or an object:
-
-```json
-{
- "key1": "value",
- "key2": "value",
-}
-```
-### Automatic arrays creation
-
-* Non-unique keys in an object are allowed and are automatically converted to the arrays internally:
-
-```json
-{
- "key": "value1",
- "key": "value2"
-}
-```
-is converted to:
-```json
-{
- "key": ["value1", "value2"]
-}
-```
-
-### Named keys hierarchy
-
-UCL accepts named keys and organize them into objects hierarchy internally. Here is an example of this process:
-```nginx
-section "blah" {
- key = value;
-}
-section foo {
- key = value;
-}
-```
-
-is converted to the following object:
-
-```nginx
-section {
- blah {
- key = value;
- }
- foo {
- key = value;
- }
-}
-```
-
-Plain definitions may be more complex and contain more than a single level of nested objects:
-
-```nginx
-section "blah" "foo" {
- key = value;
-}
-```
-
-is presented as:
-
-```nginx
-section {
- blah {
- foo {
- key = value;
- }
- }
-}
-```
-
-### Convenient numbers and booleans
-
-* Numbers can have suffixes to specify standard multipliers:
- + `[kKmMgG]` - standard 10 base multipliers (so `1k` is translated to 1000)
- + `[kKmMgG]b` - 2 power multipliers (so `1kb` is translated to 1024)
- + `[s|min|d|w|y]` - time multipliers, all time values are translated to float number of seconds, for example `10min` is translated to 600.0 and `10ms` is translated to 0.01
-* Hexadecimal integers can be used by `0x` prefix, for example `key = 0xff`. However, floating point values can use decimal base only.
-* Booleans can be specified as `true` or `yes` or `on` and `false` or `no` or `off`.
-* It is still possible to treat numbers and booleans as strings by enclosing them in double quotes.
-
-## General improvements
-
-### Comments
-
-UCL supports different style of comments:
-
-* single line: `#`
-* multiline: `/* ... */`
-
-Multiline comments may be nested:
-```c
-# Sample single line comment
-/*
- some comment
- /* nested comment */
- end of comment
-*/
-```
-
-### Macros support
-
-UCL supports external macros both multiline and single line ones:
-```nginx
-.macro_name "sometext";
-.macro_name {
- Some long text
- ....
-};
-```
-
-Moreover, each macro can accept an optional list of arguments in braces. These
-arguments themselves are the UCL object that is parsed and passed to a macro as
-options:
-
-```nginx
-.macro_name(param=value) "something";
-.macro_name(param={key=value}) "something";
-.macro_name(.include "params.conf") "something";
-.macro_name(#this is multiline macro
-param = [value1, value2]) "something";
-.macro_name(key="()") "something";
-```
-
-UCL also provide a convenient `include` macro to load content from another files
-to the current UCL object. This macro accepts either path to file:
-
-```nginx
-.include "/full/path.conf"
-.include "./relative/path.conf"
-.include "${CURDIR}/path.conf"
-```
-
-or URL (if ucl is built with url support provided by either `libcurl` or `libfetch`):
-
- .include "http://example.com/file.conf"
-
-`.include` macro supports a set of options:
-
-* `try` (default: **false**) - if this option is `true` than UCL treats errors on loading of
-this file as non-fatal. For example, such a file can be absent but it won't stop the parsing
-of the top-level document.
-* `sign` (default: **false**) - if this option is `true` UCL loads and checks the signature for
-a file from path named `<FILEPATH>.sig`. Trusted public keys should be provided for UCL API after
-parser is created but before any configurations are parsed.
-* `glob` (default: **false**) - if this option is `true` UCL treats the filename as GLOB pattern and load
-all files that matches the specified pattern (normally the format of patterns is defined in `glob` manual page
-for your operating system). This option is meaningless for URL includes.
-* `url` (default: **true**) - allow URL includes.
-* `path` (default: empty) - A UCL_ARRAY of directories to search for the include file.
-Search ends after the first match, unless `glob` is true, then all matches are included.
-* `prefix` (default false) - Put included contents inside an object, instead
-of loading them into the root. If no `key` is provided, one is automatically generated based on each files basename()
-* `key` (default: <empty string>) - Key to load contents of include into. If
-the key already exists, it must be the correct type
-* `target` (default: object) - Specify if the `prefix` `key` should be an
-object or an array.
-* `priority` (default: 0) - specify priority for the include (see below).
-* `duplicate` (default: 'append') - specify policy of duplicates resolving:
- - `append` - default strategy, if we have new object of higher priority then it replaces old one, if we have new object with less priority it is ignored completely, and if we have two duplicate objects with the same priority then we have a multi-value key (implicit array)
- - `merge` - if we have object or array, then new keys are merged inside, if we have a plain object then an implicit array is formed (regardless of priorities)
- - `error` - create error on duplicate keys and stop parsing
- - `rewrite` - always rewrite an old value with new one (ignoring priorities)
-
-Priorities are used by UCL parser to manage the policy of objects rewriting during including other files
-as following:
-
-* If we have two objects with the same priority then we form an implicit array
-* If a new object has bigger priority then we overwrite an old one
-* If a new object has lower priority then we ignore it
-
-By default, the priority of top-level object is set to zero (lowest priority). Currently,
-you can define up to 16 priorities (from 0 to 15). Includes with bigger priorities will
-rewrite keys from the objects with lower priorities as specified by the policy. The priority
-of the top-level or any other object can be changed with the `.priority` macro, which has no
-options and takes the new priority:
-
-```
-# Default priority: 0.
-foo = 6
-.priority 5
-# The following will have priority 5.
-bar = 6
-baz = 7
-# The following will be included with a priority of 3, 5, and 6 respectively.
-.include(priority=3) "path.conf"
-.include(priority=5) "equivalent-path.conf"
-.include(priority=6) "highpriority-path.conf"
-```
-
-### Variables support
-
-UCL supports variables in input. Variables are registered by a user of the UCL parser and can be presented in the following forms:
-
-* `${VARIABLE}`
-* `$VARIABLE`
-
-UCL currently does not support nested variables. To escape variables one could use double dollar signs:
-
-* `$${VARIABLE}` is converted to `${VARIABLE}`
-* `$$VARIABLE` is converted to `$VARIABLE`
-
-However, if no valid variables are found in a string, no expansion will be performed (and `$$` thus remains unchanged). This may be a subject
-to change in future libucl releases.
-
-### Multiline strings
-
-UCL can handle multiline strings as well as single line ones. It uses shell/perl like notation for such objects:
-```
-key = <<EOD
-some text
-splitted to
-lines
-EOD
-```
-
-In this example `key` will be interpreted as the following string: `some text\nsplitted to\nlines`.
-Here are some rules for this syntax:
-
-* Multiline terminator must start just after `<<` symbols and it must consist of capital letters only (e.g. `<<eof` or `<< EOF` won't work);
-* Terminator must end with a single newline character (and no spaces are allowed between terminator and newline character);
-* To finish multiline string you need to include a terminator string just after newline and followed by a newline (no spaces or other characters are allowed as well);
-* The initial and the final newlines are not inserted to the resulting string, but you can still specify newlines at the beginning and at the end of a value, for example:
-
-```
-key <<EOD
-
-some
-text
-
-EOD
-```
-
-### Single quoted strings
-
-It is possible to use single quoted strings to simplify escaping rules. All values passed in single quoted strings are *NOT* escaped, with two exceptions: a single `'` character just before `\` character, and a newline character just after `\` character that is ignored.
-
-```
-key = 'value'; # Read as value
-key = 'value\n\'; # Read as value\n\
-key = 'value\''; # Read as value'
-key = 'value\
-bla'; # Read as valuebla
-```
-
-## Emitter
-
-Each UCL object can be serialized to one of the four supported formats:
-
-* `JSON` - canonic json notation (with spaces indented structure);
-* `Compacted JSON` - compact json notation (without spaces or newlines);
-* `Configuration` - nginx like notation;
-* `YAML` - yaml inlined notation.
-
-## Validation
-
-UCL allows validation of objects. It uses the same schema that is used for json: [json schema v4](http://json-schema.org). UCL supports the full set of json schema with the exception of remote references. This feature is unlikely useful for configuration objects. Of course, a schema definition can be in UCL format instead of JSON that simplifies schemas writing. Moreover, since UCL supports multiple values for keys in an object it is possible to specify generic integer constraints `maxValues` and `minValues` to define the limits of values count in a single key. UCL currently is not absolutely strict about validation schemas themselves, therefore UCL users should supply valid schemas (as it is defined in json-schema draft v4) to ensure that the input objects are validated properly.
-
-## Performance
-
-Are UCL parser and emitter fast enough? Well, there are some numbers.
-I got a 19Mb file that consist of ~700 thousand lines of json (obtained via
-http://www.json-generator.com/). Then I checked jansson library that performs json
-parsing and emitting and compared it with UCL. Here are results:
-
-```
-jansson: parsed json in 1.3899 seconds
-jansson: emitted object in 0.2609 seconds
-
-ucl: parsed input in 0.6649 seconds
-ucl: emitted config in 0.2423 seconds
-ucl: emitted json in 0.2329 seconds
-ucl: emitted compact json in 0.1811 seconds
-ucl: emitted yaml in 0.2489 seconds
-```
-
-So far, UCL seems to be significantly faster than jansson on parsing and slightly faster on emitting. Moreover,
-UCL compiled with optimizations (-O3) performs significantly faster:
-```
-ucl: parsed input in 0.3002 seconds
-ucl: emitted config in 0.1174 seconds
-ucl: emitted json in 0.1174 seconds
-ucl: emitted compact json in 0.0991 seconds
-ucl: emitted yaml in 0.1354 seconds
-```
-
-You can do your own benchmarks by running `make check` in libucl top directory.
-
-## Conclusion
-
-UCL has clear design that should be very convenient for reading and writing. At the same time it is compatible with
-JSON language and therefore can be used as a simple JSON parser. Macro logic provides an ability to extend configuration
-language (for example by including some lua code) and comments allow to disable or enable the parts of a configuration
-quickly.
diff --git a/contrib/libucl/autogen.sh b/contrib/libucl/autogen.sh
deleted file mode 100755
index 68f4a174b46e..000000000000
--- a/contrib/libucl/autogen.sh
+++ /dev/null
@@ -1,2 +0,0 @@
-#!/bin/sh
-autoreconf -i
diff --git a/contrib/libucl/configure.ac b/contrib/libucl/configure.ac
deleted file mode 100644
index 731b7113e689..000000000000
--- a/contrib/libucl/configure.ac
+++ /dev/null
@@ -1,188 +0,0 @@
-m4_define([maj_ver], [0])
-m4_define([med_ver], [8])
-m4_define([min_ver], [1])
-m4_define([so_version], [6:0:1])
-m4_define([ucl_version], [maj_ver.med_ver.min_ver])
-
-AC_INIT([libucl],[ucl_version],[https://github.com/vstakhov/libucl],[libucl])
-AC_CONFIG_SRCDIR([configure.ac])
-AM_INIT_AUTOMAKE([1.11 foreign -Wall -Wportability no-dist-gzip dist-xz])
-m4_ifdef([AM_SILENT_RULES], [AM_SILENT_RULES([yes])])
-
-UCL_VERSION=ucl_version
-SO_VERSION=so_version
-
-AC_SUBST(UCL_VERSION)
-AC_SUBST(SO_VERSION)
-
-AC_PROG_CC_C99
-AM_PROG_CC_C_O
-AM_PROG_AR
-LT_INIT
-AC_CONFIG_MACRO_DIR([m4])
-AC_CONFIG_HEADERS([config.h])
-
-AC_C_CONST
-AC_TYPE_SIZE_T
-
-AC_CHECK_HEADERS_ONCE([fcntl.h unistd.h])
-AC_TYPE_OFF_T
-AC_FUNC_MMAP
-AC_CHECK_HEADERS_ONCE([fcntl.h])
-AC_CHECK_HEADERS_ONCE([sys/types.h])
-AC_CHECK_HEADERS_ONCE([sys/stat.h])
-AC_CHECK_HEADERS_ONCE([sys/param.h])
-AC_CHECK_HEADERS_ONCE([sys/mman.h])
-AC_CHECK_HEADERS_ONCE([stdlib.h])
-AC_CHECK_HEADERS_ONCE([stddef.h])
-AC_CHECK_HEADERS_ONCE([stdarg.h])
-AC_CHECK_HEADERS_ONCE([stdbool.h])
-AC_CHECK_HEADERS_ONCE([stdint.h])
-AC_CHECK_HEADERS_ONCE([string.h])
-AC_CHECK_HEADERS_ONCE([strings.h])
-AC_CHECK_HEADERS_ONCE([unistd.h])
-AC_CHECK_HEADERS_ONCE([ctype.h])
-AC_CHECK_HEADERS_ONCE([errno.h])
-AC_CHECK_HEADERS_ONCE([limits.h])
-AC_CHECK_HEADERS_ONCE([libgen.h])
-AC_CHECK_HEADERS_ONCE([stdio.h])
-AC_CHECK_HEADERS_ONCE([float.h])
-AC_CHECK_HEADERS_ONCE([math.h])
-AC_CHECK_HEADERS_ONCE([endian.h sys/endian.h machine/endian.h])
-
-dnl Example of default-disabled feature
-AC_ARG_ENABLE([urls], AS_HELP_STRING([--enable-urls],
- [Enable URLs fetch (requires libfetch or libcurl) @<:@default=no@:>@]), [],
- [enable_urls=no])
-AC_ARG_ENABLE([regex], AS_HELP_STRING([--enable-regex],
- [Enable regex checking for schema @<:@default=yes@:>@]), [],
- [enable_regex=yes])
-AC_ARG_ENABLE([signatures], AS_HELP_STRING([--enable-signatures],
- [Enable signatures check (requires openssl) @<:@default=no@:>@]), [],
- [enable_signatures=no])
-AC_ARG_ENABLE([lua], AS_HELP_STRING([--enable-lua],
- [Enable lua API build (requires lua libraries and headers) @<:@default=no@:>@]), [],
- [enable_lua=no])
-AC_ARG_ENABLE([utils],
- AS_HELP_STRING([--enable-utils], [Build and install utils @<:@default=no@:>@]),
- [case "${enableval}" in
- yes) utils=true ;;
- no) utils=false ;;
- *) AC_MSG_ERROR([bad value ${enableval} for --enable-utils]) ;;
- esac],[utils=false])
-AM_CONDITIONAL([UTILS], [test x$utils = xtrue])
-
-AS_IF([test "x$enable_signatures" = "xyes"], [
- AC_SEARCH_LIBS([CRYPTO_new_ex_data], [crypto], [
- AC_DEFINE(HAVE_OPENSSL, 1, [Define to 1 if you have the 'crypto' library (-lcrypto).])
- LIBCRYPTO_LIB="-lcrypto"
- LIBS_EXTRA="${LIBS_EXTRA} -lcrypto"
- ], [AC_MSG_ERROR([unable to find the CRYPTO_new_ex_data() function])])
-])
-AC_SUBST(LIBCRYPTO_LIB)
-AC_PATH_PROG(PANDOC, pandoc, [/non/existent])
-
-AC_SEARCH_LIBS([clock_gettime], [rt], [], [
- AC_CHECK_HEADER([mach/mach_time.h], [
- AC_DEFINE(HAVE_MACH_MACH_TIME_H, 1, [Define to 1 on Darwin])
- ], [AC_MSG_ERROR([unable to find clock_gettime or mach_absolute_time])])
-])
-AC_SEARCH_LIBS([remainder], [m], [], [AC_MSG_ERROR([unable to find remainder() function])])
-
-AS_IF([test "x$enable_regex" = "xyes"], [
- AC_CHECK_HEADER([regex.h], [
- AC_DEFINE(HAVE_REGEX_H, 1, [Define to 1 if you have the <regex.h> header file.])
- AC_SEARCH_LIBS([regexec], [regex], [
- AS_IF([test "x$ac_cv_search_regexec" = "x-lregex"], [
- LIBREGEX_LIB="-lregex"
- LIBS_EXTRA="${LIBS_EXTRA} -lregex"
- ]
- )],
- [AC_MSG_ERROR([unable to find the regexec() function])])],
- [AC_MSG_ERROR([unable to find the regex.h header])
- ],
- [#include <sys/types.h>])
-])
-AC_SUBST(LIBREGEX_LIB)
-
-AS_IF([test "x$enable_lua" = "xyes"], [
- AX_PROG_LUA([5.1], [], [
- AX_LUA_HEADERS([
- AX_LUA_LIBS([
- AC_DEFINE(HAVE_LUA, 1, [Define to 1 for lua support.])
- with_lua="yes"
- ], [AC_MSG_ERROR([unable to find the lua libraries])
- ])
- ], [AC_MSG_ERROR([unable to find the lua header files])
- ])
- ], [AC_MSG_ERROR([unable to find the lua interpreter])])
-], [with_lua="no"])
-
-AM_CONDITIONAL([LUA_SUB], [test "$with_lua" = "yes"])
-
-AS_IF([test "x$enable_urls" = "xyes"], [
- AC_CHECK_HEADER([fetch.h], [
- AC_DEFINE(HAVE_FETCH_H, 1, [Define to 1 if you have the <fetch.h> header file.])
- AC_CHECK_LIB(fetch, fetchXGet, [
- AC_DEFINE(HAVE_LIBFETCH, 1, [Define to 1 if you have the 'fetch' library (-lfetch).])
- LIBFETCH_LIBS="-lfetch"
- have_libfetch="yes"
- LIBS_EXTRA="${LIBS_EXTRA} -lfetch"
- ])
- ], [],[
- #include <stdio.h>
- #ifdef HAVE_SYS_PARAM_H
- #include <sys/param.h>
- #endif
- ])
- AC_SUBST(LIBFETCH_LIBS)
-
- AS_IF([ test "x$have_libfetch" != "xyes"], [
- dnl Fallback to libcurl
- PKG_CHECK_MODULES([CURL], [libcurl], [
- AC_DEFINE(CURL_FOUND, 1, [Use libcurl])
- LIBS_EXTRA="${LIBS_EXTRA} -lcurl"],
- [AC_MSG_ERROR([unable to find neither libfetch nor libcurl])])
- ])
- AC_SUBST(CURL_FOUND)
- AC_SUBST(CURL_LIBS)
- AC_SUBST(CURL_CFLAGS)
-])
-
-AC_SUBST(LIBS_EXTRA)
-
-AC_MSG_CHECKING(for GCC atomic builtins)
-AC_LINK_IFELSE([
- AC_LANG_SOURCE([[
- int main() {
- volatile unsigned long val = 1;
- __sync_synchronize();
- __sync_val_compare_and_swap(&val, 1, 0);
- __sync_add_and_fetch(&val, 1);
- __sync_sub_and_fetch(&val, 1);
- return 0;
- }
- ]])
-],
-[
- AC_MSG_RESULT([yes])
- AC_DEFINE([HAVE_ATOMIC_BUILTINS], [1], [Has gcc/MSVC atomic intrinsics])
-],
-[
- AC_MSG_RESULT([no])
- AC_DEFINE([HAVE_ATOMIC_BUILTINS], [0], [Has gcc/MSVC atomic intrinsics])
- AC_MSG_WARN([Libucl references could be thread-unsafe because atomic builtins are missing])
-])
-
-AX_CODE_COVERAGE
-
-AC_CONFIG_FILES(Makefile \
- src/Makefile \
- lua/Makefile
- tests/Makefile \
- utils/Makefile \
- doc/Makefile \
- lua/libucl.rockspec \
- libucl.pc)
-AC_CONFIG_FILES([stamp-h], [echo timestamp > stamp-h])
-AC_OUTPUT
diff --git a/contrib/libucl/doc/Makefile.am b/contrib/libucl/doc/Makefile.am
deleted file mode 100644
index dcfacf6a9a25..000000000000
--- a/contrib/libucl/doc/Makefile.am
+++ /dev/null
@@ -1,9 +0,0 @@
-EXTRA_DIST = api.md
-
-dist_man_MANS = libucl.3
-
-gen-man: @PANDOC@
- tail -n +$$(grep -n '# Synopsis' api.md | cut -d':' -f1) api.md | \
- cat pandoc.template - | sed -e 's/^# \(.*\)/# \U\1/' \
- -e "s/%%date%%/$$(LANG=C date +'%d %B, %Y')/" | \
- @PANDOC@ -s -f markdown -t man -o libucl.3
diff --git a/contrib/libucl/doc/api.md b/contrib/libucl/doc/api.md
deleted file mode 100644
index a0d33c0e68a9..000000000000
--- a/contrib/libucl/doc/api.md
+++ /dev/null
@@ -1,506 +0,0 @@
-# API documentation
-
-**Table of Contents** *generated with [DocToc](http://doctoc.herokuapp.com/)*
-
-- [Synopsis](#synopsis)
-- [Description](#description)
- - [Parser functions](#parser-functions)
- - [Emitting functions](#emitting-functions)
- - [Conversion functions](#conversion-functions)
- - [Generation functions](#generation-functions)
- - [Iteration functions](#iteration-functions)
- - [Validation functions](#validation-functions)
- - [Utility functions](#utility-functions)
-- [Parser functions](#parser-functions-1)
- - [ucl_parser_new](#ucl_parser_new)
- - [ucl_parser_register_macro](#ucl_parser_register_macro)
- - [ucl_parser_register_variable](#ucl_parser_register_variable)
- - [ucl_parser_add_chunk](#ucl_parser_add_chunk)
- - [ucl_parser_add_string](#ucl_parser_add_string)
- - [ucl_parser_add_file](#ucl_parser_add_file)
- - [ucl_parser_get_object](#ucl_parser_get_object)
- - [ucl_parser_get_error](#ucl_parser_get_error)
- - [ucl_parser_free](#ucl_parser_free)
- - [ucl_pubkey_add](#ucl_pubkey_add)
- - [ucl_parser_set_filevars](#ucl_parser_set_filevars)
- - [Parser usage example](#parser-usage-example)
-- [Emitting functions](#emitting-functions-1)
- - [ucl_object_emit](#ucl_object_emit)
- - [ucl_object_emit_full](#ucl_object_emit_full)
-- [Conversion functions](#conversion-functions-1)
-- [Generation functions](#generation-functions-1)
- - [ucl_object_new](#ucl_object_new)
- - [ucl_object_typed_new](#ucl_object_typed_new)
- - [Primitive objects generation](#primitive-objects-generation)
- - [ucl_object_fromstring_common](#ucl_object_fromstring_common)
-- [Iteration functions](#iteration-functions-1)
- - [ucl_iterate_object](#ucl_iterate_object)
-- [Validation functions](#validation-functions-1)
- - [ucl_object_validate](#ucl_object_validate)
-
-# Synopsis
-
-`#include <ucl.h>`
-
-# Description
-
-Libucl is a parser and `C` API to parse and generate `ucl` objects. Libucl consist of several groups of functions:
-
-### Parser functions
-Used to parse `ucl` files and provide interface to extract `ucl` object. Currently, `libucl` can parse only full `ucl` documents, for instance, it is impossible to parse a part of document and therefore it is impossible to use `libucl` as a streaming parser. In future, this limitation can be removed.
-
-### Emitting functions
-Convert `ucl` objects to some textual or binary representation. Currently, libucl supports the following exports:
-
-- `JSON` - valid json format (can possibly lose some original data, such as implicit arrays)
-- `Config` - human-readable configuration format (lossless)
-- `YAML` - embedded yaml format (has the same limitations as `json` output)
-
-### Conversion functions
-Help to convert `ucl` objects to C types. These functions are used to convert `ucl_object_t` to C primitive types, such as numbers, strings or boolean values.
-
-### Generation functions
-Allow creation of `ucl` objects from C types and creating of complex `ucl` objects, such as hashes or arrays from primitive `ucl` objects, such as numbers or strings.
-
-### Iteration functions
-Iterate over `ucl` complex objects or over a chain of values, for example when a key in an object has multiple values (that can be treated as implicit array or implicit consolidation).
-
-### Validation functions
-Validation functions are used to validate some object `obj` using json-schema compatible object `schema`. Both input and schema must be UCL objects to perform validation.
-
-### Utility functions
-Provide basic utilities to manage `ucl` objects: creating, removing, retaining and releasing reference count and so on.
-
-# Parser functions
-
-Parser functions operates with `struct ucl_parser`.
-
-### ucl_parser_new
-
-~~~C
-struct ucl_parser* ucl_parser_new (int flags);
-~~~
-
-Creates new parser with the specified flags:
-
-- `UCL_PARSER_KEY_LOWERCASE` - lowercase keys parsed
-- `UCL_PARSER_ZEROCOPY` - try to use zero-copy mode when reading files (in zero-copy mode text chunk being parsed without copying strings so it should exist till any object parsed is used)
-- `UCL_PARSER_NO_TIME` - treat time values as strings without parsing them as floats
-
-### ucl_parser_register_macro
-
-~~~C
-void ucl_parser_register_macro (struct ucl_parser *parser,
- const char *macro, ucl_macro_handler handler, void* ud);
-~~~
-
-Register new macro with name .`macro` parsed by handler `handler` that accepts opaque data pointer `ud`. Macro handler should be of the following type:
-
-~~~C
-bool (*ucl_macro_handler) (const unsigned char *data,
- size_t len, void* ud);`
-~~~
-
-Handler function accepts macro text `data` of length `len` and the opaque pointer `ud`. If macro is parsed successfully the handler should return `true`. `false` indicates parsing failure and the parser can be terminated.
-
-### ucl_parser_register_variable
-
-~~~C
-void ucl_parser_register_variable (struct ucl_parser *parser,
- const char *var, const char *value);
-~~~
-
-Register new variable $`var` that should be replaced by the parser to the `value` string.
-
-### ucl_parser_add_chunk
-
-~~~C
-bool ucl_parser_add_chunk (struct ucl_parser *parser,
- const unsigned char *data, size_t len);
-~~~
-
-Add new text chunk with `data` of length `len` to the parser. At the moment, `libucl` parser is not a streamlined parser and chunk *must* contain the *valid* ucl object. For example, this object should be valid:
-
-~~~json
-{ "var": "value" }
-~~~
-
-while this one won't be parsed correctly:
-
-~~~json
-{ "var":
-~~~
-
-This limitation may possible be removed in future.
-
-### ucl_parser_add_string
-~~~C
-bool ucl_parser_add_string (struct ucl_parser *parser,
- const char *data, size_t len);
-~~~
-
-This function acts exactly like `ucl_parser_add_chunk` does but if `len` argument is zero, then the string `data` must be zero-terminated and the actual length is calculated up to `\0` character.
-
-### ucl_parser_add_file
-
-~~~C
-bool ucl_parser_add_file (struct ucl_parser *parser,
- const char *filename);
-~~~
-
-Load file `filename` and parse it with the specified `parser`. This function uses `mmap` call to load file, therefore, it should not be `shrunk` during parsing. Otherwise, `libucl` can cause memory corruption and terminate the calling application. This function is also used by the internal handler of `include` macro, hence, this macro has the same limitation.
-
-### ucl_parser_get_object
-
-~~~C
-ucl_object_t* ucl_parser_get_object (struct ucl_parser *parser);
-~~~
-
-If the `ucl` data has been parsed correctly this function returns the top object for the parser. Otherwise, this function returns the `NULL` pointer. The reference count for `ucl` object returned is increased by one, therefore, a caller should decrease reference by using `ucl_object_unref` to free object after usage.
-
-### ucl_parser_get_error
-
-~~~C
-const char *ucl_parser_get_error(struct ucl_parser *parser);
-~~~
-
-Returns the constant error string for the parser object. If no error occurred during parsing a `NULL` object is returned. A caller should not try to free or modify this string.
-
-### ucl_parser_free
-
-~~~C
-void ucl_parser_free (struct ucl_parser *parser);
-~~~
-
-Frees memory occupied by the parser object. The reference count for top object is decreased as well, however if the function `ucl_parser_get_object` was called previously then the top object won't be freed.
-
-### ucl_pubkey_add
-
-~~~C
-bool ucl_pubkey_add (struct ucl_parser *parser,
- const unsigned char *key, size_t len);
-~~~
-
-This function adds a public key from text blob `key` of length `len` to the `parser` object. This public key should be in the `PEM` format and can be used by `.includes` macro for checking signatures of files included. `Openssl` support should be enabled to make this function working. If a key cannot be added (e.g. due to format error) or `openssl` was not linked to `libucl` then this function returns `false`.
-
-### ucl_parser_set_filevars
-
-~~~C
-bool ucl_parser_set_filevars (struct ucl_parser *parser,
- const char *filename, bool need_expand);
-~~~
-
-Add the standard file variables to the `parser` based on the `filename` specified:
-
-- `$FILENAME` - a filename of `ucl` input
-- `$CURDIR` - a current directory of the input
-
-For example, if a `filename` param is `../something.conf` then the variables will have the following values:
-
-- `$FILENAME` - "../something.conf"
-- `$CURDIR` - ".."
-
-if `need_expand` parameter is `true` then all relative paths are expanded using `realpath` call. In this example if `..` is `/etc/dir` then variables will have these values:
-
-- `$FILENAME` - "/etc/something.conf"
-- `$CURDIR` - "/etc"
-
-## Parser usage example
-
-The following example loads, parses and extracts `ucl` object from stdin using `libucl` parser functions (the length of input is limited to 8K):
-
-~~~C
-char inbuf[8192];
-struct ucl_parser *parser = NULL;
-int ret = 0, r = 0;
-ucl_object_t *obj = NULL;
-FILE *in;
-
-in = stdin;
-parser = ucl_parser_new (0);
-while (!feof (in) && r < (int)sizeof (inbuf)) {
- r += fread (inbuf + r, 1, sizeof (inbuf) - r, in);
-}
-ucl_parser_add_chunk (parser, inbuf, r);
-fclose (in);
-
-if (ucl_parser_get_error (parser)) {
- printf ("Error occurred: %s\n", ucl_parser_get_error (parser));
- ret = 1;
-}
-else {
- obj = ucl_parser_get_object (parser);
-}
-
-if (parser != NULL) {
- ucl_parser_free (parser);
-}
-if (obj != NULL) {
- ucl_object_unref (obj);
-}
-return ret;
-~~~
-
-# Emitting functions
-
-Libucl can transform UCL objects to a number of textual formats:
-
-- configuration (`UCL_EMIT_CONFIG`) - nginx like human readable configuration file where implicit arrays are transformed to the duplicate keys
-- compact json: `UCL_EMIT_JSON_COMPACT` - single line valid json without spaces
-- formatted json: `UCL_EMIT_JSON` - pretty formatted JSON with newlines and spaces
-- compact yaml: `UCL_EMIT_YAML` - compact YAML output
-
-Moreover, libucl API allows to select a custom set of emitting functions allowing
-efficient and zero-copy output of libucl objects. Libucl uses the following structure to support this feature:
-
-~~~C
-struct ucl_emitter_functions {
- /** Append a single character */
- int (*ucl_emitter_append_character) (unsigned char c, size_t nchars, void *ud);
- /** Append a string of a specified length */
- int (*ucl_emitter_append_len) (unsigned const char *str, size_t len, void *ud);
- /** Append a 64 bit integer */
- int (*ucl_emitter_append_int) (int64_t elt, void *ud);
- /** Append floating point element */
- int (*ucl_emitter_append_double) (double elt, void *ud);
- /** Opaque userdata pointer */
- void *ud;
-};
-~~~
-
-This structure defines the following callbacks:
-
-- `ucl_emitter_append_character` - a function that is called to append `nchars` characters equal to `c`
-- `ucl_emitter_append_len` - used to append a string of length `len` starting from pointer `str`
-- `ucl_emitter_append_int` - this function applies to integer numbers
-- `ucl_emitter_append_double` - this function is intended to output floating point variable
-
-The set of these functions could be used to output text formats of `UCL` objects to different structures or streams.
-
-Libucl provides the following functions for emitting UCL objects:
-
-### ucl_object_emit
-
-~~~C
-unsigned char *ucl_object_emit (const ucl_object_t *obj, enum ucl_emitter emit_type);
-~~~
-
-Allocate a string that is suitable to fit the underlying UCL object `obj` and fill it with the textual representation of the object `obj` according to style `emit_type`. The caller should free the returned string after using.
-
-### ucl_object_emit_full
-
-~~~C
-bool ucl_object_emit_full (const ucl_object_t *obj, enum ucl_emitter emit_type,
- struct ucl_emitter_functions *emitter);
-~~~
-
-This function is similar to the previous with the exception that it accepts the additional argument `emitter` that defines the concrete set of output functions. This emit function could be useful for custom structures or streams emitters (including C++ ones, for example).
-
-# Conversion functions
-
-Conversion functions are used to convert UCL objects to primitive types, such as strings, numbers, or boolean values. There are two types of conversion functions:
-
-- safe: try to convert an ucl object to a primitive type and fail if such a conversion is not possible
-- unsafe: return primitive type without additional checks, if the object cannot be converted then some reasonable default is returned (NULL for strings and 0 for numbers)
-
-Also there is a single `ucl_object_tostring_forced` function that converts any UCL object (including compound types - arrays and objects) to a string representation. For objects, arrays, booleans and numeric types this function performs emitting to a compact json format actually.
-
-Here is a list of all conversion functions:
-
-- `ucl_object_toint` - returns `int64_t` of UCL object
-- `ucl_object_todouble` - returns `double` of UCL object
-- `ucl_object_toboolean` - returns `bool` of UCL object
-- `ucl_object_tostring` - returns `const char *` of UCL object (this string is NULL terminated)
-- `ucl_object_tolstring` - returns `const char *` and `size_t` len of UCL object (string does not need to be NULL terminated)
-- `ucl_object_tostring_forced` - returns string representation of any UCL object
-
-Strings returned by these pointers are associated with the UCL object and exist over its lifetime. A caller should not free this memory.
-
-# Generation functions
-
-It is possible to generate UCL objects from C primitive types. Moreover, libucl allows creation and modifying complex UCL objects, such as arrays or associative objects.
-
-## ucl_object_new
-~~~C
-ucl_object_t * ucl_object_new (void)
-~~~
-
-Creates new object of type `UCL_NULL`. This object should be released by caller.
-
-## ucl_object_typed_new
-~~~C
-ucl_object_t * ucl_object_typed_new (unsigned int type)
-~~~
-
-Create an object of a specified type:
-- `UCL_OBJECT` - UCL object - key/value pairs
-- `UCL_ARRAY` - UCL array
-- `UCL_INT` - integer number
-- `UCL_FLOAT` - floating point number
-- `UCL_STRING` - NULL terminated string
-- `UCL_BOOLEAN` - boolean value
-- `UCL_TIME` - time value (floating point number of seconds)
-- `UCL_USERDATA` - opaque userdata pointer (may be used in macros)
-- `UCL_NULL` - null value
-
-This object should be released by caller.
-
-## Primitive objects generation
-Libucl provides the functions similar to inverse conversion functions called with the specific C type:
-- `ucl_object_fromint` - converts `int64_t` to UCL object
-- `ucl_object_fromdouble` - converts `double` to UCL object
-- `ucl_object_frombool` - converts `bool` to UCL object
-- `ucl_object_fromstring` - converts `const char *` to UCL object (this string should be NULL terminated)
-- `ucl_object_fromlstring` - converts `const char *` and `size_t` len to UCL object (string does not need to be NULL terminated)
-
-Also there is a function to generate UCL object from a string performing various parsing or conversion operations called `ucl_object_fromstring_common`.
-
-## ucl_object_fromstring_common
-~~~C
-ucl_object_t * ucl_object_fromstring_common (const char *str,
- size_t len, enum ucl_string_flags flags)
-~~~
-
-This function is used to convert a string `str` of size `len` to a UCL object applying `flags` conversions. If `len` is equal to zero then a `str` is assumed as NULL-terminated. This function supports the following flags (a set of flags can be specified using logical `OR` operation):
-
-- `UCL_STRING_ESCAPE` - perform JSON escape
-- `UCL_STRING_TRIM` - trim leading and trailing whitespaces
-- `UCL_STRING_PARSE_BOOLEAN` - parse passed string and detect boolean
-- `UCL_STRING_PARSE_INT` - parse passed string and detect integer number
-- `UCL_STRING_PARSE_DOUBLE` - parse passed string and detect integer or float number
-- `UCL_STRING_PARSE_TIME` - parse time values as floating point numbers
-- `UCL_STRING_PARSE_NUMBER` - parse passed string and detect number (both float, integer and time types)
-- `UCL_STRING_PARSE` - parse passed string (and detect booleans, numbers and time values)
-- `UCL_STRING_PARSE_BYTES` - assume that numeric multipliers are in bytes notation, for example `10k` means `10*1024` and not `10*1000` as assumed without this flag
-
-If parsing operations fail then the resulting UCL object will be a `UCL_STRING`. A caller should always check the type of the returned object and release it after using.
-
-# Iteration functions
-
-Iteration are used to iterate over UCL compound types: arrays and objects. Moreover, iterations could be performed over the keys with multiple values (implicit arrays).
-There are two types of iterators API: old and unsafe one via `ucl_iterate_object` and the proposed interface of safe iterators.
-
-
-## ucl_iterate_object
-~~~C
-const ucl_object_t* ucl_iterate_object (const ucl_object_t *obj,
- ucl_object_iter_t *iter, bool expand_values);
-~~~
-
-This function accepts opaque iterator pointer `iter`. In the first call this iterator *must* be initialized to `NULL`. Iterator is changed by this function call. `ucl_iterate_object` returns the next UCL object in the compound object `obj` or `NULL` if all objects have been iterated. The reference count of the object returned is not increased, so a caller should not unref the object or modify its content (e.g. by inserting to another compound object). The object `obj` should not be changed during the iteration process as well. `expand_values` flag speicifies whether `ucl_iterate_object` should expand keys with multiple values. The general rule is that if you need to iterate through the *object* or *explicit array*, then you always need to set this flag to `true`. However, if you get some key in the object and want to extract all its values then you should set `expand_values` to `false`. Mixing of iteration types is not permitted since the iterator is set according to the iteration type and cannot be reused. Here is an example of iteration over the objects using libucl API (assuming that `top` is `UCL_OBJECT` in this example):
-
-~~~C
-ucl_object_iter_t it = NULL, it_obj = NULL;
-const ucl_object_t *cur, *tmp;
-
-/* Iterate over the object */
-while ((obj = ucl_iterate_object (top, &it, true))) {
- printf ("key: \"%s\"\n", ucl_object_key (obj));
- /* Iterate over the values of a key */
- while ((cur = ucl_iterate_object (obj, &it_obj, false))) {
- printf ("value: \"%s\"\n",
- ucl_object_tostring_forced (cur));
- }
-}
-~~~
-
-## Safe iterators API
-
-Safe iterators are defined to clarify iterating over UCL objects and simplify flattening of UCL objects in non-trivial cases.
-For example, if there is an implicit array that contains another array and a boolean value it is extremely unclear how to iterate over
-such an object. Safe iterators are desinged to define two sorts of iteration:
-
-1. Iteration over complex objects with expanding all values
-2. Iteration over complex objects without expanding of values
-
-The following example demonstrates the difference between these two types of iteration:
-
-~~~
-key = 1;
-key = [2, 3, 4];
-
-Iteration with expansion:
-
-1, 2, 3, 4
-
-Iteration without expansion:
-
-1, [2, 3, 4]
-~~~
-
-UCL defines the following functions to manage safe iterators:
-
-- `ucl_object_iterate_new` - creates new safe iterator
-- `ucl_object_iterate_reset` - resets iterator to a new object
-- `ucl_object_iterate_safe` - safely iterate the object inside iterator. Note: function may allocate and free memory during its operation. Therefore it returns `NULL` either while trying to access item after the last one or when exception (such as memory allocation failure) happens.
-- `ucl_object_iter_chk_excpn` - check if the last call to `ucl_object_iterate_safe` ended up in unrecoverable exception (e.g. `ENOMEM`).
-- `ucl_object_iterate_free` - free memory associated with the safe iterator
-
-Please note that unlike unsafe iterators, safe iterators *must* be explicitly initialized and freed.
-An assert is likely generated if you use uninitialized or `NULL` iterator in all safe iterators functions.
-
-~~~C
-ucl_object_iter_t it;
-const ucl_object_t *cur;
-
-it = ucl_object_iterate_new (obj);
-
-while ((cur = ucl_object_iterate_safe (it, true)) != NULL) {
- /* Do something */
-}
-/* Check error condition */
-if (ucl_object_iter_chk_excpn (it)) {
- ucl_object_iterate_free (it);
- exit (1);
-}
-
-/* Switch to another object */
-it = ucl_object_iterate_reset (it, another_obj);
-
-while ((cur = ucl_object_iterate_safe (it, true)) != NULL) {
- /* Do something else */
-}
-/* Check error condition */
-if (ucl_object_iter_chk_excpn (it)) {
- ucl_object_iterate_free (it);
- exit (1);
-}
-
-ucl_object_iterate_free (it);
-~~~
-
-# Validation functions
-
-Currently, there is only one validation function called `ucl_object_validate`. It performs validation of object using the specified schema. This function is defined as following:
-
-## ucl_object_validate
-~~~C
-bool ucl_object_validate (const ucl_object_t *schema,
- const ucl_object_t *obj, struct ucl_schema_error *err);
-~~~
-
-This function uses ucl object `schema`, that must be valid in terms of `json-schema` draft v4, to validate input object `obj`. If this function returns `true` then validation procedure has been succeed. Otherwise, `false` is returned and `err` is set to a specific value. If a caller sets `err` to NULL then this function does not set any error just returning `false`. Error is the structure defined as following:
-
-~~~C
-struct ucl_schema_error {
- enum ucl_schema_error_code code; /* error code */
- char msg[128]; /* error message */
- ucl_object_t *obj; /* object where error occurred */
-};
-~~~
-
-Caller may use `code` field to get a numeric error code:
-
-~~~C
-enum ucl_schema_error_code {
- UCL_SCHEMA_OK = 0, /* no error */
- UCL_SCHEMA_TYPE_MISMATCH, /* type of object is incorrect */
- UCL_SCHEMA_INVALID_SCHEMA, /* schema is invalid */
- UCL_SCHEMA_MISSING_PROPERTY,/* missing properties */
- UCL_SCHEMA_CONSTRAINT, /* constraint found */
- UCL_SCHEMA_MISSING_DEPENDENCY, /* missing dependency */
- UCL_SCHEMA_UNKNOWN /* generic error */
-};
-~~~
-
-`msg` is a string description of an error and `obj` is an object where error has occurred. Error object is not allocated by libucl, so there is no need to free it after validation (a static object should thus be used).
diff --git a/contrib/libucl/doc/lua_api.md b/contrib/libucl/doc/lua_api.md
deleted file mode 100644
index 7da414903b01..000000000000
--- a/contrib/libucl/doc/lua_api.md
+++ /dev/null
@@ -1,196 +0,0 @@
-## Module `ucl`
-
-This lua module allows to parse objects from strings and to store data into
-ucl objects. It uses `libucl` C library to parse and manipulate with ucl objects.
-
-Example:
-
-~~~lua
-local ucl = require("ucl")
-
-local parser = ucl.parser()
-local res,err = parser:parse_string('{key=value}')
-
-if not res then
- print('parser error: ' .. err)
-else
- local obj = parser:get_object()
- local got = ucl.to_format(obj, 'json')
-end
-
-local table = {
- str = 'value',
- num = 100500,
- null = ucl.null,
- func = function ()
- return 'huh'
- end
-}
-
-
-print(ucl.to_format(table, 'ucl'))
--- Output:
---[[
-num = 100500;
-str = "value";
-null = null;
-func = "huh";
---]]
-~~~
-
-###Brief content:
-
-**Functions**:
-
-> [`ucl_object_push_lua(L, obj, allow_array)`](#function-ucl_object_push_lual-obj-allow_array)
-
-> [`ucl.to_format(var, format)`](#function-uclto_formatvar-format)
-
-
-
-**Methods**:
-
-> [`parser:parse_file(name)`](#method-parserparse_filename)
-
-> [`parser:parse_string(input)`](#method-parserparse_stringinput)
-
-> [`parser:get_object()`](#method-parserget_object)
-
-
-## Functions
-
-The module `ucl` defines the following functions.
-
-### Function `ucl_object_push_lua(L, obj, allow_array)`
-
-This is a `C` function to push `UCL` object as lua variable. This function
-converts `obj` to lua representation using the following conversions:
-
-- *scalar* values are directly presented by lua objects
-- *userdata* values are converted to lua function objects using `LUA_REGISTRYINDEX`,
-this can be used to pass functions from lua to c and vice-versa
-- *arrays* are converted to lua tables with numeric indices suitable for `ipairs` iterations
-- *objects* are converted to lua tables with string indices
-
-**Parameters:**
-
-- `L {lua_State}`: lua state pointer
-- `obj {ucl_object_t}`: object to push
-- `allow_array {bool}`: expand implicit arrays (should be true for all but partial arrays)
-
-**Returns:**
-
-- `{int}`: `1` if an object is pushed to lua
-
-Back to [module description](#module-ucl).
-
-### Function `ucl.to_format(var, format)`
-
-Converts lua variable `var` to the specified `format`. Formats supported are:
-
-- `json` - fine printed json
-- `json-compact` - compacted json
-- `config` - fine printed configuration
-- `ucl` - same as `config`
-- `yaml` - embedded yaml
-
-If `var` contains function, they are called during output formatting and if
-they return string value, then this value is used for ouptut.
-
-**Parameters:**
-
-- `var {variant}`: any sort of lua variable (if userdata then metafield `__to_ucl` is searched for output)
-- `format {string}`: any available format
-
-**Returns:**
-
-- `{string}`: string representation of `var` in the specific `format`.
-
-Example:
-
-~~~lua
-local table = {
- str = 'value',
- num = 100500,
- null = ucl.null,
- func = function ()
- return 'huh'
- end
-}
-
-
-print(ucl.to_format(table, 'ucl'))
--- Output:
---[[
-num = 100500;
-str = "value";
-null = null;
-func = "huh";
---]]
-~~~
-
-Back to [module description](#module-ucl).
-
-
-## Methods
-
-The module `ucl` defines the following methods.
-
-### Method `parser:parse_file(name)`
-
-Parse UCL object from file.
-
-**Parameters:**
-
-- `name {string}`: filename to parse
-
-**Returns:**
-
-- `{bool[, string]}`: if res is `true` then file has been parsed successfully, otherwise an error string is also returned
-
-Example:
-
-~~~lua
-local parser = ucl.parser()
-local res,err = parser:parse_file('/some/file.conf')
-
-if not res then
- print('parser error: ' .. err)
-else
- -- Do something with object
-end
-~~~
-
-Back to [module description](#module-ucl).
-
-### Method `parser:parse_string(input)`
-
-Parse UCL object from file.
-
-**Parameters:**
-
-- `input {string}`: string to parse
-
-**Returns:**
-
-- `{bool[, string]}`: if res is `true` then file has been parsed successfully, otherwise an error string is also returned
-
-Back to [module description](#module-ucl).
-
-### Method `parser:get_object()`
-
-Get top object from parser and export it to lua representation.
-
-**Parameters:**
-
- nothing
-
-**Returns:**
-
-- `{variant or nil}`: ucl object as lua native variable
-
-Back to [module description](#module-ucl).
-
-
-Back to [top](#).
-
diff --git a/contrib/libucl/doc/pandoc.template b/contrib/libucl/doc/pandoc.template
deleted file mode 100644
index 2effe1a157ef..000000000000
--- a/contrib/libucl/doc/pandoc.template
+++ /dev/null
@@ -1,12 +0,0 @@
-% LIBUCL(3) Libucl manual
-% Vsevolod Stakhov <vsevolod@highsecure.ru>
-% %%date%%
-
-# Name
-
-**ucl_parser_new**, **ucl_parser_register_macro**, **ucl_parser_register_variable**, **ucl_parser_add_chunk**, **ucl_parser_add_string**, **ucl_parser_add_file**, **ucl_parser_get_object**, **ucl_parser_get_error**, **ucl_parser_free**, **ucl_pubkey_add**, **ucl_parser_set_filevars** - universal configuration library parser and utility functions
-
-# Library
-
-UCL library (libucl, -lucl)
-
diff --git a/contrib/libucl/examples/ucl_cpp.cc b/contrib/libucl/examples/ucl_cpp.cc
deleted file mode 100644
index 2d15d84a6c8d..000000000000
--- a/contrib/libucl/examples/ucl_cpp.cc
+++ /dev/null
@@ -1,26 +0,0 @@
-#include <iostream>
-#include <string>
-#include "ucl++.h"
-
-int main(int argc, char **argv)
-{
- std::string input, err;
-
- input.assign((std::istreambuf_iterator<char>(std::cin)),
- std::istreambuf_iterator<char>());
-
- auto obj = ucl::Ucl::parse(input, err);
-
- if (obj) {
- std::cout << obj.dump(UCL_EMIT_CONFIG) << std::endl;
-
- for (const auto &o : obj) {
- std::cout << o.dump(UCL_EMIT_CONFIG) << std::endl;
- }
- }
- else {
- std::cerr << "Error: " << err << std::endl;
-
- return 1;
- }
-}
diff --git a/contrib/libucl/haskell/hucl.hs b/contrib/libucl/haskell/hucl.hs
deleted file mode 100644
index 2dd3ac01e4c0..000000000000
--- a/contrib/libucl/haskell/hucl.hs
+++ /dev/null
@@ -1,123 +0,0 @@
-{-# LANGUAGE ForeignFunctionInterface #-}
-
--- an example UCL FFI module:
--- uses the Object Model from Messagepack to emit
---
-
-module Data.UCL ( unpack ) where
-import Foreign.C
-import Foreign.Ptr
-import System.IO.Unsafe ( unsafePerformIO )
-import qualified Data.Text as T
-import qualified Data.Vector as V
-import qualified Data.MessagePack as MSG
-
-type ParserHandle = Ptr ()
-type UCLObjectHandle = Ptr ()
-type UCLIterHandle = Ptr ()
-type UCLEmitterType = CInt
-type ErrorString = String
-
-
-foreign import ccall "ucl_parser_new" ucl_parser_new :: CInt -> ParserHandle
-foreign import ccall "ucl_parser_add_string" ucl_parser_add_string :: ParserHandle -> CString -> CUInt -> IO Bool
-foreign import ccall "ucl_parser_add_file" ucl_parser_add_file :: ParserHandle -> CString -> IO Bool
-foreign import ccall "ucl_parser_get_object" ucl_parser_get_object :: ParserHandle -> UCLObjectHandle
-foreign import ccall "ucl_parser_get_error" ucl_parser_get_error :: ParserHandle -> CString
-
-foreign import ccall "ucl_object_iterate_new" ucl_object_iterate_new :: UCLObjectHandle -> UCLIterHandle
-foreign import ccall "ucl_object_iterate_safe" ucl_object_iterate_safe :: UCLIterHandle -> Bool -> UCLObjectHandle
-foreign import ccall "ucl_object_type" ucl_object_type :: UCLObjectHandle -> CUInt
-foreign import ccall "ucl_object_key" ucl_object_key :: UCLObjectHandle -> CString
-foreign import ccall "ucl_object_toint" ucl_object_toint :: UCLObjectHandle -> CInt
-foreign import ccall "ucl_object_todouble" ucl_object_todouble :: UCLObjectHandle -> CDouble
-foreign import ccall "ucl_object_tostring" ucl_object_tostring :: UCLObjectHandle -> CString
-foreign import ccall "ucl_object_toboolean" ucl_object_toboolean :: UCLObjectHandle -> Bool
-
-foreign import ccall "ucl_object_emit" ucl_object_emit :: UCLObjectHandle -> UCLEmitterType -> CString
-foreign import ccall "ucl_object_emit_len" ucl_object_emit_len :: UCLObjectHandle -> UCLEmitterType -> Ptr CSize -> IO CString
-
-type UCL_TYPE = CUInt
-ucl_OBJECT :: UCL_TYPE
-ucl_OBJECT = 0
-ucl_ARRAY :: UCL_TYPE
-ucl_ARRAY = 1
-ucl_INT :: UCL_TYPE
-ucl_INT = 2
-ucl_FLOAT :: UCL_TYPE
-ucl_FLOAT = 3
-ucl_STRING :: UCL_TYPE
-ucl_STRING = 4
-ucl_BOOLEAN :: UCL_TYPE
-ucl_BOOLEAN = 5
-ucl_TIME :: UCL_TYPE
-ucl_TIME = 6
-ucl_USERDATA :: UCL_TYPE
-ucl_USERDATA = 7
-ucl_NULL :: UCL_TYPE
-ucl_NULL = 8
-
-ucl_emit_json :: UCLEmitterType
-ucl_emit_json = 0
-ucl_emit_json_compact :: UCLEmitterType
-ucl_emit_json_compact = 1 :: UCLEmitterType
-ucl_emit_msgpack :: UCLEmitterType
-ucl_emit_msgpack = 4 :: UCLEmitterType
-
-ucl_parser_parse_string_pure :: String -> Either UCLObjectHandle ErrorString
-ucl_parser_parse_string_pure s = unsafePerformIO $ do
- cs <- newCString s
- let p = ucl_parser_new 0x4
- didParse <- ucl_parser_add_string p cs (toEnum $ length s)
- if didParse
- then return $ Left $ ucl_parser_get_object p
- else Right <$> peekCString ( ucl_parser_get_error p)
-
-ucl_parser_add_file_pure :: String -> Either UCLObjectHandle ErrorString
-ucl_parser_add_file_pure s = unsafePerformIO $ do
- cs <- newCString s
- let p = ucl_parser_new 0x4
- didParse <- ucl_parser_add_file p cs
- if didParse
- then return $ Left $ ucl_parser_get_object p
- else Right <$> peekCString ( ucl_parser_get_error p)
-
-unpack :: MSG.MessagePack a => String -> Either a ErrorString
-unpack s = case ucl_parser_parse_string_pure s of
- (Right err) -> Right err
- (Left obj) -> case MSG.fromObject (ucl_to_msgpack_object obj) of
- Nothing -> Right "MessagePack fromObject Error"
- (Just a) -> Left a
-
-ucl_to_msgpack_object :: UCLObjectHandle -> MSG.Object
-ucl_to_msgpack_object o = toMsgPackObj (ucl_object_type o) o
- where
- toMsgPackObj n obj
- |n==ucl_OBJECT = MSG.ObjectMap $ uclObjectToVector obj
- |n==ucl_ARRAY = MSG.ObjectArray undefined
- |n==ucl_INT = MSG.ObjectInt $ fromEnum $ ucl_object_toint obj
- |n==ucl_FLOAT = MSG.ObjectDouble $ realToFrac $ ucl_object_todouble obj
- |n==ucl_STRING = MSG.ObjectStr $ T.pack $ unsafePerformIO $ peekCString $ ucl_object_tostring obj
- |n==ucl_BOOLEAN = MSG.ObjectBool $ ucl_object_toboolean obj
- |n==ucl_TIME = error "time undefined"
- |n==ucl_USERDATA = error "userdata undefined"
- |n==ucl_NULL = error "null undefined"
- |otherwise = error "\"Unknown Type\" Error"
-
-uclObjectToVector :: UCLObjectHandle -> V.Vector (MSG.Object,MSG.Object)
-uclObjectToVector o = iterateObject (ucl_object_iterate_safe iter True ) iter V.empty
- where
- iter = ucl_object_iterate_new o
- iterateObject obj it vec = if ucl_object_type obj == ucl_NULL
- then vec
- else iterateObject (ucl_object_iterate_safe it True) it (V.snoc vec ( getUclKey obj , ucl_to_msgpack_object obj))
- getUclKey obj = MSG.ObjectStr $ T.pack $ unsafePerformIO $ peekCString $ ucl_object_key obj
-
-uclArrayToVector :: UCLObjectHandle -> V.Vector MSG.Object
-uclArrayToVector o = iterateArray (ucl_object_iterate_safe iter True ) iter V.empty
- where
- iter = ucl_object_iterate_new o
- iterateArray obj it vec = if ucl_object_type obj == ucl_NULL
- then vec
- else iterateArray (ucl_object_iterate_safe it True) it (V.snoc vec (ucl_to_msgpack_object obj))
-
diff --git a/contrib/libucl/include/ucl.h b/contrib/libucl/include/ucl.h
index 39da2593648d..b8625b9fce2f 100644
--- a/contrib/libucl/include/ucl.h
+++ b/contrib/libucl/include/ucl.h
@@ -1411,13 +1411,13 @@ struct ucl_emitter_operations {
const ucl_object_t *obj, bool first, bool print_key);
/** Start ucl object */
void (*ucl_emitter_start_object) (struct ucl_emitter_context *ctx,
- const ucl_object_t *obj, bool print_key);
+ const ucl_object_t *obj, bool first, bool print_key);
/** End ucl object */
void (*ucl_emitter_end_object) (struct ucl_emitter_context *ctx,
const ucl_object_t *obj);
/** Start ucl array */
void (*ucl_emitter_start_array) (struct ucl_emitter_context *ctx,
- const ucl_object_t *obj, bool print_key);
+ const ucl_object_t *obj, bool first, bool print_key);
void (*ucl_emitter_end_array) (struct ucl_emitter_context *ctx,
const ucl_object_t *obj);
};
diff --git a/contrib/libucl/libucl.pc b/contrib/libucl/libucl.pc
deleted file mode 100644
index 4878bebafcdd..000000000000
--- a/contrib/libucl/libucl.pc
+++ /dev/null
@@ -1,11 +0,0 @@
-prefix=/usr/local
-exec_prefix=${prefix}
-libdir=${exec_prefix}/lib
-includedir=${prefix}/include
-
-Name: LibUCL
-Description: Universal configuration library
-Version: 0.9.0
-Libs: -L${libdir} -lucl
-Libs.private:
-Cflags: -I${includedir}/
diff --git a/contrib/libucl/libucl.pc.in b/contrib/libucl/libucl.pc.in
deleted file mode 100644
index 3433fa9d8b1c..000000000000
--- a/contrib/libucl/libucl.pc.in
+++ /dev/null
@@ -1,11 +0,0 @@
-prefix=@prefix@
-exec_prefix=@exec_prefix@
-libdir=@libdir@
-includedir=@includedir@
-
-Name: LibUCL
-Description: Universal configuration library
-Version: @UCL_VERSION@
-Libs: -L${libdir} -lucl
-Libs.private: @LIBS_EXTRA@ @LUA_LIB@
-Cflags: -I${includedir}/
diff --git a/contrib/libucl/lua/Makefile.am b/contrib/libucl/lua/Makefile.am
deleted file mode 100644
index 95beafbfc94e..000000000000
--- a/contrib/libucl/lua/Makefile.am
+++ /dev/null
@@ -1,26 +0,0 @@
-ucl_common_cflags= -I$(top_srcdir)/src \
- -I$(top_srcdir)/include \
- -I$(top_srcdir)/uthash \
- -Wall -W -Wno-unused-parameter -Wno-pointer-sign
-luaexec_LTLIBRARIES= ucl.la
-ucl_la_SOURCES= lua_ucl.c
-ucl_la_CFLAGS= $(ucl_common_cflags) \
- @LUA_INCLUDE@
-ucl_la_LDFLAGS = -module -export-dynamic -avoid-version
-ucl_la_LIBADD= $(top_srcdir)/src/libucl.la \
- @LIBFETCH_LIBS@ \
- @LIBCRYPTO_LIB@ \
- @LIBREGEX_LIB@ \
- @CURL_LIBS@ \
- @LUA_LIB@
-
-include_HEADERS= $(top_srcdir)/include/lua_ucl.h
-
-ROCKSPEC = $(PACKAGE)-$(VERSION)-1.rockspec
-EXTRA_DIST = $(PACKAGE).rockspec.in \
- test.lua
-DISTCLEANFILES = $(PACKAGE).rockspec
-
-$(ROCKSPEC): $(PACKAGE).rockspec dist
- sed -e 's/@MD5@/'`$(MD5SUM) $(distdir).tar.gz | \
- cut -d " " -f 1`'/g' < $(PACKAGE).rockspec > $@ \ No newline at end of file
diff --git a/contrib/libucl/lua/libucl.rockspec.in b/contrib/libucl/lua/libucl.rockspec.in
deleted file mode 100644
index 52f39176a7bd..000000000000
--- a/contrib/libucl/lua/libucl.rockspec.in
+++ /dev/null
@@ -1,26 +0,0 @@
-package="@PACKAGE@"
-version="@VERSION@-1"
-source = {
- url = "https://github.com/downloads/vstakhov/@PACKAGE@/@PACKAGE@-@VERSION@.tar.gz",
- md5 = "@MD5@",
- dir = "@PACKAGE@-@VERSION@"
-}
-description = {
- summary = "UCL - json like configuration language",
- detailed = [[
- UCL is heavily infused by nginx configuration as the example
- of a convenient configuration system.
- However, UCL is fully compatible with JSON format and is able
- to parse json files.
- ]],
- homepage = "http://github.com/vstakhov/@PACKAGE@/",
- license = ""
-}
-dependencies = {
- "lua >= 5.1"
-}
-build = {
- type = "command",
- build_command = "LUA=$(LUA) CPPFLAGS=-I$(LUA_INCDIR) ./configure --prefix=$(PREFIX) --libdir=$(LIBDIR) --datadir=$(LUADIR) && make clean && make",
- install_command = "make install"
-}
diff --git a/contrib/libucl/lua/lua_ucl.c b/contrib/libucl/lua/lua_ucl.c
index b34fd56878b8..d6be69e42a71 100644
--- a/contrib/libucl/lua/lua_ucl.c
+++ b/contrib/libucl/lua/lua_ucl.c
@@ -82,6 +82,11 @@ static ucl_object_t* ucl_object_lua_fromelt (lua_State *L, int idx, ucl_string_f
static void *ucl_null;
+struct _rspamd_lua_text {
+ const char *start;
+ unsigned int len;
+ unsigned int flags;
+};
enum lua_ucl_push_flags {
LUA_UCL_DEFAULT_FLAGS = 0,
@@ -240,7 +245,7 @@ ucl_object_lua_push_scalar (lua_State *L, const ucl_object_t *obj,
lua_pushboolean (L, ucl_obj_toboolean (obj));
break;
case UCL_STRING:
- lua_pushstring (L, ucl_obj_tostring (obj));
+ lua_pushlstring (L, ucl_obj_tostring (obj), obj->len);
break;
case UCL_INT:
#if LUA_VERSION_NUM >= 501
@@ -401,7 +406,6 @@ ucl_object_lua_fromtable (lua_State *L, int idx, ucl_string_flags_t flags)
/* Table iterate */
if (is_array) {
- int i;
if (!is_implicit) {
top = ucl_object_typed_new (UCL_ARRAY);
@@ -411,7 +415,7 @@ ucl_object_lua_fromtable (lua_State *L, int idx, ucl_string_flags_t flags)
top = NULL;
}
- for (i = 1; i <= max; i ++) {
+ for (size_t i = 1; i <= max; i ++) {
lua_pushinteger (L, i);
lua_gettable (L, idx);
@@ -479,7 +483,16 @@ ucl_object_lua_fromelt (lua_State *L, int idx, ucl_string_flags_t flags)
str = lua_tolstring (L, idx, &sz);
if (str) {
- obj = ucl_object_fromstring_common (str, sz, flags);
+ /*
+ * ucl_object_fromstring_common has a `logic` to use strlen if sz is zero
+ * which is totally broken...
+ */
+ if (sz > 0) {
+ obj = ucl_object_fromstring_common(str, sz, flags);
+ }
+ else {
+ obj = ucl_object_fromstring_common("", sz, flags);
+ }
}
else {
obj = ucl_object_typed_new (UCL_NULL);
@@ -501,6 +514,24 @@ ucl_object_lua_fromelt (lua_State *L, int idx, ucl_string_flags_t flags)
if (lua_topointer (L, idx) == ucl_null) {
obj = ucl_object_typed_new (UCL_NULL);
}
+ else {
+ /* Assume it is a text like object */
+ struct _rspamd_lua_text *t = lua_touserdata (L, idx);
+
+ if (t) {
+ if (t->len >0) {
+ obj = ucl_object_fromstring_common(t->start, t->len, 0);
+ }
+ else {
+ obj = ucl_object_fromstring_common("", 0, 0);
+ }
+
+ /* Binary text */
+ if (t->flags & (1u << 5u)) {
+ obj->flags |= UCL_OBJECT_BINARY;
+ }
+ }
+ }
break;
case LUA_TTABLE:
case LUA_TFUNCTION:
@@ -556,10 +587,10 @@ ucl_object_lua_import (lua_State *L, int idx)
t = lua_type (L, idx);
switch (t) {
case LUA_TTABLE:
- obj = ucl_object_lua_fromtable (L, idx, 0);
+ obj = ucl_object_lua_fromtable (L, idx, UCL_STRING_RAW);
break;
default:
- obj = ucl_object_lua_fromelt (L, idx, 0);
+ obj = ucl_object_lua_fromelt (L, idx, UCL_STRING_RAW);
break;
}
@@ -584,10 +615,10 @@ ucl_object_lua_import_escape (lua_State *L, int idx)
t = lua_type (L, idx);
switch (t) {
case LUA_TTABLE:
- obj = ucl_object_lua_fromtable (L, idx, UCL_STRING_RAW);
+ obj = ucl_object_lua_fromtable (L, idx, UCL_STRING_ESCAPE);
break;
default:
- obj = ucl_object_lua_fromelt (L, idx, UCL_STRING_RAW);
+ obj = ucl_object_lua_fromelt (L, idx, UCL_STRING_ESCAPE);
break;
}
@@ -598,11 +629,12 @@ static int
lua_ucl_to_string (lua_State *L, const ucl_object_t *obj, enum ucl_emitter type)
{
unsigned char *result;
+ size_t outlen;
- result = ucl_object_emit (obj, type);
+ result = ucl_object_emit_len (obj, type, &outlen);
if (result != NULL) {
- lua_pushstring (L, (const char *)result);
+ lua_pushlstring (L, (const char *)result, outlen);
free (result);
}
else {
@@ -625,7 +657,6 @@ lua_ucl_parser_init (lua_State *L)
parser = ucl_parser_new (flags);
if (parser == NULL) {
lua_pushnil (L);
- return 1;
}
pparser = lua_newuserdata (L, sizeof (parser));
@@ -834,12 +865,6 @@ lua_ucl_parser_parse_string (lua_State *L)
return ret;
}
-struct _rspamd_lua_text {
- const char *start;
- unsigned int len;
- unsigned int flags;
-};
-
/***
* @method parser:parse_text(input)
* Parse UCL object from text object (Rspamd specific).
@@ -855,7 +880,24 @@ lua_ucl_parser_parse_text (lua_State *L)
int ret = 2;
parser = lua_ucl_parser_get (L, 1);
- t = lua_touserdata (L, 2);
+
+ if (lua_type (L, 2) == LUA_TUSERDATA) {
+ t = lua_touserdata (L, 2);
+ }
+ else if (lua_type (L, 2) == LUA_TSTRING) {
+ const char *s;
+ size_t len;
+ static struct _rspamd_lua_text st_t;
+
+ s = lua_tolstring (L, 2, &len);
+ st_t.start = s;
+ st_t.len = len;
+
+ t = &st_t;
+ }
+ else {
+ return luaL_error(L, "invalid argument as input, expected userdata or a string");
+ }
if (lua_type (L, 3) == LUA_TSTRING) {
type = lua_ucl_str_to_parse_type (lua_tostring (L, 3));
@@ -1426,10 +1468,11 @@ lua_ucl_to_format (lua_State *L)
format = UCL_EMIT_YAML;
}
else if (strcasecmp (strtype, "config") == 0 ||
- strcasecmp (strtype, "ucl") == 0) {
+ strcasecmp (strtype, "ucl") == 0) {
format = UCL_EMIT_CONFIG;
}
- else if (strcasecmp (strtype, "msgpack") == 0) {
+ else if (strcasecmp (strtype, "msgpack") == 0 ||
+ strcasecmp (strtype, "messagepack") == 0) {
format = UCL_EMIT_MSGPACK;
}
}
diff --git a/contrib/libucl/m4/ax_lua.m4 b/contrib/libucl/m4/ax_lua.m4
deleted file mode 100644
index f8e2fd4c85ce..000000000000
--- a/contrib/libucl/m4/ax_lua.m4
+++ /dev/null
@@ -1,664 +0,0 @@
-# ===========================================================================
-# http://www.gnu.org/software/autoconf-archive/ax_lua.html
-# ===========================================================================
-#
-# SYNOPSIS
-#
-# AX_PROG_LUA[([MINIMUM-VERSION], [TOO-BIG-VERSION], [ACTION-IF-FOUND], [ACTION-IF-NOT-FOUND])]
-# AX_LUA_HEADERS[([ACTION-IF-FOUND], [ACTION-IF-NOT-FOUND])]
-# AX_LUA_LIBS[([ACTION-IF-FOUND], [ACTION-IF-NOT-FOUND])]
-# AX_LUA_READLINE[([ACTION-IF-FOUND], [ACTION-IF-NOT-FOUND])]
-#
-# DESCRIPTION
-#
-# Detect a Lua interpreter, optionally specifying a minimum and maximum
-# version number. Set up important Lua paths, such as the directories in
-# which to install scripts and modules (shared libraries).
-#
-# Also detect Lua headers and libraries. The Lua version contained in the
-# header is checked to match the Lua interpreter version exactly. When
-# searching for Lua libraries, the version number is used as a suffix.
-# This is done with the goal of supporting multiple Lua installs (5.1,
-# 5.2, and 5.3 side-by-side).
-#
-# A note on compatibility with previous versions: This file has been
-# mostly rewritten for serial 18. Most developers should be able to use
-# these macros without needing to modify configure.ac. Care has been taken
-# to preserve each macro's behavior, but there are some differences:
-#
-# 1) AX_WITH_LUA is deprecated; it now expands to the exact same thing as
-# AX_PROG_LUA with no arguments.
-#
-# 2) AX_LUA_HEADERS now checks that the version number defined in lua.h
-# matches the interpreter version. AX_LUA_HEADERS_VERSION is therefore
-# unnecessary, so it is deprecated and does not expand to anything.
-#
-# 3) The configure flag --with-lua-suffix no longer exists; the user
-# should instead specify the LUA precious variable on the command line.
-# See the AX_PROG_LUA description for details.
-#
-# Please read the macro descriptions below for more information.
-#
-# This file was inspired by Andrew Dalke's and James Henstridge's
-# python.m4 and Tom Payne's, Matthieu Moy's, and Reuben Thomas's ax_lua.m4
-# (serial 17). Basically, this file is a mash-up of those two files. I
-# like to think it combines the best of the two!
-#
-# AX_PROG_LUA: Search for the Lua interpreter, and set up important Lua
-# paths. Adds precious variable LUA, which may contain the path of the Lua
-# interpreter. If LUA is blank, the user's path is searched for an
-# suitable interpreter.
-#
-# If MINIMUM-VERSION is supplied, then only Lua interpreters with a
-# version number greater or equal to MINIMUM-VERSION will be accepted. If
-# TOO-BIG-VERSION is also supplied, then only Lua interpreters with a
-# version number greater or equal to MINIMUM-VERSION and less than
-# TOO-BIG-VERSION will be accepted.
-#
-# The Lua version number, LUA_VERSION, is found from the interpreter, and
-# substituted. LUA_PLATFORM is also found, but not currently supported (no
-# standard representation).
-#
-# Finally, the macro finds four paths:
-#
-# luadir Directory to install Lua scripts.
-# pkgluadir $luadir/$PACKAGE
-# luaexecdir Directory to install Lua modules.
-# pkgluaexecdir $luaexecdir/$PACKAGE
-#
-# These paths are found based on $prefix, $exec_prefix, Lua's
-# package.path, and package.cpath. The first path of package.path
-# beginning with $prefix is selected as luadir. The first path of
-# package.cpath beginning with $exec_prefix is used as luaexecdir. This
-# should work on all reasonable Lua installations. If a path cannot be
-# determined, a default path is used. Of course, the user can override
-# these later when invoking make.
-#
-# luadir Default: $prefix/share/lua/$LUA_VERSION
-# luaexecdir Default: $exec_prefix/lib/lua/$LUA_VERSION
-#
-# These directories can be used by Automake as install destinations. The
-# variable name minus 'dir' needs to be used as a prefix to the
-# appropriate Automake primary, e.g. lua_SCRIPS or luaexec_LIBRARIES.
-#
-# If an acceptable Lua interpreter is found, then ACTION-IF-FOUND is
-# performed, otherwise ACTION-IF-NOT-FOUND is preformed. If ACTION-IF-NOT-
-# FOUND is blank, then it will default to printing an error. To prevent
-# the default behavior, give ':' as an action.
-#
-# AX_LUA_HEADERS: Search for Lua headers. Requires that AX_PROG_LUA be
-# expanded before this macro. Adds precious variable LUA_INCLUDE, which
-# may contain Lua specific include flags, e.g. -I/usr/include/lua5.1. If
-# LUA_INCLUDE is blank, then this macro will attempt to find suitable
-# flags.
-#
-# LUA_INCLUDE can be used by Automake to compile Lua modules or
-# executables with embedded interpreters. The *_CPPFLAGS variables should
-# be used for this purpose, e.g. myprog_CPPFLAGS = $(LUA_INCLUDE).
-#
-# This macro searches for the header lua.h (and others). The search is
-# performed with a combination of CPPFLAGS, CPATH, etc, and LUA_INCLUDE.
-# If the search is unsuccessful, then some common directories are tried.
-# If the headers are then found, then LUA_INCLUDE is set accordingly.
-#
-# The paths automatically searched are:
-#
-# * /usr/include/luaX.Y
-# * /usr/include/lua/X.Y
-# * /usr/include/luaXY
-# * /usr/local/include/luaX.Y
-# * /usr/local/include/lua-X.Y
-# * /usr/local/include/lua/X.Y
-# * /usr/local/include/luaXY
-#
-# (Where X.Y is the Lua version number, e.g. 5.1.)
-#
-# The Lua version number found in the headers is always checked to match
-# the Lua interpreter's version number. Lua headers with mismatched
-# version numbers are not accepted.
-#
-# If headers are found, then ACTION-IF-FOUND is performed, otherwise
-# ACTION-IF-NOT-FOUND is performed. If ACTION-IF-NOT-FOUND is blank, then
-# it will default to printing an error. To prevent the default behavior,
-# set the action to ':'.
-#
-# AX_LUA_LIBS: Search for Lua libraries. Requires that AX_PROG_LUA be
-# expanded before this macro. Adds precious variable LUA_LIB, which may
-# contain Lua specific linker flags, e.g. -llua5.1. If LUA_LIB is blank,
-# then this macro will attempt to find suitable flags.
-#
-# LUA_LIB can be used by Automake to link Lua modules or executables with
-# embedded interpreters. The *_LIBADD and *_LDADD variables should be used
-# for this purpose, e.g. mymod_LIBADD = $(LUA_LIB).
-#
-# This macro searches for the Lua library. More technically, it searches
-# for a library containing the function lua_load. The search is performed
-# with a combination of LIBS, LIBRARY_PATH, and LUA_LIB.
-#
-# If the search determines that some linker flags are missing, then those
-# flags will be added to LUA_LIB.
-#
-# If libraries are found, then ACTION-IF-FOUND is performed, otherwise
-# ACTION-IF-NOT-FOUND is performed. If ACTION-IF-NOT-FOUND is blank, then
-# it will default to printing an error. To prevent the default behavior,
-# set the action to ':'.
-#
-# AX_LUA_READLINE: Search for readline headers and libraries. Requires the
-# AX_LIB_READLINE macro, which is provided by ax_lib_readline.m4 from the
-# Autoconf Archive.
-#
-# If a readline compatible library is found, then ACTION-IF-FOUND is
-# performed, otherwise ACTION-IF-NOT-FOUND is performed.
-#
-# LICENSE
-#
-# Copyright (c) 2015 Reuben Thomas <rrt@sc3d.org>
-# Copyright (c) 2014 Tim Perkins <tprk77@gmail.com>
-#
-# 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 3 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, see <http://www.gnu.org/licenses/>.
-#
-# As a special exception, the respective Autoconf Macro's copyright owner
-# gives unlimited permission to copy, distribute and modify the configure
-# scripts that are the output of Autoconf when processing the Macro. You
-# need not follow the terms of the GNU General Public License when using
-# or distributing such scripts, even though portions of the text of the
-# Macro appear in them. The GNU General Public License (GPL) does govern
-# all other use of the material that constitutes the Autoconf Macro.
-#
-# This special exception to the GPL applies to versions of the Autoconf
-# Macro released by the Autoconf Archive. When you make and distribute a
-# modified version of the Autoconf Macro, you may extend this special
-# exception to the GPL to apply to your modified version as well.
-
-#serial 39
-
-dnl =========================================================================
-dnl AX_PROG_LUA([MINIMUM-VERSION], [TOO-BIG-VERSION],
-dnl [ACTION-IF-FOUND], [ACTION-IF-NOT-FOUND])
-dnl =========================================================================
-AC_DEFUN([AX_PROG_LUA],
-[
- dnl Check for required tools.
- AC_REQUIRE([AC_PROG_GREP])
- AC_REQUIRE([AC_PROG_SED])
-
- dnl Make LUA a precious variable.
- AC_ARG_VAR([LUA], [The Lua interpreter, e.g. /usr/bin/lua5.1])
-
- dnl Find a Lua interpreter.
- m4_define_default([_AX_LUA_INTERPRETER_LIST],
- [lua lua5.3 lua53 lua5.2 lua52 lua5.1 lua51 lua50])
-
- m4_if([$1], [],
- [ dnl No version check is needed. Find any Lua interpreter.
- AS_IF([test "x$LUA" = 'x'],
- [AC_PATH_PROGS([LUA], [_AX_LUA_INTERPRETER_LIST], [:])])
- ax_display_LUA='lua'
-
- AS_IF([test "x$LUA" != 'x:'],
- [ dnl At least check if this is a Lua interpreter.
- AC_MSG_CHECKING([if $LUA is a Lua interpreter])
- _AX_LUA_CHK_IS_INTRP([$LUA],
- [AC_MSG_RESULT([yes])],
- [ AC_MSG_RESULT([no])
- AC_MSG_ERROR([not a Lua interpreter])
- ])
- ])
- ],
- [ dnl A version check is needed.
- AS_IF([test "x$LUA" != 'x'],
- [ dnl Check if this is a Lua interpreter.
- AC_MSG_CHECKING([if $LUA is a Lua interpreter])
- _AX_LUA_CHK_IS_INTRP([$LUA],
- [AC_MSG_RESULT([yes])],
- [ AC_MSG_RESULT([no])
- AC_MSG_ERROR([not a Lua interpreter])
- ])
- dnl Check the version.
- m4_if([$2], [],
- [_ax_check_text="whether $LUA version >= $1"],
- [_ax_check_text="whether $LUA version >= $1, < $2"])
- AC_MSG_CHECKING([$_ax_check_text])
- _AX_LUA_CHK_VER([$LUA], [$1], [$2],
- [AC_MSG_RESULT([yes])],
- [ AC_MSG_RESULT([no])
- AC_MSG_ERROR([version is out of range for specified LUA])])
- ax_display_LUA=$LUA
- ],
- [ dnl Try each interpreter until we find one that satisfies VERSION.
- m4_if([$2], [],
- [_ax_check_text="for a Lua interpreter with version >= $1"],
- [_ax_check_text="for a Lua interpreter with version >= $1, < $2"])
- AC_CACHE_CHECK([$_ax_check_text],
- [ax_cv_pathless_LUA],
- [ for ax_cv_pathless_LUA in _AX_LUA_INTERPRETER_LIST none; do
- test "x$ax_cv_pathless_LUA" = 'xnone' && break
- _AX_LUA_CHK_IS_INTRP([$ax_cv_pathless_LUA], [], [continue])
- _AX_LUA_CHK_VER([$ax_cv_pathless_LUA], [$1], [$2], [break])
- done
- ])
- dnl Set $LUA to the absolute path of $ax_cv_pathless_LUA.
- AS_IF([test "x$ax_cv_pathless_LUA" = 'xnone'],
- [LUA=':'],
- [AC_PATH_PROG([LUA], [$ax_cv_pathless_LUA])])
- ax_display_LUA=$ax_cv_pathless_LUA
- ])
- ])
-
- AS_IF([test "x$LUA" = 'x:'],
- [ dnl Run any user-specified action, or abort.
- m4_default([$4], [AC_MSG_ERROR([cannot find suitable Lua interpreter])])
- ],
- [ dnl Query Lua for its version number.
- AC_CACHE_CHECK([for $ax_display_LUA version],
- [ax_cv_lua_version],
- [ dnl Get the interpreter version in X.Y format. This should work for
- dnl interpreters version 5.0 and beyond.
- ax_cv_lua_version=[`$LUA -e '
- -- return a version number in X.Y format
- local _, _, ver = string.find(_VERSION, "^Lua (%d+%.%d+)")
- print(ver)'`]
- ])
- AS_IF([test "x$ax_cv_lua_version" = 'x'],
- [AC_MSG_ERROR([invalid Lua version number])])
- AC_SUBST([LUA_VERSION], [$ax_cv_lua_version])
- AC_SUBST([LUA_SHORT_VERSION], [`echo "$LUA_VERSION" | $SED 's|\.||'`])
-
- dnl The following check is not supported:
- dnl At times (like when building shared libraries) you may want to know
- dnl which OS platform Lua thinks this is.
- AC_CACHE_CHECK([for $ax_display_LUA platform],
- [ax_cv_lua_platform],
- [ax_cv_lua_platform=[`$LUA -e 'print("unknown")'`]])
- AC_SUBST([LUA_PLATFORM], [$ax_cv_lua_platform])
-
- dnl Use the values of $prefix and $exec_prefix for the corresponding
- dnl values of LUA_PREFIX and LUA_EXEC_PREFIX. These are made distinct
- dnl variables so they can be overridden if need be. However, the general
- dnl consensus is that you shouldn't need this ability.
- AC_SUBST([LUA_PREFIX], ['${prefix}'])
- AC_SUBST([LUA_EXEC_PREFIX], ['${exec_prefix}'])
-
- dnl Lua provides no way to query the script directory, and instead
- dnl provides LUA_PATH. However, we should be able to make a safe educated
- dnl guess. If the built-in search path contains a directory which is
- dnl prefixed by $prefix, then we can store scripts there. The first
- dnl matching path will be used.
- AC_CACHE_CHECK([for $ax_display_LUA script directory],
- [ax_cv_lua_luadir],
- [ AS_IF([test "x$prefix" = 'xNONE'],
- [ax_lua_prefix=$ac_default_prefix],
- [ax_lua_prefix=$prefix])
-
- dnl Initialize to the default path.
- ax_cv_lua_luadir="$LUA_PREFIX/share/lua/$LUA_VERSION"
-
- dnl Try to find a path with the prefix.
- _AX_LUA_FND_PRFX_PTH([$LUA], [$ax_lua_prefix], [script])
- AS_IF([test "x$ax_lua_prefixed_path" != 'x'],
- [ dnl Fix the prefix.
- _ax_strip_prefix=`echo "$ax_lua_prefix" | $SED 's|.|.|g'`
- ax_cv_lua_luadir=`echo "$ax_lua_prefixed_path" | \
- $SED "s|^$_ax_strip_prefix|$LUA_PREFIX|"`
- ])
- ])
- AC_SUBST([luadir], [$ax_cv_lua_luadir])
- AC_SUBST([pkgluadir], [\${luadir}/$PACKAGE])
-
- dnl Lua provides no way to query the module directory, and instead
- dnl provides LUA_PATH. However, we should be able to make a safe educated
- dnl guess. If the built-in search path contains a directory which is
- dnl prefixed by $exec_prefix, then we can store modules there. The first
- dnl matching path will be used.
- AC_CACHE_CHECK([for $ax_display_LUA module directory],
- [ax_cv_lua_luaexecdir],
- [ AS_IF([test "x$exec_prefix" = 'xNONE'],
- [ax_lua_exec_prefix=$ax_lua_prefix],
- [ax_lua_exec_prefix=$exec_prefix])
-
- dnl Initialize to the default path.
- ax_cv_lua_luaexecdir="$LUA_EXEC_PREFIX/lib/lua/$LUA_VERSION"
-
- dnl Try to find a path with the prefix.
- _AX_LUA_FND_PRFX_PTH([$LUA],
- [$ax_lua_exec_prefix], [module])
- AS_IF([test "x$ax_lua_prefixed_path" != 'x'],
- [ dnl Fix the prefix.
- _ax_strip_prefix=`echo "$ax_lua_exec_prefix" | $SED 's|.|.|g'`
- ax_cv_lua_luaexecdir=`echo "$ax_lua_prefixed_path" | \
- $SED "s|^$_ax_strip_prefix|$LUA_EXEC_PREFIX|"`
- ])
- ])
- AC_SUBST([luaexecdir], [$ax_cv_lua_luaexecdir])
- AC_SUBST([pkgluaexecdir], [\${luaexecdir}/$PACKAGE])
-
- dnl Run any user specified action.
- $3
- ])
-])
-
-dnl AX_WITH_LUA is now the same thing as AX_PROG_LUA.
-AC_DEFUN([AX_WITH_LUA],
-[
- AC_MSG_WARN([[$0 is deprecated, please use AX_PROG_LUA instead]])
- AX_PROG_LUA
-])
-
-
-dnl =========================================================================
-dnl _AX_LUA_CHK_IS_INTRP(PROG, [ACTION-IF-TRUE], [ACTION-IF-FALSE])
-dnl =========================================================================
-AC_DEFUN([_AX_LUA_CHK_IS_INTRP],
-[
- dnl A minimal Lua factorial to prove this is an interpreter. This should work
- dnl for Lua interpreters version 5.0 and beyond.
- _ax_lua_factorial=[`$1 2>/dev/null -e '
- -- a simple factorial
- function fact (n)
- if n == 0 then
- return 1
- else
- return n * fact(n-1)
- end
- end
- print("fact(5) is " .. fact(5))'`]
- AS_IF([test "$_ax_lua_factorial" = 'fact(5) is 120'],
- [$2], [$3])
-])
-
-
-dnl =========================================================================
-dnl _AX_LUA_CHK_VER(PROG, MINIMUM-VERSION, [TOO-BIG-VERSION],
-dnl [ACTION-IF-TRUE], [ACTION-IF-FALSE])
-dnl =========================================================================
-AC_DEFUN([_AX_LUA_CHK_VER],
-[
- dnl Check that the Lua version is within the bounds. Only the major and minor
- dnl version numbers are considered. This should work for Lua interpreters
- dnl version 5.0 and beyond.
- _ax_lua_good_version=[`$1 -e '
- -- a script to compare versions
- function verstr2num(verstr)
- local _, _, majorver, minorver = string.find(verstr, "^(%d+)%.(%d+)")
- if majorver and minorver then
- return tonumber(majorver) * 100 + tonumber(minorver)
- end
- end
- local minver = verstr2num("$2")
- local _, _, trimver = string.find(_VERSION, "^Lua (.*)")
- local ver = verstr2num(trimver)
- local maxver = verstr2num("$3") or 1e9
- if minver <= ver and ver < maxver then
- print("yes")
- else
- print("no")
- end'`]
- AS_IF([test "x$_ax_lua_good_version" = "xyes"],
- [$4], [$5])
-])
-
-
-dnl =========================================================================
-dnl _AX_LUA_FND_PRFX_PTH(PROG, PREFIX, SCRIPT-OR-MODULE-DIR)
-dnl =========================================================================
-AC_DEFUN([_AX_LUA_FND_PRFX_PTH],
-[
- dnl Get the script or module directory by querying the Lua interpreter,
- dnl filtering on the given prefix, and selecting the shallowest path. If no
- dnl path is found matching the prefix, the result will be an empty string.
- dnl The third argument determines the type of search, it can be 'script' or
- dnl 'module'. Supplying 'script' will perform the search with package.path
- dnl and LUA_PATH, and supplying 'module' will search with package.cpath and
- dnl LUA_CPATH. This is done for compatibility with Lua 5.0.
-
- ax_lua_prefixed_path=[`$1 -e '
- -- get the path based on search type
- local searchtype = "$3"
- local paths = ""
- if searchtype == "script" then
- paths = (package and package.path) or LUA_PATH
- elseif searchtype == "module" then
- paths = (package and package.cpath) or LUA_CPATH
- end
- -- search for the prefix
- local prefix = "'$2'"
- local minpath = ""
- local mindepth = 1e9
- string.gsub(paths, "(@<:@^;@:>@+)",
- function (path)
- path = string.gsub(path, "%?.*$", "")
- path = string.gsub(path, "/@<:@^/@:>@*$", "")
- if string.find(path, prefix) then
- local depth = string.len(string.gsub(path, "@<:@^/@:>@", ""))
- if depth < mindepth then
- minpath = path
- mindepth = depth
- end
- end
- end)
- print(minpath)'`]
-])
-
-
-dnl =========================================================================
-dnl AX_LUA_HEADERS([ACTION-IF-FOUND], [ACTION-IF-NOT-FOUND])
-dnl =========================================================================
-AC_DEFUN([AX_LUA_HEADERS],
-[
- dnl Check for LUA_VERSION.
- AC_MSG_CHECKING([if LUA_VERSION is defined])
- AS_IF([test "x$LUA_VERSION" != 'x'],
- [AC_MSG_RESULT([yes])],
- [ AC_MSG_RESULT([no])
- AC_MSG_ERROR([cannot check Lua headers without knowing LUA_VERSION])
- ])
-
- dnl Make LUA_INCLUDE a precious variable.
- AC_ARG_VAR([LUA_INCLUDE], [The Lua includes, e.g. -I/usr/include/lua5.1])
-
- dnl Some default directories to search.
- LUA_SHORT_VERSION=`echo "$LUA_VERSION" | $SED 's|\.||'`
- m4_define_default([_AX_LUA_INCLUDE_LIST],
- [ /usr/include/lua$LUA_VERSION \
- /usr/include/lua-$LUA_VERSION \
- /usr/include/lua/$LUA_VERSION \
- /usr/include/lua$LUA_SHORT_VERSION \
- /usr/local/include/lua$LUA_VERSION \
- /usr/local/include/lua-$LUA_VERSION \
- /usr/local/include/lua/$LUA_VERSION \
- /usr/local/include/lua$LUA_SHORT_VERSION \
- ])
-
- dnl Try to find the headers.
- _ax_lua_saved_cppflags=$CPPFLAGS
- CPPFLAGS="$CPPFLAGS $LUA_INCLUDE"
- AC_CHECK_HEADERS([lua.h lualib.h lauxlib.h luaconf.h])
- CPPFLAGS=$_ax_lua_saved_cppflags
-
- dnl Try some other directories if LUA_INCLUDE was not set.
- AS_IF([test "x$LUA_INCLUDE" = 'x' &&
- test "x$ac_cv_header_lua_h" != 'xyes'],
- [ dnl Try some common include paths.
- for _ax_include_path in _AX_LUA_INCLUDE_LIST; do
- test ! -d "$_ax_include_path" && continue
-
- AC_MSG_CHECKING([for Lua headers in])
- AC_MSG_RESULT([$_ax_include_path])
-
- AS_UNSET([ac_cv_header_lua_h])
- AS_UNSET([ac_cv_header_lualib_h])
- AS_UNSET([ac_cv_header_lauxlib_h])
- AS_UNSET([ac_cv_header_luaconf_h])
-
- _ax_lua_saved_cppflags=$CPPFLAGS
- CPPFLAGS="$CPPFLAGS -I$_ax_include_path"
- AC_CHECK_HEADERS([lua.h lualib.h lauxlib.h luaconf.h])
- CPPFLAGS=$_ax_lua_saved_cppflags
-
- AS_IF([test "x$ac_cv_header_lua_h" = 'xyes'],
- [ LUA_INCLUDE="-I$_ax_include_path"
- break
- ])
- done
- ])
-
- AS_IF([test "x$ac_cv_header_lua_h" = 'xyes'],
- [ dnl Make a program to print LUA_VERSION defined in the header.
- dnl TODO It would be really nice if we could do this without compiling a
- dnl program, then it would work when cross compiling. But I'm not sure how
- dnl to do this reliably. For now, assume versions match when cross compiling.
-
- AS_IF([test "x$cross_compiling" != 'xyes'],
- [ AC_CACHE_CHECK([for Lua header version],
- [ax_cv_lua_header_version],
- [ _ax_lua_saved_cppflags=$CPPFLAGS
- CPPFLAGS="$CPPFLAGS $LUA_INCLUDE"
- AC_RUN_IFELSE(
- [ AC_LANG_SOURCE([[
-#include <lua.h>
-#include <stdlib.h>
-#include <stdio.h>
-int main(int argc, char ** argv)
-{
- if(argc > 1) printf("%s", LUA_VERSION);
- exit(EXIT_SUCCESS);
-}
-]])
- ],
- [ ax_cv_lua_header_version=`./conftest$EXEEXT p | \
- $SED -n "s|^Lua \(@<:@0-9@:>@\{1,\}\.@<:@0-9@:>@\{1,\}\).\{0,\}|\1|p"`
- ],
- [ax_cv_lua_header_version='unknown'])
- CPPFLAGS=$_ax_lua_saved_cppflags
- ])
-
- dnl Compare this to the previously found LUA_VERSION.
- AC_MSG_CHECKING([if Lua header version matches $LUA_VERSION])
- AS_IF([test "x$ax_cv_lua_header_version" = "x$LUA_VERSION"],
- [ AC_MSG_RESULT([yes])
- ax_header_version_match='yes'
- ],
- [ AC_MSG_RESULT([no])
- ax_header_version_match='no'
- ])
- ],
- [ AC_MSG_WARN([cross compiling so assuming header version number matches])
- ax_header_version_match='yes'
- ])
- ])
-
- dnl Was LUA_INCLUDE specified?
- AS_IF([test "x$ax_header_version_match" != 'xyes' &&
- test "x$LUA_INCLUDE" != 'x'],
- [AC_MSG_ERROR([cannot find headers for specified LUA_INCLUDE])])
-
- dnl Test the final result and run user code.
- AS_IF([test "x$ax_header_version_match" = 'xyes'], [$1],
- [m4_default([$2], [AC_MSG_ERROR([cannot find Lua includes])])])
-])
-
-dnl AX_LUA_HEADERS_VERSION no longer exists, use AX_LUA_HEADERS.
-AC_DEFUN([AX_LUA_HEADERS_VERSION],
-[
- AC_MSG_WARN([[$0 is deprecated, please use AX_LUA_HEADERS instead]])
-])
-
-
-dnl =========================================================================
-dnl AX_LUA_LIBS([ACTION-IF-FOUND], [ACTION-IF-NOT-FOUND])
-dnl =========================================================================
-AC_DEFUN([AX_LUA_LIBS],
-[
- dnl TODO Should this macro also check various -L flags?
-
- dnl Check for LUA_VERSION.
- AC_MSG_CHECKING([if LUA_VERSION is defined])
- AS_IF([test "x$LUA_VERSION" != 'x'],
- [AC_MSG_RESULT([yes])],
- [ AC_MSG_RESULT([no])
- AC_MSG_ERROR([cannot check Lua libs without knowing LUA_VERSION])
- ])
-
- dnl Make LUA_LIB a precious variable.
- AC_ARG_VAR([LUA_LIB], [The Lua library, e.g. -llua5.1])
-
- AS_IF([test "x$LUA_LIB" != 'x'],
- [ dnl Check that LUA_LIBS works.
- _ax_lua_saved_libs=$LIBS
- LIBS="$LUA_LIB $LIBS"
- AC_SEARCH_LIBS([lua_load], [],
- [_ax_found_lua_libs='yes'],
- [_ax_found_lua_libs='no'])
- LIBS=$_ax_lua_saved_libs
-
- dnl Check the result.
- AS_IF([test "x$_ax_found_lua_libs" != 'xyes'],
- [AC_MSG_ERROR([cannot find libs for specified LUA_LIB])])
- ],
- [ dnl First search for extra libs.
- _ax_lua_extra_libs=''
-
- _ax_lua_saved_libs=$LIBS
- LIBS="$LUA_LIB $LIBS"
- AC_SEARCH_LIBS([exp], [m])
- AC_SEARCH_LIBS([dlopen], [dl])
- LIBS=$_ax_lua_saved_libs
-
- AS_IF([test "x$ac_cv_search_exp" != 'xno' &&
- test "x$ac_cv_search_exp" != 'xnone required'],
- [_ax_lua_extra_libs="$_ax_lua_extra_libs $ac_cv_search_exp"])
-
- AS_IF([test "x$ac_cv_search_dlopen" != 'xno' &&
- test "x$ac_cv_search_dlopen" != 'xnone required'],
- [_ax_lua_extra_libs="$_ax_lua_extra_libs $ac_cv_search_dlopen"])
-
- dnl Try to find the Lua libs.
- _ax_lua_saved_libs=$LIBS
- LIBS="$LUA_LIB $LIBS"
- AC_SEARCH_LIBS([lua_load],
- [ lua$LUA_VERSION \
- lua$LUA_SHORT_VERSION \
- lua-$LUA_VERSION \
- lua-$LUA_SHORT_VERSION \
- lua \
- ],
- [_ax_found_lua_libs='yes'],
- [_ax_found_lua_libs='no'],
- [$_ax_lua_extra_libs])
- LIBS=$_ax_lua_saved_libs
-
- AS_IF([test "x$ac_cv_search_lua_load" != 'xno' &&
- test "x$ac_cv_search_lua_load" != 'xnone required'],
- [LUA_LIB="$ac_cv_search_lua_load $_ax_lua_extra_libs"])
- ])
-
- dnl Test the result and run user code.
- AS_IF([test "x$_ax_found_lua_libs" = 'xyes'], [$1],
- [m4_default([$2], [AC_MSG_ERROR([cannot find Lua libs])])])
-])
-
-
-dnl =========================================================================
-dnl AX_LUA_READLINE([ACTION-IF-FOUND], [ACTION-IF-NOT-FOUND])
-dnl =========================================================================
-AC_DEFUN([AX_LUA_READLINE],
-[
- AX_LIB_READLINE
- AS_IF([test "x$ac_cv_header_readline_readline_h" != 'x' &&
- test "x$ac_cv_header_readline_history_h" != 'x'],
- [ LUA_LIBS_CFLAGS="-DLUA_USE_READLINE $LUA_LIBS_CFLAGS"
- $1
- ],
- [$2])
-])
diff --git a/contrib/libucl/m4/gcov.m4 b/contrib/libucl/m4/gcov.m4
deleted file mode 100644
index a1359a0de64b..000000000000
--- a/contrib/libucl/m4/gcov.m4
+++ /dev/null
@@ -1,89 +0,0 @@
-# SYNOPSIS
-#
-# Add code coverage support with gcov/lcov.
-#
-# AX_CODE_COVERAGE()
-#
-# DESCRIPTION
-#
-# Provides a --enable-coverage option which checks for available
-# gcov/lcov binaries and provides ENABLE_CODE_COVERAGE conditional.
-#
-# LAST MODIFICATION
-#
-# $Id: coverage.m4 40881 2013-08-20 17:54:39Z damon $
-#
-# COPYLEFT
-#
-# Copyright (c) 2012 Roy H. Stogner <roystgnr@ices.utexas.edu>
-# Copyright (c) 2010 Karl W. Schulz <karl@ices.utexas.edu>
-#
-# Copying and distribution of this file, with or without modification, are
-# permitted in any medium without royalty provided the copyright notice
-# and this notice are preserved.
-
-AC_DEFUN([AX_CODE_COVERAGE],
-[
-
-AC_ARG_ENABLE(coverage, AC_HELP_STRING([--enable-coverage],[configure code coverage analysis tools]))
-
-HAVE_GCOV_TOOLS=0
-
-GCOV_FLAGS=""
-
-if test "x$enable_coverage" = "xyes"; then
-
- # ----------------------------
- # Check for gcov/lcov binaries
- # ----------------------------
-
- AC_ARG_VAR([GCOV], [Coverage testing command])
- if test "x$GCOV" = "x"; then
- AC_PATH_PROG(GCOV, gcov, no)
- else
- AC_PATH_PROG(GCOV, $GCOV, no)
- fi
-
- AC_PATH_PROG(LCOV, lcov, no)
- AC_PATH_PROG(GENHTML, genhtml)
-
- # ----------------------------------
- # include coverage compiler options
- # ----------------------------------
- AC_MSG_CHECKING([for clang])
-
- AC_COMPILE_IFELSE(
- [AC_LANG_PROGRAM([], [[
- #ifndef __clang__
- not clang
- #endif
- ]])],
- [CLANG=yes], [CLANG=no])
-
- AC_MSG_RESULT([$CLANG])
- HAVE_GCOV_TOOLS=1
- COVERAGE_CFLAGS="-fprofile-arcs -ftest-coverage"
- COVERAGE_LDFLAGS="--coverage -fprofile-arcs -ftest-coverage"
- COVERAGE_OPTFLAGS="-O0"
-
- # Test for C...
- CFLAGS="${GCOV_FLAGS} ${CFLAGS}"
- CXXFLAGS="${GCOV_FLAGS} ${CXXFLAGS}"
- if test "x$GCC" = "xyes" -a "x$CLANG" = "xno"; then
- COVERAGE_LIBS="-lgcov"
- else
- COVERAGE_LIBS=""
- fi
-fi
-
-AC_SUBST([GCOV])
-AC_SUBST([LCOV])
-AC_SUBST([GENHTML])
-AC_SUBST([GENHTML_OPTIONS])
-AC_SUBST([COVERAGE_CFLAGS])
-AC_SUBST([COVERAGE_OPTFLAGS])
-AC_SUBST([COVERAGE_LDFLAGS])
-AC_SUBST([COVERAGE_LIBS])
-AM_CONDITIONAL(CODE_COVERAGE_ENABLED,test x$HAVE_GCOV_TOOLS = x1)
-
-])
diff --git a/contrib/libucl/python/MANIFEST.in b/contrib/libucl/python/MANIFEST.in
deleted file mode 100644
index 336a4b3a7a07..000000000000
--- a/contrib/libucl/python/MANIFEST.in
+++ /dev/null
@@ -1,5 +0,0 @@
-include COPYING
-recursive-include include *.h
-recursive-include src *.h
-recursive-include klib *.h
-recursive-include uthash *.h
diff --git a/contrib/libucl/python/setup.py b/contrib/libucl/python/setup.py
deleted file mode 100644
index 8da832bac381..000000000000
--- a/contrib/libucl/python/setup.py
+++ /dev/null
@@ -1,75 +0,0 @@
-try:
- from setuptools import setup, Extension
- # setuptools doesn't support template param for MANIFEST.in
- from setuptools.command.egg_info import manifest_maker
- manifest_maker.template = 'python/MANIFEST.in'
-except ImportError:
- from distutils.core import setup, Extension
-
-import os
-import sys
-
-LIB_ROOT = os.path.abspath(os.path.join(__file__, os.pardir, os.pardir))
-if os.getcwd() != LIB_ROOT:
- os.chdir(LIB_ROOT)
-if LIB_ROOT not in sys.path:
- sys.path.append(LIB_ROOT)
-
-tests_require = []
-
-if sys.version < '2.7':
- tests_require.append('unittest2')
-
-uclmodule = Extension(
- 'ucl',
- libraries=['ucl', 'curl'],
- sources=['python/src/uclmodule.c'],
- include_dirs=['include'],
- language='c',
-)
-
-ucl_lib = {
- 'sources': ['src/' + fn for fn in os.listdir('src') if fn.endswith('.c')],
- 'include_dirs': ['include', 'src', 'uthash', 'klib'],
- 'macros': [('CURL_FOUND', '1')],
-}
-
-# sdist setup() will pull in the *.c files automatically, but not headers
-# MANIFEST.in will include the headers for sdist only
-template = 'python/MANIFEST.in'
-
-# distutils assume setup.py is in the root of the project
-# we need to include C source from the parent so trick it
-in_ucl_root = 'setup.py' in os.listdir('python')
-if in_ucl_root:
- os.link('python/setup.py', 'setup.py')
-
-setup(
- name = 'ucl',
- version = '0.8.1',
- description = 'ucl parser and emitter',
- ext_modules = [uclmodule],
- template=template, # no longer supported with setuptools but doesn't hurt
- libraries = [('ucl', ucl_lib)],
- test_suite = 'tests',
- tests_require = tests_require,
- author = "Eitan Adler, Denis Volpato Martins",
- author_email = "lists@eitanadler.com",
- url = "https://github.com/vstakhov/libucl/",
- license = "MIT",
- classifiers = [
- "Development Status :: 3 - Alpha",
- "Intended Audience :: Developers",
- "License :: DFSG approved",
- "License :: OSI Approved :: MIT License",
- "Programming Language :: C",
- "Programming Language :: Python :: 2",
- "Programming Language :: Python :: 3",
- "Programming Language :: Python :: Implementation :: CPython",
- "Topic :: Software Development :: Libraries",
- ]
-)
-
-# clean up the trick after the build
-if in_ucl_root:
- os.unlink("setup.py")
diff --git a/contrib/libucl/python/src/uclmodule.c b/contrib/libucl/python/src/uclmodule.c
deleted file mode 100644
index d1051fbb0d12..000000000000
--- a/contrib/libucl/python/src/uclmodule.c
+++ /dev/null
@@ -1,335 +0,0 @@
-// Attempts to load a UCL structure from a string
-#include <ucl.h>
-#include <Python.h>
-
-static PyObject *SchemaError;
-
-static PyObject *
-_basic_ucl_type (ucl_object_t const *obj)
-{
- switch (obj->type) {
- case UCL_INT:
- return Py_BuildValue ("L", (long long)ucl_object_toint (obj));
- case UCL_FLOAT:
- return Py_BuildValue ("d", ucl_object_todouble (obj));
- case UCL_STRING:
- return Py_BuildValue ("s", ucl_object_tostring (obj));
- case UCL_BOOLEAN:
- return PyBool_FromLong (ucl_object_toboolean (obj));
- case UCL_TIME:
- return Py_BuildValue ("d", ucl_object_todouble (obj));
- case UCL_NULL:
- Py_RETURN_NONE;
- }
- return NULL;
-}
-
-static PyObject *
-_iterate_valid_ucl (ucl_object_t const *obj)
-{
- const ucl_object_t *tmp;
- ucl_object_iter_t it = NULL;
-
- tmp = obj;
-
- while ((obj = ucl_object_iterate (tmp, &it, false))) {
- PyObject *val;
-
- val = _basic_ucl_type(obj);
- if (!val) {
- PyObject *key = NULL;
-
- if (obj->key != NULL) {
- key = Py_BuildValue("s", ucl_object_key(obj));
- }
-
- if (obj->type == UCL_OBJECT) {
- const ucl_object_t *cur;
- ucl_object_iter_t it_obj = NULL;
-
- val = PyDict_New();
-
- while ((cur = ucl_object_iterate (obj, &it_obj, true))) {
- PyObject *keyobj = Py_BuildValue("s",ucl_object_key(cur));
- PyDict_SetItem(val, keyobj, _iterate_valid_ucl(cur));
- }
- } else if (obj->type == UCL_ARRAY) {
- const ucl_object_t *cur;
- ucl_object_iter_t it_obj = NULL;
-
- val = PyList_New(0);
-
- while ((cur = ucl_object_iterate (obj, &it_obj, true))) {
- PyList_Append(val, _iterate_valid_ucl(cur));
- }
- } else if (obj->type == UCL_USERDATA) {
- // XXX: this should be
- // PyBytes_FromStringAndSize; where is the
- // length from?
- val = PyBytes_FromString(obj->value.ud);
- }
- }
- return val;
- }
-
- PyErr_SetString(PyExc_SystemError, "unhandled type");
- return NULL;
-}
-
-static PyObject *
-_internal_load_ucl (char *uclstr)
-{
- PyObject *ret;
- struct ucl_parser *parser =
- ucl_parser_new (UCL_PARSER_NO_TIME|UCL_PARSER_NO_IMPLICIT_ARRAYS);
- bool r = ucl_parser_add_string(parser, uclstr, 0);
-
- if (r) {
- if (ucl_parser_get_error (parser)) {
- PyErr_SetString(PyExc_ValueError, ucl_parser_get_error(parser));
- ucl_parser_free(parser);
- ret = NULL;
- goto return_with_parser;
- } else {
- ucl_object_t *uclobj = ucl_parser_get_object(parser);
- ret = _iterate_valid_ucl(uclobj);
- ucl_object_unref(uclobj);
- goto return_with_parser;
- }
- }
- else {
- PyErr_SetString(PyExc_ValueError, ucl_parser_get_error (parser));
- ret = NULL;
- goto return_with_parser;
- }
-
-return_with_parser:
- ucl_parser_free(parser);
- return ret;
-}
-
-static PyObject*
-ucl_load (PyObject *self, PyObject *args)
-{
- char *uclstr;
-
- if (PyArg_ParseTuple(args, "z", &uclstr)) {
- if (!uclstr) {
- Py_RETURN_NONE;
- }
-
- return _internal_load_ucl(uclstr);
- }
-
- return NULL;
-}
-
-static ucl_object_t *
-_iterate_python (PyObject *obj)
-{
- if (obj == Py_None) {
- return ucl_object_new();
- }
- else if (PyBool_Check (obj)) {
- return ucl_object_frombool (obj == Py_True);
- }
-#if PY_MAJOR_VERSION < 3
- else if (PyInt_Check (obj)) {
- return ucl_object_fromint (PyInt_AsLong (obj));
- }
-#endif
- else if (PyLong_Check (obj)) {
- return ucl_object_fromint (PyLong_AsLong (obj));
- }
- else if (PyFloat_Check (obj)) {
- return ucl_object_fromdouble (PyFloat_AsDouble (obj));
- }
- else if (PyUnicode_Check (obj)) {
- ucl_object_t *ucl_str;
- PyObject *str = PyUnicode_AsASCIIString(obj);
- ucl_str = ucl_object_fromstring (PyBytes_AsString (str));
- Py_DECREF(str);
- return ucl_str;
- }
-#if PY_MAJOR_VERSION < 3
- else if (PyString_Check (obj)) {
- return ucl_object_fromstring (PyString_AsString (obj));
- }
-#endif
- else if (PyDict_Check(obj)) {
- PyObject *key, *value;
- Py_ssize_t pos = 0;
- ucl_object_t *top, *elm;
- char *keystr = NULL;
-
- top = ucl_object_typed_new (UCL_OBJECT);
-
- while (PyDict_Next(obj, &pos, &key, &value)) {
- elm = _iterate_python(value);
-
- if (PyUnicode_Check(key)) {
- PyObject *keyascii = PyUnicode_AsASCIIString(key);
- keystr = PyBytes_AsString(keyascii);
- Py_DECREF(keyascii);
- }
-#if PY_MAJOR_VERSION < 3
- else if (PyString_Check(key)) {
- keystr = PyString_AsString(key);
- }
-#endif
- else {
- PyErr_SetString(PyExc_TypeError, "Unknown key type");
- return NULL;
- }
-
- ucl_object_insert_key (top, elm, keystr, 0, true);
- }
-
- return top;
- }
- else if (PySequence_Check(obj)) {
- PyObject *value;
- Py_ssize_t len, pos;
- ucl_object_t *top, *elm;
-
- len = PySequence_Length(obj);
- top = ucl_object_typed_new (UCL_ARRAY);
-
- for (pos = 0; pos < len; pos++) {
- value = PySequence_GetItem(obj, pos);
- elm = _iterate_python(value);
- ucl_array_append(top, elm);
- }
-
- return top;
- }
- else {
- PyErr_SetString(PyExc_TypeError, "Unhandled object type");
- return NULL;
- }
-
- return NULL;
-}
-
-static PyObject *
-ucl_dump (PyObject *self, PyObject *args)
-{
- PyObject *obj;
- ucl_emitter_t emitter;
- ucl_object_t *root = NULL;
-
- emitter = UCL_EMIT_CONFIG;
-
- if (!PyArg_ParseTuple(args, "O|i", &obj, &emitter)) {
- PyErr_SetString(PyExc_TypeError, "Unhandled object type");
- return NULL;
- }
-
- if (emitter >= UCL_EMIT_MAX) {
- PyErr_SetString(PyExc_TypeError, "Invalid emitter type");
- return NULL;
- }
-
- if (obj == Py_None) {
- Py_RETURN_NONE;
- }
-
- root = _iterate_python(obj);
- if (root) {
- PyObject *ret;
- char *buf;
-
- buf = (char *) ucl_object_emit (root, emitter);
- ucl_object_unref (root);
-#if PY_MAJOR_VERSION < 3
- ret = PyString_FromString (buf);
-#else
- ret = PyUnicode_FromString (buf);
-#endif
- free(buf);
-
- return ret;
- }
-
- return NULL;
-}
-
-static PyObject *
-ucl_validate (PyObject *self, PyObject *args)
-{
- PyObject *dataobj, *schemaobj;
- ucl_object_t *data, *schema;
- bool r;
- struct ucl_schema_error err;
-
- if (!PyArg_ParseTuple (args, "OO", &schemaobj, &dataobj)) {
- PyErr_SetString (PyExc_TypeError, "Unhandled object type");
- return NULL;
- }
-
- schema = _iterate_python(schemaobj);
- if (!schema)
- return NULL;
-
- data = _iterate_python(dataobj);
- if (!data)
- return NULL;
-
- // validation
- r = ucl_object_validate (schema, data, &err);
- ucl_object_unref (schema);
- ucl_object_unref (data);
-
- if (!r) {
- PyErr_SetString (SchemaError, err.msg);
- return NULL;
- }
-
- Py_RETURN_TRUE;
-}
-
-static PyMethodDef uclMethods[] = {
- {"load", ucl_load, METH_VARARGS, "Load UCL from stream"},
- {"dump", ucl_dump, METH_VARARGS, "Dump UCL to stream"},
- {"validate", ucl_validate, METH_VARARGS, "Validate ucl stream against schema"},
- {NULL, NULL, 0, NULL}
-};
-
-static void
-init_macros(PyObject *mod)
-{
- PyModule_AddIntMacro(mod, UCL_EMIT_JSON);
- PyModule_AddIntMacro(mod, UCL_EMIT_JSON_COMPACT);
- PyModule_AddIntMacro(mod, UCL_EMIT_CONFIG);
- PyModule_AddIntMacro(mod, UCL_EMIT_YAML);
- PyModule_AddIntMacro(mod, UCL_EMIT_MSGPACK);
-
- SchemaError = PyErr_NewException("ucl.SchemaError", NULL, NULL);
- Py_INCREF(SchemaError);
- PyModule_AddObject(mod, "SchemaError", SchemaError);
-}
-
-#if PY_MAJOR_VERSION >= 3
-static struct PyModuleDef uclmodule = {
- PyModuleDef_HEAD_INIT,
- "ucl",
- NULL,
- -1,
- uclMethods
-};
-
-PyMODINIT_FUNC
-PyInit_ucl (void)
-{
- PyObject *mod = PyModule_Create (&uclmodule);
- init_macros (mod);
-
- return mod;
-}
-#else
-void initucl (void)
-{
- PyObject *mod = Py_InitModule ("ucl", uclMethods);
- init_macros (mod);
-}
-#endif
diff --git a/contrib/libucl/python/tests/__init__.py b/contrib/libucl/python/tests/__init__.py
deleted file mode 100644
index e69de29bb2d1..000000000000
--- a/contrib/libucl/python/tests/__init__.py
+++ /dev/null
diff --git a/contrib/libucl/python/tests/compat.py b/contrib/libucl/python/tests/compat.py
deleted file mode 100644
index 50138262e9b7..000000000000
--- a/contrib/libucl/python/tests/compat.py
+++ /dev/null
@@ -1,8 +0,0 @@
-try:
- import unittest2 as unittest
-except ImportError:
- import unittest
-
-# Python 2.7 - 3.1
-if not hasattr(unittest.TestCase, 'assertRaisesRegex'):
- unittest.TestCase.assertRaisesRegex = unittest.TestCase.assertRaisesRegexp
diff --git a/contrib/libucl/python/tests/test_dump.py b/contrib/libucl/python/tests/test_dump.py
deleted file mode 100644
index 369241468509..000000000000
--- a/contrib/libucl/python/tests/test_dump.py
+++ /dev/null
@@ -1,66 +0,0 @@
-from .compat import unittest
-import ucl
-import sys
-
-class DumpTest(unittest.TestCase):
- def test_no_args(self):
- with self.assertRaises(TypeError):
- ucl.dump()
-
- def test_none(self):
- self.assertEqual(ucl.dump(None), None)
-
- def test_null(self):
- data = { "a" : None }
- valid = "a = null;\n"
- self.assertEqual(ucl.dump(data), valid)
-
- def test_int(self):
- data = { "a" : 1 }
- valid = "a = 1;\n"
- self.assertEqual(ucl.dump(data), valid)
-
- def test_nested_int(self):
- data = { "a" : { "b" : 1 } }
- valid = "a {\n b = 1;\n}\n"
- self.assertEqual(ucl.dump(data), valid)
-
- def test_int_array(self):
- data = { "a" : [1,2,3,4] }
- valid = "a [\n 1,\n 2,\n 3,\n 4,\n]\n"
- self.assertEqual(ucl.dump(data), valid)
-
- def test_str(self):
- data = { "a" : "b" }
- valid = "a = \"b\";\n"
- self.assertEqual(ucl.dump(data), valid)
-
- @unittest.skipIf(sys.version_info[0] > 2, "Python3 uses unicode only")
- def test_unicode(self):
- data = { unicode("a") : unicode("b") }
- valid = unicode("a = \"b\";\n")
- self.assertEqual(ucl.dump(data), valid)
-
- def test_float(self):
- data = { "a" : 1.1 }
- valid = "a = 1.100000;\n"
- self.assertEqual(ucl.dump(data), valid)
-
- def test_boolean(self):
- data = { "a" : True, "b" : False }
- valid = [
- "a = true;\nb = false;\n",
- "b = false;\na = true;\n"
- ]
- self.assertIn(ucl.dump(data), valid)
-
- def test_empty_ucl(self):
- self.assertEqual(ucl.dump({}), "")
-
- def test_json(self):
- data = { "a" : 1, "b": "bleh;" }
- valid = [
- '{\n "a": 1,\n "b": "bleh;"\n}',
- '{\n "b": "bleh;",\n "a": 1\n}'
- ]
- self.assertIn(ucl.dump(data, ucl.UCL_EMIT_JSON), valid)
diff --git a/contrib/libucl/python/tests/test_example.py b/contrib/libucl/python/tests/test_example.py
deleted file mode 100644
index f0785531f4e2..000000000000
--- a/contrib/libucl/python/tests/test_example.py
+++ /dev/null
@@ -1,59 +0,0 @@
-from .compat import unittest
-import json
-import ucl
-
-_ucl_inp = '''
-param = value;
-section {
- param = value;
- param1 = value1;
- flag = true;
- number = 10k;
- time = 0.2s;
- string = "something";
- subsection {
- host = {
- host = "hostname";
- port = 900;
- }
- host = {
- host = "hostname";
- port = 901;
- }
- }
-}
-'''
-
-_json_res = {
- 'param': 'value',
- 'section': {
- 'param': 'value',
- 'param1': 'value1',
- 'flag': True,
- 'number': 10000,
- 'time': '0.2s',
- 'string': 'something',
- 'subsection': {
- 'host': [
- {
- 'host': 'hostname',
- 'port': 900,
- },
- {
- 'host': 'hostname',
- 'port': 901,
- }
- ]
- }
- }
-}
-
-class TestExample(unittest.TestCase):
- def test_example(self):
- # load in sample UCL
- u = ucl.load(_ucl_inp)
-
- # Output and read back the JSON
- uj = json.loads(json.dumps(u))
-
- self.assertEqual(uj, _json_res)
diff --git a/contrib/libucl/python/tests/test_load.py b/contrib/libucl/python/tests/test_load.py
deleted file mode 100644
index 73d43188f3d5..000000000000
--- a/contrib/libucl/python/tests/test_load.py
+++ /dev/null
@@ -1,122 +0,0 @@
-from .compat import unittest
-import ucl
-
-class LoadTest(unittest.TestCase):
- def test_no_args(self):
- with self.assertRaises(TypeError):
- ucl.load()
-
- def test_multi_args(self):
- with self.assertRaises(TypeError):
- ucl.load(0,0)
-
- def test_none(self):
- self.assertEqual(ucl.load(None), None)
-
- def test_null(self):
- data = "a: null"
- valid = { "a" : None }
- self.assertEqual(ucl.load(data), valid)
-
- def test_int(self):
- data = "a : 1"
- valid = { "a" : 1 }
- self.assertEqual(ucl.load(data), valid)
-
- def test_braced_int(self):
- data = "{a : 1}"
- valid = { "a" : 1 }
- self.assertEqual(ucl.load(data), valid)
-
- def test_nested_int(self):
- data = "a : { b : 1 }"
- valid = { "a" : { "b" : 1 } }
- self.assertEqual(ucl.load(data), valid)
-
- def test_str(self):
- data = "a : b"
- valid = { "a" : "b" }
- self.assertEqual(ucl.load(data), valid)
-
- def test_float(self):
- data = "a : 1.1"
- valid = {"a" : 1.1}
- self.assertEqual(ucl.load(data), valid)
-
- def test_boolean(self):
- data = (
- "a : True;" \
- "b : False"
- )
- valid = { "a" : True, "b" : False }
- self.assertEqual(ucl.load(data), valid)
-
- def test_empty_ucl(self):
- self.assertEqual(ucl.load("{}"), {})
-
- def test_single_brace(self):
- self.assertEqual(ucl.load("{"), {})
-
- def test_single_back_brace(self):
- self.assertEqual(ucl.load("}"), {})
-
- def test_single_square_forward(self):
- self.assertEqual(ucl.load("["), [])
-
- def test_invalid_ucl(self):
- with self.assertRaisesRegex(ValueError, "unfinished key$"):
- ucl.load('{ "var"')
-
- def test_comment_ignored(self):
- self.assertEqual(ucl.load("{/*1*/}"), {})
-
- def test_1_in(self):
- valid = {
- 'key1': [
- 'value',
- 'value2',
- 'value;',
- 1.0,
- -0xdeadbeef,
- '0xdeadbeef.1',
- '0xreadbeef',
- -1e-10,
- 1,
- True,
- False,
- True,
- ]
- }
- with open("../tests/basic/1.in", "r") as in1:
- self.assertEqual(ucl.load(in1.read()), valid)
-
- def test_every_type(self):
- data = ("""{
- "key1": value;
- "key2": value2;
- "key3": "value;"
- "key4": 1.0,
- "key5": -0xdeadbeef
- "key6": 0xdeadbeef.1
- "key7": 0xreadbeef
- "key8": -1e-10,
- "key9": 1
- "key10": true
- "key11": no
- "key12": yes
- }""")
- valid = {
- 'key1': 'value',
- 'key2': 'value2',
- 'key3': 'value;',
- 'key4': 1.0,
- 'key5': -3735928559,
- 'key6': '0xdeadbeef.1',
- 'key7': '0xreadbeef',
- 'key8': -1e-10,
- 'key9': 1,
- 'key10': True,
- 'key11': False,
- 'key12': True,
- }
- self.assertEqual(ucl.load(data), valid)
diff --git a/contrib/libucl/python/tests/test_validation.py b/contrib/libucl/python/tests/test_validation.py
deleted file mode 100644
index f7c853ad69a7..000000000000
--- a/contrib/libucl/python/tests/test_validation.py
+++ /dev/null
@@ -1,50 +0,0 @@
-from .compat import unittest
-import ucl
-import json
-import os.path
-import glob
-import re
-
-TESTS_SCHEMA_FOLDER = '../tests/schema/*.json'
-
-comment_re = re.compile('\/\*((?!\*\/).)*?\*\/', re.DOTALL | re.MULTILINE)
-def json_remove_comments(content):
- return comment_re.sub('', content)
-
-class ValidationTest(unittest.TestCase):
- def validate(self, jsonfile):
- def perform_test(schema, data, valid, description):
- msg = '%s (valid=%r)' % (description, valid)
- if valid:
- self.assertTrue(ucl.validate(schema, data), msg)
- else:
- with self.assertRaises(ucl.SchemaError):
- ucl.validate(schema, data)
- self.fail(msg) # fail() will be called only if SchemaError is not raised
-
- with open(jsonfile) as f:
- try:
- # data = json.load(f)
- data = json.loads(json_remove_comments(f.read()))
- except ValueError as e:
- raise self.skipTest('Failed to load JSON: %s' % str(e))
-
- for testgroup in data:
- for test in testgroup['tests']:
- perform_test(testgroup['schema'], test['data'],
- test['valid'], test['description'])
-
- @classmethod
- def setupValidationTests(cls):
- """Creates each test dynamically from a folder"""
- def test_gen(filename):
- def run_test(self):
- self.validate(filename)
- return run_test
-
- for jsonfile in glob.glob(TESTS_SCHEMA_FOLDER):
- testname = os.path.splitext(os.path.basename(jsonfile))[0]
- setattr(cls, 'test_%s' % testname, test_gen(jsonfile))
-
-
-ValidationTest.setupValidationTests()
diff --git a/contrib/libucl/python/ucl.pyi b/contrib/libucl/python/ucl.pyi
deleted file mode 100644
index 79fa2901ba9f..000000000000
--- a/contrib/libucl/python/ucl.pyi
+++ /dev/null
@@ -1,15 +0,0 @@
-# Stubs for ucl (Python 3.6)
-#
-# NOTE: This dynamically typed stub was automatically generated by stubgen.
-
-UCL_EMIT_CONFIG = ... # type: int
-UCL_EMIT_JSON = ... # type: int
-UCL_EMIT_JSON_COMPACT = ... # type: int
-UCL_EMIT_MSGPACK = ... # type: int
-UCL_EMIT_YAML = ... # type: int
-
-def dump(*args, **kwargs): ...
-def load(*args, **kwargs): ...
-def validate(*args, **kwargs): ...
-
-class SchemaError(Exception): ...
diff --git a/contrib/libucl/src/Makefile.am b/contrib/libucl/src/Makefile.am
deleted file mode 100644
index 80ce5b185b83..000000000000
--- a/contrib/libucl/src/Makefile.am
+++ /dev/null
@@ -1,30 +0,0 @@
-libucl_common_cflags= -I$(top_srcdir)/src \
- -I$(top_srcdir)/include \
- -I$(top_srcdir)/uthash \
- -I$(top_srcdir)/klib \
- -Wall -W -Wno-unused-parameter -Wno-pointer-sign
-lib_LTLIBRARIES= libucl.la
-libucl_la_SOURCES= ucl_emitter.c \
- ucl_emitter_streamline.c \
- ucl_emitter_utils.c \
- ucl_hash.c \
- ucl_parser.c \
- ucl_schema.c \
- ucl_util.c \
- ucl_msgpack.c \
- ucl_sexp.c
-libucl_la_CFLAGS= $(libucl_common_cflags) \
- @CURL_CFLAGS@
-libucl_la_LDFLAGS = -version-info @SO_VERSION@
-libucl_la_LIBADD= @LIBFETCH_LIBS@ \
- @LIBCRYPTO_LIB@ \
- @LIBREGEX_LIB@ \
- @CURL_LIBS@
-
-include_HEADERS= $(top_srcdir)/include/ucl.h \
- $(top_srcdir)/include/ucl++.h
-noinst_HEADERS= ucl_internal.h \
- mum.h \
- ucl_hash.h \
- ucl_chartable.h \
- tree.h
diff --git a/contrib/libucl/src/mum.h b/contrib/libucl/src/mum.h
index 148161a3ec58..318efea50268 100644
--- a/contrib/libucl/src/mum.h
+++ b/contrib/libucl/src/mum.h
@@ -69,11 +69,9 @@ typedef unsigned __int64 uint64_t;
#endif
#endif
-#if 0
#if defined(__GNUC__) && ((__GNUC__ == 4) && (__GNUC_MINOR__ >= 9) || (__GNUC__ > 4))
#define _MUM_FRESH_GCC
#endif
-#endif
#if defined(__GNUC__) && !defined(__llvm__) && defined(_MUM_FRESH_GCC)
#define _MUM_ATTRIBUTE_UNUSED __attribute__((unused))
diff --git a/contrib/libucl/src/ucl_emitter.c b/contrib/libucl/src/ucl_emitter.c
index 4f4465dfbf4a..97d8f618021f 100644
--- a/contrib/libucl/src/ucl_emitter.c
+++ b/contrib/libucl/src/ucl_emitter.c
@@ -47,9 +47,9 @@ static void ucl_emitter_common_elt (struct ucl_emitter_context *ctx,
static void ucl_emit_ ## type ## _elt (struct ucl_emitter_context *ctx, \
const ucl_object_t *obj, bool first, bool print_key); \
static void ucl_emit_ ## type ## _start_obj (struct ucl_emitter_context *ctx, \
- const ucl_object_t *obj, bool print_key); \
+ const ucl_object_t *obj, bool first, bool print_key); \
static void ucl_emit_ ## type## _start_array (struct ucl_emitter_context *ctx, \
- const ucl_object_t *obj, bool print_key); \
+ const ucl_object_t *obj, bool first, bool print_key); \
static void ucl_emit_ ##type## _end_object (struct ucl_emitter_context *ctx, \
const ucl_object_t *obj); \
static void ucl_emit_ ##type## _end_array (struct ucl_emitter_context *ctx, \
@@ -248,12 +248,26 @@ ucl_emitter_common_end_array (struct ucl_emitter_context *ctx,
*/
static void
ucl_emitter_common_start_array (struct ucl_emitter_context *ctx,
- const ucl_object_t *obj, bool print_key, bool compact)
+ const ucl_object_t *obj, bool first, bool print_key, bool compact)
{
const ucl_object_t *cur;
ucl_object_iter_t iter = NULL;
const struct ucl_emitter_functions *func = ctx->func;
- bool first = true;
+ bool first_key = true;
+
+ if (ctx->id != UCL_EMIT_CONFIG && !first) {
+ if (compact) {
+ func->ucl_emitter_append_character (',', 1, func->ud);
+ }
+ else {
+ if (ctx->id == UCL_EMIT_YAML && ctx->indent == 0) {
+ func->ucl_emitter_append_len ("\n", 1, func->ud);
+ } else {
+ func->ucl_emitter_append_len (",\n", 2, func->ud);
+ }
+ }
+ ucl_add_tabs (func, ctx->indent, compact);
+ }
ucl_emitter_print_key (print_key, ctx, obj, compact);
@@ -269,16 +283,16 @@ ucl_emitter_common_start_array (struct ucl_emitter_context *ctx,
if (obj->type == UCL_ARRAY) {
/* explicit array */
while ((cur = ucl_object_iterate (obj, &iter, true)) != NULL) {
- ucl_emitter_common_elt (ctx, cur, first, false, compact);
- first = false;
+ ucl_emitter_common_elt (ctx, cur, first_key, false, compact);
+ first_key = false;
}
}
else {
/* implicit array */
cur = obj;
while (cur) {
- ucl_emitter_common_elt (ctx, cur, first, false, compact);
- first = false;
+ ucl_emitter_common_elt (ctx, cur, first_key, false, compact);
+ first_key = false;
cur = cur->next;
}
}
@@ -294,12 +308,26 @@ ucl_emitter_common_start_array (struct ucl_emitter_context *ctx,
*/
static void
ucl_emitter_common_start_object (struct ucl_emitter_context *ctx,
- const ucl_object_t *obj, bool print_key, bool compact)
+ const ucl_object_t *obj, bool first, bool print_key, bool compact)
{
ucl_hash_iter_t it = NULL;
const ucl_object_t *cur, *elt;
const struct ucl_emitter_functions *func = ctx->func;
- bool first = true;
+ bool first_key = true;
+
+ if (ctx->id != UCL_EMIT_CONFIG && !first) {
+ if (compact) {
+ func->ucl_emitter_append_character (',', 1, func->ud);
+ }
+ else {
+ if (ctx->id == UCL_EMIT_YAML && ctx->indent == 0) {
+ func->ucl_emitter_append_len ("\n", 1, func->ud);
+ } else {
+ func->ucl_emitter_append_len (",\n", 2, func->ud);
+ }
+ }
+ ucl_add_tabs (func, ctx->indent, compact);
+ }
ucl_emitter_print_key (print_key, ctx, obj, compact);
/*
@@ -320,13 +348,13 @@ ucl_emitter_common_start_object (struct ucl_emitter_context *ctx,
if (ctx->id == UCL_EMIT_CONFIG) {
LL_FOREACH (cur, elt) {
- ucl_emitter_common_elt (ctx, elt, first, true, compact);
+ ucl_emitter_common_elt (ctx, elt, first_key, true, compact);
}
}
else {
/* Expand implicit arrays */
if (cur->next != NULL) {
- if (!first) {
+ if (!first_key) {
if (compact) {
func->ucl_emitter_append_character (',', 1, func->ud);
}
@@ -335,15 +363,15 @@ ucl_emitter_common_start_object (struct ucl_emitter_context *ctx,
}
}
ucl_add_tabs (func, ctx->indent, compact);
- ucl_emitter_common_start_array (ctx, cur, true, compact);
+ ucl_emitter_common_start_array (ctx, cur, first_key, true, compact);
ucl_emitter_common_end_array (ctx, cur, compact);
}
else {
- ucl_emitter_common_elt (ctx, cur, first, true, compact);
+ ucl_emitter_common_elt (ctx, cur, first_key, true, compact);
}
}
- first = false;
+ first_key = false;
}
}
@@ -446,11 +474,11 @@ ucl_emitter_common_elt (struct ucl_emitter_context *ctx,
ucl_emitter_finish_object (ctx, obj, compact, !print_key);
break;
case UCL_OBJECT:
- ucl_emitter_common_start_object (ctx, obj, print_key, compact);
+ ucl_emitter_common_start_object (ctx, obj, true, print_key, compact);
ucl_emitter_common_end_object (ctx, obj, compact);
break;
case UCL_ARRAY:
- ucl_emitter_common_start_array (ctx, obj, print_key, compact);
+ ucl_emitter_common_start_array (ctx, obj, true, print_key, compact);
ucl_emitter_common_end_array (ctx, obj, compact);
break;
case UCL_USERDATA:
@@ -490,12 +518,12 @@ ucl_emitter_common_elt (struct ucl_emitter_context *ctx,
ucl_emitter_common_elt (ctx, obj, first, print_key, (compact)); \
} \
static void ucl_emit_ ## type ## _start_obj (struct ucl_emitter_context *ctx, \
- const ucl_object_t *obj, bool print_key) { \
- ucl_emitter_common_start_object (ctx, obj, print_key, (compact)); \
+ const ucl_object_t *obj, bool first, bool print_key) { \
+ ucl_emitter_common_start_object (ctx, obj, first, print_key, (compact)); \
} \
static void ucl_emit_ ## type## _start_array (struct ucl_emitter_context *ctx, \
- const ucl_object_t *obj, bool print_key) { \
- ucl_emitter_common_start_array (ctx, obj, print_key, (compact)); \
+ const ucl_object_t *obj, bool first, bool print_key) { \
+ ucl_emitter_common_start_array (ctx, obj, first, print_key, (compact)); \
} \
static void ucl_emit_ ##type## _end_object (struct ucl_emitter_context *ctx, \
const ucl_object_t *obj) { \
@@ -513,7 +541,7 @@ UCL_EMIT_TYPE_IMPL(yaml, false)
static void
ucl_emit_msgpack_elt (struct ucl_emitter_context *ctx,
- const ucl_object_t *obj, bool first, bool print_key)
+ const ucl_object_t *obj, bool _first, bool print_key)
{
ucl_object_iter_t it;
struct ucl_object_userdata *ud;
@@ -556,7 +584,7 @@ ucl_emit_msgpack_elt (struct ucl_emitter_context *ctx,
case UCL_OBJECT:
ucl_emitter_print_key_msgpack (print_key, ctx, obj);
- ucl_emit_msgpack_start_obj (ctx, obj, print_key);
+ ucl_emit_msgpack_start_obj (ctx, obj, false, print_key);
it = NULL;
while ((cur = ucl_object_iterate (obj, &it, true)) != NULL) {
@@ -575,7 +603,7 @@ ucl_emit_msgpack_elt (struct ucl_emitter_context *ctx,
case UCL_ARRAY:
ucl_emitter_print_key_msgpack (print_key, ctx, obj);
- ucl_emit_msgpack_start_array (ctx, obj, print_key);
+ ucl_emit_msgpack_start_array (ctx, obj, false, print_key);
it = NULL;
while ((cur = ucl_object_iterate (obj, &it, true)) != NULL) {
@@ -601,14 +629,14 @@ ucl_emit_msgpack_elt (struct ucl_emitter_context *ctx,
static void
ucl_emit_msgpack_start_obj (struct ucl_emitter_context *ctx,
- const ucl_object_t *obj, bool print_key)
+ const ucl_object_t *obj, bool _first, bool _print_key)
{
ucl_emitter_print_object_msgpack (ctx, obj->len);
}
static void
ucl_emit_msgpack_start_array (struct ucl_emitter_context *ctx,
- const ucl_object_t *obj, bool print_key)
+ const ucl_object_t *obj, bool _first, bool _print_key)
{
ucl_emitter_print_array_msgpack (ctx, obj->len);
}
diff --git a/contrib/libucl/src/ucl_emitter_streamline.c b/contrib/libucl/src/ucl_emitter_streamline.c
index a7178c5d74b0..8ca86fa081c9 100644
--- a/contrib/libucl/src/ucl_emitter_streamline.c
+++ b/contrib/libucl/src/ucl_emitter_streamline.c
@@ -103,18 +103,19 @@ ucl_object_emit_streamline_start_container (struct ucl_emitter_context *ctx,
top = sctx->containers;
st = malloc (sizeof (*st));
if (st != NULL) {
- if (top != NULL && !top->is_array) {
+ st->empty = true;
+ if (top && !top->is_array) {
print_key = true;
}
- st->empty = true;
+
st->obj = obj;
if (obj != NULL && obj->type == UCL_ARRAY) {
st->is_array = true;
- sctx->ops->ucl_emitter_start_array (ctx, obj, print_key);
+ sctx->ops->ucl_emitter_start_array (ctx, obj, top == NULL, print_key);
}
else {
st->is_array = false;
- sctx->ops->ucl_emitter_start_object (ctx, obj, print_key);
+ sctx->ops->ucl_emitter_start_object (ctx, obj, top == NULL, print_key);
}
LL_PREPEND (sctx->containers, st);
}
diff --git a/contrib/libucl/src/ucl_hash.c b/contrib/libucl/src/ucl_hash.c
index a74dfcdee68e..0208cfd29c9a 100644
--- a/contrib/libucl/src/ucl_hash.c
+++ b/contrib/libucl/src/ucl_hash.c
@@ -32,12 +32,12 @@
struct ucl_hash_elt {
const ucl_object_t *obj;
- size_t ar_idx;
+ struct ucl_hash_elt *prev, *next;
};
struct ucl_hash_struct {
void *hash;
- kvec_t(const ucl_object_t *) ar;
+ struct ucl_hash_elt *head;
bool caseless;
};
@@ -45,7 +45,6 @@ static uint64_t
ucl_hash_seed (void)
{
static uint64_t seed;
-
if (seed == 0) {
#ifdef UCL_RANDOM_FUNCTION
seed = UCL_RANDOM_FUNCTION;
@@ -115,7 +114,7 @@ ucl_hash_equal (const ucl_object_t *k1, const ucl_object_t *k2)
return 0;
}
-KHASH_INIT (ucl_hash_node, const ucl_object_t *, struct ucl_hash_elt, 1,
+KHASH_INIT (ucl_hash_node, const ucl_object_t *, struct ucl_hash_elt *, 1,
ucl_hash_func, ucl_hash_equal)
static inline uint32_t
@@ -227,7 +226,7 @@ ucl_hash_caseless_equal (const ucl_object_t *k1, const ucl_object_t *k2)
return 0;
}
-KHASH_INIT (ucl_hash_caseless_node, const ucl_object_t *, struct ucl_hash_elt, 1,
+KHASH_INIT (ucl_hash_caseless_node, const ucl_object_t *, struct ucl_hash_elt *, 1,
ucl_hash_caseless_func, ucl_hash_caseless_equal)
ucl_hash_t*
@@ -238,8 +237,7 @@ ucl_hash_create (bool ignore_case)
new = UCL_ALLOC (sizeof (ucl_hash_t));
if (new != NULL) {
void *h;
- kv_init (new->ar);
-
+ new->head = NULL;
new->caseless = ignore_case;
if (ignore_case) {
h = (void *)kh_init (ucl_hash_caseless_node);
@@ -258,7 +256,6 @@ ucl_hash_create (bool ignore_case)
void ucl_hash_destroy (ucl_hash_t* hashlin, ucl_hash_free_func func)
{
- const ucl_object_t *cur, *tmp;
if (hashlin == NULL) {
return;
@@ -269,10 +266,11 @@ void ucl_hash_destroy (ucl_hash_t* hashlin, ucl_hash_free_func func)
khash_t(ucl_hash_node) *h = (khash_t(ucl_hash_node) *)
hashlin->hash;
khiter_t k;
+ const ucl_object_t *cur, *tmp;
for (k = kh_begin (h); k != kh_end (h); ++k) {
if (kh_exist (h, k)) {
- cur = (kh_value (h, k)).obj;
+ cur = (kh_value (h, k))->obj;
while (cur != NULL) {
tmp = cur->next;
func (__DECONST (ucl_object_t *, cur));
@@ -293,7 +291,12 @@ void ucl_hash_destroy (ucl_hash_t* hashlin, ucl_hash_free_func func)
kh_destroy (ucl_hash_node, h);
}
- kv_destroy (hashlin->ar);
+ struct ucl_hash_elt *cur, *tmp;
+
+ DL_FOREACH_SAFE(hashlin->head, cur, tmp) {
+ UCL_FREE(sizeof(*cur), cur);
+ }
+
UCL_FREE (sizeof (*hashlin), hashlin);
}
@@ -303,7 +306,7 @@ ucl_hash_insert (ucl_hash_t* hashlin, const ucl_object_t *obj,
{
khiter_t k;
int ret;
- struct ucl_hash_elt *elt;
+ struct ucl_hash_elt **pelt, *elt;
if (hashlin == NULL) {
return false;
@@ -314,10 +317,14 @@ ucl_hash_insert (ucl_hash_t* hashlin, const ucl_object_t *obj,
hashlin->hash;
k = kh_put (ucl_hash_caseless_node, h, obj, &ret);
if (ret > 0) {
- elt = &kh_value (h, k);
- kv_push_safe (const ucl_object_t *, hashlin->ar, obj, e0);
+ elt = UCL_ALLOC(sizeof(*elt));
+ pelt = &kh_value (h, k);
+ *pelt = elt;
+ DL_APPEND(hashlin->head, elt);
elt->obj = obj;
- elt->ar_idx = kv_size (hashlin->ar) - 1;
+ }
+ else if (ret < 0) {
+ goto e0;
}
}
else {
@@ -325,10 +332,11 @@ ucl_hash_insert (ucl_hash_t* hashlin, const ucl_object_t *obj,
hashlin->hash;
k = kh_put (ucl_hash_node, h, obj, &ret);
if (ret > 0) {
- elt = &kh_value (h, k);
- kv_push_safe (const ucl_object_t *, hashlin->ar, obj, e0);
+ elt = UCL_ALLOC(sizeof(*elt));
+ pelt = &kh_value (h, k);
+ *pelt = elt;
+ DL_APPEND(hashlin->head, elt);
elt->obj = obj;
- elt->ar_idx = kv_size (hashlin->ar) - 1;
} else if (ret < 0) {
goto e0;
}
@@ -343,7 +351,7 @@ void ucl_hash_replace (ucl_hash_t* hashlin, const ucl_object_t *old,
{
khiter_t k;
int ret;
- struct ucl_hash_elt elt, *pelt;
+ struct ucl_hash_elt *elt, *nelt;
if (hashlin == NULL) {
return;
@@ -354,13 +362,14 @@ void ucl_hash_replace (ucl_hash_t* hashlin, const ucl_object_t *old,
hashlin->hash;
k = kh_put (ucl_hash_caseless_node, h, old, &ret);
if (ret == 0) {
- elt = kh_value (h, k);
+ elt = kh_value(h, k);
kh_del (ucl_hash_caseless_node, h, k);
k = kh_put (ucl_hash_caseless_node, h, new, &ret);
- pelt = &kh_value (h, k);
- pelt->obj = new;
- pelt->ar_idx = elt.ar_idx;
- kv_A (hashlin->ar, elt.ar_idx) = new;
+ nelt = UCL_ALLOC(sizeof(*nelt));
+ nelt->obj = new;
+ kh_value(h, k) = nelt;
+ DL_REPLACE_ELEM(hashlin->head, elt, nelt);
+ UCL_FREE(sizeof(*elt), elt);
}
}
else {
@@ -371,17 +380,17 @@ void ucl_hash_replace (ucl_hash_t* hashlin, const ucl_object_t *old,
elt = kh_value (h, k);
kh_del (ucl_hash_node, h, k);
k = kh_put (ucl_hash_node, h, new, &ret);
- pelt = &kh_value (h, k);
- pelt->obj = new;
- pelt->ar_idx = elt.ar_idx;
- kv_A (hashlin->ar, elt.ar_idx) = new;
+ nelt = UCL_ALLOC(sizeof(*nelt));
+ nelt->obj = new;
+ kh_value(h, k) = nelt;
+ DL_REPLACE_ELEM(hashlin->head, elt, nelt);
+ UCL_FREE(sizeof(*elt), elt);
}
}
}
struct ucl_hash_real_iter {
- const ucl_object_t **cur;
- const ucl_object_t **end;
+ const struct ucl_hash_elt *cur;
};
#define UHI_SETERR(ep, ern) {if (ep != NULL) *ep = (ern);}
@@ -405,13 +414,13 @@ ucl_hash_iterate2 (ucl_hash_t *hashlin, ucl_hash_iter_t *iter, int *ep)
return NULL;
}
- it->cur = &hashlin->ar.a[0];
- it->end = it->cur + hashlin->ar.n;
+ it->cur = hashlin->head;
}
UHI_SETERR(ep, 0);
- if (it->cur < it->end) {
- ret = *it->cur++;
+ if (it->cur) {
+ ret = it->cur->obj;
+ it->cur = it->cur->next;
}
else {
UCL_FREE (sizeof (*it), it);
@@ -429,7 +438,7 @@ ucl_hash_iter_has_next (ucl_hash_t *hashlin, ucl_hash_iter_t iter)
{
struct ucl_hash_real_iter *it = (struct ucl_hash_real_iter *)(iter);
- return it->cur < it->end - 1;
+ return it->cur != NULL;
}
@@ -454,7 +463,7 @@ ucl_hash_search (ucl_hash_t* hashlin, const char *key, unsigned keylen)
k = kh_get (ucl_hash_caseless_node, h, &search);
if (k != kh_end (h)) {
- elt = &kh_value (h, k);
+ elt = kh_value (h, k);
ret = elt->obj;
}
}
@@ -463,7 +472,7 @@ ucl_hash_search (ucl_hash_t* hashlin, const char *key, unsigned keylen)
hashlin->hash;
k = kh_get (ucl_hash_node, h, &search);
if (k != kh_end (h)) {
- elt = &kh_value (h, k);
+ elt = kh_value (h, k);
ret = elt->obj;
}
}
@@ -476,7 +485,6 @@ ucl_hash_delete (ucl_hash_t* hashlin, const ucl_object_t *obj)
{
khiter_t k;
struct ucl_hash_elt *elt;
- size_t i;
if (hashlin == NULL) {
return;
@@ -488,16 +496,10 @@ ucl_hash_delete (ucl_hash_t* hashlin, const ucl_object_t *obj)
k = kh_get (ucl_hash_caseless_node, h, obj);
if (k != kh_end (h)) {
- elt = &kh_value (h, k);
- i = elt->ar_idx;
- kv_del (const ucl_object_t *, hashlin->ar, elt->ar_idx);
+ elt = kh_value (h, k);
+ DL_DELETE(hashlin->head, elt);
kh_del (ucl_hash_caseless_node, h, k);
-
- /* Update subsequent elts */
- for (; i < hashlin->ar.n; i ++) {
- elt = &kh_value (h, i);
- elt->ar_idx --;
- }
+ UCL_FREE(sizeof(*elt), elt);
}
}
else {
@@ -505,16 +507,10 @@ ucl_hash_delete (ucl_hash_t* hashlin, const ucl_object_t *obj)
hashlin->hash;
k = kh_get (ucl_hash_node, h, obj);
if (k != kh_end (h)) {
- elt = &kh_value (h, k);
- i = elt->ar_idx;
- kv_del (const ucl_object_t *, hashlin->ar, elt->ar_idx);
+ elt = kh_value (h, k);
+ DL_DELETE(hashlin->head, elt);
kh_del (ucl_hash_node, h, k);
-
- /* Update subsequent elts */
- for (; i < hashlin->ar.n; i ++) {
- elt = &kh_value (h, i);
- elt->ar_idx --;
- }
+ UCL_FREE(sizeof(*elt), elt);
}
}
}
@@ -525,9 +521,7 @@ bool ucl_hash_reserve (ucl_hash_t *hashlin, size_t sz)
return false;
}
- if (sz > hashlin->ar.m) {
- kv_resize_safe (const ucl_object_t *, hashlin->ar, sz, e0);
-
+ if (sz > kh_size((khash_t(ucl_hash_node) *)hashlin->hash)) {
if (hashlin->caseless) {
khash_t(ucl_hash_caseless_node) *h = (khash_t(
ucl_hash_caseless_node) *)
@@ -540,8 +534,6 @@ bool ucl_hash_reserve (ucl_hash_t *hashlin, size_t sz)
}
}
return true;
-e0:
- return false;
}
static int
@@ -591,27 +583,27 @@ ucl_lc_cmp (const char *s, const char *d, size_t l)
static int
ucl_hash_cmp_icase (const void *a, const void *b)
{
- const ucl_object_t *oa = *(const ucl_object_t **)a,
- *ob = *(const ucl_object_t **)b;
+ const struct ucl_hash_elt *oa = (const struct ucl_hash_elt *)a,
+ *ob = (const struct ucl_hash_elt *)b;
- if (oa->keylen == ob->keylen) {
- return ucl_lc_cmp (oa->key, ob->key, oa->keylen);
+ if (oa->obj->keylen == ob->obj->keylen) {
+ return ucl_lc_cmp (oa->obj->key, ob->obj->key, oa->obj->keylen);
}
- return ((int)(oa->keylen)) - ob->keylen;
+ return ((int)(oa->obj->keylen)) - ob->obj->keylen;
}
static int
ucl_hash_cmp_case_sens (const void *a, const void *b)
{
- const ucl_object_t *oa = *(const ucl_object_t **)a,
- *ob = *(const ucl_object_t **)b;
+ const struct ucl_hash_elt *oa = (const struct ucl_hash_elt *)a,
+ *ob = (const struct ucl_hash_elt *)b;
- if (oa->keylen == ob->keylen) {
- return memcmp (oa->key, ob->key, oa->keylen);
+ if (oa->obj->keylen == ob->obj->keylen) {
+ return memcmp (oa->obj->key, ob->obj->key, oa->obj->keylen);
}
- return ((int)(oa->keylen)) - ob->keylen;
+ return ((int)(oa->obj->keylen)) - ob->obj->keylen;
}
void
@@ -619,18 +611,18 @@ ucl_hash_sort (ucl_hash_t *hashlin, enum ucl_object_keys_sort_flags fl)
{
if (fl & UCL_SORT_KEYS_ICASE) {
- qsort (hashlin->ar.a, hashlin->ar.n, sizeof (ucl_object_t *),
- ucl_hash_cmp_icase);
+ DL_SORT(hashlin->head, ucl_hash_cmp_icase);
}
else {
- qsort (hashlin->ar.a, hashlin->ar.n, sizeof (ucl_object_t *),
- ucl_hash_cmp_case_sens);
+ DL_SORT(hashlin->head, ucl_hash_cmp_case_sens);
}
if (fl & UCL_SORT_KEYS_RECURSIVE) {
- for (size_t i = 0; i < hashlin->ar.n; i ++) {
- if (ucl_object_type (hashlin->ar.a[i]) == UCL_OBJECT) {
- ucl_hash_sort (hashlin->ar.a[i]->value.ov, fl);
+ struct ucl_hash_elt *elt;
+
+ DL_FOREACH(hashlin->head, elt) {
+ if (ucl_object_type (elt->obj) == UCL_OBJECT) {
+ ucl_hash_sort (elt->obj->value.ov, fl);
}
}
}
diff --git a/contrib/libucl/src/ucl_msgpack.c b/contrib/libucl/src/ucl_msgpack.c
index 08e690a4728a..628ed2be993d 100644
--- a/contrib/libucl/src/ucl_msgpack.c
+++ b/contrib/libucl/src/ucl_msgpack.c
@@ -1246,8 +1246,8 @@ ucl_msgpack_consume (struct ucl_parser *parser)
/* Empty container at the end */
if (len != 0) {
ucl_create_err (&parser->err,
- "invalid non-empty container at the end; len=%zu",
- (size_t)len);
+ "invalid non-empty container at the end; len=%ju",
+ (uintmax_t)len);
return false;
}
diff --git a/contrib/libucl/src/ucl_parser.c b/contrib/libucl/src/ucl_parser.c
index 23f5bce3056f..6be16d12169c 100644
--- a/contrib/libucl/src/ucl_parser.c
+++ b/contrib/libucl/src/ucl_parser.c
@@ -47,6 +47,9 @@ struct ucl_parser_saved_state {
*/
#define ucl_chunk_skipc(chunk, p) \
do { \
+ if (p == chunk->end) { \
+ break; \
+ } \
if (*(p) == '\n') { \
(chunk)->line ++; \
(chunk)->column = 0; \
@@ -176,7 +179,7 @@ start:
if (!quoted) {
if (*p == '*') {
ucl_chunk_skipc (chunk, p);
- if (*p == '/') {
+ if (chunk->remain > 0 && *p == '/') {
comments_nested --;
if (comments_nested == 0) {
if (parser->flags & UCL_PARSER_SAVE_COMMENTS) {
@@ -345,8 +348,9 @@ ucl_check_variable_safe (struct ucl_parser *parser, const char *ptr, size_t rema
/* Call generic handler */
if (parser->var_handler (ptr, remain, &dst, &dstlen, &need_free,
parser->var_data)) {
- *out_len = dstlen;
*found = true;
+ *out_len = dstlen;
+
if (need_free) {
free (dst);
}
@@ -395,6 +399,9 @@ ucl_check_variable (struct ucl_parser *parser, const char *ptr,
}
p ++;
}
+ if(p == end) {
+ (*out_len) ++;
+ }
}
else if (*ptr != '$') {
/* Not count escaped dollar sign */
@@ -418,13 +425,14 @@ ucl_check_variable (struct ucl_parser *parser, const char *ptr,
* Expand a single variable
* @param parser
* @param ptr
- * @param remain
+ * @param in_len
* @param dest
+ * @param out_len
* @return
*/
static const char *
ucl_expand_single_variable (struct ucl_parser *parser, const char *ptr,
- size_t remain, unsigned char **dest)
+ size_t in_len, unsigned char **dest, size_t out_len)
{
unsigned char *d = *dest, *dst;
const char *p = ptr + 1, *ret;
@@ -435,7 +443,8 @@ ucl_expand_single_variable (struct ucl_parser *parser, const char *ptr,
bool strict = false;
ret = ptr + 1;
- remain --;
+ /* For the $ sign */
+ in_len --;
if (*p == '$') {
*d++ = *p++;
@@ -444,39 +453,53 @@ ucl_expand_single_variable (struct ucl_parser *parser, const char *ptr,
}
else if (*p == '{') {
p ++;
+ in_len --;
strict = true;
ret += 2;
- remain -= 2;
}
LL_FOREACH (parser->variables, var) {
- if (remain >= var->var_len) {
+ if (out_len >= var->value_len && in_len >= (var->var_len + (strict ? 1 : 0))) {
if (memcmp (p, var->var, var->var_len) == 0) {
- memcpy (d, var->value, var->value_len);
- ret += var->var_len;
- d += var->value_len;
- found = true;
- break;
+ if (!strict || p[var->var_len] == '}') {
+ memcpy (d, var->value, var->value_len);
+ ret += var->var_len;
+ d += var->value_len;
+ found = true;
+ break;
+ }
}
}
}
+
if (!found) {
if (strict && parser->var_handler != NULL) {
- if (parser->var_handler (p, remain, &dst, &dstlen, &need_free,
+ dstlen = out_len;
+
+ if (parser->var_handler (p, in_len, &dst, &dstlen, &need_free,
parser->var_data)) {
- memcpy (d, dst, dstlen);
- ret += remain;
- d += dstlen;
- found = true;
- if (need_free) {
- free (dst);
+ if (dstlen > out_len) {
+ /* We do not have enough space! */
+ if (need_free) {
+ free (dst);
+ }
+ }
+ else {
+ memcpy(d, dst, dstlen);
+ ret += in_len;
+ d += dstlen;
+ found = true;
+
+ if (need_free) {
+ free(dst);
+ }
}
}
}
- /* Leave variable as is */
+ /* Leave variable as is, in this case we use dest */
if (!found) {
- if (strict) {
+ if (strict && out_len >= 2) {
/* Copy '${' */
memcpy (d, ptr, 2);
d += 2;
@@ -506,7 +529,7 @@ ucl_expand_variable (struct ucl_parser *parser, unsigned char **dst,
const char *src, size_t in_len)
{
const char *p, *end = src + in_len;
- unsigned char *d;
+ unsigned char *d, *d_end;
size_t out_len = 0;
bool vars_found = false;
@@ -517,7 +540,7 @@ ucl_expand_variable (struct ucl_parser *parser, unsigned char **dst,
p = src;
while (p != end) {
- if (*p == '$') {
+ if (*p == '$' && p + 1 != end) {
p = ucl_check_variable (parser, p + 1, end - p - 1, &out_len, &vars_found);
}
else {
@@ -538,10 +561,11 @@ ucl_expand_variable (struct ucl_parser *parser, unsigned char **dst,
}
d = *dst;
+ d_end = d + out_len;
p = src;
- while (p != end) {
- if (*p == '$') {
- p = ucl_expand_single_variable (parser, p, end - p, &d);
+ while (p != end && d != d_end) {
+ if (*p == '$' && p + 1 != end) {
+ p = ucl_expand_single_variable (parser, p, end - p, &d, d_end - d);
}
else {
*d++ = *p++;
@@ -686,6 +710,8 @@ ucl_parser_add_container (ucl_object_t *obj, struct ucl_parser *parser,
ucl_object_unref (obj);
}
+ UCL_FREE(sizeof (struct ucl_stack), st);
+
return NULL;
}
@@ -722,13 +748,13 @@ ucl_maybe_parse_number (ucl_object_t *obj,
const char *p = start, *c = start;
char *endptr;
bool got_dot = false, got_exp = false, need_double = false,
- is_time = false, valid_start = false, is_hex = false,
- is_neg = false;
+ is_time = false, valid_start = false, is_hex = false;
+ int is_neg = 0;
double dv = 0;
int64_t lv = 0;
if (*p == '-') {
- is_neg = true;
+ is_neg = 1;
c ++;
p ++;
}
@@ -744,6 +770,7 @@ ucl_maybe_parse_number (ucl_object_t *obj,
is_hex = true;
allow_double = false;
c = p + 1;
+ p ++;
}
else if (allow_double) {
if (p == c) {
@@ -792,26 +819,46 @@ ucl_maybe_parse_number (ucl_object_t *obj,
break;
}
}
+ else if (!allow_double && *p == '.') {
+ /* Unexpected dot */
+ *pos = start;
+ return EINVAL;
+ }
else {
break;
}
}
- if (!valid_start) {
+ if (!valid_start || p == c) {
+ *pos = start;
+ return EINVAL;
+ }
+
+ char numbuf[128];
+
+ if ((size_t)(p - c + 1) >= sizeof(numbuf)) {
*pos = start;
return EINVAL;
}
+ if (is_neg) {
+ numbuf[0] = '-';
+ ucl_strlcpy (&numbuf[1], c, p - c + 1);
+ }
+ else {
+ ucl_strlcpy (numbuf, c, p - c + 1);
+ }
+
errno = 0;
if (need_double) {
- dv = strtod (c, &endptr);
+ dv = strtod (numbuf, &endptr);
}
else {
if (is_hex) {
- lv = strtoimax (c, &endptr, 16);
+ lv = strtoimax (numbuf, &endptr, 16);
}
else {
- lv = strtoimax (c, &endptr, 10);
+ lv = strtoimax (numbuf, &endptr, 10);
}
}
if (errno == ERANGE) {
@@ -819,7 +866,15 @@ ucl_maybe_parse_number (ucl_object_t *obj,
return ERANGE;
}
- /* Now check endptr */
+ /* Now check endptr and move it from numbuf to the real ending */
+ if (endptr != NULL) {
+ long shift = endptr - numbuf - is_neg;
+ endptr = (char *)c + shift;
+ }
+ if (endptr >= end) {
+ p = end;
+ goto set_obj;
+ }
if (endptr == NULL || ucl_lex_is_atom_end (*endptr) || *endptr == '\0') {
p = endptr;
goto set_obj;
@@ -849,6 +904,10 @@ ucl_maybe_parse_number (ucl_object_t *obj,
dv *= ucl_lex_num_multiplier (*p, false);
}
p += 2;
+ if (end - p > 0 && !ucl_lex_is_atom_end (*p)) {
+ *pos = start;
+ return EINVAL;
+ }
goto set_obj;
}
else if (number_bytes || (p[1] == 'b' || p[1] == 'B')) {
@@ -859,6 +918,10 @@ ucl_maybe_parse_number (ucl_object_t *obj,
}
lv *= ucl_lex_num_multiplier (*p, true);
p += 2;
+ if (end - p > 0 && !ucl_lex_is_atom_end (*p)) {
+ *pos = start;
+ return EINVAL;
+ }
goto set_obj;
}
else if (ucl_lex_is_atom_end (p[1])) {
@@ -883,6 +946,10 @@ ucl_maybe_parse_number (ucl_object_t *obj,
is_time = true;
dv *= 60.;
p += 3;
+ if (end - p > 0 && !ucl_lex_is_atom_end (*p)) {
+ *pos = start;
+ return EINVAL;
+ }
goto set_obj;
}
}
@@ -895,6 +962,10 @@ ucl_maybe_parse_number (ucl_object_t *obj,
lv *= ucl_lex_num_multiplier (*p, number_bytes);
}
p ++;
+ if (end - p > 0 && !ucl_lex_is_atom_end (*p)) {
+ *pos = start;
+ return EINVAL;
+ }
goto set_obj;
}
break;
@@ -943,7 +1014,7 @@ ucl_maybe_parse_number (ucl_object_t *obj,
}
else if (endptr == end) {
/* Just a number at the end of chunk */
- p = endptr;
+ p = end;
goto set_obj;
}
@@ -959,11 +1030,11 @@ set_obj:
else {
obj->type = UCL_TIME;
}
- obj->value.dv = is_neg ? (-dv) : dv;
+ obj->value.dv = dv;
}
else {
obj->type = UCL_INT;
- obj->value.iv = is_neg ? (-lv) : lv;
+ obj->value.iv = lv;
}
}
*pos = p;
@@ -1037,13 +1108,13 @@ ucl_lex_json_string (struct ucl_parser *parser,
}
else if (c == '\\') {
ucl_chunk_skipc (chunk, p);
- c = *p;
if (p >= chunk->end) {
ucl_set_err (parser, UCL_ESYNTAX, "unfinished escape character",
&parser->err);
return false;
}
- else if (ucl_test_character (c, UCL_CHARACTER_ESCAPE)) {
+ c = *p;
+ if (ucl_test_character (c, UCL_CHARACTER_ESCAPE)) {
if (c == 'u') {
ucl_chunk_skipc (chunk, p);
for (i = 0; i < 4 && p < chunk->end; i ++) {
@@ -1289,24 +1360,20 @@ ucl_parser_process_object_element (struct ucl_parser *parser, ucl_object_t *nobj
*/
static bool
ucl_parse_key (struct ucl_parser *parser, struct ucl_chunk *chunk,
- bool *next_key, bool *end_of_object)
+ bool *next_key, bool *end_of_object, bool *got_content)
{
const unsigned char *p, *c = NULL, *end, *t;
const char *key = NULL;
bool got_quote = false, got_eq = false, got_semicolon = false,
need_unescape = false, ucl_escape = false, var_expand = false,
- got_content = false, got_sep = false;
+ got_sep = false;
ucl_object_t *nobj;
ssize_t keylen;
p = chunk->pos;
- if (*p == '.') {
- /* It is macro actually */
- if (!(parser->flags & UCL_PARSER_DISABLE_MACRO)) {
- ucl_chunk_skipc (chunk, p);
- }
-
+ if (*p == '.' && !(parser->flags & UCL_PARSER_DISABLE_MACRO)) {
+ ucl_chunk_skipc (chunk, p);
parser->prev_state = parser->state;
parser->state = UCL_STATE_MACRO_NAME;
*end_of_object = false;
@@ -1330,13 +1397,13 @@ ucl_parse_key (struct ucl_parser *parser, struct ucl_chunk *chunk,
/* The first symbol */
c = p;
ucl_chunk_skipc (chunk, p);
- got_content = true;
+ *got_content = true;
}
else if (*p == '"') {
/* JSON style key */
c = p + 1;
got_quote = true;
- got_content = true;
+ *got_content = true;
ucl_chunk_skipc (chunk, p);
}
else if (*p == '}') {
@@ -1344,7 +1411,7 @@ ucl_parse_key (struct ucl_parser *parser, struct ucl_chunk *chunk,
*end_of_object = true;
return true;
}
- else if (*p == '.') {
+ else if (*p == '.' && !(parser->flags & UCL_PARSER_DISABLE_MACRO)) {
ucl_chunk_skipc (chunk, p);
parser->prev_state = parser->state;
parser->state = UCL_STATE_MACRO_NAME;
@@ -1361,7 +1428,7 @@ ucl_parse_key (struct ucl_parser *parser, struct ucl_chunk *chunk,
/* Parse the body of a key */
if (!got_quote) {
if (ucl_test_character (*p, UCL_CHARACTER_KEY)) {
- got_content = true;
+ *got_content = true;
ucl_chunk_skipc (chunk, p);
}
else if (ucl_test_character (*p, UCL_CHARACTER_KEY_SEP)) {
@@ -1387,11 +1454,11 @@ ucl_parse_key (struct ucl_parser *parser, struct ucl_chunk *chunk,
}
}
- if (p >= chunk->end && got_content) {
+ if (p >= chunk->end && *got_content) {
ucl_set_err (parser, UCL_ESYNTAX, "unfinished key", &parser->err);
return false;
}
- else if (!got_content) {
+ else if (!*got_content) {
return true;
}
*end_of_object = false;
@@ -1752,6 +1819,9 @@ ucl_parse_value (struct ucl_parser *parser, struct ucl_chunk *chunk)
case '{':
obj = ucl_parser_get_container (parser);
if (obj == NULL) {
+ parser->state = UCL_STATE_ERROR;
+ ucl_set_err(parser, UCL_ESYNTAX, "object value must be a part of an object",
+ &parser->err);
return false;
}
/* We have a new object */
@@ -1773,6 +1843,9 @@ ucl_parse_value (struct ucl_parser *parser, struct ucl_chunk *chunk)
case '[':
obj = ucl_parser_get_container (parser);
if (obj == NULL) {
+ parser->state = UCL_STATE_ERROR;
+ ucl_set_err(parser, UCL_ESYNTAX, "array value must be a part of an object",
+ &parser->err);
return false;
}
/* We have a new array */
@@ -1804,6 +1877,12 @@ ucl_parse_value (struct ucl_parser *parser, struct ucl_chunk *chunk)
break;
case '<':
obj = ucl_parser_get_container (parser);
+ if (obj == NULL) {
+ parser->state = UCL_STATE_ERROR;
+ ucl_set_err(parser, UCL_ESYNTAX, "multiline value must be a part of an object",
+ &parser->err);
+ return false;
+ }
/* We have something like multiline value, which must be <<[A-Z]+\n */
if (chunk->end - p > 3) {
if (memcmp (p, "<<", 2) == 0) {
@@ -1812,6 +1891,11 @@ ucl_parse_value (struct ucl_parser *parser, struct ucl_chunk *chunk)
while (p < chunk->end && *p >= 'A' && *p <= 'Z') {
p ++;
}
+ if(p == chunk->end) {
+ ucl_set_err (parser, UCL_ESYNTAX,
+ "unterminated multiline value", &parser->err);
+ return false;
+ }
if (*p =='\n') {
/* Set chunk positions and start multiline parsing */
chunk->remain -= p - c + 1;
@@ -1850,6 +1934,13 @@ parse_string:
obj = ucl_parser_get_container (parser);
}
+ if (obj == NULL) {
+ parser->state = UCL_STATE_ERROR;
+ ucl_set_err(parser, UCL_ESYNTAX, "value must be a part of an object",
+ &parser->err);
+ return false;
+ }
+
/* Parse atom */
if (ucl_test_character (*p, UCL_CHARACTER_VALUE_DIGIT_START)) {
if (!ucl_lex_number (parser, chunk, obj)) {
@@ -2339,7 +2430,7 @@ ucl_state_machine (struct ucl_parser *parser)
unsigned char *macro_escaped;
size_t macro_len = 0;
struct ucl_macro *macro = NULL;
- bool next_key = false, end_of_object = false, ret;
+ bool next_key = false, end_of_object = false, got_content = false, ret;
if (parser->top_obj == NULL) {
parser->state = UCL_STATE_INIT;
@@ -2428,7 +2519,10 @@ ucl_state_machine (struct ucl_parser *parser)
parser->state = UCL_STATE_ERROR;
return false;
}
- if (!ucl_parse_key (parser, chunk, &next_key, &end_of_object)) {
+
+ got_content = false;
+
+ if (!ucl_parse_key (parser, chunk, &next_key, &end_of_object, &got_content)) {
parser->prev_state = parser->state;
parser->state = UCL_STATE_ERROR;
return false;
@@ -2451,7 +2545,8 @@ ucl_state_machine (struct ucl_parser *parser)
return false;
}
}
- else {
+ else if (got_content) {
+ /* Do not switch state if we have not read any content */
parser->state = UCL_STATE_VALUE;
}
}
@@ -2617,6 +2712,9 @@ ucl_state_machine (struct ucl_parser *parser)
return false;
}
break;
+ case UCL_STATE_ERROR:
+ /* Already in the error state */
+ return false;
default:
ucl_set_err (parser, UCL_EINTERNAL,
"internal error: parser is in an unknown state", &parser->err);
@@ -2889,7 +2987,9 @@ ucl_parser_add_chunk_full (struct ucl_parser *parser, const unsigned char *data,
if (!special_handler->handler (parser, data, len, &ndata, &nlen,
special_handler->user_data)) {
+ UCL_FREE(sizeof (struct ucl_chunk), chunk);
ucl_create_err (&parser->err, "call for external handler failed");
+
return false;
}
@@ -2909,7 +3009,7 @@ ucl_parser_add_chunk_full (struct ucl_parser *parser, const unsigned char *data,
if (parse_type == UCL_PARSE_AUTO && len > 0) {
/* We need to detect parse type by the first symbol */
- if ((*data & 0x80) == 0x80 && (*data >= 0xdc && *data <= 0xdf)) {
+ if ((*data & 0x80) == 0x80) {
parse_type = UCL_PARSE_MSGPACK;
}
else if (*data == '(') {
diff --git a/contrib/libucl/src/ucl_schema.c b/contrib/libucl/src/ucl_schema.c
index 68f01187e375..f4ec0ed3284a 100644
--- a/contrib/libucl/src/ucl_schema.c
+++ b/contrib/libucl/src/ucl_schema.c
@@ -39,6 +39,7 @@
#ifdef HAVE_MATH_H
#include <math.h>
#endif
+#include <inttypes.h>
static bool ucl_schema_validate (const ucl_object_t *schema,
const ucl_object_t *obj, bool try_array,
diff --git a/contrib/libucl/src/ucl_util.c b/contrib/libucl/src/ucl_util.c
index b00a34787e5a..8f97c20db503 100644
--- a/contrib/libucl/src/ucl_util.c
+++ b/contrib/libucl/src/ucl_util.c
@@ -67,7 +67,7 @@ typedef kvec_t(ucl_object_t *) ucl_array_t;
#include <fetch.h>
#endif
-#if defined(_MSC_VER)
+#if defined(_WIN32)
#include <windows.h>
#include <io.h>
#include <direct.h>
@@ -889,44 +889,49 @@ ucl_fetch_file (const unsigned char *filename, unsigned char **buf, size_t *bufl
{
int fd;
struct stat st;
+ if ((fd = open (filename, O_RDONLY)) == -1) {
+ ucl_create_err (err, "cannot open file %s: %s",
+ filename, strerror (errno));
+ return false;
+ }
- if (stat (filename, &st) == -1) {
+ if (fstat (fd, &st) == -1) {
if (must_exist || errno == EPERM) {
ucl_create_err (err, "cannot stat file %s: %s",
filename, strerror (errno));
}
+ close (fd);
+
return false;
}
if (!S_ISREG (st.st_mode)) {
if (must_exist) {
ucl_create_err (err, "file %s is not a regular file", filename);
}
+ close (fd);
return false;
}
+
if (st.st_size == 0) {
/* Do not map empty files */
*buf = NULL;
*buflen = 0;
}
else {
- if ((fd = open (filename, O_RDONLY)) == -1) {
- ucl_create_err (err, "cannot open file %s: %s",
- filename, strerror (errno));
- return false;
- }
- if ((*buf = ucl_mmap (NULL, st.st_size, PROT_READ, MAP_SHARED, fd, 0)) == MAP_FAILED) {
- close (fd);
- ucl_create_err (err, "cannot mmap file %s: %s",
- filename, strerror (errno));
+ if ((*buf = ucl_mmap(NULL, st.st_size, PROT_READ, MAP_SHARED, fd, 0)) == MAP_FAILED) {
+ close(fd);
+ ucl_create_err(err, "cannot mmap file %s: %s",
+ filename, strerror(errno));
*buf = NULL;
return false;
}
*buflen = st.st_size;
- close (fd);
}
+ close (fd);
+
return true;
}
@@ -1017,6 +1022,9 @@ ucl_include_url (const unsigned char *data, size_t len,
snprintf (urlbuf, sizeof (urlbuf), "%.*s", (int)len, data);
if (!ucl_fetch_url (urlbuf, &buf, &buflen, &parser->err, params->must_exist)) {
+ if (!params->must_exist) {
+ ucl_parser_clear_error (parser);
+ }
return !params->must_exist;
}
@@ -1092,6 +1100,11 @@ ucl_include_file_single (const unsigned char *data, size_t len,
ucl_hash_t *container = NULL;
struct ucl_stack *st = NULL;
+ if (parser->state == UCL_STATE_ERROR) {
+ /* Return immediately if we are in the error state... */
+ return false;
+ }
+
snprintf (filebuf, sizeof (filebuf), "%.*s", (int)len, data);
if (ucl_realpath (filebuf, realbuf) == NULL) {
if (params->soft_fail) {
@@ -1128,6 +1141,8 @@ ucl_include_file_single (const unsigned char *data, size_t len,
return false;
}
+ ucl_parser_clear_error (parser);
+
return true;
}
@@ -1138,6 +1153,10 @@ ucl_include_file_single (const unsigned char *data, size_t len,
/* We need to check signature first */
snprintf (filebuf, sizeof (filebuf), "%s.sig", realbuf);
if (!ucl_fetch_file (filebuf, &sigbuf, &siglen, &parser->err, true)) {
+ if (buf) {
+ ucl_munmap (buf, buflen);
+ }
+
return false;
}
if (!ucl_sig_check (buf, buflen, sigbuf, siglen, parser)) {
@@ -1147,8 +1166,13 @@ ucl_include_file_single (const unsigned char *data, size_t len,
if (sigbuf) {
ucl_munmap (sigbuf, siglen);
}
+ if (buf) {
+ ucl_munmap (buf, buflen);
+ }
+
return false;
}
+
if (sigbuf) {
ucl_munmap (sigbuf, siglen);
}
@@ -1257,6 +1281,8 @@ ucl_include_file_single (const unsigned char *data, size_t len,
ucl_munmap (buf, buflen);
}
+ ucl_object_unref (new_obj);
+
return false;
}
nest_obj->prev = nest_obj;
@@ -1576,11 +1602,6 @@ ucl_include_common (const unsigned char *data, size_t len,
else if (param->type == UCL_INT) {
if (strncmp (param->key, "priority", param->keylen) == 0) {
params.priority = ucl_object_toint (param);
- if (params.priority > UCL_PRIORITY_MAX) {
- ucl_create_err (&parser->err, "Invalid priority value in macro: %d",
- params.priority);
- return false;
- }
}
}
}
@@ -1719,9 +1740,8 @@ ucl_priority_handler (const unsigned char *data, size_t len,
if (len > 0) {
value = malloc(len + 1);
ucl_strlcpy(value, (const char *)data, len + 1);
- errno = 0;
- priority = strtoul(value, &leftover, 10);
- if (errno != 0 || *leftover != '\0' || priority > UCL_PRIORITY_MAX) {
+ priority = strtol(value, &leftover, 10);
+ if (*leftover != '\0') {
ucl_create_err (&parser->err, "Invalid priority value in macro: %s",
value);
free(value);
@@ -1842,6 +1862,10 @@ ucl_load_handler (const unsigned char *data, size_t len,
!try_load)) {
free (load_file);
+ if (try_load) {
+ ucl_parser_clear_error (parser);
+ }
+
return (try_load || false);
}
@@ -1919,7 +1943,7 @@ ucl_inherit_handler (const unsigned char *data, size_t len,
/* Some sanity checks */
if (parent == NULL || ucl_object_type (parent) != UCL_OBJECT) {
- ucl_create_err (&parser->err, "Unable to find inherited object %*.s",
+ ucl_create_err (&parser->err, "Unable to find inherited object %.*s",
(int)len, data);
return false;
}
@@ -2177,7 +2201,7 @@ ucl_strnstr (const char *s, const char *find, int len)
mlen = strlen (find);
do {
do {
- if ((sc = *s++) == 0 || len-- == 0)
+ if ((sc = *s++) == 0 || len-- < mlen)
return (NULL);
} while (sc != c);
} while (strncmp (s, find, mlen) != 0);
@@ -2596,6 +2620,7 @@ ucl_object_merge (ucl_object_t *top, ucl_object_t *elt, bool copy)
if (!ucl_object_merge (found, cp, copy)) {
return false;
}
+ ucl_object_unref (cp);
}
else {
ucl_hash_replace (top->value.ov, found, cp);
@@ -2627,6 +2652,7 @@ ucl_object_merge (ucl_object_t *top, ucl_object_t *elt, bool copy)
if (!ucl_object_merge (found, cp, copy)) {
return false;
}
+ ucl_object_unref (cp);
}
else {
ucl_hash_replace (top->value.ov, found, cp);
@@ -3068,13 +3094,13 @@ ucl_object_type (const ucl_object_t *obj)
ucl_object_t*
ucl_object_fromstring (const char *str)
{
- return ucl_object_fromstring_common (str, 0, UCL_STRING_ESCAPE);
+ return ucl_object_fromstring_common (str, 0, UCL_STRING_RAW);
}
ucl_object_t *
ucl_object_fromlstring (const char *str, size_t len)
{
- return ucl_object_fromstring_common (str, len, UCL_STRING_ESCAPE);
+ return ucl_object_fromstring_common (str, len, UCL_STRING_RAW);
}
ucl_object_t *
@@ -3594,9 +3620,11 @@ ucl_object_copy_internal (const ucl_object_t *other, bool allow_array)
/* deep copy of values stored */
if (other->trash_stack[UCL_TRASH_KEY] != NULL) {
- new->trash_stack[UCL_TRASH_KEY] =
- strdup (other->trash_stack[UCL_TRASH_KEY]);
+ new->trash_stack[UCL_TRASH_KEY] = NULL;
if (other->key == (const char *)other->trash_stack[UCL_TRASH_KEY]) {
+ new->trash_stack[UCL_TRASH_KEY] = malloc(other->keylen + 1);
+ memcpy(new->trash_stack[UCL_TRASH_KEY], other->trash_stack[UCL_TRASH_KEY], other->keylen);
+ new->trash_stack[UCL_TRASH_KEY][other->keylen] = '\0';
new->key = new->trash_stack[UCL_TRASH_KEY];
}
}
@@ -3666,13 +3694,6 @@ ucl_object_compare (const ucl_object_t *o1, const ucl_object_t *o2)
ucl_object_iter_t iter = NULL;
int ret = 0;
- // Must check for NULL or code will segfault
- if ((o1 == NULL) || (o2 == NULL))
- {
- // The only way this could be true is of both are NULL
- return (o1 == NULL) && (o2 == NULL);
- }
-
if (o1->type != o2->type) {
return (o1->type) - (o2->type);
}
diff --git a/contrib/libucl/stamp-h.in b/contrib/libucl/stamp-h.in
deleted file mode 100644
index 9788f70238c9..000000000000
--- a/contrib/libucl/stamp-h.in
+++ /dev/null
@@ -1 +0,0 @@
-timestamp
diff --git a/contrib/libucl/tests/.gitignore b/contrib/libucl/tests/.gitignore
new file mode 100644
index 000000000000..464482434f22
--- /dev/null
+++ b/contrib/libucl/tests/.gitignore
@@ -0,0 +1,10 @@
+*.log
+*.trs
+*.plist
+
+test_basic
+test_generate
+test_msgpack
+test_schema
+test_speed
+test_streamline
diff --git a/contrib/libucl/tests/Makefile.am b/contrib/libucl/tests/Makefile.am
deleted file mode 100644
index 055eb8bd85b0..000000000000
--- a/contrib/libucl/tests/Makefile.am
+++ /dev/null
@@ -1,45 +0,0 @@
-EXTRA_DIST = $(TESTS) basic schema generate.res \
- streamline.res rcl_test.json.xz
-
-TESTS = basic.test \
- generate.test \
- schema.test \
- msgpack.test \
- speed.test \
- msgpack.test
-TESTS_ENVIRONMENT = $(SH) \
- TEST_DIR=$(top_srcdir)/tests \
- TEST_OUT_DIR=$(top_builddir)/tests \
- TEST_BINARY_DIR=$(top_builddir)/tests
-
-common_test_cflags = -I$(top_srcdir)/include \
- -I$(top_srcdir)/src \
- -I$(top_srcdir)/uthash
-common_test_ldadd = $(top_builddir)/src/libucl.la
-
-test_basic_SOURCES = test_basic.c
-test_basic_LDADD = $(common_test_ldadd)
-test_basic_CFLAGS = $(common_test_cflags)
-
-test_speed_SOURCES = test_speed.c
-test_speed_LDADD = $(common_test_ldadd)
-test_speed_CFLAGS = $(common_test_cflags)
-
-test_generate_SOURCES = test_generate.c
-test_generate_LDADD = $(common_test_ldadd)
-test_generate_CFLAGS = $(common_test_cflags)
-
-test_schema_SOURCES = test_schema.c
-test_schema_LDADD = $(common_test_ldadd)
-test_schema_CFLAGS = $(common_test_cflags)
-
-test_streamline_SOURCES = test_streamline.c
-test_streamline_LDADD = $(common_test_ldadd)
-test_streamline_CFLAGS = $(common_test_cflags)
-
-test_msgpack_SOURCES = test_msgpack.c
-test_msgpack_LDADD = $(common_test_ldadd)
-test_msgpack_CFLAGS = $(common_test_cflags)
-
-check_PROGRAMS = test_basic test_speed test_generate test_schema test_streamline \
- test_msgpack \ No newline at end of file
diff --git a/contrib/libucl/tests/schema/definitions.json b/contrib/libucl/tests/schema/definitions.json
deleted file mode 100644
index 1ab9b2163c44..000000000000
--- a/contrib/libucl/tests/schema/definitions.json
+++ /dev/null
@@ -1,32 +0,0 @@
-[
- {
- "description": "valid definition",
- "schema": {"$ref": "http://highsecure.ru/ucl-schema/schema#"},
- "tests": [
- {
- "description": "valid definition schema",
- "data": {
- "definitions": {
- "foo": {"type": "integer"}
- }
- },
- "valid": true
- }
- ]
- },
- {
- "description": "invalid definition",
- "schema": {"$ref": "http://highsecure.ru/ucl-schema/schema#"},
- "tests": [
- {
- "description": "invalid definition schema",
- "data": {
- "definitions": {
- "foo": {"type": 1}
- }
- },
- "valid": false
- }
- ]
- }
-]
diff --git a/contrib/libucl/tests/schema/ref.json b/contrib/libucl/tests/schema/ref.json
index 1767769cd845..d8214bc2b30c 100644
--- a/contrib/libucl/tests/schema/ref.json
+++ b/contrib/libucl/tests/schema/ref.json
@@ -124,21 +124,5 @@
"valid": false
}
]
- },
- {
- "description": "remote ref, containing refs itself",
- "schema": {"$ref": "http://highsecure.ru/ucl-schema/schema#"},
- "tests": [
- {
- "description": "remote ref valid",
- "data": {"minLength": 1},
- "valid": true
- },
- {
- "description": "remote ref invalid",
- "data": {"minLength": -1},
- "valid": false
- }
- ]
}
]
diff --git a/contrib/libucl/tests/schema/refRemote.json b/contrib/libucl/tests/schema/refRemote.json
deleted file mode 100644
index 067c666b0ec8..000000000000
--- a/contrib/libucl/tests/schema/refRemote.json
+++ /dev/null
@@ -1,76 +0,0 @@
-[
- {
- "description": "remote ref",
- "schema": {"$ref": "http://highsecure.ru/ucl-schema/remotes/integer.json"},
- "tests": [
- {
- "description": "remote ref valid",
- "data": 1,
- "valid": true
- },
- {
- "description": "remote ref invalid",
- "data": "a",
- "valid": false
- }
- ]
- },
- {
- "description": "fragment within remote ref",
- "schema": {"$ref": "http://highsecure.ru/ucl-schema/remotes/subSchemas.json#/integer"},
- "tests": [
- {
- "description": "remote fragment valid",
- "data": 1,
- "valid": true
- },
- {
- "description": "remote fragment invalid",
- "data": "a",
- "valid": false
- }
- ]
- },
- {
- "description": "ref within remote ref",
- "schema": {
- "$ref": "http://highsecure.ru/ucl-schema/remotes/subSchemas.json#/refToInteger"
- },
- "tests": [
- {
- "description": "ref within ref valid",
- "data": 1,
- "valid": true
- },
- {
- "description": "ref within ref invalid",
- "data": "a",
- "valid": false
- }
- ]
- }
-/*
- {
- "description": "change resolution scope",
- "schema": {
- "id": "http://highsecure.ru/ucl-schema/remotes/",
- "items": {
- "id": "folder/",
- "items": {"$ref": "folderInteger.json"}
- }
- },
- "tests": [
- {
- "description": "changed scope ref valid",
- "data": [[1]],
- "valid": true
- },
- {
- "description": "changed scope ref invalid",
- "data": [["a"]],
- "valid": false
- }
- ]
- }
-*/
-]
diff --git a/contrib/libucl/tests/test_speed.c b/contrib/libucl/tests/test_speed.c
index 56f2e5abc6c7..51476c94940b 100644
--- a/contrib/libucl/tests/test_speed.c
+++ b/contrib/libucl/tests/test_speed.c
@@ -44,7 +44,7 @@ get_ticks (void)
{
double res;
-#ifdef __APPLE__
+#if defined(__APPLE__) && defined(HAVE_MACH_MACH_TIME_H)
res = mach_absolute_time () / 1000000000.;
#else
struct timespec ts;
diff --git a/contrib/libucl/tests/test_streamline.c b/contrib/libucl/tests/test_streamline.c
index 4c56c4cdcffd..37fe14f9fb97 100644
--- a/contrib/libucl/tests/test_streamline.c
+++ b/contrib/libucl/tests/test_streamline.c
@@ -26,6 +26,10 @@
#include <assert.h>
#include "ucl.h"
+#include <sys/types.h>
+#include <fcntl.h>
+#include <unistd.h>
+
int
main (int argc, char **argv)
{
@@ -34,7 +38,28 @@ main (int argc, char **argv)
const char *fname_out = NULL;
struct ucl_emitter_context *ctx;
struct ucl_emitter_functions *f;
- int ret = 0;
+ int ret = 0, opt, json = 0, compact = 0, yaml = 0;
+
+ while ((opt = getopt(argc, argv, "jcy")) != -1) {
+ switch (opt) {
+ case 'j':
+ json = 1;
+ break;
+ case 'c':
+ compact = 1;
+ break;
+ case 'y':
+ yaml = 1;
+ break;
+ default: /* '?' */
+ fprintf (stderr, "Usage: %s [-jcy] [out]\n",
+ argv[0]);
+ exit (EXIT_FAILURE);
+ }
+ }
+
+ argc -= optind;
+ argv += optind;
switch (argc) {
case 2:
@@ -63,7 +88,21 @@ main (int argc, char **argv)
ucl_object_insert_key (obj, cur, "key3", 0, false);
f = ucl_object_emit_file_funcs (out);
- ctx = ucl_object_emit_streamline_new (obj, UCL_EMIT_CONFIG, f);
+
+ if (yaml) {
+ ctx = ucl_object_emit_streamline_new (obj, UCL_EMIT_YAML, f);
+ }
+ else if (json) {
+ if (compact) {
+ ctx = ucl_object_emit_streamline_new (obj, UCL_EMIT_JSON_COMPACT, f);
+ }
+ else {
+ ctx = ucl_object_emit_streamline_new (obj, UCL_EMIT_JSON, f);
+ }
+ }
+ else {
+ ctx = ucl_object_emit_streamline_new (obj, UCL_EMIT_CONFIG, f);
+ }
assert (ctx != NULL);
diff --git a/contrib/libucl/uthash/utlist.h b/contrib/libucl/uthash/utlist.h
index c82dd916e2ed..7cda1ca0ecac 100644
--- a/contrib/libucl/uthash/utlist.h
+++ b/contrib/libucl/uthash/utlist.h
@@ -1,5 +1,5 @@
/*
-Copyright (c) 2007-2013, Troy D. Hanson http://troydhanson.github.com/uthash/
+Copyright (c) 2007-2022, Troy D. Hanson https://troydhanson.github.io/uthash/
All rights reserved.
Redistribution and use in source and binary forms, with or without
@@ -24,11 +24,11 @@ SOFTWARE, EVEN IF ADVISED OF THE POSSIBILITY OF SUCH DAMAGE.
#ifndef UTLIST_H
#define UTLIST_H
-#define UTLIST_VERSION 1.9.8
+#define UTLIST_VERSION 2.3.0
#include <assert.h>
-/*
+/*
* This file contains macros to manipulate singly and doubly-linked lists.
*
* 1. LL_ macros: singly-linked lists.
@@ -38,7 +38,7 @@ SOFTWARE, EVEN IF ADVISED OF THE POSSIBILITY OF SUCH DAMAGE.
* To use singly-linked lists, your structure must have a "next" pointer.
* To use doubly-linked lists, your structure must "prev" and "next" pointers.
* Either way, the pointer to the head of the list must be initialized to NULL.
- *
+ *
* ----------------.EXAMPLE -------------------------
* struct item {
* int id;
@@ -61,41 +61,46 @@ SOFTWARE, EVEN IF ADVISED OF THE POSSIBILITY OF SUCH DAMAGE.
/* These macros use decltype or the earlier __typeof GNU extension.
As decltype is only available in newer compilers (VS2010 or gcc 4.3+
- when compiling c++ code), this code uses whatever method is needed
+ when compiling c++ source) this code uses whatever method is needed
or, for VS2008 where neither is available, uses casting workarounds. */
-#ifdef _MSC_VER /* MS compiler */
+#if !defined(LDECLTYPE) && !defined(NO_DECLTYPE)
+#if defined(_MSC_VER) /* MS compiler */
#if _MSC_VER >= 1600 && defined(__cplusplus) /* VS2010 or newer in C++ mode */
#define LDECLTYPE(x) decltype(x)
-#else /* VS2008 or older (or VS2010 in C mode) */
+#else /* VS2008 or older (or VS2010 in C mode) */
#define NO_DECLTYPE
-#define LDECLTYPE(x) char*
#endif
-#elif defined(__ICCARM__)
+#elif defined(__MCST__) /* Elbrus C Compiler */
+#define LDECLTYPE(x) __typeof(x)
+#elif defined(__BORLANDC__) || defined(__ICCARM__) || defined(__LCC__) || defined(__WATCOMC__)
#define NO_DECLTYPE
-#define LDECLTYPE(x) char*
-#else /* GNU, Sun and other compilers */
+#else /* GNU, Sun and other compilers */
#define LDECLTYPE(x) __typeof(x)
#endif
+#endif
/* for VS2008 we use some workarounds to get around the lack of decltype,
* namely, we always reassign our tmp variable to the list head if we need
* to dereference its prev/next pointers, and save/restore the real head.*/
#ifdef NO_DECLTYPE
-#define _SV(elt,list) _tmp = (char*)(list); {char **_alias = (char**)&(list); *_alias = (elt); }
-#define _NEXT(elt,list,next) ((char*)((list)->next))
-#define _NEXTASGN(elt,list,to,next) { char **_alias = (char**)&((list)->next); *_alias=(char*)(to); }
-/* #define _PREV(elt,list,prev) ((char*)((list)->prev)) */
-#define _PREVASGN(elt,list,to,prev) { char **_alias = (char**)&((list)->prev); *_alias=(char*)(to); }
-#define _RS(list) { char **_alias = (char**)&(list); *_alias=_tmp; }
-#define _CASTASGN(a,b) { char **_alias = (char**)&(a); *_alias=(char*)(b); }
-#else
-#define _SV(elt,list)
-#define _NEXT(elt,list,next) ((elt)->next)
-#define _NEXTASGN(elt,list,to,next) ((elt)->next)=(to)
-/* #define _PREV(elt,list,prev) ((elt)->prev) */
-#define _PREVASGN(elt,list,to,prev) ((elt)->prev)=(to)
-#define _RS(list)
-#define _CASTASGN(a,b) (a)=(b)
+#define IF_NO_DECLTYPE(x) x
+#define LDECLTYPE(x) char*
+#define UTLIST_SV(elt,list) _tmp = (char*)(list); {char **_alias = (char**)&(list); *_alias = (elt); }
+#define UTLIST_NEXT(elt,list,next) ((char*)((list)->next))
+#define UTLIST_NEXTASGN(elt,list,to,next) { char **_alias = (char**)&((list)->next); *_alias=(char*)(to); }
+/* #define UTLIST_PREV(elt,list,prev) ((char*)((list)->prev)) */
+#define UTLIST_PREVASGN(elt,list,to,prev) { char **_alias = (char**)&((list)->prev); *_alias=(char*)(to); }
+#define UTLIST_RS(list) { char **_alias = (char**)&(list); *_alias=_tmp; }
+#define UTLIST_CASTASGN(a,b) { char **_alias = (char**)&(a); *_alias=(char*)(b); }
+#else
+#define IF_NO_DECLTYPE(x)
+#define UTLIST_SV(elt,list)
+#define UTLIST_NEXT(elt,list,next) ((elt)->next)
+#define UTLIST_NEXTASGN(elt,list,to,next) ((elt)->next)=(to)
+/* #define UTLIST_PREV(elt,list,prev) ((elt)->prev) */
+#define UTLIST_PREVASGN(elt,list,to,prev) ((elt)->prev)=(to)
+#define UTLIST_RS(list)
+#define UTLIST_CASTASGN(a,b) (a)=(b)
#endif
/******************************************************************************
@@ -111,13 +116,14 @@ do {
LDECLTYPE(list) _ls_q; \
LDECLTYPE(list) _ls_e; \
LDECLTYPE(list) _ls_tail; \
+ IF_NO_DECLTYPE(LDECLTYPE(list) _tmp;) \
int _ls_insize, _ls_nmerges, _ls_psize, _ls_qsize, _ls_i, _ls_looping; \
if (list) { \
_ls_insize = 1; \
_ls_looping = 1; \
while (_ls_looping) { \
- _CASTASGN(_ls_p,list); \
- list = NULL; \
+ UTLIST_CASTASGN(_ls_p,list); \
+ (list) = NULL; \
_ls_tail = NULL; \
_ls_nmerges = 0; \
while (_ls_p) { \
@@ -126,35 +132,35 @@ do {
_ls_psize = 0; \
for (_ls_i = 0; _ls_i < _ls_insize; _ls_i++) { \
_ls_psize++; \
- _SV(_ls_q,list); _ls_q = _NEXT(_ls_q,list,next); _RS(list); \
+ UTLIST_SV(_ls_q,list); _ls_q = UTLIST_NEXT(_ls_q,list,next); UTLIST_RS(list); \
if (!_ls_q) break; \
} \
_ls_qsize = _ls_insize; \
while (_ls_psize > 0 || (_ls_qsize > 0 && _ls_q)) { \
if (_ls_psize == 0) { \
- _ls_e = _ls_q; _SV(_ls_q,list); _ls_q = \
- _NEXT(_ls_q,list,next); _RS(list); _ls_qsize--; \
+ _ls_e = _ls_q; UTLIST_SV(_ls_q,list); _ls_q = \
+ UTLIST_NEXT(_ls_q,list,next); UTLIST_RS(list); _ls_qsize--; \
} else if (_ls_qsize == 0 || !_ls_q) { \
- _ls_e = _ls_p; _SV(_ls_p,list); _ls_p = \
- _NEXT(_ls_p,list,next); _RS(list); _ls_psize--; \
+ _ls_e = _ls_p; UTLIST_SV(_ls_p,list); _ls_p = \
+ UTLIST_NEXT(_ls_p,list,next); UTLIST_RS(list); _ls_psize--; \
} else if (cmp(_ls_p,_ls_q) <= 0) { \
- _ls_e = _ls_p; _SV(_ls_p,list); _ls_p = \
- _NEXT(_ls_p,list,next); _RS(list); _ls_psize--; \
+ _ls_e = _ls_p; UTLIST_SV(_ls_p,list); _ls_p = \
+ UTLIST_NEXT(_ls_p,list,next); UTLIST_RS(list); _ls_psize--; \
} else { \
- _ls_e = _ls_q; _SV(_ls_q,list); _ls_q = \
- _NEXT(_ls_q,list,next); _RS(list); _ls_qsize--; \
+ _ls_e = _ls_q; UTLIST_SV(_ls_q,list); _ls_q = \
+ UTLIST_NEXT(_ls_q,list,next); UTLIST_RS(list); _ls_qsize--; \
} \
if (_ls_tail) { \
- _SV(_ls_tail,list); _NEXTASGN(_ls_tail,list,_ls_e,next); _RS(list); \
+ UTLIST_SV(_ls_tail,list); UTLIST_NEXTASGN(_ls_tail,list,_ls_e,next); UTLIST_RS(list); \
} else { \
- _CASTASGN(list,_ls_e); \
+ UTLIST_CASTASGN(list,_ls_e); \
} \
_ls_tail = _ls_e; \
} \
_ls_p = _ls_q; \
} \
if (_ls_tail) { \
- _SV(_ls_tail,list); _NEXTASGN(_ls_tail,list,NULL,next); _RS(list); \
+ UTLIST_SV(_ls_tail,list); UTLIST_NEXTASGN(_ls_tail,list,NULL,next); UTLIST_RS(list); \
} \
if (_ls_nmerges <= 1) { \
_ls_looping=0; \
@@ -174,13 +180,14 @@ do {
LDECLTYPE(list) _ls_q; \
LDECLTYPE(list) _ls_e; \
LDECLTYPE(list) _ls_tail; \
+ IF_NO_DECLTYPE(LDECLTYPE(list) _tmp;) \
int _ls_insize, _ls_nmerges, _ls_psize, _ls_qsize, _ls_i, _ls_looping; \
if (list) { \
_ls_insize = 1; \
_ls_looping = 1; \
while (_ls_looping) { \
- _CASTASGN(_ls_p,list); \
- list = NULL; \
+ UTLIST_CASTASGN(_ls_p,list); \
+ (list) = NULL; \
_ls_tail = NULL; \
_ls_nmerges = 0; \
while (_ls_p) { \
@@ -189,36 +196,36 @@ do {
_ls_psize = 0; \
for (_ls_i = 0; _ls_i < _ls_insize; _ls_i++) { \
_ls_psize++; \
- _SV(_ls_q,list); _ls_q = _NEXT(_ls_q,list,next); _RS(list); \
+ UTLIST_SV(_ls_q,list); _ls_q = UTLIST_NEXT(_ls_q,list,next); UTLIST_RS(list); \
if (!_ls_q) break; \
} \
_ls_qsize = _ls_insize; \
- while (_ls_psize > 0 || (_ls_qsize > 0 && _ls_q)) { \
+ while ((_ls_psize > 0) || ((_ls_qsize > 0) && _ls_q)) { \
if (_ls_psize == 0) { \
- _ls_e = _ls_q; _SV(_ls_q,list); _ls_q = \
- _NEXT(_ls_q,list,next); _RS(list); _ls_qsize--; \
- } else if (_ls_qsize == 0 || !_ls_q) { \
- _ls_e = _ls_p; _SV(_ls_p,list); _ls_p = \
- _NEXT(_ls_p,list,next); _RS(list); _ls_psize--; \
+ _ls_e = _ls_q; UTLIST_SV(_ls_q,list); _ls_q = \
+ UTLIST_NEXT(_ls_q,list,next); UTLIST_RS(list); _ls_qsize--; \
+ } else if ((_ls_qsize == 0) || (!_ls_q)) { \
+ _ls_e = _ls_p; UTLIST_SV(_ls_p,list); _ls_p = \
+ UTLIST_NEXT(_ls_p,list,next); UTLIST_RS(list); _ls_psize--; \
} else if (cmp(_ls_p,_ls_q) <= 0) { \
- _ls_e = _ls_p; _SV(_ls_p,list); _ls_p = \
- _NEXT(_ls_p,list,next); _RS(list); _ls_psize--; \
+ _ls_e = _ls_p; UTLIST_SV(_ls_p,list); _ls_p = \
+ UTLIST_NEXT(_ls_p,list,next); UTLIST_RS(list); _ls_psize--; \
} else { \
- _ls_e = _ls_q; _SV(_ls_q,list); _ls_q = \
- _NEXT(_ls_q,list,next); _RS(list); _ls_qsize--; \
+ _ls_e = _ls_q; UTLIST_SV(_ls_q,list); _ls_q = \
+ UTLIST_NEXT(_ls_q,list,next); UTLIST_RS(list); _ls_qsize--; \
} \
if (_ls_tail) { \
- _SV(_ls_tail,list); _NEXTASGN(_ls_tail,list,_ls_e,next); _RS(list); \
+ UTLIST_SV(_ls_tail,list); UTLIST_NEXTASGN(_ls_tail,list,_ls_e,next); UTLIST_RS(list); \
} else { \
- _CASTASGN(list,_ls_e); \
+ UTLIST_CASTASGN(list,_ls_e); \
} \
- _SV(_ls_e,list); _PREVASGN(_ls_e,list,_ls_tail,prev); _RS(list); \
+ UTLIST_SV(_ls_e,list); UTLIST_PREVASGN(_ls_e,list,_ls_tail,prev); UTLIST_RS(list); \
_ls_tail = _ls_e; \
} \
_ls_p = _ls_q; \
} \
- _CASTASGN(list->prev, _ls_tail); \
- _SV(_ls_tail,list); _NEXTASGN(_ls_tail,list,NULL,next); _RS(list); \
+ UTLIST_CASTASGN((list)->prev, _ls_tail); \
+ UTLIST_SV(_ls_tail,list); UTLIST_NEXTASGN(_ls_tail,list,NULL,next); UTLIST_RS(list); \
if (_ls_nmerges <= 1) { \
_ls_looping=0; \
} \
@@ -243,9 +250,9 @@ do {
_ls_insize = 1; \
_ls_looping = 1; \
while (_ls_looping) { \
- _CASTASGN(_ls_p,list); \
- _CASTASGN(_ls_oldhead,list); \
- list = NULL; \
+ UTLIST_CASTASGN(_ls_p,list); \
+ UTLIST_CASTASGN(_ls_oldhead,list); \
+ (list) = NULL; \
_ls_tail = NULL; \
_ls_nmerges = 0; \
while (_ls_p) { \
@@ -254,47 +261,47 @@ do {
_ls_psize = 0; \
for (_ls_i = 0; _ls_i < _ls_insize; _ls_i++) { \
_ls_psize++; \
- _SV(_ls_q,list); \
- if (_NEXT(_ls_q,list,next) == _ls_oldhead) { \
+ UTLIST_SV(_ls_q,list); \
+ if (UTLIST_NEXT(_ls_q,list,next) == _ls_oldhead) { \
_ls_q = NULL; \
} else { \
- _ls_q = _NEXT(_ls_q,list,next); \
+ _ls_q = UTLIST_NEXT(_ls_q,list,next); \
} \
- _RS(list); \
+ UTLIST_RS(list); \
if (!_ls_q) break; \
} \
_ls_qsize = _ls_insize; \
while (_ls_psize > 0 || (_ls_qsize > 0 && _ls_q)) { \
if (_ls_psize == 0) { \
- _ls_e = _ls_q; _SV(_ls_q,list); _ls_q = \
- _NEXT(_ls_q,list,next); _RS(list); _ls_qsize--; \
+ _ls_e = _ls_q; UTLIST_SV(_ls_q,list); _ls_q = \
+ UTLIST_NEXT(_ls_q,list,next); UTLIST_RS(list); _ls_qsize--; \
if (_ls_q == _ls_oldhead) { _ls_q = NULL; } \
} else if (_ls_qsize == 0 || !_ls_q) { \
- _ls_e = _ls_p; _SV(_ls_p,list); _ls_p = \
- _NEXT(_ls_p,list,next); _RS(list); _ls_psize--; \
+ _ls_e = _ls_p; UTLIST_SV(_ls_p,list); _ls_p = \
+ UTLIST_NEXT(_ls_p,list,next); UTLIST_RS(list); _ls_psize--; \
if (_ls_p == _ls_oldhead) { _ls_p = NULL; } \
} else if (cmp(_ls_p,_ls_q) <= 0) { \
- _ls_e = _ls_p; _SV(_ls_p,list); _ls_p = \
- _NEXT(_ls_p,list,next); _RS(list); _ls_psize--; \
+ _ls_e = _ls_p; UTLIST_SV(_ls_p,list); _ls_p = \
+ UTLIST_NEXT(_ls_p,list,next); UTLIST_RS(list); _ls_psize--; \
if (_ls_p == _ls_oldhead) { _ls_p = NULL; } \
} else { \
- _ls_e = _ls_q; _SV(_ls_q,list); _ls_q = \
- _NEXT(_ls_q,list,next); _RS(list); _ls_qsize--; \
+ _ls_e = _ls_q; UTLIST_SV(_ls_q,list); _ls_q = \
+ UTLIST_NEXT(_ls_q,list,next); UTLIST_RS(list); _ls_qsize--; \
if (_ls_q == _ls_oldhead) { _ls_q = NULL; } \
} \
if (_ls_tail) { \
- _SV(_ls_tail,list); _NEXTASGN(_ls_tail,list,_ls_e,next); _RS(list); \
+ UTLIST_SV(_ls_tail,list); UTLIST_NEXTASGN(_ls_tail,list,_ls_e,next); UTLIST_RS(list); \
} else { \
- _CASTASGN(list,_ls_e); \
+ UTLIST_CASTASGN(list,_ls_e); \
} \
- _SV(_ls_e,list); _PREVASGN(_ls_e,list,_ls_tail,prev); _RS(list); \
+ UTLIST_SV(_ls_e,list); UTLIST_PREVASGN(_ls_e,list,_ls_tail,prev); UTLIST_RS(list); \
_ls_tail = _ls_e; \
} \
_ls_p = _ls_q; \
} \
- _CASTASGN(list->prev,_ls_tail); \
- _CASTASGN(_tmp,list); \
- _SV(_ls_tail,list); _NEXTASGN(_ls_tail,list,_tmp,next); _RS(list); \
+ UTLIST_CASTASGN((list)->prev,_ls_tail); \
+ UTLIST_CASTASGN(_tmp,list); \
+ UTLIST_SV(_ls_tail,list); UTLIST_NEXTASGN(_ls_tail,list,_tmp,next); UTLIST_RS(list); \
if (_ls_nmerges <= 1) { \
_ls_looping=0; \
} \
@@ -311,8 +318,8 @@ do {
#define LL_PREPEND2(head,add,next) \
do { \
- (add)->next = head; \
- head = add; \
+ (add)->next = (head); \
+ (head) = (add); \
} while (0)
#define LL_CONCAT(head1,head2) \
@@ -322,7 +329,7 @@ do {
do { \
LDECLTYPE(head1) _tmp; \
if (head1) { \
- _tmp = head1; \
+ _tmp = (head1); \
while (_tmp->next) { _tmp = _tmp->next; } \
_tmp->next=(head2); \
} else { \
@@ -338,7 +345,7 @@ do {
LDECLTYPE(head) _tmp; \
(add)->next=NULL; \
if (head) { \
- _tmp = head; \
+ _tmp = (head); \
while (_tmp->next) { _tmp = _tmp->next; } \
_tmp->next=(add); \
} else { \
@@ -346,96 +353,76 @@ do {
} \
} while (0)
-#define LL_DELETE(head,del) \
- LL_DELETE2(head,del,next)
+#define LL_INSERT_INORDER(head,add,cmp) \
+ LL_INSERT_INORDER2(head,add,cmp,next)
-#define LL_DELETE2(head,del,next) \
+#define LL_INSERT_INORDER2(head,add,cmp,next) \
do { \
LDECLTYPE(head) _tmp; \
- if ((head) == (del)) { \
- (head)=(head)->next; \
+ if (head) { \
+ LL_LOWER_BOUND2(head, _tmp, add, cmp, next); \
+ LL_APPEND_ELEM2(head, _tmp, add, next); \
} else { \
- _tmp = head; \
- while (_tmp->next && (_tmp->next != (del))) { \
- _tmp = _tmp->next; \
- } \
- if (_tmp->next) { \
- _tmp->next = ((del)->next); \
- } \
+ (head) = (add); \
+ (head)->next = NULL; \
} \
} while (0)
-/* Here are VS2008 replacements for LL_APPEND and LL_DELETE */
-#define LL_APPEND_VS2008(head,add) \
- LL_APPEND2_VS2008(head,add,next)
+#define LL_LOWER_BOUND(head,elt,like,cmp) \
+ LL_LOWER_BOUND2(head,elt,like,cmp,next)
-#define LL_APPEND2_VS2008(head,add,next) \
-do { \
- if (head) { \
- (add)->next = head; /* use add->next as a temp variable */ \
- while ((add)->next->next) { (add)->next = (add)->next->next; } \
- (add)->next->next=(add); \
- } else { \
- (head)=(add); \
- } \
- (add)->next=NULL; \
-} while (0)
+#define LL_LOWER_BOUND2(head,elt,like,cmp,next) \
+ do { \
+ if ((head) == NULL || (cmp(head, like)) >= 0) { \
+ (elt) = NULL; \
+ } else { \
+ for ((elt) = (head); (elt)->next != NULL; (elt) = (elt)->next) { \
+ if (cmp((elt)->next, like) >= 0) { \
+ break; \
+ } \
+ } \
+ } \
+ } while (0)
-#define LL_DELETE_VS2008(head,del) \
- LL_DELETE2_VS2008(head,del,next)
+#define LL_DELETE(head,del) \
+ LL_DELETE2(head,del,next)
-#define LL_DELETE2_VS2008(head,del,next) \
+#define LL_DELETE2(head,del,next) \
do { \
+ LDECLTYPE(head) _tmp; \
if ((head) == (del)) { \
(head)=(head)->next; \
} else { \
- char *_tmp = (char*)(head); \
- while ((head)->next && ((head)->next != (del))) { \
- head = (head)->next; \
- } \
- if ((head)->next) { \
- (head)->next = ((del)->next); \
+ _tmp = (head); \
+ while (_tmp->next && (_tmp->next != (del))) { \
+ _tmp = _tmp->next; \
} \
- { \
- char **_head_alias = (char**)&(head); \
- *_head_alias = _tmp; \
+ if (_tmp->next) { \
+ _tmp->next = (del)->next; \
} \
} \
} while (0)
-#ifdef NO_DECLTYPE
-#undef LL_APPEND
-#define LL_APPEND LL_APPEND_VS2008
-#undef LL_DELETE
-#define LL_DELETE LL_DELETE_VS2008
-#undef LL_DELETE2
-#define LL_DELETE2 LL_DELETE2_VS2008
-#undef LL_APPEND2
-#define LL_APPEND2 LL_APPEND2_VS2008
-#undef LL_CONCAT /* no LL_CONCAT_VS2008 */
-#undef DL_CONCAT /* no DL_CONCAT_VS2008 */
-#endif
-/* end VS2008 replacements */
#define LL_COUNT(head,el,counter) \
LL_COUNT2(head,el,counter,next) \
#define LL_COUNT2(head,el,counter,next) \
-{ \
- counter = 0; \
- LL_FOREACH2(head,el,next){ ++counter; } \
-}
+do { \
+ (counter) = 0; \
+ LL_FOREACH2(head,el,next) { ++(counter); } \
+} while (0)
#define LL_FOREACH(head,el) \
LL_FOREACH2(head,el,next)
#define LL_FOREACH2(head,el,next) \
- for(el=head;el;el=(el)->next)
+ for ((el) = (head); el; (el) = (el)->next)
#define LL_FOREACH_SAFE(head,el,tmp) \
LL_FOREACH_SAFE2(head,el,tmp,next)
#define LL_FOREACH_SAFE2(head,el,tmp,next) \
- for((el)=(head);(el) && (tmp = (el)->next, 1); (el) = tmp)
+ for ((el) = (head); (el) && ((tmp) = (el)->next, 1); (el) = (tmp))
#define LL_SEARCH_SCALAR(head,out,field,val) \
LL_SEARCH_SCALAR2(head,out,field,val,next)
@@ -445,7 +432,7 @@ do {
LL_FOREACH2(head,out,next) { \
if ((out)->field == (val)) break; \
} \
-} while(0)
+} while (0)
#define LL_SEARCH(head,out,elt,cmp) \
LL_SEARCH2(head,out,elt,cmp,next)
@@ -455,19 +442,19 @@ do {
LL_FOREACH2(head,out,next) { \
if ((cmp(out,elt))==0) break; \
} \
-} while(0)
+} while (0)
-#define LL_REPLACE_ELEM(head, el, add) \
+#define LL_REPLACE_ELEM2(head, el, add, next) \
do { \
LDECLTYPE(head) _tmp; \
- assert(head != NULL); \
- assert(el != NULL); \
- assert(add != NULL); \
+ assert((head) != NULL); \
+ assert((el) != NULL); \
+ assert((add) != NULL); \
(add)->next = (el)->next; \
if ((head) == (el)) { \
(head) = (add); \
} else { \
- _tmp = head; \
+ _tmp = (head); \
while (_tmp->next && (_tmp->next != (el))) { \
_tmp = _tmp->next; \
} \
@@ -477,26 +464,158 @@ do {
} \
} while (0)
+#define LL_REPLACE_ELEM(head, el, add) \
+ LL_REPLACE_ELEM2(head, el, add, next)
+
+#define LL_PREPEND_ELEM2(head, el, add, next) \
+do { \
+ if (el) { \
+ LDECLTYPE(head) _tmp; \
+ assert((head) != NULL); \
+ assert((add) != NULL); \
+ (add)->next = (el); \
+ if ((head) == (el)) { \
+ (head) = (add); \
+ } else { \
+ _tmp = (head); \
+ while (_tmp->next && (_tmp->next != (el))) { \
+ _tmp = _tmp->next; \
+ } \
+ if (_tmp->next) { \
+ _tmp->next = (add); \
+ } \
+ } \
+ } else { \
+ LL_APPEND2(head, add, next); \
+ } \
+} while (0) \
+
#define LL_PREPEND_ELEM(head, el, add) \
+ LL_PREPEND_ELEM2(head, el, add, next)
+
+#define LL_APPEND_ELEM2(head, el, add, next) \
do { \
- LDECLTYPE(head) _tmp; \
- assert(head != NULL); \
- assert(el != NULL); \
- assert(add != NULL); \
- (add)->next = (el); \
- if ((head) == (el)) { \
- (head) = (add); \
+ if (el) { \
+ assert((head) != NULL); \
+ assert((add) != NULL); \
+ (add)->next = (el)->next; \
+ (el)->next = (add); \
} else { \
- _tmp = head; \
- while (_tmp->next && (_tmp->next != (el))) { \
- _tmp = _tmp->next; \
+ LL_PREPEND2(head, add, next); \
+ } \
+} while (0) \
+
+#define LL_APPEND_ELEM(head, el, add) \
+ LL_APPEND_ELEM2(head, el, add, next)
+
+#ifdef NO_DECLTYPE
+/* Here are VS2008 / NO_DECLTYPE replacements for a few functions */
+
+#undef LL_CONCAT2
+#define LL_CONCAT2(head1,head2,next) \
+do { \
+ char *_tmp; \
+ if (head1) { \
+ _tmp = (char*)(head1); \
+ while ((head1)->next) { (head1) = (head1)->next; } \
+ (head1)->next = (head2); \
+ UTLIST_RS(head1); \
+ } else { \
+ (head1)=(head2); \
} \
- if (_tmp->next) { \
- _tmp->next = (add); \
+} while (0)
+
+#undef LL_APPEND2
+#define LL_APPEND2(head,add,next) \
+do { \
+ if (head) { \
+ (add)->next = head; /* use add->next as a temp variable */ \
+ while ((add)->next->next) { (add)->next = (add)->next->next; } \
+ (add)->next->next=(add); \
+ } else { \
+ (head)=(add); \
+ } \
+ (add)->next=NULL; \
+} while (0)
+
+#undef LL_INSERT_INORDER2
+#define LL_INSERT_INORDER2(head,add,cmp,next) \
+do { \
+ if ((head) == NULL || (cmp(head, add)) >= 0) { \
+ (add)->next = (head); \
+ (head) = (add); \
+ } else { \
+ char *_tmp = (char*)(head); \
+ while ((head)->next != NULL && (cmp((head)->next, add)) < 0) { \
+ (head) = (head)->next; \
+ } \
+ (add)->next = (head)->next; \
+ (head)->next = (add); \
+ UTLIST_RS(head); \
+ } \
+} while (0)
+
+#undef LL_DELETE2
+#define LL_DELETE2(head,del,next) \
+do { \
+ if ((head) == (del)) { \
+ (head)=(head)->next; \
+ } else { \
+ char *_tmp = (char*)(head); \
+ while ((head)->next && ((head)->next != (del))) { \
+ (head) = (head)->next; \
+ } \
+ if ((head)->next) { \
+ (head)->next = ((del)->next); \
+ } \
+ UTLIST_RS(head); \
+ } \
+} while (0)
+
+#undef LL_REPLACE_ELEM2
+#define LL_REPLACE_ELEM2(head, el, add, next) \
+do { \
+ assert((head) != NULL); \
+ assert((el) != NULL); \
+ assert((add) != NULL); \
+ if ((head) == (el)) { \
+ (head) = (add); \
+ } else { \
+ (add)->next = head; \
+ while ((add)->next->next && ((add)->next->next != (el))) { \
+ (add)->next = (add)->next->next; \
+ } \
+ if ((add)->next->next) { \
+ (add)->next->next = (add); \
+ } \
+ } \
+ (add)->next = (el)->next; \
+} while (0)
+
+#undef LL_PREPEND_ELEM2
+#define LL_PREPEND_ELEM2(head, el, add, next) \
+do { \
+ if (el) { \
+ assert((head) != NULL); \
+ assert((add) != NULL); \
+ if ((head) == (el)) { \
+ (head) = (add); \
+ } else { \
+ (add)->next = (head); \
+ while ((add)->next->next && ((add)->next->next != (el))) { \
+ (add)->next = (add)->next->next; \
+ } \
+ if ((add)->next->next) { \
+ (add)->next->next = (add); \
+ } \
+ } \
+ (add)->next = (el); \
+ } else { \
+ LL_APPEND2(head, add, next); \
} \
- } \
} while (0) \
+#endif /* NO_DECLTYPE */
/******************************************************************************
* doubly linked list macros (non-circular) *
@@ -506,7 +625,7 @@ do {
#define DL_PREPEND2(head,add,prev,next) \
do { \
- (add)->next = head; \
+ (add)->next = (head); \
if (head) { \
(add)->prev = (head)->prev; \
(head)->prev = (add); \
@@ -531,7 +650,39 @@ do {
(head)->prev = (head); \
(head)->next = NULL; \
} \
-} while (0)
+} while (0)
+
+#define DL_INSERT_INORDER(head,add,cmp) \
+ DL_INSERT_INORDER2(head,add,cmp,prev,next)
+
+#define DL_INSERT_INORDER2(head,add,cmp,prev,next) \
+do { \
+ LDECLTYPE(head) _tmp; \
+ if (head) { \
+ DL_LOWER_BOUND2(head, _tmp, add, cmp, next); \
+ DL_APPEND_ELEM2(head, _tmp, add, prev, next); \
+ } else { \
+ (head) = (add); \
+ (head)->prev = (head); \
+ (head)->next = NULL; \
+ } \
+} while (0)
+
+#define DL_LOWER_BOUND(head,elt,like,cmp) \
+ DL_LOWER_BOUND2(head,elt,like,cmp,next)
+
+#define DL_LOWER_BOUND2(head,elt,like,cmp,next) \
+do { \
+ if ((head) == NULL || (cmp(head, like)) >= 0) { \
+ (elt) = NULL; \
+ } else { \
+ for ((elt) = (head); (elt)->next != NULL; (elt) = (elt)->next) { \
+ if ((cmp((elt)->next, like)) >= 0) { \
+ break; \
+ } \
+ } \
+ } \
+} while (0)
#define DL_CONCAT(head1,head2) \
DL_CONCAT2(head1,head2,prev,next)
@@ -541,25 +692,27 @@ do {
LDECLTYPE(head1) _tmp; \
if (head2) { \
if (head1) { \
- _tmp = (head2)->prev; \
+ UTLIST_CASTASGN(_tmp, (head2)->prev); \
(head2)->prev = (head1)->prev; \
(head1)->prev->next = (head2); \
- (head1)->prev = _tmp; \
+ UTLIST_CASTASGN((head1)->prev, _tmp); \
} else { \
(head1)=(head2); \
} \
} \
-} while (0)
+} while (0)
#define DL_DELETE(head,del) \
DL_DELETE2(head,del,prev,next)
#define DL_DELETE2(head,del,prev,next) \
do { \
+ assert((head) != NULL); \
assert((del)->prev != NULL); \
if ((del)->prev == (del)) { \
(head)=NULL; \
- } else if ((del)==(head)) { \
+ } else if ((del) == (head)) { \
+ assert((del)->next != NULL); \
(del)->next->prev = (del)->prev; \
(head) = (del)->next; \
} else { \
@@ -570,29 +723,29 @@ do {
(head)->prev = (del)->prev; \
} \
} \
-} while (0)
+} while (0)
#define DL_COUNT(head,el,counter) \
DL_COUNT2(head,el,counter,next) \
#define DL_COUNT2(head,el,counter,next) \
-{ \
- counter = 0; \
- DL_FOREACH2(head,el,next){ ++counter; } \
-}
+do { \
+ (counter) = 0; \
+ DL_FOREACH2(head,el,next) { ++(counter); } \
+} while (0)
#define DL_FOREACH(head,el) \
DL_FOREACH2(head,el,next)
#define DL_FOREACH2(head,el,next) \
- for(el=head;el;el=(el)->next)
+ for ((el) = (head); el; (el) = (el)->next)
/* this version is safe for deleting the elements during iteration */
#define DL_FOREACH_SAFE(head,el,tmp) \
DL_FOREACH_SAFE2(head,el,tmp,next)
#define DL_FOREACH_SAFE2(head,el,tmp,next) \
- for((el)=(head);(el) && (tmp = (el)->next, 1); (el) = tmp)
+ for ((el) = (head); (el) && ((tmp) = (el)->next, 1); (el) = (tmp))
/* these are identical to their singly-linked list counterparts */
#define DL_SEARCH_SCALAR LL_SEARCH_SCALAR
@@ -600,11 +753,11 @@ do {
#define DL_SEARCH_SCALAR2 LL_SEARCH_SCALAR2
#define DL_SEARCH2 LL_SEARCH2
-#define DL_REPLACE_ELEM(head, el, add) \
+#define DL_REPLACE_ELEM2(head, el, add, prev, next) \
do { \
- assert(head != NULL); \
- assert(el != NULL); \
- assert(add != NULL); \
+ assert((head) != NULL); \
+ assert((el) != NULL); \
+ assert((add) != NULL); \
if ((head) == (el)) { \
(head) = (add); \
(add)->next = (el)->next; \
@@ -626,25 +779,104 @@ do {
} \
} while (0)
+#define DL_REPLACE_ELEM(head, el, add) \
+ DL_REPLACE_ELEM2(head, el, add, prev, next)
+
+#define DL_PREPEND_ELEM2(head, el, add, prev, next) \
+do { \
+ if (el) { \
+ assert((head) != NULL); \
+ assert((add) != NULL); \
+ (add)->next = (el); \
+ (add)->prev = (el)->prev; \
+ (el)->prev = (add); \
+ if ((head) == (el)) { \
+ (head) = (add); \
+ } else { \
+ (add)->prev->next = (add); \
+ } \
+ } else { \
+ DL_APPEND2(head, add, prev, next); \
+ } \
+} while (0) \
+
#define DL_PREPEND_ELEM(head, el, add) \
+ DL_PREPEND_ELEM2(head, el, add, prev, next)
+
+#define DL_APPEND_ELEM2(head, el, add, prev, next) \
do { \
- assert(head != NULL); \
- assert(el != NULL); \
- assert(add != NULL); \
- (add)->next = (el); \
- (add)->prev = (el)->prev; \
- (el)->prev = (add); \
- if ((head) == (el)) { \
- (head) = (add); \
+ if (el) { \
+ assert((head) != NULL); \
+ assert((add) != NULL); \
+ (add)->next = (el)->next; \
+ (add)->prev = (el); \
+ (el)->next = (add); \
+ if ((add)->next) { \
+ (add)->next->prev = (add); \
+ } else { \
+ (head)->prev = (add); \
+ } \
} else { \
- (add)->prev->next = (add); \
+ DL_PREPEND2(head, add, prev, next); \
} \
} while (0) \
+#define DL_APPEND_ELEM(head, el, add) \
+ DL_APPEND_ELEM2(head, el, add, prev, next)
+
+#ifdef NO_DECLTYPE
+/* Here are VS2008 / NO_DECLTYPE replacements for a few functions */
+
+#undef DL_INSERT_INORDER2
+#define DL_INSERT_INORDER2(head,add,cmp,prev,next) \
+do { \
+ if ((head) == NULL) { \
+ (add)->prev = (add); \
+ (add)->next = NULL; \
+ (head) = (add); \
+ } else if ((cmp(head, add)) >= 0) { \
+ (add)->prev = (head)->prev; \
+ (add)->next = (head); \
+ (head)->prev = (add); \
+ (head) = (add); \
+ } else { \
+ char *_tmp = (char*)(head); \
+ while ((head)->next && (cmp((head)->next, add)) < 0) { \
+ (head) = (head)->next; \
+ } \
+ (add)->prev = (head); \
+ (add)->next = (head)->next; \
+ (head)->next = (add); \
+ UTLIST_RS(head); \
+ if ((add)->next) { \
+ (add)->next->prev = (add); \
+ } else { \
+ (head)->prev = (add); \
+ } \
+ } \
+} while (0)
+#endif /* NO_DECLTYPE */
/******************************************************************************
* circular doubly linked list macros *
*****************************************************************************/
+#define CDL_APPEND(head,add) \
+ CDL_APPEND2(head,add,prev,next)
+
+#define CDL_APPEND2(head,add,prev,next) \
+do { \
+ if (head) { \
+ (add)->prev = (head)->prev; \
+ (add)->next = (head); \
+ (head)->prev = (add); \
+ (add)->prev->next = (add); \
+ } else { \
+ (add)->prev = (add); \
+ (add)->next = (add); \
+ (head) = (add); \
+ } \
+} while (0)
+
#define CDL_PREPEND(head,add) \
CDL_PREPEND2(head,add,prev,next)
@@ -659,7 +891,39 @@ do {
(add)->prev = (add); \
(add)->next = (add); \
} \
-(head)=(add); \
+ (head) = (add); \
+} while (0)
+
+#define CDL_INSERT_INORDER(head,add,cmp) \
+ CDL_INSERT_INORDER2(head,add,cmp,prev,next)
+
+#define CDL_INSERT_INORDER2(head,add,cmp,prev,next) \
+do { \
+ LDECLTYPE(head) _tmp; \
+ if (head) { \
+ CDL_LOWER_BOUND2(head, _tmp, add, cmp, next); \
+ CDL_APPEND_ELEM2(head, _tmp, add, prev, next); \
+ } else { \
+ (head) = (add); \
+ (head)->next = (head); \
+ (head)->prev = (head); \
+ } \
+} while (0)
+
+#define CDL_LOWER_BOUND(head,elt,like,cmp) \
+ CDL_LOWER_BOUND2(head,elt,like,cmp,next)
+
+#define CDL_LOWER_BOUND2(head,elt,like,cmp,next) \
+do { \
+ if ((head) == NULL || (cmp(head, like)) >= 0) { \
+ (elt) = NULL; \
+ } else { \
+ for ((elt) = (head); (elt)->next != (head); (elt) = (elt)->next) { \
+ if ((cmp((elt)->next, like)) >= 0) { \
+ break; \
+ } \
+ } \
+ } \
} while (0)
#define CDL_DELETE(head,del) \
@@ -667,37 +931,37 @@ do {
#define CDL_DELETE2(head,del,prev,next) \
do { \
- if ( ((head)==(del)) && ((head)->next == (head))) { \
- (head) = 0L; \
+ if (((head)==(del)) && ((head)->next == (head))) { \
+ (head) = NULL; \
} else { \
(del)->next->prev = (del)->prev; \
(del)->prev->next = (del)->next; \
if ((del) == (head)) (head)=(del)->next; \
} \
-} while (0)
+} while (0)
#define CDL_COUNT(head,el,counter) \
CDL_COUNT2(head,el,counter,next) \
#define CDL_COUNT2(head, el, counter,next) \
-{ \
- counter = 0; \
- CDL_FOREACH2(head,el,next){ ++counter; } \
-}
+do { \
+ (counter) = 0; \
+ CDL_FOREACH2(head,el,next) { ++(counter); } \
+} while (0)
#define CDL_FOREACH(head,el) \
CDL_FOREACH2(head,el,next)
#define CDL_FOREACH2(head,el,next) \
- for(el=head;el;el=((el)->next==head ? 0L : (el)->next))
+ for ((el)=(head);el;(el)=(((el)->next==(head)) ? NULL : (el)->next))
#define CDL_FOREACH_SAFE(head,el,tmp1,tmp2) \
CDL_FOREACH_SAFE2(head,el,tmp1,tmp2,prev,next)
#define CDL_FOREACH_SAFE2(head,el,tmp1,tmp2,prev,next) \
- for((el)=(head), ((tmp1)=(head)?((head)->prev):NULL); \
- (el) && ((tmp2)=(el)->next, 1); \
- ((el) = (((el)==(tmp1)) ? 0L : (tmp2))))
+ for ((el) = (head), (tmp1) = (head) ? (head)->prev : NULL; \
+ (el) && ((tmp2) = (el)->next, 1); \
+ (el) = ((el) == (tmp1) ? NULL : (tmp2)))
#define CDL_SEARCH_SCALAR(head,out,field,val) \
CDL_SEARCH_SCALAR2(head,out,field,val,next)
@@ -707,7 +971,7 @@ do {
CDL_FOREACH2(head,out,next) { \
if ((out)->field == (val)) break; \
} \
-} while(0)
+} while (0)
#define CDL_SEARCH(head,out,elt,cmp) \
CDL_SEARCH2(head,out,elt,cmp,next)
@@ -717,13 +981,13 @@ do {
CDL_FOREACH2(head,out,next) { \
if ((cmp(out,elt))==0) break; \
} \
-} while(0)
+} while (0)
-#define CDL_REPLACE_ELEM(head, el, add) \
+#define CDL_REPLACE_ELEM2(head, el, add, prev, next) \
do { \
- assert(head != NULL); \
- assert(el != NULL); \
- assert(add != NULL); \
+ assert((head) != NULL); \
+ assert((el) != NULL); \
+ assert((add) != NULL); \
if ((el)->next == (el)) { \
(add)->next = (add); \
(add)->prev = (add); \
@@ -739,19 +1003,74 @@ do {
} \
} while (0)
+#define CDL_REPLACE_ELEM(head, el, add) \
+ CDL_REPLACE_ELEM2(head, el, add, prev, next)
+
+#define CDL_PREPEND_ELEM2(head, el, add, prev, next) \
+do { \
+ if (el) { \
+ assert((head) != NULL); \
+ assert((add) != NULL); \
+ (add)->next = (el); \
+ (add)->prev = (el)->prev; \
+ (el)->prev = (add); \
+ (add)->prev->next = (add); \
+ if ((head) == (el)) { \
+ (head) = (add); \
+ } \
+ } else { \
+ CDL_APPEND2(head, add, prev, next); \
+ } \
+} while (0)
+
#define CDL_PREPEND_ELEM(head, el, add) \
+ CDL_PREPEND_ELEM2(head, el, add, prev, next)
+
+#define CDL_APPEND_ELEM2(head, el, add, prev, next) \
do { \
- assert(head != NULL); \
- assert(el != NULL); \
- assert(add != NULL); \
- (add)->next = (el); \
- (add)->prev = (el)->prev; \
- (el)->prev = (add); \
- (add)->prev->next = (add); \
- if ((head) == (el)) { \
- (head) = (add); \
+ if (el) { \
+ assert((head) != NULL); \
+ assert((add) != NULL); \
+ (add)->next = (el)->next; \
+ (add)->prev = (el); \
+ (el)->next = (add); \
+ (add)->next->prev = (add); \
+ } else { \
+ CDL_PREPEND2(head, add, prev, next); \
} \
-} while (0) \
+} while (0)
-#endif /* UTLIST_H */
+#define CDL_APPEND_ELEM(head, el, add) \
+ CDL_APPEND_ELEM2(head, el, add, prev, next)
+
+#ifdef NO_DECLTYPE
+/* Here are VS2008 / NO_DECLTYPE replacements for a few functions */
+#undef CDL_INSERT_INORDER2
+#define CDL_INSERT_INORDER2(head,add,cmp,prev,next) \
+do { \
+ if ((head) == NULL) { \
+ (add)->prev = (add); \
+ (add)->next = (add); \
+ (head) = (add); \
+ } else if ((cmp(head, add)) >= 0) { \
+ (add)->prev = (head)->prev; \
+ (add)->next = (head); \
+ (add)->prev->next = (add); \
+ (head)->prev = (add); \
+ (head) = (add); \
+ } else { \
+ char *_tmp = (char*)(head); \
+ while ((char*)(head)->next != _tmp && (cmp((head)->next, add)) < 0) { \
+ (head) = (head)->next; \
+ } \
+ (add)->prev = (head); \
+ (add)->next = (head)->next; \
+ (add)->next->prev = (add); \
+ (head)->next = (add); \
+ UTLIST_RS(head); \
+ } \
+} while (0)
+#endif /* NO_DECLTYPE */
+
+#endif /* UTLIST_H */
diff --git a/contrib/libucl/utils/CMakeLists.txt b/contrib/libucl/utils/CMakeLists.txt
deleted file mode 100644
index 4de95fd7b4b0..000000000000
--- a/contrib/libucl/utils/CMakeLists.txt
+++ /dev/null
@@ -1,12 +0,0 @@
-
-PROJECT(libucl-utils C)
-
-FUNCTION(MAKE_UTIL UTIL_NAME UTIL_SRCS)
- ADD_EXECUTABLE(${UTIL_NAME} ${UTIL_SRCS})
- TARGET_LINK_LIBRARIES(${UTIL_NAME} ucl)
- INSTALL(TARGETS ${UTIL_NAME} DESTINATION bin)
-ENDFUNCTION()
-
-MAKE_UTIL(ucl_chargen chargen.c)
-MAKE_UTIL(ucl_objdump objdump.c)
-MAKE_UTIL(ucl_tool ucl-tool.c)
diff --git a/contrib/libucl/utils/Makefile.am b/contrib/libucl/utils/Makefile.am
deleted file mode 100644
index ec85aaa5e372..000000000000
--- a/contrib/libucl/utils/Makefile.am
+++ /dev/null
@@ -1,23 +0,0 @@
-common_utils_cflags = -I$(top_srcdir)/include \
- -I$(top_srcdir)/src \
- -I$(top_srcdir)/uthash
-common_utils_ldadd = $(top_builddir)/src/libucl.la
-
-ucl_chargen_SOURCES = chargen.c
-ucl_chargen_LDADD = $(common_utils_ldadd)
-ucl_chargen_CFLAGS = $(common_utils_cflags)
-
-ucl_objdump_SOURCES = objdump.c
-ucl_objdump_LDADD = $(common_utils_ldadd)
-ucl_objdump_CFLAGS = $(common_utils_cflags)
-
-ucl_tool_SOURCES = ucl-tool.c
-ucl_tool_LDADD = $(common_utils_ldadd)
-ucl_tool_CFLAGS = $(common_utils_cflags)
-
-if UTILS
-UTL = ucl_chargen ucl_objdump ucl_tool
-else
-UTL =
-endif
-bin_PROGRAMS = $(UTL)
diff --git a/contrib/libucl/utils/chargen.c b/contrib/libucl/utils/chargen.c
deleted file mode 100644
index 398134054c21..000000000000
--- a/contrib/libucl/utils/chargen.c
+++ /dev/null
@@ -1,128 +0,0 @@
-/* Copyright (c) 2013, Vsevolod Stakhov
- * All rights reserved.
- *
- * Redistribution and use in source and binary forms, with or without
- * modification, are permitted provided that the following conditions are met:
- * * Redistributions of source code must retain the above copyright
- * notice, this list of conditions and the following disclaimer.
- * * Redistributions in binary form must reproduce the above copyright
- * notice, this list of conditions and the following disclaimer in the
- * documentation and/or other materials provided with the distribution.
- *
- * THIS SOFTWARE IS PROVIDED ''AS IS'' AND ANY
- * EXPRESS OR IMPLIED WARRANTIES, INCLUDING, BUT NOT LIMITED TO, THE IMPLIED
- * WARRANTIES OF MERCHANTABILITY AND FITNESS FOR A PARTICULAR PURPOSE ARE
- * DISCLAIMED. IN NO EVENT SHALL AUTHOR BE LIABLE FOR ANY
- * DIRECT, INDIRECT, INCIDENTAL, SPECIAL, EXEMPLARY, OR CONSEQUENTIAL DAMAGES
- * (INCLUDING, BUT NOT LIMITED TO, PROCUREMENT OF SUBSTITUTE GOODS OR SERVICES;
- * LOSS OF USE, DATA, OR PROFITS; OR BUSINESS INTERRUPTION) HOWEVER CAUSED AND
- * ON ANY THEORY OF LIABILITY, WHETHER IN CONTRACT, STRICT LIABILITY, OR TORT
- * (INCLUDING NEGLIGENCE OR OTHERWISE) ARISING IN ANY WAY OUT OF THE USE OF THIS
- * SOFTWARE, EVEN IF ADVISED OF THE POSSIBILITY OF SUCH DAMAGE.
- */
-
-/**
- * @file this utility generates character table for ucl
- */
-
-#include <stdio.h>
-#include <ctype.h>
-#include <stdbool.h>
-
-static inline int
-print_flag (const char *flag, bool *need_or, char *val)
-{
- int res;
- res = sprintf (val, "%s%s", *need_or ? "|" : "", flag);
-
- *need_or |= true;
-
- return res;
-}
-
-int
-main (int argc, char **argv)
-{
- int i, col, r;
- const char *name = "ucl_chartable";
- bool need_or;
- char valbuf[2048];
-
- col = 0;
-
- if (argc > 1) {
- name = argv[1];
- }
-
- printf ("static const unsigned int %s[256] = {\n", name);
-
- for (i = 0; i < 256; i ++) {
- need_or = false;
- r = 0;
- /* UCL_CHARACTER_VALUE_END */
-
- if (i == ' ' || i == '\t') {
- r += print_flag ("UCL_CHARACTER_WHITESPACE", &need_or, valbuf + r);
- }
- if (isspace (i)) {
- r += print_flag ("UCL_CHARACTER_WHITESPACE_UNSAFE", &need_or, valbuf + r);
- }
- if (isalnum (i) || i >= 0x80 || i == '/' || i == '_') {
- r += print_flag ("UCL_CHARACTER_KEY_START", &need_or, valbuf + r);
- }
- if (isalnum (i) || i == '-' || i == '_' || i == '/' || i == '.' || i >= 0x80) {
- r += print_flag ("UCL_CHARACTER_KEY", &need_or, valbuf + r);
- }
- if (i == 0 || i == '\r' || i == '\n' || i == ']' || i == '}' || i == ';' || i == ',' || i == '#') {
- r += print_flag ("UCL_CHARACTER_VALUE_END", &need_or, valbuf + r);
- }
- else {
- if (isprint (i) || i >= 0x80) {
- r += print_flag ("UCL_CHARACTER_VALUE_STR", &need_or, valbuf + r);
- }
- if (isdigit (i) || i == '-') {
- r += print_flag ("UCL_CHARACTER_VALUE_DIGIT_START", &need_or, valbuf + r);
- }
- if (isalnum (i) || i == '.' || i == '-' || i == '+') {
- r += print_flag ("UCL_CHARACTER_VALUE_DIGIT", &need_or, valbuf + r);
- }
- }
- if (i == '"' || i == '\\' || i == '/' || i == 'b' ||
- i == 'f' || i == 'n' || i == 'r' || i == 't' || i == 'u') {
- r += print_flag ("UCL_CHARACTER_ESCAPE", &need_or, valbuf + r);
- }
- if (i == ' ' || i == '\t' || i == ':' || i == '=') {
- r += print_flag ("UCL_CHARACTER_KEY_SEP", &need_or, valbuf + r);
- }
- if (i == '\n' || i == '\r' || i == '\\' || i == '\b' || i == '\t' ||
- i == '"' || i == '\f') {
- r += print_flag ("UCL_CHARACTER_JSON_UNSAFE", &need_or, valbuf + r);
- }
- if (i == '\n' || i == '\r' || i == '\\' || i == '\b' || i == '\t' ||
- i == '"' || i == '\f' || i == '=' || i == ':' || i == '{' || i == '[' || i == ' ') {
- r += print_flag ("UCL_CHARACTER_UCL_UNSAFE", &need_or, valbuf + r);
- }
-
- if (!need_or) {
- r += print_flag ("UCL_CHARACTER_DENIED", &need_or, valbuf + r);
- }
-
- if (isprint (i)) {
- r += sprintf (valbuf + r, " /* %c */", i);
- }
- if (i != 255) {
- r += sprintf (valbuf + r, ", ");
- }
- col += r;
- if (col > 80) {
- printf ("\n%s", valbuf);
- col = r;
- }
- else {
- printf ("%s", valbuf);
- }
- }
- printf ("\n}\n");
-
- return 0;
-}
diff --git a/contrib/libucl/utils/objdump.c b/contrib/libucl/utils/objdump.c
deleted file mode 100644
index 416eca7c87e0..000000000000
--- a/contrib/libucl/utils/objdump.c
+++ /dev/null
@@ -1,185 +0,0 @@
-/* Copyright (c) 2013, Dmitriy V. Reshetnikov
- * Copyright (c) 2013, Vsevolod Stakhov
- * All rights reserved.
- *
- * Redistribution and use in source and binary forms, with or without
- * modification, are permitted provided that the following conditions are met:
- * * Redistributions of source code must retain the above copyright
- * notice, this list of conditions and the following disclaimer.
- * * Redistributions in binary form must reproduce the above copyright
- * notice, this list of conditions and the following disclaimer in the
- * documentation and/or other materials provided with the distribution.
- *
- * THIS SOFTWARE IS PROVIDED ''AS IS'' AND ANY
- * EXPRESS OR IMPLIED WARRANTIES, INCLUDING, BUT NOT LIMITED TO, THE IMPLIED
- * WARRANTIES OF MERCHANTABILITY AND FITNESS FOR A PARTICULAR PURPOSE ARE
- * DISCLAIMED. IN NO EVENT SHALL AUTHOR BE LIABLE FOR ANY
- * DIRECT, INDIRECT, INCIDENTAL, SPECIAL, EXEMPLARY, OR CONSEQUENTIAL DAMAGES
- * (INCLUDING, BUT NOT LIMITED TO, PROCUREMENT OF SUBSTITUTE GOODS OR SERVICES;
- * LOSS OF USE, DATA, OR PROFITS; OR BUSINESS INTERRUPTION) HOWEVER CAUSED AND
- * ON ANY THEORY OF LIABILITY, WHETHER IN CONTRACT, STRICT LIABILITY, OR TORT
- * (INCLUDING NEGLIGENCE OR OTHERWISE) ARISING IN ANY WAY OUT OF THE USE OF THIS
- * SOFTWARE, EVEN IF ADVISED OF THE POSSIBILITY OF SUCH DAMAGE.
- */
-
-#if defined(_MSC_VER)
- #include <BaseTsd.h>
-
- typedef SSIZE_T ssize_t;
-#endif
-
-#include "ucl.h"
-
-void
-ucl_obj_dump (const ucl_object_t *obj, unsigned int shift)
-{
- int num = shift * 4 + 5;
- char *pre = (char *) malloc (num * sizeof(char));
- const ucl_object_t *cur, *tmp;
- ucl_object_iter_t it = NULL, it_obj = NULL;
-
- pre[--num] = 0x00;
- while (num--)
- pre[num] = 0x20;
-
- tmp = obj;
-
- while ((obj = ucl_object_iterate (tmp, &it, false))) {
- printf ("%sucl object address: %p\n", pre + 4, obj);
- if (obj->key != NULL) {
- printf ("%skey: \"%s\"\n", pre, ucl_object_key (obj));
- }
- printf ("%sref: %u\n", pre, obj->ref);
- printf ("%slen: %u\n", pre, obj->len);
- printf ("%sprev: %p\n", pre, obj->prev);
- printf ("%snext: %p\n", pre, obj->next);
- if (obj->type == UCL_OBJECT) {
- printf ("%stype: UCL_OBJECT\n", pre);
- printf ("%svalue: %p\n", pre, obj->value.ov);
- it_obj = NULL;
- while ((cur = ucl_object_iterate (obj, &it_obj, true))) {
- ucl_obj_dump (cur, shift + 2);
- }
- }
- else if (obj->type == UCL_ARRAY) {
- printf ("%stype: UCL_ARRAY\n", pre);
- printf ("%svalue: %p\n", pre, obj->value.av);
- it_obj = NULL;
- while ((cur = ucl_object_iterate (obj, &it_obj, true))) {
- ucl_obj_dump (cur, shift + 2);
- }
- }
- else if (obj->type == UCL_INT) {
- printf ("%stype: UCL_INT\n", pre);
- printf ("%svalue: %jd\n", pre, (intmax_t)ucl_object_toint (obj));
- }
- else if (obj->type == UCL_FLOAT) {
- printf ("%stype: UCL_FLOAT\n", pre);
- printf ("%svalue: %f\n", pre, ucl_object_todouble (obj));
- }
- else if (obj->type == UCL_STRING) {
- printf ("%stype: UCL_STRING\n", pre);
- printf ("%svalue: \"%s\"\n", pre, ucl_object_tostring (obj));
- }
- else if (obj->type == UCL_BOOLEAN) {
- printf ("%stype: UCL_BOOLEAN\n", pre);
- printf ("%svalue: %s\n", pre, ucl_object_tostring_forced (obj));
- }
- else if (obj->type == UCL_TIME) {
- printf ("%stype: UCL_TIME\n", pre);
- printf ("%svalue: %f\n", pre, ucl_object_todouble (obj));
- }
- else if (obj->type == UCL_USERDATA) {
- printf ("%stype: UCL_USERDATA\n", pre);
- printf ("%svalue: %p\n", pre, obj->value.ud);
- }
- }
-
- free (pre);
-}
-
-int
-main(int argc, char **argv)
-{
- const char *fn = NULL;
- unsigned char *inbuf;
- struct ucl_parser *parser;
- int k, ret = 0;
- ssize_t bufsize, r = 0;
- ucl_object_t *obj = NULL;
- const ucl_object_t *par;
- FILE *in;
-
- if (argc > 1) {
- fn = argv[1];
- }
-
- if (fn != NULL) {
- in = fopen (fn, "r");
- if (in == NULL) {
- exit (EXIT_FAILURE);
- }
- }
- else {
- in = stdin;
- }
-
- parser = ucl_parser_new (0);
- inbuf = malloc (BUFSIZ);
- bufsize = BUFSIZ;
- r = 0;
-
- while (!feof (in) && !ferror (in)) {
- if (r == bufsize) {
- inbuf = realloc (inbuf, bufsize * 2);
- bufsize *= 2;
- if (inbuf == NULL) {
- perror ("realloc");
- exit (EXIT_FAILURE);
- }
- }
- r += fread (inbuf + r, 1, bufsize - r, in);
- }
-
- if (ferror (in)) {
- fprintf (stderr, "Failed to read the input file.\n");
- exit (EXIT_FAILURE);
- }
-
- ucl_parser_add_chunk (parser, inbuf, r);
- fclose (in);
- if (ucl_parser_get_error(parser)) {
- printf ("Error occurred: %s\n", ucl_parser_get_error(parser));
- ret = 1;
- goto end;
- }
-
- obj = ucl_parser_get_object (parser);
- if (ucl_parser_get_error (parser)) {
- printf ("Error occurred: %s\n", ucl_parser_get_error(parser));
- ret = 1;
- goto end;
- }
-
- if (argc > 2) {
- for (k = 2; k < argc; k++) {
- printf ("search for \"%s\"... ", argv[k]);
- par = ucl_object_lookup (obj, argv[k]);
- printf ("%sfound\n", (par == NULL )?"not ":"");
- ucl_obj_dump (par, 0);
- }
- }
- else {
- ucl_obj_dump (obj, 0);
- }
-
-end:
- if (parser != NULL) {
- ucl_parser_free (parser);
- }
- if (obj != NULL) {
- ucl_object_unref (obj);
- }
-
- return ret;
-}
diff --git a/contrib/libucl/utils/ucl-tool.c b/contrib/libucl/utils/ucl-tool.c
deleted file mode 100644
index 9b807d35c092..000000000000
--- a/contrib/libucl/utils/ucl-tool.c
+++ /dev/null
@@ -1,170 +0,0 @@
-/* Copyright (c) 2015, Cesanta Software
- *
- * Redistribution and use in source and binary forms, with or without
- * modification, are permitted provided that the following conditions are met:
- * * Redistributions of source code must retain the above copyright
- * notice, this list of conditions and the following disclaimer.
- * * Redistributions in binary form must reproduce the above copyright
- * notice, this list of conditions and the following disclaimer in the
- * documentation and/or other materials provided with the distribution.
- *
- * THIS SOFTWARE IS PROVIDED ''AS IS'' AND ANY
- * EXPRESS OR IMPLIED WARRANTIES, INCLUDING, BUT NOT LIMITED TO, THE IMPLIED
- * WARRANTIES OF MERCHANTABILITY AND FITNESS FOR A PARTICULAR PURPOSE ARE
- * DISCLAIMED. IN NO EVENT SHALL AUTHOR BE LIABLE FOR ANY
- * DIRECT, INDIRECT, INCIDENTAL, SPECIAL, EXEMPLARY, OR CONSEQUENTIAL DAMAGES
- * (INCLUDING, BUT NOT LIMITED TO, PROCUREMENT OF SUBSTITUTE GOODS OR SERVICES;
- * LOSS OF USE, DATA, OR PROFITS; OR BUSINESS INTERRUPTION) HOWEVER CAUSED AND
- * ON ANY THEORY OF LIABILITY, WHETHER IN CONTRACT, STRICT LIABILITY, OR TORT
- * (INCLUDING NEGLIGENCE OR OTHERWISE) ARISING IN ANY WAY OUT OF THE USE OF THIS
- * SOFTWARE, EVEN IF ADVISED OF THE POSSIBILITY OF SUCH DAMAGE.
- */
-
-#include "ucl.h"
-
-void usage(const char *name, FILE *out) {
- fprintf(out, "Usage: %s [--help] [-i|--in file] [-o|--out file]\n", name);
- fprintf(out, " [-s|--schema file] [-f|--format format]\n\n");
- fprintf(out, " --help - print this message and exit\n");
- fprintf(out, " --in - specify input filename "
- "(default: standard input)\n");
- fprintf(out, " --out - specify output filename "
- "(default: standard output)\n");
- fprintf(out, " --schema - specify schema file for validation\n");
- fprintf(out, " --format - output format. Options: ucl (default), "
- "json, compact_json, yaml, msgpack\n");
-}
-
-int main(int argc, char **argv) {
- int i;
- char ch;
- FILE *in = stdin, *out = stdout;
- const char *schema = NULL, *parm, *val;
- unsigned char *buf = NULL;
- size_t size = 0, r = 0;
- struct ucl_parser *parser = NULL;
- ucl_object_t *obj = NULL;
- ucl_emitter_t emitter = UCL_EMIT_CONFIG;
-
- for (i = 1; i < argc; ++i) {
- parm = argv[i];
- val = ((i + 1) < argc) ? argv[++i] : NULL;
-
- if ((strcmp(parm, "--help") == 0) || (strcmp(parm, "-h") == 0)) {
- usage(argv[0], stdout);
- exit(0);
-
- } else if ((strcmp(parm, "--in") == 0) || (strcmp(parm, "-i") == 0)) {
- if (!val)
- goto err_val;
-
- in = fopen(val, "r");
- if (in == NULL) {
- perror("fopen on input file");
- exit(EXIT_FAILURE);
- }
- } else if ((strcmp(parm, "--out") == 0) || (strcmp(parm, "-o") == 0)) {
- if (!val)
- goto err_val;
-
- out = fopen(val, "w");
- if (out == NULL) {
- perror("fopen on output file");
- exit(EXIT_FAILURE);
- }
- } else if ((strcmp(parm, "--schema") == 0) || (strcmp(parm, "-s") == 0)) {
- if (!val)
- goto err_val;
- schema = val;
-
- } else if ((strcmp(parm, "--format") == 0) || (strcmp(parm, "-f") == 0)) {
- if (!val)
- goto err_val;
-
- if (strcmp(val, "ucl") == 0) {
- emitter = UCL_EMIT_CONFIG;
- } else if (strcmp(val, "json") == 0) {
- emitter = UCL_EMIT_JSON;
- } else if (strcmp(val, "yaml") == 0) {
- emitter = UCL_EMIT_YAML;
- } else if (strcmp(val, "compact_json") == 0) {
- emitter = UCL_EMIT_JSON_COMPACT;
- } else if (strcmp(val, "msgpack") == 0) {
- emitter = UCL_EMIT_MSGPACK;
- } else {
- fprintf(stderr, "Unknown output format: %s\n", val);
- exit(EXIT_FAILURE);
- }
- } else {
- usage(argv[0], stderr);
- exit(EXIT_FAILURE);
- }
- }
-
- parser = ucl_parser_new(0);
- buf = malloc(BUFSIZ);
- size = BUFSIZ;
- while (!feof(in) && !ferror(in)) {
- if (r == size) {
- buf = realloc(buf, size*2);
- size *= 2;
- if (buf == NULL) {
- perror("realloc");
- exit(EXIT_FAILURE);
- }
- }
- r += fread(buf + r, 1, size - r, in);
- }
- if (ferror(in)) {
- fprintf(stderr, "Failed to read the input file.\n");
- exit(EXIT_FAILURE);
- }
- fclose(in);
- if (!ucl_parser_add_chunk(parser, buf, r)) {
- fprintf(stderr, "Failed to parse input file: %s\n",
- ucl_parser_get_error(parser));
- exit(EXIT_FAILURE);
- }
- if ((obj = ucl_parser_get_object(parser)) == NULL) {
- fprintf(stderr, "Failed to get root object: %s\n",
- ucl_parser_get_error(parser));
- exit(EXIT_FAILURE);
- }
- if (schema != NULL) {
- struct ucl_parser *schema_parser = ucl_parser_new(0);
- ucl_object_t *schema_obj = NULL;
- struct ucl_schema_error error;
-
- if (!ucl_parser_add_file(schema_parser, schema)) {
- fprintf(stderr, "Failed to parse schema file: %s\n",
- ucl_parser_get_error(schema_parser));
- exit(EXIT_FAILURE);
- }
- if ((schema_obj = ucl_parser_get_object(schema_parser)) == NULL) {
- fprintf(stderr, "Failed to get root object: %s\n",
- ucl_parser_get_error(schema_parser));
- exit(EXIT_FAILURE);
- }
- if (!ucl_object_validate(schema_obj, obj, &error)) {
- fprintf(stderr, "Validation failed: %s\n", error.msg);
- exit(EXIT_FAILURE);
- }
- }
-
- if (emitter != UCL_EMIT_MSGPACK) {
- fprintf(out, "%s\n", ucl_object_emit(obj, emitter));
- } else {
- size_t len;
- unsigned char *res;
-
- res = ucl_object_emit_len(obj, emitter, &len);
- fwrite(res, 1, len, out);
- }
-
- return 0;
-
-err_val:
- fprintf(stderr, "Parameter %s is missing mandatory value\n", parm);
- usage(argv[0], stderr);
- exit(EXIT_FAILURE);
-}
diff --git a/contrib/llvm-project/llvm/lib/ObjCopy/ELF/ELFObjcopy.cpp b/contrib/llvm-project/llvm/lib/ObjCopy/ELF/ELFObjcopy.cpp
index 075455c03415..7de9b4dd2ea1 100644
--- a/contrib/llvm-project/llvm/lib/ObjCopy/ELF/ELFObjcopy.cpp
+++ b/contrib/llvm-project/llvm/lib/ObjCopy/ELF/ELFObjcopy.cpp
@@ -368,7 +368,7 @@ static Error updateAndRemoveSymbols(const CommonConfig &Config,
// (like GroupSection or RelocationSection). This way, we know which
// symbols are still 'needed' and which are not.
if (Config.StripUnneeded || !Config.UnneededSymbolsToRemove.empty() ||
- !Config.OnlySection.empty()) {
+ !Config.OnlySection.empty() || Config.DiscardMode != DiscardType::None) {
for (SectionBase &Sec : Obj.sections())
Sec.markSymbols();
}
@@ -390,22 +390,23 @@ static Error updateAndRemoveSymbols(const CommonConfig &Config,
if (Config.StripDebug && Sym.Type == STT_FILE)
return true;
- if ((Config.DiscardMode == DiscardType::All ||
- (Config.DiscardMode == DiscardType::Locals &&
- StringRef(Sym.Name).starts_with(".L"))) &&
- Sym.Binding == STB_LOCAL && Sym.getShndx() != SHN_UNDEF &&
- Sym.Type != STT_FILE && Sym.Type != STT_SECTION)
- return true;
-
if ((Config.StripUnneeded ||
Config.UnneededSymbolsToRemove.matches(Sym.Name)) &&
(!Obj.isRelocatable() || isUnneededSymbol(Sym)))
return true;
- // We want to remove undefined symbols if all references have been stripped.
- if (!Config.OnlySection.empty() && !Sym.Referenced &&
- Sym.getShndx() == SHN_UNDEF)
- return true;
+ if (!Sym.Referenced) {
+ if ((Config.DiscardMode == DiscardType::All ||
+ (Config.DiscardMode == DiscardType::Locals &&
+ StringRef(Sym.Name).starts_with(".L"))) &&
+ Sym.Binding == STB_LOCAL && Sym.getShndx() != SHN_UNDEF &&
+ Sym.Type != STT_FILE && Sym.Type != STT_SECTION)
+ return true;
+ // We want to remove undefined symbols if all references have been
+ // stripped.
+ if (!Config.OnlySection.empty() && Sym.getShndx() == SHN_UNDEF)
+ return true;
+ }
return false;
};
diff --git a/contrib/llvm-project/llvm/lib/Target/PowerPC/PPCMergeStringPool.cpp b/contrib/llvm-project/llvm/lib/Target/PowerPC/PPCMergeStringPool.cpp
index 309938accdf4..daf6a0e65d54 100644
--- a/contrib/llvm-project/llvm/lib/Target/PowerPC/PPCMergeStringPool.cpp
+++ b/contrib/llvm-project/llvm/lib/Target/PowerPC/PPCMergeStringPool.cpp
@@ -170,8 +170,9 @@ void PPCMergeStringPool::collectCandidateConstants(Module &M) {
LLVM_DEBUG(dbgs() << "hasInitializer() " << Global.hasInitializer()
<< "\n");
- // We can only pool constants.
- if (!Global.isConstant() || !Global.hasInitializer())
+ // We can only pool non-thread-local constants.
+ if (!Global.isConstant() || !Global.hasInitializer() ||
+ Global.isThreadLocal())
continue;
// If a global constant has a section we do not try to pool it because
diff --git a/contrib/tzcode/Makefile b/contrib/tzcode/Makefile
index 0087b4596515..2130582c2deb 100644
--- a/contrib/tzcode/Makefile
+++ b/contrib/tzcode/Makefile
@@ -137,7 +137,7 @@ TIME_T_ALTERNATIVES_TAIL = int_least32_t.ck uint_least32_t.ck \
uint_least64_t.ck
# What kind of TZif data files to generate. (TZif is the binary time
-# zone data format that zic generates; see Internet RFC 8536.)
+# zone data format that zic generates; see Internet RFC 9636.)
# If you want only POSIX time, with time values interpreted as
# seconds since the epoch (not counting leap seconds), use
# REDO= posix_only
@@ -255,6 +255,7 @@ LDLIBS=
# -DHAVE_UNISTD_H=0 if <unistd.h> does not work*
# -DHAVE_UTMPX_H=0 if <utmpx.h> does not work*
# -Dlocale_t=XXX if your system uses XXX instead of locale_t
+# -DMKTIME_MIGHT_OVERFLOW if mktime might fail due to time_t overflow
# -DPORT_TO_C89 if tzcode should also run on mostly-C89 platforms+
# Typically it is better to use a later standard. For example,
# with GCC 4.9.4 (2016), prefer '-std=gnu11' to '-DPORT_TO_C89'.
@@ -262,7 +263,7 @@ LDLIBS=
# feature (integers at least 64 bits wide) and maybe more.
# -DRESERVE_STD_EXT_IDS if your platform reserves standard identifiers
# with external linkage, e.g., applications cannot define 'localtime'.
-# -Dssize_t=long on hosts like MS-Windows that lack ssize_t
+# -Dssize_t=int on hosts like MS-Windows that lack ssize_t
# -DSUPPORT_C89=0 if the tzcode library should not support C89 callers
# Although -DSUPPORT_C89=0 might work around latent bugs in callers,
# it does not conform to POSIX.
@@ -285,7 +286,7 @@ LDLIBS=
# This mishandles some past timestamps, as US DST rules have changed.
# It also mishandles settings like TZ='EET-2EEST' for eastern Europe,
# as Europe and US DST rules differ.
-# -DTZNAME_MAXIMUM=N to limit time zone abbreviations to N bytes (default 255)
+# -DTZNAME_MAXIMUM=N to limit time zone abbreviations to N bytes (default 254)
# -DUNINIT_TRAP if reading uninitialized storage can cause problems
# other than simply getting garbage data
# -DUSE_LTZ=0 to build zdump with the system time zone library
@@ -319,7 +320,8 @@ GCC_DEBUG_FLAGS = -DGCC_LINT -g3 -O3 \
$(GCC_INSTRUMENT) \
-Wall -Wextra \
-Walloc-size-larger-than=100000 -Warray-bounds=2 \
- -Wbad-function-cast -Wbidi-chars=any,ucn -Wcast-align=strict -Wdate-time \
+ -Wbad-function-cast -Wbidi-chars=any,ucn -Wcast-align=strict -Wcast-qual \
+ -Wdate-time \
-Wdeclaration-after-statement -Wdouble-promotion \
-Wduplicated-branches -Wduplicated-cond -Wflex-array-member-not-at-end \
-Wformat=2 -Wformat-overflow=2 -Wformat-signedness -Wformat-truncation \
@@ -336,7 +338,7 @@ GCC_DEBUG_FLAGS = -DGCC_LINT -g3 -O3 \
-Wsuggest-attribute=noreturn -Wsuggest-attribute=pure \
-Wtrampolines -Wundef -Wunused-macros -Wuse-after-free=3 \
-Wvariadic-macros -Wvla -Wwrite-strings \
- -Wno-format-nonliteral -Wno-sign-compare
+ -Wno-format-nonliteral -Wno-sign-compare -Wno-type-limits
#
# If your system has a "GMT offset" field in its "struct tm"s
# (or if you decide to add such a field in your system's "time.h" file),
@@ -614,8 +616,8 @@ TZS_YEAR= 2050
TZS_CUTOFF_FLAG= -c $(TZS_YEAR)
TZS= to$(TZS_YEAR).tzs
TZS_NEW= to$(TZS_YEAR)new.tzs
-TZS_DEPS= $(YDATA) asctime.c localtime.c \
- private.h tzfile.h zdump.c zic.c
+TZS_DEPS= $(YDATA) localtime.c private.h \
+ strftime.c tzfile.h zdump.c zic.c
TZDATA_DIST = $(COMMON) $(DATA) $(MISC)
# EIGHT_YARDS is just a yard short of the whole ENCHILADA.
EIGHT_YARDS = $(TZDATA_DIST) $(DOCS) $(SOURCES) tzdata.zi
@@ -855,10 +857,10 @@ tzselect: tzselect.ksh version
chmod +x $@.out
mv $@.out $@
-check: check_mild back.ck
+check: check_mild back.ck now.ck
check_mild: check_web check_zishrink \
character-set.ck white-space.ck links.ck mainguard.ck \
- name-lengths.ck now.ck slashed-abbrs.ck sorted.ck \
+ name-lengths.ck slashed-abbrs.ck sorted.ck \
tables.ck ziguard.ck tzs.ck
# True if UTF8_LOCALE does not work;
@@ -1103,7 +1105,7 @@ set-timestamps.out: $(EIGHT_YARDS)
touch -md @1 test.out; then \
rm -f test.out && \
for file in $$files; do \
- if git diff --quiet $$file; then \
+ if git diff --quiet HEAD $$file; then \
time=$$(TZ=UTC0 git log -1 \
--format='tformat:%cd' \
--date='format:%Y-%m-%dT%H:%M:%SZ' \
@@ -1354,13 +1356,13 @@ long-long.ck unsigned.ck: $(VERSION_DEPS)
zonenames: tzdata.zi
@$(AWK) '/^Z/ { print $$2 } /^L/ { print $$3 }' tzdata.zi
-asctime.o: private.h tzfile.h
+asctime.o: private.h
date.o: private.h
difftime.o: private.h
-localtime.o: private.h tzfile.h tzdir.h
-strftime.o: private.h tzfile.h
-zdump.o: version.h
-zic.o: private.h tzfile.h tzdir.h version.h
+localtime.o: private.h tzdir.h tzfile.h
+strftime.o: localtime.c private.h tzdir.h tzfile.h
+zdump.o: private.h version.h
+zic.o: private.h tzdir.h tzfile.h version.h
.PHONY: ALL INSTALL all
.PHONY: check check_mild check_time_t_alternatives
diff --git a/contrib/tzcode/NEWS b/contrib/tzcode/NEWS
index 83b8b8c8d39c..8c0771641ef0 100644
--- a/contrib/tzcode/NEWS
+++ b/contrib/tzcode/NEWS
@@ -1,5 +1,108 @@
News for the tz database
+Release 2025b - 2025-03-22 13:40:46 -0700
+
+ Briefly:
+ New zone for Aysén Region in Chile which moves from -04/-03 to -03.
+
+ Changes to future timestamps
+
+ Chile's Aysén Region moves from -04/-03 to -03 year-round, joining
+ Magallanes Region. The region will not change its clocks on
+ 2025-04-05 at 24:00, diverging from America/Santiago and creating a
+ new zone America/Coyhaique. (Thanks to Yonathan Dossow.) Model
+ this as a change to standard offset effective 2025-03-20.
+
+ Changes to past timestamps
+
+ Iran switched from +04 to +0330 on 1978-11-10 at 24:00, not at
+ year end. (Thanks to Roozbeh Pournader.)
+
+ Changes to code
+
+ 'zic -l TIMEZONE -d . -l /some/other/file/system' no longer
+ attempts to create an incorrect symlink, and no longer has a
+ read buffer underflow. (Problem reported by Evgeniy Gorbanev.)
+
+
+Release 2025a - 2025-01-15 10:47:24 -0800
+
+ Briefly:
+ Paraguay adopted permanent -03 starting spring 2024.
+ Improve pre-1991 data for the Philippines.
+ Etc/Unknown is now reserved.
+
+ Changes to future timestamps
+
+ Paraguay stopped changing its clocks after the spring-forward
+ transition on 2024-10-06, so it is now permanently at -03.
+ (Thanks to Heitor David Pinto and Even Scharning.)
+ This affects timestamps starting 2025-03-22, as well as the
+ obsolescent tm_isdst flags starting 2024-10-15.
+
+ Changes to past timestamps
+
+ Correct timestamps for the Philippines before 1900, and from 1937
+ through 1990. (Thanks to P Chan for the heads-up and citations.)
+ This includes adjusting local mean time before 1899; fixing
+ transitions in September 1899, January 1937, and June 1954; adding
+ transitions in December 1941, November 1945, March and September
+ 1977, and May and July 1990; and removing incorrect transitions in
+ March and September 1978.
+
+ Changes to data
+
+ Add zone1970.tab lines for the Concordia and Eyre Bird Observatory
+ research stations. (Thanks to Derick Rethans and Jule Dabars.)
+
+ Changes to code
+
+ strftime %s now generates the correct numeric string even when the
+ represented number does not fit into time_t. This is better than
+ generating the numeric equivalent of (time_t) -1, as strftime did
+ in TZDB releases 96a (when %s was introduced) through 2020a and in
+ releases 2022b through 2024b. It is also better than failing and
+ returning 0, as strftime did in releases 2020b through 2022a.
+
+ strftime now outputs an invalid conversion specifier as-is,
+ instead of eliding the leading '%', which confused debugging.
+
+ An invalid TZ now generates the time zone abbreviation "-00", not
+ "UTC", to help the user see that an error has occurred. (Thanks
+ to Arthur David Olson for suggesting a "wrong result".)
+
+ mktime and timeoff no longer incorrectly fail merely because a
+ struct tm component near INT_MIN or INT_MAX overflows when a
+ lower-order component carries into it.
+
+ TZNAME_MAXIMUM, the maximum number of bytes in a proleptic TZ
+ string's time zone abbreviation, now defaults to 254 not 255.
+ This helps reduce the size of internal state from 25480 to 21384
+ on common platforms. This change should not be a problem, as
+ nobody uses such long "abbreviations" and the longstanding tzcode
+ maximum was 16 until release 2023a. For those who prefer no
+ arbitrary limits, you can now specify TZNAME_MAXIMUM values up to
+ PTRDIFF_MAX, a limit forced by C anyway; formerly tzcode silently
+ misbehaved unless TZNAME_MAXIMUM was less than INT_MAX.
+
+ tzset and related functions no longer leak a file descriptor if
+ another thread forks or execs at about the same time and if the
+ platform has O_CLOFORK and O_CLOEXEC respectively. Also, the
+ functions no longer let a TZif file become a controlling terminal.
+
+ 'zdump -' now reads TZif data from /dev/stdin.
+ (From a question by Arthur David Olson.)
+
+ Changes to documentation
+
+ The name Etc/Unknown is now reserved: it will not be used by TZDB.
+ This is for compatibility with CLDR, which uses the string
+ "Etc/Unknown" for an unknown or invalid timezone. (Thanks to
+ Justin Grant, Mark Davis, and Guy Harris.)
+
+ Cite Internet RFC 9636, which obsoletes RFC 8536 for TZif format.
+
+
Release 2024b - 2024-09-04 12:27:47 -0700
Briefly:
@@ -116,7 +219,7 @@ Release 2024b - 2024-09-04 12:27:47 -0700
Changes to commentary
Commentary about historical transitions in Portugal and her former
- colonies has been expanded with links to many relevant legislation.
+ colonies has been expanded with links to relevant legislation.
(Thanks to Tim Parenti.)
@@ -204,10 +307,10 @@ Release 2023d - 2023-12-21 20:02:24 -0800
changing its time zone from -01/+00 to -02/-01 at the same moment
as the spring-forward transition. Its clocks will therefore not
spring forward as previously scheduled. The time zone change
- reverts to its common practice before 1981.
+ reverts to its common practice before 1981. (Thanks to Jule Dabars.)
Fix predictions for DST transitions in Palestine in 2072-2075,
- correcting a typo introduced in 2023a.
+ correcting a typo introduced in 2023a. (Thanks to Jule Dabars.)
Changes to past and future timestamps
diff --git a/contrib/tzcode/asctime.c b/contrib/tzcode/asctime.c
index ebb90a1cc84d..1977a2272896 100644
--- a/contrib/tzcode/asctime.c
+++ b/contrib/tzcode/asctime.c
@@ -7,6 +7,7 @@
/*
** Avoid the temptation to punt entirely to strftime;
+** strftime can behave badly when tm components are out of range, and
** the output of strftime is supposed to be locale specific
** whereas the output of asctime is supposed to be constant.
*/
@@ -18,27 +19,6 @@
#include "un-namespace.h"
#include <stdio.h>
-/*
-** All years associated with 32-bit time_t values are exactly four digits long;
-** some years associated with 64-bit time_t values are not.
-** Vintage programs are coded for years that are always four digits long
-** and may assume that the newline always lands in the same place.
-** For years that are less than four digits, we pad the output with
-** leading zeroes to get the newline in the traditional place.
-** The -4 ensures that we get four characters of output even if
-** we call a strftime variant that produces fewer characters for some years.
-** This conforms to recent ISO C and POSIX standards, which say behavior
-** is undefined when the year is less than 1000 or greater than 9999.
-*/
-static char const ASCTIME_FMT[] = "%s %s%3d %.2d:%.2d:%.2d %-4s\n";
-/*
-** For years that are more than four digits we put extra spaces before the year
-** so that code trying to overwrite the newline won't end up overwriting
-** a digit within a year and truncating the year (operating on the assumption
-** that no output is better than wrong output).
-*/
-static char const ASCTIME_FMT_B[] = "%s %s%3d %.2d:%.2d:%.2d %s\n";
-
enum { STD_ASCTIME_BUF_SIZE = 26 };
/*
** Big enough for something such as
@@ -52,14 +32,24 @@ enum { STD_ASCTIME_BUF_SIZE = 26 };
*/
static char buf_asctime[2*3 + 5*INT_STRLEN_MAXIMUM(int) + 7 + 2 + 1 + 1];
-/* A similar buffer for ctime.
- C89 requires that they be the same buffer.
- This requirement was removed in C99, so support it only if requested,
- as support is more likely to lead to bugs in badly written programs. */
-#if SUPPORT_C89
-# define buf_ctime buf_asctime
-#else
-static char buf_ctime[sizeof buf_asctime];
+/* On pre-C99 platforms, a snprintf substitute good enough for us. */
+#if !HAVE_SNPRINTF
+# include <stdarg.h>
+ATTRIBUTE_FORMAT((printf, 3, 4)) static int
+my_snprintf(char *s, size_t size, char const *format, ...)
+{
+ int n;
+ va_list args;
+ char stackbuf[sizeof buf_asctime];
+ va_start(args, format);
+ n = vsprintf(stackbuf, format, args);
+ va_end (args);
+ if (0 <= n && n < size)
+ memcpy (s, stackbuf, n + 1);
+ return n;
+}
+# undef snprintf
+# define snprintf my_snprintf
#endif
/* Publish asctime_r and ctime_r only when supporting older POSIX. */
@@ -84,14 +74,19 @@ asctime_r(struct tm const *restrict timeptr, char *restrict buf)
"Jan", "Feb", "Mar", "Apr", "May", "Jun",
"Jul", "Aug", "Sep", "Oct", "Nov", "Dec"
};
- const char * wn;
- const char * mn;
- char year[INT_STRLEN_MAXIMUM(int) + 2];
- char result[sizeof buf_asctime];
+ register const char * wn;
+ register const char * mn;
+ int year, mday, hour, min, sec;
+ long long_TM_YEAR_BASE = TM_YEAR_BASE;
+ size_t bufsize = (buf == buf_asctime
+ ? sizeof buf_asctime : STD_ASCTIME_BUF_SIZE);
if (timeptr == NULL) {
+ strcpy(buf, "??? ??? ?? ??:??:?? ????\n");
+ /* Set errno now, since strcpy might change it in
+ POSIX.1-2017 and earlier. */
errno = EINVAL;
- return strcpy(buf, "??? ??? ?? ??:??:?? ????\n");
+ return buf;
}
if (timeptr->tm_wday < 0 || timeptr->tm_wday >= DAYSPERWEEK)
wn = "???";
@@ -99,25 +94,41 @@ asctime_r(struct tm const *restrict timeptr, char *restrict buf)
if (timeptr->tm_mon < 0 || timeptr->tm_mon >= MONSPERYEAR)
mn = "???";
else mn = mon_name[timeptr->tm_mon];
- /*
- ** Use strftime's %Y to generate the year, to avoid overflow problems
- ** when computing timeptr->tm_year + TM_YEAR_BASE.
- ** Assume that strftime is unaffected by other out-of-range members
- ** (e.g., timeptr->tm_mday) when processing "%Y".
- */
- strftime(year, sizeof year, "%Y", timeptr);
- /*
- ** We avoid using snprintf since it's not available on all systems.
- */
- sprintf(result,
- ((strlen(year) <= 4) ? ASCTIME_FMT : ASCTIME_FMT_B),
- wn, mn,
- timeptr->tm_mday, timeptr->tm_hour,
- timeptr->tm_min, timeptr->tm_sec,
- year);
- if (strlen(result) < STD_ASCTIME_BUF_SIZE
- || buf == buf_ctime || buf == buf_asctime)
- return strcpy(buf, result);
+
+ year = timeptr->tm_year;
+ mday = timeptr->tm_mday;
+ hour = timeptr->tm_hour;
+ min = timeptr->tm_min;
+ sec = timeptr->tm_sec;
+
+ /* Vintage programs are coded for years that are always four bytes long
+ and may assume that the newline always lands in the same place.
+ For years that are less than four bytes, pad the output with
+ leading zeroes to get the newline in the traditional place.
+ For years longer than four bytes, put extra spaces before the year
+ so that vintage code trying to overwrite the newline
+ won't overwrite a digit within a year and truncate the year,
+ using the principle that no output is better than wrong output.
+ This conforms to ISO C and POSIX standards, which say behavior
+ is undefined when the year is less than 1000 or greater than 9999.
+
+ Also, avoid overflow when formatting tm_year + TM_YEAR_BASE. */
+
+ if ((year <= LONG_MAX - TM_YEAR_BASE
+ ? snprintf (buf, bufsize,
+ ((-999 - TM_YEAR_BASE <= year
+ && year <= 9999 - TM_YEAR_BASE)
+ ? "%s %s%3d %.2d:%.2d:%.2d %04ld\n"
+ : "%s %s%3d %.2d:%.2d:%.2d %ld\n"),
+ wn, mn, mday, hour, min, sec,
+ year + long_TM_YEAR_BASE)
+ : snprintf (buf, bufsize,
+ "%s %s%3d %.2d:%.2d:%.2d %d%d\n",
+ wn, mn, mday, hour, min, sec,
+ year / 10 + TM_YEAR_BASE / 10,
+ year % 10))
+ < bufsize)
+ return buf;
else {
errno = EOVERFLOW;
return NULL;
@@ -142,5 +153,8 @@ ctime_r(const time_t *timep, char *buf)
char *
ctime(const time_t *timep)
{
- return ctime_r(timep, buf_ctime);
+ /* Do not call localtime_r, as C23 requires ctime to initialize the
+ static storage that localtime updates. */
+ struct tm *tmp = localtime(timep);
+ return tmp ? asctime(tmp) : NULL;
}
diff --git a/contrib/tzcode/date.1 b/contrib/tzcode/date.1
index 01907bc76e2c..3a02e7c2e08a 100644
--- a/contrib/tzcode/date.1
+++ b/contrib/tzcode/date.1
@@ -6,15 +6,13 @@ date \- show and set date and time
.SH SYNOPSIS
.if n .nh
.if n .na
-.ie \n(.g .ds - \f(CR-\fP
-.el .ds - \-
.B date
[
-.B \*-u
+.B \-u
] [
-.B \*-c
+.B \-c
] [
-.B \*-r
+.B \-r
.I seconds
] [
.BI + format
@@ -35,7 +33,7 @@ command
without arguments writes the date and time to the standard output in
the form
.ce 1
-Wed Mar 8 14:54:40 EST 1989
+Sat Mar 8 14:54:40 EST 2025
.br
with
.B EST
@@ -49,99 +47,24 @@ If a command-line argument starts with a plus sign (\c
.q "\fB+\fP" ),
the rest of the argument is used as a
.I format
-that controls what appears in the output.
-In the format, when a percent sign (\c
-.q "\fB%\fP"
-appears,
-it and the character after it are not output,
-but rather identify part of the date or time
-to be output in a particular way
-(or identify a special character to output):
-.nf
-.sp
-.if t .in +.5i
-.if n .in +2
-.ta \w'%M\0\0'u +\w'Wed Mar 8 14:54:40 EST 1989\0\0'u
- Sample output Explanation
-%a Wed Abbreviated weekday name*
-%A Wednesday Full weekday name*
-%b Mar Abbreviated month name*
-%B March Full month name*
-%c Wed Mar 08 14:54:40 1989 Date and time*
-%C 19 Century
-%d 08 Day of month (always two digits)
-%D 03/08/89 Month/day/year (eight characters)
-%e 8 Day of month (leading zero blanked)
-%h Mar Abbreviated month name*
-%H 14 24-hour-clock hour (two digits)
-%I 02 12-hour-clock hour (two digits)
-%j 067 Julian day number (three digits)
-%k 2 12-hour-clock hour (leading zero blanked)
-%l 14 24-hour-clock hour (leading zero blanked)
-%m 03 Month number (two digits)
-%M 54 Minute (two digits)
-%n \\n newline character
-%p PM AM/PM designation
-%r 02:54:40 PM Hour:minute:second AM/PM designation
-%R 14:54 Hour:minute
-%S 40 Second (two digits)
-%t \\t tab character
-%T 14:54:40 Hour:minute:second
-%U 10 Sunday-based week number (two digits)
-%w 3 Day number (one digit, Sunday is 0)
-%W 10 Monday-based week number (two digits)
-%x 03/08/89 Date*
-%X 14:54:40 Time*
-%y 89 Last two digits of year
-%Y 1989 Year in full
-%z -0500 Numeric time zone
-%Z EST Time zone abbreviation
-%+ Wed Mar 8 14:54:40 EST 1989 Default output format*
-.if t .in -.5i
-.if n .in -2
-* The exact output depends on the locale.
-.sp
-.fi
-If a character other than one of those shown above appears after
-a percent sign in the format,
-that following character is output.
-All other characters in the format are copied unchanged to the output;
-a newline character is always added at the end of the output.
-.PP
-In Sunday-based week numbering,
-the first Sunday of the year begins week 1;
-days preceding it are part of
-.q "week 0" .
-In Monday-based week numbering,
-the first Monday of the year begins week 1.
-.PP
-To set the date, use a command line argument with one of the following forms:
-.nf
-.if t .in +.5i
-.if n .in +2
-.ta \w'198903081454\0'u
-1454 24-hour-clock hours (first two digits) and minutes
-081454 Month day (first two digits), hours, and minutes
-03081454 Month (two digits, January is 01), month day, hours, minutes
-8903081454 Year, month, month day, hours, minutes
-0308145489 Month, month day, hours, minutes, year
- (on System V-compatible systems)
-030814541989 Month, month day, hours, minutes, four-digit year
-198903081454 Four-digit year, month, month day, hours, minutes
-.if t .in -.5i
-.if n .in -2
-.fi
-If the century, year, month, or month day is not given,
-the current value is used.
-Any of the above forms may be followed by a period and two digits that give
-the seconds part of the new time; if no seconds are given, zero is assumed.
+that is processed by
+.BR strftime (3)
+to determine what to output;
+a newline character is appended.
+For example, the shell command:
+.ce 1
+date +"%Y\-%m\-%d %H:%M:%S %z"
+.br
+outputs a line like
+.q "2025\-03\-08 14:54:40 \-0500"
+instead.
.PP
These options are available:
.TP
-.BR \*-u " or " \*-c
+.BR \-u " or " \-c
Use Universal Time when setting and showing the date and time.
.TP
-.BI "\*-r " seconds
+.BI "\-r " seconds
Output the date that corresponds to
.I seconds
past the epoch of 1970-01-01 00:00:00 UTC, where
@@ -149,16 +72,13 @@ past the epoch of 1970-01-01 00:00:00 UTC, where
should be an integer, either decimal, octal (leading 0), or
hexadecimal (leading 0x), preceded by an optional sign.
.SH FILES
-.ta \w'/usr/share/zoneinfo/posixrules\0\0'u
+.ta \w'/usr/share/zoneinfo/Etc/UTC\0\0'u
/etc/localtime local timezone file
.br
/usr/lib/locale/\f2L\fP/LC_TIME description of time locale \f2L\fP
.br
/usr/share/zoneinfo timezone directory
.br
-/usr/share/zoneinfo/posixrules default DST rules (obsolete)
-.br
-/usr/share/zoneinfo/GMT for UTC leap seconds
-.PP
-If /usr/share/zoneinfo/GMT is absent,
-UTC leap seconds are loaded from /usr/share/zoneinfo/GMT0 if present.
+/usr/share/zoneinfo/Etc/UTC for UTC leap seconds
+.SH SEE ALSO
+.BR strftime (3).
diff --git a/contrib/tzcode/localtime.c b/contrib/tzcode/localtime.c
index 0fe7f1ed3f64..a80d422f2955 100644
--- a/contrib/tzcode/localtime.c
+++ b/contrib/tzcode/localtime.c
@@ -34,6 +34,14 @@ int __tz_change_interval = DETECT_TZ_CHANGES_INTERVAL;
#include "un-namespace.h"
#endif /* __FreeBSD__ */
+#if HAVE_SYS_STAT_H
+# include <sys/stat.h>
+#endif
+#if !defined S_ISREG && defined S_IFREG
+/* Ancient UNIX or recent MS-Windows. */
+# define S_ISREG(mode) (((mode) & S_IFMT) == S_IFREG)
+#endif
+
#if defined THREAD_SAFE && THREAD_SAFE
# include <pthread.h>
#ifdef __FreeBSD__
@@ -48,6 +56,73 @@ static int lock(void) { return 0; }
static void unlock(void) { }
#endif
+/* Unless intptr_t is missing, pacify gcc -Wcast-qual on char const * exprs.
+ Use this carefully, as the casts disable type checking.
+ This is a macro so that it can be used in static initializers. */
+#ifdef INTPTR_MAX
+# define UNCONST(a) ((char *) (intptr_t) (a))
+#else
+# define UNCONST(a) ((char *) (a))
+#endif
+
+/* A signed type wider than int, so that we can add 1900 + tm_mon/12 to tm_year
+ without overflow. The static_assert checks that it is indeed wider
+ than int; if this fails on your platform please let us know. */
+#if INT_MAX < LONG_MAX
+typedef long iinntt;
+# define IINNTT_MIN LONG_MIN
+# define IINNTT_MAX LONG_MAX
+#elif INT_MAX < LLONG_MAX
+typedef long long iinntt;
+# define IINNTT_MIN LLONG_MIN
+# define IINNTT_MAX LLONG_MAX
+#else
+typedef intmax_t iinntt;
+# define IINNTT_MIN INTMAX_MIN
+# define IINNTT_MAX INTMAX_MAX
+#endif
+static_assert(IINNTT_MIN < INT_MIN && INT_MAX < IINNTT_MAX);
+
+/* On platforms where offtime or mktime might overflow,
+ strftime.c defines USE_TIMEX_T to be true and includes us.
+ This tells us to #define time_t to an internal type timex_t that is
+ wide enough so that strftime %s never suffers from integer overflow,
+ and to #define offtime (if TM_GMTOFF is defined) or mktime (otherwise)
+ to a static function that returns the redefined time_t.
+ It also tells us to define only data and code needed
+ to support the offtime or mktime variant. */
+#ifndef USE_TIMEX_T
+# define USE_TIMEX_T false
+#endif
+#if USE_TIMEX_T
+# undef TIME_T_MIN
+# undef TIME_T_MAX
+# undef time_t
+# define time_t timex_t
+# if MKTIME_FITS_IN(LONG_MIN, LONG_MAX)
+typedef long timex_t;
+# define TIME_T_MIN LONG_MIN
+# define TIME_T_MAX LONG_MAX
+# elif MKTIME_FITS_IN(LLONG_MIN, LLONG_MAX)
+typedef long long timex_t;
+# define TIME_T_MIN LLONG_MIN
+# define TIME_T_MAX LLONG_MAX
+# else
+typedef intmax_t timex_t;
+# define TIME_T_MIN INTMAX_MIN
+# define TIME_T_MAX INTMAX_MAX
+# endif
+
+# ifdef TM_GMTOFF
+# undef timeoff
+# define timeoff timex_timeoff
+# undef EXTERN_TIMEOFF
+# else
+# undef mktime
+# define mktime timex_mktime
+# endif
+#endif
+
#ifndef TZ_ABBR_CHAR_SET
# define TZ_ABBR_CHAR_SET \
"abcdefghijklmnopqrstuvwxyzABCDEFGHIJKLMNOPQRSTUVWXYZ0123456789 :+-._"
@@ -57,12 +132,23 @@ static void unlock(void) { }
# define TZ_ABBR_ERR_CHAR '_'
#endif /* !defined TZ_ABBR_ERR_CHAR */
-/*
-** Support non-POSIX platforms that distinguish between text and binary files.
-*/
+/* Port to platforms that lack some O_* flags. Unless otherwise
+ specified, the flags are standardized by POSIX. */
#ifndef O_BINARY
-# define O_BINARY 0
+# define O_BINARY 0 /* MS-Windows */
+#endif
+#ifndef O_CLOEXEC
+# define O_CLOEXEC 0
+#endif
+#ifndef O_CLOFORK
+# define O_CLOFORK 0
+#endif
+#ifndef O_IGNORE_CTTY
+# define O_IGNORE_CTTY 0 /* GNU/Hurd */
+#endif
+#ifndef O_NOCTTY
+# define O_NOCTTY 0
#endif
#ifndef WILDABBR
@@ -91,7 +177,10 @@ static void unlock(void) { }
static const char wildabbr[] = WILDABBR;
static char const etc_utc[] = "Etc/UTC";
+
+#if !USE_TIMEX_T || defined TM_ZONE || !defined TM_GMTOFF
static char const *utc = etc_utc + sizeof "Etc/" - 1;
+#endif
/*
** The DST rules to use if TZ has no rules and we can't load TZDEFRULES.
@@ -103,10 +192,31 @@ static char const *utc = etc_utc + sizeof "Etc/" - 1;
# define TZDEFRULESTRING ",M3.2.0,M11.1.0"
#endif
+/* Limit to time zone abbreviation length in proleptic TZ strings.
+ This is distinct from TZ_MAX_CHARS, which limits TZif file contents.
+ It defaults to 254, not 255, so that desigidx_type can be an unsigned char.
+ unsigned char suffices for TZif files, so the only reason to increase
+ TZNAME_MAXIMUM is to support TZ strings specifying abbreviations
+ longer than 254 bytes. There is little reason to do that, though,
+ as strings that long are hardly "abbreviations". */
+#ifndef TZNAME_MAXIMUM
+# define TZNAME_MAXIMUM 254
+#endif
+
+#if TZNAME_MAXIMUM < UCHAR_MAX
+typedef unsigned char desigidx_type;
+#elif TZNAME_MAXIMUM < INT_MAX
+typedef int desigidx_type;
+#elif TZNAME_MAXIMUM < PTRDIFF_MAX
+typedef ptrdiff_t desigidx_type;
+#else
+# error "TZNAME_MAXIMUM too large"
+#endif
+
struct ttinfo { /* time type information */
- int_fast32_t tt_utoff; /* UT offset in seconds */
+ int_least32_t tt_utoff; /* UT offset in seconds */
+ desigidx_type tt_desigidx; /* abbreviation list index */
bool tt_isdst; /* used to set tm_isdst */
- int tt_desigidx; /* abbreviation list index */
bool tt_ttisstd; /* transition is std time */
bool tt_ttisut; /* transition is UT */
};
@@ -125,12 +235,6 @@ static char const UNSPEC[] = "-00";
for ttunspecified to work without crashing. */
enum { CHARS_EXTRA = max(sizeof UNSPEC, 2) - 1 };
-/* Limit to time zone abbreviation length in proleptic TZ strings.
- This is distinct from TZ_MAX_CHARS, which limits TZif file contents. */
-#ifndef TZNAME_MAXIMUM
-# define TZNAME_MAXIMUM 255
-#endif
-
/* A representation of the contents of a TZif file. Ideally this
would have no size limits; the following sizes should suffice for
practical use. This struct should not be too large, as instances
@@ -173,7 +277,6 @@ static struct tm *gmtsub(struct state const *, time_t const *, int_fast32_t,
static bool increment_overflow(int *, int);
static bool increment_overflow_time(time_t *, int_fast32_t);
static int_fast32_t leapcorr(struct state const *, time_t);
-static bool normalize_overflow32(int_fast32_t *, int *, int);
static struct tm *timesub(time_t const *, int_fast32_t, struct state const *,
struct tm *);
static bool tzparse(char const *, struct state *, struct state const *);
@@ -194,8 +297,10 @@ static struct state *const gmtptr = &gmtmem;
# define TZ_STRLEN_MAX 255
#endif /* !defined TZ_STRLEN_MAX */
+#if !USE_TIMEX_T || !defined TM_GMTOFF
static char lcl_TZname[TZ_STRLEN_MAX + 1];
static int lcl_is_set;
+#endif
#ifdef __FreeBSD__
static pthread_once_t gmt_once = PTHREAD_ONCE_INIT;
static pthread_once_t gmtime_once = PTHREAD_ONCE_INIT;
@@ -221,27 +326,29 @@ static int localtime_key_error;
** trigger latent bugs in programs.
*/
-#if SUPPORT_C89
+#if !USE_TIMEX_T
+
+# if SUPPORT_C89
static struct tm tm;
#endif
-#if 2 <= HAVE_TZNAME + TZ_TIME_T
-char * tzname[2] = {
- (char *) wildabbr,
- (char *) wildabbr
-};
-#endif
-#if 2 <= USG_COMPAT + TZ_TIME_T
+# if 2 <= HAVE_TZNAME + TZ_TIME_T
+char *tzname[2] = { UNCONST(wildabbr), UNCONST(wildabbr) };
+# endif
+# if 2 <= USG_COMPAT + TZ_TIME_T
long timezone;
int daylight;
-#endif
-#if 2 <= ALTZONE + TZ_TIME_T
+# endif
+# if 2 <= ALTZONE + TZ_TIME_T
long altzone;
+# endif
+
#endif
/* Initialize *S to a value based on UTOFF, ISDST, and DESIGIDX. */
static void
-init_ttinfo(struct ttinfo *s, int_fast32_t utoff, bool isdst, int desigidx)
+init_ttinfo(struct ttinfo *s, int_fast32_t utoff, bool isdst,
+ desigidx_type desigidx)
{
s->tt_utoff = utoff;
s->tt_isdst = isdst;
@@ -305,20 +412,22 @@ detzcode64(const char *const codep)
return result;
}
+#if !USE_TIMEX_T || !defined TM_GMTOFF
+
static void
update_tzname_etc(struct state const *sp, struct ttinfo const *ttisp)
{
-#if HAVE_TZNAME
- tzname[ttisp->tt_isdst] = (char *) &sp->chars[ttisp->tt_desigidx];
-#endif
-#if USG_COMPAT
+# if HAVE_TZNAME
+ tzname[ttisp->tt_isdst] = UNCONST(&sp->chars[ttisp->tt_desigidx]);
+# endif
+# if USG_COMPAT
if (!ttisp->tt_isdst)
timezone = - ttisp->tt_utoff;
-#endif
-#if ALTZONE
+# endif
+# if ALTZONE
if (ttisp->tt_isdst)
altzone = - ttisp->tt_utoff;
-#endif
+# endif
}
/* If STDDST_MASK indicates that SP's TYPE provides useful info,
@@ -349,18 +458,18 @@ settzname(void)
When STDDST_MASK becomes zero we can stop looking. */
int stddst_mask = 0;
-#if HAVE_TZNAME
- tzname[0] = tzname[1] = (char *) (sp ? wildabbr : utc);
+# if HAVE_TZNAME
+ tzname[0] = tzname[1] = UNCONST(sp ? wildabbr : utc);
stddst_mask = 3;
-#endif
-#if USG_COMPAT
+# endif
+# if USG_COMPAT
timezone = 0;
stddst_mask = 3;
-#endif
-#if ALTZONE
+# endif
+# if ALTZONE
altzone = 0;
stddst_mask |= 2;
-#endif
+# endif
/*
** And to get the latest time zone abbreviations into tzname. . .
*/
@@ -370,9 +479,9 @@ settzname(void)
for (i = sp->typecnt - 1; stddst_mask && 0 <= i; i--)
stddst_mask = may_update_tzname_etc(stddst_mask, sp, i);
}
-#if USG_COMPAT
+# if USG_COMPAT
daylight = stddst_mask >> 1 ^ 1;
-#endif
+# endif
}
/* Replace bogus characters in time zone abbreviations.
@@ -399,6 +508,8 @@ scrub_abbrs(struct state *sp)
return 0;
}
+#endif
+
#ifdef DETECT_TZ_CHANGES
/*
* Check whether either the time zone name or the file it refers to has
@@ -473,11 +584,15 @@ union local_storage {
#endif /* !__FreeBSD__ */
};
-/* Load tz data from the file named NAME into *SP. Read extended
- format if DOEXTEND. Use *LSP for temporary storage. Return 0 on
+/* These tzload flags can be ORed together, and fit into 'char'. */
+enum { TZLOAD_FROMENV = 1 }; /* The TZ string came from the environment. */
+enum { TZLOAD_TZSTRING = 2 }; /* Read any newline-surrounded TZ string. */
+
+/* Load tz data from the file named NAME into *SP. Respect TZLOADFLAGS.
+ Use *LSP for temporary storage. Return 0 on
success, an errno value on failure. */
static int
-tzloadbody(char const *name, struct state *sp, bool doextend,
+tzloadbody(char const *name, struct state *sp, char tzloadflags,
union local_storage *lsp)
{
register int i;
@@ -485,7 +600,9 @@ tzloadbody(char const *name, struct state *sp, bool doextend,
register int stored;
register ssize_t nread;
#ifdef __FreeBSD__
- int serrno;
+ struct stat sb;
+ const char *relname;
+ int dd, serrno;
#else /* !__FreeBSD__ */
register bool doaccess;
#endif /* !__FreeBSD__ */
@@ -533,45 +650,75 @@ tzloadbody(char const *name, struct state *sp, bool doextend,
name = lsp->fullname;
}
- if (doaccess && access(name, R_OK) != 0)
- return errno;
- fid = _open(name, O_RDONLY | O_BINARY);
+ if (doaccess && (tzloadflags & TZLOAD_FROMENV)) {
+ /* Check for security violations and for devices whose mere
+ opening could have unwanted side effects. Although these
+ checks are racy, they're better than nothing and there is
+ no portable way to fix the races. */
+ if (access(name, R_OK) < 0)
+ return errno;
+#ifdef S_ISREG
+ {
+ struct stat st;
+ if (stat(name, &st) < 0)
+ return errno;
+ if (!S_ISREG(st.st_mode))
+ return EINVAL;
+ }
+#endif
+ }
+ fid = _open(name, (O_RDONLY | O_BINARY | O_CLOEXEC | O_CLOFORK
+ | O_IGNORE_CTTY | O_NOCTTY));
#else /* __FreeBSD__ */
- {
- const char *relname = name;
- if (strncmp(relname, TZDIR "/", strlen(TZDIR) + 1) == 0)
- relname += strlen(TZDIR) + 1;
- int dd = _open(TZDIR, O_DIRECTORY | O_RDONLY);
- if (dd < 0)
- return errno;
- fid = _openat(dd, relname, O_RDONLY | O_BINARY,
- issetugid() ? AT_RESOLVE_BENEATH : 0);
- serrno = errno;
- _close(dd);
- errno = serrno;
- }
+ relname = name;
+ if (strncmp(relname, TZDIR "/", strlen(TZDIR) + 1) == 0)
+ relname += strlen(TZDIR) + 1;
+ dd = _open(TZDIR, O_DIRECTORY | O_RDONLY);
+ if (issetugid() && (tzloadflags & TZLOAD_FROMENV)) {
+ if (dd < 0)
+ return errno;
+ if (fstatat(dd, name, &sb, AT_RESOLVE_BENEATH) < 0) {
+ fid = -1;
+ } else if (!S_ISREG(sb.st_mode)) {
+ fid = -1;
+ errno = EINVAL;
+ } else {
+ fid = _openat(dd, relname, O_RDONLY | O_BINARY, AT_RESOLVE_BENEATH);
+ }
+ } else {
+ if (dd < 0) {
+ relname = name;
+ dd = AT_FDCWD;
+ }
+ fid = _openat(dd, relname, O_RDONLY | O_BINARY, 0);
+ }
+ if (dd != AT_FDCWD && dd >= 0) {
+ serrno = errno;
+ _close(dd);
+ errno = serrno;
+ }
#endif /* __FreeBSD__ */
if (fid < 0)
return errno;
#ifdef DETECT_TZ_CHANGES
- if (doextend) {
- /*
- * Detect if the timezone file has changed. Check 'doextend' to
- * ignore TZDEFRULES; the tzfile_changed() function can only
- * keep state for a single file.
- */
- switch (tzfile_changed(name, fid)) {
- case -1:
- serrno = errno;
- _close(fid);
- return serrno;
- case 0:
- _close(fid);
- return 0;
- case 1:
- break;
- }
+ if (tzloadflags) {
+ /*
+ * Detect if the timezone file has changed. Check tzloadflags
+ * to ignore TZDEFRULES; the tzfile_changed() function can only
+ * keep state for a single file.
+ */
+ switch (tzfile_changed(name, fid)) {
+ case -1:
+ serrno = errno;
+ _close(fid);
+ return serrno;
+ case 0:
+ _close(fid);
+ return 0;
+ case 1:
+ break;
+ }
}
#endif /* DETECT_TZ_CHANGES */
nread = _read(fid, up->buf, sizeof up->buf);
@@ -697,7 +844,7 @@ tzloadbody(char const *name, struct state *sp, bool doextend,
correction must differ from the previous one's by 1
second or less, except that the first correction can be
any value; these requirements are more generous than
- RFC 8536, to allow future RFC extensions. */
+ RFC 9636, to allow future RFC extensions. */
if (! (i == 0
|| (prevcorr < corr
? corr == prevcorr + 1
@@ -748,7 +895,7 @@ tzloadbody(char const *name, struct state *sp, bool doextend,
if (!version)
break;
}
- if (doextend && nread > 2 &&
+ if ((tzloadflags & TZLOAD_TZSTRING) && nread > 2 &&
up->buf[0] == '\n' && up->buf[nread - 1] == '\n' &&
sp->typecnt + 2 <= TZ_MAX_TYPES) {
struct state *ts = &lsp->u.st;
@@ -823,23 +970,23 @@ tzloadbody(char const *name, struct state *sp, bool doextend,
return 0;
}
-/* Load tz data from the file named NAME into *SP. Read extended
- format if DOEXTEND. Return 0 on success, an errno value on failure. */
+/* Load tz data from the file named NAME into *SP. Respect TZLOADFLAGS.
+ Return 0 on success, an errno value on failure. */
static int
-tzload(char const *name, struct state *sp, bool doextend)
+tzload(char const *name, struct state *sp, char tzloadflags)
{
#ifdef ALL_STATE
union local_storage *lsp = malloc(sizeof *lsp);
if (!lsp) {
return HAVE_MALLOC_ERRNO ? errno : ENOMEM;
} else {
- int err = tzloadbody(name, sp, doextend, lsp);
+ int err = tzloadbody(name, sp, tzloadflags, lsp);
free(lsp);
return err;
}
#else
union local_storage ls;
- return tzloadbody(name, sp, doextend, &ls);
+ return tzloadbody(name, sp, tzloadflags, &ls);
#endif
}
@@ -1180,7 +1327,7 @@ tzparse(const char *name, struct state *sp, struct state const *basep)
sp->leapcnt = basep->leapcnt;
memcpy(sp->lsis, basep->lsis, sp->leapcnt * sizeof *sp->lsis);
} else {
- load_ok = tzload(TZDEFRULES, sp, false) == 0;
+ load_ok = tzload(TZDEFRULES, sp, 0) == 0;
if (!load_ok)
sp->leapcnt = 0; /* So, we're off a little. */
}
@@ -1417,7 +1564,7 @@ tzparse(const char *name, struct state *sp, struct state const *basep)
static void
gmtload(struct state *const sp)
{
- if (tzload(etc_utc, sp, true) != 0)
+ if (tzload(etc_utc, sp, TZLOAD_TZSTRING) != 0)
tzparse("UTC0", sp, NULL);
}
@@ -1444,10 +1591,13 @@ tzdata_is_fresh(void)
}
#endif /* DETECT_TZ_CHANGES */
+#if !USE_TIMEX_T || !defined TM_GMTOFF
+
/* Initialize *SP to a value appropriate for the TZ setting NAME.
+ Respect TZLOADFLAGS.
Return 0 on success, an errno value on failure. */
static int
-zoneinit(struct state *sp, char const *name)
+zoneinit(struct state *sp, char const *name, char tzloadflags)
{
if (name && ! name[0]) {
/*
@@ -1462,7 +1612,7 @@ zoneinit(struct state *sp, char const *name)
strcpy(sp->chars, utc);
return 0;
} else {
- int err = tzload(name, sp, true);
+ int err = tzload(name, sp, tzloadflags);
if (err != 0 && name && name[0] != ':' && tzparse(name, sp, NULL))
err = 0;
if (err == 0)
@@ -1492,13 +1642,15 @@ tzset_unlocked_name(char const *name)
if (tzdata_is_fresh() == 0)
#endif /* DETECT_TZ_CHANGES */
return;
-#ifdef ALL_STATE
+# ifdef ALL_STATE
if (! sp)
lclptr = sp = malloc(sizeof *lclptr);
-#endif /* defined ALL_STATE */
+# endif
if (sp) {
- if (zoneinit(sp, name) != 0)
- zoneinit(sp, "");
+ if (zoneinit(sp, name, TZLOAD_FROMENV | TZLOAD_TZSTRING) != 0) {
+ zoneinit(sp, "", 0);
+ strcpy(sp->chars, UNSPEC);
+ }
if (0 < lcl)
strcpy(lcl_TZname, name);
}
@@ -1506,6 +1658,9 @@ tzset_unlocked_name(char const *name)
lcl_is_set = lcl;
}
+#endif
+
+#if !USE_TIMEX_T
void
tzset(void)
{
@@ -1514,6 +1669,7 @@ tzset(void)
tzset_unlocked();
unlock();
}
+#endif
#ifdef __FreeBSD__
void
@@ -1548,14 +1704,14 @@ gmtcheck(void)
#define gmtcheck() _once(&gmt_once, gmtcheck)
#endif
-#if NETBSD_INSPIRED
+#if NETBSD_INSPIRED && !USE_TIMEX_T
timezone_t
tzalloc(char const *name)
{
timezone_t sp = malloc(sizeof *sp);
if (sp) {
- int err = zoneinit(sp, name);
+ int err = zoneinit(sp, name, TZLOAD_TZSTRING);
if (err != 0) {
free(sp);
errno = err;
@@ -1584,6 +1740,8 @@ tzfree(timezone_t sp)
#endif
+#if !USE_TIMEX_T || !defined TM_GMTOFF
+
/*
** The easy way to behave "as if no library function calls" localtime
** is to not call it, so we drop its guts into "localsub", which can be
@@ -1638,14 +1796,14 @@ localsub(struct state const *sp, time_t const *timep, int_fast32_t setname,
return NULL; /* "cannot happen" */
result = localsub(sp, &newt, setname, tmp);
if (result) {
-#if defined ckd_add && defined ckd_sub
+# if defined ckd_add && defined ckd_sub
if (t < sp->ats[0]
? ckd_sub(&result->tm_year,
result->tm_year, years)
: ckd_add(&result->tm_year,
result->tm_year, years))
return NULL;
-#else
+# else
register int_fast64_t newy;
newy = result->tm_year;
@@ -1655,7 +1813,7 @@ localsub(struct state const *sp, time_t const *timep, int_fast32_t setname,
if (! (INT_MIN <= newy && newy <= INT_MAX))
return NULL;
result->tm_year = newy;
-#endif
+# endif
}
return result;
}
@@ -1684,25 +1842,26 @@ localsub(struct state const *sp, time_t const *timep, int_fast32_t setname,
result = timesub(&t, ttisp->tt_utoff, sp, tmp);
if (result) {
result->tm_isdst = ttisp->tt_isdst;
-#ifdef TM_ZONE
- result->TM_ZONE = (char *) &sp->chars[ttisp->tt_desigidx];
-#endif /* defined TM_ZONE */
+# ifdef TM_ZONE
+ result->TM_ZONE = UNCONST(&sp->chars[ttisp->tt_desigidx]);
+# endif
if (setname)
update_tzname_etc(sp, ttisp);
}
return result;
}
+#endif
-#if NETBSD_INSPIRED
+#if !USE_TIMEX_T
+# if NETBSD_INSPIRED
struct tm *
localtime_rz(struct state *restrict sp, time_t const *restrict timep,
struct tm *restrict tmp)
{
return localsub(sp, timep, 0, tmp);
}
-
-#endif
+# endif
static struct tm *
localtime_tzset(time_t const *timep, struct tm *tmp, bool setname)
@@ -1731,9 +1890,9 @@ localtime_key_init(void)
struct tm *
localtime(const time_t *timep)
{
-#if !SUPPORT_C89
+# if !SUPPORT_C89
static struct tm tm;
-#endif
+# endif
#ifdef __FreeBSD__
struct tm *p_tm = &tm;
@@ -1762,6 +1921,7 @@ localtime_r(const time_t *restrict timep, struct tm *restrict tmp)
{
return localtime_tzset(timep, tmp, false);
}
+#endif
/*
** gmtsub is to gmtime as localsub is to localtime.
@@ -1780,12 +1940,14 @@ gmtsub(ATTRIBUTE_MAYBE_UNUSED struct state const *sp, time_t const *timep,
** "+xx" or "-xx" if offset is non-zero,
** but this is no time for a treasure hunt.
*/
- tmp->TM_ZONE = ((char *)
- (offset ? wildabbr : gmtptr ? gmtptr->chars : utc));
+ tmp->TM_ZONE = UNCONST(offset ? wildabbr
+ : gmtptr ? gmtptr->chars : utc);
#endif /* defined TM_ZONE */
return result;
}
+#if !USE_TIMEX_T
+
/*
* Re-entrant version of gmtime.
*/
@@ -1807,9 +1969,9 @@ gmtime_key_init(void)
struct tm *
gmtime(const time_t *timep)
{
-#if !SUPPORT_C89
+# if !SUPPORT_C89
static struct tm tm;
-#endif
+# endif
#ifdef __FreeBSD__
struct tm *p_tm = &tm;
@@ -1833,7 +1995,7 @@ gmtime(const time_t *timep)
return gmtime_r(timep, p_tm);
}
-#if STD_INSPIRED
+# if STD_INSPIRED
/* This function is obsolescent and may disappear in future releases.
Callers can instead use localtime_rz with a fixed-offset zone. */
@@ -1855,9 +2017,9 @@ offtime_key_init(void)
struct tm *
offtime(const time_t *timep, long offset)
{
-#if !SUPPORT_C89
+# if !SUPPORT_C89
static struct tm tm;
-#endif
+# endif
#ifdef __FreeBSD__
struct tm *p_tm = &tm;
@@ -1881,6 +2043,7 @@ offtime(const time_t *timep, long offset)
return offtime_r(timep, offset, p_tm);
}
+# endif
#endif
/*
@@ -1939,7 +2102,7 @@ timesub(const time_t *timep, int_fast32_t offset,
dayoff = offset / SECSPERDAY - corr / SECSPERDAY + rem / SECSPERDAY - 3;
rem %= SECSPERDAY;
/* y = (EPOCH_YEAR
- + floor((tdays + dayoff) / DAYSPERREPEAT) * YEARSPERREPEAT),
+ + floor((tdays + dayoff) / DAYSPERREPEAT) * YEARSPERREPEAT),
sans overflow. But calculate against 1570 (EPOCH_YEAR -
YEARSPERREPEAT) instead of against 1970 so that things work
for localtime values before 1970 when time_t is unsigned. */
@@ -2056,17 +2219,17 @@ increment_overflow(int *ip, int j)
}
static bool
-increment_overflow32(int_fast32_t *const lp, int const m)
+increment_overflow_time_iinntt(time_t *tp, iinntt j)
{
#ifdef ckd_add
- return ckd_add(lp, *lp, m);
+ return ckd_add(tp, *tp, j);
#else
- register int_fast32_t const l = *lp;
-
- if ((l >= 0) ? (m > INT_FAST32_MAX - l) : (m < INT_FAST32_MIN - l))
- return true;
- *lp += m;
- return false;
+ if (j < 0
+ ? (TYPE_SIGNED(time_t) ? *tp < TIME_T_MIN - j : *tp <= -1 - j)
+ : TIME_T_MAX - j < *tp)
+ return true;
+ *tp += j;
+ return false;
#endif
}
@@ -2090,30 +2253,6 @@ increment_overflow_time(time_t *tp, int_fast32_t j)
#endif
}
-static bool
-normalize_overflow(int *const tensptr, int *const unitsptr, const int base)
-{
- register int tensdelta;
-
- tensdelta = (*unitsptr >= 0) ?
- (*unitsptr / base) :
- (-1 - (-1 - *unitsptr) / base);
- *unitsptr -= tensdelta * base;
- return increment_overflow(tensptr, tensdelta);
-}
-
-static bool
-normalize_overflow32(int_fast32_t *tensptr, int *unitsptr, int base)
-{
- register int tensdelta;
-
- tensdelta = (*unitsptr >= 0) ?
- (*unitsptr / base) :
- (-1 - (-1 - *unitsptr) / base);
- *unitsptr -= tensdelta * base;
- return increment_overflow32(tensptr, tensdelta);
-}
-
static int
tmcomp(register const struct tm *const atmp,
register const struct tm *const btmp)
@@ -2158,11 +2297,9 @@ time2sub(struct tm *const tmp,
{
register int dir;
register int i, j;
- register int saved_seconds;
- register int_fast32_t li;
register time_t lo;
register time_t hi;
- int_fast32_t y;
+ iinntt y, mday, hour, min, saved_seconds;
time_t newt;
time_t t;
struct tm yourtm, mytm;
@@ -2170,36 +2307,57 @@ time2sub(struct tm *const tmp,
*okayp = false;
mktmcpy(&yourtm, tmp);
+ min = yourtm.tm_min;
if (do_norm_secs) {
- if (normalize_overflow(&yourtm.tm_min, &yourtm.tm_sec,
- SECSPERMIN))
- return WRONG;
+ min += yourtm.tm_sec / SECSPERMIN;
+ yourtm.tm_sec %= SECSPERMIN;
+ if (yourtm.tm_sec < 0) {
+ yourtm.tm_sec += SECSPERMIN;
+ min--;
+ }
}
- if (normalize_overflow(&yourtm.tm_hour, &yourtm.tm_min, MINSPERHOUR))
- return WRONG;
- if (normalize_overflow(&yourtm.tm_mday, &yourtm.tm_hour, HOURSPERDAY))
- return WRONG;
+
+ hour = yourtm.tm_hour;
+ hour += min / MINSPERHOUR;
+ yourtm.tm_min = min % MINSPERHOUR;
+ if (yourtm.tm_min < 0) {
+ yourtm.tm_min += MINSPERHOUR;
+ hour--;
+ }
+
+ mday = yourtm.tm_mday;
+ mday += hour / HOURSPERDAY;
+ yourtm.tm_hour = hour % HOURSPERDAY;
+ if (yourtm.tm_hour < 0) {
+ yourtm.tm_hour += HOURSPERDAY;
+ mday--;
+ }
+
y = yourtm.tm_year;
- if (normalize_overflow32(&y, &yourtm.tm_mon, MONSPERYEAR))
- return WRONG;
+ y += yourtm.tm_mon / MONSPERYEAR;
+ yourtm.tm_mon %= MONSPERYEAR;
+ if (yourtm.tm_mon < 0) {
+ yourtm.tm_mon += MONSPERYEAR;
+ y--;
+ }
+
/*
** Turn y into an actual year number for now.
** It is converted back to an offset from TM_YEAR_BASE later.
*/
- if (increment_overflow32(&y, TM_YEAR_BASE))
- return WRONG;
- while (yourtm.tm_mday <= 0) {
- if (increment_overflow32(&y, -1))
- return WRONG;
- li = y + (1 < yourtm.tm_mon);
- yourtm.tm_mday += year_lengths[isleap(li)];
+ y += TM_YEAR_BASE;
+
+ while (mday <= 0) {
+ iinntt li = y - (yourtm.tm_mon <= 1);
+ mday += year_lengths[isleap(li)];
+ y--;
}
- while (yourtm.tm_mday > DAYSPERLYEAR) {
- li = y + (1 < yourtm.tm_mon);
- yourtm.tm_mday -= year_lengths[isleap(li)];
- if (increment_overflow32(&y, 1))
- return WRONG;
+ while (DAYSPERLYEAR < mday) {
+ iinntt li = y + (1 < yourtm.tm_mon);
+ mday -= year_lengths[isleap(li)];
+ y++;
}
+ yourtm.tm_mday = mday;
for ( ; ; ) {
i = mon_lengths[isleap(y)][yourtm.tm_mon];
if (yourtm.tm_mday <= i)
@@ -2207,16 +2365,14 @@ time2sub(struct tm *const tmp,
yourtm.tm_mday -= i;
if (++yourtm.tm_mon >= MONSPERYEAR) {
yourtm.tm_mon = 0;
- if (increment_overflow32(&y, 1))
- return WRONG;
+ y++;
}
}
#ifdef ckd_add
if (ckd_add(&yourtm.tm_year, y, -TM_YEAR_BASE))
return WRONG;
#else
- if (increment_overflow32(&y, -TM_YEAR_BASE))
- return WRONG;
+ y -= TM_YEAR_BASE;
if (! (INT_MIN <= y && y <= INT_MAX))
return WRONG;
yourtm.tm_year = y;
@@ -2232,9 +2388,8 @@ time2sub(struct tm *const tmp,
** not in the same minute that a leap second was deleted from,
** which is a safer assumption than using 58 would be.
*/
- if (increment_overflow(&yourtm.tm_sec, 1 - SECSPERMIN))
- return WRONG;
saved_seconds = yourtm.tm_sec;
+ saved_seconds -= SECSPERMIN - 1;
yourtm.tm_sec = SECSPERMIN - 1;
} else {
saved_seconds = yourtm.tm_sec;
@@ -2343,10 +2498,8 @@ time2sub(struct tm *const tmp,
return WRONG;
}
label:
- newt = t + saved_seconds;
- if ((newt < t) != (saved_seconds < 0))
+ if (increment_overflow_time_iinntt(&t, saved_seconds))
return WRONG;
- t = newt;
if (funcp(sp, &t, offset, tmp))
*okayp = true;
return t;
@@ -2443,6 +2596,8 @@ time1(struct tm *const tmp,
return WRONG;
}
+#if !defined TM_GMTOFF || !USE_TIMEX_T
+
static time_t
mktime_tzname(struct state *sp, struct tm *tmp, bool setname)
{
@@ -2454,16 +2609,9 @@ mktime_tzname(struct state *sp, struct tm *tmp, bool setname)
}
}
-#if NETBSD_INSPIRED
-
-time_t
-mktime_z(struct state *restrict sp, struct tm *restrict tmp)
-{
- return mktime_tzname(sp, tmp, false);
-}
-
-#endif
-
+# if USE_TIMEX_T
+static
+# endif
time_t
mktime(struct tm *tmp)
{
@@ -2479,7 +2627,17 @@ mktime(struct tm *tmp)
return t;
}
-#if STD_INSPIRED
+#endif
+
+#if NETBSD_INSPIRED && !USE_TIMEX_T
+time_t
+mktime_z(struct state *restrict sp, struct tm *restrict tmp)
+{
+ return mktime_tzname(sp, tmp, false);
+}
+#endif
+
+#if STD_INSPIRED && !USE_TIMEX_T
/* This function is obsolescent and may disappear in future releases.
Callers can instead use mktime. */
time_t
@@ -2491,12 +2649,14 @@ timelocal(struct tm *tmp)
}
#endif
-#ifndef EXTERN_TIMEOFF
-# ifndef timeoff
-# define timeoff my_timeoff /* Don't collide with OpenBSD 7.4 <time.h>. */
+#if defined TM_GMTOFF || !USE_TIMEX_T
+
+# ifndef EXTERN_TIMEOFF
+# ifndef timeoff
+# define timeoff my_timeoff /* Don't collide with OpenBSD 7.4 <time.h>. */
+# endif
+# define EXTERN_TIMEOFF static
# endif
-# define EXTERN_TIMEOFF static
-#endif
/* This function is obsolescent and may disappear in future releases.
Callers can instead use mktime_z with a fixed-offset zone. */
@@ -2508,7 +2668,9 @@ timeoff(struct tm *tmp, long offset)
gmtcheck();
return time1(tmp, gmtsub, gmtptr, offset);
}
+#endif
+#if !USE_TIMEX_T
time_t
timegm(struct tm *tmp)
{
@@ -2521,6 +2683,7 @@ timegm(struct tm *tmp)
*tmp = tmcpy;
return t;
}
+#endif
static int_fast32_t
leapcorr(struct state const *sp, time_t t)
@@ -2541,15 +2704,16 @@ leapcorr(struct state const *sp, time_t t)
** XXX--is the below the right way to conditionalize??
*/
-#if STD_INSPIRED
+#if !USE_TIMEX_T
+# if STD_INSPIRED
/* NETBSD_INSPIRED_EXTERN functions are exported to callers if
NETBSD_INSPIRED is defined, and are private otherwise. */
-# if NETBSD_INSPIRED
-# define NETBSD_INSPIRED_EXTERN
-# else
-# define NETBSD_INSPIRED_EXTERN static
-# endif
+# if NETBSD_INSPIRED
+# define NETBSD_INSPIRED_EXTERN
+# else
+# define NETBSD_INSPIRED_EXTERN static
+# endif
/*
** IEEE Std 1003.1 (POSIX) says that 536457599
@@ -2630,17 +2794,13 @@ posix2time(time_t t)
return t;
}
-#endif /* STD_INSPIRED */
+# endif /* STD_INSPIRED */
-#if TZ_TIME_T
+# if TZ_TIME_T
-# if !USG_COMPAT
-# define daylight 0
-# define timezone 0
-# endif
-# if !ALTZONE
-# define altzone 0
-# endif
+# if !USG_COMPAT
+# define timezone 0
+# endif
/* Convert from the underlying system's time_t to the ersatz time_tz,
which is called 'time_t' in this file. Typically, this merely
@@ -2658,9 +2818,9 @@ time(time_t *p)
{
time_t r = sys_time(0);
if (r != (time_t) -1) {
- int_fast32_t offset = EPOCH_LOCAL ? (daylight ? timezone : altzone) : 0;
- if (increment_overflow32(&offset, -EPOCH_OFFSET)
- || increment_overflow_time(&r, offset)) {
+ iinntt offset = EPOCH_LOCAL ? timezone : 0;
+ if (offset < IINNTT_MIN + EPOCH_OFFSET
+ || increment_overflow_time_iinntt(&r, offset - EPOCH_OFFSET)) {
errno = EOVERFLOW;
r = -1;
}
@@ -2670,4 +2830,5 @@ time(time_t *p)
return r;
}
+# endif
#endif
diff --git a/contrib/tzcode/newctime.3 b/contrib/tzcode/newctime.3
index d19fd25b7926..9d09e5a55bd9 100644
--- a/contrib/tzcode/newctime.3
+++ b/contrib/tzcode/newctime.3
@@ -5,43 +5,34 @@
asctime, ctime, difftime, gmtime, localtime, mktime \- convert date and time
.SH SYNOPSIS
.nf
-.ie \n(.g .ds - \f(CR-\fP
-.el .ds - \-
.B #include <time.h>
.PP
-.B [[deprecated]] char *ctime(time_t const *clock);
-.PP
-/* Only in POSIX.1-2017 and earlier. */
-.B char *ctime_r(time_t const *clock, char *buf);
-.PP
-.B double difftime(time_t time1, time_t time0);
-.PP
-.B [[deprecated]] char *asctime(struct tm const *tm);
-.PP
-/* Only in POSIX.1-2017 and earlier. */
-.B "char *asctime_r(struct tm const *restrict tm,"
-.B " char *restrict result);"
-.PP
.B struct tm *localtime(time_t const *clock);
-.PP
.B "struct tm *localtime_r(time_t const *restrict clock,"
.B " struct tm *restrict result);"
-.PP
.B "struct tm *localtime_rz(timezone_t restrict zone,"
.B " time_t const *restrict clock,"
.B " struct tm *restrict result);"
.PP
.B struct tm *gmtime(time_t const *clock);
-.PP
.B "struct tm *gmtime_r(time_t const *restrict clock,"
.B " struct tm *restrict result);"
.PP
.B time_t mktime(struct tm *tm);
-.PP
.B "time_t mktime_z(timezone_t restrict zone,"
.B " struct tm *restrict tm);"
.PP
-.B cc ... \*-ltz
+.B double difftime(time_t time1, time_t time0);
+.PP
+.B [[deprecated]] char *asctime(struct tm const *tm);
+.B [[deprecated]] char *ctime(time_t const *clock);
+.PP
+/* Only in POSIX.1-2017 and earlier. */
+.B char *ctime_r(time_t const *clock, char *buf);
+.B "char *asctime_r(struct tm const *restrict tm,"
+.B " char *restrict result);"
+.PP
+.B cc ... \-ltz
.fi
.SH DESCRIPTION
.ie '\(en'' .ds en \-
@@ -54,82 +45,37 @@ asctime, ctime, difftime, gmtime, localtime, mktime \- convert date and time
\\$3\*(lq\\$1\*(rq\\$2
..
The
-.B ctime
-function
-converts a long integer, pointed to by
-.IR clock ,
-and returns a pointer to a
-string of the form
-.br
-.ce
-.eo
-Thu Nov 24 18:22:48 1986\n\0
-.br
-.ec
-Years requiring fewer than four characters are padded with leading zeroes.
-For years longer than four characters, the string is of the form
-.br
-.ce
-.eo
-Thu Nov 24 18:22:48 81986\n\0
-.ec
-.br
-with five spaces before the year.
-These unusual formats are designed to make it less likely that older
-software that expects exactly 26 bytes of output will mistakenly output
-misleading values for out-of-range years.
-.PP
-The
-.BI * clock
-timestamp represents the time in seconds since 1970-01-01 00:00:00
-Coordinated Universal Time (UTC).
-The POSIX standard says that timestamps must be nonnegative
-and must ignore leap seconds.
-Many implementations extend POSIX by allowing negative timestamps,
-and can therefore represent timestamps that predate the
-introduction of UTC and are some other flavor of Universal Time (UT).
-Some implementations support leap seconds, in contradiction to POSIX.
-.PP
-The
-.B ctime
-function is deprecated starting in C23.
-Callers can use
-.B localtime_r
-and
-.B strftime
-instead.
-.PP
-The
.B localtime
and
.B gmtime
functions
+convert an integer, pointed to by
+.IR clock ,
+and
return pointers to
.q "tm"
structures, described below.
+If the integer is out of range for conversion,
+these functions return a null pointer.
The
.B localtime
function
corrects for the time zone and any time zone adjustments
(such as Daylight Saving Time in the United States).
-.PP
The
.B gmtime
-function
-converts to Coordinated Universal Time.
+function converts to Coordinated Universal Time.
.PP
The
-.B asctime
-function
-converts a time value contained in a
-.q "tm"
-structure to a string,
-as shown in the above example,
-and returns a pointer to the string.
-This function is deprecated starting in C23.
-Callers can use
-.B strftime
-instead.
+.BI * clock
+timestamp represents the time in seconds since 1970-01-01 00:00:00
+Coordinated Universal Time (UTC).
+The POSIX standard says that timestamps must be nonnegative
+and must ignore leap seconds.
+Many implementations extend POSIX by allowing negative timestamps,
+and can therefore represent timestamps that predate the
+introduction of UTC and are some other flavor of Universal Time (UT).
+Some implementations support leap seconds, in contradiction to POSIX.
.PP
The
.B mktime
@@ -204,6 +150,52 @@ returns the difference between two calendar times,
expressed in seconds.
.PP
The
+.B asctime
+function
+converts a time value contained in a
+.q "tm"
+structure to a pointer to a
+string of the form
+.br
+.ce
+.eo
+Thu Nov 24 18:22:48 1986\n\0
+.br
+.ec
+Years requiring fewer than four characters are padded with leading zeroes.
+For years longer than four characters, the string is of the form
+.br
+.ce
+.eo
+Thu Nov 24 18:22:48 81986\n\0
+.ec
+.br
+with five spaces before the year.
+This unusual format is designed to make it less likely that older
+software that expects exactly 26 bytes of output will mistakenly output
+misleading values for out-of-range years.
+This function is deprecated starting in C23.
+Callers can use
+.B strftime
+instead.
+.PP
+The
+.B ctime
+function is equivalent to calliing
+.B localtime
+and then calling
+.B asctime
+on the result.
+Like
+.BR asctime ,
+this function is deprecated starting in C23.
+Callers can use
+.B localtime
+and
+.B strftime
+instead.
+.PP
+The
.BR ctime_r ,
.BR localtime_r ,
.BR gmtime_r ,
diff --git a/contrib/tzcode/newstrftime.3 b/contrib/tzcode/newstrftime.3
index a9997a092d0a..e9a382240ed2 100644
--- a/contrib/tzcode/newstrftime.3
+++ b/contrib/tzcode/newstrftime.3
@@ -40,8 +40,6 @@
strftime \- format date and time
.SH SYNOPSIS
.nf
-.ie \n(.g .ds - \f(CR-\fP
-.el .ds - \-
.B #include <time.h>
.PP
.B "size_t strftime(char *restrict buf, size_t maxsize,"
@@ -93,7 +91,7 @@ If a bracketed member name is followed by
.B strftime
can use the named member even though POSIX.1-2024 does not list it;
if the name is followed by
-.q \*- ,
+.q \- ,
.B strftime
ignores the member even though POSIX.1-2024 lists it
which means portable code should set it.
@@ -139,11 +137,14 @@ is replaced by the locale's appropriate date and time representation.
.IR tm_sec ,
.IR tm_gmtoff ,
.IR tm_zone ,
-.IR tm_isdst \*-].
+.IR tm_isdst \-].
.TP
%D
is equivalent to
.c %m/%d/%y .
+Although used in the United States for current dates,
+this format is ambiguous elsewhere
+and for dates that might involve other centuries.
.RI [ tm_year ,
.IR tm_mon ,
.IR tm_mday ]
@@ -167,6 +168,8 @@ is equivalent to
.TP
%G
is replaced by the ISO 8601 year with century as a decimal number.
+This is the year that includes the greater part of the week.
+(Monday as the first day of a week).
See also the
.c %V
conversion specification.
@@ -176,11 +179,7 @@ conversion specification.
.TP
%g
is replaced by the ISO 8601 year without century as a decimal number [00,99].
-This is the year that includes the greater part of the week.
-(Monday as the first day of a week).
-See also the
-.c %V
-conversion specification.
+Since it omits the century, it is ambiguous for dates.
.RI [ tm_year ,
.IR tm_yday ,
.IR tm_wday ]
@@ -249,9 +248,22 @@ of leap seconds.
is replaced by the number of seconds since the Epoch (see
.BR ctime (3)).
Although %s is reliable in this implementation,
-it can have glitches on other platforms (notably platforms lacking
-.IR tm_gmtoff ),
-so portable code should format a
+it can have glitches on other platforms
+(notably obsolescent platforms lacking
+.I tm_gmtoff
+or where
+.B time_t
+is no wider than int), and POSIX allows
+.B strftime
+to set
+.B errno
+to
+.B EINVAL
+or
+.B EOVERFLOW
+and return 0 if the number of seconds would be negative or out of range for
+.BR time_t .
+Portable code should therefore format a
.B time_t
value directly via something like
.B sprintf
@@ -267,7 +279,7 @@ with "%s".
.IR tm_min ,
.IR tm_sec ,
.IR tm_gmtoff +,
-.IR tm_isdst \*-].
+.IR tm_isdst \-].
.TP
%T
is replaced by the time in the format
@@ -284,7 +296,7 @@ is replaced by the week number of the year (Sunday as the first day of
the week) as a decimal number [00,53].
.RI [ tm_wday ,
.IR tm_yday ,
-.IR tm_year \*-]
+.IR tm_year \-]
.TP
%u
is replaced by the weekday (Monday as the first day of the week)
@@ -318,31 +330,33 @@ as a decimal number [0,6].
.TP
%X
is replaced by the locale's appropriate time representation.
-.RI [ tm_year \*-,
-.IR tm_yday \*-,
-.IR tm_mon \*-,
-.IR tm_mday \*-,
-.IR tm_wday \*-,
+.RI [ tm_year \-,
+.IR tm_yday \-,
+.IR tm_mon \-,
+.IR tm_mday \-,
+.IR tm_wday \-,
.IR tm_hour ,
.IR tm_min ,
.IR tm_sec ,
.IR tm_gmtoff ,
.IR tm_zone ,
-.IR tm_isdst \*-].
+.IR tm_isdst \-].
.TP
%x
is replaced by the locale's appropriate date representation.
+This format can be ambiguous for dates, e.g.,
+it can generate "01/02/03" in the C locale.
.RI [ tm_year ,
.IR tm_yday ,
.IR tm_mon ,
.IR tm_mday ,
.IR tm_wday ,
-.IR tm_hour \*-,
-.IR tm_min \*-,
-.IR tm_sec \*-,
-.IR tm_gmtoff \*-,
-.IR tm_zone \*-,
-.IR tm_isdst \*-].
+.IR tm_hour \-,
+.IR tm_min \-,
+.IR tm_sec \-,
+.IR tm_gmtoff \-,
+.IR tm_zone \-,
+.IR tm_isdst \-].
.TP
%Y
is replaced by the year with century as a decimal number.
@@ -350,28 +364,29 @@ is replaced by the year with century as a decimal number.
.TP
%y
is replaced by the year without century as a decimal number [00,99].
+Since it omits the century, it is ambiguous for dates.
.RI [ tm_year ]
.TP
%Z
is replaced by the time zone abbreviation,
or by the empty string if this is not determinable.
.RI [ tm_zone ,
-.IR tm_isdst \*-]
+.IR tm_isdst \-]
.TP
%z
is replaced by the offset from the Prime Meridian
-in the format +HHMM or \*-HHMM (ISO 8601) as appropriate,
+in the format +HHMM or \-HHMM (ISO 8601) as appropriate,
with positive values representing locations east of Greenwich,
or by the empty string if this is not determinable.
-The numeric time zone abbreviation \*-0000 is used when the time is
+The numeric time zone abbreviation \-0000 is used when the time is
Universal Time
but local time is indeterminate; by convention this is used for
locations while uninhabited, and corresponds to a zero offset when the
time zone abbreviation begins with
-.q "\*-" .
+.q "\-" .
.RI [ tm_gmtoff ,
.IR tm_zone +,
-.IR tm_isdst \*-]
+.IR tm_isdst \-]
.TP
%%
is replaced by a single %.
@@ -418,15 +433,6 @@ This function fails if:
The total number of resulting bytes, including the terminating
NUL character, is more than
.IR maxsize .
-.PP
-This function may fail if:
-.TP
-[EOVERFLOW]
-The format includes an
-.c %s
-conversion and the number of seconds since the Epoch cannot be represented
-in a
-.c time_t .
.SH SEE ALSO
.BR date (1),
.BR getenv (3),
diff --git a/contrib/tzcode/newtzset.3 b/contrib/tzcode/newtzset.3
index 661fb25be098..db6bfa7fa64c 100644
--- a/contrib/tzcode/newtzset.3
+++ b/contrib/tzcode/newtzset.3
@@ -5,8 +5,6 @@
tzset \- initialize time conversion information
.SH SYNOPSIS
.nf
-.ie \n(.g .ds - \f(CR-\fP
-.el .ds - \-
.B #include <time.h>
.PP
.BI "timezone_t tzalloc(char const *" TZ );
@@ -23,7 +21,7 @@ tzset \- initialize time conversion information
.br
.B extern int daylight;
.PP
-.B cc ... \*-ltz
+.B cc ... \-ltz
.fi
.SH DESCRIPTION
.ie '\(en'' .ds en \-
@@ -110,7 +108,7 @@ except a leading colon
digits, comma
.RB ( , ),
ASCII minus
-.RB ( \*- ),
+.RB ( \- ),
ASCII plus
.RB ( + ),
and NUL bytes are allowed.
@@ -150,7 +148,7 @@ daylight saving time is assumed to be one hour ahead of standard time. One or
more digits may be used; the value is always interpreted as a decimal
number. The hour must be between zero and 24, and the minutes (and
seconds) \*(en if present \*(en between zero and 59. If preceded by a
-.q "\*-" ,
+.q "\-" ,
the time zone shall be east of the Prime Meridian; otherwise it shall be
west (which may be indicated by an optional preceding
.q "+" .
@@ -239,7 +237,7 @@ values that directly specify the timezone.
stands for US Eastern Standard
Time (EST), 5 hours behind UT, without daylight saving.
.TP
-.B <+12>\*-12<+13>,M11.1.0,M1.2.1/147
+.B <+12>\-12<+13>,M11.1.0,M1.2.1/147
stands for Fiji time, 12 hours ahead
of UT, springing forward on November's first Sunday at 02:00, and
falling back on January's second Monday at 147:00 (i.e., 03:00 on the
@@ -249,34 +247,34 @@ and daylight saving time are
and
.q "+13".
.TP
-.B IST\*-2IDT,M3.4.4/26,M10.5.0
+.B IST\-2IDT,M3.4.4/26,M10.5.0
stands for Israel Standard Time (IST) and Israel Daylight Time (IDT),
2 hours ahead of UT, springing forward on March's fourth
Thursday at 26:00 (i.e., 02:00 on the first Friday on or after March
23), and falling back on October's last Sunday at 02:00.
.TP
-.B <\*-04>4<\*-03>,J1/0,J365/25
+.B <\-04>4<\-03>,J1/0,J365/25
stands for permanent daylight saving time, 3 hours behind UT with
abbreviation
-.q "\*-03".
+.q "\-03".
There is a dummy fall-back transition on December 31 at 25:00 daylight
saving time (i.e., 24:00 standard time, equivalent to January 1 at
00:00 standard time), and a simultaneous spring-forward transition on
January 1 at 00:00 standard time, so daylight saving time is in effect
all year and the initial
-.B <\*-04>
+.B <\-04>
is a placeholder.
.TP
-.B <\*-03>3<\*-02>,M3.5.0/\*-2,M10.5.0/\*-1
+.B <\-03>3<\-02>,M3.5.0/\-2,M10.5.0/\-1
stands for time in western Greenland, 3 hours behind UT, where clocks
follow the EU rules of
springing forward on March's last Sunday at 01:00 UT (\-02:00 local
time, i.e., 22:00 the previous day) and falling back on October's last
Sunday at 01:00 UT (\-01:00 local time, i.e., 23:00 the previous day).
The abbreviations for standard and daylight saving time are
-.q "\*-03"
+.q "\-03"
and
-.q "\*-02".
+.q "\-02".
.PP
If
.I TZ
diff --git a/contrib/tzcode/private.h b/contrib/tzcode/private.h
index 9c5edff252fd..532d9ddc81c8 100644
--- a/contrib/tzcode/private.h
+++ b/contrib/tzcode/private.h
@@ -37,6 +37,38 @@
# define SUPPORT_C89 1
#endif
+
+/* The following feature-test macros should be defined before
+ any #include of a system header. */
+
+/* Enable tm_gmtoff, tm_zone, and environ on GNUish systems. */
+#define _GNU_SOURCE 1
+/* Fix asctime_r on Solaris 11. */
+#define _POSIX_PTHREAD_SEMANTICS 1
+/* Enable strtoimax on pre-C99 Solaris 11. */
+#define __EXTENSIONS__ 1
+/* Cause MS-Windows headers to define POSIX names. */
+#define _CRT_DECLARE_NONSTDC_NAMES 1
+/* Prevent MS-Windows headers from defining min and max. */
+#define NOMINMAX 1
+
+/* On GNUish systems where time_t might be 32 or 64 bits, use 64.
+ On these platforms _FILE_OFFSET_BITS must also be 64; otherwise
+ setting _TIME_BITS to 64 does not work. The code does not
+ otherwise rely on _FILE_OFFSET_BITS being 64, since it does not
+ use off_t or functions like 'stat' that depend on off_t. */
+#ifndef _TIME_BITS
+# ifndef _FILE_OFFSET_BITS
+# define _FILE_OFFSET_BITS 64
+# endif
+# if _FILE_OFFSET_BITS == 64
+# define _TIME_BITS 64
+# endif
+#endif
+
+/* End of feature-test macro definitions. */
+
+
#ifndef __STDC_VERSION__
# define __STDC_VERSION__ 0
#endif
@@ -51,6 +83,7 @@
#endif
#if __STDC_VERSION__ < 202311
+# undef static_assert
# define static_assert(cond) extern int static_assert_check[(cond) ? 1 : -1]
#endif
@@ -87,11 +120,11 @@
#if !defined HAVE_GETTEXT && defined __has_include
# if __has_include(<libintl.h>)
-# define HAVE_GETTEXT true
+# define HAVE_GETTEXT 1
# endif
#endif
#ifndef HAVE_GETTEXT
-# define HAVE_GETTEXT false
+# define HAVE_GETTEXT 0
#endif
#ifndef HAVE_INCOMPATIBLE_CTIME_R
@@ -124,20 +157,20 @@
#if !defined HAVE_SYS_STAT_H && defined __has_include
# if !__has_include(<sys/stat.h>)
-# define HAVE_SYS_STAT_H false
+# define HAVE_SYS_STAT_H 0
# endif
#endif
#ifndef HAVE_SYS_STAT_H
-# define HAVE_SYS_STAT_H true
+# define HAVE_SYS_STAT_H 1
#endif
#if !defined HAVE_UNISTD_H && defined __has_include
# if !__has_include(<unistd.h>)
-# define HAVE_UNISTD_H false
+# define HAVE_UNISTD_H 0
# endif
#endif
#ifndef HAVE_UNISTD_H
-# define HAVE_UNISTD_H true
+# define HAVE_UNISTD_H 1
#endif
#ifndef NETBSD_INSPIRED
@@ -149,25 +182,6 @@
# define ctime_r _incompatible_ctime_r
#endif /* HAVE_INCOMPATIBLE_CTIME_R */
-/* Enable tm_gmtoff, tm_zone, and environ on GNUish systems. */
-#define _GNU_SOURCE 1
-/* Fix asctime_r on Solaris 11. */
-#define _POSIX_PTHREAD_SEMANTICS 1
-/* Enable strtoimax on pre-C99 Solaris 11. */
-#define __EXTENSIONS__ 1
-
-/* On GNUish systems where time_t might be 32 or 64 bits, use 64.
- On these platforms _FILE_OFFSET_BITS must also be 64; otherwise
- setting _TIME_BITS to 64 does not work. The code does not
- otherwise rely on _FILE_OFFSET_BITS being 64, since it does not
- use off_t or functions like 'stat' that depend on off_t. */
-#ifndef _FILE_OFFSET_BITS
-# define _FILE_OFFSET_BITS 64
-#endif
-#if !defined _TIME_BITS && _FILE_OFFSET_BITS == 64
-# define _TIME_BITS 64
-#endif
-
/*
** Nested includes
*/
@@ -260,6 +274,10 @@
# endif
#endif
+#ifndef HAVE_SNPRINTF
+# define HAVE_SNPRINTF (!PORT_TO_C89 || 199901 <= __STDC_VERSION__)
+#endif
+
#ifndef HAVE_STRFTIME_L
# if _POSIX_VERSION < 200809
# define HAVE_STRFTIME_L 0
@@ -305,7 +323,7 @@
** stdint.h, even with pre-C99 compilers.
*/
#if !defined HAVE_STDINT_H && defined __has_include
-# define HAVE_STDINT_H true /* C23 __has_include implies C99 stdint.h. */
+# define HAVE_STDINT_H 1 /* C23 __has_include implies C99 stdint.h. */
#endif
#ifndef HAVE_STDINT_H
# define HAVE_STDINT_H \
@@ -375,11 +393,15 @@ typedef int int_fast32_t;
# endif
#endif
+#ifndef INT_LEAST32_MAX
+typedef int_fast32_t int_least32_t;
+#endif
+
#ifndef INTMAX_MAX
# ifdef LLONG_MAX
typedef long long intmax_t;
# ifndef HAVE_STRTOLL
-# define HAVE_STRTOLL true
+# define HAVE_STRTOLL 1
# endif
# if HAVE_STRTOLL
# define strtoimax strtoll
@@ -459,7 +481,7 @@ typedef unsigned long uintmax_t;
hosts, unless compiled with -DHAVE_STDCKDINT_H=0 or with pre-C23 EDG. */
#if !defined HAVE_STDCKDINT_H && defined __has_include
# if __has_include(<stdckdint.h>)
-# define HAVE_STDCKDINT_H true
+# define HAVE_STDCKDINT_H 1
# endif
#endif
#ifdef HAVE_STDCKDINT_H
@@ -554,13 +576,26 @@ typedef unsigned long uintmax_t;
# define ATTRIBUTE_REPRODUCIBLE /* empty */
#endif
+#if HAVE___HAS_C_ATTRIBUTE
+# if __has_c_attribute(unsequenced)
+# define ATTRIBUTE_UNSEQUENCED [[unsequenced]]
+# endif
+#endif
+#ifndef ATTRIBUTE_UNSEQUENCED
+# define ATTRIBUTE_UNSEQUENCED /* empty */
+#endif
+
/* GCC attributes that are useful in tzcode.
+ __attribute__((const)) is stricter than [[unsequenced]],
+ so the latter is an adequate substitute in non-GCC C23 platforms.
__attribute__((pure)) is stricter than [[reproducible]],
so the latter is an adequate substitute in non-GCC C23 platforms. */
#if __GNUC__ < 3
+# define ATTRIBUTE_CONST ATTRIBUTE_UNSEQUENCED
# define ATTRIBUTE_FORMAT(spec) /* empty */
# define ATTRIBUTE_PURE ATTRIBUTE_REPRODUCIBLE
#else
+# define ATTRIBUTE_CONST __attribute__((const))
# define ATTRIBUTE_FORMAT(spec) __attribute__((format spec))
# define ATTRIBUTE_PURE __attribute__((pure))
#endif
@@ -593,6 +628,12 @@ typedef unsigned long uintmax_t;
# define RESERVE_STD_EXT_IDS 0
#endif
+#ifdef time_tz
+# define defined_time_tz true
+#else
+# define defined_time_tz false
+#endif
+
/* If standard C identifiers with external linkage (e.g., localtime)
are reserved and are not already being renamed anyway, rename them
as if compiling with '-Dtime_tz=time_t'. */
@@ -608,9 +649,9 @@ typedef unsigned long uintmax_t;
** typical platforms.
*/
#if defined time_tz || EPOCH_LOCAL || EPOCH_OFFSET != 0
-# define TZ_TIME_T 1
+# define TZ_TIME_T true
#else
-# define TZ_TIME_T 0
+# define TZ_TIME_T false
#endif
#if defined LOCALTIME_IMPLEMENTATION && TZ_TIME_T
@@ -707,7 +748,7 @@ DEPRECATED_IN_C23 char *ctime(time_t const *);
char *asctime_r(struct tm const *restrict, char *restrict);
char *ctime_r(time_t const *, char *);
#endif
-double difftime(time_t, time_t);
+ATTRIBUTE_CONST double difftime(time_t, time_t);
size_t strftime(char *restrict, size_t, char const *restrict,
struct tm const *restrict);
# if HAVE_STRFTIME_L
@@ -729,9 +770,9 @@ void tzset(void);
|| defined __GLIBC__ || defined __tm_zone /* musl */ \
|| defined __FreeBSD__ || defined __NetBSD__ || defined __OpenBSD__ \
|| (defined __APPLE__ && defined __MACH__))
-# define HAVE_DECL_TIMEGM true
+# define HAVE_DECL_TIMEGM 1
# else
-# define HAVE_DECL_TIMEGM false
+# define HAVE_DECL_TIMEGM 0
# endif
#endif
#if !HAVE_DECL_TIMEGM && !defined timegm
@@ -771,7 +812,11 @@ extern long altzone;
*/
#ifndef STD_INSPIRED
-# define STD_INSPIRED 0
+# ifdef __NetBSD__
+# define STD_INSPIRED 1
+# else
+# define STD_INSPIRED 0
+# endif
#endif
#if STD_INSPIRED
# if TZ_TIME_T || !defined offtime
@@ -880,7 +925,7 @@ ATTRIBUTE_PURE time_t time2posix_z(timezone_t, time_t);
default: TIME_T_MAX_NO_PADDING) \
: (time_t) -1)
enum { SIGNED_PADDING_CHECK_NEEDED
- = _Generic((time_t) 0,
+ = _Generic((time_t) 0,
signed char: false, short: false,
int: false, long: false, long long: false,
default: true) };
@@ -927,8 +972,8 @@ static_assert(! TYPE_SIGNED(time_t) || ! SIGNED_PADDING_CHECK_NEEDED
# define UNINIT_TRAP 0
#endif
-/* localtime.c sometimes needs access to timeoff if it is not already public.
- tz_private_timeoff should be used only by localtime.c. */
+/* strftime.c sometimes needs access to timeoff if it is not already public.
+ tz_private_timeoff should be used only by localtime.c and strftime.c. */
#if (!defined EXTERN_TIMEOFF \
&& defined TM_GMTOFF && (200809 < _POSIX_VERSION || ! UNINIT_TRAP))
# ifndef timeoff
diff --git a/contrib/tzcode/strftime.c b/contrib/tzcode/strftime.c
index 755d341fa6d9..487a5234cbc5 100644
--- a/contrib/tzcode/strftime.c
+++ b/contrib/tzcode/strftime.c
@@ -39,8 +39,63 @@
#include <locale.h>
#include <stdio.h>
+/* If true, the value returned by an idealized unlimited-range mktime
+ always fits into an integer type with bounds MIN and MAX.
+ If false, the value might not fit.
+ This macro is usable in #if if its arguments are.
+ Add or subtract 2**31 - 1 for the maximum UT offset allowed in a TZif file,
+ divide by the maximum number of non-leap seconds in a year,
+ divide again by two just to be safe,
+ and account for the tm_year origin (1900) and time_t origin (1970). */
+#define MKTIME_FITS_IN(min, max) \
+ ((min) < 0 \
+ && ((min) + 0x7fffffff) / 366 / 24 / 60 / 60 / 2 + 1970 - 1900 < INT_MIN \
+ && INT_MAX < ((max) - 0x7fffffff) / 366 / 24 / 60 / 60 / 2 + 1970 - 1900)
+
+/* MKTIME_MIGHT_OVERFLOW is true if mktime can fail due to time_t overflow
+ or if it is not known whether mktime can fail,
+ and is false if mktime definitely cannot fail.
+ This macro is usable in #if, and so does not use TIME_T_MAX or sizeof.
+ If the builder has not configured this macro, guess based on what
+ known platforms do. When in doubt, guess true. */
+#ifndef MKTIME_MIGHT_OVERFLOW
+# if defined __FreeBSD__ || defined __NetBSD__ || defined __OpenBSD__
+# include <sys/param.h>
+# endif
+# if ((/* The following heuristics assume native time_t. */ \
+ defined_time_tz) \
+ || ((/* Traditional time_t is 'long', so if 'long' is not wide enough \
+ assume overflow unless we're on a known-safe host. */ \
+ !MKTIME_FITS_IN(LONG_MIN, LONG_MAX)) \
+ && (/* GNU C Library 2.29 (2019-02-01) and later has 64-bit time_t \
+ if __TIMESIZE is 64. */ \
+ !defined __TIMESIZE || __TIMESIZE < 64) \
+ && (/* FreeBSD 12 r320347 (__FreeBSD_version 1200036; 2017-06-26), \
+ and later has 64-bit time_t on all platforms but i386 which \
+ is currently scheduled for end-of-life on 2028-11-30. */ \
+ !defined __FreeBSD_version || __FreeBSD_version < 1200036 \
+ || defined __i386) \
+ && (/* NetBSD 6.0 (2012-10-17) and later has 64-bit time_t. */ \
+ !defined __NetBSD_Version__ || __NetBSD_Version__ < 600000000) \
+ && (/* OpenBSD 5.5 (2014-05-01) and later has 64-bit time_t. */ \
+ !defined OpenBSD || OpenBSD < 201405)))
+# define MKTIME_MIGHT_OVERFLOW 1
+# else
+# define MKTIME_MIGHT_OVERFLOW 0
+# endif
+#endif
+/* Check that MKTIME_MIGHT_OVERFLOW is consistent with time_t's range. */
+static_assert(MKTIME_MIGHT_OVERFLOW
+ || MKTIME_FITS_IN(TIME_T_MIN, TIME_T_MAX));
+
+#if MKTIME_MIGHT_OVERFLOW
+/* Do this after system includes as it redefines time_t, mktime, timeoff. */
+# define USE_TIMEX_T true
+# include "localtime.c"
+#endif
+
#ifndef DEPRECATE_TWO_DIGIT_YEARS
-# define DEPRECATE_TWO_DIGIT_YEARS false
+# define DEPRECATE_TWO_DIGIT_YEARS 0
#endif
struct lc_time_T {
@@ -135,10 +190,6 @@ strftime(char *restrict s, size_t maxsize, char const *restrict format,
tzset();
p = _fmt(format, t, s, s + maxsize, &warn);
- if (!p) {
- errno = EOVERFLOW;
- return 0;
- }
if (DEPRECATE_TWO_DIGIT_YEARS
&& warn != IN_NONE && getenv(YEAR_2000_NAME)) {
fprintf(stderr, "\n");
@@ -170,7 +221,12 @@ _fmt(const char *format, const struct tm *t, char *pt,
if (*format == '%') {
label:
switch (*++format) {
- case '\0':
+ default:
+ /* Output unknown conversion specifiers as-is,
+ to aid debugging. This includes '%' at
+ format end. This conforms to C23 section
+ 7.29.3.5 paragraph 6, which says behavior
+ is undefined here. */
--format;
break;
case 'A':
@@ -327,16 +383,17 @@ label:
tm.tm_mday = t->tm_mday;
tm.tm_mon = t->tm_mon;
tm.tm_year = t->tm_year;
+
+ /* Get the time_t value for TM.
+ Native time_t, or its redefinition
+ by localtime.c above, is wide enough
+ so that this cannot overflow. */
#ifdef TM_GMTOFF
mkt = timeoff(&tm, t->TM_GMTOFF);
#else
tm.tm_isdst = t->tm_isdst;
mkt = mktime(&tm);
#endif
- /* If mktime fails, %s expands to the
- value of (time_t) -1 as a failure
- marker; this is better in practice
- than strftime failing. */
if (TYPE_SIGNED(time_t)) {
intmax_t n = mkt;
sprintf(buf, "%"PRIdMAX, n);
@@ -590,12 +647,6 @@ label:
warnp);
continue;
case '%':
- /*
- ** X311J/88-090 (4.12.3.5): if conversion char is
- ** undefined, behavior is undefined. Print out the
- ** character itself as printf(3) also does.
- */
- default:
break;
}
}
diff --git a/contrib/tzcode/theory.html b/contrib/tzcode/theory.html
index d3573ede0dfb..352a3d87078f 100644
--- a/contrib/tzcode/theory.html
+++ b/contrib/tzcode/theory.html
@@ -123,8 +123,9 @@ If geolocation information is available, a selection interface can
locate the user on a timezone map or prioritize names that are
geographically close. For an example selection interface, see the
<code>tzselect</code> program in the <code><abbr>tz</abbr></code> code.
-The <a href="https://cldr.unicode.org">Unicode Common Locale Data
-Repository</a> contains data that may be useful for other selection
+Unicode's <a href="https://cldr.unicode.org">Common Locale Data
+Repository (<abbr>CLDR</abbr>)</a>
+contains data that may be useful for other selection
interfaces; it maps timezone names like <code>Europe/Prague</code> to
locale-dependent strings like "Prague", "Praha", "Прага", and "布拉格".
</p>
@@ -200,6 +201,8 @@ in decreasing order of importance:
<li>
A name must not be empty, or contain '<code>//</code>', or
start or end with '<code>/</code>'.
+ Also, a name must not be '<code>Etc/Unknown</code>', as
+ <abbr>CLDR</abbr> uses that string for an unknown or invalid timezone.
</li>
<li>
Do not use names that differ only in case.
@@ -220,10 +223,18 @@ in decreasing order of importance:
do not need locations, since local time is not defined there.
</li>
<li>
- If all the clocks in a timezone have agreed since 1970,
- do not bother to include more than one timezone
- even if some of the clocks disagreed before 1970.
+ If all clocks in a region have agreed since 1970,
+ give them just one name even if some of the clocks disagreed before 1970,
+ or reside in different countries or in notable or faraway locations.
Otherwise these tables would become annoyingly large.
+ For example, do not create a name <code>Indian/Crozet</code>
+ as a near-duplicate or alias of <code>Asia/Dubai</code>
+ merely because they are different countries or territories,
+ or their clocks disagreed before 1970, or the
+ <a href="https://en.wikipedia.org/wiki/Crozet_Islands">Crozet Islands</a>
+ are notable in their own right,
+ or the Crozet Islands are not adjacent to other locations
+ that use <code>Asia/Dubai</code>.
</li>
<li>
If boundaries between regions are fluid, such as during a war or
@@ -579,10 +590,10 @@ in decreasing order of importance:
locations while uninhabited.
The leading '<code>-</code>' is a flag that the <abbr>UT</abbr> offset is in
some sense undefined; this notation is derived
- from <a href="https://datatracker.ietf.org/doc/html/rfc3339">Internet
+ from <a href="https://www.rfc-editor.org/rfc/rfc3339">Internet
<abbr title="Request For Comments">RFC</abbr> 3339</a>.
(The abbreviation 'Z' that
- <a href="https://datatracker.ietf.org/doc/html/rfc9557">Internet
+ <a href="https://www.rfc-editor.org/rfc/rfc9557">Internet
<abbr>RFC</abbr> 9557</a> uses for this concept
would violate the POSIX requirement
of at least three characters in an abbreviation.)
@@ -1115,8 +1126,8 @@ However POSIX.1-2024, like earlier POSIX editions, has some limitations:
the name of a file from which time-related information is read.
The file's format is <dfn><abbr>TZif</abbr></dfn>,
a timezone information format that contains binary data; see
- <a href="https://datatracker.ietf.org/doc/html/8536">Internet
- <abbr>RFC</abbr> 8536</a>.
+ <a href="https://www.rfc-editor.org/rfc/9636">Internet
+ <abbr>RFC</abbr> 9636</a>.
The daylight saving time rules to be used for a
particular timezone are encoded in the
<abbr>TZif</abbr> file; the format of the file allows <abbr>US</abbr>,
@@ -1201,12 +1212,15 @@ The vestigial <abbr>API</abbr>s are:
The <code>tm_isdst</code> member is almost never needed and most of
its uses should be discouraged in favor of the abovementioned
<abbr>API</abbr>s.
+ It was intended as an index into the <code>tzname</code> variable,
+ but as mentioned previously that usage is obsolete.
Although it can still be used in arguments to
<code>mktime</code> to disambiguate timestamps near
a <abbr>DST</abbr> transition when the clock jumps back on
platforms lacking <code>tm_gmtoff</code>, this
- disambiguation does not work when standard time itself jumps back,
- which can occur when a location changes to a time zone with a
+ disambiguation works only for proleptic <code>TZ</code> strings;
+ it does not work in general for geographical timezones,
+ such as when a location changes to a time zone with a
lesser <abbr>UT</abbr> offset.
</li>
</ul>
@@ -1223,8 +1237,8 @@ The vestigial <abbr>API</abbr>s are:
Programs that in the past used the <code>timezone</code> function
may now examine <code>localtime(&amp;clock)-&gt;tm_zone</code>
(if <code>TM_ZONE</code> is defined) or
- <code>tzname[localtime(&amp;clock)-&gt;tm_isdst]</code>
- (if <code>HAVE_TZNAME</code> is nonzero) to learn the correct time
+ use <code>strftime</code> with a <code>%Z</code> conversion specification
+ to learn the correct time
zone abbreviation to use.
</li>
<li>
diff --git a/contrib/tzcode/tz-link.html b/contrib/tzcode/tz-link.html
index be2aae5489d6..ad2cc972a4f9 100644
--- a/contrib/tzcode/tz-link.html
+++ b/contrib/tzcode/tz-link.html
@@ -194,9 +194,9 @@ After obtaining the code and data files, see the
The code lets you compile the <code><abbr>tz</abbr></code> source files into
machine-readable binary files, one for each location. The binary files
are in a special format specified by
-<a href="https://datatracker.ietf.org/doc/html/8536">The
+<a href="https://www.rfc-editor.org/rfc/9636">The
Time Zone Information Format (<abbr>TZif</abbr>)</a>
-(Internet <abbr title="Request For Comments">RFC</abbr> 8536).
+(Internet <abbr title="Request For Comments">RFC</abbr> 9636).
The code also lets
you read a <abbr>TZif</abbr> file and interpret timestamps for that
location.</p>
@@ -260,7 +260,7 @@ Studio Code</a>.
</p>
<p>
For further information about updates, please see
-<a href="https://datatracker.ietf.org/doc/html/rfc6557">Procedures for
+<a href="https://www.rfc-editor.org/rfc/rfc6557">Procedures for
Maintaining the Time Zone Database</a> (Internet <abbr>RFC</abbr> 6557).
More detail can be
found in <a href="theory.html">Theory and pragmatics of the
@@ -379,26 +379,26 @@ calculates the current time difference between locations.</li>
<li>The <a href="https://www.ietf.org">Internet Engineering Task Force</a>'s
<a href="https://datatracker.ietf.org/wg/tzdist/charter/">Time Zone Data
Distribution Service (tzdist) working group</a> defined <a
-href="https://datatracker.ietf.org/doc/html/rfc7808">TZDIST</a>
+href="https://www.rfc-editor.org/rfc/rfc7808">TZDIST</a>
(Internet <abbr>RFC</abbr> 7808), a time zone data distribution service,
-along with <a href="https://datatracker.ietf.org/doc/html/rfc7809">CalDAV</a>
+along with <a href="https://www.rfc-editor.org/rfc/rfc7809">CalDAV</a>
(Internet <abbr>RFC</abbr> 7809), a calendar access protocol for
transferring time zone data by reference.
<a href="https://devguide.calconnect.org/Time-Zones/TZDS/">TZDIST
implementations</a> are available.
The <a href="https://www.ietf.org/mailman/listinfo/tzdist-bis">tzdist-bis
mailing list</a> discusses possible extensions.</li>
-<li>The <a href="https://datatracker.ietf.org/doc/html/rfc5545">
+<li>The <a href="https://www.rfc-editor.org/rfc/rfc5545">
Internet Calendaring and Scheduling Core Object Specification
(iCalendar)</a> (Internet <abbr>RFC</abbr> 5445)
covers time zone
data; see its VTIMEZONE calendar component.
The iCalendar format requires specialized parsers and generators; a
-variant <a href="https://datatracker.ietf.org/doc/html/rfc6321">xCal</a>
+variant <a href="https://www.rfc-editor.org/rfc/rfc6321">xCal</a>
(Internet <abbr>RFC</abbr> 6321) uses
<a href="https://www.w3.org/XML/"><abbr
title="Extensible Markup Language">XML</abbr></a> format, and a variant
-<a href="https://datatracker.ietf.org/doc/html/rfc7265">jCal</a>
+<a href="https://www.rfc-editor.org/rfc/rfc7265">jCal</a>
(Internet <abbr>RFC</abbr> 7265)
uses <a href="https://www.json.org/json-en.html"><abbr
title="JavaScript Object Notation">JSON</abbr></a> format.</li>
@@ -935,7 +935,13 @@ with perhaps the best-documented history of clock adjustments.</dd>
<dt>United States</dt>
<dd>The Department of Transportation's <a
href="https://www.transportation.gov/regulations/recent-time-zone-proceedings">Recent
-Time Zone Proceedings</a> lists changes to time zone boundaries.</dd>
+Time Zone Proceedings</a> lists changes to
+official written time zone boundaries, and its <a
+href="https://geodata.bts.gov/datasets/usdot::time-zones/about">Time
+Zones dataset</a> maps current boundaries.
+These boundaries are only for standard time, so the current map puts
+all of Arizona in one time zone even though part of Arizona
+observes <abbr>DST</abbr> and part does not.</dd>
<dt>Uruguay</dt>
<dd>The Oceanography, Hydrography, and Meteorology Service of the Uruguayan
Navy (SOHMA) publishes an annual <a
@@ -979,6 +985,14 @@ a Sleep Research Society position statement</a>.
doi:<a href="https://doi.org/10.1093/sleep/zsac236">10.1093/sleep/zsac236</a>.
After reviewing the scientific literature, the Sleep Research Society
advocates permanent standard time due to its health benefits.
+<li>Neumann P, von Blanckenburg K. <a
+href="https://journals.sagepub.com/doi/full/10.1177/0961463X241310562">What
+time will it be? A comprehensive literature review on daylight saving time</a>.
+<em>Time Soc</em>. 2025-01-21.
+doi:<a href="https://doi.org/10.1177/0961463X241310562">10.1177/0961463X241310562</a>.
+This reviews DST's effects on electricity, health, crime, road safety,
+and the economy, focusing on research since 2010, and concludes that
+year-round standard time is preferable overall.
<li>Rishi MA, Cheng JY, Strang AR <em>et al</em>.
<a href="https://jcsm.aasm.org/doi/10.5664/jcsm.10898">Permanent standard time
is the optimal choice for health and safety:
@@ -994,7 +1008,8 @@ should we abolish Daylight Saving Time?</a>
<em>J Biol Rhythms.</em> 2019;34(3):227&ndash;230.
doi:<a href="https://doi.org/10.1177/0748730419854197">10.1177/0748730419854197</a>.
The Society for Research on Biological Rhythms
-opposes DST changes and permanent DST, and advocates that governments adopt
+opposes <abbr>DST</abbr> changes and permanent <abbr>DST</abbr>,
+and advocates that governments adopt
"permanent Standard Time for the health and safety of their citizens".</li>
</ul>
</section>
@@ -1023,7 +1038,7 @@ title="Institute of Electrical and Electronics Engineers">IEEE</abbr> 1588)
can achieve submicrosecond clock accuracy on a local area network
with special-purpose hardware.</li>
<li><a
-href="https://datatracker.ietf.org/doc/html/rfc4833">Timezone
+href="https://www.rfc-editor.org/rfc/rfc4833">Timezone
Options for <abbr title="Dynamic Host Configuration Protocol">DHCP</abbr></a>
(Internet <abbr>RFC</abbr> 4833)
specifies a <a
@@ -1105,7 +1120,7 @@ the abovementioned <abbr>NTP</abbr> implementations, <a
href="https://github.com/google/unsmear">supports</a> conversion between
<abbr>UTC</abbr> and smeared <abbr>POSIX</abbr> timestamps, and is used by major
cloud service providers. However, according to
-<a href="https://datatracker.ietf.org/doc/html/rfc8633#section-3.7.1">&sect;3.7.1 of
+<a href="https://www.rfc-editor.org/rfc/rfc8633#section-3.7.1">&sect;3.7.1 of
Network Time Protocol Best Current Practices</a>
(Internet <abbr>RFC</abbr> 8633), leap smearing is not suitable for
applications requiring accurate <abbr>UTC</abbr> or civil time,
@@ -1165,16 +1180,16 @@ interchange &ndash; Part 1: Basic rules</em></a>.</li>
<a href="https://www.w3.org/TR/xmlschema/#dateTime"><abbr>XML</abbr>
Schema: Datatypes &ndash; dateTime</a> specifies a format inspired by
<abbr>ISO</abbr> 8601 that is in common use in <abbr>XML</abbr> data.</li>
-<li><a href="https://datatracker.ietf.org/doc/html/rfc5322#section-3.3">&sect;3.3 of
+<li><a href="https://www.rfc-editor.org/rfc/rfc5322#section-3.3">&sect;3.3 of
Internet Message Format</a> (Internet <abbr>RFC</abbr> 5322)
specifies the time notation used in email and <a
href="https://en.wikipedia.org/wiki/Hypertext_Transfer_Protocol"><abbr>HTTP</abbr></a>
headers.</li>
<li>
-<a href="https://datatracker.ietf.org/doc/html/rfc3339">Date and Time
+<a href="https://www.rfc-editor.org/rfc/rfc3339">Date and Time
on the Internet: Timestamps</a> (Internet <abbr>RFC</abbr> 3339)
specifies an <abbr>ISO</abbr> 8601 profile for use in new Internet protocols.
-An extension, <a href="https://datatracker.ietf.org/doc/html/rfc9557">Date
+An extension, <a href="https://www.rfc-editor.org/rfc/rfc9557">Date
and Time on the Internet: Timestamps with Additional Information</a>
(Internet <abbr>RFC</abbr> 9557) extends this profile
to let you specify the <code><abbr>tzdb</abbr></code> timezone of a timestamp
diff --git a/contrib/tzcode/tzfile.5 b/contrib/tzcode/tzfile.5
index 63bda4114388..66d169fc5302 100644
--- a/contrib/tzcode/tzfile.5
+++ b/contrib/tzcode/tzfile.5
@@ -11,7 +11,7 @@ The timezone information files used by
.Xr tzset 3
are found under
.Pa /usr/share/zoneinfo .
-These files use the format described in Internet RFC 8536.
+These files use the format described in Internet RFC 9636.
Each file is a sequence of 8-bit bytes.
In a file, a binary integer is represented by a sequence of one or
more bytes in network order (bigendian, or high-order byte first),
@@ -107,7 +107,7 @@ and
serves as an index into the array of time zone abbreviation bytes
that follow the
.Vt ttinfo
-entries in the file; if the designated string is "\*-00", the
+entries in the file; if the designated string is "\-00", the
.Vt ttinfo
entry is a placeholder indicating that local time is unspecified.
The
@@ -128,7 +128,7 @@ The byte strings can overlap if one is a suffix of the other.
The encoding of these strings is not specified.
.It Va tzh_leapcnt
pairs of four-byte values, written in network byte order;
-the first value of each pair gives the nonnegative time
+the first value of each pair gives the non-negative time
(as returned by
.Xr time 3 )
at which a leap second occurs or at which the leap second table expires;
@@ -141,7 +141,7 @@ Each pair denotes one leap second, either positive or negative,
except that if the last pair has the same correction as the previous one,
the last pair denotes the leap second table's expiration time.
Each leap second is at the end of a UTC calendar month.
-The first leap second has a nonnegative occurrence time,
+The first leap second has a non-negative occurrence time,
and is a positive leap second if and only if its correction is positive;
the correction for each leap second after the first differs
from the previous leap second by either 1 for a positive leap second,
@@ -168,7 +168,7 @@ The standard/wall and UT/local indicators were designed for
transforming a TZif file's transition times into transitions appropriate
for another time zone specified via
a proleptic TZ string that lacks rules.
-For example, when TZ="EET\*-2EEST" and there is no TZif file "EET\*-2EEST",
+For example, when TZ="EET\-2EEST" and there is no TZif file "EET\-2EEST",
the idea was to adapt the transition times from a TZif file with the
well-known name "posixrules" that is present only for this purpose and
is a copy of the file "Europe/Brussels", a file with a different UT offset.
@@ -177,7 +177,7 @@ the default rules are installation-dependent, and no implementation
is known to support this feature for timestamps past 2037,
so users desiring (say) Greek time should instead specify
TZ="Europe/Athens" for better historical coverage, falling back on
-TZ="EET\*-2EEST,M3.5.0/3,M10.5.0/4" if POSIX conformance is required
+TZ="EET\-2EEST,M3.5.0/3,M10.5.0/4" if POSIX conformance is required
and older timestamps need not be handled accurately.
.Pp
The
@@ -203,7 +203,7 @@ after the last transition time stored in the file
or for all instants if the file has no transitions.
The TZ string is empty (i.e., nothing between the newlines)
if there is no proleptic representation for such instants.
-If nonempty, the TZ string must agree with the local time
+If non-empty, the TZ string must agree with the local time
type after the last transition time if present in the eight-byte data;
for example, given the string
.Dq "WET0WEST,M3.5.0/1,M10.5.0"
@@ -218,7 +218,7 @@ the earliest transition time.
For version-3-format timezone files, a TZ string (see
.Xr newtzset 3 )
may use the following POSIX.1-2024 extensions to POSIX.1-2017:
-First, as in TZ="<\*-02>2<\*-01>,M3.5.0/\*-1,M10.5.0/0",
+First, as in TZ="<\-02>2<\-01>,M3.5.0/\-1,M10.5.0/0",
the hours part of its transition times may be signed and range from
\-167 through 167 instead of being limited to unsigned values
from 0 through 24.
@@ -275,7 +275,7 @@ time did not exist (possibly with an error indication).
Time zone designations should consist of at least three (3)
and no more than six (6) ASCII characters from the set of
alphanumerics,
-.Dq "\*-" ,
+.Dq "\-" ,
and
.Dq "+" .
This is for compatibility with POSIX requirements for
@@ -300,16 +300,16 @@ through 60 instead of the usual 59; the UTC offset is unaffected.
This section documents common problems in reading or writing TZif files.
Most of these are problems in generating TZif files for use by
older readers.
-The goals of this section are:
+The goals of this section are to help:
.Bl -bullet
.It
-to help TZif writers output files that avoid common
+TZif writers output files that avoid common
pitfalls in older or buggy TZif readers,
.It
-to help TZif readers avoid common pitfalls when reading
+TZif readers avoid common pitfalls when reading
files generated by future TZif writers, and
.It
-to help any future specification authors see what sort of
+any future specification authors see what sort of
problems arise when the TZif format is changed.
.El
.Pp
@@ -320,9 +320,9 @@ reader was designed for.
When complete compatibility was not achieved, an attempt was
made to limit glitches to rarely used timestamps and allow
simple partial workarounds in writers designed to generate
-new-version data useful even for older-version readers.
+newer-version data useful even for older-version readers.
This section attempts to document these compatibility issues and
-workarounds, as well as to document other common bugs in
+workarounds as well as documenting other common bugs in
readers.
.Pp
Interoperability problems with TZif include the following:
@@ -355,15 +355,15 @@ for two time zones east, e.g.,
for a time zone with a never-used standard time (XXX, \-03)
and negative daylight saving time (EDT, \-04) all year.
Alternatively,
-as a partial workaround a writer can substitute standard time
+as a partial workaround, a writer can substitute standard time
for the next time zone east \(en e.g.,
.Dq "AST4"
for permanent
Atlantic Standard Time (\-04).
.It
-Some readers designed for version 2 or 3, and that require strict
-conformance to RFC 8536, reject version 4 files whose leap second
-tables are truncated at the start or that end in expiration times.
+Some readers designed for version 2 or 3 and that require strict
+conformance to RFC 9636 reject version 4 files whose leap second
+tables are truncated at the start or end in expiration times.
.It
Some readers ignore the footer, and instead predict future
timestamps from the time type of the last transition.
@@ -378,7 +378,7 @@ and even for current timestamps it can fail for settings like
TZ="Africa/Casablanca". This corresponds to a TZif file
containing explicit transitions through the year 2087,
followed by a footer containing the TZ string
-.Dq <+01>\*-1 ,
+.Dq <+01>\-1 ,
which should be used only for timestamps after the last
explicit transition.
.It
@@ -389,7 +389,7 @@ As a partial workaround, a writer can output a dummy (no-op)
first transition at an early time.
.It
Some readers mishandle timestamps before the first
-transition that has a timestamp not less than \-2**31.
+transition that has a timestamp that is not less than \-2**31.
Readers that support only 32-bit timestamps are likely to be
more prone to this problem, for example, when they process
64-bit transitions only some of which are representable in 32
@@ -401,7 +401,7 @@ Some readers mishandle a transition if its timestamp has
the minimum possible signed 64-bit value.
Timestamps less than \-2**59 are not recommended.
.It
-Some readers mishandle TZ strings that
+Some readers mishandle proleptic TZ strings that
contain
.Dq "<"
or
@@ -418,9 +418,9 @@ non-ASCII characters.
These characters are not recommended.
.It
Some readers may mishandle time zone abbreviations that
-contain fewer than 3 or more than 6 characters, or that
+contain fewer than 3 or more than 6 characters or that
contain ASCII characters other than alphanumerics,
-.Dq "\*-",
+.Dq "\-",
and
.Dq "+".
These abbreviations are not recommended.
@@ -430,7 +430,7 @@ daylight-saving time UT offsets that are less than the UT
offsets for the corresponding standard time.
These readers do not support locations like Ireland, which
uses the equivalent of the TZ string
-.Dq "IST\*-1GMT0,M10.5.0,M3.5.0/1",
+.Dq "IST\-1GMT0,M10.5.0,M3.5.0/1",
observing standard time
(IST, +01) in summer and daylight saving time (GMT, +00) in winter.
As a partial workaround, a writer can output data for the
@@ -443,7 +443,7 @@ abbreviations correctly.
.It
Some readers generate ambiguous timestamps for positive leap seconds
that occur when the UTC offset is not a multiple of 60 seconds.
-For example, in a timezone with UTC offset +01:23:45 and with
+For example, with UTC offset +01:23:45 and
a positive leap second 78796801 (1972-06-30 23:59:60 UTC), some readers will
map both 78796800 and 78796801 to 01:23:45 local time the next day
instead of mapping the latter to 01:23:46, and they will map 78796815 to
@@ -462,15 +462,15 @@ Developers of distributed applications should keep this
in mind if they need to deal with pre-1970 data.
.It
Some readers mishandle timestamps before the first
-transition that has a nonnegative timestamp.
+transition that has a non-negative timestamp.
Readers that do not support negative timestamps are likely to
be more prone to this problem.
.It
Some readers mishandle time zone abbreviations like
-.Dq "\*-08"
+.Dq "\-08"
that contain
-.Dq "+" ,
-.Dq "\*-" ,
+.Dq "+",
+.Dq "\-",
or digits.
.It
Some readers mishandle UT offsets that are out of the
@@ -479,7 +479,7 @@ support locations like Kiritimati that are outside this
range.
.It
Some readers mishandle UT offsets in the range [\-3599, \-1]
-seconds from UT, because they integer-divide the offset by
+seconds from UT because they integer-divide the offset by
3600 to get 0 and then display the hour part as
.Dq "+00" .
.It
@@ -498,8 +498,8 @@ of one hour, or of 15 minutes, or of 1 minute.
.%A P. Eggert
.%A K. Murchison
.%T "The Time Zone Information Format (TZif)"
-.%R RFC 8536
-.%D February 2019
-.%U https://datatracker.ietf.org/doc/html/rfc8536
-.%U https://doi.org/10.17487/RFC8536
+.%R RFC 9636
+.%D October 2024
+.%U https://datatracker.ietf.org/doc/html/rfc9636
+.%U https://doi.org/10.17487/RFC9636
.Re
diff --git a/contrib/tzcode/tzfile.h b/contrib/tzcode/tzfile.h
index c09f39465914..55867b5c260c 100644
--- a/contrib/tzcode/tzfile.h
+++ b/contrib/tzcode/tzfile.h
@@ -28,7 +28,7 @@
#endif /* !defined TZDEFRULES */
-/* See Internet RFC 8536 for more details about the following format. */
+/* See Internet RFC 9636 for more details about the following format. */
/*
** Each file begins with. . .
diff --git a/contrib/tzcode/tzselect.8 b/contrib/tzcode/tzselect.8
index ee031614f3ed..b83f702d5e0d 100644
--- a/contrib/tzcode/tzselect.8
+++ b/contrib/tzcode/tzselect.8
@@ -4,8 +4,6 @@
.SH NAME
tzselect \- select a timezone
.SH SYNOPSIS
-.ie \n(.g .ds - \f(CR-\fP
-.el .ds - \-
.ds d " degrees
.ds m " minutes
.ds s " seconds
@@ -20,15 +18,15 @@ tzselect \- select a timezone
.\}
.B tzselect
[
-.B \*-c
+.B \-c
.I coord
] [
-.B \*-n
+.B \-n
.I limit
] [
-.B \*-\*-help
+.B \-\-help
] [
-.B \*-\*-version
+.B \-\-version
]
.SH DESCRIPTION
The
@@ -40,7 +38,7 @@ The output is suitable as a value for the TZ environment variable.
All interaction with the user is done via standard input and standard error.
.SH OPTIONS
.TP
-.BI "\*-c " coord
+.BI "\-c " coord
Instead of asking for continent and then country and then city,
ask for selection from time zones whose largest cities
are closest to the location with geographical coordinates
@@ -70,27 +68,27 @@ seconds, with any trailing fractions represent fractional minutes or
.I SS
is present) seconds. The decimal point is that of the current locale.
For example, in the (default) C locale,
-.B "\*-c\ +40.689\*-074.045"
+.B "\-c\ +40.689\-074.045"
specifies 40.689\*d\*_N, 74.045\*d\*_W,
-.B "\*-c\ +4041.4\*-07402.7"
+.B "\-c\ +4041.4\-07402.7"
specifies 40\*d\*_41.4\*m\*_N, 74\*d\*_2.7\*m\*_W, and
-.B "\*-c\ +404121\*-0740240"
+.B "\-c\ +404121\-0740240"
specifies 40\*d\*_41\*m\*_21\*s\*_N, 74\*d\*_2\*m\*_40\*s\*_W.
If
.I coord
is not one of the documented forms, the resulting behavior is unspecified.
.TP
-.BI "\*-n " limit
+.BI "\-n " limit
When
-.B \*-c
+.B \-c
is used, display the closest
.I limit
locations (default 10).
.TP
-.B "\*-\*-help"
+.B "\-\-help"
Output help information and exit.
.TP
-.B "\*-\*-version"
+.B "\-\-version"
Output version information and exit.
.SH "ENVIRONMENT VARIABLES"
.TP
diff --git a/contrib/tzcode/version b/contrib/tzcode/version
index 699e50d4d38e..ef468adcecf9 100644
--- a/contrib/tzcode/version
+++ b/contrib/tzcode/version
@@ -1 +1 @@
-2024b
+2025b
diff --git a/contrib/tzcode/zdump.8 b/contrib/tzcode/zdump.8
index 7a78f6b9c040..c5cb092db16f 100644
--- a/contrib/tzcode/zdump.8
+++ b/contrib/tzcode/zdump.8
@@ -28,6 +28,14 @@ The
program prints the current time in each
.Ar timezone
named on the command line.
+A
+.Ar timezone
+of
+.Li -
+is treated as if it were
+.Pa /dev/stdin ;
+this can be used to pipe TZif data into
+.Nm .
.Pp
The following options are available:
.Bl -tag -width indent
@@ -106,7 +114,7 @@ then a line
where
.Ar string
is a double-quoted string giving the timezone, a second line
-.Dq "\*- \*- \fIinterval\fP"
+.Dq "\- \- \fIinterval\fP"
describing the time interval before the first transition if any, and
zero or more following lines
.Dq "\fIdate time interval\fP",
@@ -138,11 +146,11 @@ the seconds are omitted if they are zero, and
the minutes are also omitted if they are also zero.
Positive UT
offsets are east of Greenwich.
-The UT offset \*-00 denotes a UT
+The UT offset \-00 denotes a UT
placeholder in areas where the actual offset is unspecified; by
convention, this occurs when the UT offset is zero and the time zone
abbreviation begins with
-.Dq "-"
+.Dq "\-"
or is
.Dq "zzz".
.Pp
diff --git a/contrib/tzcode/zdump.c b/contrib/tzcode/zdump.c
index a42c337e6d44..a8a8f5aa42ca 100644
--- a/contrib/tzcode/zdump.c
+++ b/contrib/tzcode/zdump.c
@@ -14,10 +14,6 @@
#include "private.h"
#include <stdio.h>
-#ifndef HAVE_SNPRINTF
-# define HAVE_SNPRINTF (!PORT_TO_C89 || 199901 <= __STDC_VERSION__)
-#endif
-
#ifndef HAVE_LOCALTIME_R
# define HAVE_LOCALTIME_R 1
#endif
@@ -148,17 +144,6 @@ sumsize(ptrdiff_t a, ptrdiff_t b)
size_overflow();
}
-/* Return the size of of the string STR, including its trailing NUL.
- Report an error and exit if this would exceed INDEX_MAX which means
- pointer subtraction wouldn't work. */
-static ptrdiff_t
-xstrsize(char const *str)
-{
- size_t len = strlen(str);
- if (len < INDEX_MAX)
- return len + 1;
- size_overflow();
-}
/* Return a pointer to a newly allocated buffer of size SIZE, exiting
on failure. SIZE should be positive. */
@@ -266,7 +251,7 @@ tzalloc(char const *val)
static ptrdiff_t fakeenv0size;
void *freeable = NULL;
char **env = fakeenv, **initial_environ;
- ptrdiff_t valsize = xstrsize(val);
+ ptrdiff_t valsize = strlen(val) + 1;
if (fakeenv0size < valsize) {
char **e = environ, **to;
ptrdiff_t initial_nenvptrs = 1; /* Counting the trailing NULL pointer. */
@@ -427,7 +412,7 @@ saveabbr(char **buf, ptrdiff_t *bufalloc, struct tm const *tmp)
if (HAVE_LOCALTIME_RZ)
return ab;
else {
- ptrdiff_t absize = xstrsize(ab);
+ ptrdiff_t absize = strlen(ab) + 1;
if (*bufalloc < absize) {
free(*buf);
@@ -489,6 +474,7 @@ main(int argc, char *argv[])
register time_t cuthitime;
time_t now;
bool iflag = false;
+ size_t arglenmax = 0;
cutlotime = absolute_min_time;
cuthitime = absolute_max_time;
@@ -588,15 +574,21 @@ main(int argc, char *argv[])
now = time(NULL);
now |= !now;
}
- longest = 0;
for (i = optind; i < argc; i++) {
size_t arglen = strlen(argv[i]);
- if (longest < arglen)
- longest = min(arglen, INT_MAX);
+ if (arglenmax < arglen)
+ arglenmax = arglen;
}
+ if (!HAVE_SETENV && INDEX_MAX <= arglenmax)
+ size_overflow();
+ longest = min(arglenmax, INT_MAX - 2);
for (i = optind; i < argc; ++i) {
- timezone_t tz = tzalloc(argv[i]);
+ /* Treat "-" as standard input on platforms with /dev/stdin.
+ It's not worth the bother of supporting "-" on other
+ platforms, as that would need temp files. */
+ timezone_t tz = tzalloc(strcmp(argv[i], "-") == 0
+ ? "/dev/stdin" : argv[i]);
char const *ab;
time_t t;
struct tm tm, newtm;
@@ -697,7 +689,7 @@ yeartot(intmax_t y)
return absolute_max_time;
seconds = diff400 * SECSPER400YEARS;
years = diff400 * 400;
- } else {
+ } else {
seconds = isleap(myy) ? SECSPERLYEAR : SECSPERNYEAR;
years = 1;
}
@@ -928,13 +920,10 @@ showextrema(timezone_t tz, char *zone, time_t lo, struct tm *lotmp, time_t hi)
}
}
-#if HAVE_SNPRINTF
-# define my_snprintf snprintf
-#else
+/* On pre-C99 platforms, a snprintf substitute good enough for us. */
+#if !HAVE_SNPRINTF
# include <stdarg.h>
-
-/* A substitute for snprintf that is good enough for zdump. */
-static int
+ATTRIBUTE_FORMAT((printf, 3, 4)) static int
my_snprintf(char *s, size_t size, char const *format, ...)
{
int n;
@@ -962,6 +951,7 @@ my_snprintf(char *s, size_t size, char const *format, ...)
va_end(args);
return n;
}
+# define snprintf my_snprintf
#endif
/* Store into BUF, of size SIZE, a formatted local time taken from *TM.
@@ -976,10 +966,10 @@ format_local_time(char *buf, ptrdiff_t size, struct tm const *tm)
{
int ss = tm->tm_sec, mm = tm->tm_min, hh = tm->tm_hour;
return (ss
- ? my_snprintf(buf, size, "%02d:%02d:%02d", hh, mm, ss)
+ ? snprintf(buf, size, "%02d:%02d:%02d", hh, mm, ss)
: mm
- ? my_snprintf(buf, size, "%02d:%02d", hh, mm)
- : my_snprintf(buf, size, "%02d", hh));
+ ? snprintf(buf, size, "%02d:%02d", hh, mm)
+ : snprintf(buf, size, "%02d", hh));
}
/* Store into BUF, of size SIZE, a formatted UT offset for the
@@ -1014,10 +1004,10 @@ format_utc_offset(char *buf, ptrdiff_t size, struct tm const *tm, time_t t)
mm = off / 60 % 60;
hh = off / 60 / 60;
return (ss || 100 <= hh
- ? my_snprintf(buf, size, "%c%02ld%02d%02d", sign, hh, mm, ss)
+ ? snprintf(buf, size, "%c%02ld%02d%02d", sign, hh, mm, ss)
: mm
- ? my_snprintf(buf, size, "%c%02ld%02d", sign, hh, mm)
- : my_snprintf(buf, size, "%c%02ld", sign, hh));
+ ? snprintf(buf, size, "%c%02ld%02d", sign, hh, mm)
+ : snprintf(buf, size, "%c%02ld", sign, hh));
}
/* Store into BUF (of size SIZE) a quoted string representation of P.
@@ -1120,7 +1110,7 @@ istrftime(char *buf, ptrdiff_t size, char const *time_fmt,
for (abp = ab; is_alpha(*abp); abp++)
continue;
len = (!*abp && *ab
- ? my_snprintf(b, s, "%s", ab)
+ ? snprintf(b, s, "%s", ab)
: format_quoted_string(b, s, ab));
if (s <= len)
return false;
@@ -1128,7 +1118,7 @@ istrftime(char *buf, ptrdiff_t size, char const *time_fmt,
}
formatted_len
= (tm->tm_isdst
- ? my_snprintf(b, s, &"\t\t%d"[show_abbr], tm->tm_isdst)
+ ? snprintf(b, s, &"\t\t%d"[show_abbr], tm->tm_isdst)
: 0);
}
break;
diff --git a/contrib/tzcode/zic.8 b/contrib/tzcode/zic.8
index 3804096dd6f6..d83ff7c4a0b1 100644
--- a/contrib/tzcode/zic.8
+++ b/contrib/tzcode/zic.8
@@ -112,13 +112,13 @@ Link \fItimezone\fP posixrules
If
.Ar timezone
is
-.Dq "\*-"
+.Dq "\-"
(the default), any already-existing link is removed.
.Pp
Unless
.Ar timezone
is
-.Dq "\*-" ,
+.Dq "\-" ,
this option is obsolete and poorly supported.
Among other things it should not be used for timestamps after the year 2037,
and it should not be combined with
@@ -148,6 +148,10 @@ omits data intended for negative timestamps (i.e., before the Epoch), and
.Fl r @0/@2147483648
outputs data intended only for nonnegative timestamps that fit into
31-bit signed integers.
+On platforms with GNU
+.Nm date ,
+.Dq "zic \-r @$(date +%s)"
+omits data intended for past timestamps.
Although this option typically reduces the output file's size,
the size can increase due to the need to represent the timestamp range
boundaries, particularly if
@@ -366,7 +370,15 @@ separate script to further restrict in which
of years the rule would apply.
.It IN
Names the month in which the rule takes effect.
-Month names may be abbreviated.
+Month names may be abbreviated as mentioned previously;
+for example, January can appear as
+.Dq January ,
+.Dq JANU
+or
+.Dq Ja ,
+but not as
+.Dq j
+which would be ambiguous with both June and July.
.It ON
Gives the day on which the rule takes effect.
Recognized forms include:
@@ -389,7 +401,12 @@ or a weekday name preceded by
.Dq "last"
(e.g.,
.Ql "lastSunday" )
-may be abbreviated or spelled out in full.
+may be abbreviated as mentioned previously,
+e.g.,
+.Dq Su
+for Sunday and
+.Dq lastsa
+for the last Saturday.
There must be no white space characters within the
.Ar ON
field.
@@ -540,7 +557,7 @@ field,
giving the amount of time to be added to local standard time
and whether the resulting time is standard or daylight saving.
Standard time applies if this field is
-.Ql \*-
+.Ql \-
or for timestamps occurring before any rule takes effect.
When an amount of time is given, only the sum of standard time and
this amount matters.
diff --git a/contrib/tzcode/zic.c b/contrib/tzcode/zic.c
index 2605f65dcd23..80902ce534a1 100644
--- a/contrib/tzcode/zic.c
+++ b/contrib/tzcode/zic.c
@@ -526,19 +526,19 @@ memcheck(void *ptr)
}
static void *
-emalloc(size_t size)
+xmalloc(size_t size)
{
return memcheck(malloc(size));
}
static void *
-erealloc(void *ptr, size_t size)
+xrealloc(void *ptr, size_t size)
{
return memcheck(realloc(ptr, size));
}
static char *
-estrdup(char const *str)
+xstrdup(char const *str)
{
return memcheck(strdup(str));
}
@@ -567,7 +567,7 @@ growalloc(void *ptr, ptrdiff_t itemsize, ptrdiff_t nitems,
{
return (nitems < *nitems_alloc
? ptr
- : erealloc(ptr, grow_nitems_alloc(nitems_alloc, itemsize)));
+ : xrealloc(ptr, grow_nitems_alloc(nitems_alloc, itemsize)));
}
/*
@@ -654,6 +654,8 @@ close_file(FILE *stream, char const *dir, char const *name,
char const *e = (ferror(stream) ? _("I/O error")
: fclose(stream) != 0 ? strerror(errno) : NULL);
if (e) {
+ if (name && *name == '/')
+ dir = NULL;
fprintf(stderr, "%s: %s%s%s%s%s\n", progname,
dir ? dir : "", dir ? "/" : "",
name ? name : "", name ? ": " : "",
@@ -961,6 +963,9 @@ static mode_t mflag = (S_IRUSR | S_IRGRP | S_IROTH
| S_IWUSR);
static const char * tzdefault;
+/* True if DIRECTORY ends in '/'. */
+static bool directory_ends_in_slash;
+
/* -1 if the TZif output file should be slim, 0 if default, 1 if the
output should be fat for backward compatibility. ZIC_BLOAT_DEFAULT
determines the default. */
@@ -1166,6 +1171,7 @@ _("invalid file mode"));
return EXIT_FAILURE;
associate();
change_directory(directory);
+ directory_ends_in_slash = directory[strlen(directory) - 1] == '/';
catch_signals();
for (i = 0; i < nzones; i = j) {
/*
@@ -1353,7 +1359,7 @@ random_dirent(char const **name, char **namealloc)
uint_fast64_t unfair_min = - ((UINTMAX_MAX % base__6 + 1) % base__6);
if (!dst) {
- dst = emalloc(size_sum(dirlen, prefixlen + suffixlen + 1));
+ dst = xmalloc(size_sum(dirlen, prefixlen + suffixlen + 1));
memcpy(dst, src, dirlen);
memcpy(dst + dirlen, prefix, prefixlen);
dst[dirlen + prefixlen + suffixlen] = '\0';
@@ -1370,6 +1376,20 @@ random_dirent(char const **name, char **namealloc)
}
}
+/* For diagnostics the directory, and file name relative to that
+ directory, respectively. A diagnostic routine can name FILENAME by
+ outputting diagdir(FILENAME), then diagslash(FILENAME), then FILENAME. */
+static char const *
+diagdir(char const *filename)
+{
+ return *filename == '/' ? "" : directory;
+}
+static char const *
+diagslash(char const *filename)
+{
+ return &"/"[*filename == '/' || directory_ends_in_slash];
+}
+
/* Prepare to write to the file *OUTNAME, using *TEMPNAME to store the
name of the temporary file that will eventually be renamed to
*OUTNAME. Assign the temporary file's name to both *OUTNAME and
@@ -1406,8 +1426,9 @@ open_outfile(char const **outname, char **tempname)
} else if (fopen_errno == EEXIST)
random_dirent(outname, tempname);
else {
- fprintf(stderr, _("%s: Can't create %s/%s: %s\n"),
- progname, directory, *outname, strerror(fopen_errno));
+ fprintf(stderr, _("%s: Can't create %s%s%s: %s\n"),
+ progname, diagdir(*outname), diagslash(*outname), *outname,
+ strerror(fopen_errno));
exit(EXIT_FAILURE);
}
}
@@ -1424,9 +1445,10 @@ rename_dest(char *tempname, char const *name)
if (tempname) {
if (rename(tempname, name) != 0) {
int rename_errno = errno;
- (void)remove(tempname);
- fprintf(stderr, _("%s: rename to %s/%s: %s\n"),
- progname, directory, name, strerror(rename_errno));
+ remove(tempname);
+ fprintf(stderr, _("%s: rename to %s%s%s: %s\n"),
+ progname, diagdir(name), diagslash(name), name,
+ strerror(rename_errno));
exit(EXIT_FAILURE);
}
free(tempname);
@@ -1436,7 +1458,8 @@ rename_dest(char *tempname, char const *name)
/* Create symlink contents suitable for symlinking TARGET to LINKNAME, as a
freshly allocated string. TARGET should be a relative file name, and
is relative to the global variable DIRECTORY. LINKNAME can be either
- relative or absolute. */
+ relative or absolute. Return a null pointer if the symlink contents
+ was not computed because LINKNAME is absolute but DIRECTORY is not. */
static char *
relname(char const *target, char const *linkname)
{
@@ -1449,8 +1472,10 @@ relname(char const *target, char const *linkname)
size_t len = strlen(directory);
size_t lenslash = len + (len && directory[len - 1] != '/');
size_t targetsize = strlen(target) + 1;
+ if (*directory != '/')
+ return NULL;
linksize = size_sum(lenslash, targetsize);
- f = result = emalloc(linksize);
+ f = result = xmalloc(linksize);
memcpy(result, directory, len);
result[len] = '/';
memcpy(result + lenslash, target, targetsize);
@@ -1464,7 +1489,7 @@ relname(char const *target, char const *linkname)
dotdotetcsize = size_sum(size_product(dotdots, 3), taillen + 1);
if (dotdotetcsize <= linksize) {
if (!result)
- result = emalloc(dotdotetcsize);
+ result = xmalloc(dotdotetcsize);
for (i = 0; i < dotdots; i++)
memcpy(result + 3 * i, "../", 3);
memmove(result + 3 * dotdots, f + dir_len, taillen + 1);
@@ -1500,8 +1525,9 @@ dolink(char const *target, char const *linkname, bool staysymlink)
return;
else {
char const *e = strerror(errno);
- fprintf(stderr, _("%s: Can't remove %s/%s: %s\n"),
- progname, directory, linkname, e);
+ fprintf(stderr, _("%s: Can't remove %s%s%s: %s\n"),
+ progname, diagdir(linkname), diagslash(linkname), linkname,
+ e);
exit(EXIT_FAILURE);
}
}
@@ -1544,8 +1570,9 @@ dolink(char const *target, char const *linkname, bool staysymlink)
mkdirs(linkname, true);
linkdirs_made = true;
} else {
- fprintf(stderr, _("%s: Can't link %s/%s to %s/%s: %s\n"),
- progname, directory, target, directory, outname,
+ fprintf(stderr, _("%s: Can't link %s%s%s to %s%s%s: %s\n"),
+ progname, diagdir(target), diagslash(target), target,
+ diagdir(outname), diagslash(outname), outname,
strerror(link_errno));
exit(EXIT_FAILURE);
}
@@ -1554,21 +1581,23 @@ dolink(char const *target, char const *linkname, bool staysymlink)
bool absolute = *target == '/';
char *linkalloc = absolute ? NULL : relname(target, linkname);
char const *contents = absolute ? target : linkalloc;
- int symlink_errno;
+ int symlink_errno = -1;
- while (true) {
- if (symlink(contents, outname) == 0) {
- symlink_errno = 0;
- break;
+ if (contents) {
+ while (true) {
+ if (symlink(contents, outname) == 0) {
+ symlink_errno = 0;
+ break;
+ }
+ symlink_errno = errno;
+ if (symlink_errno == EEXIST)
+ random_dirent(&outname, &tempname);
+ else if (symlink_errno == ENOENT && !linkdirs_made) {
+ mkdirs(linkname, true);
+ linkdirs_made = true;
+ } else
+ break;
}
- symlink_errno = errno;
- if (symlink_errno == EEXIST)
- random_dirent(&outname, &tempname);
- else if (symlink_errno == ENOENT && !linkdirs_made) {
- mkdirs(linkname, true);
- linkdirs_made = true;
- } else
- break;
}
free(linkalloc);
if (symlink_errno == 0) {
@@ -1581,8 +1610,8 @@ dolink(char const *target, char const *linkname, bool staysymlink)
fp = fopen(target, "rb");
if (!fp) {
char const *e = strerror(errno);
- fprintf(stderr, _("%s: Can't read %s/%s: %s\n"),
- progname, directory, target, e);
+ fprintf(stderr, _("%s: Can't read %s%s%s: %s\n"),
+ progname, diagdir(target), diagslash(target), target, e);
exit(EXIT_FAILURE);
}
tp = open_outfile(&outname, &tempname);
@@ -1593,6 +1622,8 @@ dolink(char const *target, char const *linkname, bool staysymlink)
if (link_errno != ENOTSUP)
warning(_("copy used because hard link failed: %s"),
strerror(link_errno));
+ else if (symlink_errno < 0)
+ warning(_("copy used because symbolic link not obvious"));
else if (symlink_errno != ENOTSUP)
warning(_("copy used because symbolic link failed: %s"),
strerror(symlink_errno));
@@ -1906,8 +1937,8 @@ inrule(char **fields, int nfields)
fields[RF_COMMAND], fields[RF_MONTH], fields[RF_DAY],
fields[RF_TOD]))
return;
- r.r_name = estrdup(fields[RF_NAME]);
- r.r_abbrvar = estrdup(fields[RF_ABBRVAR]);
+ r.r_name = xstrdup(fields[RF_NAME]);
+ r.r_abbrvar = xstrdup(fields[RF_ABBRVAR]);
if (max_abbrvar_len < strlen(r.r_abbrvar))
max_abbrvar_len = strlen(r.r_abbrvar);
rules = growalloc(rules, sizeof *rules, nrules, &nrules_alloc);
@@ -1990,7 +2021,8 @@ inzsub(char **fields, int nfields, bool iscont)
z.z_filenum = filenum;
z.z_linenum = linenum;
z.z_stdoff = gethms(fields[i_stdoff], _("invalid UT offset"));
- if ((cp = strchr(fields[i_format], '%')) != 0) {
+ cp = strchr(fields[i_format], '%');
+ if (cp) {
if ((*++cp != 's' && *cp != 'z') || strchr(cp, '%')
|| strchr(fields[i_format], '/')) {
error(_("invalid abbreviation format"));
@@ -2028,9 +2060,9 @@ inzsub(char **fields, int nfields, bool iscont)
return false;
}
}
- z.z_name = iscont ? NULL : estrdup(fields[ZF_NAME]);
- z.z_rule = estrdup(fields[i_rule]);
- z.z_format = cp1 = estrdup(fields[i_format]);
+ z.z_name = iscont ? NULL : xstrdup(fields[ZF_NAME]);
+ z.z_rule = xstrdup(fields[i_rule]);
+ z.z_format = cp1 = xstrdup(fields[i_format]);
if (z.z_format_specifier == 'z') {
cp1[cp - fields[i_format]] = 's';
if (noise)
@@ -2173,8 +2205,8 @@ inlink(char **fields, int nfields)
return;
l.l_filenum = filenum;
l.l_linenum = linenum;
- l.l_target = estrdup(fields[LF_TARGET]);
- l.l_linkname = estrdup(fields[LF_LINKNAME]);
+ l.l_target = xstrdup(fields[LF_TARGET]);
+ l.l_linkname = xstrdup(fields[LF_LINKNAME]);
links = growalloc(links, sizeof *links, nlinks, &nlinks_alloc);
links[nlinks++] = l;
}
@@ -2197,7 +2229,7 @@ rulesub(struct rule *rp, const char *loyearp, const char *hiyearp,
rp->r_month = lp->l_value;
rp->r_todisstd = false;
rp->r_todisut = false;
- dp = estrdup(timep);
+ dp = xstrdup(timep);
if (*dp != '\0') {
ep = dp + strlen(dp) - 1;
switch (lowerit(*ep)) {
@@ -2272,19 +2304,23 @@ rulesub(struct rule *rp, const char *loyearp, const char *hiyearp,
** Sun<=20
** Sun>=7
*/
- dp = estrdup(dayp);
+ dp = xstrdup(dayp);
if ((lp = byword(dp, lasts)) != NULL) {
rp->r_dycode = DC_DOWLEQ;
rp->r_wday = lp->l_value;
rp->r_dayofmonth = len_months[1][rp->r_month];
} else {
- if ((ep = strchr(dp, '<')) != 0)
- rp->r_dycode = DC_DOWLEQ;
- else if ((ep = strchr(dp, '>')) != 0)
- rp->r_dycode = DC_DOWGEQ;
+ ep = strchr(dp, '<');
+ if (ep)
+ rp->r_dycode = DC_DOWLEQ;
else {
+ ep = strchr(dp, '>');
+ if (ep)
+ rp->r_dycode = DC_DOWGEQ;
+ else {
ep = dp;
rp->r_dycode = DC_DOM;
+ }
}
if (rp->r_dycode != DC_DOM) {
*ep++ = 0;
@@ -2427,7 +2463,7 @@ writezone(const char *const name, const char *const string, char version,
/* Allocate the ATS and TYPES arrays via a single malloc,
as this is a bit faster. Do not malloc(0) if !timecnt,
as that might return NULL even on success. */
- zic_t *ats = emalloc(align_to(size_product(timecnt + !timecnt,
+ zic_t *ats = xmalloc(align_to(size_product(timecnt + !timecnt,
sizeof *ats + 1),
alignof(zic_t)));
void *typesptr = ats + timecnt;
@@ -2802,7 +2838,7 @@ writezone(const char *const name, const char *const string, char version,
if (thisleapexpiry) {
/* Append a no-op leap correction indicating when the leap
second table expires. Although this does not conform to
- Internet RFC 8536, most clients seem to accept this and
+ Internet RFC 9636, most clients seem to accept this and
the plan is to amend the RFC to allow this in version 4
TZif files. */
puttzcodepass(leapexpires, fp, pass);
@@ -3059,7 +3095,7 @@ stringzone(char *result, struct zone const *zpfirst, ptrdiff_t zonecount)
result[0] = '\0';
- /* Internet RFC 8536 section 5.1 says to use an empty TZ string if
+ /* Internet RFC 9636 section 6.1 says to use an empty TZ string if
future timestamps are truncated. */
if (hi_time < max_time)
return -1;
@@ -3187,9 +3223,9 @@ outzone(const struct zone *zpfirst, ptrdiff_t zonecount)
max_abbr_len = 2 + max_format_len + max_abbrvar_len;
max_envvar_len = 2 * max_abbr_len + 5 * 9;
- startbuf = emalloc(max_abbr_len + 1);
- ab = emalloc(max_abbr_len + 1);
- envvar = emalloc(max_envvar_len + 1);
+ startbuf = xmalloc(max_abbr_len + 1);
+ ab = xmalloc(max_abbr_len + 1);
+ envvar = xmalloc(max_envvar_len + 1);
INITIALIZE(untiltime);
INITIALIZE(starttime);
/*
@@ -3972,7 +4008,7 @@ mkdirs(char const *argname, bool ancestors)
if (Dflag)
return;
- char *name = estrdup(argname);
+ char *name = xstrdup(argname);
char *cp = name;
/* On MS-Windows systems, do not worry about drive letters or
diff --git a/lib/libc/tests/stdtime/detect_tz_changes_test.c b/lib/libc/tests/stdtime/detect_tz_changes_test.c
index e3fdcc0baef7..ad8c4818669d 100644
--- a/lib/libc/tests/stdtime/detect_tz_changes_test.c
+++ b/lib/libc/tests/stdtime/detect_tz_changes_test.c
@@ -44,12 +44,6 @@ static const struct tzcase {
static const time_t then = 1751328000; /* 2025-07-01 00:00:00 UTC */
-#ifdef DETECT_TZ_CHANGES
-static const char *tz_change_interval_sym = "__tz_change_interval";
-static int *tz_change_interval_p;
-static const int tz_change_interval = 3;
-static int tz_change_timeout = 90;
-
static bool debugging;
static void
@@ -89,6 +83,35 @@ change_tz(const char *tzn)
debug("time zone %s installed", tzn);
}
+ATF_TC(thin_jail);
+ATF_TC_HEAD(thin_jail, tc)
+{
+ atf_tc_set_md_var(tc, "descr", "Test typical thin jail scenario");
+ atf_tc_set_md_var(tc, "require.user", "root");
+}
+ATF_TC_BODY(thin_jail, tc)
+{
+ const struct tzcase *tzcase = tzcases;
+ char buf[128];
+ struct tm *tm;
+ size_t len;
+
+ /* prepare chroot */
+ ATF_REQUIRE_EQ(0, mkdir("root", 0755));
+ ATF_REQUIRE_EQ(0, mkdir("root/etc", 0755));
+ change_tz(tzcase->tzfn);
+ /* enter chroot */
+ ATF_REQUIRE_EQ(0, chroot("root"));
+ ATF_REQUIRE_EQ(0, chdir("/"));
+ /* check timezone */
+ unsetenv("TZ");
+ ATF_REQUIRE((tm = localtime(&then)) != NULL);
+ len = strftime(buf, sizeof(buf), "%z (%Z)", tm);
+ ATF_REQUIRE(len > 0);
+ ATF_CHECK_STREQ(tzcase->expect, buf);
+}
+
+#ifdef DETECT_TZ_CHANGES
/*
* Test time zone change detection.
*
@@ -106,6 +129,11 @@ change_tz(const char *tzn)
* after we've received and discarded the first report from the child,
* which should come almost immediately on startup.
*/
+static const char *tz_change_interval_sym = "__tz_change_interval";
+static int *tz_change_interval_p;
+static const int tz_change_interval = 3;
+static int tz_change_timeout = 90;
+
ATF_TC(detect_tz_changes);
ATF_TC_HEAD(detect_tz_changes, tc)
{
@@ -324,9 +352,10 @@ ATF_TC_BODY(tz_env_setugid, tc)
ATF_TP_ADD_TCS(tp)
{
-#ifdef DETECT_TZ_CHANGES
debugging = !getenv("__RUNNING_INSIDE_ATF_RUN") &&
isatty(STDERR_FILENO);
+ ATF_TP_ADD_TC(tp, thin_jail);
+#ifdef DETECT_TZ_CHANGES
ATF_TP_ADD_TC(tp, detect_tz_changes);
#endif /* DETECT_TZ_CHANGES */
ATF_TP_ADD_TC(tp, tz_env);
diff --git a/lib/libifconfig/Makefile b/lib/libifconfig/Makefile
index fb7c659e068c..02629eb88f25 100644
--- a/lib/libifconfig/Makefile
+++ b/lib/libifconfig/Makefile
@@ -17,6 +17,7 @@ SRCS= libifconfig.c \
libifconfig_internal.c \
libifconfig_lagg.c \
libifconfig_media.c \
+ libifconfig_nl.c \
libifconfig_sfp.c
GEN= libifconfig_sfp_tables.h \
diff --git a/lib/libifconfig/libifconfig.h b/lib/libifconfig/libifconfig.h
index a5ce7b375830..817f52bd094e 100644
--- a/lib/libifconfig/libifconfig.h
+++ b/lib/libifconfig/libifconfig.h
@@ -35,6 +35,8 @@
#include <netinet/ip_carp.h>
#include <netinet6/in6_var.h>
+#include <stdbool.h>
+
#define ND6_IFF_DEFAULTIF 0x8000
typedef enum {
@@ -381,3 +383,12 @@ int ifconfig_set_vlantag(ifconfig_handle_t *h, const char *name,
* length of *lenp * IFNAMSIZ bytes.
*/
int ifconfig_list_cloners(ifconfig_handle_t *h, char **bufp, size_t *lenp);
+
+/** Brings the interface up/down
+ * @param h An open ifconfig state object
+ * @param ifname The interface name
+ * @param up true to bring the interface up, false to bring it down
+ * @return 0 on success, nonzero on failure.
+ * On failure, the error info on the handle is set.
+ */
+int ifconfig_set_up(ifconfig_handle_t *h, const char *ifname, bool up);
diff --git a/lib/libifconfig/libifconfig_nl.c b/lib/libifconfig/libifconfig_nl.c
new file mode 100644
index 000000000000..7d9decabe26f
--- /dev/null
+++ b/lib/libifconfig/libifconfig_nl.c
@@ -0,0 +1,72 @@
+/*-
+ * SPDX-License-Identifier: BSD-2-Clause
+ *
+ * Copyright (c) 2025, Muhammad Saheed <saheed@FreeBSD.org>
+ */
+
+#include <netlink/netlink.h>
+#include <netlink/netlink_snl.h>
+#include <netlink/route/common.h>
+#include <netlink/route/interface.h>
+
+#include "libifconfig.h"
+#include "libifconfig_internal.h"
+
+static int ifconfig_modify_flags(ifconfig_handle_t *h, const char *ifname,
+ int ifi_flags, int ifi_change);
+
+static int
+ifconfig_modify_flags(ifconfig_handle_t *h, const char *ifname, int ifi_flags,
+ int ifi_change)
+{
+ int ret = 0;
+ struct snl_state ss;
+ struct snl_writer nw;
+ struct nlmsghdr *hdr;
+ struct ifinfomsg *ifi;
+ struct snl_errmsg_data e = { 0 };
+
+ if (!snl_init(&ss, NETLINK_ROUTE)) {
+ ifconfig_error(h, NETLINK, ENOTSUP);
+ return (-1);
+ }
+
+ snl_init_writer(&ss, &nw);
+ hdr = snl_create_msg_request(&nw, NL_RTM_NEWLINK);
+ ifi = snl_reserve_msg_object(&nw, struct ifinfomsg);
+ snl_add_msg_attr_string(&nw, IFLA_IFNAME, ifname);
+
+ ifi->ifi_flags = ifi_flags;
+ ifi->ifi_change = ifi_change;
+
+ hdr = snl_finalize_msg(&nw);
+ if (hdr == NULL) {
+ ifconfig_error(h, NETLINK, ENOMEM);
+ ret = -1;
+ goto out;
+ }
+
+ if (!snl_send_message(&ss, hdr)) {
+ ifconfig_error(h, NETLINK, EIO);
+ ret = -1;
+ goto out;
+ }
+
+ if (!snl_read_reply_code(&ss, hdr->nlmsg_seq, &e)) {
+ ifconfig_error(h, NETLINK, e.error);
+ ret = -1;
+ goto out;
+ }
+
+out:
+ snl_free(&ss);
+ return (ret);
+}
+
+int
+ifconfig_set_up(ifconfig_handle_t *h, const char *ifname, bool up)
+{
+ int flag = up ? IFF_UP : ~IFF_UP;
+
+ return (ifconfig_modify_flags(h, ifname, flag, IFF_UP));
+}
diff --git a/libexec/rc/rc.d/bluetooth b/libexec/rc/rc.d/bluetooth
index 22bd5078034d..239944c73dd6 100755
--- a/libexec/rc/rc.d/bluetooth
+++ b/libexec/rc/rc.d/bluetooth
@@ -127,8 +127,17 @@ bluetooth_setup_stack()
> /dev/null 2>&1 || return 1
# Initilalize HCI node
- ${hccontrol} -n ${dev}hci reset \
- > /dev/null 2>&1 || return 1
+ for loop in 1 2 3
+ do
+ ${hccontrol} -n ${dev}hci reset \
+ > /dev/null 2>1 && break
+ if [ ${loop} -eq 3 ]
+ then
+ warn Reset failed three times, giving up.
+ return 1
+ fi
+ warn Reset failed, retrying.
+ done
${hccontrol} -n ${dev}hci read_bd_addr \
> /dev/null 2>&1 || return 1
diff --git a/release/tools/azure.conf b/release/tools/azure.conf
index 519ab13fe432..a633e6e508d4 100644
--- a/release/tools/azure.conf
+++ b/release/tools/azure.conf
@@ -27,7 +27,8 @@ vm_extra_pre_umount() {
# them from the image allows it to boot faster.
chroot ${DESTDIR} ${EMULATOR} env ASSUME_ALWAYS_YES=yes \
/usr/sbin/pkg delete -f -y pkg
- rm -r ${DESTDIR}/var/db/pkg/repos/FreeBSD
+ rm -r ${DESTDIR}/var/db/pkg/repos/FreeBSD-ports
+ rm -r ${DESTDIR}/var/db/pkg/repos/FreeBSD-ports-kmods
chroot ${DESTDIR} ${EMULATOR} pw usermod root -h -
diff --git a/release/tools/ec2.conf b/release/tools/ec2.conf
index ef7a603efea9..31f40962b19d 100644
--- a/release/tools/ec2.conf
+++ b/release/tools/ec2.conf
@@ -27,7 +27,8 @@ ec2_common() {
chroot ${DESTDIR} ${EMULATOR} env ASSUME_ALWAYS_YES=yes \
/usr/sbin/pkg delete -f -y pkg
umount ${DESTDIR}/dev
- rm -r ${DESTDIR}/var/db/pkg/repos/FreeBSD
+ rm -r ${DESTDIR}/var/db/pkg/repos/FreeBSD-ports
+ rm -r ${DESTDIR}/var/db/pkg/repos/FreeBSD-ports-kmods
# Turn off IPv6 Duplicate Address Detection; the EC2 networking
# configuration makes it unnecessary.
diff --git a/release/tools/vagrant.conf b/release/tools/vagrant.conf
index c212af7d012e..506174d0ea16 100644
--- a/release/tools/vagrant.conf
+++ b/release/tools/vagrant.conf
@@ -20,7 +20,8 @@ vagrant_common () {
# them from the image allows it to boot faster.
env ASSUME_ALWAYS_YES=yes pkg -c ${DESTDIR} clean -y -a
env ASSUME_ALWAYS_YES=yes pkg -c ${DESTDIR} delete -f -y pkg
- rm -r ${DESTDIR}/var/db/pkg/repos/FreeBSD
+ rm -r ${DESTDIR}/var/db/pkg/repos/FreeBSD-ports
+ rm -r ${DESTDIR}/var/db/pkg/repos/FreeBSD-ports-kmods
# Vagrant instances use DHCP to get their network configuration.
echo 'ifconfig_DEFAULT="SYNCDHCP"' >> ${DESTDIR}/etc/rc.conf
diff --git a/sbin/pfctl/parse.y b/sbin/pfctl/parse.y
index 00c36b218055..59c27d1f5d7c 100644
--- a/sbin/pfctl/parse.y
+++ b/sbin/pfctl/parse.y
@@ -238,6 +238,7 @@ static struct pool_opts {
#define POM_TYPE 0x01
#define POM_STICKYADDRESS 0x02
#define POM_ENDPI 0x04
+#define POM_IPV6NH 0x08
u_int8_t opts;
int type;
int staticport;
@@ -543,7 +544,7 @@ int parseport(char *, struct range *r, int);
%token MAXSRCCONN MAXSRCCONNRATE OVERLOAD FLUSH SLOPPY PFLOW ALLOW_RELATED
%token TAGGED TAG IFBOUND FLOATING STATEPOLICY STATEDEFAULTS ROUTE SETTOS
%token DIVERTTO DIVERTREPLY BRIDGE_TO RECEIVEDON NE LE GE AFTO NATTO RDRTO
-%token BINATTO MAXPKTRATE MAXPKTSIZE
+%token BINATTO MAXPKTRATE MAXPKTSIZE IPV6NH
%token <v.string> STRING
%token <v.number> NUMBER
%token <v.i> PORTBINARY
@@ -2648,13 +2649,16 @@ pfrule : action dir logquick interface route af proto fromto
YYERROR;
}
r.rt = $5.rt;
- decide_address_family($5.redirspec->host, &r.af);
- if (!(r.rule_flag & PFRULE_AFTO))
- remove_invalid_hosts(&($5.redirspec->host), &r.af);
- if ($5.redirspec->host == NULL) {
- yyerror("no routing address with "
- "matching address family found.");
- YYERROR;
+
+ if (!($5.redirspec->pool_opts.opts & PF_POOL_IPV6NH)) {
+ decide_address_family($5.redirspec->host, &r.af);
+ if (!(r.rule_flag & PFRULE_AFTO))
+ remove_invalid_hosts(&($5.redirspec->host), &r.af);
+ if ($5.redirspec->host == NULL) {
+ yyerror("no routing address with "
+ "matching address family found.");
+ YYERROR;
+ }
}
}
#ifdef __FreeBSD__
@@ -2978,7 +2982,8 @@ filter_opt : USER uids {
filter_opts.nat = $4;
filter_opts.nat->af = $2;
- if ($4->af && $4->af != $2) {
+ remove_invalid_hosts(&($4->host), &(filter_opts.nat->af));
+ if ($4->host == NULL) {
yyerror("af-to addresses must be in the "
"target address family");
YYERROR;
@@ -2998,8 +3003,9 @@ filter_opt : USER uids {
filter_opts.nat->af = $2;
filter_opts.rdr = $6;
filter_opts.rdr->af = $2;
- if (($4->af && $4->host->af != $2) ||
- ($6->af && $6->host->af != $2)) {
+ remove_invalid_hosts(&($4->host), &(filter_opts.nat->af));
+ remove_invalid_hosts(&($6->host), &(filter_opts.rdr->af));
+ if ($4->host == NULL || $6->host == NULL) {
yyerror("af-to addresses must be in the "
"target address family");
YYERROR;
@@ -4674,6 +4680,14 @@ pool_opt : BITMASK {
pool_opts.marker |= POM_ENDPI;
pool_opts.opts |= PF_POOL_ENDPI;
}
+ | IPV6NH {
+ if (pool_opts.marker & POM_IPV6NH) {
+ yyerror("prefer-ipv6-nexthop cannot be redefined");
+ YYERROR;
+ }
+ pool_opts.marker |= POM_IPV6NH;
+ pool_opts.opts |= PF_POOL_IPV6NH;
+ }
| MAPEPORTSET number '/' number '/' number {
if (pool_opts.mape.offset) {
yyerror("map-e-portset cannot be redefined");
@@ -4813,6 +4827,12 @@ natrule : nataction interface af proto fromto tag tagged rtable
"address'");
YYERROR;
}
+ if ($9->pool_opts.opts & PF_POOL_IPV6NH) {
+ yyerror("The prefer-ipv6-nexthop option "
+ "can't be used for nat/rdr/binat pools"
+ );
+ YYERROR;
+ }
if (!r.af && ! $9->host->ifindex)
r.af = $9->host->af;
@@ -5074,13 +5094,6 @@ route_host : STRING {
route_host_list : route_host optnl { $$ = $1; }
| route_host_list comma route_host optnl {
- if ($1->af == 0)
- $1->af = $3->af;
- if ($1->af != $3->af) {
- yyerror("all pool addresses must be in the "
- "same address family");
- YYERROR;
- }
$1->tail->next = $3;
$1->tail = $3->tail;
$$ = $1;
@@ -6678,6 +6691,7 @@ lookup(char *s)
{ "pass", PASS},
{ "pflow", PFLOW},
{ "port", PORT},
+ { "prefer-ipv6-nexthop", IPV6NH},
{ "prio", PRIO},
{ "priority", PRIORITY},
{ "priq", PRIQ},
diff --git a/sbin/pfctl/pfctl_parser.c b/sbin/pfctl/pfctl_parser.c
index 18b78a150c28..3c4f9f6b4334 100644
--- a/sbin/pfctl/pfctl_parser.c
+++ b/sbin/pfctl/pfctl_parser.c
@@ -508,6 +508,8 @@ print_pool(struct pfctl_pool *pool, u_int16_t p1, u_int16_t p2, int id)
if (pool->mape.offset > 0)
printf(" map-e-portset %u/%u/%u",
pool->mape.offset, pool->mape.psidlen, pool->mape.psid);
+ if (pool->opts & PF_POOL_IPV6NH)
+ printf(" prefer-ipv6-nexthop");
}
void
@@ -1438,7 +1440,7 @@ ifa_add_groups_to_map(char *ifa_name)
ENTRY item;
ENTRY *ret_item;
int *answer;
-
+
item.key = ifg->ifgrq_group;
if (hsearch_r(item, FIND, &ret_item, &isgroup_map) == 0) {
struct ifgroupreq ifgr2;
@@ -1580,7 +1582,7 @@ is_a_group(char *name)
{
ENTRY item;
ENTRY *ret_item;
-
+
item.key = name;
if (hsearch_r(item, FIND, &ret_item, &isgroup_map) == 0)
return (0);
diff --git a/sbin/pfctl/tests/files/pf1073.in b/sbin/pfctl/tests/files/pf1073.in
new file mode 100644
index 000000000000..477995893ac3
--- /dev/null
+++ b/sbin/pfctl/tests/files/pf1073.in
@@ -0,0 +1 @@
+pass in on vtnet0 route-to ( vtnet1 2001:db8::1 ) prefer-ipv6-nexthop inet
diff --git a/sbin/pfctl/tests/files/pf1073.ok b/sbin/pfctl/tests/files/pf1073.ok
new file mode 100644
index 000000000000..f34867508c75
--- /dev/null
+++ b/sbin/pfctl/tests/files/pf1073.ok
@@ -0,0 +1 @@
+pass in on vtnet0 route-to (vtnet1 2001:db8::1) prefer-ipv6-nexthop inet all flags S/SA keep state
diff --git a/sbin/pfctl/tests/files/pf1074.fail b/sbin/pfctl/tests/files/pf1074.fail
new file mode 100644
index 000000000000..afe8ee3c458f
--- /dev/null
+++ b/sbin/pfctl/tests/files/pf1074.fail
@@ -0,0 +1 @@
+no routing address with matching address family found.
diff --git a/sbin/pfctl/tests/files/pf1074.in b/sbin/pfctl/tests/files/pf1074.in
new file mode 100644
index 000000000000..5d285bc5d6e8
--- /dev/null
+++ b/sbin/pfctl/tests/files/pf1074.in
@@ -0,0 +1 @@
+pass in on vtnet0 route-to ( vtnet1 2001:db8::1 ) inet
diff --git a/sbin/pfctl/tests/pfctl_test_list.inc b/sbin/pfctl/tests/pfctl_test_list.inc
index 3a68cc06ec74..8bfccddf50e5 100644
--- a/sbin/pfctl/tests/pfctl_test_list.inc
+++ b/sbin/pfctl/tests/pfctl_test_list.inc
@@ -181,3 +181,5 @@ PFCTL_TEST(1069, "max-pkt-size")
PFCTL_TEST_FAIL(1070, "include line number")
PFCTL_TEST(1071, "mask length on (lo0)")
PFCTL_TEST_FAIL(1072, "Invalid port range")
+PFCTL_TEST(1073, "Filter AF different than route-to AF, with prefer-ipv6-nexthop")
+PFCTL_TEST_FAIL(1074, "Filter AF different than route-to AF, without prefer-ipv6-nexthop")
diff --git a/sbin/veriexec/veriexec.8 b/sbin/veriexec/veriexec.8
index 8e99f1d61faf..8352dd8e5e49 100644
--- a/sbin/veriexec/veriexec.8
+++ b/sbin/veriexec/veriexec.8
@@ -195,7 +195,7 @@ and be strict about enforcing certificate validity:
.Ed
.Nm
-will look for a detatched signature that it recognizes, such as
+will look for a detached signature that it recognizes, such as
.Pa manifest.asc
(OpenPGP) or
.Pa manifest.*sig
diff --git a/share/man/man4/Makefile b/share/man/man4/Makefile
index 519b113b0a2e..1d708cfda019 100644
--- a/share/man/man4/Makefile
+++ b/share/man/man4/Makefile
@@ -8,6 +8,9 @@ MANPACKAGE= kernel
# the doc repository); otherwise the automatically generated hardware
# notes will not include your driver.
+# If you enable a driver for a different architecture, please remember
+# to update the arch specifier in the document title of the manual.
+
MAN= aac.4 \
aacraid.4 \
acpi.4 \
diff --git a/share/man/man4/gpio.4 b/share/man/man4/gpio.4
index 9a629ff402fd..b84bfb01de51 100644
--- a/share/man/man4/gpio.4
+++ b/share/man/man4/gpio.4
@@ -1,3 +1,6 @@
+.\"
+.\" SPDX-License-Identifier: BSD-2-Clause
+.\"
.\" Copyright (c) 2013, Sean Bruno <sbruno@freebsd.org>
.\" All rights reserved.
.\"
@@ -22,7 +25,7 @@
.\" OUT OF THE USE OF THIS SOFTWARE, EVEN IF ADVISED OF THE POSSIBILITY OF
.\" SUCH DAMAGE.
.\"
-.Dd June 27, 2019
+.Dd August 28, 2025
.Dt GPIO 4
.Os
.Sh NAME
@@ -33,7 +36,6 @@ To compile these devices into your kernel and use the device hints, place the
following lines in your kernel configuration file:
.Bd -ragged -offset indent
.Cd "device gpio"
-.Cd "device gpioc"
.Cd "device gpioiic"
.Cd "device gpioled"
.Ed
diff --git a/share/man/man4/syncache.4 b/share/man/man4/syncache.4
index e92502fd15ff..f83e9b083e45 100644
--- a/share/man/man4/syncache.4
+++ b/share/man/man4/syncache.4
@@ -10,7 +10,7 @@
.\" notice, this list of conditions and the following disclaimer in the
.\" documentation and/or other materials provided with the distribution.
.\"
-.Dd April 12, 2021
+.Dd August 30, 2025
.Dt SYNCACHE 4
.Os
.Sh NAME
@@ -39,6 +39,8 @@ MIBs for controlling TCP SYN caching
.Nm sysctl Cm net.inet.tcp.syncache.count
.It
.Nm sysctl Cm net.inet.tcp.syncache.see_other
+.It
+.Nm sysctl Cm net.inet.tcp.syncache.rst_on_sock_fail
.El
.Sh DESCRIPTION
The
@@ -107,6 +109,18 @@ and run only with
set
.Va net.inet.tcp.syncookies_only
to 1.
+To use
+.Nm syncookies
+to handle bucket overflows in the
+.Nm syncache
+set
+.Va net.inet.tcp.syncookies
+to 1.
+The default value for
+.Va net.inet.tcp.syncookies_only
+is 0 and the default value for
+.Va net.inet.tcp.syncookies
+is 1.
.Pp
The
.Nm
@@ -169,6 +183,9 @@ However, extra
.Xr ucred 9
referencing is required on every incoming SYN packet processed.
The default is off.
+.It Va rst_on_sock_fail
+Send a TCP RST segment if the socket allocation fails.
+The default is on.
.El
.Pp
Statistics on the performance of the
@@ -206,8 +223,16 @@ Entries dropped due to ICMP unreachable messages.
Failures to allocate new
.Nm
entry.
+.It Li "cookies sent"
+SYN cookies sent in SYN ACK segments.
.It Li "cookies received"
-Connections created from segment containing ACK.
+ACK segments with valid syncookies which resulted in TCP connection
+establishment.
+.It Li "spurious cookies rejected"
+Received ACKs, for which the syncache lookup failed and also no syncookie was
+recently sent.
+.It Li "failed cookies rejected"
+Received ACKs for which the syncookie validation failed.
.El
.Sh SEE ALSO
.Xr netstat 1 ,
diff --git a/share/man/man5/pf.conf.5 b/share/man/man5/pf.conf.5
index a9ae823257a4..bdd8a843d72a 100644
--- a/share/man/man5/pf.conf.5
+++ b/share/man/man5/pf.conf.5
@@ -2470,7 +2470,13 @@ NAT address and port.
This feature implements "full-cone" NAT behavior.
.El
.Pp
-Additionally, the
+Additionally, options
+.Ar sticky-address
+and
+.Ar prefer-ipv6-nexthop
+can be specified to influence how IP addresses selected from pools.
+.Pp
+The
.Ar sticky-address
option can be specified to help ensure that multiple connections from the
same source are mapped to the same redirection address.
@@ -2486,6 +2492,14 @@ beyond the lifetime of the states, increase the global options with
See
.Sx STATEFUL TRACKING OPTIONS
for more ways to control the source tracking.
+.Pp
+The
+.Ar prefer-ipv6-nexthop
+option allows for IPv6 addresses to be used as the nexthop
+for IPv4 packets routed with the
+.Ar route-to
+rule option. If a table is used with IPv4 and IPv6 addresses, first the IPv6 addresses
+will be used in round-robin fashion, then IPv4 addresses.
.Sh STATE MODULATION
Much of the security derived from TCP is attributable to how well the
initial sequence numbers (ISNs) are chosen.
@@ -3580,7 +3594,7 @@ limit-item = ( "states" | "frags" | "src-nodes" ) number
pooltype = ( "bitmask" | "random" |
"source-hash" [ ( hex-key | string-key ) ] |
- "round-robin" ) [ sticky-address ]
+ "round-robin" ) [ sticky-address | prefer-ipv6-nexthop ]
subqueue = string | "{" queue-list "}"
queue-list = string [ [ "," ] string ]
diff --git a/share/man/man9/VFS.9 b/share/man/man9/VFS.9
index a269d8d070cf..a1d0a19bec13 100644
--- a/share/man/man9/VFS.9
+++ b/share/man/man9/VFS.9
@@ -44,7 +44,6 @@ rather than implementing empty functions or casting to
.Sh SEE ALSO
.Xr VFS_CHECKEXP 9 ,
.Xr VFS_FHTOVP 9 ,
-.Xr VFS_INIT 9 ,
.Xr VFS_MOUNT 9 ,
.Xr VFS_QUOTACTL 9 ,
.Xr VFS_SET 9 ,
diff --git a/share/mk/bsd.man.mk b/share/mk/bsd.man.mk
index 36d2cf1a1433..a2c34eff9e3e 100644
--- a/share/mk/bsd.man.mk
+++ b/share/mk/bsd.man.mk
@@ -168,7 +168,18 @@ ${__target}: ${MANSRC.${__page:T}:U${__page}}
.endfor
.endfor
.else
-all-man: ${${__group}}
+.for __page in ${${__group}}
+.if defined(MANSRC.${__page:T})
+.for __target in ${__page:T:S/:/\:/g}
+all-man: ${__target}
+CLEANFILES+= ${__target}
+${__target}: ${MANSRC.${__page:T}}
+ ${CP} ${.ALLSRC} ${.TARGET}
+.endfor
+.else
+all-man: ${__page}
+.endif
+.endfor
.endif
.endif
.endif # defined(MANFILTER)
diff --git a/share/vt/fonts/gallant.hex b/share/vt/fonts/gallant.hex
index 5f45c3d116f4..57a63150954e 100644
--- a/share/vt/fonts/gallant.hex
+++ b/share/vt/fonts/gallant.hex
@@ -225,8 +225,8 @@
00ff:0000000000001980198000000000f0f0602030403040188018800d000d000600060004000c00080078007000
0100:1f801f800000060006000b000b0009001180118010803fc020c0204040604060e0f000000000000000000000
0101:0000000000000fc00fc0000000000f8018c010c003c01cc030c030c030c039c01ee000000000000000000000
-0102:1b001b000e00060006000b000b0009001180118010803fc020c0204040604060e0f000000000000000000000
-0103:000000000d800d800700000000000f8018c010c003c01cc030c030c030c039c01ee000000000000000000000
+0102:198019800f00060006000b000b0009001180118010803fc020c0204040604060e0f000000000000000000000
+0103:000000000cc00cc00780000000000f8018c010c003c01cc030c030c030c039c01ee000000000000000000000
0104:000000000000060006000b000b0009001180118010803fc020c0204040604060e0f000c00180030001e00000
0105:00000000000000000000000000000f8018c010c003c01cc030c030c030c039c01ee000c00180030001e00000
0106:030006000c000fc01060202020006000600060006000600060002000302018400f8000000000000000000000
@@ -243,8 +243,8 @@
0111:00000000006000e0006007f000600f6031e020e0606060606060606070e039601e7000000000000000000000
0112:1f801f8000007fc0304030403000300030803f803080300030003000302030207fe000000000000000000000
0113:0000000000001f801f80000000000f0030c0606060607fe060006000300018600f8000000000000000000000
-0114:0d800d8007007fc0304030403000300030803f803080300030003000302030207fe000000000000000000000
-0115:000000000d800d800700000000000f0030c0606060607fe060006000300018600f8000000000000000000000
+0114:0cc00cc007807fc0304030403000300030803f803080300030003000302030207fe000000000000000000000
+0115:000000000cc00cc00780000000000f0030c0606060607fe060006000300018600f8000000000000000000000
0116:0600060000007fc0304030403000300030803f803080300030003000302030207fe000000000000000000000
0117:00000000000000000600060000000f0030c0606060607fe060006000300018600f8000000000000000000000
0118:0000000000007fc0304030403000300030803f803080300030003000302030207fe000c00180030001e00000
@@ -253,8 +253,8 @@
011b:0000000018c00d800700020000000f0030c0606060607fe060006000300018600f8000000000000000000000
011c:07000d8000000fc0106020202000600060006000600061f060602060306018600f8000000000000000000000
011d:00000000020007000d8018c000001f2031e060c060c060c031803f0060007fc03fe02060402040207fc03f80
-011e:0d800d8007000fc0106020202000600060006000600061f060602060306018600f8000000000000000000000
-011f:000000001b001b000e00000000001f2031e060c060c060c031803f0060007fc03fe02060402040207fc03f80
+011e:0cc00cc007800fc0106020202000600060006000600061f060602060306018600f8000000000000000000000
+011f:00000000198019800f00000000001f2031e060c060c060c031803f0060007fc03fe02060402040207fc03f80
0120:0300030000000fc0106020202000600060006000600061f060602060306018600f8000000000000000000000
0121:00000000000000000600060000001f2031e060c060c060c031803f0060007fc03fe02060402040207fc03f80
0122:0000000000000fc0106020202000600060006000600061f060602060306018600f800600030001800f000000
@@ -268,7 +268,7 @@
012a:1f801f8000001f800600060006000600060006000600060006000600060006001f8000000000000000000000
012b:0000000000001f801f80000000001e00060006000600060006000600060006001f8000000000000000000000
012c:198019800f001f800600060006000600060006000600060006000600060006001f8000000000000000000000
-012d:000000001b001b000e00000000001e00060006000600060006000600060006001f8000000000000000000000
+012d:00000000198019800f00000000001e00060006000600060006000600060006001f8000000000000000000000
012e:0000000000001f800600060006000600060006000600060006000600060006001f8006000c0018000f000000
012f:00000000000006000600000000001e00060006000600060006000600060006001f8006000c0018000f000000
0130:0600060000001f800600060006000600060006000600060006000600060006001f8000000000000000000000
@@ -301,8 +301,8 @@
014b:0000000000000000000000000000278079c030c030c030c030c030c030c030c078c000c000c0008007000600
014c:1f801f8000000f0011c020c020606060606060606060606060602040304018800f0000000000000000000000
014d:0000000000001f801f80000000000f8011c020e06060606060606060704038801f0000000000000000000000
-014e:0d800d8007000f0011c020c020606060606060606060606060602040304018800f0000000000000000000000
-014f:0000000000000d800d80070000000f8011c020e06060606060606060704038801f0000000000000000000000
+014e:0cc00cc007800f0011c020c020606060606060606060606060602040304018800f0000000000000000000000
+014f:0000000000000cc00cc0078000000f8011c020e06060606060606060704038801f0000000000000000000000
0150:036006c00d800f0011c020c020606060606060606060606060602040304018800f0000000000000000000000
0151:00000000000006c00d801b0000000f8011c020e06060606060606060704038801f0000000000000000000000
0152:0000000000001fe0262046204600c600c610c7f0c610c600c6004600661036101ff000000000000000000000
@@ -331,8 +331,8 @@
0169:0000000000000e401fc01380000079e030c030c030c030c030c030c030c039c01e6000000000000000000000
016a:1f801f800000f070602060206020602060206020602060206020602070403fc01f8000000000000000000000
016b:0000000000001f801f800000000079e030c030c030c030c030c030c030c039c01e6000000000000000000000
-016c:0d800d800700f070602060206020602060206020602060206020602070403fc01f8000000000000000000000
-016d:0000000000000d800d800700000079e030c030c030c030c030c030c030c039c01e6000000000000000000000
+016c:0cc00cc00780f070602060206020602060206020602060206020602070403fc01f8000000000000000000000
+016d:0000000000000cc00cc00780000079e030c030c030c030c030c030c030c039c01e6000000000000000000000
016e:07000d800d80f770602060206020602060206020602060206020602070403fc01f8000000000000000000000
016f:0000000007000d800d800700000079e030c030c030c030c030c030c030c039c01e6000000000000000000000
0170:06c00d801b00f070602060206020602060206020602060206020602070403fc01f8000000000000000000000
@@ -351,18 +351,1399 @@
017d:18c00d8007003fe020c000c00180018003000300060006000c000c00180018203fe000000000000000000000
017e:0000000018c00d800700020000007fe060e041c0038007000e001c00382070607fe000000000000000000000
017f:00000000038004c004c00c000c000c000c003c000c000c000c000c000c000c001e0000000000000000000000
+0180:0000000020006000fe006000600067806fc070e06060606060606060706078c04f8000000000000000000000
+0181:0000000000007f80d840d8601860186018c01fc01860183018301830183018603fc000000000000000000000
+0182:000000000000ffc0604060406000600060007f8060c0606060606060606060c0ff8000000000000000000000
+0183:000000007fc0600060006000600067806fc070e06060606060606060706078c04f8000000000000000000000
+0184:00000000100030007000f000b000338037c038e03060306030603060306030c03f8000000000000000000000
+0185:0000000000000000100030007000f000b000338037c038e030603060306030c03f8000000000000000000000
+0186:0000000000000f0011c020c000600060006000600060006000600040304018800f0000000000000000000000
+0187:0000003000600f4011c020c020006000600060006000600060006000304038800f0000000000000000000000
+0188:00000000000000000030006000401fc031c020c06000600060006000704030c01f8000000000000000000000
+0189:000000000000ff0061c060c0606060606060fc60606060606060606060406180fe0000000000000000000000
+018a:0000000000007f80d8e0d86018301830183018301830183018301830182018c03f0000000000000000000000
+018b:0000000000007fe040c040c000c000c000c03fc060c0c0c0c0c0c0c0c0c060c03fe000000000000000000000
+018c:000000003fe000600060006000601e603f6070e0606060606060606060e031e01f2000000000000000000000
+018d:0000000000000f8011c020e0606060606060704038801f000e000700038000c01f8000000000000000000000
+018e:0000000000003fe020c020c000c000c010c01fc010c000c000c000c040c040c07fe000000000000000000000
+018f:0000000000000f0011c020c0206000600060006000607fe060602040304018800f0000000000000000000000
+0190:000000001f803fc070206060600030001c001f80300060006000602020601fc00f8000000000000000000000
+0191:0000000000003fe0182018201800180018401fc0184018001800180018001800d800d0006000000000000000
+0192:00000000038004c004c00c000c000c000c001f800c000c000c000c000c000c006c0068001000000000000000
+0193:0000006000b01fb0218040804000c000c000c000c000c3e0c0c040c060c030c01f0000000000000000000000
+0194:000000000000f07060206020604030403080188019000d000e0006000e0013001300218021801f0000000000
+0195:0000000020006000e000600060006e3073306330633063306330633063306330f1e000000000000000000000
+0196:0000000000001e000600060006000600060006000600060006000600060006001f8000000000000000000000
+0197:0000000000001f80060006000600060006003fc00600060006000600060006001f8000000000000000000000
+0198:000000000000f0606190633066006c00780078007c006e006700638061c060e0f07000000000000000000000
+0199:180024006c00600060006000600061c0630066007c0078007c006e0067006380f1e000000000000000000000
+019a:000000001e00060006000600060006003fc006000600060006000600060006001f8000000000000000000000
+019b:0000000000001c001c000e3006c007000e003b00cb0011801180118020c020c071e000000000000000000000
+019c:00000000ef7066606660666066606660666066606660666066606660666077603bb000000000000000000000
+019d:0000000000006070302038203c202c20262022202320232021a020e020e020602030e000c000000000000000
+019e:0000000000000000000000000000278079c030c030c030c030c030c030c030c078c000c000c000c000c001e0
+019f:0000000000000f0011c020c02060606061606d606b60686060602040304018800f0000000000000000000000
+01a0:0000000000001e3023b041a040c0c0c0c0c0c0c0c0c0c0c0c0c04080608031001e0000000000000000000000
+01a1:00000000000000000000000000001f3023b041e0c0c0c0c0c0c0c0c0e08071003e0000000000000000000000
+01a2:0000000000001c102730437043b0c1b0c1b0c1b0c1b0c1b0c1b041b0633032301c3000300030003000300070
+01a3:000000000000000000000000000000001c102730437041b0c1b0c1b041b063303c3000300030003000300070
+01a4:0000000000007fc09860d830d830183018601bc01800180018001800180018003c0000000000000000000000
+01a5:000000000000000018002c0060006f8071c060e06060606060606060604070807f006000600060006000f000
+01a6:00000000f80060007f00618060c060c060807f00700078006c00660063006180e0c000600030000000000000
+01a7:0000000000007f8060c04060406000e003c007801e00380070006020602030601fe000000000000000000000
+01a8:00000000000000000000000000003f8030c020c001c007801e003800304030c01fc000000000000000000000
+01a9:0000000000007fe060203020180018000c0007000700040008001000202040207fe000000000000000000000
+01aa:000000003800640064003e00060006000600060006000600060006000600060006000660026001c000000000
+01ab:0000000000000000040004000c007fc00c000c000c000c000c000c000c200e6007a0002000c0038000000000
+01ac:0000000000003fe04620660066000600060006000600060006000600060006001f8000000000000000000000
+01ad:0000000001c002c004c004000c007fc00c000c000c000c000c000c000c200e60078000000000000000000000
+01ae:0000000000007fe046200600060006000600060006000600060006000600060006c002c001c0000000000000
+01af:006000d00010f070602060206020602060206020602060206020602070403fc01f8000000000000000000000
+01b0:0000000000000000006000d0001079e030c030c030c030c030c030c030c039c01e6000000000000000000000
+01b1:00000000000079e049200900118020c0204060606060606060606040304038800f0000000000000000000000
+01b2:000000000000f06060d060d06010601060106020602060206040604070803f001e0000000000000000000000
+01b3:000000000000f1e06090313031301a001a001a000c000c000c000c000c000c001e0000000000000000000000
+01b4:0000000000000000000000000000e1e0c05060b060b0310031001a001a000c000c00080018001000f000e000
+01b5:0000000000003fe020c000c00180018003001fe0060006000c000c00180018203fe000000000000000000000
+01b6:00000000000000000000000000007fe060e041c003803fe00e001c00382070607fe000000000000000000000
+01b7:0000000000003fe020c000c0018001800300030007c00fc000e000600060406060403f801f00000000000000
+01b8:0000000000007fc030403000180018000c000c003e003f00700060006000602020601fc00f80000000000000
+01b9:000000000000000000000000000000007fc0304018000c0006003f0070006000604020c01f800f0000000000
+01ba:00000000000000000000000000007fc04180030006000c0018003f8001c000c007803c007000604038c00f80
+01bb:000000001f003f8061c040c000c000c000c001801fe006000c00180030207fe07fe000000000000000000000
+01bc:000000007fc07fc02000200020003f8031c000e00060006000604060606030c01f8000000000000000000000
+01bd:000000000000000000007f807f80200020003f8031c000e000602060306018c00f8000000000000000000000
+01be:00000000000000000000080008001800ff8018001c000f0003c000e0106018601fc000000000000000000000
+01bf:0000000000000000000000000000ef8071c060e060606060606060606040608061006600780060006000f000
+01c0:0000000006000600060006000600060006000600060006000600060006000600060000000000000000000000
+01c1:0000000019801980198019801980198019801980198019801980198019801980198000000000000000000000
+01c2:00000000060006000600060006003fc0060006003fc006000600060006000600060000000000000000000000
+01c3:0000000006000600060006000600060006000600060006000600000000000600060000000000000000000000
+01c4:0c3006600180f3f0da10cc10c620c620c620c640c640c640c680c680c480d910e1f000000000000000000000
+01c5:000000000630f360d9c0cc00c400c5f0c510c420c420c440c440c480c480d910e1f000000000000000000000
+01c6:0c30066001800c001c000c000c006df0dd108c208c208c408c408c808c80dd107bf000000000000000000000
+01c7:000000000000f1f0606060606060606060606060606060606060606061606160ff6000600060004003800300
+01c8:000000000000f03060306000600060f060306030603060306030603060b060b0ffb008300c300e2007c00380
+01c9:000000000000786018601800180019e0186018601860186018601860186018607e60106018601c400f800700
+01ca:000000000000e3f0c130e130e130b130b130993099308d308d30873087308330c7b000300030002001c00180
+01cb:000000000000e330c130e100e100b170b130993099308d308d30873087308330c7b008300c300e2007c00380
+01cc:00000000000000300030000000004f70f3b061b061b061b061b061b061b061b0f3f008300c300e2007c00380
+01cd:18c00d800700060006000b000b0009001180118010803fc020c0204040604060e0f000000000000000000000
+01ce:0000000018c00d800700000000000f8018c010c003c01cc030c030c030c039c01ee000000000000000000000
+01cf:18c00d8007001f800600060006000600060006000600060006000600060006001f8000000000000000000000
+01d0:0000000031801b000e00000000001e00060006000600060006000600060006001f8000000000000000000000
+01d1:31801b000e000f0011c020c020606060606060606060606060602040304018800f0000000000000000000000
+01d2:0000000031801b000e00000000000f8011c020e06060606060606060704038801f0000000000000000000000
+01d3:18c00d800700f070602060206020602060206020602060206020602070403fc01f8000000000000000000000
+01d4:0000000018c00d8007000000000079e030c030c030c030c030c030c030c039c01e6000000000000000000000
+01d5:7fe030c030c00000f07060206020602060206020602060206020602070403fc01f8000000000000000000000
+01d6:00007fe0000030c030c00000000079e030c030c030c030c030c030c030c039c01e6000000000000000000000
+01d7:030066606c600000f07060206020602060206020602060206020602070403fc01f8000000000000000000000
+01d8:00000180030036c030c00000000079e030c030c030c030c030c030c030c039c01e6000000000000000000000
+01d9:18c00d80676060600000f0706020602060206020602060206020602070403fc01f8000000000000000000000
+01da:000018c00d80070060606060000079e030c030c030c030c030c030c030c039c01e6000000000000000000000
+01db:0c000600636060600000f0706020602060206020602060206020602070403fc01f8000000000000000000000
+01dc:00000c000600030060606060000079e030c030c030c030c030c030c030c039c01e6000000000000000000000
+01dd:00000000000000000000000000001f00618000c0006000607fe06060606030c00f0000000000000000000000
+01de:7fe000006060666006000b000b0009001180118010803fc020c0204040604060e0f000000000000000000000
+01df:00007fe0000019801980000000000f8018c010c003c01cc030c030c030c039c01ee000000000000000000000
+01e0:7fe000000f000f0006000b000b0009001180118010803fc020c0204040604060e0f000000000000000000000
+01e1:7fe0000006000f000f00060000000f8018c010c003c01cc030c030c030c039c01ee000000000000000000000
+01e2:7fe0000000000fe00e20162016001600164027c026403e002600460046104610e7f000000000000000000000
+01e3:00000000000000007fe0000000001f80364026600e603fe066006600660067603fc000000000000000000000
+01e4:0000000000000fc010602020200060006000600061f06060606027f0306018600f8000000000000000000000
+01e5:00000000000000000000000000001f2031e060c060c060c031803f0060007fc03fe02060fff040207fc03f80
+01e6:18c00d8007000fc0106020202000600060006000600061f060602060306018600f8000000000000000000000
+01e7:0000000018c00d800700000000001f2031e060c060c060c031803f0060007fc03fe02060402040207fc03f80
+01e8:18c00d800700f0e06180630066006c00780078007c006e006700638061c060e0f07000000000000000000000
+01e9:18c00d806700e00060006000600061c0630066007c0078007c006e0067006380f1e000000000000000000000
+01ea:0000000000000f0011c020c020606060606060606060606060602040304018800f0006000c0018000f000000
+01eb:00000000000000000000000000000f8011c020e06060606060606060704038801f0006000c0018000f000000
+01ec:7fe0000000000f0011c020c020606060606060606060606060602040304018800f0006000c0018000f000000
+01ed:00000000000000007fe0000000000f8011c020e06060606060606060704038801f0006000c0018000f000000
+01ee:18c00d8007003fe020c000c0018001800300030007c00fc000e000600060406060403f801f00000000000000
+01ef:00000000000031801b000e00000000007fc04180030006000c001f8001c000c040c060803f001e0000000000
+01f0:000000000c6006c003800000000007800180018001800180018001800180018001804180618071003e001c00
+01f1:000000000000f3f0da10cc10c620c620c620c640c640c640c680c680c480d910e1f000000000000000000000
+01f2:000000000000f000d800cc00c400c5f0c510c420c420c440c440c480c480d910e1f000000000000000000000
+01f3:0000000000000c001c000c000c006df0dd108c208c208c408c408c808c80dd107bf000000000000000000000
+01f4:03800f001c000fc0106020202000600060006000600061f060602060306018600f8000000000000000000000
+01f5:0000000003800f001c00000000001f2031e060c060c060c031803f0060007fc03fe02060402040207fc03f80
+01f6:000000000000ef00c600c600c600c600c670fe30c630c630c630c630c630c630efe000000000000000000000
+01f7:000000000000ef8071c060e06060606060606060606060c060c061006100660078006000600060006000f000
+01f8:38001e000700c07060207020782058204c2046204720432041a040e040e04060e03000000000000000000000
+01f9:0000000038001e00070000000000278079c030c030c030c030c030c030c030c079e000000000000000000000
+01fa:06001800660009000900060006000b000900118011803fc020c0204040604060e0f000000000000000000000
+01fb:03800f001c0009000900060000000f8018c010c003c01cc030c030c030c039c01ee000000000000000000000
+01fc:03800f001c000fe00e20162016001600164027c026403e002600460046104610e7f000000000000000000000
+01fd:0000000003800f001c00000000001f80364026600e603fe066006600660067603fc000000000000000000000
+01fe:03800f001c600fc011c021c021e06360636066606c606c6078603840304038806f0000000000000000000000
+01ff:0000000003800f001c00000000000fe011c021e06360666066606c60784038807f0000000000000000000000
+0200:e38079e01c70060006000b000b0009001180118010803fc020c0204040604060e0f000000000000000000000
+0201:00000000e38079e01c70000000000f8018c010c003c01cc030c030c030c039c01ee000000000000000000000
+0202:0f0019801980060006000b000b0009001180118010803fc020c0204040604060e0f000000000000000000000
+0203:000000000f0019801980000000000f8018c010c003c01cc030c030c030c039c01ee000000000000000000000
+0204:e38079e01c707fc0304030403000300030803f803080300030003000302030207fe000000000000000000000
+0205:00000000e38079e01c70000000000f0030c0606060607fe060006000300018600f8000000000000000000000
+0206:0f001980198000007fc0304030403000300030803f80308030003000302030207fe000000000000000000000
+0207:000000000f0019801980000000000f0030c0606060607fe060006000300018600f8000000000000000000000
+0208:e38079e01c7000001f80060006000600060006000600060006000600060006001f8000000000000000000000
+0209:00000000e38079e01c70000000001e00060006000600060006000600060006001f8000000000000000000000
+020a:0f001980198000001f80060006000600060006000600060006000600060006001f8000000000000000000000
+020b:000000000f0019801980000000001e00060006000600060006000600060006001f8000000000000000000000
+020c:e38079e01c700f0011c020c020606060606060606060606060602040304018800f0000000000000000000000
+020d:00000000e38079e01c70000000000f8011c020e06060606060606060704038801f0000000000000000000000
+020e:0f001980198000000f0011c020c02060606060606060606060602040304018800f0000000000000000000000
+020f:000000000f0019801980000000000f8011c020e06060606060606060704038801f0000000000000000000000
+0210:e38079e01c70ff00618060c060c060c060807f007c006e006700638061c060e0f07000000000000000000000
+0211:00000000e38079e01c7000000000738034c038c0300030003000300030003000780000000000000000000000
+0212:0f00198019800000ff00618060c060c060807f007c006e006700638061c060e0f07000000000000000000000
+0213:000000000f001980198000000000738034c038c0300030003000300030003000780000000000000000000000
+0214:e38079e01c700000f07060206020602060206020602060206020602070403fc01f8000000000000000000000
+0215:00000000e38079e01c700000000079e030c030c030c030c030c030c030c039c01e6000000000000000000000
+0216:0f00198019800000f07060206020602060206020602060206020602070403fc01f8000000000000000000000
+0217:000000000f00198019800000000079e030c030c030c030c030c030c030c039c01e6000000000000000000000
+0218:0000000000001fe030606020602070003c001e00078001c000e04060406060c07f8000000f000f0003001e00
+0219:00000000000000000000000000001fc030c0304038001e00078001c020c030c03f8000000f000f0003001e00
+021a:0000000000007fe04620060006000600060006000600060006000600060006001f8000000f000f0003001e00
+021b:0000000000000000040004000c007fc00c000c000c000c000c000c000c200e40078000000f000f0003001e00
+021c:0000000020003f8020c000600060006001c007003e00018000600060006000e001c007003c00000000000000
+021d:000000000000000020003f8020c00060006001c007003e0001800060006000e001c007003c00000000000000
+021e:31801b000e00f0f0606060606060606060607fe0606060606060606060606060f0f000000000000000000000
+021f:18c00d8017003000700030003000378039c030c030c030c030c030c030c030c079e000000000000000000000
+0220:000000000000278079c030c030c030c030c030c030c030c030c030c030c030c078c000c000c000c000c001e0
+0221:00000000018003800180018001801d8067804380c180c180c180c1e0e390759039e002000400000000000000
+0222:000000000900118030c030c030c018800d0006000b00118030c030c030c018800f0000000000000000000000
+0223:00000000000000000900118030c030c018800d0006000b00118030c030c018800f0000000000000000000000
+0224:0000000000003fe020c000c00180018003000300060006000c000c00180018003fc00060006001c000000000
+0225:00000000000000000000000000007fe060e041c0038007000e001c00380070007fc00060006001c000000000
+0226:06000f0006000000060006000b000b000900118010803fc020c0204040604060e0f000000000000000000000
+0227:0000000006000f000f00060000000f8018c010c003c01cc030c030c030c039c01ee000000000000000000000
+0228:0000000000007fc0304030403000300030803f803080300030003000302030207fe002000300018009800700
+0229:00000000000000000000000000000f0030c0606060607fe060006000300018600f8002000300018009800700
+022a:7fe00000606060600f0011c020c02060606060606060606060602040304018800f0000000000000000000000
+022b:000000003fc0000030c030c000000f8011c020e06060606060606060704038801f0000000000000000000000
+022c:7fe000003c6063c00f0011c020c02060606060606060606060602040304018800f0000000000000000000000
+022d:00003fc000000cc01f80330000000f8011c020e06060606060606060704038801f0000000000000000000000
+022e:06000f00060000000f0011c020c02060606060606060606060602040304018800f0000000000000000000000
+022f:0000000006000f000600000000000f8011c020e06060606060606060704038801f0000000000000000000000
+0230:3fc000000f000f0000000f0011c020c0206060606060606060602040304018800f0000000000000000000000
+0231:3fc0000006000f000600000000000f8011c020e06060606060606060704038801f0000000000000000000000
+0232:3fc000000000f07060203040188018800d0006000600060006000600060006000f0000000000000000000000
+0233:00000000000000003fc000000000f0f0602030403040188018800d000d000600060004000c00080078007000
+0234:000000001e00060006000600060006000600060006000600060006c0076006401f8004000800000000000000
+0235:0000000000000000000000000000278079c030c030c030c030c030e030d030d079e001000200000000000000
+0236:0000000000000000040004000c007fc00c000c000c000c000c000cc00d600e40078008001000000000000000
+0237:000000000000000000000000000003c000c000c000c000c000c000c000c000c000c020c030c038801f000e00
+0238:0000000006000e0006000600060036c07fe04f20c630c630c630c630ef7079e030c000000000000000000000
+0239:000000000000000000000000000030c079e0ef70c630c630c630c6304f207fe036c006000600060006000f00
+023a:0000000000100620064006800f000b001580198010803fc060c0a04040604060e0f000000000000000000000
+023b:0000004000400fc010e020a02080610061006100620062006200240034201c400f8008000800000000000000
+023c:00000000000000000000004000801f8031c021c06200620064006400784038c01f8010002000000000000000
+023d:0000000000003c0018001800180018001800ff001800180018001800181018103ff000000000000000000000
+023e:0000002000207fe046400680068007000700060006000e000e001600160026003f8040004000000000000000
+023f:00000000000000000000000000001fc030c0304038001e00078001c020c030c03f8018000c00066003c00000
+0240:00000000000000000000000000007fe060e041c0038007000e001c0038007000700018000c00066003c00000
+0241:000000001e007180604060600060006000c001800f000c000c000c000c000c001e0000000000000000000000
+0242:0000000000000000000000001e00718060c000c000c001800e00080008001c00000000000000000000000000
+0243:000000000000ff00608060c060c060c061807f8060c06060fc606060606060c0ff8000000000000000000000
+0244:000000000000f0706020602060206020fff06020602060206020602070403fc01f8000000000000000000000
+0245:00000000000002000200020007000700070009800980098010c010c010c02060707000000000000000000000
+0246:0000008000807fc0314031403100320032803f803480340034003800382038207fe010001000000000000000
+0247:00000000000000000080008001000f0032c0626064607fe068006800300018602f8020000000000000000000
+0248:0000000000001f8006000600060006000600060006003fc00600060006000600060006000600040038003000
+0249:000000000000018001800000000007800180018001800ff0018001800180018001804180618071003e001c00
+024a:000000001cc0278043804180c180c180c180c180c180c180c180e18073803f8001800180018001b000b00060
+024b:00000000000000000000000000001cc027804380c180c180c180c180e18073803f800180018001b000b00060
+024c:000000000000ff00618060c060c060c06080ff007c006e006700638061c060e0f07000000000000000000000
+024d:000000000000000000000000000039c01a601c601800ff0018001800180018003c0000000000000000000000
+024e:000000000000f07060203040fff018800d0006000600060006000600060006000f0000000000000000000000
+024f:0000000000000000000000000000f0f0602030403040fff018800d000d000600060004000c00080078007000
+0250:0000000000000000000000000000778039c030c030c030c033803c00308031801f0000000000000000000000
+0251:00000000000000000000000000003f2063a0c1c0c1c0c180c180c180c3c0e4c0786000000000000000000000
+0252:0000000000000000000000000000c3c064e0786030603060306070607060b8c09f8000000000000000000000
+0253:000000001e00230063006000600067806fc070e06060606060606060706078c04f8000000000000000000000
+0254:00000000000000000000000000003f00618041c000c000c000c000c0608071803f0000000000000000000000
+0255:00000000000000000000000000001f8031c020c06000600060006380744038c05f8000000000000000000000
+0256:0000000000c001c000c000c000c01ec063c041c0c0c0c0c0c0c0c0c0e1c072c03cc000d00050007000000000
+0257:00000000007000d000d000d000c01ec063c041c0c0c0c0c0c0c0c0c0e1c072c03ce000000000000000000000
+0258:00000000000000000000000000000f0030c0606060607fe00060006000c061801f0000000000000000000000
+0259:00000000000000000000000000001f00618000c0006000607fe06060606030c00f0000000000000000000000
+025a:00000000000000000000000000003c00c690035003200d803180c180c18063001c0000000000000000000000
+025b:00000000000000000000000000000f801fc0206060003f003f00600060203fc01f0000000000000000000000
+025c:00000000000000000000000000001f003f80604000600fc00fc0006040603fc00f8000000000000000000000
+025d:00000000000000000000000000003e107f50c0b000d01f801f8000c080c07f801f0000000000000000000000
+025e:00000000000000000000000000001f003f806040c060cfc0cfc0c06040603fc00f8000000000000000000000
+025f:0000000007800300030003000300030003001f800300030003000300320032001c0000000000000000000000
+0260:000000000000000000e0013001301f8031c060c060c060c060c060c061c033c01ec00040204030c01f800f00
+0261:00000000000000000000000000001f8031c060c060c060c060c060c061c033c01ec00040204030c01f800f00
+0262:00000000000000000000000000000fc0106020206000600061f06060306018600f8000000000000000000000
+0263:000000000000000000000000000070e0304030401880188019000d000e0006000e0013001300218021801f00
+0264:0000000000000000000000000000000000007060d8b0989099100d000e0006000e0013001300218021801f00
+0265:0000000079e030c030c030c030c030c030c030c039c01ec000c000c000e000c0008000000000000000000000
+0266:000000001e003300330030003000378039c030c030c030c030c030c030c030c079e000000000000000000000
+0267:0000000010003000700030003000378039c030c030c030c030c030c030c030c078c000c00380070000000000
+0268:00000000000006000600000000001e000600060006003fc006000600060006001f8000000000000000000000
+0269:00000000000000000000000000001e00060006000600060006000600060006001f8000000000000000000000
+026a:00000000000000000000000000001f80060006000600060006000600060006001f8000000000000000000000
+026b:000000001e00060006000600060006001e6067800600060006000600060006001f8000000000000000000000
+026c:000000001e00060006000600060006003e0066003fc0060006000600060006001f8000000000000000000000
+026d:000000001e0006000600060006000600060006000600060006000600060006000660066003c0018000000000
+026e:00000000f00030003000300030003ff0306030c0318033003600338030e03070fc700070186019c00f800000
+026f:0000000000000000000000000000ef70666066606660666066606660666077603bb000000000000000000000
+0270:0000000000000000000000000000ef70666066606660666066606660666076e03b6000600060006000300000
+0271:0000000000000000000000000000ddc06ee06660666066606660666066606660ef6000600660066003c00000
+0272:000000000000000000000000000013c03ce0186018601860186018601860186018f0d800d800700000000000
+0273:00000000000000000000000000004f00f3806180618061806180618061806180f18001b001b000e000000000
+0274:0000000000000000000000000000c0e06040704058404c404640434041c040c0e06000000000000000000000
+0275:00000000000000000000000000000f8011c020e060607fe07fe06060704038801f0000000000000000000000
+0276:00000000000000000000000000001de023304200c210c3f0c210c200e20073303de000000000000000000000
+0277:000000000000000000000f003fc06060c030c630c630c630c630c63066207fc0198000000000000000000000
+0278:0000000000000000060006000f8017c026e0666066606660666076403e801f00060006000000000000000000
+0279:000000000000000000000000000003c00180018001800180018001806380658039c000000000000000000000
+027a:000000000000000003c00180018001800180018001800180018001806380658039c000000000000000000000
+027b:00000000000000000000000000000780030003000300030003000300c700cb0073000330033001e000000000
+027c:0000000000000000000000000000738034c038c0300030003000300030003000300030003000780000000000
+027d:0000000000000000000000000000738034c038c0300030003000300030003000300031801b800e0000000000
+027e:000000000000000000000000038004c004c00c000c000c000c000c000c000c001e0000000000000000000000
+027f:0000000000000000000000001c00320032000300030003000300030003000300030003000300078000000000
+0280:00000000000000000000000000007f8030c0306030403f803e003700338031c078e000000000000000000000
+0281:000000000000000000000000000078e031c0338037003e003f803040306030c07f8000000000000000000000
+0282:00000000000000000000000000001fc030c0304038001e00078001c020c030c03f801000100013000e000000
+0283:0000000001c00260066006000600060006000600060006000600060006000600060006000600640064003800
+0284:0000000001c00260066006000600060006000600060006000600060006003fc0060006000600640064003800
+0285:00000000380064006400060006000600060006000600060006000600060006000600060006000660026001c0
+0286:0000000001c0026006600600060006000600060006000600060006000600060006003fc06660646064003800
+0287:00000000000000001e00270043000300030003000300030003003fe003000200020000000000000000000000
+0288:0000000000000000040004000c007fc00c000c000c000c000c000c000c000c000cc004c00380000000000000
+0289:000000000000000000000000000079e030c030c030c0fff030c030c030c039c01e6000000000000000000000
+028a:000000000000000000000000000079e009001880304060606060206020c011c00f0000000000000000000000
+028b:000000000000000000000000000078c031c03060306030603060306030e039c01f0000000000000000000000
+028c:0000000000000000000000000000060006000b000b001180118020c020c04060e0f000000000000000000000
+028d:00000000000000000000000000001980198019802dc02dc02ec0466046604660eff000000000000000000000
+028e:0000000000e001e0010003000200060006000b000b001180118020c020c04060f0f000000000000000000000
+028f:0000000000000000000000000000f0706020304018800d0006000600060006000f0000000000000000000000
+0290:00000000000000000000000000007fe060e041c0038007000e001c00380070407f80019000f0006000000000
+0291:00000000000000000000000000007fe060e041c0038007000e001c00386070907fe002000400000000000000
+0292:000000000000000000000000000000007fc04180030006000c001f8001c000c040c060803f001e0000000000
+0293:000000000000000000000000000000007fc04180030006000c001f8001c038c044c062803f001e8000400000
+0294:000000001e007180604060600060006000c001800f000c000c000c000c000c001e0000000000000000000000
+0295:00000000078018e02060606060006000300018000f0003000300030003000300078000000000000000000000
+0296:000000001e000c000c000c000c000c000f00018000c0006000606060604071801e0000000000000000000000
+0297:0000000000000000000000000fc0106020202000600060006000600060006000600060002000302018400f80
+0298:0000000000000f0011c020c020606060666066606060606060602040304018800f0000000000000000000000
+0299:0000000000000000000000000000ff00608060c061807f8060c06060606060c0ff8000000000000000000000
+029a:00000000000000000000000000001f003f8040c0c0607e607e60c060c0407f803e0000000000000000000000
+029b:00000000000000000000007000900fc0106020206000600061f06060306018600f8000000000000000000000
+029c:0000000000000000000000000000f1e060c060c060c07fc060c060c060c060c0f1e000000000000000000000
+029d:00000000000003000300000000000f000300030003000300030003000300030007c01b00230022001c000000
+029e:00000000f1e038c01cc00ec007c003c007c00cc018c070c000c000c000c000e000c000000000000000000000
+029f:00000000000000000000000000007800300030003000300030003000300030407fc000000000000000000000
+02a0:00000000000000000030005000501e4023c041c0c0c0c0c0c0c0c0c0e0c071c03fc000c000c000c000c001e0
+02a1:000000001e007180604060600060006000c001800f000c007f800c000c000c001e0000000000000000000000
+02a2:00000000078018e02060606060006000300018000f0003001fe0030003000300078000000000000000000000
+02a3:0000000000000c001c000c000c006df0dd108c208c208c408c408c808c80dd107bf000000000000000000000
+02a4:0000000000000c001c000c000c006df0dd108c208c208c408c408cc08c60dc307a1000100c20064001800000
+02a5:0000000000000c001c000c000c006df0dd108c208c208c408c408c808ce0dd907bf001000200000000000000
+02a6:0000000000000000200020006000fff0663066106700638060e06070623066303fe000000000000000000000
+02a7:0000000000e00130233023006300ff00630063006300630063006300630073003f0003000300320032001c00
+02a8:0000000000000000200020006000f9e0633062106600660066006660629063b03de001000200000000000000
+02a9:000000001800260026006000600060006000fbc0666066606660666066606660f760006000600c600cc00780
+02aa:0000000000000000e0006000600063f0663066106700638060e06070643066303fe000000000000000000000
+02ab:0000000000000000e0006000600067f066306430607060e061c06380671066303ff000000000000000000000
+02ac:00000000ff706620662037403b40198019800000ff706620662037403b401980198000000000000000000000
+02ad:0000000000000000000000007fe07fe060606060000000007fe07fe060606060000000000000000000000000
+02ae:00006000a1e0b0c0b0c030c030c030c030c030c039c01ec000c000c000e000c0008000000000000000000000
+02af:00006000a1e0b0c0b0c030c030c030c030c030c039c01ec000c000c000d00050005000600000000000000000
+02b0:000000001000300070003000378039c030c030c030c030c079e0000000000000000000000000000000000000
+02b1:00000f001380300030003000378039c030c030c030c030c079e0000000000000000000000000000000000000
+02b2:000000c000c0000003c000c000c000c000c000c000c010c018800f0000000000000000000000000000000000
+02b3:0000000033801cc0180018001800180018003c00000000000000000000000000000000000000000000000000
+02b4:0000000003c00180018001800180018033801cc0000000000000000000000000000000000000000000000000
+02b5:0000000007800300030003000300030067003b00030001600080000000000000000000000000000000000000
+02b6:0000000078e031c0338037003e003f803040306030c07f800000000000000000000000000000000000000000
+02b7:00000000eff0466046602ec02dc02dc019801980198000000000000000000000000000000000000000000000
+02b8:0000000078f0302018400c800d000500060006000c0038003000000000000000000000000000000000000000
+02b9:0000000003000300060006000c000c0000000000000000000000000000000000000000000000000000000000
+02ba:000000000c600c6018c018c03180318000000000000000000000000000000000000000000000000000000000
+02bb:000000000100030006000c000c000f000f000600000000000000000000000000000000000000000000000000
+02bc:0000000006000f000f000300030006000c000800000000000000000000000000000000000000000000000000
+02bd:0000000006000f000f000c000c00060003000100000000000000000000000000000000000000000000000000
+02be:000000000e0003800180018003800e0000000000000000000000000000000000000000000000000000000000
+02bf:0000000007001c00180018001c00070000000000000000000000000000000000000000000000000000000000
+02c0:000000001e00718060c000c001800e0008000800080000000000000000000000000000000000000000000000
+02c1:00000000078018e0306030001800070001000100010000000000000000000000000000000000000000000000
+02c2:0000000000e003800e0038000e00038000e00000000000000000000000000000000000000000000000000000
+02c3:0000000070001c00070001c007001c0070000000000000000000000000000000000000000000000000000000
+02c4:0000000006000f00198030c06060000000000000000000000000000000000000000000000000000000000000
+02c5:00000000606030c019800f000600000000000000000000000000000000000000000000000000000000000000
+02c6:0000000006001f8030c000000000000000000000000000000000000000000000000000000000000000000000
+02c7:0000000030c01980060000000000000000000000000000000000000000000000000000000000000000000000
+02c8:0000000006000600060006000600060000000000000000000000000000000000000000000000000000000000
+02c9:000000003fc03fc0000000000000000000000000000000000000000000000000000000000000000000000000
+02ca:03800f001c000000000000000000000000000000000000000000000000000000000000000000000000000000
+02cb:1c000f0003800000000000000000000000000000000000000000000000000000000000000000000000000000
+02cc:0000000000000000000000000000000000000000000000000000000000000000000006000600060006000600
+02cd:00000000000000000000000000000000000000000000000000000000000000000000000000003fc03fc00000
+02ce:1c000f0003800000000000000000000000000000000000000000000000000000000000000000000000000000
+02cf:03800f001c000000000000000000000000000000000000000000000000000000000000000000000000000000
+02d0:00000000000000000000000000001f800f000600000000000000000006000f001f8000000000000000000000
+02d1:00000000000000000000000000001f800f000600000000000000000000000000000000000000000000000000
+02d2:000000000000000000000000000000000e0003800180018003800e0000000000000000000000000000000000
+02d3:0000000000000000000000000000000007001c00180018001c00070000000000000000000000000000000000
+02d4:0000000000000000000000000000000006000600060006001f801f8000000000000000000000000000000000
+02d5:000000000000000000000000000000001f801f80060006000600060000000000000000000000000000000000
+02d6:00000000000000000000000000000000060006001f801f800600060000000000000000000000000000000000
+02d7:00000000000000000000000000000000000000001f801f800000000000000000000000000000000000000000
+02d8:198019800f000000000000000000000000000000000000000000000000000000000000000000000000000000
+02d9:06000f0006000000000000000000000000000000000000000000000000000000000000000000000000000000
+02da:0f00198019800f00000000000000000000000000000000000000000000000000000000000000000000000000
+02db:000000000000000000000000000000000000000000000000000000000000000000000600030001800f000000
+02dc:1c6036c063800000000000000000000000000000000000000000000000000000000000000000000000000000
+02dd:1c7079e0e3800000000000000000000000000000000000000000000000000000000000000000000000000000
+02de:0000000000000000000000000000000000001c0036c003800100000000000000000000000000000000000000
+02df:30c019800f0006000f00198030c0000000000000000000000000000000000000000000000000000000000000
+02e0:0000000070e03040188019000d000e0006000e00130021801f00000000000000000000000000000000000000
+02e1:00001e000600060006000600060006000600060006001f800000000000000000000000000000000000000000
+02e2:000000001fc030c038001e00078001c030c03f80000000000000000000000000000000000000000000000000
+02e3:0000000079c0308019000e000700098010c039e0000000000000000000000000000000000000000000000000
+02e4:00000000070018c018c018000e00020002000000000000000000000000000000000000000000000000000000
+02e5:00000000000000003f8001800180018001800180018001800180018001800180018000000000000000000000
+02e6:00000000000000000180018001803f8001800180018001800180018001800180018000000000000000000000
+02e7:00000000000000000180018001800180018001803f8001800180018001800180018000000000000000000000
+02e8:00000000000000000180018001800180018001800180018001803f8001800180018000000000000000000000
+02e9:00000000000000000180018001800180018001800180018001800180018001803f8000000000000000000000
+02ea:00000000000000000000000000000000000000003000300030003000300030003f8000000000000000000000
+02eb:00000000000000000000000000000000000000003000300030003f8030003000300000000000000000000000
+02ec:0000000000000000000000000000000000000000000000000000000000000000000060c031801b000e000400
+02ed:00007fe000007fe0000000000000000000000000000000000000000000000000000000000000000000000000
+02ee:0000000030c079e079e01860186030c061804100000000000000000000000000000000000000000000000000
+02ef:00000000000000000000000000000000000000000000000000000000000000000000606030c019800f000600
+02f0:0000000000000000000000000000000000000000000000000000000000000000000006000f00198030c06060
+02f1:00000000000000000000000000000000000000000000000000000000000000e003800e0038000e00038000e0
+02f2:00000000000000000000000000000000000000000000000000000000000070001c00070001c007001c007000
+02f3:0000000000000000000000000000000000000000000000000000000000000000000000000f00198019800f00
+02f4:000000000000000000000000000000001c000f00038000000000000000000000000000000000000000000000
+02f5:00000000000000000000000000000000e38079e01c7000000000000000000000000000000000000000000000
+02f6:000000000000000000000000000000001c7079e0e38000000000000000000000000000000000000000000000
+02f7:00000000000000000000000000000000000000000000000000000000000000000000000000001c6036c06380
+02f8:000000000c001e001e000c00000000000c001e001e000c000000000000000000000000000000000000000000
+02f9:000000003f803f80300030003000300030000000000000000000000000000000000000000000000000000000
+02fa:000000001fc01fc000c000c000c000c000c00000000000000000000000000000000000000000000000000000
+02fb:0000000000000000000000000000000000000000300030003000300030003f803f8000000000000000000000
+02fc:000000000000000000000000000000000000000000c000c000c000c000c01fc01fc000000000000000000000
+02fd:0000000000000000000000000000000000000000606060606060606060607fe07fe000000000000000000000
+02fe:0000000000000000000000000000000000000000600060006000600060007fe07fe000000000000000000000
+02ff:00000000000000000000000000000000000000000000000000000000000000000000100030007fe030001000
0300:0c00060003000000000000000000000000000000000000000000000000000000000000000000000000000000
0301:030006000c000000000000000000000000000000000000000000000000000000000000000000000000000000
0302:04000e001b003180000000000000000000000000000000000000000000000000000000000000000000000000
0303:1c803f8027000000000000000000000000000000000000000000000000000000000000000000000000000000
0304:00001f801f800000000000000000000000000000000000000000000000000000000000000000000000000000
-0306:1b001b000e000000000000000000000000000000000000000000000000000000000000000000000000000000
+0305:00007fe07fe00000000000000000000000000000000000000000000000000000000000000000000000000000
+0306:198019800f000000000000000000000000000000000000000000000000000000000000000000000000000000
+0307:0600060000000000000000000000000000000000000000000000000000000000000000000000000000000000
0308:1980198000000000000000000000000000000000000000000000000000000000000000000000000000000000
+0309:0e00130003000600000000000000000000000000000000000000000000000000000000000000000000000000
030a:0e001b001b000e00000000000000000000000000000000000000000000000000000000000000000000000000
+030b:1c7079e0e3800000000000000000000000000000000000000000000000000000000000000000000000000000
030c:31801b000e000400000000000000000000000000000000000000000000000000000000000000000000000000
+030d:0600060006000600000000000000000000000000000000000000000000000000000000000000000000000000
+030e:1980198019801980000000000000000000000000000000000000000000000000000000000000000000000000
+030f:e38079e01c700000000000000000000000000000000000000000000000000000000000000000000000000000
+0310:666030c01f800000000000000000000000000000000000000000000000000000000000000000000000000000
+0311:0f00198019800000000000000000000000000000000000000000000000000000000000000000000000000000
+0312:07000c000f000f00000000000000000000000000000000000000000000000000000000000000000000000000
+0313:0f000f0003000e00000000000000000000000000000000000000000000000000000000000000000000000000
+0314:0f000f000c000700000000000000000000000000000000000000000000000000000000000000000000000000
+0315:01e001e0006001c0000000000000000000000000000000000000000000000000000000000000000000000000
+0316:00000000000000000000000000000000000000000000000000000000000000000000000000001c000f000380
+0317:000000000000000000000000000000000000000000000000000000000000000000000000000003800f001c00
+0318:00000000000000000000000000000000000000000000000000000000000000000000008000800f8000800080
+0319:00000000000000000000000000000000000000000000000000000000000000000000100010001f0010001000
+031a:00f0001000100010000000000000000000000000000000000000000000000000000000000000000000000000
+031b:00000000000000f000f0003000e0000000000000000000000000000000000000000000000000000000000000
+031c:0000000000000000000000000000000000000000000000000000000000000000000007001c0018001c000700
+031d:0000000000000000000000000000000000000000000000000000000000000000000004000400040004001f00
+031e:000000000000000000000000000000000000000000000000000000000000000000001f000400040004000400
+031f:00000000000000000000000000000000000000000000000000000000000000000000040004001f0004000400
+0320:00000000000000000000000000000000000000000000000000000000000000000000000000001f0000000000
+0321:0000000000000000000000000000000000000000000000000000000000000000000000800080008001001e00
+0322:00000000000000000000000000000000000000000000000000000000000000000000020002000200010000f0
+0323:0000000000000000000000000000000000000000000000000000000000000000000000000000060006000000
+0324:0000000000000000000000000000000000000000000000000000000000000000000000000000198019800000
+0325:0000000000000000000000000000000000000000000000000000000000000000000000000600090009000600
+0326:0000000000000000000000000000000000000000000000000000000000000000000000000f000f0003000e00
0327:000000000000000000000000000000000000000000000000000000000000000000000600030001800f000000
0328:0000000000000000000000000000000000000000000000000000000000000000000006000c0018000f000000
+0329:0000000000000000000000000000000000000000000000000000000000000000000006000600060006000000
+032a:0000000000000000000000000000000000000000000000000000000000000000000000007fe0402040200000
+032b:000000000000000000000000000000000000000000000000000000000000000000000000462046207fe00000
+032c:00000000000000000000000000000000000000000000000000000000000000000000000018c00d8007000000
+032d:00000000000000000000000000000000000000000000000000000000000000000000000004000e001b003180
+032e:000000000000000000000000000000000000000000000000000000000000000000000000198019800f000000
+032f:0000000000000000000000000000000000000000000000000000000000000000000000000f00198019800000
+0330:0000000000000000000000000000000000000000000000000000000000000000000000000e401fc013800000
+0331:00000000000000000000000000000000000000000000000000000000000000000000000000001f801f800000
0332:00000000000000000000000000000000000000000000000000000000000000000000000000000000fff0fff0
+0333:00000000000000000000000000000000000000000000000000000000000000000000fff0fff00000fff0fff0
+0334:0000000000000000000000000000000000001c203e6036c067c0438000000000000000000000000000000000
+0335:00000000000000000000000000000000000000001f801f800000000000000000000000000000000000000000
+0336:00000000000000000000000000000000000000007fe07fe00000000000000000000000000000000000000000
+0337:0000000000000000000000000000000001800180060006001800180000000000000000000000000000000000
+0338:0000000000000000000000000060006001800180060006001800180060006000000000000000000000000000
+0339:0000000000000000000000000000000000000000000000000000000000000000000000000600010001000600
+033a:000000000000000000000000000000000000000000000000000000000000000000000000000080208020ffe0
+033b:0000000000000000000000000000000000000000000000000000000000000000000000000000ffe08020ffe0
+033c:00000000000000000000000000000000000000000000000000000000000000000000000071c08a2004000400
+033d:19800f0006000f00198000000000000000000000000000000000000000000000000000000000000000000000
+033e:0300060003000600000000000000000000000000000000000000000000000000000000000000000000000000
+033f:fff00000fff00000000000000000000000000000000000000000000000000000000000000000000000000000
+0340:0c00060003000000000000000000000000000000000000000000000000000000000000000000000000000000
+0341:030006000c000000000000000000000000000000000000000000000000000000000000000000000000000000
+0342:1c40238000000000000000000000000000000000000000000000000000000000000000000000000000000000
+0343:0e00010001000600000000000000000000000000000000000000000000000000000000000000000000000000
+0344:03800f00dc60c060000000000000000000000000000000000000000000000000000000000000000000000000
+0345:0000000000000000000000000000000000000000000000000000000000000000000000000600060007000000
+0346:7fe0402040200000000000000000000000000000000000000000000000000000000000000000000000000000
+0347:0000000000000000000000000000000000000000000000000000000000000000000000003fc000003fc00000
+0348:0000000000000000000000000000000000000000000000000000000000000000000000001980198019801980
+0349:0000000000000000000000000000000000000000000000000000000000000000000000000f00010001000100
+034a:1d20366066c04b80000000000000000000000000000000000000000000000000000000000000000000000000
+034b:060000203e606780400006000000000000000000000000000000000000000000000000000000000000000000
+034c:1e60678000001e60678000000000000000000000000000000000000000000000000000000000000000000000
+034d:0000000000000000000000000000000000000000000000000000000000000000000020406060fff060602040
+034e:0000000000000000000000000000000000000000000000000000000000000000000006000f001f8006000600
+034f:0000000000000000000000000000000000000000000000000000000000000000000000000000000000000000
+0350:1c00070001c007001c0000000000000000000000000000000000000000000000000000000000000000000000
+0351:0600080008000600000000000000000000000000000000000000000000000000000000000000000000000000
+0352:1f80606046200000000000000000000000000000000000000000000000000000000000000000000000000000
+0353:0000000000000000000000000000000000000000000000000000000000000000000060601980060019806060
+0354:0000000000000000000000000000000000000000000000000000000000000000000003800e0038000e000380
+0355:000000000000000000000000000000000000000000000000000000000000000000001c00070001c007001c00
+0356:00000000000000000000000000000000000000000000000000000000000000000000c0c031e00de03330c330
+0357:0c00020002000c00000000000000000000000000000000000000000000000000000000000000000000000000
+0358:0070007000700000000000000000000000000000000000000000000000000000000000000000000000000000
+0359:00000000000000000000000000000000000000000000000000000000000000000000090006001f8006000900
+035a:0000000000000000000000000000000000000000000000000000000000000000000071c08a2084208a2071c0
+035b:18003fe07fc00180000000000000000000000000000000000000000000000000000000000000000000000000
+035c:0000000000000000000000000000000000000000000000000000000000000000000020102010102008400780
+035d:2010201010200840078000000000000000000000000000000000000000000000000000000000000000000000
+035e:1ff01ff000000000000000000000000000000000000000000000000000000000000000000000000000000000
+035f:000000000000000000000000000000000000000000000000000000000000000000000000000000001ff01ff0
+0360:1e10333021e00000000000000000000000000000000000000000000000000000000000000000000000000000
+0361:0780084010202010201000000000000000000000000000000000000000000000000000000000000000000000
+0362:00000000000000000000000000000000000000000000000000000000000000000000004000603ff000600040
+0363:0f0000800f8010800f8000000000000000000000000000000000000000000000000000000000000000000000
+0364:0f0010801f0010000f0000000000000000000000000000000000000000000000000000000000000000000000
+0365:0200000002000200020000000000000000000000000000000000000000000000000000000000000000000000
+0366:0f001080108010800f0000000000000000000000000000000000000000000000000000000000000000000000
+0367:10801080108010800f0000000000000000000000000000000000000000000000000000000000000000000000
+0368:0f001000100010000f0000000000000000000000000000000000000000000000000000000000000000000000
+0369:0080008007800880078000000000000000000000000000000000000000000000000000000000000000000000
+036a:080008000f000880088000000000000000000000000000000000000000000000000000000000000000000000
+036b:5dc0664044404440444000000000000000000000000000000000000000000000000000000000000000000000
+036c:0b800c0008000800080000000000000000000000000000000000000000000000000000000000000000000000
+036d:04001f0004000400070000000000000000000000000000000000000000000000000000000000000000000000
+036e:1080108009000900060000000000000000000000000000000000000000000000000000000000000000000000
+036f:11000a0004000a00110000000000000000000000000000000000000000000000000000000000000000000000
+0370:0000000000007800300030003000300030003fc0300030003000300030003000780000000000000000000000
+0371:000000000000000000000000000078003000300030003fc03000300030003000780000000000000000000000
+0372:000000000000fff0c630c630c6300600060006000600060006000600060006001f8000000000000000000000
+0373:000000000000000000003fe04620462006000600060006000600060006000600060000000000000000000000
+0374:00000000000007000e000c000800000000000000000000000000000000000000000000000000000000000000
+0375:00000000000000000000000000000000000000000000000000000100030007000e0000000000000000000000
+0376:000000000000f0f0606060e06160616062606260646064606860686070606060f0f000000000000000000000
+0377:0000000000000000000000000000f0f0606060e0616062606460686070606060f0f000000000000000000000
+037a:0000000000000000000000000000000000000000000000000000000000000000000000000600060007000000
+037b:00000000000000000000000000000f8011c020e00060006000600060004038801f0000000000000000000000
+037c:00000000000000000000000000001f00388070406000670067006000200011c00f8000000000000000000000
+037d:00000000000000000000000000000f8011c020e000600e600e600060004038801f0000000000000000000000
+037e:000000000000000000000000000000000c001e001e000c00000000000c001e001e00060006000c0018001000
+037f:0000000000001f80060006000600060006000600060006000600060006000600060006000600040038003000
+0384:03800f001c000000000000000000000000000000000000000000000000000000000000000000000000000000
+0385:03800f00dc60c060000000000000000000000000000000000000000000000000000000000000000000000000
+0386:0000000000004600c600cb008b0009001180118010803fc020c0204040604060e0f000000000000000000000
+0387:0000000000000000000000000000000006000f000f0006000000000000000000000000000000000000000000
+0388:0000000000005fe0d820d8209800180018401fc01840180018001800181018103ff000000000000000000000
+0389:000000000000f8f0b060b060b060306030603fe030603060306030603060306078f000000000000000000000
+038a:0000000000004fc0c300c30083000300030003000300030003000300030003000fc000000000000000000000
+038c:0000000000004780c8e0d0609030303030303030303030303030102018200c40078000000000000000000000
+038e:0000000000007c70d820d8208c400c4006800300030003000300030003000300078000000000000000000000
+038f:0000000000004780c8e0d06090303030303030303030102018200c40048024903cf000000000000000000000
+0390:0000000003800f00dc60c06000001e00060006000600060006000600060006001f8000000000000000000000
+0391:000000000000060006000b000b0009001180118010803fc020c0204040604060e0f000000000000000000000
+0392:000000000000ff00608060c060c060c061807f8060c0606060606060606060c0ff8000000000000000000000
+0393:0000000000007fc0304030403000300030003000300030003000300030003000780000000000000000000000
+0394:00000000000006000e000b000b0011801180118020c020c020c04060406040607fe000000000000000000000
+0395:0000000000007fc0304030403000300030803f803080300030003000302030207fe000000000000000000000
+0396:0000000000003fe020c000c00180018003000300060006000c000c00180018203fe000000000000000000000
+0397:000000000000f0f0606060606060606060607fe0606060606060606060606060f0f000000000000000000000
+0398:0000000000000f8011c020e06060606060606f606060606060606060704038801f0000000000000000000000
+0399:0000000000001f800600060006000600060006000600060006000600060006001f8000000000000000000000
+039a:000000000000f0e06180630066006c00780078007c006e006700638061c060e0f07000000000000000000000
+039b:000000000000060006000b000b000b0011801180118020c020c020c040604060e0f000000000000000000000
+039c:000000000000e07060e070e070e070e05960596059604d604e604e6044604460e4f000000000000000000000
+039d:000000000000c07060207020782058204c2046204720432041a040e040e04060e03000000000000000000000
+039e:0000000000007fe0402000000000000000003fc03fc0000000000000000040207fe000000000000000000000
+039f:0000000000000f0011c020c020606060606060606060606060602040304018800f0000000000000000000000
+03a0:000000000000ffe0606060606060606060606060606060606060606060606060606000000000000000000000
+03a1:0000000000007f8030c030603060306030c03780300030003000300030003000780000000000000000000000
+03a3:0000000000007fe060203020180018000c0007000700040008001000202040207fe000000000000000000000
+03a4:0000000000007fe04620060006000600060006000600060006000600060006001f8000000000000000000000
+03a5:000000000000f07060203040188018800d0006000600060006000600060006000f0000000000000000000000
+03a6:000000000600060006000f8017c026e066606660666066606660666076403e801f0006000600060000000000
+03a7:000000000000f07060203040388018800d00060006000b00118011c020c04060e0f000000000000000000000
+03a8:000000000000ef70666066606660666076403f800f00060006000600060006000f0000000000000000000000
+03a9:0000000000000f0011c020c0206060606060606060602040304018800900492079e000000000000000000000
+03aa:30c030c000001f800600060006000600060006000600060006000600060006001f8000000000000000000000
+03ab:30c030c00000f07060203040188018800d0006000600060006000600060006000f0000000000000000000000
+03ac:00000000020006000600040000001f9031d060e060e060c060c060c061e072603c3000000000000000000000
+03ad:00000000020006000600040000000f801fc0206060003f003f00600060203fc01f0000000000000000000000
+03ae:0000000002000600060004000000278079c030c030c030c030c030c030c030c078c000c000c000c000c001e0
+03af:00000000020006000600040000001e00060006000600060006000600060006001f8000000000000000000000
+03b0:000000000200666066600400000079e030c030c030c030c030c030c030c038800f0000000000000000000000
+03b1:00000000000000000000000000001f9031d060e060e060c060c060c061e072603c3000000000000000000000
+03b2:000000000f00198030c030c030c030c031003e00330031c030e030e030603860378030003000300030007800
+03b3:000000000000000000000000000070e0b04030401880188019000d000e0006000e0013001300218021801f00
+03b4:0000000000001f8030001c000e0007000f8011c020e0606060606060704038801f0000000000000000000000
+03b5:00000000000000000000000000000f801fc0206060003f003f00600060203fc01f0000000000000000000000
+03b6:00000000000000007fe000c003000c00180030007000600060006000700030001e00078000c0006000c00380
+03b7:0000000000000000000000000000278079c030c030c030c030c030c030c030c078c000c000c000c000c001e0
+03b8:00000000000000000f8011c020e06060606060607fe0606060606060704038801f0000000000000000000000
+03b9:00000000000000000000000000001e00060006000600060006000600060006001f8000000000000000000000
+03ba:0000000000000000000000000000f1c0630066007c0078007c006e0067006380f1e000000000000000000000
+03bb:0000000000001c001c000e00060006000b000b000b0011801180118020c020c071e000000000000000000000
+03bc:000000000000000000000000000079e030c030c030c030c030c030c030c039c03e6030003000300030007800
+03bd:0000000000000000000000000000f070602030203040184018800c800d000600060000000000000000000000
+03be:00000000000000007fe018003000600038000e0003c0060018006000700038001e00078000c0006000c00380
+03bf:00000000000000000000000000000f8011c020e06060606060606060704038801f0000000000000000000000
+03c0:0000000000000000000000000000fff030c030c030c030c030c030c030c030e0787000000000000000000000
+03c1:00000000000000000000000000000f8011c020e0606060606060606070407880670060006000600060006000
+03c2:00000000000000000000000000000f8011c020e0600060006000600078003f000f80018000c0018007000000
+03c3:00000000000000000000000000000ff011c020606060606060606060704038801f0000000000000000000000
+03c4:00000000000000000000000000007fe00600060006000600060006000600030001e000000000000000000000
+03c5:000000000000000000000000000079e030c030c030c030c030c030c030c038800f0000000000000000000000
+03c6:0000000000000000000000000000098013c026e0666066606660666076403e801f0006000600060006000600
+03c7:00000000000000000000000000006020702018401c800c800700070007000700098009c010c0207020300000
+03c8:0000000000000000000000000000e670666066606660666066606660666076403f800f000600060006000f00
+03c9:00000000000000000000000000006060c030c630c630c630c630c63066207fc0198000000000000000000000
+03ca:00000000000030c030c0000000001e00060006000600060006000600060006001f8000000000000000000000
+03cb:00000000000030c030c00000000079e030c030c030c030c030c030c030c038800f0000000000000000000000
+03cc:00000000020006000600040000000f8011c020e06060606060606060704038801f0000000000000000000000
+03cd:000000000200060006000400000079e030c030c030c030c030c030c030c038800f0000000000000000000000
+03ce:00000000020006000600040000006060c030c630c630c630c630c63066207fc0198000000000000000000000
+03cf:000000000000f0e06180630066006c00780078007c006e006700638061c060e0f07000c001800b0006000200
+03d0:000003800c4010202040ff8020004f8051c060e06060606060606060704038801f0000000000000000000000
+03d1:000000001e0023004180618060c030c00ff000606060b060b060306038401c800f0000000000000000000000
+03d2:0000000000006030d050d8901880188018800d000d00060006000600060006000f0000000000000000000000
+03d3:0180030006006030d050d8901880188018800d000d00060006000600060006000f0000000000000000000000
+03d4:1980198000006030d050d8901880188018800d000d00060006000600060006000f0000000000000000000000
+03d5:000000000600060006000f8017c026e066606660666066606660666076403e801f0006000600060000000000
+03d6:0000000000000000000000703fc0e0604030c630c630c630c630c63066207fc0198000000000000000000000
+03d7:00000000000000000000000000006040b0e0b1c03380378026802c8078c070e06060004001801e0000000000
+03d8:0000000000000f0011c020c020606060606060606060204030401880060006003fc000000000000000000000
+03d9:00000000000000000000000000000f8011c020e06060606060606060704038801f0006000600060000000000
+03da:0000000000000f0011c020c020606000600060006000200030001800060006003fc000000000000000000000
+03db:00000000000000000000002000e00fc010002000600060006000600078003f000f80018000c0018007000000
+03dc:0000000000007fc0304030403000300030803f80308030003000300030003000780000000000000000000000
+03dd:0000000000000000000000401f80300030003000300030003f80300030003000300030003000300000000000
+03de:0000000000003c00180018001800300030003fc000c000c000c001800180018003c000000000000000000000
+03df:00000000000000002000500058001800186031e0364078c060c00180018001a000a000400000000000000000
+03e0:0000000000000f0011c020c02060006001e00660186001e00660004000400080070000000000000000000000
+03e1:0000000000000f0001c000c00060006001e00660186001e00660004000400080010000000000000000000000
+03e2:00000000000036c066606660c630c630c630c630c630c630c630c630c63066207fc001800600180000000000
+03e3:00000000000000000000000036c066606660c630c630c630c630c630c63066207fc001800600180000000000
+03e4:00000000000008e010602060606060606060606060606060706038e01f6000600060006000600060006000f0
+03e5:000000000000000000000000000008e0106020606060606060606060706038e01f60006000600060006000f0
+03e6:000000000000e00060006000600067806fc070e06060606060606060606060c070c0018003003e0000000000
+03e7:000000000000000000000000e0006000600067806fc070e060606060606060c070c0018003003e0000000000
+03e8:000000001f8031c060e020e001c0038007001c0038003000700070007000700070003020306018c00f800000
+03e9:0000000000000000000000001f8031c060e021c0038007001c0038003000700070003020306018c00f800000
+03ea:000018400c800d00070007000b0009801180118010c020c020c0406040604060fff000000000000000000000
+03eb:0000000000000000000018400c800d0007000b000980118010c020c040604060fff000000000000000000000
+03ec:00000000000001e00e0018003000270058807040606060606060606020e011c00f8000000000000000000000
+03ed:0000000000000000000001e00e00180030002700588070406060606020e011c00f8000000000000000000000
+03ee:000000000f000600060006007fe07fe0462046200600060006000600060006000600060006000f0000000000
+03ef:000000000000000000000f00060006007fe07fe0462046200600060006000600060006000f00000000000000
+03f0:00000000000000000000000000006040b0e0b1c03380338026802c8078a070e0606000000000000000000000
+03f1:00000000000000000000000000000f8011c020e06060606060606060704058802700300018000e0001c00000
+03f2:00000000000000000000000000001f8030c020406000600060006000700030c01f8000000000000000000000
+03f3:00000000000000c000c00000000003c000c000c000c000c000c000c000c000c000c020c030c038801f000e00
+03f4:0000000000000f8011c020e06060606060607fe06060606060606060704038801f0000000000000000000000
+03f5:00000000000000000000000000001f803f80600060007f007f00600060003f801f0000000000000000000000
+03f6:00000000000000000000000000003f003f8000c000c01fc01fc000c000c03f803e0000000000000000000000
+03f7:0000000000007800300030003f8030c0306030603060306030c0378030003000780000000000000000000000
+03f8:00000000000000000000000000007800300030003f8030c0306030603060306038c037803000300030007800
+03f9:0000000000000fc01060202020006000600060006000600060002000302018400f8000000000000000000000
+03fa:000000000000e070606070e079604e6044604060406040604060406040604060e0f000000000000000000000
+03fb:00000000000000000000000000000000c0e0c0c0e1c0f2c09cc088c080c080c080d08050803080008000c000
+03fc:00000000000000000000000000000f8011c020e0606060606060606070407880670060006000ff0060006000
+03fd:0000000000003f00608040400040006000600060006000600060004040c021801f0000000000000000000000
+03fe:0000000000000fc01060202020006000600063006300600060002000302018400f8000000000000000000000
+03ff:0000000000003f00608040400040006000600c600c6000600060004040c021801f0000000000000000000000
+0400:1c000f0003807fc0304030403000300030803f803080300030003000302030207fe000000000000000000000
+0401:1980198000007fc0304030403000300030803f803080300030003000302030207fe000000000000000000000
+0402:000000000000ffc08c400c000c000c000ce00f300c300c300c300c300c300db03ee000000000000000000000
+0403:0180030006007fc0304030403000300030003000300030003000300030003000780000000000000000000000
+0404:0000000000000fc0106020202000600061007f006100600060002000302018400f8000000000000000000000
+0405:0000000000001fe030606020602070003c001e00078001c000e04060406060c07f8000000000000000000000
+0406:0000000000001f800600060006000600060006000600060006000600060006001f8000000000000000000000
+0407:1980198000001f800600060006000600060006000600060006000600060006001f8000000000000000000000
+0408:0000000000001f80060006000600060006000600060006000600060006000600060006000600040038003000
+0409:000000000000ffc02300230023002300230023e02330233023302330a330a330c7e000000000000000000000
+040a:000000000000f780630063006300630063007fe0633063306330633063306330f7e000000000000000000000
+040b:000000000000ffc08c400c000c000c000ce00f300e300c300c300c300c300c301e7000000000000000000000
+040c:018003000600f0e06180630066006c00780078007c006e006700638061c060e0f07000000000000000000000
+040d:38001e000700f0f060606060606060e061606260646068607060606060606060f0f000000000000000000000
+040e:606030c00f00f070602030403040188018800d000d000600060004000c000800780070000000000000000000
+040f:000000000000f0f0606060606060606060606060606060606060606060606060fff00f000600000000000000
+0410:000000000000060006000b000b0009001180118010803fc020c0204040604060e0f000000000000000000000
+0411:000000000000ffc0604060406000600060007f8060c0606060606060606060c0ff8000000000000000000000
+0412:000000000000ff00608060c060c060c061807f8060c0606060606060606060c0ff8000000000000000000000
+0413:0000000000007fc0304030403000300030003000300030003000300030003000780000000000000000000000
+0414:0000000000007ff020c020c020c020c020c020c020c020c040c040c040c040c0fff0c030c030801000000000
+0415:0000000000007fc0304030403000300030803f803080300030003000302030207fe000000000000000000000
+0416:000000000000ef30c6106620664036801f000e0007000ec016c0266046608630cf7000000000000000000000
+0417:000000004f807fc060e04060006000e007c00fc000e000600060406060403f801f0000000000000000000000
+0418:000000000000f0f060606060606060e061606260646068607060606060606060f0f000000000000000000000
+0419:606030c00f00f0f060606060606060e061606260646068607060606060606060f0f000000000000000000000
+041a:000000000000f0e06180630066006c00780078007c006e006700638061c060e0f07000000000000000000000
+041b:0000000000003fe010c010c010c010c010c010c020c020c020c0a0c0e0c0e0c0c1e000000000000000000000
+041c:000000000000e07060e070e070e070e05960596059604d604e604e6044604460e4f000000000000000000000
+041d:000000000000f0f0606060606060606060607fe0606060606060606060606060f0f000000000000000000000
+041e:0000000000000f0011c020c020606060606060606060606060602040304018800f0000000000000000000000
+041f:000000000000fff0606060606060606060606060606060606060606060606060f0f000000000000000000000
+0420:0000000000007f8030c030603060306030c03780300030003000300030003000780000000000000000000000
+0421:0000000000000fc01060202020006000600060006000600060002000302018400f8000000000000000000000
+0422:0000000000007fe04620060006000600060006000600060006000600060006001f8000000000000000000000
+0423:000000000000f070602030403040188018800d000d000600060004000c000800780070000000000000000000
+0424:0000000000001f8006000f8017c026e0666066606660666076403e801f0006001f8000000000000000000000
+0425:000000000000f07060203040388018800d00060006000b00118011c020c04060e0f000000000000000000000
+0426:000000000000f1e060c060c060c060c060c060c060c060c060c060c060c060c0fff000300030001000000000
+0427:00000000000079e030c030c030c030c030c030c039c01ec000c000c000c000c001e000000000000000000000
+0428:000000000000f6f0666066606660666066606660666066606660666066606660fff000000000000000000000
+0429:000000000000f6f0666066606660666066606660666066606660666066606660fff000300030001000000000
+042a:000000000000fc00980098001800180018001f801fc018e018601860186018c01f8000000000000000000000
+042b:000000000000e0f0c060c060c060c060fc60fe60c760c360c360c360c360c660fcf000000000000000000000
+042c:000000000000780030003000300030003f003f8031c030c030c030c030c031807f0000000000000000000000
+042d:0000000000003f00608040400040006008600fe0086000600060004040c021801f0000000000000000000000
+042e:000000000000e180c2e0c460c430cc30cc30fc30cc30cc30cc30c420c620c340e18000000000000000000000
+042f:0000000000000ff0186030603060306010600fe003e007600e601c6038607060e0f000000000000000000000
+0430:00000000000000000000000000000f8018c010c003c01cc030c030c030c039c01ee000000000000000000000
+0431:0000000000000fc01f80200020004f8051c060e06060606060606060704038801f0000000000000000000000
+0432:0000000000000000000000000000ff00608060c061807f8060c06060606060c0ff8000000000000000000000
+0433:00000000000000000000000000007fc030403000300030003000300030003000780000000000000000000000
+0434:00000000000000000000000000003ff0118011801180118011802180218021807ff060606060402000000000
+0435:00000000000000000000000000000f0030c0606060607fe060006000300018600f8000000000000000000000
+0436:0000000000000000000000000000ef30c610662066403f801fc0266046608630cf7000000000000000000000
+0437:0000000000000000000000004f807fc06060006007c00fc00060406060403f801f0000000000000000000000
+0438:0000000000000000000000000000f0f0606060e0616062606460686070606060f0f000000000000000000000
+0439:00000000606030c00f0000000000f0f0606060e0616062606460686070606060f0f000000000000000000000
+043a:0000000000000000000000000000f1c0630066007c0078007c006e0067006380f1e000000000000000000000
+043b:00000000000000000000000000001fe008c008c008c010c010c010c050c070c061e000000000000000000000
+043c:0000000000000000000000000000e07060e070e0596059604d604e6046604460e4f000000000000000000000
+043d:0000000000000000000000000000f1e060c060c060c07fc060c060c060c060c0f1e000000000000000000000
+043e:00000000000000000000000000000f8011c020e06060606060606060704038801f0000000000000000000000
+043f:00000000000000000000000000007fe030c030c030c030c030c030c030c030c079e000000000000000000000
+0440:0000000000000000000000000000ef8071c060e06060606060606060604070807f006000600060006000f000
+0441:00000000000000000000000000001f8031c020c06000600060006000704030c01f8000000000000000000000
+0442:00000000000000000000000000007fe0462006000600060006000600060006001f8000000000000000000000
+0443:0000000000000000000000000000f0f0602030403040188018800d000d000600060004000c00080078007000
+0444:0000000000000f0006000600060036c07fe0ef70c630c630c630c6304f207fe036c006000600060006000f00
+0445:0000000000000000000000000000f8f0704038801d000e0007000b8011c020e0f1f000000000000000000000
+0446:000000000000000000000000000079e030c030c030c030c030c030c030c030c07ff000300030001000000000
+0447:000000000000000000000000000079e030c030c030c039c01ec000c000c000c001e000000000000000000000
+0448:0000000000000000000000000000f6f066606660666066606660666066606660fff000000000000000000000
+0449:0000000000000000000000000000f6f066606660666066606660666066606660fff000300030001000000000
+044a:0000000000000000000000000000fc00980098001f801fc018e01860186018c01f8000000000000000000000
+044b:0000000000000000000000000000e0f0c060c060fc60fe60c760c360c360c660fcf000000000000000000000
+044c:00000000000000000000000000007800300030003f003f8031c030c030c031807f0000000000000000000000
+044d:00000000000000000000000000003f006080404008600fe00860006040c021801f0000000000000000000000
+044e:0000000000000000000000000000f18062e0646064307c306c30642066206340f18000000000000000000000
+044f:00000000000000000000000000001fe030c060c020c01fc007c00ec01cc038c071e000000000000000000000
+0450:0000000000001c000f00038000000f0030c0606060607fe060006000300018600f8000000000000000000000
+0451:00000000000019801980000000000f0030c0606060607fe060006000300018600f8000000000000000000000
+0452:000000001000300070003000fe003000378039c030c030c030c030c030c030c078c000c030c038801f000e00
+0453:00000000030006000c00000000007fc030403000300030003000300030003000780000000000000000000000
+0454:00000000000000000000000000000fc01060202061007f0061006000302018400f8000000000000000000000
+0455:00000000000000000000000000001fc030c0304038001e00078001c020c030c03f8000000000000000000000
+0456:00000000000006000600000000001e00060006000600060006000600060006001f8000000000000000000000
+0457:00000000000019801980000000001e00060006000600060006000600060006001f8000000000000000000000
+0458:00000000000000c000c00000000003c000c000c000c000c000c000c000c000c000c020c030c038801f000e00
+0459:00000000000000000000000000003f8013001300130023e023302330a330e330c7e000000000000000000000
+045a:0000000000000000000000000000f7806300630063007fe06330633063306330f7e000000000000000000000
+045b:000000001000300070003000fe003000378039c030c030c030c030c030c030c079e000000000000000000000
+045c:00000000030006000c0000000000f1c0630066007c0078007c006e0067006380f1e000000000000000000000
+045d:000000001c000f00038000000000f0f0606060e0616062606460686070606060f0f000000000000000000000
+045e:00000000606030c00f0000000000f0f0602030403040188018800d000d000600060004000c00080078007000
+045f:000000000000000000000000000079e030c030c030c030c030c030c030c030c07fe00f000600000000000000
+0460:000000000000fef066206620662076207740334037403bc03b80198019801980198000000000000000000000
+0461:0000000000000000000000000000ff7066206620662037403b403b4019801980198000000000000000000000
+0462:000000000000fc0098001800ff80180018001f801fc018e018601860186018c01f8000000000000000000000
+0463:000000000000000000000000fc001800ff8018001f801fc018e01860186018c01f8000000000000000000000
+0464:000000000000e3c0446048204800580059007f0059005800580048004c204640e38000000000000000000000
+0465:0000000000000000000000000000e3c04460482059007f00590048004c204640e38000000000000000000000
+0466:000000000000060006000b000b0009001180118010803fc024c0244044604460e4f000000000000000000000
+0467:0000000000000000000000000000060006000b000900118010803fc024c04460e4f000000000000000000000
+0468:000000000000e60046004b004b0049005180518050807fc064c0644044604460e4f000000000000000000000
+0469:0000000000000000000000000000e60046004b004900518050807fc064c04460e4f000000000000000000000
+046a:000000000000fff060203040188018800d003fc04660c630c630c630c630c630ef7000000000000000000000
+046b:00000000000000000000000000007fe0304018800d003fc04660c630c630c630ef7000000000000000000000
+046c:000000000000fff0b02098408c8086808700ffe0b330b330b330b330b330b330f77000000000000000000000
+046d:0000000000000000000000000000fff0b02098408c808700ffe0b330b330b330f77000000000000000000000
+046e:19800f00060000000f801fc020e04060006000e007c00fc000e00060006000803f00600060003c001f000000
+046f:000019800f000600000000000f801fc020e0406000e007c00fc000e0006000803f00600060003c001f000000
+0470:000000000000ef70666066606660666076403f800f00060006000600060006000f0000000000000000000000
+0471:0000000000000000000000000000e670666066606660666066606660666076403f800f000600060006000f00
+0472:0000000000000f0011c020c02060606060607c6063e0606060602040304018800f0000000000000000000000
+0473:00000000000000000000000000000f0011c020c060607c6063e02040304018800f0000000000000000000000
+0474:000000000000f020607030d0309030801900190019000e000e000e0004000400040000000000000000000000
+0475:0000000000000000000000000000f020607030d03080190019000e000e000400040000000000000000000000
+0476:e38079e01c70f020607030d0309030801900190019000e000e000e0004000400040000000000000000000000
+0477:00000000e38079e01c7000000000f020607030d03080190019000e000e000400040000000000000000000000
+0478:0000000000003000380048004c00cf30ce10ce10cd20cd20cd2049c068c038c010800080018001000f000e00
+0479:00000000000000000000000000003000380048004c00cf30ce10cd20cd2049c068c038c0108001800f000e00
+047a:000000000e001f802ee040604030c030c030c030c030c030c0304020602037401f8007000000000000000000
+047b:0000000000000000000000000e001f802ee040604030c030c0304020602037401f8007000000000000000000
+047c:0c00338040e00e006160c130c630c030c030c030c030c030c630c630c63066207fc019800000000000000000
+047d:0000000000000c00338040e00e006160c130c630c030c030c630c63066207fc0198000000000000000000000
+047e:7fc044400000fef066206620662076207740334037403bc03b80198019801980198000000000000000000000
+047f:0000000000007fc0444000000000fef0662066207740334037403bc019801980198000000000000000000000
+0480:0000000000000fc01060202020006000600060006000600060002000306018e00fe0006000600060006000f0
+0481:00000000000000000000000000000f8010c02040200060006000200030c019c00fc000c000c000c000c001e0
+0482:00000000000000000000000000000000000000000180018003003b00070006e0ec001c001b80180030003000
+0483:00603fc060000000000000000000000000000000000000000000000000000000000000000000000000000000
+0484:03c0066006600000000000000000000000000000000000000000000000000000000000000000000000000000
+0485:0f000c0007000000000000000000000000000000000000000000000000000000000000000000000000000000
+0486:0f0003000e000000000000000000000000000000000000000000000000000000000000000000000000000000
+0487:3c006780c0e00000000000000000000000000000000000000000000000000000000000000000000000000000
+0488:04000a0000000000204050a000000000000000004020a0500000000000000000204050a00000000004000a00
+0489:08000e000000000040e0702000000000000000008070e010000000000000000040e07020000000000e000200
+048a:606030c00f00f0f060606060606060e061606260646068607060606060606060f0f00030006000c001800000
+048b:00000000606030c00f0000000000f0f0606060e0616062606460686070606060f0f00030006000c001800000
+048c:00000000000030003000fe00300030003f003f8031c030c030c030c030c031807f0000000000000000000000
+048d:00000000000000000000000030003000fe0030003f003f8031c030c030c031807f0000000000000000000000
+048e:0000000000007f8030c030603060366033c03f8030c030603000300030003000780000000000000000000000
+048f:0000000000000000000000000000ef8071c060e06060606060606060664073807f8060c0606060006000f000
+0490:0000004000407fc0300030003000300030003000300030003000300030003000780000000000000000000000
+0491:00000000000000000000004000407fc030003000300030003000300030003000780000000000000000000000
+0492:0000000000003fe018201820180018007f0018001800180018001800180018003c0000000000000000000000
+0493:00000000000000000000000000003fe0182018007f00180018001800180018003c0000000000000000000000
+0494:0000000000007fc030403040300030003000378038c038c030c030c030c030c078c000c008c00cc00f800700
+0495:00000000000000000000000000007fc0304030003000378038c038c030c030c078c000c008c00cc007800000
+0496:000000000000ef30c6106620664036801f000e0007800ec016c0266046608630cf7000300030003000000000
+0497:0000000000000000000000000000ef30c610662066403f801fc0266046608630cf7000300030000000000000
+0498:000000004f807fc060e04060006000e007c00fc000e000600060406060403f801f0004000700010006000000
+0499:0000000000000000000000004f807fc06060006007c00fc00060406060403f801f0004000700010006000000
+049a:000000000000f0e06180630066006c00780078007c006e006700638061c060e0f07000300030003000000000
+049b:0000000000000000000000000000f1c0630066007c0078007c006e0067006380f1f000300030000000000000
+049c:000000000000f07060c069806b006e007c0078007c006e006f006b8069c060e0f07000000000000000000000
+049d:0000000000000000000000000000f0e061806b006e0078006e006f006b8061c0f0f000000000000000000000
+049e:000000000000f07060c0fd80630066007c0078007c006e006700638061c060e0f07000000000000000000000
+049f:0000000000000000f0006000fc0061c0630066007c0078007c006e0067006380f1e000000000000000000000
+04a0:000000000000f870b0c0b180330036003c003c003e003700338031c030e03070783000000000000000000000
+04a1:0000000000000000000000000000f8e0b180b3003e003c003e003700338031c078f000000000000000000000
+04a2:000000000000f0f0606060606060606060607fe0606060606060606060606060f0f000300030003000000000
+04a3:0000000000000000000000000000f0f06060606060607fe06060606060606060f0f000300030000000000000
+04a4:000000000000f3f0619061906180618061807f80618061806180618061806180f3c000000000000000000000
+04a5:0000000000000000000000000000f3f06190618061807f806180618061806180f3c000000000000000000000
+04a6:000000000000ff8063006300630063006300636063b063306330633063306330f7b000300230033003e001c0
+04a7:0000000000000000000000000000ff80630063006300636063b0633063306330f7b000300230033001e00000
+04a8:0000000000000e001000218022c064606c606c606c606c606c602640314019800e6000000000000000000000
+04a9:00000000000000000000000000000e001000218022c064606c602640314019800e6000000000000000000000
+04aa:0000000000000fc01060202020006000600060006000600060002000302018400f8004000700010006000000
+04ab:00000000000000000000000000001f8031c020c06000600060006000704030c01f8004000700010006000000
+04ac:0000000000007fe04620060006000600060006000600060006000600060006001f8004000700010006000000
+04ad:00000000000000000000000000007fe0462006000600060006000600060006001f8004000700010006000000
+04ae:000000000000f07060203040188018800d0006000600060006000600060006000f0000000000000000000000
+04af:0000000000000000000000000000000078e030403040188018800d000d000600060006000600060006000f00
+04b0:000000000000f07060203040188018800d0006003fc0060006000600060006000f0000000000000000000000
+04b1:0000000000000000000000000000000078e030403040188018800d000d0006003fc006000600060006000f00
+04b2:000000000000f07060203040388018800d00060006000b00118011c020c04060e0f000300030003000000000
+04b3:0000000000000000000000000000f8f0704038801d000e0007000b8011c020e0f1f000300030003000000000
+04b4:000000000000ff709960186018601860186018601860186018601860186018603ff000300030003000000000
+04b5:0000000000000000000000000000ff70996018601860186018601860186018603ff000300030000000000000
+04b6:00000000000079e030c030c030c030c030c030c039c01ec000c000c000c000c001e000300030003000000000
+04b7:000000000000000000000000000079e030c030c030c030c039c01ec000c000c001e000300030003000000000
+04b8:00000000000079e030c030c030c034c034c034c03dc01ec004c004c004c000c001e000300030003000000000
+04b9:000000000000000000000000000079e030c030c034c034c03dc01ec004c004c001e000300030003000000000
+04ba:00000000000078003000300030003000378039c030c030c030c030c030c030c079e000000000000000000000
+04bb:0000000000000000000000000000780030003000378039c030c030c030c030c079e000000000000000000000
+04bc:0000000000000f0011c0a0c0a060ffe0600060006000600060002000304018800f0000000000000000000000
+04bd:0000000000000000000000000000070018c0b060b060ffe03000300018000c60078000000000000000000000
+04be:0000000000000f0011c0a0c0a060ffe0600060006000600060002000304018800f0006000600060000000000
+04bf:0000000000000000000000000000070018c0b060b060ffe03000300018000c60078003000300030000000000
+04c0:0000000000001f800600060006000600060006000600060006000600060006001f8000000000000000000000
+04c1:606030c00f00ef30c6106620664036801f000e0007000ec016c0266046608630cf7000000000000000000000
+04c2:00000000606030c00f0000000000ef30c610662066403f801fc0266046608630cf7000000000000000000000
+04c3:000000000000f0e06180630066006c00780078007c00670061c060e060706030f0300030027003e001800000
+04c4:0000000000000000000000000000f1c0630066006c007c00670061c060e06060f060006004e007c003000000
+04c5:0000000000003fe010c010c010c010c010c010c020c020c020c0a0c0e0c0e0c0c1e0006000c0018003000000
+04c6:00000000000000000000000000001fe008c008c008c010c010c050c070c070c061e0006000c0018003000000
+04c7:000000000000f0f0606060606060606060607fe0606060606060606060606060f060006004e007c003000000
+04c8:0000000000000000000000000000f1e060c060c060c07fc060c060c060c060c0f0c000c009c00f8006000000
+04c9:000000000000f0f0606060606060606060607fe0606060606060606060606060f0f0006000c0018003000000
+04ca:0000000000000000000000000000f1e060c060c060c07fc060c060c060c060c0f1e000c00180030006000000
+04cb:00000000000079e030c030c030c030c030c030c03dc01ec000c000c000c000c001e0006000c0018003000000
+04cc:000000000000000000000000000079e030c030c030c030c03dc01ec000c000c001e0006000c0018003000000
+04cd:000000000000e07060e070e070e070e05960596059604d604e604e6044604460e4f00030006000c001800000
+04ce:0000000000000000000000000000e07060e070e0596059604d604e6046604460e4f00030006000c001800000
+04cf:0000000000001f800600060006000600060006000600060006000600060006001f8000000000000000000000
+04d0:606030c00f00060006000b000b0009001180118010803fc020c0204040604060e0f000000000000000000000
+04d1:00000000606030c00f00000000000f8018c010c003c01cc030c030c030c039c01ee000000000000000000000
+04d2:198019800000060006000b000b0009001180118010803fc020c0204040604060e0f000000000000000000000
+04d3:00000000000019801980000000000f8018c010c003c01cc030c030c030c039c01ee000000000000000000000
+04d4:0000000000000fe00e20162016001600164027c026403e002600460046104610e7f000000000000000000000
+04d5:00000000000000000000000000001f80364026600e603fe066006600660067603fc000000000000000000000
+04d6:606030c00f007fc0304030403000300030803f803080300030003000302030207fe000000000000000000000
+04d7:00000000606030c00f00000000000f0030c0606060607fe060006000300018600f8000000000000000000000
+04d8:0000000000003f0060804040004000600060006000607fe04040404040c021801f0000000000000000000000
+04d9:00000000000000000000000000003f0060804040006000607fe0404040c021801f0000000000000000000000
+04da:1980198000003f0060804040004000600060006000607fe04040404040c021801f0000000000000000000000
+04db:00000000000019801980000000003f0060804040006000607fe0404040c021801f0000000000000000000000
+04dc:198019800000ef30c6106620664036801f000e0007800ec016c0266046608630cf7000000000000000000000
+04dd:0000000000001980198000000000ef30c610662066403f801fc0266046608630cf7000000000000000000000
+04de:198019804f807fc060e04060006000e007c00fc000e000600060406060403f801f0000000000000000000000
+04df:0000000019801980000000004f807fc06060006007c00fc00060406060403f801f0000000000000000000000
+04e0:0000000000007fe040c00180030006000c001f8001c000c000c040c060803f001e0000000000000000000000
+04e1:00000000000000000000000000003fe020c00180030006000c001f8001c000c000c020c030801f000e000000
+04e2:3fc000000000f0f060606060606060e061606260646068607060606060606060f0f000000000000000000000
+04e3:00000000000000003fc000000000f0f0606060e0616062606460686070606060f0f000000000000000000000
+04e4:198019800000f0f060606060606060e061606260646068607060606060606060f0f000000000000000000000
+04e5:0000000000001980198000000000f0f0606060e0616062606460686070606060f0f000000000000000000000
+04e6:1980198000000f0011c020c020606060606060606060606060602040304018800f0000000000000000000000
+04e7:00000000000019801980000000000f8011c020e06060606060606060704038801f0000000000000000000000
+04e8:0000000000000f8011c020e06060606060607fe06060606060606060704038801f0000000000000000000000
+04e9:00000000000000000000000000000f8011c020e060607fe060606060704038801f0000000000000000000000
+04ea:1980198000000f8011c020e06060606060607fe06060606060606060704038801f0000000000000000000000
+04eb:00000000000019801980000000000f8011c020e060607fe060606060704038801f0000000000000000000000
+04ec:1980198000003f00608040400040006008600fe0086000600060004040c021801f0000000000000000000000
+04ed:00000000000019801980000000003f006080404008600fe00860006040c021801f0000000000000000000000
+04ee:3fc000000000f070602030403040188018800d000d000600060004000c000800780070000000000000000000
+04ef:00000000000000003fc000000000f0f0602030403040188018800d000d000600060004000c00080078007000
+04f0:198019800000f070602030403040188018800d000d000600060004000c000800780070000000000000000000
+04f1:0000000000001980198000000000f0f0602030403040188018800d000d000600060004000c00080078007000
+04f2:06c00d801b00f070602030403040188018800d000d000600060004000c000800780070000000000000000000
+04f3:0000000006c00d801b0000000000f0f0602030403040188018800d000d000600060004000c00080078007000
+04f4:19801980000079e030c030c030c030c030c030c039c01ec000c000c000c000c001e000000000000000000000
+04f5:000000000000198019800000000079e030c030c030c039c01ec000c000c000c001e000000000000000000000
+04f6:0000000000007fc03040304030003000300030003000300030003000300030007c000c000c000c0000000000
+04f7:00000000000000000000000000007fc0304030003000300030003000300030007c000c000c00000000000000
+04f8:198019800000e0f0c060c060c060c060fc60fe60c760c360c360c360c360c660fcf000000000000000000000
+04f9:0000000000001980198000000000e0f0c060c060fc60fe60c760c360c360c660fcf000000000000000000000
+04fa:0000000000003fe018201820180018007f0018001800180018001800180018003e0002002200320032001c00
+04fb:00000000000000000000000000003fe0182018007f00180018001800180018003e0002002200320032001c00
+04fc:000000000000f07060203040388018800d00060006000b00118011c020c04060e060026003c0018000000000
+04fd:0000000000000000000000000000f8f0704038801d000e0007000b8011c020c0f0e00060026003c001800000
+04fe:000000000000f07060203040388018800d007fe006000b00118011c020c04060e0f000000000000000000000
+04ff:0000000000000000000000000000f8f0704038801d007fe007000b8011c020e0f1f000000000000000000000
+05d0:0000000000000000000000000000e1e06060306018c03cc067806300c180c0c0f0e000000000000000000000
+1e00:000000000000060006000b000b0009001180118010803fc020c0204040604060e0f000000600090009000600
+1e01:00000000000000000000000000000f8018c010c003c01cc030c030c030c039c01ee000000600090009000600
+1e02:0c000c000000ff00608060c060c060c061807f8060c0606060606060606060c0ff8000000000000000000000
+1e03:0600060020006000e0006000600067806fc070e06060606060606060706078c04f8000000000000000000000
+1e04:000000000000ff00608060c060c060c061807f8060c0606060606060606060c0ff8000000000060006000000
+1e05:0000000020006000e0006000600067806fc070e06060606060606060706078c04f8000000000060006000000
+1e06:000000000000ff00608060c060c060c061807f8060c0606060606060606060c0ff80000000003fc03fc00000
+1e07:0000000020006000e0006000600067806fc070e06060606060606060706078c04f80000000003fc03fc00000
+1e08:03800f001c000fc01060202020006000600060006000600060002000302018400f8002000300018009800700
+1e09:0000000003800f001c00000000001f8031c020c06000600060006000704030c01f8002000300018009800700
+1e0a:060006000000ff0061c060c06060606060606060606060606060606060406180fe0000000000000000000000
+1e0b:06000600006000e00060006000600f6031e020e0606060606060606070e039601e7000000000000000000000
+1e0c:000000000000ff0061c060c06060606060606060606060606060606060406180fe0000000000060006000000
+1e0d:00000000006000e00060006000600f6031e020e0606060606060606070e039601e7000000000060006000000
+1e0e:000000000000ff0061c060c06060606060606060606060606060606060406180fe00000000003fc03fc00000
+1e0f:00000000006000e00060006000600f6031e020e0606060606060606070e039601e70000000003fc03fc00000
+1e10:000000000000ff0061c060c06060606060606060606060606060606060406180fe0002000300018009800700
+1e11:00000000006000e00060006000600f6031e020e0606060606060606070e039601e7002000300018009800700
+1e12:000000000000ff0061c060c06060606060606060606060606060606060406180fe00000004000e001b003180
+1e13:00000000006000e00060006000600f6031e020e0606060606060606070e039601e70000004000e001b003180
+1e14:0e0007003fc000007fc0304030403000300030803f80308030003000302030207fe000000000000000000000
+1e15:1c000f00038000001f801f8000000f0030c0606060607fe060006000300018600f8000000000000000000000
+1e16:07000e003fc000007fc0304030403000300030803f80308030003000302030207fe000000000000000000000
+1e17:03800f001c0000001f801f8000000f0030c0606060607fe060006000300018600f8000000000000000000000
+1e18:0000000000007fc0304030403000300030803f803080300030003000302030207fe0000004000e001b003180
+1e19:00000000000000000000000000000f0030c0606060607fe060006000300018600f80000004000e001b003180
+1e1a:0000000000007fc0304030403000300030803f803080300030003000302030207fe000000e401fc013800000
+1e1b:00000000000000000000000000000f0030c0606060607fe060006000300018600f8000000e401fc013800000
+1e1c:198019800f007fc0304030403000300030803f803080300030003000302030207fe002000300018009800700
+1e1d:00000000198019800f00000000000f0030c0606060607fe060006000300018600f8002000300018009800700
+1e1e:0600060000007fc0304030403000300030803f80308030003000300030003000780000000000000000000000
+1e1f:030003000000038004c004c00c000c000c000c001f800c000c000c000c000c001e0000000000000000000000
+1e20:1f801f8000000fc0106020202000600060006000600061f060602060306018600f8000000000000000000000
+1e21:0000000000001f801f80000000001f2031e060c060c060c031803f0060007fc03fe02060402040207fc03f80
+1e22:060006000000f0f0606060606060606060607fe0606060606060606060606060f0f000000000000000000000
+1e23:0300030010003000700030003000378039c030c030c030c030c030c030c030c079e000000000000000000000
+1e24:000000000000f0f0606060606060606060607fe0606060606060606060606060f0f000000600060000000000
+1e25:0000000010003000700030003000378039c030c030c030c030c030c030c030c079e000000600060000000000
+1e26:198019800000f0f0606060606060606060607fe0606060606060606060606060f0f000000000000000000000
+1e27:0cc00cc010003000700030003000378039c030c030c030c030c030c030c030c079e000000000000000000000
+1e28:000000000000f0f0606060606060606060607fe0606060606060606060606060f0f0100018000c004c003800
+1e29:0000000010003000700030003000378039c030c030c030c030c030c030c030c079e0100018000c004c003800
+1e2a:000000000000f0f0606060606060606060607fe0606060606060606060606060f0f00000198019800f000000
+1e2b:0000000010003000700030003000378039c030c030c030c030c030c030c030c079e00000198019800f000000
+1e2c:0000000000001f800600060006000600060006000600060006000600060006001f8000000e401fc013800000
+1e2d:00000000000006000600000000001e00060006000600060006000600060006001f8000000e401fc013800000
+1e2e:030066606c6000001f80060006000600060006000600060006000600060006001f8000000000000000000000
+1e2f:03800f001c0000001980198000001e00060006000600060006000600060006001f8000000000000000000000
+1e30:03800f001c00f0e06180630066006c00780078007c006e006700638061c060e0f07000000000000000000000
+1e31:01c007806e00e00060006000600061c0630066007c0078007c006e0067006380f1e000000000000000000000
+1e32:000000000000f0e06180630066006c00780078007c006e006700638061c060e0f07000000600060000000000
+1e33:000000006000e00060006000600061c0630066007c0078007c006e0067006380f1e000000600060000000000
+1e34:000000000000f0e06180630066006c00780078007c006e006700638061c060e0f070000000003fc03fc00000
+1e35:000000006000e00060006000600061c0630066007c0078007c006e0067006380f1e0000000003fc03fc00000
+1e36:00000000000078003000300030003000300030003000300030003000302030207fe000000600060000000000
+1e37:000000001e0006000600060006000600060006000600060006000600060006001f8000000600060000000000
+1e38:3fc03fc0000078003000300030003000300030003000300030003000302030207fe000000600060000000000
+1e39:3fc03fc000001e000600060006000600060006000600060006000600060006001f8000000600060000000000
+1e3a:00000000000078003000300030003000300030003000300030003000302030207fe0000000003fc03fc00000
+1e3b:000000001e0006000600060006000600060006000600060006000600060006001f80000000003fc03fc00000
+1e3c:00000000000078003000300030003000300030003000300030003000302030207fe0000004000e001b003180
+1e3d:000000001e0006000600060006000600060006000600060006000600060006001f80000004000e001b003180
+1e3e:03800f001c00e07060e070e070e070e05960596059604d604e604e6044604460e4f000000000000000000000
+1e3f:0000000003800f001c0000000000ddc06ee06660666066606660666066606660ef7000000000000000000000
+1e40:060006000000e07060e070e070e070e05960596059604d604e604e6044604460e4f000000000000000000000
+1e41:0000000000000600060000000000ddc06ee06660666066606660666066606660ef7000000000000000000000
+1e42:000000000000e07060e070e070e070e05960596059604d604e604e6044604460e4f000000600060000000000
+1e43:0000000000000000000000000000ddc06ee06660666066606660666066606660ef7000000600060000000000
+1e44:060006000000c07060207020782058204c2046204720432041a040e040e04060e03000000000000000000000
+1e45:0000000000000600060000000000278079c030c030c030c030c030c030c030c079e000000000000000000000
+1e46:000000000000c07060207020782058204c2046204720432041a040e040e04060e03000000600060000000000
+1e47:0000000000000000000000000000278079c030c030c030c030c030c030c030c079e000000600060000000000
+1e48:000000000000c07060207020782058204c2046204720432041a040e040e04060e030000000003fc03fc00000
+1e49:0000000000000000000000000000278079c030c030c030c030c030c030c030c079e0000000003fc03fc00000
+1e4a:000000000000c07060207020782058204c2046204720432041a040e040e04060e030000004000e001b003180
+1e4b:0000000000000000000000000000278079c030c030c030c030c030c030c030c079e0000004000e001b003180
+1e4c:07001e003c6063c00f0011c020c02060606060606060606060602040304018800f0000000000000000000000
+1e4d:03800f001c0000003c6063c000000f8011c020e06060606060606060704038801f0000000000000000000000
+1e4e:1980198000003c6063c00f0011c020c0206060606060606060602040304018800f0000000000000000000000
+1e4f:1980198000001c6036c0638000000f8011c020e06060606060606060704038801f0000000000000000000000
+1e50:0e0007003fc000000f0011c020c02060606060606060606060602040304018800f0000000000000000000000
+1e51:1c000f00038000003fc03fc000000f8011c020e06060606060606060704038801f0000000000000000000000
+1e52:07000e003fc000000f0011c020c02060606060606060606060602040304018800f0000000000000000000000
+1e53:03800f001c0000003fc03fc000000f8011c020e06060606060606060704038801f0000000000000000000000
+1e54:03800f001c007f8030c030603060306030c03780300030003000300030003000780000000000000000000000
+1e55:0000000003800f001c0000000000ef8071c060e06060606060606060604070807f006000600060006000f000
+1e56:0600060000007f8030c030603060306030c03780300030003000300030003000780000000000000000000000
+1e57:0000000000000600060000000000ef8071c060e06060606060606060604070807f006000600060006000f000
+1e58:0c000c000000ff00618060c060c060c060807f007c006e006700638061c060e0f07000000000000000000000
+1e59:0000000000000600060000000000738034c038c0300030003000300030003000780000000000000000000000
+1e5a:000000000000ff00618060c060c060c060807f007c006e006700638061c060e0f07000000600060000000000
+1e5b:0000000000000000000000000000738034c038c0300030003000300030003000780000001800180000000000
+1e5c:3fc03fc00000ff00618060c060c060c060807f007c006e006700638061c060e0f07000000600060000000000
+1e5d:0000000000003fc03fc000000000738034c038c0300030003000300030003000780000001800180000000000
+1e5e:000000000000ff00618060c060c060c060807f007c006e006700638061c060e0f070000000003fc03fc00000
+1e5f:0000000000000000000000000000738034c038c03000300030003000300030007800000000003fc03fc00000
+1e60:0600060000001fe030606020602070003c001e00078001c000e04060406060c07f8000000000000000000000
+1e61:00000000000006000600000000001fc030c0304038001e00078001c020c030c03f8000000000000000000000
+1e62:0000000000001fe030606020602070003c001e00078001c000e04060406060c07f8000000600060000000000
+1e63:00000000000000000000000000001fc030c0304038001e00078001c020c030c03f8000000600060000000000
+1e64:0c700de003801fe030606020602070003c001e00078001c000e04060406060c07f8000000000000000000000
+1e65:06000600000003800f001c0000001fc030c0304038001e00078001c020c030c03f8000000000000000000000
+1e66:060036c0198006001fe030606020602070003c000e0003c000e04060406060c07f8000000000000000000000
+1e67:06000600000030c01980060000001fc030c0304038001e00078001c020c030c03f8000000000000000000000
+1e68:0600060000001fe030606020602070003c001e00078001c000e04060406060c07f8000000600060000000000
+1e69:00000000000006000600000000001fc030c0304038001e00078001c020c030c03f8000000600060000000000
+1e6a:0600060000007fe04620060006000600060006000600060006000600060006001f8000000000000000000000
+1e6b:00000c000c000000040004000c007fc00c000c000c000c000c000c000c200e40078000000000000000000000
+1e6c:0000000000007fe04620060006000600060006000600060006000600060006001f8000000600060000000000
+1e6d:0000000000000000040004000c007fc00c000c000c000c000c000c000c200e40078000000600060000000000
+1e6e:0000000000007fe04620060006000600060006000600060006000600060006001f80000000003fc03fc00000
+1e6f:0000000000000000040004000c007fc00c000c000c000c000c000c000c200e400780000000003fc03fc00000
+1e70:0000000000007fe04620060006000600060006000600060006000600060006001f80000004000e001b003180
+1e71:0000000000000000040004000c007fc00c000c000c000c000c000c000c200e400780000004000e001b003180
+1e72:000000000000f070602060206020602060206020602060206020602070403fc01f8000001980198000000000
+1e73:000000000000000000000000000079e030c030c030c030c030c030c030c039c01e6000001980198000000000
+1e74:000000000000f070602060206020602060206020602060206020602070403fc01f8000000e401fc013800000
+1e75:000000000000000000000000000079e030c030c030c030c030c030c030c039c01e6000000e401fc013800000
+1e76:000000000000f070602060206020602060206020602060206020602070403fc01f80000004000e001b003180
+1e77:000000000000000000000000000079e030c030c030c030c030c030c030c039c01e60000004000e001b003180
+1e78:07001e003c6063c00000f0706020602060206020602060206020602070403fc01f8000000000000000000000
+1e79:03800f001c0000003c6063c0000079e030c030c030c030c030c030c030c039c01e6000000000000000000000
+1e7a:1980198000003fc0f07060206020602060206020602060206020602070403fc01f8000000000000000000000
+1e7b:00001980198000003fc03fc0000079e030c030c030c030c030c030c030c039c01e6000000000000000000000
+1e7c:0e401fc01380e0e060403080308030801900190019000c000e000e0004000400040000000000000000000000
+1e7d:000000000e401fc0138000000000f070602030403040188018800d000d000600060000000000000000000000
+1e7e:000000000000e0e060403080308030801900190019000c000e000e0004000400040000000600060000000000
+1e7f:0000000000000000000000000000f070602030403040188018800d000d000600060000000600060000000000
+1e80:1c000f000380fef066206620662076207740334037403bc03b80198019801980198000000000000000000000
+1e81:000000001c000f00038000000000ff7066206620662037403b403b4019801980198000000000000000000000
+1e82:03800f001c00fef066206620662076207740334037403bc03b80198019801980198000000000000000000000
+1e83:0000000003800f001c0000000000ff7066206620662037403b403b4019801980198000000000000000000000
+1e84:198019800000fef066206620662076207740334037403bc03b80198019801980198000000000000000000000
+1e85:0000000000001980198000000000ff7066206620662037403b403b4019801980198000000000000000000000
+1e86:060006000000fef066206620662076207740334037403bc03b80198019801980198000000000000000000000
+1e87:0000000000000600060000000000ff7066206620662037403b403b4019801980198000000000000000000000
+1e88:000000000000fef066206620662076207740334037403bc03b80198019801980198000000000060006000000
+1e89:0000000000000000000000000000ff7066206620662037403b403b4019801980198000000000060006000000
+1e8a:060006000000f07060203040388018800d00060006000b00118011c020c04060e0f000000000000000000000
+1e8b:0000000000000600060000000000f8f0704038801d000e0007000b8011c020e0f1f000000000000000000000
+1e8c:198019800000f07060203040388018800d00060006000b00118011c020c04060e0f000000000000000000000
+1e8d:0000000000001980198000000000f8f0704038801d000e0007000b8011c020e0f1f000000000000000000000
+1e8e:060006000000f07060203040188018800d0006000600060006000600060006000f0000000000000000000000
+1e8f:0000000000000600060000000000f0f0602030403040188018800d000d000600060004000c00080078007000
+1e90:020007000d8018c000003fe020c000c001800180030006000c000c00180018203fe000000000000000000000
+1e91:00000000020007000d8018c000007fe060e041c0038007000e001c00382070607fe000000000000000000000
+1e92:0000000000003fe020c000c00180018003000300060006000c000c00180018203fe000000600060000000000
+1e93:00000000000000000000000000007fe060e041c0038007000e001c00382070607fe000000600060000000000
+1e94:0000000000003fe020c000c00180018003000300060006000c000c00180018203fe0000000003fc03fc00000
+1e95:00000000000000000000000000007fe060e041c0038007000e001c00382070607fe0000000003fc03fc00000
+1e96:0000000010003000700030003000378039c030c030c030c030c030c030c030c079e0000000003fc03fc00000
+1e97:000018c018c00000040004000c007fc00c000c000c000c000c000c000c200e40078000000000000000000000
+1e98:0000060009000900060000000000ff7066206620662037403b403b4019801980198000000000000000000000
+1e99:0000060009000900060000000000f0f0602030403040188018800d000d000600060004000c00080078007000
+1e9a:00000200010001000200000000000f8018c010c003c01cc030c030c030c039c01ee000000000000000000000
+1e9b:060006000000038004c004c00c000c000c003c000c000c000c000c000c000c001e0000000000000000000000
+1e9c:00000000038004c004c00c000c000d800f003e000c001c003c006c000c000c001e0000000000000000000000
+1e9d:00000000038004c004c00c007f807f800c003c000c000c000c000c000c000c001e0000000000000000000000
+1e9e:000000000f80386030e061c0638067006e00638061c060e06060606068606cc0ef8000000000000000000000
+1e9f:0000000000001f8030001c000e0007000f8011c020e0606060606060704038801f0000000000000000000000
+1ea0:000000000000060006000b000b0009001180118010803fc020c0204040604060e0f000000600060000000000
+1ea1:00000000000000000000000000000f8018c010c003c01cc030c030c030c039c01ee000000600060000000000
+1ea2:0e0013000300060006000b000b0009001180118010803fc020c0204040604060e0f000000000000000000000
+1ea3:000000000e0013000300060000000f8018c010c003c01cc030c030c030c039c01ee000000000000000000000
+1ea4:307079e0cd80060006000b000b0009001180118010803fc020c0204040604060e0f000000000000000000000
+1ea5:00000000307079e0cd80000000000f8018c010c003c01cc030c030c030c039c01ee000000000000000000000
+1ea6:31c078f0cc30060006000b000b0009001180118010803fc020c0204040604060e0f000000000000000000000
+1ea7:0000000031c078f0cc30000000000f8018c010c003c01cc030c030c030c039c01ee000000000000000000000
+1ea8:30e07930cc30066006000b000b0009001180118010803fc020c0204040604060e0f000000000000000000000
+1ea9:0000000030e07930cc30006000000f8018c010c003c01cc030c030c030c039c01ee000000000000000000000
+1eaa:3c6063c006001980000006000b000b000900118010803fc020c0204040604060e0f000000000000000000000
+1eab:3c6063c0000006000f00198000000f8018c010c003c01cc030c030c030c039c01ee000000000000000000000
+1eac:06000f001980060006000b000b0009001180118010803fc020c0204040604060e0f000000600060000000000
+1ead:04000e001b00318060c0000000000f8018c010c003c01cc030c030c030c039c01ee000000600060000000000
+1eae:01c007802e401f8006000b000b0009001180118010803fc020c0204040604060e0f000000000000000000000
+1eaf:01c007800e00000030c00f0000000f8018c010c003c01cc030c030c030c039c01ee000000000000000000000
+1eb0:38001e0027401f8006000b000b0009001180118010803fc020c0204040604060e0f000000000000000000000
+1eb1:38001e000700000030c00f0000000f8018c010c003c01cc030c030c030c039c01ee000000000000000000000
+1eb2:0700098023401f8006000b000b0009001180118010803fc020c0204040604060e0f000000000000000000000
+1eb3:0e0013000300060020401f8000000f8018c010c003c01cc030c030c030c039c01ee000000000000000000000
+1eb4:3c6063c020401f8006000b000b0009001180118010803fc020c0204040604060e0f000000000000000000000
+1eb5:1c6036c06380000020401f8000000f8018c010c003c01cc030c030c030c039c01ee000000000000000000000
+1eb6:20401f800000060006000b000b0009001180118010803fc020c0204040604060e0f000000600060000000000
+1eb7:00000000000020401f80000000000f8018c010c003c01cc030c030c030c039c01ee000000600060000000000
+1eb8:0000000000007fc0304030403000300030803f803080300030003000302030207fe000000600060000000000
+1eb9:00000000000000000000000000000f0030c0606060607fe060006000300018600f8000000600060000000000
+1eba:0e00130003007fc0304030403000300030803f803080300030003000302030207fe000000000000000000000
+1ebb:00000e00130003000600000000000f0030c0606060607fe060006000300018600f8000000000000000000000
+1ebc:1c6036c063807fc0304030403000300030803f803080300030003000302030207fe000000000000000000000
+1ebd:000000001c6036c06380000000000f0030c0606060607fe060006000300018600f8000000000000000000000
+1ebe:307079e0cd807fc0304030403000300030803f803080300030003000302030207fe000000000000000000000
+1ebf:00000000307079e0cd80000000000f0030c0606060607fe060006000300018600f8000000000000000000000
+1ec0:31c078f0cc307fc0304030403000300030803f803080300030003000302030207fe000000000000000000000
+1ec1:0000000031c078f0cc30000000000f0030c0606060607fe060006000300018600f8000000000000000000000
+1ec2:30e07930cc3000607fc0304030403000300030803f80308030003000302030207fe000000000000000000000
+1ec3:000030e07930cc300060000000000f0030c0606060607fe060006000300018600f8000000000000000000000
+1ec4:3c6063c00600198000007fc030403040300030803f80308030003000302030207fe000000000000000000000
+1ec5:3c6063c0000006000f00198000000f0030c0606060607fe060006000300018600f8000000000000000000000
+1ec6:06000f0019807fc0304030403000300030803f803080300030003000302030207fe000000600060000000000
+1ec7:000004000e001b00318060c000000f0030c0606060607fe060006000300018600f8000000600060000000000
+1ec8:0e00130006001f800600060006000600060006000600060006000600060006001f8000000000000000000000
+1ec9:00000e00130003000600000000001e00060006000600060006000600060006001f8000000000000000000000
+1eca:0000000000001f800600060006000600060006000600060006000600060006001f8000000600060000000000
+1ecb:00000000000006000600000000001e00060006000600060006000600060006001f8000000600060000000000
+1ecc:0000000000000f0011c020c020606060606060606060606060602040304018800f0000000600060000000000
+1ecd:00000000000000000000000000000f8011c020e06060606060606060704038801f0000000600060000000000
+1ece:0e00130003000f0011c020c020606060606060606060606060602040304018800f0000000000000000000000
+1ecf:0000000000000000006000f000300fa011c020e06060606060606060704038801f0000000000000000000000
+1ed0:307079e0cd800f0011c020c020606060606060606060606060602040304018800f0000000000000000000000
+1ed1:00000000307079e0cd80000000000f8011c020e06060606060606060704038801f0000000000000000000000
+1ed2:31c078f0cc300f0011c020c020606060606060606060606060602040304018800f0000000000000000000000
+1ed3:0000000031c078f0cc30000000000f8011c020e06060606060606060704038801f0000000000000000000000
+1ed4:30e079b0cc3000600f0011c020c02060606060606060606060602040304018800f0000000000000000000000
+1ed5:0000000030e079b0cc30006000000f0011c020e06060606060606060704038801f0000000000000000000000
+1ed6:3c6063c00600198000000f0011c020c0206060606060606060602040304018800f0000000000000000000000
+1ed7:3c6063c0000006000f00198000000f8011c020e06060606060606060704038801f0000000000000000000000
+1ed8:06000f0019800f0011c020c020606060606060606060606060602040304018800f0000000600060000000000
+1ed9:04000e001b00318060c0000000000f8011c020e06060606060606060704038801f0000000600060000000000
+1eda:0e603cf070300fa011c020c020606060606060606060606060602040304018800f0000000000000000000000
+1edb:0000000000000e003c6070f000300fa011c020e06060606060606060704038801f0000000000000000000000
+1edc:e06078f01c300fa011c020c020606060606060606060606060602040304018800f0000000000000000000000
+1edd:0000000070003c000e6000f000300fa011c020e06060606060606060704038801f0000000000000000000000
+1ede:1c6036f006300fa011c020c020606060606060606060606060602040304018800f0000000000000000000000
+1edf:000000001c00360006600cf000300fa011c020e06060606060606060704038801f0000000000000000000000
+1ee0:7260fef09c300fa011c020c020606060606060606060606060602040304018800f0000000000000000000000
+1ee1:0000000039007f004e6000f000300fa011c020e06060606060606060704038801f0000000000000000000000
+1ee2:006000f000300fa011c020c020606060606060606060606060602040304018800f0000000600060000000000
+1ee3:0000000000000000006000f000300fa011c020e06060606060606060704038801f0000000600060000000000
+1ee4:000000000000f070602060206020602060206020602060206020602070403fc01f8000000600060000000000
+1ee5:000000000000000000000000000079e030c030c030c030c030c030c030c039c01e6000000600060000000000
+1ee6:0e0013000300f670602060206020602060206020602060206020602070403fc01f8000000000000000000000
+1ee7:000000000e00130003000600000079e030c030c030c030c030c030c030c039c01e6000000000000000000000
+1ee8:0e603cd07010f070602060206020602060206020602060206020602070403fc01f8000000000000000000000
+1ee9:0000000007001e00386000d0001079e030c030c030c030c030c030c030c039c01e6000000000000000000000
+1eea:70603cd00e10f070602060206020602060206020602060206020602070403fc01f8000000000000000000000
+1eeb:0000000070003c000e6000d0001079e030c030c030c030c030c030c030c039c01e6000000000000000000000
+1eec:1c00266006d00c10f07060206020602060206020602060206020602070403fc01f8000000000000000000000
+1eed:0e00130003000600006000d0001079e030c030c030c030c030c030c030c039c01e6000000000000000000000
+1eee:7100db608e700010f07060206020602060206020602060206020602070403fc01f8000000000000000000000
+1eef:1c6036c063800000006000d0001079e030c030c030c030c030c030c030c039c01e6000000000000000000000
+1ef0:006000d00010f070602060206020602060206020602060206020602070403fc01f8000000600060000000000
+1ef1:0000000000000000006000d0001079e030c030c030c030c030c030c030c039c01e6000000600060000000000
+1ef2:38001e000700f07060203040188018800d0006000600060006000600060006000f0000000000000000000000
+1ef3:000000001c000f00038000000000f0f0602030403040188018800d000d000600060004000c00080078007000
+1ef4:000000000000f07060203040188018800d0006000600060006000600060006000f0000000600060000000000
+1ef5:0000000000000000000000000000f0f0602030403040188018800d000d000600060004000c0008007b007300
+1ef6:0e0013000300f67060203040188018800d0006000600060006000600060006000f0000000000000000000000
+1ef7:00000e0013000300060000000000f0f0602030403040188018800d000d000600060004000c00080078007000
+1ef8:1c6036c06380f07060203040188018800d0006000600060006000600060006000f0000000000000000000000
+1ef9:000000001c6036c0638000000000f0f0602030403040188018800d000d000600060004000c00080078007000
+1efa:000000000000fe006c006c006c006c006c006c006c006c006c006c006c206c20ffe000000000000000000000
+1efb:00000000f3c030c030c07fe07fe030c030c030c030c030c030c030c030c030c0fdf000000000000000000000
+1efc:0000000007000c001800300030006000618063c060e060606060606070403f801f0000000000000000000000
+1efd:000000000000000007000c00180030003000618063c060e06060606070403f801f0000000000000000000000
+1efe:000000000000f0f0602030403040188018800d000d000600060004006c009800980070000000000000000000
+1eff:0000000000000000000000000000f0f0602030403040188018800d000d000600060004006c00980098007000
+1f00:000000000f0003000e00000000001f9031d060e060e060c060c060c061e072603c3000000000000000000000
+1f01:00000000078006000380000000001f9031d060e060e060c060c060c061e072603c3000000000000000000000
+1f02:00000000798018c07040000000001f9031d060e060e060c060c060c061e072603c3000000000000000000000
+1f03:00000000798060c03840000000001f9031d060e060e060c060c060c061e072603c3000000000000000000000
+1f04:0000000078c019807100000000001f9031d060e060e060c060c060c061e072603c3000000000000000000000
+1f05:0000000078c061803900000000001f9031d060e060e060c060c060c061e072603c3000000000000000000000
+1f06:1c40238000000f0003000e0000001f9031d060e060e060c060c060c061e072603c3000000000000000000000
+1f07:1c40238000000f000c00070000001f9031d060e060e060c060c060c061e072603c3000000000000000000000
+1f08:0000f0003000e60006000b000b0009001180118010803fc020c0204040604060e0f000000000000000000000
+1f09:0000f000c000760006000b000b0009001180118010803fc020c0204040604060e0f000000000000000000000
+1f0a:3000180008000300f3003580e580048008c008c008401fe01060102020302030707000000000000000000000
+1f0b:3000180008000300f300c5807580048008c008c008401fe01060102020302030707000000000000000000000
+1f0c:1800300020000300f3003580e580048008c008c008401fe01060102020302030707000000000000000000000
+1f0d:1800300020000300f300c5807580048008c008c008401fe01060102020302030707000000000000000000000
+1f0e:000071008e000300f3003580e580048008c008c008401fe01060102020302030707000000000000000000000
+1f0f:000071008e000300f300c5807580048008c008c008401fe01060102020302030707000000000000000000000
+1f10:000000000f0003000e00000000000f801fc0206060003f003f00600060203fc01f0000000000000000000000
+1f11:000000000f000c000700000000000f801fc0206060003f003f00600060203fc01f0000000000000000000000
+1f12:00000000798018c07040000000000f801fc0206060003f003f00600060203fc01f0000000000000000000000
+1f13:00000000798060c03840000000000f801fc0206060003f003f00600060203fc01f0000000000000000000000
+1f14:0000000078c019807100000000000f801fc0206060003f003f00600060203fc01f0000000000000000000000
+1f15:0000000078c061803900000000000f801fc0206060003f003f00600060203fc01f0000000000000000000000
+1f18:f0003000e0007fc0304030403000300030803f803080300030003000302030207fe000000000000000000000
+1f19:f000c00070007fc0304030403000300030803f803080300030003000302030207fe000000000000000000000
+1f1a:f6003300e1007fc0304030403000300030803f803080300030003000302030207fe000000000000000000000
+1f1b:f600c30071007fc0304030403000300030803f803080300030003000302030207fe000000000000000000000
+1f1c:f1803300e2007fc0304030403000300030803f803080300030003000302030207fe000000000000000000000
+1f1d:f180c30072007fc0304030403000300030803f803080300030003000302030207fe000000000000000000000
+1f20:000000000f0003000e0000000000278079c030c030c030c030c030c030c030c078c000c000c000c000c001e0
+1f21:000000000f000c00070000000000278079c030c030c030c030c030c030c030c078c000c000c000c000c001e0
+1f22:00000000798018c0704000000000278079c030c030c030c030c030c030c030c078c000c000c000c000c001e0
+1f23:00000000798060c0384000000000278079c030c030c030c030c030c030c030c078c000c000c000c000c001e0
+1f24:0000000078c01980710000000000278079c030c030c030c030c030c030c030c078c000c000c000c000c001e0
+1f25:0000000078c06180390000000000278079c030c030c030c030c030c030c030c078c000c000c000c000c001e0
+1f26:1c40238000000f0003000e000000278079c030c030c030c030c030c030c030c078c000c000c000c000c001e0
+1f27:1c40238000000f000c0007000000278079c030c030c030c030c030c030c030c078c000c000c000c000c001e0
+1f28:f0003000e000f0f0606060606060606060607fe0606060606060606060606060f0f000000000000000000000
+1f29:f000c0007000f0f0606060606060606060607fe0606060606060606060606060f0f000000000000000000000
+1f2a:f6003300e100f0f0606060606060606060607fe0606060606060606060606060f0f000000000000000000000
+1f2b:f600c3007100f0f0606060606060606060607fe0606060606060606060606060f0f000000000000000000000
+1f2c:f1803300e200f0f0606060606060606060607fe0606060606060606060606060f0f000000000000000000000
+1f2d:f180c3007200f0f0606060606060606060607fe0606060606060606060606060f0f000000000000000000000
+1f2e:e71068e0c000f0f0606060606060606060607fe0606060606060606060606060f0f000000000000000000000
+1f2f:f710c8e07000f0f0606060606060606060607fe0606060606060606060606060f0f000000000000000000000
+1f30:000000000f0003000e00000000001e00060006000600060006000600060006001f8000000000000000000000
+1f31:000000000f000c000700000000001e00060006000600060006000600060006001f8000000000000000000000
+1f32:00000000798018c07040000000001e00060006000600060006000600060006001f8000000000000000000000
+1f33:00000000798060c03840000000001e00060006000600060006000600060006001f8000000000000000000000
+1f34:0000000078c019807100000000001e00060006000600060006000600060006001f8000000000000000000000
+1f35:0000000078c061803900000000001e00060006000600060006000600060006001f8000000000000000000000
+1f36:1c40238000000f0003000e0000001e00060006000600060006000600060006001f8000000000000000000000
+1f37:1c40238000000f000c00070000001e00060006000600060006000600060006001f8000000000000000000000
+1f38:f0003000e0000f800600060006000600060006000600060006000600060006001f8000000000000000000000
+1f39:f000c00070000f800600060006000600060006000600060006000600060006001f8000000000000000000000
+1f3a:f6003300e1001f800600060006000600060006000600060006000600060006001f8000000000000000000000
+1f3b:f600c30071000f800600060006000600060006000600060006000600060006001f8000000000000000000000
+1f3c:f1003300e2001f800600060006000600060006000600060006000600060006001f8000000000000000000000
+1f3d:f180c30072001f800600060006000600060006000600060006000600060006001f8000000000000000000000
+1f3e:e71068e0c0001f800600060006000600060006000600060006000600060006001f8000000000000000000000
+1f3f:f710c8e070001f800600060006000600060006000600060006000600060006001f8000000000000000000000
+1f40:000000000f0003000e00000000000f8011c020e06060606060606060704038801f0000000000000000000000
+1f41:000000000f000c000700000000000f8011c020e06060606060606060704038801f0000000000000000000000
+1f42:00000000798018c07040000000000f8011c020e06060606060606060704038801f0000000000000000000000
+1f43:00000000798060c03840000000000f8011c020e06060606060606060704038801f0000000000000000000000
+1f44:0000000078c019807100000000000f8011c020e06060606060606060704038801f0000000000000000000000
+1f45:0000000078c061803900000000000f8011c020e06060606060606060704038801f0000000000000000000000
+1f48:f0003000e0000f0011c020c020606060606060606060606060602040304018800f0000000000000000000000
+1f49:f000c00070000f0011c020c020606060606060606060606060602040304018800f0000000000000000000000
+1f4a:f6003300e1000f0011c020c020606060606060606060606060602040304018800f0000000000000000000000
+1f4b:f600c30071000f0011c020c020606060606060606060606060602040304018800f0000000000000000000000
+1f4c:f1003300e2000f0011c020c020606060606060606060606060602040304018800f0000000000000000000000
+1f4d:f180c30072000f0011c020c020606060606060606060606060602040304018800f0000000000000000000000
+1f50:000000000f0003000e000000000079e030c030c030c030c030c030c030c038800f0000000000000000000000
+1f51:000000000f000c0007000000000079e030c030c030c030c030c030c030c038800f0000000000000000000000
+1f52:00000000798018c070400000000079e030c030c030c030c030c030c030c038800f0000000000000000000000
+1f53:00000000798060c038400000000079e030c030c030c030c030c030c030c038800f0000000000000000000000
+1f54:0000000078c0198071000000000079e030c030c030c030c030c030c030c038800f0000000000000000000000
+1f55:0000000078c0618039000000000079e030c030c030c030c030c030c030c038800f0000000000000000000000
+1f56:1c40238000000f0003000e00000079e030c030c030c030c030c030c030c038800f0000000000000000000000
+1f57:1c40238000000f000c000700000079e030c030c030c030c030c030c030c038800f0000000000000000000000
+1f59:f000c0007000f07060203040188018800d0006000600060006000600060006000f0000000000000000000000
+1f5b:f600c3007100f07060203040188018800d0006000600060006000600060006000f0000000000000000000000
+1f5d:f180c3007200f07060203040188018800d0006000600060006000600060006000f0000000000000000000000
+1f5f:f710c8e07000f07060203040188018800d0006000600060006000600060006000f0000000000000000000000
+1f60:000000000f0003000e00000000006060c030c630c630c630c630c63066207fc0198000000000000000000000
+1f61:000000000f000c000700000000006060c030c630c630c630c630c63066207fc0198000000000000000000000
+1f62:00000000798018c07040000000006060c030c630c630c630c630c63066207fc0198000000000000000000000
+1f63:00000000798060c03840000000006060c030c630c630c630c630c63066207fc0198000000000000000000000
+1f64:0000000078c019807100000000006060c030c630c630c630c630c63066207fc0198000000000000000000000
+1f65:0000000078c061803900000000006060c030c630c630c630c630c63066207fc0198000000000000000000000
+1f66:1c40238000000f0003000e0000006060c030c630c630c630c630c63066207fc0198000000000000000000000
+1f67:1c40238000000f000c00070000006060c030c630c630c630c630c63066207fc0198000000000000000000000
+1f68:f0003000e0000f0011c020c0206060606060606060602040304018800900492079e000000000000000000000
+1f69:f000c00070000f0011c020c0206060606060606060602040304018800900492079e000000000000000000000
+1f6a:f6003300e1000f0011c020c0206060606060606060602040304018800900492079e000000000000000000000
+1f6b:f600c30071000f0011c020c0206060606060606060602040304018800900492079e000000000000000000000
+1f6c:f1803300e2000f0011c020c0206060606060606060602040304018800900492079e000000000000000000000
+1f6d:f180c30072000f0011c020c0206060606060606060602040304018800900492079e000000000000000000000
+1f6e:e71068e0c0000f0011c020c0206060606060606060602040304018800900492079e000000000000000000000
+1f6f:f710c8e070000f0011c020c0206060606060606060602040304018800900492079e000000000000000000000
+1f70:000000000c0006000200000000001f9031d060e060e060c060c060c061e072603c3000000000000000000000
+1f71:00000000030006000400000000001f9031d060e060e060c060c060c061e072603c3000000000000000000000
+1f72:0000000000000c000600020000000f801fc0206060003f003f00600060203fc01f0000000000000000000000
+1f73:00000000000003000600040000000f801fc0206060003f003f00600060203fc01f0000000000000000000000
+1f74:000000000c000600020000000000278079c030c030c030c030c030c030c030c078c000c000c000c000c001e0
+1f75:0000000003000600040000000000278079c030c030c030c030c030c030c030c078c000c000c000c000c001e0
+1f76:000000000c0006000200000000001e00060006000600060006000600060006001f8000000000000000000000
+1f77:00000000030006000400000000001e00060006000600060006000600060006001f8000000000000000000000
+1f78:000000000c0006000200000000000f8011c020e06060606060606060704038801f0000000000000000000000
+1f79:00000000030006000400000000000f8011c020e06060606060606060704038801f0000000000000000000000
+1f7a:000000000c00060002000000000079e030c030c030c030c030c030c030c038800f0000000000000000000000
+1f7b:000000000300060004000000000079e030c030c030c030c030c030c030c038800f0000000000000000000000
+1f7c:000000000c0006000200000000006060c030c630c630c630c630c63066207fc0198000000000000000000000
+1f7d:0000000007000c000800000000006060c030c630c630c630c630c63066207fc0198000000000000000000000
+1f80:000000000f0003000e00000000001f9031d060e060e060c060c060c061e072603c3000000600060007000000
+1f81:000000000f000c000700000000001f9031d060e060e060c060c060c061e072603c3000000600060007000000
+1f82:00000000798018c07040000000001f9031d060e060e060c060c060c061e072603c3000000600060007000000
+1f83:00000000798060c03840000000001f9031d060e060e060c060c060c061e072603c3000000600060007000000
+1f84:0000000078c019807100000000001f9031d060e060e060c060c060c061e072603c3000000600060007000000
+1f85:0000000078c061803900000000001f9031d060e060e060c060c060c061e072603c3000000600060007000000
+1f86:1c40238000000f0003000e0000001f9031d060e060e060c060c060c061e072603c3000000600060007000000
+1f87:1c40238000000f000c00070000001f9031d060e060e060c060c060c061e072603c3000000600060007000000
+1f88:00000000f0003600e6000b000b0009001180118010803fc020c0204040604060e0f000000040004000600000
+1f89:00000000f000c60076000b000b0009001180118010803fc020c0204040604060e0f000000040004000600000
+1f8a:3000180008000300f3003580e580048008c008c008401fe01060102020302030707000000040004000600000
+1f8b:3000180008000300f300c5807580048008c008c008401fe01060102020302030707000000040004000600000
+1f8c:0c00180010000300f3003580e580048008c008c008401fe01060102020302030707000000040004000600000
+1f8d:0c00180010000300f300c5807580048008c008c008401fe01060102020302030707000000040004000600000
+1f8e:000071008e000300f3003580e580048008c008c008401fe01060102020302030707000000040004000600000
+1f8f:000071008e000300f300c5807580048008c008c008401fe01060102020302030707000000060006000700000
+1f90:000000000f0003000e0000000000278079c030c030c030c030c030c030c030c078c000c030c030c038c001e0
+1f91:000000000f000c00070000000000278079c030c030c030c030c030c030c030c078c000c030c030c038c001e0
+1f92:0000000000007b00198070800000278079c030c030c030c030c030c030c030c078c000c030c030c038c001e0
+1f93:0000000000007b00618038800000278079c030c030c030c030c030c030c030c078c000c030c030c038c001e0
+1f94:00000000000078c0198071000000278079c030c030c030c030c030c030c030c078c000c030c030c038c001e0
+1f95:00000000000078c0618039000000278079c030c030c030c030c030c030c030c078c000c030c030c038c001e0
+1f96:1c40238000000f0003000e000000278079c030c030c030c030c030c030c030c078c000c030c030c038c001e0
+1f97:1c40238000000f000c0007000000278079c030c030c030c030c030c030c030c078c000c030c030c038c001e0
+1f98:f0003000e000f0f0606060606060606060607fe0606060606060606060606060f0f000000060006000700000
+1f99:f000c0007000f0f0606060606060606060607fe0606060606060606060606060f0f000000060006000700000
+1f9a:f6003300e100f0f0606060606060606060607fe0606060606060606060606060f0f000000060006000700000
+1f9b:f600c3007100f0f0606060606060606060607fe0606060606060606060606060f0f000000060006000700000
+1f9c:f1803300e200f0f0606060606060606060607fe0606060606060606060606060f0f000000060006000700000
+1f9d:f180c3007200f0f0606060606060606060607fe0606060606060606060606060f0f000000060006000700000
+1f9e:e71068e0c000f0f0606060606060606060607fe0606060606060606060606060f0f000000060006000700000
+1f9f:f710c8e07000f0f0606060606060606060607fe0606060606060606060606060f0f000000060006000700000
+1fa0:000000000f0003000e00000000006060c030c630c630c630c630c63066207fc0198000000600060007000000
+1fa1:000000000f000c000700000000006060c030c630c630c630c630c63066207fc0198000000600060007000000
+1fa2:000000003d800cc03840000000006060c030c630c630c630c630c63066207fc0198000000600060007000000
+1fa3:000000003d8030c01c40000000006060c030c630c630c630c630c63066207fc0198000000600060007000000
+1fa4:000000003c600cc03880000000006060c030c630c630c630c630c63066207fc0198000000600060007000000
+1fa5:000000003c6030c01c80000000006060c030c630c630c630c630c63066207fc0198000000600060007000000
+1fa6:1c40238000000f0003000e0000006060c030c630c630c630c630c63066207fc0198000000600060007000000
+1fa7:1c40238000000f000c00070000006060c030c630c630c630c630c63066207fc0198000000600060007000000
+1fa8:0710f8e03000ef0011c020c0206060606060606060602040304018800900492079e000000000000000000000
+1fa9:f000c00070000f0011c020c0206060606060606060602040304018800900492079e000000060006000700000
+1faa:f6003300e1000f0011c020c0206060606060606060602040304018800900492079e000000060006000700000
+1fab:f600c30071000f0011c020c0206060606060606060602040304018800900492079e000000060006000700000
+1fac:f1803300e2000f0011c020c0206060606060606060602040304018800900492079e000000060006000700000
+1fad:f180c30072000f0011c020c0206060606060606060602040304018800900492079e000000060006000700000
+1fae:e71068e0c0000f0011c020c0206060606060606060602040304018800900492079e000000060006000700000
+1faf:f710c8e070000f0011c020c0206060606060606060602040304018800900492079e000000060006000700000
+1fb0:00000000000010800f00000000001f9031d060e060e060c060c060c061e072603c3000000000000000000000
+1fb1:0000000000001f801f80000000001f9031d060e060e060c060c060c061e072603c3000000000000000000000
+1fb2:000000000c0006000200000000001f9031d060e060e060c060c060c061e072603c3000000600060007000000
+1fb3:00000000000000000000000000001f9031d060e060e060c060c060c061e072603c3000000600060007000000
+1fb4:00000000030006000400000000001f9031d060e060e060c060c060c061e072603c3000000600060007000000
+1fb6:0000000000001c402380000000001f9031d060e060e060c060c060c061e072603c3000000000000000000000
+1fb7:0000000000001c402380000000001f9031d060e060e060c060c060c061e072603c3000000600060007000000
+1fb8:10800f000000060006000b000b0009001180118010803fc020c0204040604060e0f000000000000000000000
+1fb9:1f801f800000060006000b000b0009001180118010803fc020c0204040604060e0f000000000000000000000
+1fba:00000000c000660026000b000b0009001180118010803fc020c0204040604060e0f000000000000000000000
+1fbb:000000003000660046000b000b0009001180118010803fc020c0204040604060e0f000000000000000000000
+1fbc:000000000000060006000b000b0009001180118010803fc020c0204040604060e0f000000060006000700000
+1fbd:000000000e000100010006000000000000000000000000000000000000000000000000000000000000000000
+1fbe:0000000000000000000000000000000000000000000000000000000000000000000000000600060007000000
+1fbf:000000000f0003000e0000000000000000000000000000000000000000000000000000000000000000000000
+1fc0:1c803f8027000000000000000000000000000000000000000000000000000000000000000000000000000000
+1fc1:1c803f8027000000198019800000000000000000000000000000000000000000000000000000000000000000
+1fc2:000000000c000600020000000000278079c030c030c030c030c030c030c030c078c000c030c030c038c001e0
+1fc3:0000000000000000000000000000278079c030c030c030c030c030c030c030c078c000c030c030c038c001e0
+1fc4:0000000003000600040000000000278079c030c030c030c030c030c030c030c078c000c030c030c038c001e0
+1fc6:0000000000001c40238000000000278079c030c030c030c030c030c030c030c078c000c000c000c000c001e0
+1fc7:0000000000001c40238000000000278079c030c030c030c030c030c030c030c078c000c030c030c038c001e0
+1fc8:c000600020007fc0304030403000300030803f803080300030003000302030207fe000000000000000000000
+1fc9:6000c00080007fc0304030403000300030803f803080300030003000302030207fe000000000000000000000
+1fca:c00060002000f0f0606060606060606060607fe0606060606060606060606060f0f000000000000000000000
+1fcb:6000c0008000f0f0606060606060606060607fe0606060606060606060606060f0f000000000000000000000
+1fcc:000000000000f0f0606060606060606060607fe0606060606060606060606060f0f000000060006000700000
+1fcd:3d800cc038400000000000000000000000000000000000000000000000000000000000000000000000000000
+1fce:3cc00d8039000000000000000000000000000000000000000000000000000000000000000000000000000000
+1fcf:1c40238000000f0003000e000000000000000000000000000000000000000000000000000000000000000000
+1fd0:00000000000010800f00000000001e00060006000600060006000600060006001f8000000000000000000000
+1fd1:0000000000001f801f80000000001e00060006000600060006000600060006001f8000000000000000000000
+1fd2:0000000018000c0064c060c000001e00060006000600060006000600060006001f8000000000000000000000
+1fd3:000000000300060064c060c000001e00060006000600060006000600060006001f8000000000000000000000
+1fd6:00000000000000001c40238000001e00060006000600060006000600060006001f8000000000000000000000
+1fd7:00001c40238000003180318000001e00060006000600060006000600060006001f8000000000000000000000
+1fd8:10800f0000001f800600060006000600060006000600060006000600060006001f8000000000000000000000
+1fd9:1f801f8000001f800600060006000600060006000600060006000600060006001f8000000000000000000000
+1fda:000000000000df806600260006000600060006000600060006000600060006001f8000000000000000000000
+1fdb:00000000000067e0c1808180018001800180018001800180018001800180018007e000000000000000000000
+1fdd:3d8030c01c400000000000000000000000000000000000000000000000000000000000000000000000000000
+1fde:3cc031801d000000000000000000000000000000000000000000000000000000000000000000000000000000
+1fdf:1c40238000000f000c0007000000000000000000000000000000000000000000000000000000000000000000
+1fe0:00000000000010800f000000000079e030c030c030c030c030c030c030c038800f0000000000000000000000
+1fe1:0000000000001f801f800000000079e030c030c030c030c030c030c030c038800f0000000000000000000000
+1fe2:0000000018000c0064c060c0000079e030c030c030c030c030c030c030c038800f0000000000000000000000
+1fe3:000000000300060064c060c0000079e030c030c030c030c030c030c030c038800f0000000000000000000000
+1fe4:000000000f0003000e00000000000f8011c020e0606060606060606070407880670060006000600060006000
+1fe5:000000000f000c000700000000000f8011c020e0606060606060606070407880670060006000600060006000
+1fe6:0000000000001c4023800000000079e030c030c030c030c030c030c030c038800f0000000000000000000000
+1fe7:00001c402380000031803180000079e030c030c030c030c030c030c030c038800f0000000000000000000000
+1fe8:10800f000000f07060203040188018800d0006000600060006000600060006000f0000000000000000000000
+1fe9:1f801f800000f07060203040188018800d0006000600060006000600060006000f0000000000000000000000
+1fea:c00060002000f07060203040188018800d0006000600060006000600060006000f0000000000000000000000
+1feb:6000c0008000f07060203040188018800d0006000600060006000600060006000f0000000000000000000000
+1fec:f000c00070007f8030c030603060306030c03780300030003000300030003000780000000000000000000000
+1fed:000018000c0064c060c000000000000000000000000000000000000000000000000000000000000000000000
+1fee:00000300060064c060c000000000000000000000000000000000000000000000000000000000000000000000
+1fef:00000c0006000200000000000000000000000000000000000000000000000000000000000000000000000000
+1ff2:000000000c0006000200000000006060c030c630c630c630c630c63066207fc0198000000600060007000000
+1ff3:00000000000000000000000000006060c030c630c630c630c630c63066207fc0198000000600060007000000
+1ff4:00000000030006000400000000006060c030c630c630c630c630c63066207fc0198000000600060007000000
+1ff6:0000000000001c402380000000006060c030c630c630c630c630c63066207fc0198000000600060007000000
+1ff7:0000000000001c402380000000006060c030c630c630c630c630c63066207fc0198000000600060007000000
+1ff8:0000c00060002f0011c020c020606060606060606060606060602040304018800f0000000000000000000000
+1ff9:000000006000cf0091c020c020606060606060606060606060602040304018800f0000000000000000000000
+1ffa:0000c00060002f0011c020c0206060606060606060602040304018800900492079e000000000000000000000
+1ffb:000000006000cf0091c020c0206060606060606060602040304018800900492079e000000000000000000000
+1ffc:0000000000000f0011c020c0206060606060606060602040304018800900492079e000000060006000700000
+1ffd:0000030006000400000000000000000000000000000000000000000000000000000000000000000000000000
+1ffe:0000078006000380000000000000000000000000000000000000000000000000000000000000000000000000
+2000:0000000000000000000000000000000000000000000000000000000000000000000000000000000000000000
+2001:0000000000000000000000000000000000000000000000000000000000000000000000000000000000000000
+2002:0000000000000000000000000000000000000000000000000000000000000000000000000000000000000000
+2003:0000000000000000000000000000000000000000000000000000000000000000000000000000000000000000
+2004:0000000000000000000000000000000000000000000000000000000000000000000000000000000000000000
+2005:0000000000000000000000000000000000000000000000000000000000000000000000000000000000000000
+2006:0000000000000000000000000000000000000000000000000000000000000000000000000000000000000000
+2007:0000000000000000000000000000000000000000000000000000000000000000000000000000000000000000
+2008:0000000000000000000000000000000000000000000000000000000000000000000000000000000000000000
+2009:0000000000000000000000000000000000000000000000000000000000000000000000000000000000000000
+200a:0000000000000000000000000000000000000000000000000000000000000000000000000000000000000000
+200b:0000000000000000000000000000000000000000000000000000000000000000000000000000000000000000
+200c:0000000000000000000000000000000000000000000000000000000000000000000000000000000000000000
+200d:0000000000000000000000000000000000000000000000000000000000000000000000000000000000000000
+200e:0000000000000000000000000000000000000000000000000000000000000000000000000000000000000000
+200f:0000000000000000000000000000000000000000000000000000000000000000000000000000000000000000
2010:00000000000000000000000000000000000000003fc03fc00000000000000000000000000000000000000000
2011:00000000000000000000000000000000000000003fc03fc00000000000000000000000000000000000000000
2012:00000000000000000000000000000000000000003fc03fc00000000000000000000000000000000000000000
@@ -377,29 +1758,1184 @@
201b:000006000f000f000c000c000600030001000000000000000000000000000000000000000000000000000000
201c:00000cc019801980198019801980198000000000000000000000000000000000000000000000000000000000
201d:0000198019801980198019801980330000000000000000000000000000000000000000000000000000000000
-201e:0000000000000000000000000000000000000000000000001980198019801980198033000000000000000000
-201f:00001980198019801980198019800cc000000000000000000000000000000000000000000000000000000000
+201e:0000000000000000000000000000000000000000000000003b803b803b801980198033000000000000000000
+201f:00001dc01dc01dc01980198019800cc000000000000000000000000000000000000000000000000000000000
2020:0000000000000600060006003fc03fc006000600060006000600060006000600060000000000000000000000
2021:0000000000000600060006003fc03fc006000600060006003fc03fc006000600060000000000000000000000
2022:0000000000000000000000000000000007000f800f800f800700000000000000000000000000000000000000
+2023:000000000000000000000000000008000c000e000f000e000c00080000000000000000000000000000000000
+2024:000000000000000000000000000000000000000000000000000007000f800f80070000000000000000000000
+2025:000000000000000000000000000000000000000000000000000071c0fbe0fbe071c000000000000000000000
2026:0000000000000000000000000000000000000000000000000000222077707770222000000000000000000000
+2027:000000000000000000000000000000000000000007000f800f80070000000000000000000000000000000000
+2028:00000000000000004200620052004a004600420000000200020002000200020003e000000000000000000000
+2029:0000000000003fe07e607e607e607e607e603e60026002600260026002600260026000000000000000000000
+202a:0000000000000000000000000000000000000000000000000000000000000000000000000000000000000000
+202b:0000000000000000000000000000000000000000000000000000000000000000000000000000000000000000
+202c:0000000000000000000000000000000000000000000000000000000000000000000000000000000000000000
+202d:0000000000000000000000000000000000000000000000000000000000000000000000000000000000000000
+202e:0000000000000000000000000000000000000000000000000000000000000000000000000000000000000000
+202f:0000000000000000000000000000000000000000000000000000000000000000000000000000000000000000
2030:000000000000318049804b003300060006000c000c001800180036c03920692066c000000000000000000000
-2032:0000060006000600060006000600000000000000000000000000000000000000000000000000000000000000
-2033:0000198019801980198019801980000000000000000000000000000000000000000000000000000000000000
-2039:000000000000000000000000000000000180030006000c0018000c0006000300018000000000000000000000
-203a:0000000000000000000000000000000018000c00060003000180030006000c00180000000000000000000000
+2031:000000000000318049804b003300060006000cc00d20192018c036c03920692066c000000000000000000000
+2032:000003000300060006000c000c00000000000000000000000000000000000000000000000000000000000000
+2033:00000cc00cc01980198033003300000000000000000000000000000000000000000000000000000000000000
+2034:00003330333066606660ccc0ccc0000000000000000000000000000000000000000000000000000000000000
+2035:00000c000c000600060003000300000000000000000000000000000000000000000000000000000000000000
+2036:000033003300198019800cc00cc0000000000000000000000000000000000000000000000000000000000000
+2037:0000ccc0ccc06660666033303330000000000000000000000000000000000000000000000000000000000000
+2038:0000000000000000000000000000000000000000000000000000000000000000000006000f00198030c06060
+2039:000000000000000000000000000000000180030006000c000600030001800000000000000000000000000000
+203a:0000000000000000000000000000000018000c000600030006000c0018000000000000000000000000000000
+203b:0000000000000000000086104620204010800900c630c6300900108020404620861000000000000000000000
203c:0000000019801980198019801980198019801980198019801980000000001980198000000000000000000000
+203d:000000000f001f803dc02cc00cc00cc00d800f000e000c000c00000000000c000c0000000000000000000000
203e:00003fc03fc00000000000000000000000000000000000000000000000000000000000000000000000000000
+203f:0000000000000000000000000000000000000000000000000000000000000000801060603fc01f8000000000
+2040:00001f803fc06060801000000000000000000000000000000000000000000000000000000000000000000000
+2041:000000000180018003000300060006000e000e001b001b003180318060c060c0000000000000000000000000
+2042:0000000000000000090006001f80060009000000492030c0fff030c049200000000000000000000000000000
+2043:00000000000000000000000000000000000000001f801f801f80000000000000000000000000000000000000
+2044:00000060006000c000c00180018003000300060006000c000c00180018003000300000000000000000000000
+2045:000000000fc00fc00e000e000e000e000fc00fc00e000e000e000e000e000fc00fc000000000000000000000
+2046:000000003f003f0007000700070007003f003f00070007000700070007003f003f0000000000000000000000
+2047:0000000039c07fe0ef708630063006300c600840108031803180000000003180318000000000000000000000
+2048:000000003c607e60e76083600360036006600c60186030603060000000003060306000000000000000000000
+2049:0000000063c067e06e70683060306030606060c0618063006300000000006300630000000000000000000000
+204a:000000000000000000000000000000003f803f80008000800080010001000100010000000000000000000000
+204b:000000000000ff8027c027e027e027e027c02780240024002400240024002400240000000000000000000000
+204c:00000000000000000000000000003fe07c80fc80fc80fc807c803fe000000000000000000000000000000000
+204d:0000000000000000000000000000ff8027c027e027e027e027c0ff8000000000000000000000000000000000
+204e:000000000000000000000000000000000000000000001080090006001f800600090010800000000000000000
+204f:000000000000000000000000000000000c001e001e000c00000000000c001e001e00180018000c0006000200
+2050:00000000000000000e003f8071c060c00000000000000000000060c071c03f800e0000000000000000000000
+2051:0000000000000000090006001f80060009000000090006001f80060009000000000000000000000000000000
+2052:00000000386038c038c0018001800300030006000c000c001800180031c031c061c000000000000000000000
+2053:00000000000000000000000000000000000000001c203e6036c067c043800000000000000000000000000000
+2054:00000000000000000000000000000000000000000000000000000000000000001f803fc06060801000000000
+2055:00000000000000000000000004004440248015000e00ffe00e00150024804440040000000000000000000000
+2056:00000000000000000000000000e000e000e038003800380000e000e000e00000000000000000000000000000
+2057:0000249024904920492092409240000000000000000000000000000000000000000000000000000000000000
+2058:000000000000000000000e000e000e000000e0e0e0e0e0e000000e000e000e00000000000000000000000000
+2059:00000000000000000000e0e0e0e0e0e000000e000e000e000000e0e0e0e0e0e0000000000000000000000000
+205a:0000000000000e000e000e00000000000000000000000000000000000e000e000e0000000000000000000000
+205b:00000e000e000e0000000000000000000000e0e0e0e0e0e0000000000000000000000e000e000e0000000000
+205c:00000000000000000000e4e0e4e0e4e004000400ffe004000400e4e0e4e0e4e0000000000000000000000000
+205d:000000000e000e000e000000000000000e000e000e000000000000000e000e000e0000000000000000000000
+205e:000000000e000e000e00000000000e000e000e00000000000e000e000e00000000000e000e000e0000000000
+205f:0000000000000000000000000000000000000000000000000000000000000000000000000000000000000000
+2060:0000000000000000000000000000000000000000000000000000000000000000000000000000000000000000
+2061:0000000000000000000000000000000000000000000000000000000000000000000000000000000000000000
+2062:0000000000000000000000000000000000000000000000000000000000000000000000000000000000000000
+2063:0000000000000000000000000000000000000000000000000000000000000000000000000000000000000000
+2064:0000000000000000000000000000000000000000000000000000000000000000000000000000000000000000
+2066:0000000000000000000000000000000000000000000000000000000000000000000000000000000000000000
+2067:0000000000000000000000000000000000000000000000000000000000000000000000000000000000000000
+2068:0000000000000000000000000000000000000000000000000000000000000000000000000000000000000000
+2069:0000000000000000000000000000000000000000000000000000000000000000000000000000000000000000
+206a:0000000000000000000000000000000000000000000000000000000000000000000000000000000000000000
+206b:0000000000000000000000000000000000000000000000000000000000000000000000000000000000000000
+206c:0000000000000000000000000000000000000000000000000000000000000000000000000000000000000000
+206d:0000000000000000000000000000000000000000000000000000000000000000000000000000000000000000
+206e:0000000000000000000000000000000000000000000000000000000000000000000000000000000000000000
+206f:0000000000000000000000000000000000000000000000000000000000000000000000000000000000000000
+2070:0000000007000f80118010c030c030c030c0308018801f000e00000000000000000000000000000000000000
+2071:000000000600060000001e001e0006000600060006001f801f80000000000000000000000000000000000000
+2074:0000000000800180038005800980118021803fe07fe001800180000000000000000000000000000000000000
+2075:000000000fc00fc0100020003f8031c000e00060206030c01f80000000000000000000000000000000000000
+2076:0000000007000c001800300067806fc070e0606070403f801f00000000000000000000000000000000000000
+2077:000000001fe03fe0604000c00080018001000300020006000400000000000000000000000000000000000000
+2078:000000000f00118030c018800d0006000b00118030c018800f00000000000000000000000000000000000000
+2079:000000000f8011c020e0606070e03f601e6000c0018007003c00000000000000000000000000000000000000
+207a:000000000000060006001f801f80060006000000000000000000000000000000000000000000000000000000
+207b:000000000000000000001f801f80000000000000000000000000000000000000000000000000000000000000
+207c:0000000000001f801f80000000001f801f800000000000000000000000000000000000000000000000000000
+207d:0000000000c001800380030007000600070003000380018000c0000000000000000000000000000000000000
+207e:00000000300018001c000c000e0006000e000c001c0018003000000000000000000000000000000000000000
+207f:00000000000000000000278079c030c030c030c030c030c079e0000000000000000000000000000000000000
+2080:00000000000000000000000000000000000007000f80118010c030c030c030c0308018801f000e0000000000
+2081:000000000000000000000000000000000000020006000e001e003600060006000600060006003fc000000000
+2082:0000000000000000000000000000000000001f003f8061c040c0018003000c00180030207fe07fe000000000
+2083:0000000000000000000000000000000000000f801fc020e000e007c00fc000e0406060403f801f0000000000
+2084:00000000000000000000000000000000000000800180038005800980118021803fe07fe00180018000000000
+2085:0000000000000000000000000000000000000fc00fc0100020003f8031c000e00060206030c01f8000000000
+2086:00000000000000000000000000000000000007000c001800300067806fc070e0606070403f801f0000000000
+2087:0000000000000000000000000000000000001fe03fe0604000c0008001800100030002000600040000000000
+2088:0000000000000000000000000000000000000f00118030c018800d0006000b00118030c018800f0000000000
+2089:0000000000000000000000000000000000000f8011c020e0606070e03f601e6000c0018007003c0000000000
+208a:0000000000000000000000000000000000000000000000000000060006001f801f8006000600000000000000
+208b:0000000000000000000000000000000000000000000000000000000000001f801f8000000000000000000000
+208c:00000000000000000000000000000000000000000000000000001f801f80000000001f801f80000000000000
+208d:00000000000000000000000000000000000000c001800380030007000600070003000380018000c000000000
+208e:000000000000000000000000000000000000300018001c000c000e0006000e000c001c001800300000000000
+2090:0000000000000000000000000000000000000000000000000f8018c010c003c01cc030c039c01ee000000000
+2091:0000000000000000000000000000000000000000000000000f0030c060607fe06000300018600f8000000000
+2092:0000000000000000000000000000000000000000000000000f8011c020e060606060704038801f0000000000
+2093:000000000000000000000000000000000000000000000000f8f0704038800f000f0011c020e0f1f000000000
+2094:0000000000000000000000000000000000000000000000001f00618000c000607fe0606030c00f0000000000
+2095:00000000000000000000000000000000000010003000700030003000378039c030c030c030c079e000000000
+2096:0000000000000000000000000000000000006000e0006000638066007c0078006e0067006380f1e000000000
+2097:0000000000000000000000000000000000001e000600060006000600060006000600060006001f8000000000
+2098:000000000000000000000000000000000000000000000000ddc06ee066606660666066606660ef7000000000
+2099:000000000000000000000000000000000000000000000000278079c030c030c030c030c030c079e000000000
+209a:00000000000000000000000000000000000000000000ef8071c060e060606060604070807f0060006000f000
+209b:0000000000000000000000000000000000000000000000001fc030c038001e00078001c030c03f8000000000
+209c:000000000000000000000000000000000000040004000c007fc00c000c000c000c000c200e40078000000000
+20a0:0000000000001f8031c020c0600060006fe06620760036401fc00640060006200fe000000000000000000000
+20a1:0000024002400fc014e024a02480690069006900720072007200240034203c404f8048004800000000000000
+20a2:0000000000000fc01060202020006e6066b06730660066006600260036201e400f8000000000000000000000
+20a3:0000000000007fc030403040300030007f80300030007f003000300030003000780000000000000000000000
+20a4:0000000000000f801cc018c01800180018007e007e0018001800180018003e207fe061c00000000000000000
+20a5:0000000000000000008000800100ddc06ee066606e606e607660766066606660ef7040008000800000000000
+20a6:000000000000c0706020702078205820fff046204720fff041a040e040e04060e03000000000000000000000
+20a7:000000000000fe00c300c180c580cd80df00fe70ccc0ccc0cc60cc30cdb0cdb0e76000000000000000000000
+20a8:000000000000fc00c600c300c300c300c200fce0e310f300d9e0cc70c730c3b0e1e000000000000000000000
+20a9:000000000000fef06620662066207620fff0334037403bc03b80198019801980198000000000000000000000
+20aa:0000000000000000000000003f607f60c360db60db60db60db60db60d960dfc0df8000000000000000000000
+20ab:00c001c000c01ff000c01ec063c041c0c0c0c0c0c0c0c0c0e1c072c03ce000007fe000000000000000000000
20ac:0000000000000f801040202020006000ff8060006000ff0060002000300018400f8000000000000000000000
+20ad:000000000000f0e06180630066006c007800fff07c006e006700638061c060e0f07000000000000000000000
+20ae:0000000000007fe0462006000640068007200e40168027000e001600260006001f8000000000000000000000
+20af:0000000000000000020004003e00d98018c018c030c030c0308060e06190f390dde001800180018000000000
+20b0:000000000000000003c00720062006200320034003c0118039805fc08ec00460006001800000000000000000
+20b1:0000000000007f8030c0fff03060fff030c03780300030003000300030003000780000000000000000000000
+20b2:0000020002000fc0126022202200620062006200620063f06260226032601a600f8002000200000000000000
+20b3:000000000000060006000b000b0009001180fff01080fff020c0204040604060e0f000000000000000000000
+20b4:000000000000ff00c18080c080c001c0ffe00f003c00ffe0e000c040c04060c03fc000000000000000000000
+20b5:0000020002000fc0126022202200620062006200620062006200220032201e400f8002000200000000000000
+20b6:0000000000000000110011003300fff03300330033003300330033003310339031e000000000000000000000
+20b7:0000000000000ff018303010301038001e000f0003c06ce0927092309230d2607fc000000000000000000000
+20b8:00000000fff0fff000000000fff0fff006000600060006000600060006000600060000000000000000000000
+20b9:00000000fff0fff00e000380fff0fff001800700fe00700038001c000e000700038000000000000000000000
+20ba:00000000000030003100320034003900320034007830b03030307030b02030c03f0000000000000000000000
+20bb:000000006000900090007f803fe030303030303030303ab07560300018000fc007c000000000000000000000
+20bc:000000000000000000000000060006000f001fc026e066606660c630c630c630c63000000000000000000000
+20bd:0000000000007f8030c030603060306030c0378030003000fff0300030003000780000000000000000000000
+20be:0000000004800fc014e024a024a064b064b06000600060006000200030001e00ffe000000000000000000000
+20bf:000012001200ff00608060c060c060c061807f8060c0606060606060606060c0ff8012001200000000000000
+20c0:0000000007001dc03060306060006000600060006000306030601dc0070000007ff000000000000000000000
+20d0:180030007fe0ffe0000000000000000000000000000000000000000000000000000000000000000000000000
+20d1:03000180ffc0ffe0000000000000000000000000000000000000000000000000000000000000000000000000
+20d2:0000060006000600060006000600060006000600060006000600060006000600060006000600060006000000
+20d3:0000000000000600060006000600060006000600060006000600060006000600060006000600000000000000
+20d4:40005f0060c07820000000000000000000000000000000000000000000000000000000000000000000000000
+20d5:00200fa0306041e0000000000000000000000000000000000000000000000000000000000000000000000000
+20d6:30006000ffe06000300000000000000000000000000000000000000000000000000000000000000000000000
+20d7:018000c0ffe000c0018000000000000000000000000000000000000000000000000000000000000000000000
+20d8:000000000000000000000000000000000f0010801080108010800f0000000000000000000000000000000000
+20d9:000000000000000000000000000000000f00108013e011c010800f0000000000000000000000000000000000
+20da:000000000000000000000000000000000f00108011c013e010800f0000000000000000000000000000000000
+20db:6660666000000000000000000000000000000000000000000000000000000000000000000000000000000000
+20dc:db60db6000000000000000000000000000000000000000000000000000000000000000000000000000000000
+20dd:000000000000000000001f8020404020402080108010801080104020402020401f8000000000000000000000
+20de:0000000000000000fff0801080108010801080108010801080108010801080108010fff00000000000000000
+20df:0000000000000000000006000900108020404020801080104020204010800900060000000000000000000000
+20e0:00000000000000000f001080204060205020881084108210811040a04060204010800f000000000000000000
+20e1:318060c0ffe060c0318000000000000000000000000000000000000000000000000000000000000000000000
+20e2:0000000000003fc0c030801080108010801080108010801080108010801080108010c0303fc0000000000000
+20e3:0000000000007fe0a050c0308010801080108010801080108010801080108010c030a0507fe0000000000000
+20e4:000006000600060009000900090010801080108020402040204040204020402080108010fff0000000000000
+20e5:000000006000600030003000180018000c000c000600030003000180018000c000c000000000000000000000
+20e6:0000198019801980198019801980198019801980198019801980198019801980198000000000000000000000
+20e7:fff0001000100010001000100010001000100010001000100010001000100010001000000000000000000000
+20e8:0000000000000000000000000000000000000000000000000000000000000000000000000000666066600000
+20e9:fff0fff0c030c030000000000000000000000000000000000000000000000000000000000000000000000000
+20ea:000000000000000000000000180030006000fff0fff060003000180000000000000000000000000000000000
+20eb:0000000000000cc00cc00cc00cc00cc019801980198019803300330033003300330000000000000000000000
+20ec:000000000000000000000000000000000000000000000000000000000000000000007ff07fe000c001800300
+20ed:00000000000000000000000000000000000000000000000000000000000000000000ffe07fe0300018000c00
+20ee:0000000000000000000000000000000000000000000000000000000000000000000020006000fff060002000
+20ef:0000000000000000000000000000000000000000000000000000000000000000000000400060fff000600040
+20f0:090006001f800600090000000000000000000000000000000000000000000000000000000000000000000000
+2100:00007c00c60006007e00c620c660cec07780030006e00d901b00330063004300019000e00000000000000000
+2101:00007c00c60006007e00c620c660cec07780030007e00e301e0031e060304030063003e00000000000000000
+2102:0000000000001f8028e0486048004800480048004800480048004800486028e01f8000000000000000000000
+2103:6000900090006fc01060202020006000600060006000600060002000302018400f8000000000000000000000
+2104:0000000000000c000c003f004c804c008c008c008c004c004c803f000c000fe00fe000000000000000000000
+2105:00007c00c600c000c000c020c060c6c07d80030007e00e301e30363066304630063003e00000000000000000
+2106:00007c00c600c000c000c020c060c6c07d80030006300e301e30363066304630063003e00000000000000000
+2107:00000000000000000000000000000f801fc0206060003f003f00600060203fc01f0000000000000000000000
+2108:0000000000003f00608040400040086008600fe0086008600060404040c021801f0000000000000000000000
+2109:6000900090006ff00c100c100c000c000c200fe00c200c000c000c000c000c001e0000000000000000000000
+210a:0000000000000000000000000f9018f03060306060c060c060c023801f8003e01f006300630066003e001c00
+210b:00000000000078708c908c906ce00d601ac01cc018c038c0598091809190919060e000000000000000000000
+210c:0000000000001c6033c061806000c000c700d980e0c07060706038301c300c306830b060006000c079009e00
+210d:00000000000079e0492049204920492049204f2049204920492049204920492079e000000000000000000000
+210e:000000000c000c000c00180018001b8037c038c030c0618061806180c300c300c38000000000000000000000
+210f:000000000c000c000f80f80018001b8037c038c030c0618061806180c300c300c38000000000000000000000
+2110:00000000000007e03cc070c000c000c000c000c000c000c000c000c000c000c000c0008019801f000c000000
+2111:000000000fe03fc0600061c003a003800380038001c001c060c0e0c070c070c0388039001e00000000000000
+2112:00000000000019c023204620464027801c000c001800180030007020b020ac40638000000000000000000000
+2113:00000000000001c00320062006400c400c800c8019001a0034003800300078c08f0000000000000000000000
+2114:00000000cc00cc00ffe0cc00cc00cc00cde0ce70cc30cc30cc30cc30cc30ce70cde000000000000000000000
+2115:0000000000007820482064206420522052204920492044a044a042604260412041e000000000000000000000
+2116:00000000000087008200c200c260a290a290929092908a908a60860086f08200c30000000000000000000000
+2117:0000000000000f00108020402f4059a059a059a05f20582058203840204010800f0000000000000000000000
+2118:0000000000003fc043204630263006600cc08f007c00180018001800b000b000600000000000000000000000
+2119:0000000000007f8048c0486048204820486048c04f8048004800480048004800780000000000000000000000
+211a:0000000000001f8028c0486048204820482048204820482048204820486028c01f800600038001c000000000
+211b:0000000000003fc043204630263006600cc00f000d80198019801990b0d0b0d0606000000000000000000000
+211c:00000000000078e0cd3066303630466006c0078006c006c086c0c460e8607070602000000000000000000000
+211d:0000000000007f8048c0486048204820486048c04f804980498048c048c04860786000000000000000000000
+211e:000000000000ff00618060c060c060c060807f007c006e306740638061c062e0f47000000000000000000000
+211f:78000f000100ff0062c062c062c064c064807f007c006e0067006b8069c070e0f07020002000000000000000
+2120:00003d1041b03950051045103910000000000000000000000000000000000000000000000000000000000000
+2121:00000000000000000000000000000000f80020002f40284028402f40284028402f7000000000000000000000
+2122:00007d1011b01150111011101110000000000000000000000000000000000000000000000000000000000000
+2123:f0001e000200e2e064403480348038801900190019001e001e002e0024002400440040004000000000000000
+2124:0000000000007fe07fe002400240048004800900090012001200240024007fe07fe000000000000000000000
+2125:000000000000000000007fc04180030006000c001f80030006000c001f8001c000c040c060803f001e000000
+2126:0000000000000f0011c020c0206060606060606060602040304018800900492079e000000000000000000000
+2127:00000000000079e049200900118020c0204060606060606060606040304038800f0000000000000000000000
+2128:000000000f8011c020e040600060006000e011c00fc010e00060006000606060b06030401f800f0000000000
+2129:00000000000000000000000000001f8006000600060006000600060006000600078000000000000000000000
+212a:000000000000f0e06180630066006c00780078007c006e006700638061c060e0f07000000000000000000000
+212b:06000f0019800f0006000b000b0009001180118010803fc020c0204040604060e0f000000000000000000000
+212c:0000000000003fc043204630263006600cc00f000d80186018601830b830b66063c000000000000000000000
+212d:0000000000000f1039e073006300e600e600e600e380e1c0e0c0e10070007c203fc00f000000000000000000
+212e:00000000000000000e00318060c060c0e0e0ffe0e000e000e0006040604031800e0000000000000000000000
+212f:000000000000000000000000000003800c40188031006600f8006040608031001e0000000000000000000000
+2130:00000000000019e02310461046603f80060007c01e00380071e06610601020601f8000000000000000000000
+2131:0000000000103fe04fc04100222006400fc03e404c80980018001800b000b000600000000000000000000000
+2132:00000000000003c00180018001800180018021803f80218001800180418041807fc000000000000000000000
+2133:0000000000000c3014502ca02ca02ca05960596059605960b2c0b2c0b2d0b2d098e000000000000000000000
+2134:000000000000000000000000000003800c4018a030a06070e0206040608031001e0000000000000000000000
+2135:000000000000c180c1c0e0e0706038203c404e80c700e380e1c070e038703830e03000000000000000000000
+2136:000000000000c000ff807fc000c0004000400040004000400040004000407fe0ffc000000000000000000000
+2137:000000000000600078003e00070001000100010001000100018002c004e03c60782000000000000000000000
+2138:000000000000c000ff807fc00080018001800180018001800180018001800300030000000000000000000000
+2139:000000000000000006000f000f00060000003f000f000f000f000f000f000f003fc000000000000000000000
+213a:000000000000000000000f903fd07060c0d08190801080108010803040603fc00f8000000000000000000000
+213b:00000000000000000000000000000000f80080008000e91088a094409c40a2a0a31000000000000000000000
+213c:0000000000000000000000000000ffe0248024802480248024802480249024903c6000000000000000000000
+213d:00000000000000000000000000000000f020902048402480250013001200090009001480248024801f000000
+213e:0000000000007fe0482048204800480048004800480048004800480048004800780000000000000000000000
+213f:000000000000fff0909090909090909090909090909090909090909090909090f0f000000000000000000000
+2140:0000000000007fe04800240012000900048002400240048009001200240048007fe000000000000000000000
+2141:0000000000001f00318060c060c060607c60006000600060006060c060c031801f0000000000000000000000
+2142:0000000000007fc07fc000c000c000c000c000c000c000c000c000c000c000c000c000000000000000000000
+2143:00000000000000c000c000c000c000c000c000c000c000c000c000c000c07fc07fc000000000000000000000
+2144:0000000000000600060006000600060006000f000f001980198030c030c06060606000000000000000000000
+2145:0000000000003e00258024402420242048204820482048209040904090809700f80000000000000000000000
+2146:0000000001e001200120012001200e40324042404240424084808480848084807f8000000000000000000000
+2147:00000000000000000000000000000f801260241048204fe048009000900051803e0000000000000000000000
+2148:0000000000000000078004800780000000000f000900090009001200120012001e0000000000000000000000
+2149:000000000000000003c0024003c0000000000780048004800480090009000900090012002400780000000000
+214a:0000000000000c000c007f804c404c204c204c200c400f800c000c000c000fe00fe000000000000000000000
+214b:0000000067807fc01860386078606c600ee007c007801f003180318031801f000e0000000000000000000000
+214c:000000000180e240242024202410241024107f20a4a0a440a4a07f2024202400240024002400240024001800
+214d:000038006c006c006c00c620fe60c6c0c780030007e00e301e0031e060304030063003e00000000000000000
+214e:000000000000000000000000000003c001800180018011801f801180018021803fc000000000000000000000
+214f:000000000000000000000000000000004440aaa0aaa0aaa0aaa0aaa044406660999000000000000000000000
+2150:000018003800380018001820186018c019803f0006000c001bf030306060406000c000c00180018003000000
+2151:000018003800380018001820186018c019803f0006000c0019e033306330433001f00030006000c003000000
+2152:18003800380018001820186018c019803f0006000c001800300079e03b303b301b301b301b301b301b303de0
+2153:000018003800380018001820186018c019803f0007e00f301830303061e040300030033001e0000000000000
+2154:000038007c006c004c001820306060c07d807f0007e00f301830303061e040300030033001e0000000000000
+2155:000018003800380018001820186018c019803f0007f00ff01b00330063e040300030033001e0000000000000
+2156:000038007c006c004c001820306060c07d807f0007f00ff01b00330063e040300030033001e0000000000000
+2157:00003c006600060006003c20066006c067803f0007f00ff01b00330063e040300030033001e0000000000000
+2158:000004000c001c001c002c204c607ec00d800f0007f00ff01b00330063e040300030033001e0000000000000
+2159:000018003800380018001820186018c019803f0006600d801b00360067c046600660066003c0000000000000
+215a:0000fc00fc00c000c000f8200c600cc0cd807b0006600d801b00360067c046600660066003c0000000000000
+215b:000018003800380018001820186018c019803f0007c00e601e60366063c046600660066003c0000000000000
+215c:00003c006600060006003c20066006c067803d0007c00e601e60366063c046600660066003c0000000000000
+215d:00007e007e00600060007c20066006c067803f0007c00e601e60366063c046600660066003c0000000000000
+215e:00007e0006000c200c6018c01980330036006c001bc036606660466003c006600660066003c0000000000000
+215f:000018003800380018001820186018c019803f0006000c001800300060004000000000000000000000000000
+2160:0000000000001f000400040004000400040004000400040004000400040004001f0000000000000000000000
+2161:0000000000003fc00900090009000900090009000900090009000900090009003fc000000000000000000000
+2162:000000000000ffe0248024802480248024802480248024802480248024802480ffe000000000000000000000
+2163:000000000000fef0282028202820244024402440228022802280210021002100ffc000000000000000000000
+2164:000000000000f9f02040204020401080108010800900090009000600060006001f8000000000000000000000
+2165:000000000000e3f04140414041402240224022401440144014400840084008403ff000000000000000000000
+2166:000000000000e7f042a042a042a042a024a024a024a024a018a018a018a018a03df000000000000000000000
+2167:000000000000dff08aa08aa08aa08aa052a052a052a052a022a022a022a022a077f000000000000000000000
+2168:000000000000fef0244024402280228022802100210022802280228024402440fef000000000000000000000
+2169:0000000000007bc0110011000a000a000a00040004000a000a000a00110011007bc000000000000000000000
+216a:000000000000f7f0224022401440144014400840084014401440144022402240f7f000000000000000000000
+216b:000000000000eff0452045202920292029201120112029202920292045204520eff000000000000000000000
+216c:00000000000078003000300030003000300030003000300030003000302030207fe000000000000000000000
+216d:0000000000000fc01060202020006000600060006000600060002000302018400f8000000000000000000000
+216e:000000000000ff0061c060c06060606060606060606060606060606060406180fe0000000000000000000000
+216f:000000000000e07060e070e070e070e05960596059604d604e604e6044604460e4f000000000000000000000
+2170:00000000000004000400000000000c00040004000400040004000400040004000e0000000000000000000000
+2171:000000000000108010800000000031801080108010801080108010801080108039c000000000000000000000
+2172:0000000000004440444000000000ccc044404440444044404440444044404440eee000000000000000000000
+2173:0000000000004000400000000000dc7048204820444044404440428042804280e7c000000000000000000000
+2174:000000000000000000000000000070e0204020401080108009000900060006000f0000000000000000000000
+2175:0000000000000020002000000000e3e0412041202220222022201420142014203e7000000000000000000000
+2176:00000000000000a000a000000000c7e082a082a044a044a044a028a028a028a07df000000000000000000000
+2177:00000000000002a002a000000000dfe08aa08aa08aa052a052a052a022a022a077f000000000000000000000
+2178:00000000000020002000000000006ee0244022802280210021002280228024407ee000000000000000000000
+2179:000000000000000000000000000071c0208011000a00040004000a001100208071c000000000000000000000
+217a:000000000000004000400000000077c02240144014400840084014401440224077e000000000000000000000
+217b:00000000000000a000a000000000efe044a028a028a010a010a028a028a044a0eff000000000000000000000
+217c:000000001e0006000600060006000600060006000600060006000600060006001f8000000000000000000000
+217d:00000000000000000000000000001f8031c020c06000600060006000704030c01f8000000000000000000000
+217e:00000000006000e00060006000600f6031e020e0606060606060606070e039601e7000000000000000000000
+217f:0000000000000000000000000000ddc06ee06660666066606660666066606660ef7000000000000000000000
+2180:0000000000000f8036e04660c630c630c630c630c630c630c630c630662076c01f0000000000000000000000
+2181:000000000000ff0061c060c07860666063606360636063606660786060406180fe0000000000000000000000
+2182:0000000000000f8036e04660c630cf30d6b0d6b0d6b0d6b0cf30c630662076c01f0000000000000000000000
+2183:0000000000003f00608040400040006000600060006000600060004040c021801f0000000000000000000000
+2184:00000000000000000000000000001f8038c03040006000600060006020e030c01f8000000000000000000000
+2185:0000000000000fc01060202020006000600060006000600060002000302018600fe000600060006000600000
+2186:000000000000060006000600060006000600060006004620666036c01f800f00060000000000000000000000
+2187:000000000000ff0061c078c06460626072606a606a6072606260646078406180fe0000000000000000000000
+2188:0000000000000f8036e046609fb0a650af50a950a950af50a6509f90662076c01f0000000000000000000000
+2189:00003c006600660066006620666066c067803f0007e00f301830303061e040300030033001e0000000000000
+218a:000000007fe07fe040c00180030006000c001800300030003000302038601fc00f8000000000000000000000
+218b:000000000f801fc0206060206000600070003f003e0070006000602070403f801f0000000000000000000000
+2190:0000000000000000000000000c00180030007fe07fe0300018000c0000000000000000000000000000000000
+2191:0000000006000f001f8036c06660060006000600060006000600060006000600060000000000000000000000
+2192:0000000000000000000000000300018000c07fe07fe000c00180030000000000000000000000000000000000
+2193:000000000600060006000600060006000600060006000600666036c01f800f00060000000000000000000000
+2194:000000000000000000000000198030c06060fff0fff0606030c0198000000000000000000000000000000000
+2195:0000000006000f001f8036c0666006000600060006000600666036c01f800f00060000000000000000000000
+2196:0000000000000000000000007f007f0078006c0066006300618000c000600000000000000000000000000000
+2197:0000000000000000000000000fe00fe001e0036006600c601860300060000000000000000000000000000000
+2198:0000000000000000000000006000300018600c600660036001e00fe00fe00000000000000000000000000000
+2199:000000000000000000000000006000c06180630066006c0078007f007f000000000000000000000000000000
+219a:0000000000000000000000001800306060c0fff0fff061803300180000000000000000000000000000000000
+219b:00000000000000000000000001800cc01860fff0fff0306060c0018000000000000000000000000000000000
+219c:000000000000000000000000300060004880d550f550c5504220600030000000000000000000000000000000
+219d:00000000000000000000000000c000601120aab0aaf0aa304420006000c00000000000000000000000000000
+219e:000000000000000000000000198033006600fff0fff066003300198000000000000000000000000000000000
+219f:0000000006000f001f8036c0666006000f001f8036c066600600060006000600060000000000000000000000
+21a0:00000000000000000000000019800cc00660fff0fff006600cc0198000000000000000000000000000000000
+21a1:0000000006000600060006000600666036c01f800f000600666036c01f800f00060000000000000000000000
+21a2:000000000000000000000000180030306060ffc0ffc060603030180000000000000000000000000000000000
+21a3:0000000000000000000000000180c0c060603ff03ff06060c0c0018000000000000000000000000000000000
+21a4:000000000000000000000000180030306030fff0fff060303030180000000000000000000000000000000000
+21a5:0000000006000f001f8036c06660060006000600060006000600060006007fe07fe000000000000000000000
+21a6:0000000000000000000000000180c0c0c060fff0fff0c060c0c0018000000000000000000000000000000000
+21a7:000000007fe07fe006000600060006000600060006000600666036c01f800f00060000000000000000000000
+21a8:000006000f001f8036c066600600060006000600666036c01f800f000600fff0fff000000000000000000000
+21a9:00000000000003c003e00070183030306070ffe0ff8060003000180000000000000000000000000000000000
+21aa:0000000000003c007c00e000c180c0c0e0607ff01ff0006000c0018000000000000000000000000000000000
+21ab:000000000000000000e00110191031106130ffe0ff8061003100190000000000000000000000000000000000
+21ac:000000000000000070008800898088c0c8607ff01ff0086008c0098000000000000000000000000000000000
+21ad:000000000000000000000000198030c06c60f670e6f0636030c0198000000000000000000000000000000000
+21ae:000000000000000000000000108022404620fff0fff046202440108000000000000000000000000000000000
+21af:000000000000030006000c00180030007fe07fe000c00180230036003c003e003f0000000000000000000000
+21b0:0000000006000c0018003fc03fc018c00cc006c000c000c000c000c000c000c000c000000000000000000000
+21b1:000000000600030001803fc03fc0318033003600300030003000300030003000300000000000000000000000
+21b2:0000000000c000c000c000c000c000c000c006c00cc018c03fc03fc018000c00060000000000000000000000
+21b3:0000000030003000300030003000300030003600330031803fc03fc001800300060000000000000000000000
+21b4:00000000ff00ff000300030003000300030003000300030033301b600fc00780030000000000000000000000
+21b5:000000000000003000300030003000300030183030306030fff0fff060003000180000000000000000000000
+21b6:00000000000000000000038006c00c600c60183099307e303c00180000000000000000000000000000000000
+21b7:000000000000000000001c00360063006300c180c990c7e003c0018000000000000000000000000000000000
+21b8:0000000000007fe07fe000007f007f0078006c0066006300618000c000600000000000000000000000000000
+21b9:00008c009800b000ffe0ffe0b00098008c000310019000d07ff07ff000d00190031000000000000000000000
+21ba:0000000000001f801e00198018c0186000600060606060606060204030c019800f0000000000000000000000
+21bb:0000000000001f80078019803180618060006000606060606060204030c019800f0000000000000000000000
+21bc:000000000000000000000000000000000c00180030007fe0ffe0000000000000000000000000000000000000
+21bd:0000000000000000000000000000000000000000ffe07fe0300018000c000000000000000000000000000000
+21be:0000000008000c000e000f000d800cc00c000c000c000c000c000c000c000c000c0000000000000000000000
+21bf:000000000100030007000f001b00330003000300030003000300030003000300030000000000000000000000
+21c0:00000000000000000000000000000000060003000180ffc0ffe0000000000000000000000000000000000000
+21c1:0000000000000000000000000000000000000000ffe0ffc00180030006000000000000000000000000000000
+21c2:000000000c000c000c000c000c000c000c000c000c000cc00d800f000e000c00080000000000000000000000
+21c3:0000000003000300030003000300030003000300030033001b000f0007000300010000000000000000000000
+21c4:00000000018000c00060fff0fff0006000c0198030006000fff0fff060003000180000000000000000000000
+21c5:0000000030c078c0fcc0b4c030c030c030c030c030c030c030c032d033f031e030c000000000000000000000
+21c6:00000000180030006000fff0fff060003000198000c00060fff0fff0006000c0018000000000000000000000
+21c7:00000000180030006000fff0fff060003000180030006000fff0fff060003000180000000000000000000000
+21c8:0000000030c079e0fff0b6d030c030c030c030c030c030c030c030c030c030c030c000000000000000000000
+21c9:00000000018000c00060fff0fff0006000c0018000c00060fff0fff0006000c0018000000000000000000000
+21ca:0000000030c030c030c030c030c030c030c030c030c030c030c0b6d0fff079e030c000000000000000000000
+21cb:00000000000000000c00180030007fe0ffe000000000ffe0ffc0018003000600000000000000000000000000
+21cc:00000000000000000300018000c07fe07ff0000000007ff03ff018000c000600000000000000000000000000
+21cd:00000000000000000040304030406ff06ff0c080c1006ff06ff0320032000200000000000000000000000000
+21ce:00000000000000000100214021405fa05fa0821084105fa05fa0284028400800000000000000000000000000
+21cf:0000000000000000040004c004c0ff60ff6008301030ff60ff6020c020c02000000000000000000000000000
+21d0:00000000000000000000300030006ff06ff0c000c0006ff06ff0300030000000000000000000000000000000
+21d1:0000000006000f001f8039c079e0f9f019801980198019801980198019801980198000000000000000000000
+21d2:0000000000000000000000c000c0ff60ff6000300030ff60ff6000c000c00000000000000000000000000000
+21d3:00000000198019801980198019801980198019801980f9f079e039c01f800f00060000000000000000000000
+21d4:0000000000000000000030c030c06f606f60c030c0306f606f6030c030c00000000000000000000000000000
+21d5:000006000f001f8039c079e0f9f01980198019801980f9f079e039c01f800f00060000000000000000000000
+21d6:0000000000000000000000007f004c006600730059804cc006600330018000c0000000000000000000000000
+21d7:00000000000000000000000007f00190033006700cd01990330066000c001800000000000000000000000000
+21d8:00000000000000000000000018000c006600330019900cd006700330019007f0000000000000000000000000
+21d9:0000000000000000000000000180030006600cc09980b300e600cc009800fe00000000000000000000000000
+21da:000000000000180018003ff03ff070006000fff0fff0600070003ff03ff01800180000000000000000000000
+21db:00000000000001800180ffc0ffc000e00060fff0fff0006000e0ffc0ffc00180018000000000000000000000
+21dc:0000000000000000000000002000200061006380f6706c206000200020000000000000000000000000000000
+21dd:0000000000000000000000000040004008601c60e6f043600060004000400000000000000000000000000000
+21de:0000000006000f001f8036c06660060006007fe07fe0060006007fe07fe00600060000000000000000000000
+21df:00000000060006007fe07fe0060006007fe07fe006000600666036c01f800f00060000000000000000000000
+21e0:000000000000000000000000180030006000db60db6060003000180000000000000000000000000000000000
+21e1:000006000f001f8036c066600000000006000600060000000000060006000600000000000600060006000000
+21e2:0000000000000000000000000300018000c0db60db6000c00180030000000000000000000000000000000000
+21e3:0000060006000600000000000600060006000000000006000600060000000000666036c01f800f0006000000
+21e4:000000000000000000000000c600cc00d800fff0fff0d800cc00c60000000000000000000000000000000000
+21e5:0000000000000000000000000630033001b0fff0fff001b00330063000000000000000000000000000000000
+21e6:0000000000000000000006000a00120023f0401080108010401023f012000a00060000000000000000000000
+21e7:0000000006000900108020404020f0f0108010801080108010801080108010801f8000000000000000000000
+21e8:00000000000000000000060005000480fc408020801080108020fc4004800500060000000000000000000000
+21e9:000000001f8010801080108010801080108010801080f0f04020204010800900060000000000000000000000
+21ea:0000000006000900108020404020f0f01080108010801f8000001f80108010801f8000000000000000000000
+21eb:0000000006000900108020404020f0f0108010801080108010801080f0f08010fff000000000000000000000
+21ec:000000000600090010803fc04020f0f0108010801080108010801080f0f08010fff000000000000000000000
+21ed:0000000006000f00168026404620f6f0168016801680168016801680f6f08610fff000000000000000000000
+21ee:0000000006000900108026404920909020404020f0f0108010801080108010801f8000000000000000000000
+21ef:0000000006000900108026404920909020404020f0f0108010801080f0f08010fff000000000000000000000
+21f0:00000000000000000000e600a500a480bc408020801080108020bc40a480a500e60000000000000000000000
+21f1:000000000000000000000000fff08000be00b800ac00a600a300818080c08060803000000000000000000000
+21f2:000000000000000000000000c0106010301018100c500650035001d007d00010fff000000000000000000000
+21f3:0000000006000900108020404020f0f0108010801080f0f04020204010800900060000000000000000000000
+21f4:00000000000000000000000001801cc02260fff0fff022601cc0018000000000000000000000000000000000
+21f5:0000000030c031e033f032d030c030c030c030c030c030c030c0b4c0fcc078c030c000000000000000000000
+21f6:018000c00060fff0fff0006000c0018000c00060fff0fff0006000c0018000c00060fff0fff0006000c00180
+21f7:0000000000000000000000000000198031806180fff0fff06180318019800000000000000000000000000000
+21f8:0000000000000000000000000000198018c01860fff0fff0186018c019800000000000000000000000000000
+21f9:0000000000000000000000000000168026404620fff0fff04620264016800000000000000000000000000000
+21fa:00000000000000000000000000001a4032406240fff0fff0624032401a400000000000000000000000000000
+21fb:0000000000000000000000000000258024c02460fff0fff0246024c025800000000000000000000000000000
+21fc:0000000000000000000000002040204069606960fff0fff06960696020402040000000000000000000000000
+21fd:00000000000000000000000000001800280048008ff08ff04800280018000000000000000000000000000000
+21fe:0000000000000000000000000100018001400120ff10ff100120014001800100000000000000000000000000
+21ff:00000000000000000000000009001980294049208f108f104920294019800900000000000000000000000000
+2200:000000006060606060603fc03fc030c01980198019800f000f000f0006000600060000000000000000000000
+2201:000000001f803fc070e060606000600060006000600060006000606070e03fc01f8000000000000000000000
+2202:0000000000003c000f00038001c000c000c03fe070e060606060606070e03fc01f8000000000000000000000
+2203:0000000000007fe07fe000600060006000607fe07fe000600060006000607fe07fe000000000000000000000
+2204:0000010001007fe07fe002600260046004607fe07fe008600860106010607fe07fe020002000000000000000
+2205:00000000000000000000000000100fa011c020e06160626064606860704038805f0080000000000000000000
+2206:000000000000060006000f000f0019801980198030c030c030c0606060607fe07fe000000000000000000000
+2207:0000000000007fe07fe06060606030c030c030c01980198019800f000f000600060000000000000000000000
+2208:0000000000000000000007e01fe03800300060007fe07fe06000300038001fe007e000000000000000000000
+2209:0000000000000040004007e01fe03880308061007fe07fe0610032003a001fe007e004000400000000000000
+220a:0000000000000000000000000000000007c0180020007fc02000180007c00000000000000000000000000000
+220b:000000000000000000007e007f8001c000c000607fe07fe0006000c001c07f807e0000000000000000000000
+220c:00000000020002007e007f8005c004c008607fe07fe0086010c011c07f807e00200020000000000000000000
+220d:000000000000000000000000000000003e00018000403fe0004001803e000000000000000000000000000000
+220e:00000000000000000000000000007fe07fe07fe07fe07fe07fe07fe07fe07fe07fe000000000000000000000
+220f:00000000fff0fff0606060606060606060606060606060606060606060606060f0f0f0f00000000000000000
+2210:00000000e070e070606060606060606060606060606060606060606060606060fff0fff00000000000000000
+2211:000000007fe07fe03020180018000c000c00070007000c000c001800180030207fe07fe00000000000000000
2212:00000000000000000000000000000000000000003fc03fc00000000000000000000000000000000000000000
+2213:0000000000003fc03fc00000000006000600060006003fc03fc0060006000600060000000000000000000000
+2214:000000000000060006000000000006000600060006003fc03fc0060006000600060000000000000000000000
+2215:000000000000018001800300030003000600060006000c000c000c0018001800180030003000000000000000
+2216:00000000000000000000180018000c000c000600060003000300018001800000000000000000000000000000
+2217:00000000000006000600c630e67076e036c01f801f8036c076e0e670c6300600060000000000000000000000
+2218:0000000000000000000000000000000006000f00198019800f00060000000000000000000000000000000000
+2219:0000000000000000000000000000000006000f001f801f800f00060000000000000000000000000000000000
+221a:0000002000200060006000c000c001800180e3006300360036001c001c000800080000000000000000000000
+221b:0000f01008100830703008600860f0c000c0f18031801b001b000e000e000400040000000000000000000000
+221c:00001010301050309030fc60106010c000c0f18031801b001b000e000e000400040000000000000000000000
+221d:0000000000000000000000000000303048408480830083008480484030300000000000000000000000000000
+221e:000000000000000000000000000030c049208610861086108610492030c00000000000000000000000000000
+221f:00000000000000000000c000c000c000c000c000c000c000c000c000c000fff0fff000000000000000000000
+2220:0000000000000000000003000300060006000c000c00180018003000300060006000fff0fff0000000000000
+2221:00000000000003000300660036001c000e001b001980318030c060c060c0fff0fff000c000c0000000000000
+2222:000000000000000000000600030001e0078038c0c0c0c0c038c0078001e00300060000000000000000000000
+2223:0000000000000600060006000600060006000600060006000600060006000600060000000000000000000000
+2224:0000000000000600060006000600066007801e00660006000600060006000600060000000000000000000000
+2225:0000000000001980198019801980198019801980198019801980198019801980198000000000000000000000
+2226:0000000000001980198019801980198019f01f80f98019801980198019801980198000000000000000000000
+2227:0000000000000000000000000000060006000f000f001980198030c030c06060606000000000000000000000
+2228:00000000000000000000000000006060606030c030c0198019800f000f000600060000000000000000000000
+2229:000000000000000000001f803fc070e060606060606060606060606060606060606000000000000000000000
+222a:0000000000000000000060606060606060606060606060606060606070e03fc01f8000000000000000000000
+222b:000001e003e00700060006000600060006000600060006000600060006000600060006000e007c0078000000
+222c:000007700ef01980198019801980198019801980198019801980198019801980198019803980f700ee000000
+222d:000019903330777066606660666066606660666066606660666066606660666066606660eee0ccc099800000
+222e:000001e003e00700060006001f80264026404620462046204620264026401f80060006000e007c0078000000
+222f:000007700ef01980198019803fc059a059a0999099909990999059a059a03fc0198019803980f700ee000000
+2230:00001dd03bb03770264026403fc06660a650a650a650a650a650a65066603fc026402640eec0ddc0bb800000
+2231:000003c007c00e000c000c003f004c804c404c408df08ce08c400c000c000c000c000c001c00f800f0000000
+2232:000003c007c00e000c000c003f004c804c808c408df08ce08c404c804c803f000c000c001c00f800f0000000
+2233:000003c007c00e000c000c003f004c804c808c408ce08df08c404c804c803f000c000c001c00f800f0000000
+2234:000000000000000006000f000f000600000000000000000030c079e079e030c0000000000000000000000000
+2235:000000000000000030c079e079e030c0000000000000000006000f000f000600000000000000000000000000
+2236:000000000000000006000f000f000600000000000000000006000f000f000600000000000000000000000000
+2237:000000000000000030c079e079e030c0000000000000000030c079e079e030c0000000000000000000000000
+2238:000000000000000000000000000006000600000000003fc03fc0000000000000000000000000000000000000
+2239:000000000000000000c001e001e000c000007f007f00000000c001e001e000c0000000000000000000000000
+223a:000000000000000030c079e079e030c000007fe07fe0000030c079e079e030c0000000000000000000000000
+223b:000000000000000006000f000f00060000203e606780400006000f000f000600000000000000000000000000
+223c:000000000000000000000000000000001c203e6067c043800000000000000000000000000000000000000000
+223d:00000000000000000000000000000000438067c03e601c200000000000000000000000000000000000000000
+223e:00000000000000000000078007c000601c203e6067c0438060003e001e000000000000000000000000000000
+223f:00000000000000000000000018603c607c607e6067e063c063c0618000000000000000000000000000000000
+2240:000018001c000e0007000300030007000e001c001800180018001c000e000700030000000000000000000000
+2241:000000000000000000000080008001001d203e6067c04b800800100010000000000000000000000000000000
+2242:00000000000000000000000000007fe07fe0000000001c203e6067c043800000000000000000000000000000
+2243:00000000000000000000000000001c203e6067c04380000000007fe07fe00000000000000000000000000000
+2244:00000000000000000100010001001e203e6067c04780040004007fe07fe00800100010000000000000000000
+2245:00000000000000001c203e6067c04380000000007fe07fe0000000007fe07fe0000000000000000000000000
+2246:00000000000000001c203e6067c04380008001007fe07fe0020004007fe07fe0080010000000000000000000
+2247:00000000008000801d203e6067c04380020004007fe07fe0040008007fe07fe0100020000000000000000000
+2248:0000000000000000000000001c203e6067c04380000000001c203e6067c04380000000000000000000000000
+2249:0000000000000080008001001d203e6067c04380020002001c203e6067c04b80080010001000000000000000
+224a:0000000000001c203e6067c04380000000001c203e6067c04380000000007fe07fe000000000000000000000
+224b:0000000000001c203e6067c0438000001c203e6067c0438000001c203e6067c0438000000000000000000000
+224c:0000000000000000438067c03e601c20000000007fe07fe0000000007fe07fe0000000000000000000000000
+224d:0000000000000000000000008010e0707fe01f80000000001f807fe0e0708010000000000000000000000000
+224e:0000000000000000000000000f001980f0f0f0f0000000000f001980f0f0f0f0000000000000000000000000
+224f:0000000000000000000000000f001980f0f0f0f00000000000000000fff0fff0000000000000000000000000
+2250:000000000000000006000f000f000600000000007fe07fe0000000007fe07fe0000000000000000000000000
+2251:000006000f000f00060000007fe07fe0000000007fe07fe0000006000f000f00060000000000000000000000
+2252:0000300078007800300000007fe07fe0000000007fe07fe0000000c001e001e000c000000000000000000000
+2253:000000c001e001e000c000007fe07fe0000000007fe07fe00000300078007800300000000000000000000000
+2254:00000000000000000000000000004000e7e0e7e0400000004000e7e0e7e04000000000000000000000000000
+2255:00000000000000000000000000000040fce0fce0004000000040fce0fce00040000000000000000000000000
+2256:00000000000000000000000000007fe07fe006000900090006007fe07fe00000000000000000000000000000
+2257:00000000000000000600090009000600000000007fe07fe0000000007fe07fe0000000000000000000000000
+2258:00000000000000001f807fe0e0708010000000007fe07fe0000000007fe07fe0000000000000000000000000
+2259:00000000000006000f00198030c06060000000007fe07fe0000000007fe07fe0000000000000000000000000
+225a:000000000000606030c019800f000600000000007fe07fe0000000007fe07fe0000000000000000000000000
+225b:00000000000019800f003fc00f001980000000007fe07fe0000000007fe07fe0000000000000000000000000
+225c:0000000006000f00198030c060607fe0000000007fe07fe0000000007fe07fe0000000000000000000000000
+225d:0000103010401740f570954097409440f74000007fe07fe0000000007fe07fe0000000000000000000000000
+225e:000000003bc066606660666066606660000000007fe07fe0000000007fe07fe0000000000000000000000000
+225f:1f803fc070e001c003800700070000000700070000007fe07fe0000000007fe07fe000000000000000000000
+2260:000000000000000000000000004000c001807fc07fc006000c007fc07fc03000600040000000000000000000
+2261:00000000000000000000000000007fc07fc000007fc07fc000007fc07fc00000000000000000000000000000
+2262:00000000000000000000010002007fc07fc004007fc07fc008007fc07fc01000200000000000000000000000
+2263:0000000000000000000000007fc07fc000007fc07fc000007fc07fc000007fc07fc000000000000000000000
+2264:00000000000000000000000000e007801e00780078001e00078000e000007fe07fe000000000000000000000
+2265:0000000070001e00078001e001e007801e00700000007fe07fe0000000007fe07fe000000000000000000000
+2266:0000000000e007801e00780078001e00078000e000007fe07fe0000000007fe07fe000000000000000000000
+2267:0000000070001e00078001e001e007801e00700000007fe07fe0000000007fe07fe000000000000000000000
+2268:0000000000e007801e00780078001e00078001e003007fe07fe006000c007fe07fe018003000000000000000
+2269:0000000070001e00078001e001e007801e0070c001807fe07fe0030006007fe07fe00c001800000000000000
+226a:000000000000000007300e701ce039c07380e700e700738039c01ce00e700730000000000000000000000000
+226b:0000000000000000ce00e700738039c01ce00e700e701ce039c07380e700ce00000000000000000000000000
+226c:000033000c001e0033003300330073807380738073803300330033001e000c00330000000000000000000000
+226d:0000000000000000018001808310e3707fe01f80060006001f807fe0ec708c10180018000000000000000000
+226e:000000000000000000400040008000e007801f00790079001e00078002e00400040004000000000000000000
+226f:000000000000000002000200020074001e00078009e009e00f801e0070001000200020000000000000000000
+2270:0000000000400040008000e007801f00790079001e00078002e004007fe07fe0080008000800000000000000
+2271:0000000000000200020072001e00078009e009e00f801e00700010007fe07fe0200020000000000000000000
+2272:00000000000000e007801e00780078001e00078000e0000000001c203e6067c0438000000000000000000000
+2273:00000000000070001e00078001e001e007801e007000000000001c203e6067c0438000000000000000000000
+2274:00000080008000e007801f00790079001e00078004e0040008001c203e6077c0538010002000000000000000
+2275:00000040004070801e80078001e001e007801e007200040004001c203e6077c0538010002000000000000000
+2276:0000000000e007801e00780078001e00078070e01e00078001e001e007801e00700000000000000000000000
+2277:0000000070001e00078001e001e007801e0070e007801e00780078001e00078000e000000000000000000000
+2278:0200020002e007801e007a007a001e00078072e01e00078005e005e007801e00740004000400000000000000
+2279:0020002070401e40078001e001e007801e0076e007801e00780078001e00278020e040004000000000000000
+227a:000000000000000000000000006001c007803c00e0003c00078001c000600000000000000000000000000000
+227b:000000000000000000000000c00070003c00078000e007803c007000c0000000000000000000000000000000
+227c:00000000000000000000006001c007803c00e0003c000780e1c03c60078001c0006000000000000000000000
+227d:00000000000000000000c00070003c00078000e007803c0070e0c7803c007000c00000000000000000000000
+227e:000000000000006001c007803c00e0003c00078001c0006000001c203e6067c0438000000000000000000000
+227f:000000000000c00070003c00078000e007803c007000c00000001c203e6067c0438000000000000000000000
+2280:000000000000000003000300066007c007803c00ec003c001f8019c018603000300000000000000000000000
+2281:000000000000000001800180c30073003f00078006e007803c007c00cc001800180000000000000000000000
+2282:0000000000000000000007e01fe03800600060006000600038001fe007e00000000000000000000000000000
+2283:000000000000000000007e007f8001c0006000600060006001c07f807e000000000000000000000000000000
+2284:0000000000000180018007e01fe03980618061806180618039801fe007e00180018000000000000000000000
+2285:000000000000180018007e007f8019c0186018601860186019c07f807e001800180000000000000000000000
+2286:000000000000000007e01fe03800600060006000600038001fe007e000007fe07fe000000000000000000000
+2287:00000000000000007e007f8001c0006000600060006001c07f807e0000007fe07fe000000000000000000000
+2288:000000000040004007e01fe0390061006200620064003c001fe017e010007fe07fe020002000000000000000
+2289:00000000004000407f807f8001c0016002600260046005c07f807e0010007fe07fe020004000000000000000
+228a:00000000000007e01fe03800600060006000600038001fe007e000c001807fe07fe00c001800000000000000
+228b:0000000000007e007f8001c0006000600060006001c07f807e0000c001807fe07fe00c001800000000000000
+228c:0000000000000000000060606060626066606fe0666062606060606070e03fc01f8000000000000000000000
+228d:000000000000000000006060606066606f606f60666060606060606070e03fc01f8000000000000000000000
+228e:00000000000000000000c060c060c460c460df60c460c460c060c060e0e07fc03f8000000000000000000000
+228f:000000000000000000007fe07fe0600060006000600060006000600060007fe07fe000000000000000000000
+2290:000000000000000000007fe07fe0006000600060006000600060006000607fe07fe000000000000000000000
+2291:000000007fe07fe0600060006000600060006000600060007fe07fe000007fe07fe000000000000000000000
+2292:000000007fe07fe0006000600060006000600060006000607fe07fe000007fe07fe000000000000000000000
+2293:000000000000000000007fe07fe0606060606060606060606060606060606060606000000000000000000000
+2294:0000000000000000000060606060606060606060606060606060606060607fe07fe000000000000000000000
+2295:00000000000000000e0035804440444084208420ffe0842084204440444035800e0000000000000000000000
+2296:00000000000000000e0031804040404080208020ffe0802080204040404031800e0000000000000000000000
+2297:00000000000000000e003180404060c091208a2084208a20912060c0404031800e0000000000000000000000
+2298:00000000000000000e003180404040c0812082208420882090206040404031800e0000000000000000000000
+2299:00000000000000000e0031804040404080208e208e208e2080204040404031800e0000000000000000000000
+229a:00000000000000000e003180404040408e209120912091208e204040404031800e0000000000000000000000
+229b:00000000000000000e0031804040404095208e2084208e2095204040404031800e0000000000000000000000
+229c:00000000000000000e003180404040409f208020802080209f204040404031800e0000000000000000000000
+229d:00000000000000000e0031804040404080208020bfa0802080204040404031800e0000000000000000000000
+229e:0000000000000000ffe084208420842084208420ffe084208420842084208420ffe000000000000000000000
+229f:0000000000000000ffe080208020802080208020ffe080208020802080208020ffe000000000000000000000
+22a0:0000000000000000ffe08020c060a0a091208a2084208a209120a0a0c0608020ffe000000000000000000000
+22a1:0000000000000000ffe080208020802084208e208e2084208020802080208020ffe000000000000000000000
+22a2:00000000000000000000600060006000600060007fe07fe06000600060006000600000000000000000000000
+22a3:00000000000000000000006000600060006000607fe07fe00060006000600060006000000000000000000000
+22a4:0000000000000000000000000000060006000600060006000600060006007fe07fe000000000000000000000
+22a5:00000000000000000000000000007fe07fe00600060006000600060006000600060000000000000000000000
+22a6:00000000000000000000000030003000300030003fc03fc03000300030003000000000000000000000000000
+22a7:000000000000000000000000300030003fc03fc0300030003fc03fc030003000000000000000000000000000
+22a8:000000000000000000000000600060007fe07fe0600060007fe07fe060006000000000000000000000000000
+22a9:000000000000000000000000cc00cc00cc00cc00cff0cff0cc00cc00cc00cc00000000000000000000000000
+22aa:000000000000000000000000db00db00db00db00dbf0dbf0db00db00db00db00000000000000000000000000
+22ab:000000000000000000000000cc00cc00cff0cff0cc00cc00cff0cff0cc00cc00000000000000000000000000
+22ac:00000000000000000020602060406040608060807fe07fe06200620064006400680008000000000000000000
+22ad:000000000000000000200020604060407fe07fe0610061007fe07fe064006400080008000000000000000000
+22ae:000000000000000000200020cc20cc40cc40cc40cff0cff0cc80cc80cc80cd00010001000000000000000000
+22af:000000000000000000100020cc20cc20cff0cff0cc40cc80cff0cff0cd00cd00010002000000000000000000
+22b0:0000000000000000038001c0006001c007803c00e0003c00078001c000e001c0038000000000000000000000
+22b1:000000000000000038007000e00070003c00078000e007803c007000e0007000380000000000000000000000
+22b2:000000000000000000000000002000e003200c203020c02030200c20032000e0002000000000000000000000
+22b3:0000000000000000000000008000e0009800860081808060818086009800e000800000000000000000000000
+22b4:000000000000002000e003200c203020c02030200c20032000e000200000ffe0ffe000000000000000000000
+22b5:0000000000008000e0009800860081808060818086009800e00080000000ffe0ffe000000000000000000000
+22b6:0000000000000000000000000000204050e08ff08ff050e02040000000000000000000000000000000000000
+22b7:000000000000000000000000000020807140fe20fe2071402080000000000000000000000000000000000000
+22b8:000000000000000000000000000000800140fe20fe2001400080000000000000000000000000000000000000
+22b9:0000000000000000000000000000060006000600000070e070e0000006000600060000000000000000000000
+22ba:00000000000000000000000000000000000000007fe07fe00600060006000600060006000600000000000000
+22bb:00000000000000006060606030c030c0198019800f000f000600060000007fe07fe000000000000000000000
+22bc:00000000000000007fe07fe00000060006000f000f001980198030c030c06060606000000000000000000000
+22bd:00000000000000007fe07fe000006060606030c030c0198019800f000f000600060000000000000000000000
+22be:00000000000000000000c000c000f000cc00c200c100c100c080c080c080ffe0ffe000000000000000000000
+22bf:00000000000000000000006000e001e0036006600c60186030606060c060ffe0ffe000000000000000000000
+22c0:060006000f000f000f0019801980198030c030c030c0606060606060c030c030c03000000000000000000000
+22c1:c030c030c03060606060606030c030c030c01980198019800f000f000f000600060000000000000000000000
+22c2:0f003fc070e060606060c030c030c030c030c030c030c030c030c030c030c030c03000000000000000000000
+22c3:c030c030c030c030c030c030c030c030c030c030c030c0306060606070e03fc00f0000000000000000000000
+22c4:0000000000000000000000000600090010802040108009000600000000000000000000000000000000000000
+22c5:0000000000000000000000000000000006000f000f0006000000000000000000000000000000000000000000
+22c6:0000000000000000000000000000000019800f003fc00f001980000000000000000000000000000000000000
+22c7:000000000000000006000f00c630606030c01980fff0198030c06060c6300f00060000000000000000000000
+22c8:000000000000000000008010c030a050909089108610861089109090a050c030801000000000000000000000
+22c9:000000000000000000008010c020a040908089008600860089009080a040c020801000000000000000000000
+22ca:0000000000000000000080104030205010900910061006100910109020504030801000000000000000000000
+22cb:0000000000000000000080004000200010000800040006000900108020404020801000000000000000000000
+22cc:0000000000000000000000100020004000800100020006000900108020404020801000000000000000000000
+22cd:00000000000000000000000000000000438067c03e601c20000000007fe07fe0000000000000000000000000
+22ce:0000000000000000c06060c0318031801b001b001b001b000e000e000e000400040000000000000000000000
+22cf:0000000000000000040004000e000e000e001b001b001b001b003180318060c0c06000000000000000000000
+22d0:000000000000000007e01fe0380063e067e0640067e063e038001fe007e00000000000000000000000000000
+22d1:00000000000000007e007f8001c07c607e6002607e607c6001c07f807e000000000000000000000000000000
+22d2:000000000000000000003fc07fe0e070c030c630cf30c930c930c930c930c930c93000000000000000000000
+22d3:00000000000000000000c930c930c930c930c930c930cf30c630c030e0707fe03fc000000000000000000000
+22d4:000000000000060006003fc07fe0e670c630c630c630c630c630c630c630c630c63000000000000000000000
+22d5:000000000000000030c030c030c0fff0fff030c030c030c0fff0fff030c030c030c000000000000000000000
+22d6:000000000000000000000000000000e007801e00786078601e00078000e00000000000000000000000000000
+22d7:000000000000000000000000000070001e00078061e061e007801e0070000000000000000000000000000000
+22d8:0000000000000000049009201240248049009200920049002480124009200490000000000000000000000000
+22d9:0000000000000000920049002480124009200490049009201240248049009200000000000000000000000000
+22da:0000000000600180060018006000ffe00000ffe0ffe00000ffe000c003000c003000c0000000000000000000
+22db:00000000c00030000c00030000c0ffe00000ffe0ffe00000ffe0600018000600018000600000000000000000
+22dc:0000000000000000000000007fe07fe0000000e007801e00780078001e00078000e000000000000000000000
+22dd:0000000000000000000000007fe07fe0000070001e00078001e001e007801e00700000000000000000000000
+22de:00000000000000000000006001c007803c60e1c007803c00e0003c00078001c0006000000000000000000000
+22df:00000000000000000000c00070003c00c78070e03c00078000e007803c007000c00000000000000000000000
+22e0:00000000000004000400046009c00f803c00e8003c000f80e9c03c600f8009c0106010001000000000000000
+22e1:00000000000000800080c08071003d00078002e007803e0072e0c7803e007200c40004000400000000000000
+22e2:004000807fe07fe0610061006100620062006200640064007fe07fe008007fe07fe010001000000000000000
+22e3:004000807fe07fe0016001600160026002600260046004607fe07fe008007fe07fe010001000000000000000
+22e4:000000007fe07fe060006000600060006000600060007fe07fe0018003007fe07fe00c001800000000000000
+22e5:000000007fe07fe000600060006000600060006000607fe07fe0018003007fe07fe00c001800000000000000
+22e6:00000000000000e007801f00780078001e00078000e0040008001c203e6077c0538010002000000000000000
+22e7:00000000000070001e00078001e001e007801e007000040004001c203e6077c0538010002000000000000000
+22e8:000000000000006000c003801c00e0001c00038000c0046004001c203e6077c0538010002000000000000000
+22e9:000000000000c00060003800070000e0070038006000c40004001c203e6077c0538010002000000000000000
+22ea:000000000000000000800080012001e003200e203420c42038200c20132010e0202020004000000000000000
+22eb:0000000000000000008000808100e1009a0086008580846089808e009800f000a00020004000000000000000
+22ec:00000080008000a001e003200d203220c22032200c20072004e008200800ffe0ffe010001000000000000000
+22ed:0000010001008100e2009a0086008580846085808e009800e80090001000ffe0ffe020002000000000000000
+22ee:000006000f000f0006000000000006000f000f0006000000000006000f000f00060000000000000000000000
+22ef:000000000000000000000000000000000000eee0eee0eee00000000000000000000000000000000000000000
+22f0:0000006000f000f000600000000006000f000f000600000000006000f000f000600000000000000000000000
+22f1:00006000f000f00060000000000006000f000f00060000000000006000f000f0006000000000000000000000
+22f2:0000000000000000000003f00ff01c0018003000fff0fff0300018001c000ff003f000000000000000000000
+22f3:0000000000000000000007e01fe03800306060607fe07fe06060306038001fe007e000000000000000000000
+22f4:0000000000000000000000000000000007c0180020407fc02040180007c00000000000000000000000000000
+22f5:0000018003c00180000007e01fe03800300060007fe07fe06000300038001fe007e000000000000000000000
+22f6:000000007fe07fe0000007e01fe03800300060007fe07fe06000300038001fe007e000000000000000000000
+22f7:000000000000000000007fe00000000007c0180020407fc02040180007c00000000000000000000000000000
+22f8:0000000007e01fe03800300060007fe07fe06000300038001fe007e000007fe07fe000000000000000000000
+22f9:0000000000000000000007e01fe0380030007fe0600060007fe0300038001fe007e000000000000000000000
+22fa:00000000000000000000fc00ff000380018000c0fff0fff000c001800380ff00fc0000000000000000000000
+22fb:000000000000000000007e007f8001c060c060607fe07fe0606060c001c07f807e0000000000000000000000
+22fc:000000000000000000000000000000003e00018020403fe0204001803e000000000000000000000000000000
+22fd:000000007fe07fe000007e007f8001c000c000607fe07fe0006000c001c07f807e0000000000000000000000
+22fe:000000000000000000007fe0000000003e00018020403fe0204001803e000000000000000000000000000000
+22ff:fff0fff0c000c000c000c000c000c000c000c000fff0fff0c000c000c000c000c000c000c000c000fff0fff0
+2300:00000000000000000000000000100fa011c020e06160626064606860704038805f0080000000000000000000
+2301:000000000000000000000000000006000700078006c00660660036001e000e00060000000000000000000000
+2302:0f000f001980198030c030c060606060c030c030c030c030c030c030c030fff0000000000000000000000000
+2303:060006000f000f001980198030c030c060606060c030c0300000000000000000000000000000000000000000
+2304:0000000000000000000000000000000000000000c030c0306060606030c030c0198019800f000f0006000600
+2305:00000000000000000000fff0fff00000060006000f000f001980198030c030c060606060c030c03000000000
+2306:0000fff0fff000000000fff0fff00000060006000f000f001980198030c030c060606060c030c03000000000
+2307:030006000c000c000600030001800180030006000c000c000600030001800180030006000c000c0006000300
+2308:000000003fc03fc0300030003000300030003000300030003000300030003000300030003000000000000000
+2309:000000003fc03fc000c000c000c000c000c000c000c000c000c000c000c000c000c000c000c0000000000000
+230a:000000003000300030003000300030003000300030003000300030003000300030003fc03fc0000000000000
+230b:0000000000c000c000c000c000c000c000c000c000c000c000c000c000c000c000c03fc03fc0000000000000
+230c:000000000000000000000000000000000000000000000000000000000000000000f000000200020002000200
+230d:0000000000000000000000000000000000000000000000000000000000000000f00000000400040004000400
+230e:0200020002000200000000f00000000000000000000000000000000000000000000000000000000000000000
+230f:04000400040004000000f0000000000000000000000000000000000000000000000000000000000000000000
+2310:0000000000000000000000000000000000007fe07fe060006000600060000000000000000000000000000000
+2311:0000000000000000000000000000000030c01f8010801080108010801f8030c0000000000000000000000000
+2312:000000000000000000000000000000001f802040402040208010801000000000000000000000000000000000
+2313:000000000000000000000000000000001f802040402040208010fff000000000000000000000000000000000
+2314:000000000000000000000000000000001f802040606030c019800f0000000000000000000000000000000000
+2315:0000000000000000000003000cc01020201020102010201010202cc043008000000000000000000000000000
+2316:0000000000000400040004000e003580444084208020f1e080208420444035800e0004000400040000000000
+2317:000000000000000030c030c0fff0fff030c030c030c030c030c0fff0fff030c030c000000000000000000000
+2318:0000000000000000f0f090909f90fff030c030c030c030c030c0fff09f909090f0f000000000000000000000
+2319:000000000000000000000000000060006000600060007fe07fe0000000000000000000000000000000000000
+231a:00000003ff80030180030180030180030180037d800383800610c00c10601810301a1cb01800300c00600610c0038380037d8003018003018003018003018003ff80
+231b:00000007ffe0040020040020020040020040010080010080008100004200003c00004200008100010080021840021840047e20047e2009ff900ffff00ffff0000000
+231c:fe00fe00c000c000c000c000c000000000000000000000000000000000000000000000000000000000000000
+231d:03f003f000300030003000300030000000000000000000000000000000000000000000000000000000000000
+231e:000000000000000000000000000000000000000000000000000000000000c000c000c000c000c000fc00fc00
+231f:0000000000000000000000000000000000000000000000000000000000000030003000300030003003f003f0
+2320:000001e003e00300030006000600060006000600060006000600060006000600060006000600060006000600
+2321:060006000600060006000600060006000600060006000600060006000600060006000c000c007c0078000000
+2322:0000000000000000000000000000000000000000000000001f80606080100000000000000000000000000000
+2323:000000000000000000000000000000000000000000000000801060601f800000000000000000000000000000
+2324:00000000000000000000000000000000f6f0e6700f000f001980198030c030c060606060c030c03000000000
+2325:00000000000000000000000000000000f0f0f8f01c000e000700038001f000f0000000000000000000000000
+2326:00000000000000000000ff80ff8080408040a12092208c108c109220a12080408040ff80ff80000000000000
+2327:00000000000000000000fff0fff08010a050909089108610861089109090a0508010fff0fff0000000000000
+2328:000000000000000000007fe0fff08010a9508010a9508010bfd0bfd08010fff07fe000000000000000000000
+2329:00300000600000600000600000c00000c00000c00001800001800001800003000003000001800001800001800000c00000c00000c000006000006000006000003000
+232a:0c000006000006000006000003000003000003000001800001800001800000c00000c0000180000180000180000300000300000300000600000600000600000c0000
+232b:000000000000000000001ff01ff020102010485044908310831044904850201020101ff01ff0000000000000
+232c:0000000006000900108022404120909090509010901090109010905090904120224010800900060000000000
+232d:0000000000000000080008001000100026102f1059a059a08f40864000800080010001000000000000000000
+232e:000000000000000000000000000007000880104013f0144008809700a000c000f00000000000000000000000
+232f:000000000000000000001f801f80000000007fe07fe0000000001f801f800000000000000000000000000000
+2330:00000000000000000000104038e07df020402040204040804080408081008100ff0000000000000000000000
+2331:00000000000000001000100010003880544092209ff092205440388010001000100000000000000000000000
+2332:000000000000000000000000c000b0008c00830080c0fff080c083008c00b000c00000000000000000000000
+2333:000000000000000000000000c000b0008c00830080c0fff00000000000000000000000000000000000000000
+2334:0000000000000000000000000000000000008010801080108010801080108010fff000000000000000000000
+2335:0000000000000000000000000000000000000000000080104020204010800900060000000000000000000000
+2336:0000fff0060006000600060006000600060006000600060006000600060006000600060006000600fff00000
+2337:000000007fe07fe060606060606060606060606060606060606060606060606060607fe07fe0000000000000
+2338:00000000fff0fff0c030c030c030dfb0dfb0c030c030c030dfb0dfb0c030c030c030fff0fff0000000000000
+2339:00000000fff0fff0c030c030c630c630c030c030dfb0dfb0c030c030c630c630c030fff0fff0000000000000
+233a:00000000fff0fff0c030c030c030c630c930d0b0e070e070d0b0c930c630c030c030fff0fff0000000000000
+233b:00000000fff0fff0c030c030c030c030c630cf30d9b0d9b0cf30c630c030c030c030fff0fff0000000000000
+233c:00000000fff0fff0c030c030cf30dfb0f0f0e070c030c030e070f0f0dfb0cf30c030fff0fff0000000000000
+233d:0000000000000600060006000f003fc076e0e670c630c630e67076e03fc00f00060006000600000000000000
+233e:000000000000000000000f003fc070e06060e670c930c930e670606070e03fc00f0000000000000000000000
+233f:000000c000c000c00180018001800300030003007fe07fe00c000c000c001800180018003000300030000000
+2340:00003000300030001800180018000c000c000c007fe07fe003000300030001800180018000c000c000c00000
+2341:00000000fff0c0f0c1b0c1b0c1b0c330c330c330c630c630cc30cc30cc30d830d830d830f030fff000000000
+2342:00000000fff0f030d830d830d830cc30cc30cc30c630c630c330c330c330c1b0c1b0c1b0c0f0fff000000000
+2343:00000000fff0c030c030c030c070c1b0c630d830e030e030d830c630c1b0c070c030c030c030fff000000000
+2344:00000000fff0c030c030c030e030d830c630c1b0c070c070c1b0c630d830e030c030c030c030fff000000000
+2345:000000000000030003000300130033007300fff0fff073003300130003000300030000000000000000000000
+2346:0000000000000c000c000c000c800cc00ce0fff0fff00ce00cc00c800c000c000c0000000000000000000000
+2347:00000000fff0c030c030c030c030c430cc30dc30fff0fff0dc30cc30c430c030c030c030c030fff000000000
+2348:00000000fff0c030c030c030c030c230c330c3b0fff0fff0c3b0c330c230c030c030c030c030fff000000000
+2349:0000180018000c000c000c000f003fc07ce0ec70c630c630e37073e03fc00f8001800180018000c000c00000
+234a:00000000000000000600060006000600060006000600060006000600fff0fff000000000fff0000000000000
+234b:00000000060006000600060006000f000f001680168026402640462046208610fff006000600060000000000
+234c:00000000fff0c030c030e070e070e070d0b0d0b0d0b0c930c930c930c630c630c030c030c030fff000000000
+234d:00000000fff0c030c030c030c630c630c930c930d0b0d0b0e070e070c030fff0c030c030c030fff000000000
+234e:00000000060006001f803fc0666066606660666066603fc01f80060006007fe07fe000000000000000000000
+234f:00000000000006000f001f803fc0060006000600fff0fff00600060006000600060000000000000000000000
+2350:00000000fff0c630cf30dfb0fff0c630c630c630c630c630c630c630c630c630c630c630c630fff000000000
+2351:00000000fff00000fff0fff00600060006000600060006000600060006000600060000000000000000000000
+2352:00000000060006000600fff086104620462026402640168016800f000f000600060006000600060000000000
+2353:00000000fff0c030c030c030c630c630c930c930c930d0b0d0b0d0b0e070e070e070c030c030fff000000000
+2354:00000000fff0c030c030c030fff0c030e070e070d0b0d0b0c930c930c630c630c030c030c030fff000000000
+2355:000000007fe07fe0060006001f803fc0666066606660666066603fc01f800600060000000000000000000000
+2356:00000000000006000600060006000600fff0fff00600060006003fc01f800f00060000000000000000000000
+2357:00000000fff0c630c630c630c630c630c630c630c630c630c630c630c630fff0dfb0cf30c630fff000000000
+2358:000000000600060006000600000000000000000000000000000000000000000000000000fff0000000000000
+2359:000000000000000000000600060009000900108010802040204040204020fff0fff00000fff0000000000000
+235a:000000000000000000000600090010802040402080108010402020401080090006000000fff0000000000000
+235b:0000000000000000000000000000000006000f00198019800f0006000000000000000000fff0000000000000
+235c:00000000000000000f003fc070e06060e070c030c030e070606070e03fc00f0000000000fff0000000000000
+235d:000000000000000000000f0030c06060c630cf30d9b0d9b0cf30c630c030c030c03000000000000000000000
+235e:00000000fff0fff0c030c630c630c630c630c030c030c030c030c030c030c030c030fff0fff0000000000000
+235f:00000000000000000f003fc060606060c930c630c630c930606060603fc00f00000000000000000000000000
+2360:00000000fff0fff0c030c630cf30cf30c630c030c030c030c630cf30cf30c630c030fff0fff0000000000000
+2361:30c079e030c00000fff0fff00600060006000600060006000600060006000600060000000000000000000000
+2362:000030c079e030c000000600060009000900108010802040204040204020fff0fff000000000000000000000
+2363:0000000030c079e030c0000000000600c630666036c01f801f8036c06660c630060000000000000000000000
+2364:0000000030c079e030c000000000000006000f00198019800f00060000000000000000000000000000000000
+2365:000030c079e030c000000f003fc070e06060e070c030c030e070606070e03fc00f0000000000000000000000
+2366:00000000060006000600c630c630c630c630c630c630c630c630c630666036c00f0006000600060000000000
+2367:000000000300030003001ff03ff073006300c300c300c300c300630073003ff01ff003000300030000000000
+2368:00000000000030c079e030c0000000001c107e70e3e081c00000000000000000000000000000000000000000
+2369:00000000000030c079e030c00000600018000600018000600060018006001800600000000000000000000000
+236a:000000000000000000000000000000003f803f800000000000000e000e000e001c0038000000000000000000
+236b:00000000000000000000fff08010402040203c507e70f3e090c0090009000600060000000000000000000000
+236c:0000000000000f0010802040402040205c307e70e7e0c3a040204020204010800f0000000000000000000000
+236d:000000000000060006000600060006001e307e70e7e0c7800600060006000600060006000600000000000000
+236e:0000000000000000000000000e000e000e000000000000000e000e000e001c0038000000fff0000000000000
+236f:00000000fff0fff0c030c130c130dfb0dfb0c230c230c430c430dfb0dfb0c830c830c030fff0fff000000000
+2370:00000000fff0fff0c030cf30cf30d9b0c1b0c1b0c330c630c630c630c030c630c630c030fff0fff000000000
+2371:0000000000000000000080108010402040203c507e70f3e090c0090009000600060000000000000000000000
+2372:00000000000000000000060006000900090030907cf0e7e0a3c0402040208010801000000000000000000000
+2373:000000000000000000000000000000007e007e000600060006000600060006000600038000e0000000000000
+2374:000000000000000000000000000000001f803fc070e060606060606070e07fc0670060006000600000000000
+2375:00000000000000000000000000006060c030c630c630c630c630c63066207fc0198000000000000000000000
+2376:00000000000000000000000000001f9031d060e060e060c060c060c061e072603c300000fff0000000000000
+2377:00000000000000000000000000000f801fc0206060003f003f00600060203fc01f000000fff0000000000000
+2378:0000000000000000000000007e007e000600060006000600060006000600038000e00000fff0000000000000
+2379:00000000000000000000000000006060c030c630c630c630c630c63066207fc019800000fff0000000000000
+237a:00000000000000000000000000001f9031d060e060e060c060c060c061e072603c3000000000000000000000
+237b:000000c0018001801ff01ff0030003006600660066003c003c003c0018001800180000000000000000000000
+237c:0000000000000cc00f000c003c00cc00cc003c000c000f000cc00cc08f008ff0bff0c000f800000000000000
+237d:000000000000000000000000000000000000f0f0f0f030c030c030c030c03fc03fc000000000000000000000
+237e:000000000f001f8030c060606060c030c030fff0fff030c030c030c030c0f0f0f0f000000000000000000000
+237f:00000000060006000600060006000f001f801f800f0006000600060006000600060000000000000000000000
+2380:0000000000000f001080008000800f801080108010808f904020204010800900060000000000000000000000
+2381:0000000000000000000000000000000078008400040004007c008400840084007d500000fff0000000000000
+2382:0000000000000000000000000000000071c08a200820082079e08a208a208a2079e0000079e0000000000000
+2383:0000000000000000000000008010c0304f2010800080c0b0cfb01080108010804fa0c0308010000000000000
+2384:0000000000000000000000000000ffc089209110911091109110911091108920ffc000000000000000000000
+2385:00000000000006000600f6f08610861086108610861086108610861086108610f6f006000600000000000000
+2386:000000000000000006000f00198030c004600630ff10ff100630046030c019800f0006000000000000000000
+2387:000000000000000000000040006003f003f0066006400c000c0018001800f1f0f1f000000000000000000000
+2388:00000000842084204e4055402480554055404e404e404e4055405540248055404e4084208420000000000000
+2389:000000000000000000000f003fc0606040208010f0f099908f10462060603fc00f0000000000000000000000
+238a:000000000000000000000f003fc060604020fff0b0d099908f10462060603fc00f0000000000000000000000
+238b:00000000000000000000f300c3c0a0e0906008700430c230e070606070e03fc00f0000000000000000000000
+238c:000000000f801fc038e03870fe707c70387010000000000070e089108910891070e000000000000000000000
+238d:0000000000003fc03fc030c030c030c030c030c030c030c030c030c030c0f0f0f0f000000000000000000000
+238e:0000000000000ff01fe030e030c030c030c030c030c030c030c030c070c07f80ff0000000000000000000000
+238f:0000000000000000fff006000900108020404020801080104020204010800900060000000000000000000000
+2390:0000000000000000060009001080204040208010801040202040108009000600fff000000000000000000000
+2391:000000000000fff0060009001080204040208010fff080104020204010800900060000000000000000000000
+2392:000000000000060009001080204040208010fff0801040202040108009000600fff000000000000000000000
+2393:00000000000000000000000000000000ffe0ffe000000000eee0eee000000000000000000000000000000000
+2394:0000000000001f801080204020404020402080108010402040202040204010801f8000000000000000000000
+2395:00000000fff0fff0c030c030c030c030c030c030c030c030c030c030c030c030c030c030fff0fff000000000
+2396:00000000000000003fc03f803f803f003f003e003e003c003c00380038003000300000000000000000000000
+2397:0000d540804000409ff00010801004108c101fd0bfd01fd08c10041080101010f01010101ff0000000000000
+2398:0000ffc08040804095508000801082008310bf80bfd0bf808310820080108000f01010001550000000000000
+2399:0000000003c006400a4012403e402040e070a050a050a050bfd0801080108010fff000000000000000000000
+239a:00000000000000000000000000007fe0801088909110a21084508890911080107fe000000000000000000000
+239b:0000000001800300060006000c000c000c001800180018001800300030003000300030003000300030003000
+239c:3000300030003000300030003000300030003000300030003000300030003000300030003000300030003000
+239d:30003000300030003000300030003000300018001800180018000c000c000c00060006000300018000000000
+239e:0000000018000c0006000600030003000300018001800180018000c000c000c000c000c000c000c000c000c0
+239f:00c000c000c000c000c000c000c000c000c000c000c000c000c000c000c000c000c000c000c000c000c000c0
+23a0:00c000c000c000c000c000c000c000c000c00180018001800180030003000300060006000c00180000000000
+23a1:000000003f803f80300030003000300030003000300030003000300030003000300030003000300030003000
+23a2:3000300030003000300030003000300030003000300030003000300030003000300030003000300030003000
+23a3:3000300030003000300030003000300030003000300030003000300030003000300030003f803f8000000000
+23a4:000000001fc01fc000c000c000c000c000c000c000c000c000c000c000c000c000c000c000c000c000c000c0
+23a5:00c000c000c000c000c000c000c000c000c000c000c000c000c000c000c000c000c000c000c000c000c000c0
+23a6:00c000c000c000c000c000c000c000c000c000c000c000c000c000c000c000c000c000c01fc01fc000000000
+23a7:0000000000c00180030003000600060006000600060006000600060006000600060006000600060006000600
+23a8:06000600060006000600060006000c000c0018003000300018000c000c000600060006000600060006000600
+23a9:060006000600060006000600060006000600060006000600060006000600060003000300018000c000000000
+23aa:0600060006000600060006000600060006000600060006000600060006000600060006000600060006000600
+23ab:00000000300018000c000c000600060006000600060006000600060006000600060006000600060006000600
+23ac:060006000600060006000600060003000300018000c000c00180030003000600060006000600060006000600
+23ad:06000600060006000600060006000600060006000600060006000600060006000c000c001800300000000000
+23ae:0600060006000600060006000600060006000600060006000600060006000600060006000600060006000600
+23af:0000000000000000000000000000000000000000fff0fff00000000000000000000000000000000000000000
+23b0:00c0018003000300060006000600060006000600060006000600060006000600060006000c000c0018003000
+23b1:300018000c000c000600060006000600060006000600060006000600060006000600060003000300018000c0
+23b2:00000000000000007fe07fe030003000180018000c000c0006000600030003000180018000c000c000600060
+23b3:0060006000c000c00180018003000300060006000c000c0018001800300030007fe07fe00000000000000000
+23b4:fff0fff0c030c030c030c0300000000000000000000000000000000000000000000000000000000000000000
+23b5:0000000000000000000000000000000000000000000000000000000000000000c030c030c030c030fff0fff0
+23b6:00000000c030c030c030c030fff0fff0000000000000fff0fff0c030c030c030c03000000000000000000000
+23b7:06000600060006000600c600c60066006600360036001e001e000e000e000600060000000000000000000000
+23b8:c000c000c000c000c000c000c000c000c000c000c000c000c000c000c000c000c000c000c000c000c000c000
+23b9:0030003000300030003000300030003000300030003000300030003000300030003000300030003000300030
23ba:fff0fff000000000000000000000000000000000000000000000000000000000000000000000000000000000
23bb:000000000000000000000000fff0fff000000000000000000000000000000000000000000000000000000000
23bc:00000000000000000000000000000000000000000000000000000000fff0fff0000000000000000000000000
23bd:00000000000000000000000000000000000000000000000000000000000000000000000000000000fff0fff0
+23be:00000000000007e0040004000400040004000400040004000400040004000400040000000000000000000000
+23bf:000000000000040004000400040004000400040004000400040004000400040007e000000000000000000000
+23c0:000000000400040004001f0024804440444084208420842084204440444024801f0004000400040000000000
+23c1:0000ffe00400040004001f0024804440444084208420842084204440444024801f0004000400040000000000
+23c2:00000400040004001f0024804440444084208420842084204440444024801f00040004000400ffe000000000
+23c3:000004000400040004000e000e0015001500248024804440444084208420ffe0040004000400040000000000
+23c4:0000ffe00400040004000e000e0015001500248024804440444084208420ffe0040004000400040000000000
+23c5:000004000400040004000e000e0015001500248024804440444084208420ffe0040004000400ffe000000000
+23c6:0000000004000400040004000400040004203c40478084000400040004000400040004000400040000000000
+23c7:0000ffe004000400040004000400040004203c40478084000400040004000400040004000400040000000000
+23c8:00000400040004000400040004000400040004203c4047808400040004000400040004000400ffe000000000
+23c9:0000ffe004000400040004000400040004000400040004000400040004000400040004000400040000000000
+23ca:0000040004000400040004000400040004000400040004000400040004000400040004000400ffe000000000
+23cb:000000000000fc00040004000400040004000400040004000400040004000400040000000000000000000000
+23cc:0000000000000400040004000400040004000400040004000400040004000400fc0000000000000000000000
+23cd:00000000000007000600f6f08410801080108010801080108010801080108010fff000000000000000000000
+23ce:000000000000000000e000e000e000e008e018e038e07fe0ffe07fc038001800080000000000000000000000
+23cf:000000000000000006000f001f803fc07fe0fff0000000000000fff0fff0fff0fff000000000000000000000
+23d0:0600060006000600060006000600060006000600060006000600060006000600060006000600060006000600
+23d1:00000000000000000000000000000000c03060603fc00f000000000000000000000000000000000000000000
+23d2:0000000000000000000000000000fff0fff000000000c03060603fc00f000000000000000000000000000000
+23d3:0000000000000000000000000000c03060603fc00f0000000000fff0fff00000000000000000000000000000
+23d4:0000000000000000000000000000fff0fff0000000008610492030c030c00000000000000000000000000000
+23d5:00000000000000000000000000008610492030c030c000000000fff0fff00000000000000000000000000000
+23d6:0000000000000000000000000000000000008610492030c030c0000000000000000000000000000000000000
+23d7:0000000000000000003000300030003000300030fff0fff00000000000000000000000000000000000000000
+23d8:0000000000000000c030c030c030c030c030c030fff0fff00000000000000000000000000000000000000000
+23d9:0000000000000000c630c630c630c630c630c630fff0fff00000000000000000000000000000000000000000
+23da:0000000006000600060006000600060006000600fff0fff0000000003fc03fc0000000000f000f0000000000
+23db:00000000000000000000000000003fc020402040fff0204020403fc000000000000000000000000000000000
+23dc:00000000000000000000000000000000000000000000000000003fc07fe0e070c03000000000000000000000
+23dd:00000000000000000000c030e0707fe03fc00000000000000000000000000000000000000000000000000000
+23de:000000000000000000000000000000000000000006000f007fe0f9f0c030c030c03000000000000000000000
+23df:0000000000000000c030c030c030f9f07fe00f00060000000000000000000000000000000000000000000000
+23e0:0000000000000000000000000000000000000000000000001f803fc06060c030801000000000000000000000
+23e1:00000000000000008010c03060603fc01f800000000000000000000000000000000000000000000000000000
+23e2:00000000000000000000000000003f0021002080208040404040402080208010fff000000000000000000000
+23e3:000000000000000006000900108020404f209090a050a050a050a05090904f20204010800900060000000000
+23e4:0000000000000000000000000000000000000000fff000000000000000000000000000000000000000000000
+23e5:00000000000000000000000000000ff010101010202020204040404080808080ff0000000000000000000000
+23e6:00000000000000000000000018002400420042007ff002100210012000c00000000000000000000000000000
+23e7:0000000000002000200022002200fa007200223002c00f000f001f00318060c0c06080300000000000000000
+23e8:000000000000000000000000000000000000000000000000000021c0622062202220222022202220222071c0
+23e9:000000000000000000000000000000c00c00f00f00fc0fc0ff0ff0ffcffcffffffffffffffcffcff0ff0fc0fc0f00f00c00c00000000000000000000000000000000
+23ea:00000000000000000000000000000000300300f00f03f03f0ff0ff3ff3ffffffffffffff3ff3ff0ff0ff03f03f00f00f003003000000000000000000000000000000
+23eb:000000000000000000001800007e0001ff8007ffe01ffff87ffffeffffff001800007e0001ff8007ffe01ffff87ffffeffffff000000000000000000000000000000
+23ec:000000000000000000ffffff7ffffe1ffff807ffe001ff80007e00001800ffffff7ffffe1ffff807ffe001ff80007e00001800000000000000000000000000000000
+23ed:000000000000000000008430c630e730f7b0fff0fff0fff0fff0f7b0e730c630843000000000000000000000
+23ee:00000000000000000000c210c630ce70def0fff0fff0fff0fff0def0ce70c630c21000000000000000000000
+23ef:000000000000000000008330c330e330f330fb30ff30ff30fb30f330e330c330833000000000000000000000
+23f0:0000000f00f03f81fc387e1c31c38c0300c00618600618600c18300c18300c18300660600780600300c001c3800ffff01f00f8000000000000000000000000000000
+23f1:1f80060066601f803fc060606660c630c630c630c630c030606060603fc01f80000000000000000000000000
+23f2:0000000000001f803fc060607060d830cc30c630c330c030606060603fc01f80000000000000000000000000
+23f3:00000007ffe004002004002002004003ffc001ff8001ff8000ff00007e00003c00004200009900010080021840021840047e20047e2009ff900ffff00ffff0000000
+23f4:000000000000000000c001c003c007c00fc01fc03fc03fc01fc00fc007c003c001c000c00000000000000000
+23f5:0000000000000000300038003c003e003f003f803fc03fc03f803f003e003c00380030000000000000000000
+23f6:000000000000000000000000000006000f001f803fc07fe0fff0fff000000000000000000000000000000000
+23f7:0000000000000000000000000000fff0fff07fe03fc01f800f00060000000000000000000000000000000000
+23f8:0000000000000000000079e079e079e079e079e079e079e079e079e079e079e079e000000000000000000000
+23f9:00000000000000000000fff0fff0fff0fff0fff0fff0fff0fff0fff0fff0fff0fff000000000000000000000
+23fa:000000000000000000000f003fc07fe07fe0fff0fff0fff0fff07fe07fe03fc00f0000000000000000000000
+23fb:00000000000006000600060036c066606660c630c630c030c030606060603fc00f0000000000000000000000
+23fc:000000000000000000000f003fc060606660c630c630c630c630666060603fc00f0000000000000000000000
+23fd:0000000000000000000006000600060006000600060006000600060006000600060000000000000000000000
+23fe:0000000000000000000006001c0038003000700070007000700038003e001fe0078000000000000000000000
+23ff:000000000000000000000000001000f007e03f40f8a0c0a038a0074000e00000000000000000000000000000
+2400:00004200620052004a00460042000000108010801080108010800f0000000400040004000400040007e00000
+2401:00003c00420030000c0042003c0000000f0010801080108010800f0000000420042007e00420042004200000
+2402:00003c00420030000c0042003c0000001f000400040004000400040000000420024001800180024004200000
+2403:00007e0040007e00400040007e0000001f000400040004000400040000000420024001800180024004200000
+2404:00007e0040007e00400040007e0000000f0010801080108010800f00000007c0010001000100010001000000
+2405:00007e0040007e00400040007e000000108018801480128011801080000003c00420042004a0044003a00000
+2406:00003c00420042007e004200420000000f8010001000100010000f8000000460058006000600058004600000
+2407:00007c0042007e00420042007c0000001f8010001f80100010001f8000000400040004000400040007e00000
+2408:00000000000000007c0042007e00420042007c00000003c00420030000c0042003c000000000000000000000
+2409:0000000000000000420042007e00420042004200000007c00100010001000100010000000000000000000000
+240a:0000000000000000400040004000400040007e00000007e0040007e004000400040000000000000000000000
+240b:0000000000000000420042002400240018001800000007c00100010001000100010000000000000000000000
+240c:00000000000000007e0040007e00400040004000000007e0040007e004000400040000000000000000000000
+240d:00000000000000003e0040004000400040003e00000007c0042007c004800440042000000000000000000000
+240e:00000000000000003c00420030000c0042003c00000003c0042004200420042003c000000000000000000000
+240f:00000000000000003c00420030000c0042003c00000003e0008000800080008003e000000000000000000000
+2410:00007c0042004200420042007c000000100010001000100010001f80000007e0040007e00400040007e00000
+2411:00007c0042004200420042007c0000000f8010001000100010000f8000000080038000800080008003e00000
+2412:00007c0042004200420042007c0000000f8010001000100010000f80000003c0042000400180020007e00000
+2413:00007c0042004200420042007c0000000f8010001000100010000f80000003c0042001e00020042003c00000
+2414:00007c0042004200420042007c0000000f8010001000100010000f80000004000480048007e0008000800000
+2415:00004200620052004a004600420000000f00108010801f801080108000000460058006000600058004600000
+2416:00003c00420030000c0042003c000000104008800500020002000200000004200620052004a0046004200000
+2417:00007e0040007e00400040007e0000001f0004000400040004000400000007c0042007e00420042007c00000
+2418:00003e0040004000400040003e0000000f00108010801f8010801080000004200620052004a0046004200000
+2419:00000000000000007e0040007e00400040007e0000000420066005a004200420042000000000000000000000
+241a:00003c00420030000c0042003c000000108010801080108010800f00000007c0042007e00420042007c00000
+241b:00007e0040007e00400040007e0000000f0010800c00030010800f00000003e0040004000400040003e00000
+241c:00000000000000007e0040007e00400040004000000003c00420030000c0042003c000000000000000000000
+241d:00000000000000003c00420040004e0042003c00000003c00420030000c0042003c000000000000000000000
+241e:00000000000000007c0042007c00480044004200000003c00420030000c0042003c000000000000000000000
+241f:0000000000000000420042004200420042003c00000003c00420030000c0042003c000000000000000000000
+2420:00000000000000003c00420030000c0042003c00000007c0042007c004000400040000000000000000000000
+2421:00007c0042004200420042007c0000001f8010001f80100010001f8000000400040004000400040007e00000
+2422:00000000600060006c007000e00067806fc070e06060606060606060706078c06f8000000000000000000000
+2423:0000000000000000000000000000000000000000000000006060606060607fe07fe000000000000000000000
+2424:000000000000630073007b006f006700630000000000030003000300030003e003e000000000000000000000
+2425:0000000000000000000000900120024004900920124024804900920024004800900000000000000000000000
+2426:000000000f001f8039c030403000300018000c00060003000300000000000300030000000000000000000000
+2427:0000000000000000000033303330ccc0ccc033303330ccc0ccc033303330ccc0ccc000000000000000000000
+2428:000033303330ccc0ccc033303330ccc0ccc033303330ccc0ccc033303330ccc0ccc000000000000000000000
+2429:00001c701c70e380e3801c701c70e380e3801c701c70e380e3801c701c70e380e38000000000000000000000
+2440:000000000000000000000000000007e007e00660066006606600660066007e007e0000000000000000000000
+2441:000000000000000000000000000000600060006000607fe07fe0606060606060606000000000000000000000
+2442:000000000000000000000000000060606060606060607fe07fe0060006000600060000000000000000000000
+2443:000000000000000000000000000006000600060006007fe07fe0606060606060606000000000000000000000
+2444:00000000000000000000000000007fe07fe06660666006000600666066607fe07fe000000000000000000000
+2445:0000000000000000000000008010e070999086109990e0708010000000000000000000000000000000000000
+2446:000000000000000001e001e071e071e0700070007000700071e071e001e001e0000000000000000000000000
+2447:000000000000000000000000000000e000e006e006e006000600760076007000700000000000000000000000
+2448:00000000000000000000000001e001e001e001e001e06de06de06c006c006c006c0000000000000000000000
+2449:0000000000000000000000000000000000000000000077607760776077607760776000000000000000000000
+244a:00000000000000006600660066003300330033001980198019800cc00cc00cc0066006600660000000000000
+2460:00000f0030c0402046208e109e108610861086108610861086104620402030c00f0000000000000000000000
+2461:00000f0030c040204f20919081908190831086108c10981098105fa0402030c00f0000000000000000000000
+2462:00000f0030c040204f20989080d080d08f1080d080d080d098904f20402030c00f0000000000000000000000
+2463:00000f0030c0402041a0831086108c109990b190bfd08190819041a0402030c00f0000000000000000000000
+2464:00000f0030c040205fa09810981098109f9081908190819099904f20402030c00f0000000000000000000000
+2465:00000f0030c040204f20b0d0b0d0b0108f10b0d0b0d0b0d0b0d04f20402030c00f0000000000000000000000
+2466:00000f0030c040205fa0819083108310861086108c108c1098105820402030c00f0000000000000000000000
+2467:00000f0030c040204f20b0d0b0d0b0d08f10b0d0b0d0b0d0b0d04f20402030c00f0000000000000000000000
+2468:00000f0030c040204f20b0d0b0d0b0d0b0d08fd080d080d0b0d04f20402030c00f0000000000000000000000
+2469:00000f0030c040204020b390b6d0b6d0b6d0b6d0b6d0b6d0b3904020402030c00f0000000000000000000000
+246a:00000f0030c0402040209990bb909990999099909990999099904020402030c00f0000000000000000000000
+246b:00000f0030c040204020b390b6d0b0d0b190b310b610b610b7d04020402030c00f0000000000000000000000
+246c:00000f0030c040204020b390b6d0b0d0b190b190b0d0b6d0b3904020402030c00f0000000000000000000000
+246d:00000f0030c040204020b190b310b610b6d0b6d0b7d0b0d0b0d04020402030c00f0000000000000000000000
+246e:00000f0030c040204020b7d0b610b610b790b0d0b0d0b6d0b3904020402030c00f0000000000000000000000
+246f:00000f0030c040204020b190b310b610b790b6d0b6d0b6d0b3904020402030c00f0000000000000000000000
+2470:00000f0030c040204020b7d0b0d0b0d0b190b190b310b310b3104020402030c00f0000000000000000000000
+2471:00000f0030c040204020b390b6d0b6d0b390b6d0b6d0b6d0b3904020402030c00f0000000000000000000000
+2472:00000f0030c040204020b390b6d0b6d0b6d0b3d0b0d0b190b3104020402030c00f0000000000000000000000
+2473:00000f0030c0402040209890a55085508950895091509150bc904020402030c00f0000000000000000000000
+2474:000000000000402046208e109e10861086108610861086108610462040200000000000000000000000000000
+2475:00000000000040204f20919081908190831086108c10981098105fa040200000000000000000000000000000
+2476:00000000000040204f20989080d080d08f1080d080d080d098904f2040200000000000000000000000000000
+2477:000000000000402041a0831086108c109990b190bfd08190819041a040200000000000000000000000000000
+2478:00000000000040205fa09810981098109f9081908190819099904f2040200000000000000000000000000000
+2479:00000000000040204f20b0d0b0d0b0108f10b0d0b0d0b0d0b0d04f2040200000000000000000000000000000
+247a:00000000000040205fa0819083108310861086108c108c109810582040200000000000000000000000000000
+247b:00000000000040204f20b0d0b0d0b0d08f10b0d0b0d0b0d0b0d04f2040200000000000000000000000000000
+247c:00000000000040204f20b0d0b0d0b0d0b0d08fd080d080d0b0d04f2040200000000000000000000000000000
+247d:00000000000040204020b390b6d0b6d0b6d0b6d0b6d0b6d0b390402040200000000000000000000000000000
+247e:000000000000402040209990bb90999099909990999099909990402040200000000000000000000000000000
+247f:00000000000040204020b390b6d0b0d0b190b310b610b610b7d0402040200000000000000000000000000000
+2480:00000000000040204020b390b6d0b0d0b190b190b0d0b6d0b390402040200000000000000000000000000000
+2481:00000000000040204020b190b310b610b6d0b6d0b7d0b0d0b0d0402040200000000000000000000000000000
+2482:00000000000040204020b7d0b610b610b790b0d0b0d0b6d0b390402040200000000000000000000000000000
+2483:00000000000040204020b190b310b610b790b6d0b6d0b6d0b390402040200000000000000000000000000000
+2484:00000000000040204020b7d0b0d0b0d0b190b190b310b310b310402040200000000000000000000000000000
+2485:00000000000040204020b390b6d0b6d0b390b6d0b6d0b6d0b390402040200000000000000000000000000000
+2486:00000000000040204020b390b6d0b6d0b6d0b3d0b0d0b190b310402040200000000000000000000000000000
+2487:000000000000402040209890a55085508950895091509150bc90402040200000000000000000000000000000
+2488:0000000004000c001c003c006c000c000c000c000c000c000c000c000c000c307fb000000000000000000000
+2489:000000003e007f00c3808180018001800180030006000c00180030006080ffb0ffb000000000000000000000
+248a:000000000f801fc020e04060006000e007c00fc000e000600060406060403fb01f3000000000000000000000
+248b:0000000001800380038005800580098009801180118021803fe07fe0018001b001b000000000000000000000
+248c:000000001f801f802000200040007f00638001c000c000c000c080c0c0c061b03f3000000000000000000000
+248d:0000000007000c00180030003000600067806fc070e060606060606070403fb01f3000000000000000000000
+248e:000000001fe03fe06040004000c0008000800180010001000300020002000660046000000000000000000000
+248f:000000000f00118030c030c030c018800d0006000b00118030c030c030c018b00f3000000000000000000000
+2490:000000000f8011c020e060606060606070e03f601e60006000c000c0018007303c3000000000000000000000
+2491:0000000043004480c840c84048404840484048404840484048404840484044b0e33000000000000000000000
+2492:00000000210021006300e700210021002100210021002100210021002100213073b000000000000000000000
+2493:0000000047004880d040d04040404080408041004100420042004400440048b0efb000000000000000000000
+2494:0000000043004480c840c84040404040408047004080404040404840484044b0e33000000000000000000000
+2495:0000000041004100c200c200440044004800490051005fe04100410041004130e13000000000000000000000
+2496:000000004fc04840c800c800480048004f0040804040404040404840484044b0e33000000000000000000000
+2497:0000000043004480c840c840480048004f0048804840484048404840484044b0e33000000000000000000000
+2498:000000004fe04020c020c0404040408040804100410042004200440044004860e86000000000000000000000
+2499:0000000043004480c840c84048404840448043004480484048404840484044b0e33000000000000000000000
+249a:0000000043004480c840c840484048404840444043c0404040404840484044b0e33000000000000000000000
+249b:00000000610092809440144024402440244024404440444044408440844082b0f93000000000000000000000
+249c:00000000402040208010801080108f9098d090d083d09cd0b0d0b0d0b0d0b9d09ef040204020000000000000
+249d:0000000040205020b010f010b010b390b7d0b8f0b070b070b070b070b870bcd0a79040204020000000000000
+249e:00000000402040208010801080109f90b1d0a0d0e010e010e010e010f050b0d09f9040204020000000000000
+249f:00000000402041e080d080d080d08ed0b3d0a1d0e0d0e0d0e0d0e0d0f1d0bad09cd040204020000000000000
+24a0:0000000040204020801080108010871098d0b070b070bff0b010b01098108c70879040204020000000000000
+24a1:0000000043a044e084d08c108c108c108c109f908c108c108c108c108c108c109e1040204020000000000000
+24a2:00000000402040208010801080108f3099f0b0d0b0d0b0d099909f10b010bfd09ff05060602020201fe00fc0
+24a3:0000000050207020f010b010b010b790b9d0b0d0b0d0b0d0b0d0b0d0b0d0b0d0f9f040204020000000000000
+24a4:00000000402046208610801080109e10861086108610861086108610861086109f9040204020000000000000
+24a5:00000000402041a0819080108010879081908190819081908190819081908190819051a059a01f000e000000
+24a6:000000004020b020f010b010b010b1d0b310b610bc10b810bc10b610b710b390f9f040204020000000000000
+24a7:000000005e2046208610861086108610861086108610861086108610861086109f9040204020000000000000
+24a8:0000000040204020801080108010ddd0eef0e670e670e670e670e670e670e670ef7040204020000000000000
+24a9:0000000040204020801080108010a790f9d0b0d0b0d0b0d0b0d0b0d0b0d0b0d0f9f040204020000000000000
+24aa:000000004020402080108010801087108b9091d0b0d0b0d0b0d0b0d0b8909d108e1040204020000000000000
+24ab:0000000040204020801080108010f710bb90b1d0b0d0b0d0b0d0b0d0b090b910fe1070207020300030007800
+24ac:000000004020402080108010801086708bd091d0b0d0b0d0b0d0b0d0b8d09dd08fd040e040e000c000c001e0
+24ad:0000000040204020801080108010f390b4d0b8d0b010b010b010b010b010b010f81040204020000000000000
+24ae:00000000402040208010801080109fd0b0d0b050b8109e10879081d0a0d0b0d0bf9040204020000000000000
+24af:0000000040204020841084108c10ffd08c108c108c108c108c108c108c308e50879040204020000000000000
+24b0:0000000040204020801080108010f9f0b0d0b0d0b0d0b0d0b0d0b0d0b0d0b9d09e7040204020000000000000
+24b1:0000000040204020801080108010f070e030b050b050989098908d108d108610861040204020000000000000
+24b2:0000000040204020801080108010ff70e630e630e630b750bb50bb5099909990999040204020000000000000
+24b3:0000000040204020801080108010f8f0f050b8909d108e1087108b9091d0a0f0f1f040204020000000000000
+24b4:0000000040204020801080108010f0f0e030b050b050989098908d108d108610861044204c20080078007000
+24b5:0000000040204020801080108010fff0e0f0c1d0839087108e109c10b830f070fff040204020000000000000
+24b6:1f8020404020462086108b108b108910919091909090bfd0a0d0a050c070c070e0f04020402020401f800000
+24b7:1f80204040207f20b090b0d0b0d0b0d0b190bf90b0d0b070b070b070b070b0d0bf904020402020401f800000
+24b8:1f802040402047a088d090509010b010b010b010b010b010b010901098508c9087104020402020401f800000
+24b9:1f80204040207e20b390b190b0d0b0d0b0d0b0d0b0d0b0d0b0d0b0d0b090b310bc104020402020401f800000
+24ba:1f80204040207fe0b050b050b010b010b090bf90b090b010b010b010b030b030fff04020402020401f800000
+24bb:1f80204040207fe0b050b050b010b010b090bf90b090b010b010b010b010b010f8104020402020401f800000
+24bc:1f802040402047a0887090309010b010b010b010b010b1f0b070907098708c7087904020402020401f800000
+24bd:1f8020404020f9f0b0d0b0d0b0d0b0d0b0d0bfd0b0d0b0d0b0d0b0d0b0d0b0d0f9f04020402020401f800000
+24be:1f80204040205fa08610861086108610861086108610861086108610861086109f904020402020401f800000
+24bf:1f80204040205fa086108610861086108610861086108610861086108610861084107820702020401f800000
+24c0:1f80204040207860b0d0b190b310b610bc10bc10be10b710b390b1d0b0f0b070f8304020402020401f800000
+24c1:1f80204040207820b010b010b010b010b010b010b010b010b010b010b030b030fff04020402020401f800000
+24c2:1f80204040206060b0d0b8d0b8d0b8d0ad50ad50ad50a750a650a650a250a250e2d04020402020401f800000
+24c3:1f80204040206060b050b850b850ac50a450a650a650a250a350a1d0a0d0a0d0e0f04020402020401f800000
+24c4:1f80204040204e209390a190a0d0e0d0e0d0e0d0e0d0e0d0e0d0a090b09099108e104020402020401f800000
+24c5:1f80204040207f80b0d0b070b070b070b0d0b790b010b010b010b010b010b010f8104020402020401f800000
+24c6:1f80204040204e209390a190a0d0e0d0e0d0e0d0e0d0e8d0e4d0b290b9909fd08cd04020402020401f800000
+24c7:1f80204040207f00b190b0d0b0d0b0d0b090bf10bc10b610b710b390b1d0b0f0b8704020402020401f800000
+24c8:1f80204040201fe0b070e030e030f010bc109e10879081d080f0c070c070e0d0ff904020402020401f800000
+24c9:1f80204040207fe0c630861086108610861086108610861086108610861086109f904020402020401f800000
+24ca:1f80204040207060b050b050b050b050b050b050b050b050b050b050b8909f108e104020402020401f800000
+24cb:1f802040402060e0e050b090b090b0909910991099108c108e108e108410841084104020402020401f800000
+24cc:1f80204040207ee0e630e630e630f630f750b350b750bbd0bb9099909990999099904020402020401f800000
+24cd:1f80204040207060e030b050b89098908d10861086108b10919091d0a0d0c070e0f04020402020401f800000
+24ce:1f80204040207060e030b050989098908d1086108610861086108610861086108f104020402020401f800000
+24cf:1f80204040207fe0a0d080d08190819083108310861086108c108c1098109830bff04020402020401f800000
+24d0:1f802040402040208010801080108f9098d090d083d09cd0b0d0b0d0b0d0b9d09ef04020402020401f800000
+24d1:1f80204040205020b010f010b010b390b7d0b8f0b070b070b070b070b870bcd0a7904020402020401f800000
+24d2:1f802040402040208010801080109f90b1d0a0d0e010e010e010e010f050b0d09f904020402020401f800000
+24d3:1f802040402041e080d080d080d08ed0b3d0a1d0e0d0e0d0e0d0e0d0f1d0bad09cd04020402020401f800000
+24d4:1f80204040204020801080108010871098d0b070b070bff0b010b01098108c7087904020402020401f800000
+24d5:1f80204043a044e084d08c108c108c108c109f908c108c108c108c108c108c109e104020402020401f800000
+24d6:1f80204040204020801080108f3099f0b0d0b0d0b0d099909f10b010bfd09ff09070a030a0305fe03fc01f80
+24d7:1f80204050207020f010b010b010b790b9d0b0d0b0d0b0d0b0d0b0d0b0d0b0d0f9f04020402020401f800000
+24d8:1f802040402046208610801080109e10861086108610861086108610861086109f904020402020401f800000
+24d9:1f802040402041a0819080108010879081908190819081908190819081908190819051a059a03f401f800000
+24da:1f8020404020b020f010b010b010b1d0b310b610bc10b810bc10b610b710b390f9f04020402020401f800000
+24db:1f8020405e2046208610861086108610861086108610861086108610861086109f904020402020401f800000
+24dc:1f80204040204020801080108010ddd0eef0e670e670e670e670e670e670e670ef704020402020401f800000
+24dd:1f80204040204020801080108010a790f9d0b0d0b0d0b0d0b0d0b0d0b0d0b0d0f9f04020402020401f800000
+24de:1f8020404020402080108010801087108b9091d0b0d0b0d0b0d0b0d0b8909d108e104020402020401f800000
+24df:1f802040402040208010f710bb90b1d0b0d0b0d0b0d0b0d0b090b910be10b010b0107010702030401f800000
+24e0:1f80204040204020801086708bd091d0b0d0b0d0b0d0b0d0b8d09dd08fd080d080d040e040e020c01f800000
+24e1:1f80204040204020801080108010f390b4d0b8d0b010b010b010b010b010b010f8104020402020401f800000
+24e2:1f802040402040208010801080109fd0b0d0b050b8109e10879081d0a0d0b0d0bf904020402020401f800000
+24e3:1f80204040204020841084108c10ffd08c108c108c108c108c108c108c308e5087904020402020401f800000
+24e4:1f80204040204020801080108010f9f0b0d0b0d0b0d0b0d0b0d0b0d0b0d0b9d09e704020402020401f800000
+24e5:1f80204040204020801080108010f070e030b050b050989098908d108d10861086104020402020401f800000
+24e6:1f80204040204020801080108010ff70e630e630e630b750bb50bb509990999099904020402020401f800000
+24e7:1f80204040204020801080108010f8f0f050b8909d108e1087108b9091d0a0f0f1f04020402020401f800000
+24e8:1f802040402040208010f0f0e030b050b050989098908d108d108610861084108c104820782030401f800000
+24e9:1f80204040204020801080108010fff0e0f0c1d0839087108e109c10b830f070fff04020402020401f800000
+24ea:1f80204047204fa0919090d0b0d0b0d0b0d0b0d0b0d0b0d0b0d0b09098909f108e104020402020401f800000
+24eb:00000f003fc07fe07fe0e670c470e670e670e670e670e670e6707fe07fe03fc00f0000000000000000000000
+24ec:00000f003fc07fe07fe0cc70c930cf30ce70ccf0c9f0c9f0c8307fe07fe03fc00f0000000000000000000000
+24ed:00000f003fc07fe07fe0cc70c930cf30ce70ce70cf30c930cc707fe07fe03fc00f0000000000000000000000
+24ee:00000f003fc07fe07fe0ce70ccf0c9f0c930c930c830cf30cf307fe07fe03fc00f0000000000000000000000
+24ef:00000f003fc07fe07fe0c830c9f0c9f0c870cf30cf30c930cc707fe07fe03fc00f0000000000000000000000
+24f0:00000f003fc07fe07fe0ce70ccf0c9f0c870c930c930c930cc707fe07fe03fc00f0000000000000000000000
+24f1:00000f003fc07fe07fe0c830cf30cf30ce70ce70ccf0ccf0ccf07fe07fe03fc00f0000000000000000000000
+24f2:00000f003fc07fe07fe0cc70c930c930cc70c930c930c930cc707fe07fe03fc00f0000000000000000000000
+24f3:00000f003fc07fe07fe0cc70c930c930c930cc30cf30ce70ccf07fe07fe03fc00f0000000000000000000000
+24f4:00000f003fc07fe07fe0ce70b5b0f5b0edb0edb0ddb0ddb086707fe07fe03fc00f0000000000000000000000
+24f5:0f0030c040204f20b0d0402046208e109e1086108610861086108610861046204020b0d04f20402030c00f00
+24f6:0f0030c040204f20b0d040204f20919081908190831086108c10981098105fa04020b0d04f20402030c00f00
+24f7:0f0030c040204f20b0d040204f20989080d080d08f1080d080d080d098904f204020b0d04f20402030c00f00
+24f8:0f0030c040204f20b0d0402041a0831086108c109990b190bfd08190819041a04020b0d04f20402030c00f00
+24f9:0f0030c040204f20b0d040205fa09810981098109f9081908190819099904f204020b0d04f20402030c00f00
+24fa:0f0030c040204f20b0d040204f20b0d0b0d0b0108f10b0d0b0d0b0d0b0d04f204020b0d04f20402030c00f00
+24fb:0f0030c040204f20b0d040205fa0819083108310861086108c108c10981058204020b0d04f20402030c00f00
+24fc:0f0030c040204f20b0d040204f20b0d0b0d0b0d08f10b0d0b0d0b0d0b0d04f204020b0d04f20402030c00f00
+24fd:0f0030c040204f20b0d040204f20b0d0b0d0b0d0b0d08fd080d080d0b0d04f204020b0d04f20402030c00f00
+24fe:0f0030c040204f20b0d040204020b390b6d0b6d0b6d0b6d0b6d0b6d0b39040204020b0d04f20402030c00f00
+24ff:00000f003fc07fe07fe0e070c630cf30cf30cf30cf30c630e0707fe07fe03fc00f0000000000000000000000
2500:0000000000000000000000000000000000000000fff0fff00000000000000000000000000000000000000000
2501:000000000000000000000000000000000000fff0fff0fff0fff0000000000000000000000000000000000000
2502:0600060006000600060006000600060006000600060006000600060006000600060006000600060006000600
2503:0f000f000f000f000f000f000f000f000f000f000f000f000f000f000f000f000f000f000f000f000f000f00
+2504:0000000000000000000000000000000000000000777077700000000000000000000000000000000000000000
+2505:0000000000000000000000000000000000007770777077707770000000000000000000000000000000000000
+2506:0000000006000600060006000000000000000600060006000600000000000000060006000600060000000000
+2507:000000000f000f000f000f000000000000000f000f000f000f000000000000000f000f000f000f0000000000
+2508:00000000000000000000000000000000000000006db06db00000000000000000000000000000000000000000
+2509:0000000000000000000000000000000000006db06db06db06db0000000000000000000000000000000000000
+250a:0000060006000600060000000000060006000600000000000600060006000600000000000600060006000000
+250b:00000f000f000f000f00000000000f000f000f00000000000f000f000f000f00000000000f000f000f000000
250c:000000000000000000000000000000000000000007f007f00600060006000600060006000600060006000600
250d:00000000000000000000000000000000000007f007f007f007f0060006000600060006000600060006000600
250e:00000000000000000000000000000000000000000ff00ff00f000f000f000f000f000f000f000f000f000f00
@@ -464,6 +3000,10 @@
2549:0f000f000f000f000f000f000f000f000f00ff00fff0fff0ff000f000f000f000f000f000f000f000f000f00
254a:0f000f000f000f000f000f000f000f000f000ff0fff0fff00ff00f000f000f000f000f000f000f000f000f00
254b:0f000f000f000f000f000f000f000f000f00fff0fff0fff0fff00f000f000f000f000f000f000f000f000f00
+254c:000000000000000000000000000000000000000079e079e00000000000000000000000000000000000000000
+254d:00000000000000000000000000000000000079e079e079e079e0000000000000000000000000000000000000
+254e:0000000006000600060006000600060006000000000000000000060006000600060006000600060000000000
+254f:000000000f000f000f000f000f000f000f0000000000000000000f000f000f000f000f000f000f0000000000
2550:000000000000000000000000000000000000fff000000000fff0000000000000000000000000000000000000
2551:0900090009000900090009000900090009000900090009000900090009000900090009000900090009000900
2552:00000000000000000000000000000000000007f00600060007f0060006000600060006000600060006000600
@@ -497,8 +3037,1551 @@
256e:0000000000000000000000000000000000000000e000f8001c000c0006000600060006000600060006000600
256f:060006000600060006000600060006000c001c00f800e0000000000000000000000000000000000000000000
2570:060006000600060006000600060006000300038001f000700000000000000000000000000000000000000000
+2571:0010002000200040004000800080010001000200020004000400080008001000100020002000400040008000
+2572:8000400040002000200010001000080008000400040002000200010001000080008000400040002000200010
+2573:8010402040202040204010801080090009000600060006000600090009001080108020402040402040208010
+2574:0000000000000000000000000000000000000000fc00fc000000000000000000000000000000000000000000
+2575:0600060006000600060006000600060006000600060000000000000000000000000000000000000000000000
+2576:000000000000000000000000000000000000000003f003f00000000000000000000000000000000000000000
+2577:0000000000000000000000000000000000000000000006000600060006000600060006000600060006000600
+2578:000000000000000000000000000000000000fc00fc00fc00fc00000000000000000000000000000000000000
+2579:0f000f000f000f000f000f000f000f000f000f000f0000000000000000000000000000000000000000000000
+257a:00000000000000000000000000000000000003f003f003f003f0000000000000000000000000000000000000
+257b:000000000000000000000000000000000000000000000f000f000f000f000f000f000f000f000f000f000f00
+257c:00000000000000000000000000000000000003f0fff0fff003f0000000000000000000000000000000000000
+257d:060006000600060006000600060006000600060006000f000f000f000f000f000f000f000f000f000f000f00
+257e:000000000000000000000000000000000000fc00fff0fff0fc00000000000000000000000000000000000000
+257f:0f000f000f000f000f000f000f000f000f000f000f0006000600060006000600060006000600060006000600
+2580:fff0fff0fff0fff0fff0fff0fff0fff0fff0fff0fff000000000000000000000000000000000000000000000
+2581:0000000000000000000000000000000000000000000000000000000000000000000000000000fff0fff0fff0
+2582:0000000000000000000000000000000000000000000000000000000000000000fff0fff0fff0fff0fff0fff0
+2583:0000000000000000000000000000000000000000000000000000fff0fff0fff0fff0fff0fff0fff0fff0fff0
+2584:00000000000000000000000000000000000000000000fff0fff0fff0fff0fff0fff0fff0fff0fff0fff0fff0
+2585:000000000000000000000000000000000000fff0fff0fff0fff0fff0fff0fff0fff0fff0fff0fff0fff0fff0
+2586:000000000000000000000000fff0fff0fff0fff0fff0fff0fff0fff0fff0fff0fff0fff0fff0fff0fff0fff0
+2587:000000000000fff0fff0fff0fff0fff0fff0fff0fff0fff0fff0fff0fff0fff0fff0fff0fff0fff0fff0fff0
+2588:fff0fff0fff0fff0fff0fff0fff0fff0fff0fff0fff0fff0fff0fff0fff0fff0fff0fff0fff0fff0fff0fff0
+2589:ffc0ffc0ffc0ffc0ffc0ffc0ffc0ffc0ffc0ffc0ffc0ffc0ffc0ffc0ffc0ffc0ffc0ffc0ffc0ffc0ffc0ffc0
+258a:ff80ff80ff80ff80ff80ff80ff80ff80ff80ff80ff80ff80ff80ff80ff80ff80ff80ff80ff80ff80ff80ff80
+258b:fe00fe00fe00fe00fe00fe00fe00fe00fe00fe00fe00fe00fe00fe00fe00fe00fe00fe00fe00fe00fe00fe00
+258c:fc00fc00fc00fc00fc00fc00fc00fc00fc00fc00fc00fc00fc00fc00fc00fc00fc00fc00fc00fc00fc00fc00
+258d:f800f800f800f800f800f800f800f800f800f800f800f800f800f800f800f800f800f800f800f800f800f800
+258e:e000e000e000e000e000e000e000e000e000e000e000e000e000e000e000e000e000e000e000e000e000e000
+258f:c000c000c000c000c000c000c000c000c000c000c000c000c000c000c000c000c000c000c000c000c000c000
+2590:03f003f003f003f003f003f003f003f003f003f003f003f003f003f003f003f003f003f003f003f003f003f0
2591:aaa00000aaa00000aaa00000aaa00000aaa00000aaa00000aaa00000aaa00000aaa00000aaa00000aaa00000
2592:3330ccc03330ccc03330ccc03330ccc03330ccc03330ccc03330ccc03330ccc03330ccc03330ccc03330ccc0
2593:fff0aaa0fff0aaa0fff0aaa0fff0aaa0fff0aaa0fff0aaa0fff0aaa0fff0aaa0fff0aaa0fff0aaa0fff0aaa0
+2594:fff0fff0fff00000000000000000000000000000000000000000000000000000000000000000000000000000
+2595:0030003000300030003000300030003000300030003000300030003000300030003000300030003000300030
+2596:00000000000000000000000000000000000000000000fc00fc00fc00fc00fc00fc00fc00fc00fc00fc00fc00
+2597:0000000000000000000000000000000000000000000003f003f003f003f003f003f003f003f003f003f003f0
+2598:fc00fc00fc00fc00fc00fc00fc00fc00fc00fc00fc0000000000000000000000000000000000000000000000
+2599:fc00fc00fc00fc00fc00fc00fc00fc00fc00fc00fc00fff0fff0fff0fff0fff0fff0fff0fff0fff0fff0fff0
+259a:fc00fc00fc00fc00fc00fc00fc00fc00fc00fc00fc0003f003f003f003f003f003f003f003f003f003f003f0
+259b:fff0fff0fff0fff0fff0fff0fff0fff0fff0fff0fff0fc00fc00fc00fc00fc00fc00fc00fc00fc00fc00fc00
+259c:fff0fff0fff0fff0fff0fff0fff0fff0fff0fff0fff003f003f003f003f003f003f003f003f003f003f003f0
+259d:03f003f003f003f003f003f003f003f003f003f003f000000000000000000000000000000000000000000000
+259e:03f003f003f003f003f003f003f003f003f003f003f0fc00fc00fc00fc00fc00fc00fc00fc00fc00fc00fc00
+259f:03f003f003f003f003f003f003f003f003f003f003f0fff0fff0fff0fff0fff0fff0fff0fff0fff0fff0fff0
+25a0:000000000000000000000000ffe0ffe0ffe0ffe0ffe0ffe0ffe0ffe0ffe0ffe0ffe000000000000000000000
+25a1:000000000000000000000000ffe0802080208020802080208020802080208020ffe000000000000000000000
+25a2:0000000000000000000000007fc08020802080208020802080208020802080207fc000000000000000000000
+25a3:000000000000000000000000ffe0802080209f209f209f209f209f2080208020ffe000000000000000000000
+25a4:000000000000000000000000ffe08020ffe08020ffe08020ffe08020ffe08020ffe000000000000000000000
+25a5:000000000000000000000000ffe0aaa0aaa0aaa0aaa0aaa0aaa0aaa0aaa0aaa0ffe000000000000000000000
+25a6:000000000000000000000000ffe0aaa0ffe0aaa0ffe0aaa0ffe0aaa0ffe0aaa0ffe000000000000000000000
+25a7:000000000000000000000000ffe0c920a4a09260c920a4a09260c920a4a09260ffe000000000000000000000
+25a8:000000000000000000000000ffe09260a4a0c9209260a4a0c9209260a4a0c920ffe000000000000000000000
+25a9:000000000000000000000000ffe0c460aaa09120aaa0c460aaa09120aaa0c460ffe000000000000000000000
+25aa:0000000000000000000000000000000000001f001f001f001f001f0000000000000000000000000000000000
+25ab:0000000000000000000000000000000000001f001100110011001f0000000000000000000000000000000000
+25ac:000000000000000000000000000000000000fff0fff0fff0fff0fff000000000000000000000000000000000
+25ad:000000000000000000000000000000000000fff0801080108010fff000000000000000000000000000000000
+25ae:00001f001f001f001f001f001f001f001f001f001f001f001f001f001f001f001f001f001f001f001f000000
+25af:00001f001100110011001100110011001100110011001100110011001100110011001100110011001f000000
+25b0:0000000000000000000000000000000000001ff03ff07fe0ffc0ff8000000000000000000000000000000000
+25b1:0000000000000000000000000000000000001ff0201040208040ff8000000000000000000000000000000000
+25b2:00000000000000000000060006000f000f001f801f803fc03fc07fe07fe0fff0fff000000000000000000000
+25b3:0000000000000000000006000600090009001080108020402040402040208010fff000000000000000000000
+25b4:0000000000000000000000000000060006000f000f001f801f803fc03fc00000000000000000000000000000
+25b5:000000000000000000000000000006000600090009001080108020403fc00000000000000000000000000000
+25b6:00000000000000000000c000f000fc00ff00ffc0fff0fff0ffc0ff00fc00f000c00000000000000000000000
+25b7:00000000000000000000c000b0008c00830080c08030803080c083008c00b000c00000000000000000000000
+25b8:0000000000000000000000000000000030003c003f003fc03fc03f003c003000000000000000000000000000
+25b9:000000000000000000000000000030002c00230020c020c023002c0030000000000000000000000000000000
+25ba:0000000000000000000000000000e000fc00ff80fff0fff0ff80fc00e0000000000000000000000000000000
+25bb:0000000000000000000000000000e0009c0083808070807083809c00e0000000000000000000000000000000
+25bc:00000000000000000000fff0fff07fe07fe03fc03fc01f801f800f000f000600060000000000000000000000
+25bd:00000000000000000000fff08010402040202040204010801080090009000600060000000000000000000000
+25be:00000000000000000000000000003fc03fc01f801f800f000f00060006000000000000000000000000000000
+25bf:00000000000000000000000000003fc020401080108009000900060006000000000000000000000000000000
+25c0:00000000000000000000003000f003f00ff03ff0fff0fff03ff00ff003f000f0003000000000000000000000
+25c1:00000000000000000000003000d003100c103010c010c01030100c10031000d0003000000000000000000000
+25c2:0000000000000000000000000000000000c003c00fc03fc03fc00fc003c000c0000000000000000000000000
+25c3:000000000000000000000000000000c003400c40304030400c40034000c00000000000000000000000000000
+25c4:0000000000000000000000000000007003f01ff0fff0fff01ff003f000700000000000000000000000000000
+25c5:0000000000000000000000000000007003901c10e010e0101c10039000700000000000000000000000000000
25c6:0000000000000000000006000f001f803fc07fe0fff0fff07fe03fc01f800f00060000000000000000000000
-fffd:000000007fe07fe0606060606060606060606060606060606060606060607fe07fe000000000000000000000
+25c7:0000000000000000000006000900108020404020801080104020204010800900060000000000000000000000
+25c8:0000000000000000000006000900108026404f209f909f904f20264010800900060000000000000000000000
+25c9:000000000000000000001f8020405fa05fa0bfd0bfd0bfd0bfd05fa05fa020401f8000000000000000000000
+25ca:0600060009000900108010802040204040204020801080104020402020402040108010800900090006000600
+25cb:000000000000000000001f8020404020402080108010801080104020402020401f8000000000000000000000
+25cc:0000000000000000000016800000402000008010000000008010000040200000168000000000000000000000
+25cd:000000000000000000001f80294049204920c930c930c930c9304920492029401f8000000000000000000000
+25ce:000000000000000000001f8020404f2050a0a050a050a050a05050a04f2020401f8000000000000000000000
+25cf:000000000000000000001f803fc07fe07fe0fff0fff0fff0fff07fe07fe03fc01f8000000000000000000000
+25d0:000000000000000000001f803c407c207c20fc10fc10fc10fc107c207c203c401f8000000000000000000000
+25d1:000000000000000000001f8023c043e043e083f083f083f083f043e043e023c01f8000000000000000000000
+25d2:000000000000000000001f8020404020402080108010fff0fff07fe07fe03fc01f8000000000000000000000
+25d3:000000000000000000001f803fc07fe07fe0fff0fff0801080104020402020401f8000000000000000000000
+25d4:000000000000000000001f8023c043e043e083f083f0801080104020402020401f8000000000000000000000
+25d5:000000000000000000001f8023c043e043e083f083f0fff0fff07fe07fe03fc01f8000000000000000000000
+25d6:000000000000000000001c003c007c007c00fc00fc00fc00fc007c007c003c001c0000000000000000000000
+25d7:00000000000000000000038003c003e003e003f003f003f003f003e003e003c0038000000000000000000000
+25d8:00000000000000003fe03fe03fe03fe038e030603060306038e03fe03fe03fe03fe000000000000000000000
+25d9:000000000000fff0e070dfb0bfd07fe07fe0fff0fff0fff0fff07fe07fe0bfd0dfb0e070fff0000000000000
+25da:000000000000fff0e070dfb0bfd07fe07fe0fff0fff000000000000000000000000000000000000000000000
+25db:00000000000000000000000000000000000000000000fff0fff07fe07fe0bfd0dfb0e070fff0000000000000
+25dc:000000000000000000001c002000400040008000800000000000000000000000000000000000000000000000
+25dd:0000000000000000000003800040002000200010001000000000000000000000000000000000000000000000
+25de:0000000000000000000000000000000000000000000000100010002000200040038000000000000000000000
+25df:00000000000000000000000000000000000000000000800080004000400020001c0000000000000000000000
+25e0:000000000000000000001f802040402040208010801000000000000000000000000000000000000000000000
+25e1:00000000000000000000000000000000000000000000801080104020402020401f8000000000000000000000
+25e2:0000000000000000000000100030007000f001f003f007f00ff01ff03ff07ff0fff000000000000000000000
+25e3:000000000000000000008000c000e000f000f800fc00fe00ff00ff80ffc0ffe0fff000000000000000000000
+25e4:00000000000000000000fff0ffe0ffc0ff80ff00fe00fc00f800f000e000c000800000000000000000000000
+25e5:00000000000000000000fff07ff03ff01ff00ff007f003f001f000f000700030001000000000000000000000
+25e6:0000000000000000000000000000000007000880088008800700000000000000000000000000000000000000
+25e7:00000000000000000000fff0fc10fc10fc10fc10fc10fc10fc10fc10fc10fc10fff000000000000000000000
+25e8:00000000000000000000fff083f083f083f083f083f083f083f083f083f083f0fff000000000000000000000
+25e9:00000000000000000000fff0fff0ffd0ff90ff10fe10fc10f810f010e010c010fff000000000000000000000
+25ea:00000000000000000000fff08030807080f081f083f087f08ff09ff0bff0fff0fff000000000000000000000
+25eb:00000000000000000000fff08610861086108610861086108610861086108610fff000000000000000000000
+25ec:0000000000000000000006000600090009001080108026402f404f2046208010fff000000000000000000000
+25ed:00000000000000000000060006000d000d001c801c803c403c407c207c20fc10fff000000000000000000000
+25ee:00000000000000000000060006000b000b001380138023c023c043e043e083f0fff000000000000000000000
+25ef:000000000000000000001f8020404020402080108010801080104020402020401f8000000000000000000000
+25f0:00000000000000000000fff08210821082108210fe1080108010801080108010fff000000000000000000000
+25f1:00000000000000000000fff080108010801080108010fe108210821082108210fff000000000000000000000
+25f2:00000000000000000000fff08010801080108010801087f08410841084108410fff000000000000000000000
+25f3:00000000000000000000fff0841084108410841087f080108010801080108010fff000000000000000000000
+25f4:000000000000000000001f802240422042208210fe10801080104020402020401f8000000000000000000000
+25f5:000000000000000000001f8020404020402080108010fe1082104220422022401f8000000000000000000000
+25f6:000000000000000000001f802040402040208010801087f084104420442024401f8000000000000000000000
+25f7:000000000000000000001f80244044204420841087f0801080104020402020401f8000000000000000000000
+25f8:00000000000000000000fff080208040808081008200840088009000a000c000800000000000000000000000
+25f9:00000000000000000000fff04010201010100810041002100110009000500030001000000000000000000000
+25fa:000000000000000000008000c000a00090008800840082008100808080408020fff000000000000000000000
+25fb:0000000000000000000000007fe0402040204020402040204020402040207fe0000000000000000000000000
+25fc:0000000000000000000000007fe07fe07fe07fe07fe07fe07fe07fe07fe07fe0000000000000000000000000
+25fd:00000000000000000000000000000000000000000000ff0000810000810000810000810000810000810000ff00000000000000000000000000000000000000000000
+25fe:00000000000000000000000000000000000000000000ff0000ff0000ff0000ff0000ff0000ff0000ff0000ff00000000000000000000000000000000000000000000
+25ff:0000000000000000000000100030005000900110021004100810101020104010fff000000000000000000000
+2600:000000000000000004008420444020800e001f00df601f000e00208044408420040000000000000000000000
+2601:0000000000000000000000000000000000c019e03de03ff07ff07ff0fff0fff07fe000000000000000000000
+2602:000000001f807fe0fff0fff006000600060006000600060006000600660066003c0000000000000000000000
+2603:1f801080fff01f8026407fe07fe0666030c01f801f803fc079e0fff0f9f0fff079e03fc01f80000000000000
+2604:0000000000000000020002000400040008200840108011002200240008606180960090006000000000000000
+2605:0000000000000000060006000f000f00fff07fe03fc01f800f001f801f8039c030c000000000000000000000
+2606:00000000000000000600060009000900f9f0402020401080090010801680294030c000000000000000000000
+2607:0000008001c0038007000e001c003800700038001c000e00072003e001e001e003e000000000000000000000
+2608:000000000000fff0ffe0c1c0c380c700ce00dc00ce00c700c390c1f0c0f0c0f0c1f000000000000000000000
+2609:00000000000000000e0031804040404080208e208e208e2080204040404031800e0000000000000000000000
+260a:0000000000000600198020404020402080108010402040202040204060609090909060600000000000000000
+260b:0000000000006060909090906060204020404020402080108010402040202040198006000000000000000000
+260c:00000000000000000020004000801d00220041004100410022001c0000000000000000000000000000000000
+260d:000001c00220041004100410022001c002000400380044008200820082004400380000000000000000000000
+260e:000000000000000000003fc07fe0fff0e070d0b01f8039c070e0e070f0f0f9f0fff000000000000000000000
+260f:000000000000000000003fc040209f90a050d0b01f80204046208f1086108010fff000000000000000000000
+2610:00000000000000000000fff08010801080108010801080108010801080108010fff000000000000000000000
+2611:00000000000000000000fff0801080d0819081908310e310b6109e108c108010fff000000000000000000000
+2612:00000000000000000000fff08010a050909089108610861089109090a0508010fff000000000000000000000
+2613:00000000000030c030c0198019800f000f00060006000f000f001980198030c030c000000000000000000000
+2614:00208008208408410410410810000800fe0007ffe00ffff01ffff800180000180000180000180000180000180000180000180000180003180003180001f00000e000
+2615:0000001861801861800c30c00618600618600c30c01861800000007fffc07fffc06000f86000fe3001863001861803fe0c07f807fc0003f800000000000000000000
+2616:0000000000000600198060604020402040208010801080108010801080108010fff000000000000000000000
+2617:00000000000006001f807fe07fe07fe07fe0fff0fff0fff0fff0fff0fff0fff0fff000000000000000000000
+2618:00000000000019801f801f800f00e670f6f079e0f6f0e670060006000c000c000c0000000000000000000000
+2619:000000000000000000100020004006400f203fc07fa0ff10ff107f903f900f20064000000000000000000000
+261a:00000000000000000000000001c007e0ffd0ffd007d007d007d003d003d003d001e000000000000000000000
+261b:00000000000000000000000038007e00bff0bff0be00be00be00bc00bc00bc00780000000000000000000000
+261c:00000000000000000000000001c00620791082107e100410079002100390021001e000000000000000000000
+261d:00000100028002800280028002800e407a40aa20a9a0aa608110802080407f804080ffc0ffc0000000000000
+261e:0000000000000000000000003800460089e0841087e082009e0084009c008400780000000000000000000000
+261f:0000ffc0ffc040807f80804080208110aa60a9a0aa207a400e40028002800280028002800100000000000000
+2620:00003f807fc0ffe0ce60842084207bc071c03f8055407fc00000c060f1e03f800e003f80f1e0c06000000000
+2621:0000000000000000fc00fff003f000f001e003c00f003c007800f000fc00fff003f000000000000000000000
+2622:00000f0030c040206060f0f0f9f0fff0f9f08010861086108f104f205fa03fc00f0000000000000000000000
+2623:0000000000001080204020402040108016800900168079e096900f0006000600090030c00000000000000000
+2624:000000000600fff07fe03fc006007fe086107fe046203fc026401f8026401f8026401f801680060000000000
+2625:000000000f00198030c030c030c0198019800f007fe07fe00600060006000600060006000600060000000000
+2626:00000000060006001f801f80060006007fe07fe006000600060006003e000f0007c006000600060000000000
+2627:000000001fc00c600c300c300c300c600dc00c00ccc06d803f001e003f006d80ccc000000000000000000000
+2628:00000000060006001f801f80060006007fe07fe0060006000600060006000600060006000600060000000000
+2629:0000000000000000000000001f000400040084208420ffe084208420040004001f0000000000000000000000
+262a:00000000000000000e003d8078007040f040f1f0f040f0a0f000700078003d800e0000000000000000000000
+262b:000009000f000000462056a09690b6d0b6d0b6d0b6d0b6d0b6d09f905fa00f003fc000000000000000000000
+262c:0000000006004f209690969096909690cf3060607fe03fc026400f001680264046200f000000000000000000
+262d:00000e00338000c000c0006007600e601f603be031e000e000f033b06e10c000800000000000000000000000
+262e:00000000000000000e00358044404440842084208e209520a4a04440444035800e0000000000000000000000
+262f:00000000000000000f0030c040207020f810ccd0ccd0fe10ff307fe07fe03fc00f0000000000000000000000
+2630:00000000fff0fff0fff0000000000000fff0fff0fff0000000000000fff0fff0fff000000000000000000000
+2631:00000000f9f0f9f0f9f0000000000000fff0fff0fff0000000000000fff0fff0fff000000000000000000000
+2632:00000000fff0fff0fff0000000000000f9f0f9f0f9f0000000000000fff0fff0fff000000000000000000000
+2633:00000000f9f0f9f0f9f0000000000000f9f0f9f0f9f0000000000000fff0fff0fff000000000000000000000
+2634:00000000fff0fff0fff0000000000000fff0fff0fff0000000000000f9f0f9f0f9f000000000000000000000
+2635:00000000f9f0f9f0f9f0000000000000fff0fff0fff0000000000000f9f0f9f0f9f000000000000000000000
+2636:00000000fff0fff0fff0000000000000f9f0f9f0f9f0000000000000f9f0f9f0f9f000000000000000000000
+2637:00000000f9f0f9f0f9f0000000000000f9f0f9f0f9f0000000000000f9f0f9f0f9f000000000000000000000
+2638:00000000000000000000000004005f40248055404e40fbe04e40554024805f40040000000000000000000000
+2639:000000000000000000001f80204040204920891080108f10909050a0402020401f8000000000000000000000
+263a:000000000000000000001f8020404020492089108010a05090904f20402020401f8000000000000000000000
+263b:000000000000000000001f803fc07fe06660e670fff0cf30e67070e07fe03fc01f8000000000000000000000
+263c:000000000000000000000000040084204e4011002080e0e0208011004e408420040000000000000000000000
+263d:000000000000000003800d001200140024002400240024002400140012000d00038000000000000000000000
+263e:00000000000000001c000b000480028002400240024002400240028004800b001c0000000000000000000000
+263f:6060606039c01f803fc070e060606060606070e03fc01f80060006007fe07fe0060006000600060006000000
+2640:000000001f803fc070e060606060606070e03fc01f80060006007fe07fe00600060006000600060000000000
+2641:00000000060006000600060006007fe07fe0060006001f803fc070e060606060606070e03fc01f8000000000
+2642:000000000000000003f001f000f001f03fb07f90e1c0c0c0c0c0c0c0e1c07f803f0000000000000000000000
+2643:00000000600060c030c030c018c018c018c030c030c030c060c0fff0fff000c000c000c000c000c000000000
+2644:00000000000030003000fc00fc00300030c033e03e60383030303060306030c030c000c000c000c000000000
+2645:00000600c630666036c03fc03fc036c06660c63006001f803fc070e060606060606070e03fc01f8000000000
+2646:00008610c630ef70c630c630c630c630666076e03fc00f000600060006001f801f8006000600060000000000
+2647:00007e007f8061c060e06060606060e061c07f007e006000600060006000600060007fe07fe0000000000000
+2680:000000000000000000007ff040104010401040104610461040104010401040107ff000000000000000000000
+2681:000000000000000000007ff0401040d040d040104010401040105810581040107ff000000000000000000000
+2682:000000000000000000007ff0401040d040d040104310431040105810581040107ff000000000000000000000
+2683:000000000000000000007ff0401058d058d0401040104010401058d058d040107ff000000000000000000000
+2684:000000000000000000007ff0401058d058d0401046104610401058d058d040107ff000000000000000000000
+2685:000000000000000000007ff0401058d058d0401058d058d0401058d058d040107ff000000000000000000000
+2686:000000000000000000001f8020404020402080108190819080104020402020401f8000000000000000000000
+2687:000000000000000000001f8020404020402080109990999080104020402020401f8000000000000000000000
+2688:000000000000000000001f803fc07fe07fe0fff0fe70fe70fff07fe07fe03fc01f8000000000000000000000
+2689:000000000000000000001f803fc07fe07fe0fff0e670e670fff07fe07fe03fc01f8000000000000000000000
+268a:000000000000000000000000000000000000000000000000fff0fff0fff00000000000000000000000000000
+268b:000000000000000000000000000000000000000000000000f9f0f9f0f9f00000000000000000000000000000
+268c:000000000000000000000000fff0fff0fff0000000000000fff0fff0fff00000000000000000000000000000
+268d:000000000000000000000000f9f0f9f0f9f0000000000000fff0fff0fff00000000000000000000000000000
+268e:000000000000000000000000fff0fff0fff0000000000000f9f0f9f0f9f00000000000000000000000000000
+268f:000000000000000000000000f9f0f9f0f9f0000000000000f9f0f9f0f9f00000000000000000000000000000
+2690:000000000000000000007fe07fe060606060606060607fe07fe0600060006000600000000000000000000000
+2691:000000000000000000007fe07fe07fe07fe07fe07fe07fe07fe0600060006000600000000000000000000000
+26b2:000000001f803fc070e060606060606070e03fc01f8006000600060006000600060006000600060000000000
+26b3:000000001f803fc070e000600060006000e007c00780060006007fe07fe00600060006000600060000000000
+26b4:00000f001f8039c070e0e070c030e07070e039c01f800f00060006007fe07fe0060006000600060000000000
+26b5:00000600c630666036c01f80fff0fff01f8036c06660c630060006007fe07fe0060006000600060000000000
+26b6:00000000060006000600060006000600000070e070e019800f000600e070f0f039c01f800f00060000000000
+26b7:000000000630066006c0078006c006600630060006000f003fc06060c030c03060603fc00f00000000000000
+2700:000000000000000000004000a010b870bdc0478005004780bdc0b870a0104000000000000000000000000000
+2701:0000000000000000000000004000a000a000600030007fc0bff0ac0046000000000000000000000000000000
+2702:000000000000000000004000a010b870bdc0478005004780bdc0b870a0104000000000000000000000000000
+2703:0000000000000000000000004600ac00bff07fc030006000a000a00040000000000000000000000000000000
+2704:000000000000000000004000a010b870bdc0478005004780bdc0b870a0104000000000000000000000000000
+2705:0000000000000000c0000120000110000220000220000440020440050880088880045100022100010200008200004400002400001800000000000000000000000000
+2706:00000f0030c040204da09d909c1098109810981098109c109d904da0502030c00f0000000000000000000000
+2707:00000f003fc04f204f208f108f108f109990bfd0fff0f9f0f0f06060402030c00f0000000000000000000000
+2708:00001000180018000e000e008780c780ffe0fff0ffe0c78087800e000e001800180010000000000000000000
+2709:000000000000fff08010c030a05090908f109f909f908f109090a050c0308010fff000000000000000000000
+270a:00000000000000780003cf001e4900124900124900124900124fc01250301fe010102008101e081000081000100800200601c001fe00000000000000000000000000
+270b:000000003c0001e7800124800724800924800924800924e009249009249009249009001008001008001008002008002004004003008000ff00000000000000000000
+270c:0000000000001ce014a014a00aa00aa005205420a820a9f0aa108010802060c01f0000000000000000000000
+270d:00000000000000000030007000e001c01f8027004ef09c10bc107010eff08000000000000000000000000000
+270e:0000000000000000000018003c007a00f100e88044402220111008b0047002f001f000000000000000000000
+270f:0000000000000000000000000000ff80c040c060fff0c060c040ff8000000000000000000000000000000000
+2710:0000000000000000000001f002f0047008b0111022204440e880f1007a003c00180000000000000000000000
+2711:0000000000000000000000000000e700a880a840b74087f0bf40a840a880e700000000000000000000000000
+2712:0000000000000000000000000000e700ef80efc0fcf0f000fcf0efc0ef80e700000000000000000000000000
+2713:0000000000000020002000400040008000804100410022002200140014000800080000000000000000000000
+2714:0000000000000070007000e000e001c001c0e380e380770077001e001e000c000c0000000000000000000000
+2715:0000000000000000000000004020204010800900060006000900108020404020000000000000000000000000
+2716:000000000000000000000000606070e039c01f800f000f001f8039c070e06060000000000000000000000000
+2717:0000000000000000000000000010102010400880070006000900108020402000000000000000000000000000
+2718:000000000000000000000000003038e039c01f800f001f003b8071c0e0e0e000000000000000000000000000
+2719:00001f801080168016801680f6f08610bfd0bfd08610f6f016801680168010801f8000000000000000000000
+271a:00001f801f801f801f801f80fff0fff0fff0fff0fff0fff01f801f801f801f801f8000000000000000000000
+271b:000000000000060006000600060006000600f9f0f9f006000600060006000600060000000000000000000000
+271c:0000000000000f000f000f000f000f00f0f0f0f0f0f0f0f00f000f000f000f000f0000000000000000000000
+271d:000000000600060006007fe07fe0060006000600060006000600060006000600060000000000000000000000
+271e:00000f000980098079e04030403079f03980098009800980098009800980098009800f800780000000000000
+271f:1f8010801680f6f08610bfd0bfd08610f6f01680168016801680168016801680168010801f80000000000000
+2720:0000000000000000000000003f800e008e208420e4e0ffe0e4e084208e200e003f8000000000000000000000
+2721:0000000000000000060006000900fff0891050a0204050a08910fff009000600060000000000000000000000
+2722:00000000000000000000000004000e000e00040064c0ffe064c004000e000e00040000000000000000000000
+2723:0000000000000000000000000e000e000e000400e4e0ffe0e4e004000e000e000e0000000000000000000000
+2724:0000000000000000000000000e001f001f006ec0f5e0ffe0f5e06ec01f001f000e0000000000000000000000
+2725:00000000000000000000000004000e001f00248064c0ffe064c024801f000e00040000000000000000000000
+2726:00000000000000000000000004000e000e001f007fc0ffe07fc01f000e000e00040000000000000000000000
+2727:00000000000000000000000004000a000a00110060c0802060c011000a000a00040000000000000000000000
+2728:00000000402000e0500040500400880a03060a04013183064040883180500a20500a202004d8001021101020a06c804011c0a0108110000000000000000000000000
+2729:00000000000000000000000004000e000a001b007bc0c0607bc01b000a000e00040000000000000000000000
+272a:0000000000000000000000000e003b807bc071c0e0e08020e0e071c07bc03b800e0000000000000000000000
+272b:00000000000000000000000004000e000e00110060c0e0e060c011000e000e00040000000000000000000000
+272c:00000000000000000000000004000a000a0011006ec08e206ec011000a000a00040000000000000000000000
+272d:00000000000000000000000004000a000a00150064c09f2064c015000a000a00040000000000000000000000
+272e:00000000000000000000000004000a000a0015006ec09f206ec015000a000a00040000000000000000000000
+272f:0000000000000000000006000b000b00138063e083f0fc107c601c800d000d00060000000000000000000000
+2730:00000000000000000000000007000b800b8011c060f0803060f011c00b800b80070000000000000000000000
+2731:000000000e000e00ce60eee0ffe07fc03f801f003f807fc0ffe0eee0ce600e000e0000000000000000000000
+2732:000000000e000e00ce60eee0fbe071c031801100318071c0fbe0eee0ce600e000e0000000000000000000000
+2733:00000000000000000000000004004440248015000e00ffe00e00150024804440040000000000000000000000
+2734:0000000000000000000000000400444064c035801f00ffe01f00358064c04440040000000000000000000000
+2735:0000000000000000000000000600464066c03780ff00ffe01fe03d806cc04c400c0000000000000000000000
+2736:000000000000000000000000040044406ec03f801f000e001f003f806ec04440040000000000000000000000
+2737:00000000000000000000108010801980fff01f80060006001f80fff019801080108000000000000000000000
+2738:00000000000000000000108019801f80fff03fc00f000f003fc0fff01f801980108000000000000000000000
+2739:0000000000000000000000002480150095207fc01f00ffe01f007fc095201500248000000000000000000000
+273a:000000000000000000000000a4a01500952075c00e00ffe00e0075c095201500a4a000000000000000000000
+273b:0000000000000000060066606f603fc000000f000f0000001f803fc06f606660060000000000000000000000
+273c:0000000000000000060066606f603fc01f801080108010801f803fc06f606660060000000000000000000000
+273d:0000000000000000000006006660ef707fe03fc01f801f803fc07fe0ef706660060000000000000000000000
+273e:000000000000000000000f006660e97079e039c01f80168026404f208f1066600f0000000000000000000000
+273f:00000000000000000e001f001f001f006ec0f1e0f1e0f1e03b807fc07fc07fc03b8000000000000000000000
+2740:00000000000000000e001100110071c08e209f209f20ffe03f804440444044403b8000000000000000000000
+2741:0000000000000000000000000e00644034c015808020f1e080203500658044c00e0000000000000000000000
+2742:0000000000000000000000000e003b805b406ec0fbe09120fbe06ec05b403b800e0000000000000000000000
+2743:000000000000000000000e000a00eee0a4a0e4e01f001f00e4e0a4a0eee00a000e0000000000000000000000
+2744:000000000000000000000a000a002e802480e4e01f001f00e4e024802e800a000a0000000000000000000000
+2745:0000000000000000060006000f00fff0f9f070e0204070e0f9f0fff00f000600060000000000000000000000
+2746:0000000000000000090006000f005fa0b9d070e0204070e0b9d05fa00f000600090000000000000000000000
+2747:0000000000000000000000008e204e402e800400e4e0ffe0e4e004002e804e408e2000000000000000000000
+2748:000000000000000000008f105fa00f004620e670fff0fff0e67046200f005fa08f1000000000000000000000
+2749:000000000000000000000e000e00eee0e4e0e4e01f001f00e4e0e4e0eee00e000e0000000000000000000000
+274a:00000000000000000000000084204440248000000400eee00400000024804440842000000000000000000000
+274b:000000000000000000008610c630666036c01f80fff0fff01f8036c06660c630861000000000000000000000
+274c:0000000000000000000000000000000000000100800381c001c38000e700007e00003c00007e0000e70001c3800381c0010080000000000000000000000000000000
+274d:000000000000000000000f0033c040e040e0807080708070807040e040e033c00f0000000000000000000000
+274e:00000000000000000000000007ffe006ff60047e20063c600718e00781e007c3e007c3e00781e00718e0063c60047e2006ff6007ffe0000000000000000000000000
+274f:00000000000000000000ffc08040804080708070807080708070fff03ff03ff0000000000000000000000000
+2750:0000000000000000000000003ff03ff0fff08070807080708070807080408040ffc000000000000000000000
+2751:00000000000000000000ffc080608070807080708070807080708070fff07ff03ff000000000000000000000
+2752:000000000000000000003ff07ff0fff080708070807080708070807080708060ffc000000000000000000000
+2753:00000000000003fe000fff000fff800c1f80000f80000f80000f80000f80001f00003e00007c00007c00000000000000007c00007c00007c00007c00000000000000
+2754:00000000000007fe0008010009f0800f1880000880000880000880000880001100002200004400007c00000000000000007c00004400004400007c00000000000000
+2755:000000000000007c00004400004400004400004400004400004400004400004400004400004400007c00000000000000007c00004400004400007c00000000000000
+2756:0000000000000000020007000f800700124038e07df038e0124007000f800700020000000000000000000000
+2757:00000000000000ff0000ff0000ff0000ff0000ff0000ff0000ff0000ff0000ff0000ff0000ff00000000001800007e0000ff00007e00001800000000000000000000
+2758:0000000006000600060006000600060006000600060006000600060006000600060000000000000000000000
+2759:000000000f000f000f000f000f000f000f000f000f000f000f000f000f000f000f0000000000000000000000
+275a:000000001f801f801f801f801f801f801f801f801f801f801f801f801f801f801f8000000000000000000000
+275b:000007000800100016001f001f001f000e000000000000000000000000000000000000000000000000000000
+275c:00000e001f001f001f000d00010002001c000000000000000000000000000000000000000000000000000000
+275d:0000387040808100b160f9f0f9f0f9f070e00000000000000000000000000000000000000000000000000000
+275e:000070e0f9f0f9f0f9f068d008101020e1c00000000000000000000000000000000000000000000000000000
+275f:00000000000000000000000000000000000000000000000000000e001f001f001f000d00010002001c000000
+2760:000000000000000000000000000000000000000000000000000071c0fbe0fbe0fbe069a008201040e3800000
+2761:0000004000403ff07e407e40fe40fe40fe407e407e403e400fc0004000403c407c40608031000e0000000000
+2762:00007fc0ffe0ffe0ffe0ffe0ffe07fc03f801f000e00040000000e001f001f000e0000000000000000000000
+2763:0000000071c0fbe0ffe0ffe0ffe0ffe07fc03f801f000e0000000e001f001f000e0000000000000000000000
+2764:0000000000000000000070e0f9f0fff0fff0fff0fff07fe03fc01f800f000600060000000000000000000000
+2765:000000000000000000003c007e00ff00ff807fc03ff03ff07fc0ff80ff007e003c0000000000000000000000
+2766:000000001c1063b0c1608200040033007f80ffc0ffc0ffc07f803f001e200c60038000000000000000000000
+2767:000000000000000080004000200026004f003fc05fe08ff08ff09fe09fc04f00260000000000000000000000
+2768:0000000001c007000e001e001c003c003c003c003c003c001c001e000f00070001c000000000000000000000
+2769:0000000038000e0007000780038003c003c003c003c003c0038007800f000e00380000000000000000000000
+276a:0000000003c0078007800f000f000f000f000f000f000f000f000f000780078003c000000000000000000000
+276b:000000003c001e001e000f000f000f000f000f000f000f000f000f001e001e003c0000000000000000000000
+276c:000000000700070007000e000e000e001c001c001c000e000e000e0007000700070000000000000000000000
+276d:000000000e000e000e000700070007000380038003800700070007000e000e000e0000000000000000000000
+276e:0000000000c001c003c007800f001e003c0078003c001e000f00078003c001c000c000000000000000000000
+276f:000000006000700078003c001e000f00078003c007800f001e003c0078007000600000000000000000000000
+2770:000000000780078007800f000f000f001e001e001e000f000f000f0007800780078000000000000000000000
+2771:000000001e001e001e000f000f000f000780078007800f000f000f001e001e001e0000000000000000000000
+2772:000000000100020004000c000c000c000c000c000c000c000c000c000c000c000c0004000200010000000000
+2773:0000000008000400020003000300030003000300030003000300030003000300030002000400080000000000
+2774:0000000003c0078007800f000f000f001e003c001e000f000f000f000780078003c000000000000000000000
+2775:000000003c001e001e000f000f000f00078003c007800f000f000f001e001e003c0000000000000000000000
+2776:00000f003fc07fe079e0f1f0e1f0f9f0f9f0f9f0f9f0f9f0f9f060607fe03fc00f0000000000000000000000
+2777:00000f003fc07fe070e0cf30df30fe70fcf0f9f0f3f0e7f0cfb040207fe03fc00f0000000000000000000000
+2778:00000f003fc07fe070e0ce30df30fe30f070fe30ff30df30ce3070e07fe03fc00f0000000000000000000000
+2779:00000f003fc07fe07e60fcf0f9f0f3f0e670ce70c030fe70fe707c207fe03fc00f0000000000000000000000
+277a:00000f003fc07fe04020cfb0cff0cff0e0f0fe30ff30df30cf3060e07fe03fc00f0000000000000000000000
+277b:00000f003fc07fe070e0c630cf30cff0c0f0ce30cf30cf30c63070e07fe03fc00f0000000000000000000000
+277c:00000f003fc07fe04020de70fcf0fcf0f9f0f9f0f3f0f3f0e7f067e07fe03fc00f0000000000000000000000
+277d:00000f003fc07fe06060c630cf30cf30e070c630cf30cf30cf3060607fe03fc00f0000000000000000000000
+277e:00000f003fc07fe06060c630cf30cf30c630e030ff30cf30cf3060607fe03fc00f0000000000000000000000
+277f:00000f003fc07fe04c2089908990c990c990c990c990c990c99084207fe03fc00f0000000000000000000000
+2780:00000f0030c0402046208e109e108610861086108610861086104620402030c00f0000000000000000000000
+2781:00000f0030c040204f20919081908190831086108c10981098105fa0402030c00f0000000000000000000000
+2782:00000f0030c040204f20989080d080d08f1080d080d080d098904f20402030c00f0000000000000000000000
+2783:00000f0030c0402041a0831086108c109990b190bfd08190819041a0402030c00f0000000000000000000000
+2784:00000f0030c040205fa09810981098109f9081908190819099904f20402030c00f0000000000000000000000
+2785:00000f0030c040204f20b0d0b0d0b0108f10b0d0b0d0b0d0b0d04f20402030c00f0000000000000000000000
+2786:00000f0030c040205fa0819083108310861086108c108c1098105820402030c00f0000000000000000000000
+2787:00000f0030c040204f20b0d0b0d0b0d08f10b0d0b0d0b0d0b0d04f20402030c00f0000000000000000000000
+2788:00000f0030c040204f20b0d0b0d0b0d0b0d08fd080d080d0b0d04f20402030c00f0000000000000000000000
+2789:00000f0030c040204020b390b6d0b6d0b6d0b6d0b6d0b6d0b3904020402030c00f0000000000000000000000
+278a:00000f003fc07fe079e0e1f0f9f0f9f0f9f0f9f0f9f0f9f0f9f079e07fe03fc00f0000000000000000000000
+278b:00000f003fc07fe070e0cf30ff30fe70fcf0f9f0f3f0e7f0cff040207fe03fc00f0000000000000000000000
+278c:00000f003fc07fe070e0cf30ff30ff30f0f0ff30ff30ff30cf3070e07fe03fc00f0000000000000000000000
+278d:00000f003fc07fe07e60fcf0f9f0f3f0e670ce70c030fe70fe707e607fe03fc00f0000000000000000000000
+278e:00000f003fc07fe04020cff0cff0cff0c0f0ff30ff30ff30ff3040f07fe03fc00f0000000000000000000000
+278f:00000f003fc07fe070e0cf30cf30cff0c0f0cf30cf30cf30cf3070e07fe03fc00f0000000000000000000000
+2790:00000f003fc07fe04060fe70fcf0fcf0f9f0f9f0f3f0f3f0e7f067e07fe03fc00f0000000000000000000000
+2791:00000f003fc07fe070e0cf30cf30cf30f0f0cf30cf30cf30cf3070e07fe03fc00f0000000000000000000000
+2792:00000f003fc07fe070e0cf30cf30cf30cf30f030ff30cf30cf3070e07fe03fc00f0000000000000000000000
+2793:00000f003fc07fe04c2089908990c990c990c990c990c990c9904c207fe03fc00f0000000000000000000000
+2794:000000000000000000001e000f00078003c0ffe0fff0fff0ffe003c007800f001e0000000000000000000000
+2795:000000000000000000000000000000003c00003c00003c00003c0001ff8001ff8001ff8001ff80003c00003c00003c00003c00000000000000000000000000000000
+2796:00000000000000000000000000000000000000000000000000000001ff8001ff8001ff8001ff80000000000000000000000000000000000000000000000000000000
+2797:000000003c00003c00003c00003c0000000000000001ff8001ff8001ff8001ff80000000000000003c00003c00003c00003c00000000000000000000000000000000
+2798:0000000000000000000020007000f8007c003e001f000f9007f003f001f001f003f000000000000000000000
+2799:000000000000000000000000020003000380ffc0ffe0fff0ffe0ffc003800300020000000000000000000000
+279a:0000000000000000000003f001f001f003f007f00f901f003e007c00f8007000200000000000000000000000
+279b:000000000000000000000000000000000c000f0003c0fff003c00f000c000000000000000000000000000000
+279c:0000000000000000000006000f00078003c07fe0fff0fff07fe003c007800f00060000000000000000000000
+279d:00000000000000000000000000000100018001c001e0fff001e001c001800100000000000000000000000000
+279e:00000000000000000000000000000100018001c0ffe0fff0ffe001c001800100000000000000000000000000
+279f:00000000000000000000000000000100018001c0b7e0b7f0b7e001c001800100000000000000000000000000
+27a0:000000000000000000000000020003000380b7c0b7e0b7f0b7e0b7c003800300020000000000000000000000
+27a1:000000000000000000000000000001000180ffc0ffe0fff0ffe0ffc001800100000000000000000000000000
+27a2:000000000000000000000000c000b0004c00230010c00ff01fc03f007c00f000c00000000000000000000000
+27a3:000000000000000000000000c000f0007c003f001fc00ff010c023004c00b000c00000000000000000000000
+27a4:000000000000000000000000c000f0007c003f001fc00ff01fc03f007c00f000c00000000000000000000000
+27a5:00000000000000000000000000008100c180ffc0ffe0fff07fe03fc001800100000000000000000000000000
+27a6:0000000000000000000000000000010001803fc07fe0fff0ffe0ffc0c1808100000000000000000000000000
+27a7:0000000000000000000001800180ffc0ffc0ffe0ffe0fff0ffe0ffe0ffc0ffc0018001800000000000000000
+27a8:00000000000000000000000001000100ff80ff80ffc0fff0ffc0ff80ff800100010000000000000000000000
+27a9:000000000000000000000000000007000780fdc080e0807080e0fdc007800700000000000000000000000000
+27aa:00000000000000000000000000000f000e80fe40e020e010e020fe400e800f00000000000000000000000000
+27ab:0000000000000000000000000000004001c01e20202040108070f1f0f7e0ff803e0038000000000000000000
+27ac:000000000000000000000000000038003e00ff80f7e0f1f08070401020201e2001c000400000000000000000
+27ad:000000000000000000000000000003000280fe40802080108030fe707ee03fc0038003000000000000000000
+27ae:0000000000000000000000000000030003803fc07ee0fe70803080108020fe40028003000000000000000000
+27af:000000000000000000000000000003000280fe40402020104030fe707ee03fc0038003000000000000000000
+27b0:000000000000000000000000ff001f01fcf0003f0000ffc00303f00c00f81c003c38001c38001c3c00381f00300fc0c003ff00000000000000000000000000000000
+27b1:0000000000000000000000000000030003803fc07ee0fe70403020104020fe40028003000000000000000000
+27b2:00000f003fc07de07ce0fc70003000100000000000100030fc707ce07de03fc00f0000000000000000000000
+27b3:00000000000000000000000000000000f080a8c054e02bf054e0a8c0f0800000000000000000000000000000
+27b4:0000000000000000000020003000d8006c0036001b000d10071000b0007000f003f000000000000000000000
+27b5:000000000000000000000000000000005080a8c054e003f054e0a8c050800000000000000000000000000000
+27b6:0000000000000000000003f000f0007000b007100d101b0036006c00d8003000200000000000000000000000
+27b7:0000000000000000000030003800dc00fe007f003f001f100f1000b0007000f003f000000000000000000000
+27b8:00000000000000000000000000000000f080f8c07ce01ff07ce0f8c0f0800000000000000000000000000000
+27b9:0000000000000000000003f000f0007000b00f101f103f007f00fe00dc003800300000000000000000000000
+27ba:000000000000000000000000000000006040f8c0fce0fff0fce0f8c060400000000000000000000000000000
+27bb:00000000000000000000000000006000f040fcc0fce0fff0fce0fcc0f8406000000000000000000000000000
+27bc:0000000000000000000000000000e00078403c601ff01ff03c607840e0000000000000000000000000000000
+27bd:000000000000000000000000e000f8007c403e601ff01ff03e607c40f000e000000000000000000000000000
+27be:000000000000000000001200090004800240ff2000100010ff20024004800900120000000000000000000000
+27bf:000000000000000000000000f03f030ec0ec0700700f80f811c11c20e20e6066066066066066066066067047043883881f01f0000000000000000000000000000000
+27c0:00000000000000000000000080208040808081008200840088009000a000c000ffe000000000000000000000
+27c1:000000000000000004000a000a0011001100248024804a404a409f208020ffe0000000000000000000000000
+27c2:0000000000000000000000000000000006000600060006000600060006007fe07fe000000000000000000000
+27c3:0000000000000000000007e01fe0380060c06120612060c038001fe007e00000000000000000000000000000
+27c4:000000000000000000007e007f8001c0306048604860306001c07f807e000000000000000000000000000000
+27c5:000000001c00660063006300030003000600060006000c000c000c000c000c000c000c000e00070001e00000
+27c6:00000000038006600c600c600c000c00060006000600030003000300030003000300030007000e0078000000
+27c7:00000000000000000000000000006660666030c030c0198019800f000f000600060000000000000000000000
+27c8:00000000000000000000c0f0c3f0c7006c006c006c006c00370033f030f00000000000000000000000000000
+27c9:00000000000000000000f030fc300e3003600360036003600ec0fcc0f0c00000000000000000000000000000
+27ca:0000000000000600060006000600060006003fc0060006000600060006000600060000000000000000000000
+27cb:000000000000000000100030006000c00180030006000c00180030006000c000800000000000000000000000
+27cc:00003ff03ff018001c000c000e00060006000600060006000e000c001c001800300000000000000000000000
+27cd:00000000000000008000c0006000300018000c0006000300018000c000600030001000000000000000000000
+27ce:000000000000000000000000fff0861086108f108f1099909990b0d0b0d0e070e070fff00000000000000000
+27cf:000000000000000000000000fff0e070e070b0d0b0d0999099908f108f1086108610fff00000000000000000
+27d0:0000000000000000000006000900108020404020861086104020204010800900060000000000000000000000
+27d1:0000000000000000000000000000060006000f000f001980198030c030c06660666000000000000000000000
+27d2:000000000000000000000000000000006660666066606660666036c03fc00f00000000000000000000000000
+27d3:000000000000000000000030003000300030003000300330033000300030fff0fff000000000000000000000
+27d4:00000000000000000000fff0fff0c000c000cc00cc00c000c000c000c000c000c00000000000000000000000
+27d5:0000000000000000000000000000e01030302850249023102310249028503030e01000000000000000000000
+27d6:00000000000000000000000000008070c0c0a14092408c408c409240a140c0c0807000000000000000000000
+27d7:0000000000000000000000000000e070204030c0294026402640294030c02040e07000000000000000000000
+27d8:0000000000000600060006000600060006000600060006000600060006000600060006007fe07fe000000000
+27d9:0000000000007fe07fe006000600060006000600060006000600060006000600060006000600060000000000
+27da:00000000000000000000000019801980f9f0f9f019801980f9f0f9f019801980000000000000000000000000
+27db:0000000000000000000000001980198019801980f9f0f9f01980198019801980000000000000000000000000
+27dc:0000000000000000000000000000200050008fe08fe050002000000000000000000000000000000000000000
+27dd:000000000000000000000000c000c000c000fff0fff0c000c000c00000000000000000000000000000000000
+27de:000000000000000000000000003000300030fff0fff000300030003000000000000000000000000000000000
+27df:000000000f0010801080108010800f000600060006000600060006000600fff0fff000000000000000000000
+27e0:0600060009000900108010802040204040204020fff0fff04020402020402040108010800900090006000600
+27e1:00000000000000000000000004000a000a00110060c0802060c011000a000a00040000000000000000000000
+27e2:00000000000000000000000002000500050008803060e0103060088005000500020000000000000000000000
+27e3:00000000000000000000000004000a000a00110060c0807060c011000a000a00040000000000000000000000
+27e4:00000000000000000000000000000ff008100810f810f810081008100ff00000000000000000000000000000
+27e5:0000000000000000000000000000ff008100810081f081f081008100ff000000000000000000000000000000
+27e6:000000003fc03fc0330033003300330033003300330033003300330033003300330033003fc03fc000000000
+27e7:000000003fc03fc00cc00cc00cc00cc00cc00cc00cc00cc00cc00cc00cc00cc00cc00cc03fc03fc000000000
+27e8:000000000180018003000300060006000c000c00180018000c000c0006000600030003000180018000000000
+27e9:00000000180018000c000c0006000600030003000180018003000300060006000c000c001800180000000000
+27ea:00000000066006600cc00cc019801980330033006600660033003300198019800cc00cc00660066000000000
+27eb:000000006600660033003300198019800cc00cc0066006600cc00cc019801980330033006600660000000000
+27ec:0000000001000300050009000900090009000900090009000900090009000900090005000300010000000000
+27ed:0000000008000c000a000900090009000900090009000900090009000900090009000a000c00080000000000
+27ee:000000000200040004000c000c000c000c000c000c000c000c000c000c000c000c0004000400020000000000
+27ef:0000000008000400040006000600060006000600060006000600060006000600060004000400080000000000
+27f0:000006000900198029404920c930492049204920492049204920492049204920492000000000000000000000
+27f1:00004920492049204920492049204920492049204920c9304920294019800900060000000000000000000000
+27f2:000000000000000003800fe00c6018309930db307e303c30003018300c600fe0038000000000000000000000
+27f3:00000000000000001c007f006300c180c990cdb0c7e0c3c0c000c18063007f001c0000000000000000000000
+27f4:0000000000000000000000003800d68092409220fff092209240d68038000000000000000000000000000000
+27f5:000000000000000000000000180030006000fff0fff060003000180000000000000000000000000000000000
+27f6:000000000000000000000000018000c00060fff0fff0006000c0018000000000000000000000000000000000
+27f7:000000000000000000000000198030c06060fff0fff0606030c0198000000000000000000000000000000000
+27f8:00000000000000000000300030006ff06ff0c000c0006ff06ff0300030000000000000000000000000000000
+27f9:0000000000000000000000c000c0ff60ff6000300030ff60ff6000c000c00000000000000000000000000000
+27fa:0000000000000000000030c030c06f606f60c030c0306f606f6030c030c00000000000000000000000000000
+27fb:000000000000000000000000183030306030fff0fff060303030183000000000000000000000000000000000
+27fc:000000000000000000000000c180c0c0c060fff0fff0c060c0c0c18000000000000000000000000000000000
+27fd:00000000000000000000303030306ff06ff0c030c0306ff06ff0303030300000000000000000000000000000
+27fe:00000000000000000000c0c0c0c0ff60ff60c030c030ff60ff60c0c0c0c00000000000000000000000000000
+27ff:000000000000000000000000018000c0106028b04530826000c0018000000000000000000000000000000000
+2800:0000000000000000000000000000000000000000000000000000000000000000000000000000000000000000
+2801:0000000000003800380038000000000000000000000000000000000000000000000000000000000000000000
+2802:0000000000000000000000000000000038003800380000000000000000000000000000000000000000000000
+2803:0000000000003800380038000000000038003800380000000000000000000000000000000000000000000000
+2804:0000000000000000000000000000000000000000000000000000380038003800000000000000000000000000
+2805:0000000000003800380038000000000038003800380000000000000000000000000000000000000000000000
+2806:0000000000003800380038000000000000000000000000000000380038003800000000000000000000000000
+2807:0000000000003800380038000000000038003800380000000000380038003800000000000000000000000000
+2808:00000000000001c001c001c00000000000000000000000000000000000000000000000000000000000000000
+2809:00000000000039c039c039c00000000000000000000000000000000000000000000000000000000000000000
+280a:00000000000001c001c001c00000000038003800380000000000000000000000000000000000000000000000
+280b:00000000000039c039c039c00000000038003800380000000000000000000000000000000000000000000000
+280c:00000000000001c001c001c00000000000000000000000000000380038003800000000000000000000000000
+280d:00000000000039c039c039c00000000000000000000000000000380038003800000000000000000000000000
+280e:00000000000001c001c001c00000000038003800380000000000380038003800000000000000000000000000
+280f:00000000000039c039c039c00000000038003800380000000000380038003800000000000000000000000000
+2810:0000000000000000000000000000000001c001c001c000000000000000000000000000000000000000000000
+2811:0000000000003800380038000000000001c001c001c000000000000000000000000000000000000000000000
+2812:0000000000000000000000000000000039c039c039c000000000000000000000000000000000000000000000
+2813:0000000000003800380038000000000039c039c039c000000000000000000000000000000000000000000000
+2814:0000000000000000000000000000000001c001c001c000000000380038003800000000000000000000000000
+2815:0000000000003800380038000000000001c001c001c000000000380038003800000000000000000000000000
+2816:0000000000000000000000000000000039c039c039c000000000380038003800000000000000000000000000
+2817:0000000000003800380038000000000039c039c039c000000000380038003800000000000000000000000000
+2818:00000000000001c001c001c00000000001c001c001c000000000000000000000000000000000000000000000
+2819:00000000000039c039c039c00000000001c001c001c000000000000000000000000000000000000000000000
+281a:00000000000001c001c001c00000000039c039c039c000000000000000000000000000000000000000000000
+281b:00000000000039c039c039c00000000039c039c039c000000000000000000000000000000000000000000000
+281c:00000000000001c001c001c00000000001c001c001c000000000380038003800000000000000000000000000
+281d:00000000000039c039c039c00000000001c001c001c000000000380038003800000000000000000000000000
+281e:00000000000001c001c001c00000000039c039c039c000000000380038003800000000000000000000000000
+281f:00000000000039c039c039c00000000039c039c039c000000000380038003800000000000000000000000000
+2820:000000000000000000000000000000000000000000000000000001c001c001c0000000000000000000000000
+2821:000000000000380038003800000000000000000000000000000001c001c001c0000000000000000000000000
+2822:000000000000000000000000000000003800380038000000000001c001c001c0000000000000000000000000
+2823:000000000000380038003800000000003800380038000000000001c001c001c0000000000000000000000000
+2824:000000000000000000000000000000000000000000000000000039c039c039c0000000000000000000000000
+2825:000000000000380038003800000000000000000000000000000039c039c039c0000000000000000000000000
+2826:000000000000000000000000000000003800380038000000000039c039c039c0000000000000000000000000
+2827:000000000000380038003800000000003800380038000000000039c039c039c0000000000000000000000000
+2828:00000000000001c001c001c0000000000000000000000000000001c001c001c0000000000000000000000000
+2829:00000000000039c039c039c0000000000000000000000000000001c001c001c0000000000000000000000000
+282a:00000000000001c001c001c0000000003800380038000000000001c001c001c0000000000000000000000000
+282b:00000000000039c039c039c0000000003800380038000000000001c001c001c0000000000000000000000000
+282c:00000000000001c001c001c0000000000000000000000000000039c039c039c0000000000000000000000000
+282d:00000000000039c039c039c0000000000000000000000000000039c039c039c0000000000000000000000000
+282e:00000000000001c001c001c0000000003800380038000000000039c039c039c0000000000000000000000000
+282f:00000000000039c039c039c0000000003800380038000000000039c039c039c0000000000000000000000000
+2830:0000000000000000000000000000000001c001c001c00000000001c001c001c0000000000000000000000000
+2831:0000000000003800380038000000000001c001c001c00000000001c001c001c0000000000000000000000000
+2832:0000000000000000000000000000000039c039c039c00000000001c001c001c0000000000000000000000000
+2833:0000000000003800380038000000000039c039c039c00000000001c001c001c0000000000000000000000000
+2834:0000000000000000000000000000000001c001c001c00000000039c039c039c0000000000000000000000000
+2835:0000000000003800380038000000000001c001c001c00000000039c039c039c0000000000000000000000000
+2836:0000000000000000000000000000000039c039c039c00000000039c039c039c0000000000000000000000000
+2837:0000000000003800380038000000000039c039c039c00000000039c039c039c0000000000000000000000000
+2838:00000000000001c001c001c00000000001c001c001c00000000001c001c001c0000000000000000000000000
+2839:00000000000039c039c039c00000000001c001c001c00000000001c001c001c0000000000000000000000000
+283a:00000000000001c001c001c00000000039c039c039c00000000001c001c001c0000000000000000000000000
+283b:00000000000039c039c039c00000000039c039c039c00000000001c001c001c0000000000000000000000000
+283c:00000000000001c001c001c00000000001c001c001c00000000039c039c039c0000000000000000000000000
+283d:00000000000039c039c039c00000000001c001c001c00000000039c039c039c0000000000000000000000000
+283e:00000000000001c001c001c00000000039c039c039c00000000039c039c039c0000000000000000000000000
+283f:00000000000039c039c039c00000000039c039c039c00000000039c039c039c0000000000000000000000000
+2840:0000000000000000000000000000000000000000000000000000000000000000000000003800380038000000
+2841:0000000000003800380038000000000000000000000000000000000000000000000000003800380038000000
+2842:0000000000000000000000000000000038003800380000000000000000000000000000003800380038000000
+2843:0000000000003800380038000000000038003800380000000000000000000000000000003800380038000000
+2844:0000000000000000000000000000000000000000000000000000380038003800000000003800380038000000
+2845:0000000000003800380038000000000038003800380000000000000000000000000000003800380038000000
+2846:0000000000003800380038000000000000000000000000000000380038003800000000003800380038000000
+2847:0000000000003800380038000000000038003800380000000000380038003800000000003800380038000000
+2848:00000000000001c001c001c00000000000000000000000000000000000000000000000003800380038000000
+2849:00000000000039c039c039c00000000000000000000000000000000000000000000000003800380038000000
+284a:00000000000001c001c001c00000000038003800380000000000000000000000000000003800380038000000
+284b:00000000000039c039c039c00000000038003800380000000000000000000000000000003800380038000000
+284c:00000000000001c001c001c00000000000000000000000000000380038003800000000003800380038000000
+284d:00000000000039c039c039c00000000000000000000000000000380038003800000000003800380038000000
+284e:00000000000001c001c001c00000000038003800380000000000380038003800000000003800380038000000
+284f:00000000000039c039c039c00000000038003800380000000000380038003800000000003800380038000000
+2850:0000000000000000000000000000000001c001c001c000000000000000000000000000003800380038000000
+2851:0000000000003800380038000000000001c001c001c000000000000000000000000000003800380038000000
+2852:0000000000000000000000000000000039c039c039c000000000000000000000000000003800380038000000
+2853:0000000000003800380038000000000039c039c039c000000000000000000000000000003800380038000000
+2854:0000000000000000000000000000000001c001c001c000000000380038003800000000003800380038000000
+2855:0000000000003800380038000000000001c001c001c000000000380038003800000000003800380038000000
+2856:0000000000000000000000000000000039c039c039c000000000380038003800000000003800380038000000
+2857:0000000000003800380038000000000039c039c039c000000000380038003800000000003800380038000000
+2858:00000000000001c001c001c00000000001c001c001c000000000000000000000000000003800380038000000
+2859:00000000000039c039c039c00000000001c001c001c000000000000000000000000000003800380038000000
+285a:00000000000001c001c001c00000000039c039c039c000000000000000000000000000003800380038000000
+285b:00000000000039c039c039c00000000039c039c039c000000000000000000000000000003800380038000000
+285c:00000000000001c001c001c00000000001c001c001c000000000380038003800000000003800380038000000
+285d:00000000000039c039c039c00000000001c001c001c000000000380038003800000000003800380038000000
+285e:00000000000001c001c001c00000000039c039c039c000000000380038003800000000003800380038000000
+285f:00000000000039c039c039c00000000039c039c039c000000000380038003800000000003800380038000000
+2860:000000000000000000000000000000000000000000000000000001c001c001c0000000003800380038000000
+2861:000000000000380038003800000000000000000000000000000001c001c001c0000000003800380038000000
+2862:000000000000000000000000000000003800380038000000000001c001c001c0000000003800380038000000
+2863:000000000000380038003800000000003800380038000000000001c001c001c0000000003800380038000000
+2864:000000000000000000000000000000000000000000000000000039c039c039c0000000003800380038000000
+2865:000000000000380038003800000000000000000000000000000039c039c039c0000000003800380038000000
+2866:000000000000000000000000000000003800380038000000000039c039c039c0000000003800380038000000
+2867:000000000000380038003800000000003800380038000000000039c039c039c0000000003800380038000000
+2868:00000000000001c001c001c0000000000000000000000000000001c001c001c0000000003800380038000000
+2869:00000000000039c039c039c0000000000000000000000000000001c001c001c0000000003800380038000000
+286a:00000000000001c001c001c0000000003800380038000000000001c001c001c0000000003800380038000000
+286b:00000000000039c039c039c0000000003800380038000000000001c001c001c0000000003800380038000000
+286c:00000000000001c001c001c0000000000000000000000000000039c039c039c0000000003800380038000000
+286d:00000000000039c039c039c0000000000000000000000000000039c039c039c0000000003800380038000000
+286e:00000000000001c001c001c0000000003800380038000000000039c039c039c0000000003800380038000000
+286f:00000000000039c039c039c0000000003800380038000000000039c039c039c0000000003800380038000000
+2870:0000000000000000000000000000000001c001c001c00000000001c001c001c0000000003800380038000000
+2871:0000000000003800380038000000000001c001c001c00000000001c001c001c0000000003800380038000000
+2872:0000000000000000000000000000000039c039c039c00000000001c001c001c0000000003800380038000000
+2873:0000000000003800380038000000000039c039c039c00000000001c001c001c0000000003800380038000000
+2874:0000000000000000000000000000000001c001c001c00000000039c039c039c0000000003800380038000000
+2875:0000000000003800380038000000000001c001c001c00000000039c039c039c0000000003800380038000000
+2876:0000000000000000000000000000000039c039c039c00000000039c039c039c0000000003800380038000000
+2877:0000000000003800380038000000000039c039c039c00000000039c039c039c0000000003800380038000000
+2878:00000000000001c001c001c00000000001c001c001c00000000001c001c001c0000000003800380038000000
+2879:00000000000039c039c039c00000000001c001c001c00000000001c001c001c0000000003800380038000000
+287a:00000000000001c001c001c00000000039c039c039c00000000001c001c001c0000000003800380038000000
+287b:00000000000039c039c039c00000000039c039c039c00000000001c001c001c0000000003800380038000000
+287c:00000000000001c001c001c00000000001c001c001c00000000039c039c039c0000000003800380038000000
+287d:00000000000039c039c039c00000000001c001c001c00000000039c039c039c0000000003800380038000000
+287e:00000000000001c001c001c00000000039c039c039c00000000039c039c039c0000000003800380038000000
+287f:00000000000039c039c039c00000000039c039c039c00000000039c039c039c0000000003800380038000000
+2880:00000000000000000000000000000000000000000000000000000000000000000000000001c001c001c00000
+2881:00000000000038003800380000000000000000000000000000000000000000000000000001c001c001c00000
+2882:00000000000000000000000000000000380038003800000000000000000000000000000001c001c001c00000
+2883:00000000000038003800380000000000380038003800000000000000000000000000000001c001c001c00000
+2884:00000000000000000000000000000000000000000000000000003800380038000000000001c001c001c00000
+2885:00000000000038003800380000000000380038003800000000000000000000000000000001c001c001c00000
+2886:00000000000038003800380000000000000000000000000000003800380038000000000001c001c001c00000
+2887:00000000000038003800380000000000380038003800000000003800380038000000000001c001c001c00000
+2888:00000000000001c001c001c000000000000000000000000000000000000000000000000001c001c001c00000
+2889:00000000000039c039c039c000000000000000000000000000000000000000000000000001c001c001c00000
+288a:00000000000001c001c001c000000000380038003800000000000000000000000000000001c001c001c00000
+288b:00000000000039c039c039c000000000380038003800000000000000000000000000000001c001c001c00000
+288c:00000000000001c001c001c000000000000000000000000000003800380038000000000001c001c001c00000
+288d:00000000000039c039c039c000000000000000000000000000003800380038000000000001c001c001c00000
+288e:00000000000001c001c001c000000000380038003800000000003800380038000000000001c001c001c00000
+288f:00000000000039c039c039c000000000380038003800000000003800380038000000000001c001c001c00000
+2890:0000000000000000000000000000000001c001c001c0000000000000000000000000000001c001c001c00000
+2891:0000000000003800380038000000000001c001c001c0000000000000000000000000000001c001c001c00000
+2892:0000000000000000000000000000000039c039c039c0000000000000000000000000000001c001c001c00000
+2893:0000000000003800380038000000000039c039c039c0000000000000000000000000000001c001c001c00000
+2894:0000000000000000000000000000000001c001c001c0000000003800380038000000000001c001c001c00000
+2895:0000000000003800380038000000000001c001c001c0000000003800380038000000000001c001c001c00000
+2896:0000000000000000000000000000000039c039c039c0000000003800380038000000000001c001c001c00000
+2897:0000000000003800380038000000000039c039c039c0000000003800380038000000000001c001c001c00000
+2898:00000000000001c001c001c00000000001c001c001c0000000000000000000000000000001c001c001c00000
+2899:00000000000039c039c039c00000000001c001c001c0000000000000000000000000000001c001c001c00000
+289a:00000000000001c001c001c00000000039c039c039c0000000000000000000000000000001c001c001c00000
+289b:00000000000039c039c039c00000000039c039c039c0000000000000000000000000000001c001c001c00000
+289c:00000000000001c001c001c00000000001c001c001c0000000003800380038000000000001c001c001c00000
+289d:00000000000039c039c039c00000000001c001c001c0000000003800380038000000000001c001c001c00000
+289e:00000000000001c001c001c00000000039c039c039c0000000003800380038000000000001c001c001c00000
+289f:00000000000039c039c039c00000000039c039c039c0000000003800380038000000000001c001c001c00000
+28a0:000000000000000000000000000000000000000000000000000001c001c001c00000000001c001c001c00000
+28a1:000000000000380038003800000000000000000000000000000001c001c001c00000000001c001c001c00000
+28a2:000000000000000000000000000000003800380038000000000001c001c001c00000000001c001c001c00000
+28a3:000000000000380038003800000000003800380038000000000001c001c001c00000000001c001c001c00000
+28a4:000000000000000000000000000000000000000000000000000039c039c039c00000000001c001c001c00000
+28a5:000000000000380038003800000000000000000000000000000039c039c039c00000000001c001c001c00000
+28a6:000000000000000000000000000000003800380038000000000039c039c039c00000000001c001c001c00000
+28a7:000000000000380038003800000000003800380038000000000039c039c039c00000000001c001c001c00000
+28a8:00000000000001c001c001c0000000000000000000000000000001c001c001c00000000001c001c001c00000
+28a9:00000000000039c039c039c0000000000000000000000000000001c001c001c00000000001c001c001c00000
+28aa:00000000000001c001c001c0000000003800380038000000000001c001c001c00000000001c001c001c00000
+28ab:00000000000039c039c039c0000000003800380038000000000001c001c001c00000000001c001c001c00000
+28ac:00000000000001c001c001c0000000000000000000000000000039c039c039c00000000001c001c001c00000
+28ad:00000000000039c039c039c0000000000000000000000000000039c039c039c00000000001c001c001c00000
+28ae:00000000000001c001c001c0000000003800380038000000000039c039c039c00000000001c001c001c00000
+28af:00000000000039c039c039c0000000003800380038000000000039c039c039c00000000001c001c001c00000
+28b0:0000000000000000000000000000000001c001c001c00000000001c001c001c00000000001c001c001c00000
+28b1:0000000000003800380038000000000001c001c001c00000000001c001c001c00000000001c001c001c00000
+28b2:0000000000000000000000000000000039c039c039c00000000001c001c001c00000000001c001c001c00000
+28b3:0000000000003800380038000000000039c039c039c00000000001c001c001c00000000001c001c001c00000
+28b4:0000000000000000000000000000000001c001c001c00000000039c039c039c00000000001c001c001c00000
+28b5:0000000000003800380038000000000001c001c001c00000000039c039c039c00000000001c001c001c00000
+28b6:0000000000000000000000000000000039c039c039c00000000039c039c039c00000000001c001c001c00000
+28b7:0000000000003800380038000000000039c039c039c00000000039c039c039c00000000001c001c001c00000
+28b8:00000000000001c001c001c00000000001c001c001c00000000001c001c001c00000000001c001c001c00000
+28b9:00000000000039c039c039c00000000001c001c001c00000000001c001c001c00000000001c001c001c00000
+28ba:00000000000001c001c001c00000000039c039c039c00000000001c001c001c00000000001c001c001c00000
+28bb:00000000000039c039c039c00000000039c039c039c00000000001c001c001c00000000001c001c001c00000
+28bc:00000000000001c001c001c00000000001c001c001c00000000039c039c039c00000000001c001c001c00000
+28bd:00000000000039c039c039c00000000001c001c001c00000000039c039c039c00000000001c001c001c00000
+28be:00000000000001c001c001c00000000039c039c039c00000000039c039c039c00000000001c001c001c00000
+28bf:00000000000039c039c039c00000000039c039c039c00000000039c039c039c00000000001c001c001c00000
+28c0:00000000000000000000000000000000000000000000000000000000000000000000000039c039c039c00000
+28c1:00000000000038003800380000000000000000000000000000000000000000000000000039c039c039c00000
+28c2:00000000000000000000000000000000380038003800000000000000000000000000000039c039c039c00000
+28c3:00000000000038003800380000000000380038003800000000000000000000000000000039c039c039c00000
+28c4:00000000000000000000000000000000000000000000000000003800380038000000000039c039c039c00000
+28c5:00000000000038003800380000000000380038003800000000000000000000000000000039c039c039c00000
+28c6:00000000000038003800380000000000000000000000000000003800380038000000000039c039c039c00000
+28c7:00000000000038003800380000000000380038003800000000003800380038000000000039c039c039c00000
+28c8:00000000000001c001c001c000000000000000000000000000000000000000000000000039c039c039c00000
+28c9:00000000000039c039c039c000000000000000000000000000000000000000000000000039c039c039c00000
+28ca:00000000000001c001c001c000000000380038003800000000000000000000000000000039c039c039c00000
+28cb:00000000000039c039c039c000000000380038003800000000000000000000000000000039c039c039c00000
+28cc:00000000000001c001c001c000000000000000000000000000003800380038000000000039c039c039c00000
+28cd:00000000000039c039c039c000000000000000000000000000003800380038000000000039c039c039c00000
+28ce:00000000000001c001c001c000000000380038003800000000003800380038000000000039c039c039c00000
+28cf:00000000000039c039c039c000000000380038003800000000003800380038000000000039c039c039c00000
+28d0:0000000000000000000000000000000001c001c001c0000000000000000000000000000039c039c039c00000
+28d1:0000000000003800380038000000000001c001c001c0000000000000000000000000000039c039c039c00000
+28d2:0000000000000000000000000000000039c039c039c0000000000000000000000000000039c039c039c00000
+28d3:0000000000003800380038000000000039c039c039c0000000000000000000000000000039c039c039c00000
+28d4:0000000000000000000000000000000001c001c001c0000000003800380038000000000039c039c039c00000
+28d5:0000000000003800380038000000000001c001c001c0000000003800380038000000000039c039c039c00000
+28d6:0000000000000000000000000000000039c039c039c0000000003800380038000000000039c039c039c00000
+28d7:0000000000003800380038000000000039c039c039c0000000003800380038000000000039c039c039c00000
+28d8:00000000000001c001c001c00000000001c001c001c0000000000000000000000000000039c039c039c00000
+28d9:00000000000039c039c039c00000000001c001c001c0000000000000000000000000000039c039c039c00000
+28da:00000000000001c001c001c00000000039c039c039c0000000000000000000000000000039c039c039c00000
+28db:00000000000039c039c039c00000000039c039c039c0000000000000000000000000000039c039c039c00000
+28dc:00000000000001c001c001c00000000001c001c001c0000000003800380038000000000039c039c039c00000
+28dd:00000000000039c039c039c00000000001c001c001c0000000003800380038000000000039c039c039c00000
+28de:00000000000001c001c001c00000000039c039c039c0000000003800380038000000000039c039c039c00000
+28df:00000000000039c039c039c00000000039c039c039c0000000003800380038000000000039c039c039c00000
+28e0:000000000000000000000000000000000000000000000000000001c001c001c00000000039c039c039c00000
+28e1:000000000000380038003800000000000000000000000000000001c001c001c00000000039c039c039c00000
+28e2:000000000000000000000000000000003800380038000000000001c001c001c00000000039c039c039c00000
+28e3:000000000000380038003800000000003800380038000000000001c001c001c00000000039c039c039c00000
+28e4:000000000000000000000000000000000000000000000000000039c039c039c00000000039c039c039c00000
+28e5:000000000000380038003800000000000000000000000000000039c039c039c00000000039c039c039c00000
+28e6:000000000000000000000000000000003800380038000000000039c039c039c00000000039c039c039c00000
+28e7:000000000000380038003800000000003800380038000000000039c039c039c00000000039c039c039c00000
+28e8:00000000000001c001c001c0000000000000000000000000000001c001c001c00000000039c039c039c00000
+28e9:00000000000039c039c039c0000000000000000000000000000001c001c001c00000000039c039c039c00000
+28ea:00000000000001c001c001c0000000003800380038000000000001c001c001c00000000039c039c039c00000
+28eb:00000000000039c039c039c0000000003800380038000000000001c001c001c00000000039c039c039c00000
+28ec:00000000000001c001c001c0000000000000000000000000000039c039c039c00000000039c039c039c00000
+28ed:00000000000039c039c039c0000000000000000000000000000039c039c039c00000000039c039c039c00000
+28ee:00000000000001c001c001c0000000003800380038000000000039c039c039c00000000039c039c039c00000
+28ef:00000000000039c039c039c0000000003800380038000000000039c039c039c00000000039c039c039c00000
+28f0:0000000000000000000000000000000001c001c001c00000000001c001c001c00000000039c039c039c00000
+28f1:0000000000003800380038000000000001c001c001c00000000001c001c001c00000000039c039c039c00000
+28f2:0000000000000000000000000000000039c039c039c00000000001c001c001c00000000039c039c039c00000
+28f3:0000000000003800380038000000000039c039c039c00000000001c001c001c00000000039c039c039c00000
+28f4:0000000000000000000000000000000001c001c001c00000000039c039c039c00000000039c039c039c00000
+28f5:0000000000003800380038000000000001c001c001c00000000039c039c039c00000000039c039c039c00000
+28f6:0000000000000000000000000000000039c039c039c00000000039c039c039c00000000039c039c039c00000
+28f7:0000000000003800380038000000000039c039c039c00000000039c039c039c00000000039c039c039c00000
+28f8:00000000000001c001c001c00000000001c001c001c00000000001c001c001c00000000039c039c039c00000
+28f9:00000000000039c039c039c00000000001c001c001c00000000001c001c001c00000000039c039c039c00000
+28fa:00000000000001c001c001c00000000039c039c039c00000000001c001c001c00000000039c039c039c00000
+28fb:00000000000039c039c039c00000000039c039c039c00000000001c001c001c00000000039c039c039c00000
+28fc:00000000000001c001c001c00000000001c001c001c00000000039c039c039c00000000039c039c039c00000
+28fd:00000000000039c039c039c00000000001c001c001c00000000039c039c039c00000000039c039c039c00000
+28fe:00000000000001c001c001c00000000039c039c039c00000000039c039c039c00000000039c039c039c00000
+28ff:00000000000039c039c039c00000000039c039c039c00000000039c039c039c00000000039c039c039c00000
+2900:0000000000000000000000000000248022402120fff0fff02120224024800000000000000000000000000000
+2901:0000000000000000000000000000548052405120fff0fff05120524054800000000000000000000000000000
+2902:00000000000000000000318031806ff06ff0c180c1806ff06ff0318031800000000000000000000000000000
+2903:0000000000000000000018c018c0ff60ff6018301830ff60ff6018c018c00000000000000000000000000000
+2904:00000000000000000000264026407fe07fe0c630c6307fe07fe0264026400000000000000000000000000000
+2905:0000000000000000000000000000c480c240c120fff0fff0c120c240c4800000000000000000000000000000
+2906:00000000000000000000303030306ff06ff0c030c0306ff06ff0303030300000000000000000000000000000
+2907:00000000000000000000c0c0c0c0ff60ff60c030c030ff60ff60c0c0c0c00000000000000000000000000000
+2908:0000000006000600060006007fe07fe00600060006000600666036c01f800f00060000000000000000000000
+2909:0000000006000f001f8036c0666006000600060006007fe07fe0060006000600060000000000000000000000
+290a:0000000006000f001f8036c06660e67036c036c036c036c036c036c036c036c036c000000000000000000000
+290b:0000000036c036c036c036c036c036c036c036c036c0e670666036c01f800f00060000000000000000000000
+290c:000000000000000000000000180030006000f9f0f9f060003000180000000000000000000000000000000000
+290d:000000000000000000000000018000c00060f9f0f9f0006000c0018000000000000000000000000000000000
+290e:000000000000000000000000180030006000f770f77060003000180000000000000000000000000000000000
+290f:000000000000000000000000018000c00060eef0eef0006000c0018000000000000000000000000000000000
+2910:0000000000000000000000000000048002400120db70db700120024004800000000000000000000000000000
+2911:000000000000000000000000018000c00060aab0aab0006000c0018000000000000000000000000000000000
+2912:00000000fff0fff006000f001f8036c066600600060006000600060006000600060000000000000000000000
+2913:0000000006000600060006000600060006000600666036c01f800f000600fff0fff000000000000000000000
+2914:00000000000000000000000000008480444024201ff01ff02420444084800000000000000000000000000000
+2915:00000000000000000000000000008a804a402a201ff01ff02a204a408a800000000000000000000000000000
+2916:00000000000000000000000000008480424021201ff01ff02120424084800000000000000000000000000000
+2917:00000000000000000000000000008a80494028a01ff01ff028a049408a800000000000000000000000000000
+2918:0000000000000000000000000000954054a034503ff03ff0345054a095400000000000000000000000000000
+2919:0000000000000000000000000030006000c0ff80ff8000c00060003000000000000000000000000000000000
+291a:000000000000000000000000c000600030001ff01ff030006000c00000000000000000000000000000000000
+291b:000000000000000000000000009001200240ff80ff8002400120009000000000000000000000000000000000
+291c:0000000000000000000000009000480024001ff01ff024004800900000000000000000000000000000000000
+291d:000000000000000000000000018003004600eff0eff046000300018000000000000000000000000000000000
+291e:00000000000000000000000018000c000620ff70ff7006200c00180000000000000000000000000000000000
+291f:000000000000000000000000019003104610eff0eff046100310019000000000000000000000000000000000
+2920:00000000000000000000000098008c008620ff70ff7086208c00980000000000000000000000000000000000
+2921:000000000000000000000000fc00fc00f000d800cc00c630033001b000f003f003f000000000000000000000
+2922:00000000000000000000000003f003f000f001b00330c630cc00d800f000fc00fc0000000000000000000000
+2923:000000000000000000000000fc00fc00f000d800cc00c600030001800cc007c0038000000000000000000000
+2924:00000000000000000000000007e007e001e0036006600c601800300066007c00380000000000000000000000
+2925:00000000000000000000000038007c006600300018000c600660036001e007e007e000000000000000000000
+2926:00000000000000000000000001c003e0066000c00180630066006c0078007e007e0000000000000000000000
+2927:000000000000000000000000f9f0e070f0f0d9b0cf3006000f00198030c06060c03000000000000000000000
+2928:000000000000000001f00070c0f061b033301e300c001e00333061b0c0f0007001f000000000000000000000
+2929:000000000000000000000000c030606030c019800f000600cf30d9b0f0f0e070f9f000000000000000000000
+292a:0000000000000000f800e000f030d860ccc0c78003000780ccc0d860f030e000f80000000000000000000000
+292b:000000000000000000000000c030606030c01980030006000c00198030c06060c03000000000000000000000
+292c:000000000000000000000000c030606030c019800c0006000300198030c06060c03000000000000000000000
+292d:000000000000000001f00070c0f061b0333018300c000600333061b0c0f0007001f000000000000000000000
+292e:000000000000000001f00070c0f061b0333006300c001800333061b0c0f0007001f000000000000000000000
+292f:0000000000000000000001f00070c0f061b0333018300c00060033006180c0c0006000000000000000000000
+2930:000000000000000000000060c0c06180330006000c001830333061b0c0f0007001f000000000000000000000
+2931:000000000000000000000000f9f0e070f0f0d9b0c33006000c00198030c06060c03000000000000000000000
+2932:000000000000000000000000f9f0e070f0f0d9b0cc3006000300198030c06060c03000000000000000000000
+2933:00000000000000000000000001801cc03660e3f0c1f0006000c0018000000000000000000000000000000000
+2934:000000000000030007800fc01b6033300300030003000300030003000600fe00f80000000000000000000000
+2935:000000000000f800fe00060003000300030003000300030033301b600fc00780030000000000000000000000
+2936:000000000000000000300030003000300030183030306060ffe0ff8060003000180000000000000000000000
+2937:0000000000000000c000c000c000c000c000c180c0c060607ff01ff0006000c0018000000000000000000000
+2938:0000000000000300018000c000c000600060006000600060186018c019801e001f8000000000000000000000
+2939:0000000000000c001800300030006000600060006000600061803180198007801f8000000000000000000000
+293a:00000000000000000000000007c00fe04c70783078307c307e00000000000000000000000000000000000000
+293b:00000000000000000000000003f061f060f060f071903f801f00000000000000000000000000000000000000
+293c:0000000000000000000000003e007f00e320c1e0c1e0c3e007e0000000001f801f8000000000000000000000
+293d:0000000000003e007f00e320c1e0c1e0c3e007e00000060006001f801f800600060000000000000000000000
+293e:0000000000000000000000000000018000c000c0fc60f860f060f06098e01fc00f8000000000000000000000
+293f:000000000000000000000000000018003000300063f061f060f060f071903f801f0000000000000000000000
+2940:00000000000000001c007f006300c180c180c3c0c7e0cdb0c990c18063007f001c0000000000000000000000
+2941:000000000000000003800fe00c60183018303c307e30db30993018300c600fe0038000000000000000000000
+2942:000000000000018000c00060fff0fff0006000c0198030006000fe00fe006000300018000000000000000000
+2943:000000000000180030006000fff0fff060003000198000c0006007f007f0006000c001800000000000000000
+2944:000000000000018000c0006007f007f0006000c0198030006000fff0fff06000300018000000000000000000
+2945:00000000000000000000018000c00060fff0fff0006030c03180fc00fc003000300000000000000000000000
+2946:00000000000000000000180030006000fff0fff0600030c018c003f003f000c000c000000000000000000000
+2947:00000000000000000000000000000000858048c03060fff0fff0306048c08580000000000000000000000000
+2948:0000000000000000000000000000000020804e409120fff0fff091204e402080000000000000000000000000
+2949:000006000f001f8036c066600f001f8036c06660060006000f001f8030c030c030c01f800f00000000000000
+294a:000000000000000000000000000000000c00180030007fe0ffc0018003000600000000000000000000000000
+294b:00000000000000000000000000000000060003000180ffc07fe0300018000c00000000000000000000000000
+294c:00000000040006000700078006c00660060006000600660036001e000e000600020000000000000000000000
+294d:00000000020006000e001e0036006600060006000600066006c0078007000600040000000000000000000000
+294e:00000000000000000000000000000000198030c06060fff0fff0000000000000000000000000000000000000
+294f:00000000040006000700078006c00660060006000600066006c0078007000600040000000000000000000000
+2950:00000000000000000000000000000000000000000000fff0fff0606030c01980000000000000000000000000
+2951:00000000020006000e001e0036006600060006000600660036001e000e000600020000000000000000000000
+2952:00000000000000000000000000000000c300c600cc00dff0fff0c000c000c000000000000000000000000000
+2953:000000000000000000000000000000000c3006300330ffb0fff0003000300030000000000000000000000000
+2954:000000007fe07fe0040006000700078006c00660060006000600060006000600060000000000000000000000
+2955:000000000600060006000600060006000600066006c007800700060004007fe07fe000000000000000000000
+2956:00000000000000000000000000000000c000c000c000fff0dff0cc00c600c300000000000000000000000000
+2957:00000000000000000000000000000000003000300030fff0ffb0033006300c30000000000000000000000000
+2958:000000007fe07fe0020006000e001e0036006600060006000600060006000600060000000000000000000000
+2959:000000000600060006000600060006000600660036001e000e00060002007fe07fe000000000000000000000
+295a:000000000000000000000000000000000c30183030307ff0fff0003000300030000000000000000000000000
+295b:00000000000000000000000000000000c300c180c0c0ffe0fff0c000c000c000000000000000000000000000
+295c:00000000040006000700078006c0066006000600060006000600060006007fe07fe000000000000000000000
+295d:000000007fe07fe00600060006000600060006000600066006c0078007000600040000000000000000000000
+295e:00000000000000000000000000000000003000300030fff07ff0303018300c30000000000000000000000000
+295f:00000000000000000000000000000000c000c000c000fff0ffe0c0c0c180c300000000000000000000000000
+2960:00000000020006000e001e003600660006000600060006000600060006007fe07fe000000000000000000000
+2961:000000007fe07fe00600060006000600060006000600660036001e000e000600020000000000000000000000
+2962:00000000000000000c00180030007fe0ffe000000000ffe07fe0300018000c00000000000000000000000000
+2963:0000000000000900198039c079e0d9b019801980198019801980198019801980198000000000000000000000
+2964:0000000000000000060003000180ffc0ffe000000000ffe0ffc0018003000600000000000000000000000000
+2965:000000000000198019801980198019801980198019801980d9b079e039c01980090000000000000000000000
+2966:00000000000000000c00180030007fe0ffe00000060003000180ffc0ffe00000000000000000000000000000
+2967:0000000000000000ffe07fe0300018000c000000ffe0ffc00180030006000000000000000000000000000000
+2968:0000000000000000060003000180ffc0ffe000000c00180030007fe0ffe00000000000000000000000000000
+2969:0000000000000000ffe0ffc00180030006000000ffe07fe0300018000c000000000000000000000000000000
+296a:0000000000000000000000000c00180030007fe0ffe000000000ffe0ffe00000000000000000000000000000
+296b:000000000000000000000000ffe0ffe000000000ffe07fe0300018000c000000000000000000000000000000
+296c:000000000000000000000000060003000180ffc0ffe000000000ffe0ffe00000000000000000000000000000
+296d:000000000000000000000000ffe0ffe000000000ffe0ffc00180030006000000000000000000000000000000
+296e:0000000000000980198039807980d980198019801980198019b019e019c01980190000000000000000000000
+296f:0000000000001900198019c019e019b01980198019801980d980798039801980098000000000000000000000
+2970:00000000000000000000000000000000ffe0fff000300030fff0ffe000000000000000000000000000000000
+2971:00000000000000007c007c00000000007c007d8000c00060fff0fff0006000c0018000000000000000000000
+2972:00000000000000001c203e6067c043800000018000c00060fff0fff0006000c0018000000000000000000000
+2973:0000000000000000180030006000fff0fff060003000180000001c203e6067c0438000000000000000000000
+2974:0000000000000000018000c00060fff0fff0006000c0018000001c203e6067c0438000000000000000000000
+2975:0000018000c00060fff0fff0006000c0018000001c203e6067c043801c203e6067c043800000000000000000
+2976:000000000000007003c01e00f0001e0003c0187030006000fff0fff060003000180000000000000000000000
+2977:0000000000000000000000000000003018e033806e00fff0fff06e00338018e0003000000000000000000000
+2978:000000000000e0003c00078000f007803c00e18000c00060fff0fff0006000c0018000000000000000000000
+2979:00001fe03fe07000600070003fe01fe00000018000c00060fff0fff0006000c0018000000000000000000000
+297a:00000000000000f001f00300130026004600fff0fff0460026001300030001f000f000000000000000000000
+297b:00007f807fc000e0006000e07fc07f800000180030006000fff0fff060003000180000000000000000000000
+297c:0000000000000000000038007000c00078001ff01ff07800c000700038000000000000000000000000000000
+297d:0000000000000000000001c000e0003001e0ff80ff8001e0003000e001c00000000000000000000000000000
+297e:000000000000108039c069606f604f2006000600060006000600060006000600060000000000000000000000
+297f:0000000000000600060006000600060006000600060006004f206f60696039c0108000000000000000000000
+2980:0000000066606660666066606660666066606660666066606660666066606660666000000000000000000000
+2981:00000000000000000000000000000f003fc03fc03fc03fc03fc00f0000000000000000000000000000000000
+2982:00000000000000000e003180318031800e00000000000e003180318031800e00000000000000000000000000
+2983:000000001fe031803180198019801980318071803180198019801980318031801fe000000000000000000000
+2984:000000007f8018c018c019801980198018c018e018c019801980198018c018c07f8000000000000000000000
+2985:0000000001e006c00dc01980198033003300330033003300198019800dc006c001e000000000000000000000
+2986:00000000780036003b00198019800cc00cc00cc00cc00cc0198019803b003600780000000000000000000000
+2987:0000000001c006c00cc018c018c030c030c030c030c030c018c018c00cc006c001c000000000000000000000
+2988:000000003800360033003180318030c030c030c030c030c03180318033003600380000000000000000000000
+2989:0000000000c001c003c006c00cc018c030c060c030c018c00cc006c003c001c000c000000000000000000000
+298a:00000000300038003c0036003300318030c0306030c03180330036003c003800300000000000000000000000
+298b:0000000007c007c00600060006000600060006000600060006000600060007c007c0000007c007c000000000
+298c:000000003e003e00060006000600060006000600060006000600060006003e003e0000003e003e0000000000
+298d:0000000007c007c00700078006c00660060006000600060006000600060007c007c000000000000000000000
+298e:000000003e003e000600060006000600060006000600660036001e000e003e003e0000000000000000000000
+298f:0000000007c007c00600060006000600060006000600066006c00780070007c007c000000000000000000000
+2990:000000003e003e000e001e003600660006000600060006000600060006003e003e0000000000000000000000
+2991:000000000600060006000c000c000c00188019c018800c000c000c0006000600060000000000000000000000
+2992:0000000006000600060003000300030011803980118003000300030006000600060000000000000000000000
+2993:00000000000001800300063004c00b000c003800c80038000c000b0004c00630030001800000000000000000
+2994:00000000000018000c00c60032000d00030001c0013001c003000d003200c6000c0018000000000000000000
+2995:00000000000000000d80db0036006c006f00d8c0d830d8c06f006c003600db000d8000000000000000000000
+2996:00000000000000001b000db006c003600f6031b0c1b031b00f60036006c00db01b0000000000000000000000
+2997:0000000000c003800e003c003c003c003c003c003c003c003c003c000e00038000c000000000000000000000
+2998:0000000030001c00070003c003c003c003c003c003c003c003c003c007001c00300000000000000000000000
+2999:00000000000006000f000600000006000f000600000006000f000600000006000f0006000000000000000000
+299a:0000000006000c0018000c0006000c0018000c0006000c0018000c0006000c00180000000000000000000000
+299b:00000000000000008000c060618032001c000c000e001300118020c02060fff0fff040004000000000000000
+299c:00000000000000000000c000c000c000c000ff00c100c100c100c100c100fff0fff000000000000000000000
+299d:00000000000000000000c000c000c000c000f800c400c200d900d900c100fff0fff000000000000000000000
+299e:00000000000000000000006000c00180030006700c801860301060e0c000fff0fff000000000000000000000
+299f:00000000000000000000006000c00180030006000c00180030006000c000fff0fff000000000000000000000
+29a0:00000000000003000c00d80030003c00330060c0603060c033003c003000d8000c0003000000000000000000
+29a1:00000000000000000000c030cfb070e06060b0d0b0d0198019800f000f000600060000000000000000000000
+29a2:00000000000000000000fff0fff00030006000c00180030006000c0018003000600000000000000000000000
+29a3:000000000000000000006000300018000c0006000300018000c000600030fff0fff000000000000000000000
+29a4:00000000006000c00180030006000c00180030006000c000fff0fff00000fff0fff000000000000000000000
+29a5:000000006000300018000c0006000300018000c000600030fff0fff00000fff0fff000000000000000000000
+29a6:000000000000000000000000000000008000c0006000300018000c0007f003f0000000000000000000000000
+29a7:0000000000000000000000000000000003f007f00c00180030006000c0008000000000000000000000000000
+29a8:000000000fc01fc003c066c036c01c800e001b001980318030c060c060c0fff0fff000c000c0000000000000
+29a9:000000003f003f803c00366036c0138007000d80198018c030c030603060fff0fff030003000000000000000
+29aa:0000000000c000c0fff0fff060c060c030c0318019801b000e001c8036c066c003c01fc00fc0000000000000
+29ab:0000000030003000fff0fff03060306030c018c019800d800700138036c036603c003f803f00000000000000
+29ac:00000000000000000000c000c000c000c1f0f070dcf0c790c390c780ccc0d860f060e0000000000000000000
+29ad:00000000000000000000003000300030f830e0f0f3b09e309c301e30333061b060f000700000000000000000
+29ae:00000000000000000000e000f060d860ccc0c780c390c790dcf0f070c1f0c000c000c0000000000000000000
+29af:00000000000000000000007060f061b033301e309c309e30f3b0e0f0f8300030003000300000000000000000
+29b0:00000000000000000e00b180404060409020882084208220812040c0404031a00e0000000000000000000000
+29b1:00000000ffe000000e0031a0404040c08120822084208820902060404040b1800e0000000000000000000000
+29b2:0e00110011000e000e0031a0404040c08120822084208820902060404040b1800e0000000000000000000000
+29b3:00800040ffe000400e8031a0404040c08120822084208820902060404040b1800e0000000000000000000000
+29b4:20004000ffe040002e0031a0404040c08120822084208820902060404040b1800e0000000000000000000000
+29b5:00000000000000000e0031804040404080208020ffe0802080204040404031800e0000000000000000000000
+29b6:00000000000000000e00358044404440842084208420842084204440444035800e0000000000000000000000
+29b7:00000000000000000e00318040405140912091209120912091205140404031800e0000000000000000000000
+29b8:00000000000000000e003180404060409020882084208220812040c0404031800e0000000000000000000000
+29b9:00000000000000000e003180404044408420842084208420bfa04040404031800e0000000000000000000000
+29ba:00000000000000000e0035804440444084208420ffe0802080204040404031800e0000000000000000000000
+29bb:00000000000000000e00b1a0404060c091208a2084208a20912060c04040b1a00e0000000000000000000000
+29bc:00000000000000000e00318040404040b120b220842089a091a04040404031800e0000000000000000000000
+29bd:04000e00150024800e00358044404440842084208420842084204440444035800e0004000000000000000000
+29be:00000000000000000e00318040404e409120a0a0a0a0a0a091204e40404031800e0000000000000000000000
+29bf:00000000000000000e00318040404e409f20bfa0bfa0bfa09f204e40404031800e0000000000000000000000
+29c0:00000000000000000e0031804240444088209020a020902088204440424031800e0000000000000000000000
+29c1:00000000000000000e003180484044408220812080a0812082204440484031800e0000000000000000000000
+29c2:00000000000000000c00330040804080806080508050805080604080408033000c0000000000000000000000
+29c3:00000000000000000c00330040804080807080708040807080704080408033000c0000000000000000000000
+29c4:00000000000000000000fff080308050809081108210841088109010a010c010fff000000000000000000000
+29c5:00000000000000000000fff0c010a01090108810841082108110809080508030fff000000000000000000000
+29c6:00000000000000000000fff08010b0d099908f10bfd0bfd08f109990b0d08010fff000000000000000000000
+29c7:00000000000000000000fff08010801086108f109f909f908f10861080108010fff000000000000000000000
+29c8:00000000000000000000fff0801080109f9090909090909090909f9080108010fff000000000000000000000
+29c9:00000000000000000000ff80808080809ff09090909090909090ff90101010101ff000000000000000000000
+29ca:06000f0006000000060006000f000f001980198030c030c060606060c030fff0fff000000000000000000000
+29cb:0000060006000f000f001980198030c030c060606060c030fff0fff00000fff0fff000000000000000000000
+29cc:0000060006000f000f001980198030c030c067606860c730c0b0cf30c030fff0fff000000000000000000000
+29cd:000000000000000000000000000006000600090009001080108020402040fff0fff000000000000000000000
+29ce:8000e0009800860081808060818086009820e0e083200c203020c02030200c20032000e00020000000000000
+29cf:000000000000000000000000000000a003a00ca030a0c0a030a00ca003a000a0000000000000000000000000
+29d0:0000000000000000000000000000a000b800a600a180a060a180a600b800a000000000000000000000000000
+29d1:000000000000000000008010c030e050f090f910f610f610f910f090e050c030801000000000000000000000
+29d2:000000000000000000008010c030a07090f089f087f087f089f090f0a070c030801000000000000000000000
+29d3:000000000000000000008010c030e070f0f0f9f0fff0fff0f9f0f0f0e070c030801000000000000000000000
+29d4:000000000000000000008010c020e040f080f900fe00fe00f900f080e040c020801000000000000000000000
+29d5:0000000000000000000080104030207010f009f007f007f009f010f020704030801000000000000000000000
+29d6:00000000000000000000fff04020204010800900060006000900108020404020fff000000000000000000000
+29d7:00000000000000000000fff07fe03fc01f800f00060006000f001f803fc07fe0fff000000000000000000000
+29d8:00000000030006000c00180018000c000600030006000c00180018000c000600030000000000000000000000
+29d9:0000000018000c0006000300030006000c0018000c0006000300030006000c00180000000000000000000000
+29da:000000000c6018c0318063006300318018c00c6018c0318063006300318018c00c6000000000000000000000
+29db:000000006300318018c00c600c6018c031806300318018c00c600c6018c03180630000000000000000000000
+29dc:0000000000000000000000000000300048008400840086108610492030c00000000000000000000000000000
+29dd:000000000000060009001080108030c049208610861086108610492030c00000000000000000000000000000
+29de:000000000000000000000600060036c04f2086108610861086104f2036c00600060000000000000000000000
+29df:0000000000000000000000000000204050a08f108f1050a02040000000000000000000000000000000000000
+29e0:00000000000000000000ffc0ffe0fff0e010e010e010e010e010e010e01060103ff000000000000000000000
+29e1:000000000000000000000000003000f003300c303030fff0fff000000000fff0fff000000000000000000000
+29e2:00000000000000000000000000000000c630c630c630c630c630c630c630fff0fff000000000000000000000
+29e3:000000000000000000000000000006600cc0ffe0ffe019803300ffe0ffe06600cc0000000000000000000000
+29e4:000000001c203e6067c04380000006600cc0ffe0ffe019803300ffe0ffe06600cc0000000000000000000000
+29e5:00000000000001100220fff0fff004400880fff0fff011002200fff0fff04400880000000000000000000000
+29e6:0000000000000000000000000000c030c030fff0fff0c030c030fff0fff0c030c03000000000000000000000
+29e7:000000000000060006000600fff0fff00600060006000600fff0fff006000600060000000000000000000000
+29e8:0000000000000000fff0fc30fc307c607c603cc03cc01d801d800f000f000600060000000000000000000000
+29e9:0000000000000000fff0c3f0c3f063e063e033c033c01b801b800f000f000600060000000000000000000000
+29ea:0000000006000f001f803fc07fe0fff07fe03fc01fc00f00666036c01f800f00060000000000000000000000
+29eb:040004000e000e001f001f003f803f807fc07fc0ffe0ffe07fc07fc03f803f801f001f000e000e0004000400
+29ec:000000001f803fc070e060606060606070e03fc01f800600666036c01f800f00060000000000000000000000
+29ed:000000001f803fc07fe07fe07fe07fe07fe03fc01f800600666036c01f800f00060000000000000000000000
+29ee:000000007fe0060006007fe07fe0606060606060606060607fe07fe0060006007fe000000000000000000000
+29ef:000000007fe0060006007fe07fe07fe07fe07fe07fe07fe07fe07fe0060006007fe000000000000000000000
+29f0:000000007fe0060006000f00198020c06060c0306060204019c00f00060006007fe000000000000000000000
+29f1:000000007fe0060006000f001f803fc07fe0fff07fe03fc01fc00f00060006007fe000000000000000000000
+29f2:000000007fe0060006000f0030c06060c030c030c030606030c00f00060006007fe000000000000000000000
+29f3:000000007fe0060006000f003fc07fe0fff0fff0fff07fe03fc00f00060006007fe000000000000000000000
+29f4:00000000000000000000c000c18000c00060fff0fff0006000c0c180c0000000000000000000000000000000
+29f5:000000001800180018000c000c000c0006000600060003000300030001800180018000000000000000000000
+29f6:0000fc00fd80018001800300030003000600060006000c000c000c0018001800180000000000000000000000
+29f7:000000001800180018000c000c000c003fc03fc0060003000300030001800180018000000000000000000000
+29f8:00000180018001800300030003000600060006000c000c000c00180018001800300030003000000000000000
+29f9:00003000300030001800180018000c000c000c00060006000600030003000300018001800180000000000000
+29fa:0000000000000000000000001980198019801980fff0fff01980198019801980000000000000000000000000
+29fb:0000000000000000000000006660666066606660fff0fff06660666066606660000000000000000000000000
+29fc:00000000000000000060006000c0018006001800600018000600018000c00060006000000000000000000000
+29fd:0000000000000000600060003000180006000180006001800600180030006000600000000000000000000000
+29fe:00000000000000000000000000000000060006001f801f800600060000000000000000000000000000000000
+29ff:00000000000000000000000000000000000000001f801f800000000000000000000000000000000000000000
+2a00:00000000000000000e00318040404040802084208e20842080204040404031800e0000000000000000000000
+2a01:00000000000000000e0035804440444084208420ffe0842084204440444035800e0000000000000000000000
+2a02:00000000000000000e003180404060c091208a2084208a20912060c0404031800e0000000000000000000000
+2a03:00000000000000000000c030c030c030c030c030c030c630c630c030c030c030c0306060606070e03fc00f00
+2a04:00000000000000000000c030c030c030c030c630c630dfb0dfb0c630c630c030c0306060606070e03fc00f00
+2a05:00000000000000000000fff0fff0c030c030c030c030c030c030c030c030c030c030c030c030c030c030c030
+2a06:00000000000000000000c030c030c030c030c030c030c030c030c030c030c030c030c030c030c030fff0fff0
+2a07:000000000a000a000a000a0015001500150015002a802a802a802a805140514051405140a0a0a0a0a0a0a0a0
+2a08:00000000a0a0a0a0a0a0a0a051405140514051402a802a802a802a8015001500150015000a000a000a000a00
+2a09:0000000080204040404020802080110011000a000a00040004000a000a001100110020802080404040408020
+2a0a:0000000000007fe0602030201f0038804c4047404740444028801f00202040207fe000000000000000000000
+2a0b:000001e003e0070006007fe0662036001e000e00070007000e001600260046207fe006000e007c0078000000
+2a0c:000080f081f093809300fb0013001300130003000300030003000300030003000300030007003e003c000000
+2a0d:000001e003e00700060006000600060006007fe0060006000600060006000600060006000e007c0078000000
+2a0e:000001e003e0070006000600060006007fe0060006007fe00600060006000600060006000e007c0078000000
+2a0f:000001e003e00700060006000600063006c007000e003600c600060006000600060006000e007c0078000000
+2a10:000001e003e00700060006001f80264026404600460046004600260026001f80060006000e007c0078000000
+2a11:000003c007c00e000c000c000c008c408ce08df04c404c404c803f000c000c000c000c001c00f800f0000000
+2a12:000001e003e007000600060007e00020002000200620062000200020002007e0060006000e007c0078000000
+2a13:000001e003e00700060006000780004000400020062006200020004000400780060006000e007c0078000000
+2a14:000001e003e007000600060007c00620062000100310031000100620062007c0060006000e007c0078000000
+2a15:000001e003e00700060006001f80204020404020462046204020204020401f80060006000e007c0078000000
+2a16:000001e003e00700060006007fe0462046204620462046204620462046207fe0060006000e007c0078000000
+2a17:000000f001f00380030003001b0033006300ffe0fff0633033301b30036003000300030007003e003c000000
+2a18:000001e003e0070006000600666036c01f800f0006000f001f8036c066600600060006000e007c0078000000
+2a19:000001e003e0070006001f803fc076e066606660666066606660666066606660666006000e007c0078000000
+2a1a:000001e003e00700060066606660666066606660666066606660666076e03fc01f8006000e007c0078000000
+2a1b:3fc0000001e003e0070006000600060006000600060006000600060006000600060006000e007c0078000000
+2a1c:000001e003e0070006000600060006000600060006000600060006000600060006000e007c00780000003fc0
+2a1d:000000000000000000008010c030a050909089108610861089109090a050c030801000000000000000000000
+2a1e:0030007000f001b0033006300c30183030306030c030c0306030303018300c300630033001b000f000700030
+2a1f:000000000000000000000000060009001080108009000600000006000900108010801c800480090012000c00
+2a20:0000000000009c00ce00e700738039c01ce00e700e701ce039c07380e700ce009c0000000000000000000000
+2a21:0000000008000c000e000f000d800cc00c000c000c000c000c000c000c000c000c000c000c000c000c000c00
+2a22:000000000600090009000600000006000600060006007fe07fe0060006000600060000000000000000000000
+2a23:000004000e001b00318060c0000006000600060006007fe07fe0060006000600060000000000000000000000
+2a24:0000000000001c203e6067c0438006000600060006007fe07fe0060006000600060000000000000000000000
+2a25:000000000000000000000000000006000600060006007fe07fe0060006000600060000000000060006000000
+2a26:0000000000000000000006000600060006007fe07fe006000600060006001c203e6067c04380000000000000
+2a27:000000000000000000000000000006000600060006007fe07fe0060006f00610061000f00080008000f00000
+2a28:000000000000000000000000000006000600060006007fe07fe006000f001f80060000000000000000000000
+2a29:0000000000000000000000000600060002000c0000007fe07fe0000000000000000000000000000000000000
+2a2a:000000000000000000000000000000000000000000007fe07fe0000000000600060000000000000000000000
+2a2b:000000000000000000000000000060006000000000007fe07fe0000000000060006000000000000000000000
+2a2c:000000000000000000000000000000600060000000007fe07fe0000000006000600000000000000000000000
+2a2d:000000000000000000001c002000460046008600bfc0bfc086004600460020001c0000000000000000000000
+2a2e:00000000000000000000038000400620062006103fd03fd00610062006200040038000000000000000000000
+2a2f:000000000000000000000000204070e039c01f800f001f8039c070e020400000000000000000000000000000
+2a30:0000000000000000000006000600606030c019800f0006000f00198030c06060000000000000000000000000
+2a31:0000000000000000000000000000606030c019800f0006000f00198030c0606000003fc00000000000000000
+2a32:0000000000000000000000000000606030c019800f0006000f00198030c060603fc000000000000000000000
+2a33:00000000000000000000000031801b008e20ce607bc031807bc0ce608e201b00318000000000000000000000
+2a34:00000000000000001c002000400058608cc08780830087808cc05860400020001c0000000000000000000000
+2a35:000000000000000003800040002061a033101e100c101e10331061a000200040038000000000000000000000
+2a36:04000e001b00318060c000001f802040402050a0891086108610891050a0402020401f800000000000000000
+2a37:000000000000000000001f8020404f2050a0a950a650a650a95050a04f2020401f8000000000000000000000
+2a38:000000000000000000001f802040462046208010bfd0bfd080104620462020401f8000000000000000000000
+2a39:060006000900090009001080108010802040264026405fa05fa0462086108010fff000000000000000000000
+2a3a:060006000900090009001080108010802040204020404f204f20402080108010fff000000000000000000000
+2a3b:06000600090009000900108010801080204030c039c04f2046204f209990b0d0fff000000000000000000000
+2a3c:00000000000000000000000000000000000000600060006000607fe07fe00000000000000000000000000000
+2a3d:00000000000000000000000000000000000060006000600060007fe07fe00000000000000000000000000000
+2a3e:0000000000000000000000000000000006000900090006000000000006000900090007000300060018000000
+2a3f:000000000000e070e0706060606060606060606060606060606060606060fff0fff000000000000000000000
+2a40:000000000000000000001f803fc070e060606060666066606060606060606060606000000000000000000000
+2a41:0000000000000000000060606060606060606f606f6060606060606070e03fc01f8000000000000000000000
+2a42:0000000000003fc0000060606060606060606060606060606060606070e03fc01f8000000000000000000000
+2a43:0000000000003fc000001f803fc070e060606060606060606060606060606060606000000000000000000000
+2a44:000000000000000000001f803fc070e06060c030c030c630c630c930c930d0b0d0b000000000000000000000
+2a45:00000000000000000000d0b0d0b0c930c930c630c630c030c030606070e03fc01f8000000000000000000000
+2a46:0000606060606060606060606060606070e03fc01f8000001f803fc070e06060606060606060606060606060
+2a47:00001f803fc070e060606060606060606060606060600000606060606060606060606060606070e03fc01f80
+2a48:000060606060606060606060606070e03fc01f8000003fc000001f803fc070e0606060606060606060606060
+2a49:00001f803fc070e060606060606060606060606000003fc0000060606060606060606060606070e03fc01f80
+2a4a:00000000000000000000c630c630c630c630c630c630c630c630c630c6307fe039c000000000000000000000
+2a4b:0000000000000000000039c07fe0c630c630c630c630c630c630c630c630c630c63000000000000000000000
+2a4c:00000000000000000000fff06060606060606060606060606060606070e03fc01f8000000000000000000000
+2a4d:000000000000000000001f803fc070e060606060606060606060606060606060fff000000000000000000000
+2a4e:00000000000000000000fff0fff0c030c030dfb0d9b0d9b0d9b0d9b0d9b0d9b0d9b000000000000000000000
+2a4f:00000000000000000000d9b0d9b0d9b0d9b0d9b0d9b0d9b0dfb0c030c030fff0fff000000000000000000000
+2a50:00000000000000000000fff0606069607fe0696069607fe06960606070e03fc01f8000000000000000000000
+2a51:0000000000000600060000000000060006000f000f001980198030c030c06060606000000000000000000000
+2a52:00000000000006000600000000006060606030c030c0198019800f000f000600060000000000000000000000
+2a53:00000000000000000000000000000e000e001b001b00318035806ac06ac0d160d16000000000000000000000
+2a54:0000000000000000000000000000d160d1606ac06ac0358031801b001b000e000e0000000000000000000000
+2a55:00000000000000000000000000000a000a00150015002a802a8051405140a0a0a0a000000000000000000000
+2a56:0000000000000000000000000000a0a0a0a0514051402a802a80150015000a000a0000000000000000000000
+2a57:00000000000000000000c010c030c060c0c0c180c300c600cc00d800f000e000c00000000000000000000000
+2a58:000000000000000000000030007000f001b0033006300c30183030306030c030803000000000000000000000
+2a59:000000000000000000006060606036c036c01f80198019801f8036c036c06060606000000000000000000000
+2a5a:0000000000000000000000000000060006000f000f001f801f8036c036c06660666000000000000000000000
+2a5b:00000000000000000000000000006660666036c036c01f801f800f000f000600060000000000000000000000
+2a5c:0000000000000000000000000000060006000f000f0019801980fff030c06060606000000000000000000000
+2a5d:00000000000000000000000000006060606030c0fff0198019800f000f000600060000000000000000000000
+2a5e:00003fc03fc000003fc03fc00000060006000f000f001980198030c030c06060606000000000000000000000
+2a5f:0000000000000000000000000000060006000f000f001980198030c030c06060606000003fc03fc000000000
+2a60:000000000000000000000000060006000f000f001980198030c030c06060606000003fc03fc000003fc03fc0
+2a61:00000000000000000000000000000000000030c030c0198019800f000f000600060000003fc03fc000000000
+2a62:00003fc03fc000003fc03fc000006060606030c030c0198019800f000f000600060000000000000000000000
+2a63:0000000000000000000000006060606030c030c0198019800f000f000600060000003fc03fc000003fc03fc0
+2a64:0030007000f001b0033006300c30183030306030fff0fff06030303018300c300630033001b000f000700030
+2a65:c000e000f000d800cc00c600c300c180c0c0c060fff0fff0c060c0c0c180c300c600cc00d800f000e000c000
+2a66:0000000000000000000000000000000000007fe07fe0000000007fe07fe00000060006000000000000000000
+2a67:00000000000000000600060000007fe07fe0000000007fe07fe0000000007fe07fe000000000000000000000
+2a68:00000000000000001980198019807fe07fe0198019807fe07fe0198019807fe07fe019801980000000000000
+2a69:00000000000000002640264026407fe07fe0264026407fe07fe0264026407fe07fe026402640000000000000
+2a6a:0000000000000000000006000600000000001c203e6036c067c0438000000000000000000000000000000000
+2a6b:000000000000000000c000c0000000001c203e6036c067c04380000000003000300000000000000000000000
+2a6c:00000000000000001c203e6036c067c0438000007fe000001c203e6036c067c0438000000000000000000000
+2a6d:000006000600000000001c203e6036c067c0438000007fe07fe0000000007fe07fe000000000000000000000
+2a6e:000030c019800f003fc03fc00f00198030c0000000007fe07fe0000000007fe07fe000000000000000000000
+2a6f:000006000f001980000000001c203e6067c04380000000001c203e6067c04380000000000000000000000000
+2a70:00001c203e6067c0438000001c203e6067c0438000007fe07fe0000000007fe07fe000000000000000000000
+2a71:000000007fe07fe0000000007fe07fe000000600060006003fc03fc006000600060000000000000000000000
+2a72:000000000600060006003fc03fc006000600060000007fe07fe0000000007fe07fe000000000000000000000
+2a73:000000000000000000007fe07fe0000000007fe07fe000001c203e6067c04380000000000000000000000000
+2a74:0000000000000000000000000000000000006de06de0000000006de06de00000000000000000000000000000
+2a75:000000000000000000000000000000000000fbe0fbe000000000fbe0fbe00000000000000000000000000000
+2a76:000000000000000000000000000000000000eee0eee000000000eee0eee00000000000000000000000000000
+2a77:00000000000030c030c0000000007fe07fe0000000007fe07fe00000000030c030c000000000000000000000
+2a78:000000000000db60db6000000000ffe0ffe000000000ffe0ffe000000000ffe0ffe000000000000000000000
+2a79:0000000000000000000000000000006001c007001e60789078901e60070001c0006000000000000000000000
+2a7a:000000000000000000000000000030001c00070033c048f048f033c007001c00300000000000000000000000
+2a7b:3c007e00c30006000c001800000018e001c007001e00780078001e00070001c0006000000000000000000000
+2a7c:03c007e00c30006000c001800000618038000e00078001e001e007800e003800700000000000000000000000
+2a7d:0000000000000000006001c007001e00780078001e00070071c01c60070001c0006000000000000000000000
+2a7e:0000000000000000600038000e00078001e001e007800e0038e063800e003800600000000000000000000000
+2a7f:0000000000000000006001c007001e00786078601e00070071c01c60070001c0006000000000000000000000
+2a80:0000000000000000600038000e00078061e061e007800e0038e063800e003800600000000000000000000000
+2a81:0000000000000000606061c007001e00780078001e00070071c01c60070001c0006000000000000000000000
+2a82:0000000000000000606038600e00078001e001e007800e0038e063800e003800600000000000000000000000
+2a83:0000006000600000006001c007001e00780078001e00070071c01c60070001c0006000000000000000000000
+2a84:0000600060000000600038000e00078001e001e007800e0038e063800e003800600000000000000000000000
+2a85:006001c007001e00780078001e00070001c0006000001c203e6067c0438000001c203e6067c0438000000000
+2a86:600038000e00078001e001e007800e003800600000001c203e6067c0438000001c203e6067c0438000000000
+2a87:000000000000006001c007001e00780078001e00070001c000e0018003007fe07fe018003000000000000000
+2a88:000000000000600038000e00078001e001e007800e0038007000018003007fe07fe018003000000000000000
+2a89:006001c007001e00780078001e00070001c0016001001d203e6067c0438004001c203e606fc04b8008001000
+2a8a:600038000e00078001e001e007800e003800610001001d203e6067c0438004001c203e606fc04b8008001000
+2a8b:0000000001e00f0078000f0001e000007fe0000000007fe0000078000f0001e00f0078000000000000000000
+2a8c:0000000078000f0001e00f00780000007fe0000000007fe0000001e00f0078000f0001e00000000000000000
+2a8d:006001c007001e00780078001e00070001c0006000001c203e6067c0438000007fe07fe00000000000000000
+2a8e:600038000e00078001e001e007800e003800600000001c203e6067c0438000007fe07fe00000000000000000
+2a8f:000001e00f0078000f0001e000001c203e6067c04380000078000f0001e00f00780000000000000000000000
+2a90:000078000f0001e00f00780000001c203e6067c04380000001e00f0078000f0001e000000000000000000000
+2a91:000001e00f0078000f0001e078000f0001e00f00780000007fe07fe0000000007fe07fe00000000000000000
+2a92:000078000f0001e00f00780001e00f0078000f0001e000007fe07fe0000000007fe07fe00000000000000000
+2a93:000001e00f0078000f0001e078000f0001e078000f0001e00f00780001e00f00780000000000000000000000
+2a94:000078000f0001e00f00780001e00f00780001e00f0078000f0001e078000f0001e000000000000000000000
+2a95:0000000000000000006001c007001c6071c007001e00780078001e00070001c0006000000000000000000000
+2a96:0000000000000000600038000e00638038e00e00078001e001e007800e003800600000000000000000000000
+2a97:0000000000000000006001c007001c6071c007001e00786078601e00070001c0006000000000000000000000
+2a98:0000000000000000600038000e00638038e00e00078061e061e007800e003800600000000000000000000000
+2a99:00007fe07fe000007fe07fe00000006001c007001e00780078001e00070001c0006000000000000000000000
+2a9a:00007fe07fe000007fe07fe00000600038000e00078001e001e007800e003800600000000000000000000000
+2a9b:0000006001c007001c6071c007001c6071c007001e00780078001e00070001c0006000000000000000000000
+2a9c:0000600038000e00638038e00e00638038e00e00078001e001e007800e003800600000000000000000000000
+2a9d:00001c203e6036c067c043800000006001c007001e00780078001e00070001c0006000000000000000000000
+2a9e:00001c203e6036c067c043800000600038000e00078001e001e007800e003800600000000000000000000000
+2a9f:00001c203e6036c067c04380006001c007001e00780078001e00070001c000607fe07fe000007fe07fe00000
+2aa0:00001c203e6036c067c04380600038000e00078001e001e007800e00380060007fe07fe000007fe07fe00000
+2aa1:0000000000000000000000000000006001c007201e6079c079c01e60072001c0006000000000000000000000
+2aa2:0000000000000000000000000000600038004e00678039e039e067804e003800600000000000000000000000
+2aa3:00000000000000000e701ce039c07380e700e700738039c01ce00e700000fff0fff000000000000000000000
+2aa4:00000000000000000000000060c031801b000e001b0031801b000e001b00318060c000000000000000000000
+2aa5:000000000000000000000000000000008020c06060c031801b00318060c0c060802000000000000000000000
+2aa6:000000000000000000000000000000c003a00e203c10f010f0103c100e2003a000c000000000000000000000
+2aa7:000000000000000000000000000030005c00470083c080f080f083c047005c00300000000000000000000000
+2aa8:000000000000000000c003a00e203c10f010f0103c100e20e3a038c00e00038000c000000000000000000000
+2aa9:000000000000000030005c00470083c080f080f083c047005c7031c007001c00300000000000000000000000
+2aaa:0000000000000000000000000000006001c007001e007fe07fe01e00070001c0006000000000000000000000
+2aab:0000000000000000000000000000600038000e0007807fe07fe007800e003800600000000000000000000000
+2aac:0000000000000000006001c007001e007fe07fe01e00070001c0006000007fe07fe000000000000000000000
+2aad:0000000000000000600038000e0007807fe07fe007800e003800600000007fe07fe000000000000000000000
+2aae:000000000000000006000f00090079e079e0000000007fe07fe0000000007fe07fe000000000000000000000
+2aaf:00000000000000000000006001c007803c00e0003c00078001c000600000ffe0ffe000000000000000000000
+2ab0:00000000000000000000c00070003c00078000e007803c007000c0000000ffe0ffe000000000000000000000
+2ab1:00000000000000000000006001c007803c00e0003c00078001c003600600ffe0ffe030006000000000000000
+2ab2:00000000000000000000c00070003c00078000e007803c007000c0c00180ffe0ffe00c001800000000000000
+2ab3:00000000006001c007803c00e0003c00078001c000600000ffe0ffe00000ffe0ffe000000000000000000000
+2ab4:00000000c00070003c00078000e007803c007000c0000000ffe0ffe00000ffe0ffe000000000000000000000
+2ab5:00000000006001c007803c00e0003c00078001c006600600ffe0ffe01800ffe0ffe060006000000000000000
+2ab6:00000000c00070003c00078000e007803c007000c1800180ffe0ffe00600ffe0ffe018001800000000000000
+2ab7:0000006001c007803c00e0003c00078001c000601c203e6067c043801c203e6067c043800000000000000000
+2ab8:0000c00070003c00078000e007803c007000c0001c203e6067c043801c203e6067c043800000000000000000
+2ab9:0000006001c007803c00e0003c00078001c002601e203e6067c047801c203e606fc04b801000100000000000
+2aba:0000c00070003c00078000e007803c007080c0801ca03f6067c043801e203e6067c047800400040000000000
+2abb:000000000000000000000000031006301ce07380ce0073801ce0067003100000000000000000000000000000
+2abc:0000000000000000000000008c00c60073801ce007301ce07380e6008c000000000000000000000000000000
+2abd:0000000000000000000007e01fe03800600061806180600038001fe007e00000000000000000000000000000
+2abe:000000000000000000007e007f8001c0006018601860006001c07f807e000000000000000000000000000000
+2abf:000007e01fe03800600060006000600038001fe007e000000600060006003fc03fc006000600060000000000
+2ac0:00007e007f8001c0006000600060006001c07f807e0000000600060006003fc03fc006000600060000000000
+2ac1:000007e01fe03800600060006000600038001fe007e0000030c019800f0006000f00198030c0000000000000
+2ac2:00007e007f8001c0006000600060006001c07f807e00000030c019800f0006000f00198030c0000000000000
+2ac3:000006000600000007e01fe03800600060006000600038001fe007e000007fe07fe000000000000000000000
+2ac4:00000600060000007e007f8001c0006000600060006001c07f807e0000007fe07fe000000000000000000000
+2ac5:0000000007e01fe03800600060006000600038001fe007e000007fe07fe000007fe07fe00000000000000000
+2ac6:000000007e007f8001c0006000600060006001c07f807e0000007fe07fe000007fe07fe00000000000000000
+2ac7:0000000007e01fe03800600060006000600038001fe007e000001c203e6036c067c043800000000000000000
+2ac8:000000007e007f8001c0006000600060006001c07f807e0000001c203e6036c067c043800000000000000000
+2ac9:000007e01fe03800600060006000600038001fe007e000001c203e6067c043801c203e6067c0438000000000
+2aca:00007e007f8001c0006000600060006001c07f807e0000001c203e6067c043801c203e6067c0438000000000
+2acb:0000000007e01fe03800600060006000600038001fe007e001807fe07fe006007fe07fe01800300000000000
+2acc:000000007e007f8001c0006000600060006001c07f807ec001807fe07fe003007fe07fe006000c0000000000
+2acd:000000000000000000000000000000000000fff0fff0c000c000c000c000fc00fc0000000000000000000000
+2ace:000000000000000000000000000000000000fff0fff0003000300030003003f003f000000000000000000000
+2acf:0000000000000000000007e01fe03860606060606060606038601fe007e00000000000000000000000000000
+2ad0:000000000000000000007e007f8061c0606060606060606061c07f807e000000000000000000000000000000
+2ad1:000000000000000007e01fe03860606060606060606038601fe007e000007fe07fe000000000000000000000
+2ad2:00000000000000007e007f8061c0606060606060606061c07f807e0000007fe07fe000000000000000000000
+2ad3:000007e01fe038006000600038001fe007e000007e007f8001c00060006001c07f807e000000000000000000
+2ad4:00007e007f8001c00060006001c07f807e00000007e01fe038006000600038001fe007e00000000000000000
+2ad5:000007e01fe038006000600038001fe007e0000007e01fe038006000600038001fe007e00000000000000000
+2ad6:00007e007f8001c00060006001c07f807e0000007e007f8001c00060006001c07f807e000000000000000000
+2ad7:000000000000000000000000e0e0f3e03b801b001b001b001b003b80f3e0e0e0000000000000000000000000
+2ad8:000000000000000000000000e0e0f3e03b801b007fc07fc01b003b80f3e0e0e0000000000000000000000000
+2ad9:000000000000000000000000000000000f003fc036c066606660666066606660000000000000000000000000
+2ada:00000000000000003fc03fc0060006000f003fc036c066606660666066606660060006000600000000000000
+2adb:000000000000000006000600060006000f003fc036c066606660666066606660060006000600000000000000
+2adc:0000000000000000060006000600066006c007006e607660e66036c03fc00f00000000000000000000000000
+2add:000000000000000006000600060006000600060066606660666036c03fc00f00000000000000000000000000
+2ade:00000000000000000000000000600060006000600fe00fe00060006000600060000000000000000000000000
+2adf:000000000000000000000000000000007fe07fe0060006000600060006000000000000000000000000000000
+2ae0:00000000000000000000000000000000060006000600060006007fe07fe00000000000000000000000000000
+2ae1:000000000c000c000c000ce00d100d000ce00c100d100ce00c00ffc0ffc00000000000000000000000000000
+2ae2:00000000000000000000c000c000fff0fff0c000fff0fff0c000fff0fff0c000c00000000000000000000000
+2ae3:0000000000000000000003300330033003300330ff30ff300330033003300330033000000000000000000000
+2ae4:00000000000000000000003000300030fff0fff000300030fff0fff000300030003000000000000000000000
+2ae5:00000000000000000000033003300330ff30ff3003300330ff30ff3003300330033000000000000000000000
+2ae6:00000000000000000000cc00cc00cc00cc00cc00fff0fff0cc00cc00cc00cc00cc0000000000000000000000
+2ae7:00000000000000000000fff0fff000000000fff0fff006000600060006000600060000000000000000000000
+2ae8:00000000000000000000060006000600060006000600fff0fff000000000fff0fff000000000000000000000
+2ae9:0000000000000600060006000600fff0fff000000000fff0fff0060006000600060000000000000000000000
+2aea:000000000000000000000000fff0fff019801980198019801980198019801980198000000000000000000000
+2aeb:000000000000000000000000198019801980198019801980198019801980fff0fff000000000000000000000
+2aec:00000000000000000000fff0fff000300030fff0fff000300030003000300030003000000000000000000000
+2aed:00000000000000000000fff0fff0c000c000fff0fff0c000c000c000c000c000c00000000000000000000000
+2aee:00000000000006000600060036001e000e0006000700078006c0060006000600060000000000000000000000
+2aef:000000000f0010801080108010800f0006000600060006000600060006000600060000000000000000000000
+2af0:000000000600060006000600060006000600060006000f0010801080108010800f0000000000000000000000
+2af1:000000003fc03fc006000600060006000600060006000f0010801080108010800f0000000000000000000000
+2af2:000000000000198019801980198019801980fff0fff019801980198019801980198000000000000000000000
+2af3:000000000000198019801980198019807d80dfb0dfb01be01980198019801980198000000000000000000000
+2af4:0000000000006660666066606660666066606660666066606660666066606660666000000000000000000000
+2af5:000000000000666066606660666066606660fff0fff066606660666066606660666000000000000000000000
+2af6:000000000e000e000e000000000000000e000e000e000000000000000e000e000e0000000000000000000000
+2af7:0000000000000180030006600cc0198033306660ccc06660333019800cc00660030001800000000000000000
+2af8:00000000000018000c00660033001980ccc0666033306660ccc01980330066000c0018000000000000000000
+2af9:0000006001c007001e00780078001e00070071c01c60070071c01c60070001c0006000000000000000000000
+2afa:0000600038000e00078001e001e007800e0038e063800e0038e063800e003800600000000000000000000000
+2afb:000000000000333033303330333033306660666066606660ccc0ccc0ccc0ccc0ccc000000000000000000000
+2afc:0000000066606660666066606660666066606660666066606660666066606660666066606660666066600000
+2afd:0000000000000cc00cc00cc00cc00cc019801980198019803300330033003300330000000000000000000000
+2afe:0000000000000000000000001f801980198019801980198019801980198019801f8000000000000000000000
+2aff:00001f80198019801980198019801980198019801980198019801980198019801f8000000000000000000000
+2b00:000000000000000000000ff0041002100210041008d011302210440088005000200000000000000000000000
+2b01:00000000000000000000ff008200840084008200b100c88084400220011000a0004000000000000000000000
+2b02:0000000000000000000020005000880044002210113008d004100210021004100ff000000000000000000000
+2b03:00000000000000000000004000a0011002208440c880b1008200840084008200ff0000000000000000000000
+2b04:00000000000000000000000000000900198029404f2080104f20294019800900000000000000000000000000
+2b05:00000000000000000000000000000800180038007ff0fff07ff0380018000800000000000000000000000000
+2b06:0000000006000f001f803fc07fe0fff01f801f801f801f801f801f801f801f801f8000000000000000000000
+2b07:000000001f801f801f801f801f801f801f801f801f80fff07fe03fc01f800f00060000000000000000000000
+2b08:000000000000000000000ff007f003f003f007f00ff01f303e107c00f8007000200000000000000000000000
+2b09:00000000000000000000ff00fe00fc00fc00fe00ff00cf8087c003e001f000e0004000000000000000000000
+2b0a:0000000000000000000020007000f8007c003e101f300ff007f003f003f007f00ff000000000000000000000
+2b0b:00000000000000000000004000e001f003e087c0cf80ff00fe00fc00fc00fe00ff0000000000000000000000
+2b0c:00000000000000000000000000000900198039c07fe0fff07fe039c019800900000000000000000000000000
+2b0d:06000f001f803fc07fe0fff01f801f801f801f801f80fff07fe03fc01f800f00060000000000000000000000
+2b0e:00000000000000000000000000000000ffc0ffc000c000c000c003f001e000c0000000000000000000000000
+2b0f:00000000000000000000000000c001e003f000c000c000c0ffc0ffc000000000000000000000000000000000
+2b10:000000000000000000000000000000003ff03ff0300030003000fc0078003000000000000000000000000000
+2b11:00000000000000000000000030007800fc003000300030003ff03ff000000000000000000000000000000000
+2b12:00000000000000000000fff0fff0fff0fff0fff0fff080108010801080108010fff000000000000000000000
+2b13:00000000000000000000fff080108010801080108010fff0fff0fff0fff0fff0fff000000000000000000000
+2b14:00000000000000000000fff0bff09ff08ff087f083f081f080f0807080308010fff000000000000000000000
+2b15:00000000000000000000fff08010c010e010f010f810fc10fe10ff10ff90ffd0fff000000000000000000000
+2b16:0000000000000000000006000d001c803c407c20fc10fc107c203c401c800d00060000000000000000000000
+2b17:0000000000000000000006000b00138023c043e083f083f043e023c013800b00060000000000000000000000
+2b18:0000000000000000000006000f001f803fc07fe0fff080104020204010800900060000000000000000000000
+2b19:00000000000000000000060009001080204040208010fff07fe03fc01f800f00060000000000000000000000
+2b1a:00000000000000000000aaa00010800000108000001080000010800000108000555000000000000000000000
+2b1b:00000000000000000000000000000003ffc003ffc003ffc003ffc003ffc003ffc003ffc003ffc003ffc003ffc003ffc003ffc0000000000000000000000000000000
+2b1c:00000000000000000000000000000003ffc002004002004002004002004002004002004002004002004002004002004003ffc0000000000000000000000000000000
+2b1d:0000000000000000000000000000000000000000060006000000000000000000000000000000000000000000
+2b1e:0000000000000000000000000000000000000f00090009000f00000000000000000000000000000000000000
+2b1f:000000000000000006000f001f803fc07fe07fe07fe03fc03fc03fc01f801f801f8000000000000000000000
+2b20:000000000000000006000900108020404020402040202040204030c0108010801f8000000000000000000000
+2b21:0000000000000600090010802040402040204020402040204020204010800900060000000000000000000000
+2b22:00000000000006000f001f803fc07fe07fe07fe07fe07fe07fe03fc01f800f00060000000000000000000000
+2b23:0000000000001f801f803fc03fc07fe07fe07fe07fe07fe07fe03fc03fc01f801f8000000000000000000000
+2b24:000000000000000000001f803fc07fe07fe0fff0fff0fff0fff07fe07fe03fc01f8000000000000000000000
+2b25:000000000000000000000000000004000e001f003f807fc03f801f000e000400000000000000000000000000
+2b26:000000000000000000000000000004000a00110020804040208011000a000400000000000000000000000000
+2b27:000000000000040004000e000e001f001f003f803f801f001f000e000e000400040000000000000000000000
+2b28:000000000000040004000a000a001100110020802080110011000a000a000400040000000000000000000000
+2b29:0000000000000000000000000000000006000f001f803fc01f800f0006000000000000000000000000000000
+2b2a:00000000000000000000060006000f000f001f801f800f000f00060006000000000000000000000000000000
+2b2b:0000000000000000000006000600090009001080108009000900060006000000000000000000000000000000
+2b2c:0000000000000000000000000f003fc07fe0fff0fff0fff0fff07fe03fc00f00000000000000000000000000
+2b2d:0000000000000000000000000f0030c040208010801080108010402030c00f00000000000000000000000000
+2b2e:000000000000000000000f001f803fc03fc07fe07fe07fe07fe03fc03fc01f800f0000000000000000000000
+2b2f:000000000000000000000f0010802040204040204020402040202040204010800f0000000000000000000000
+2b30:000000000000000000000000180033806440fff0fff064403380180000000000000000000000000000000000
+2b31:180030006000fff0fff060003000180030006000fff0fff060003000180030006000fff0fff0600030001800
+2b32:00000000000000000000000001c016b024904490fff04490249016b001c00000000000000000000000000000
+2b33:000000000000000000000000018000c0106028b04530826000c0018000000000000000000000000000000000
+2b34:0000000000000000000000000000124024404840fff0fff04840244012400000000000000000000000000000
+2b35:000000000000000000000000000012a024a048a0fff0fff048a024a012a00000000000000000000000000000
+2b36:0000000000000000000000000000123024304830fff0fff04830243012300000000000000000000000000000
+2b37:0000000000000000000000000000120024004800edb0edb04800240012000000000000000000000000000000
+2b38:000000000000000000000000180030006000d550d55060003000180000000000000000000000000000000000
+2b39:0000000000000000000000000000121022204240ff80ff804240222012100000000000000000000000000000
+2b3a:0000000000000000000000000000151025204540ff80ff804540252015100000000000000000000000000000
+2b3b:0000000000000000000000000000121024204840ff80ff804840242012100000000000000000000000000000
+2b3c:0000000000000000000000000000151029205140ff80ff805140292015100000000000000000000000000000
+2b3d:00000000000000000000000000002a9052a0a2c0ffc0ffc0a2c052a02a900000000000000000000000000000
+2b3e:000000000000000000000000000000001a10312060c0fff0fff060c031201a10000000000000000000000000
+2b3f:0000000000000000000000001800338066c0fc70f83060003000180000000000000000000000000000000000
+2b40:000000000000000003e003e00000000003e01be030006000fff0fff060003000180000000000000000000000
+2b41:0000000000000000438067c03e601c200000180030006000fff0fff060003000180000000000000000000000
+2b42:0000180030006000fff0fff060003000180000001c203e6067c043801c203e6067c043800000000000000000
+2b43:0000000000000000000000000000c00071801cc00760fff0fff007601cc07180c00000000000000000000000
+2b44:000000000000f000f8000c000c8006400620fff0fff0062006400c800c00f800f00000000000000000000000
+2b45:0000000000000000100010003ff0200040007ff0800080007ff0400020003ff0100010000000000000000000
+2b46:000000000000000000800080ffc000400020ffe000100010ffe000200040ffc0008000800000000000000000
+2b47:0000000000000000438067c03e601c200000018000c00060fff0fff0006000c0018000000000000000000000
+2b48:018000c00060fff0fff0006000c001800000438067c03e601c200000438067c03e601c200000000000000000
+2b49:00000000000000001c203e6067c043800000180030006000fff0fff060003000180000000000000000000000
+2b4a:180030006000fff0fff060003000180000001c203e6067c0438000001c203e6067c043800000000000000000
+2b4b:0000000000000000180030006000fff0fff06000300018000000438067c03e601c2000000000000000000000
+2b4c:0000000000000000018000c00060fff0fff0006000c001800000438067c03e601c2000000000000000000000
+2b4d:000000000000030006000c00180030007fe07fe000c00180230036003c003e003f0000000000000000000000
+2b4e:00000000000000000000030007800fc003000300060006000c000c0000000000000000000000000000000000
+2b4f:000000000000000000000c000c0006000600030003000fc00780030000000000000000000000000000000000
+2b50:00000000000000000000000000000000180000990000660000240000c30000c300002400006600009900001800000000000000000000000000000000000000000000
+2b51:0000000000000000000000000000000019800f003fc00f001980000000000000000000000000000000000000
+2b52:0000000000000000000000000000000011000e0031800e001100000000000000000000000000000000000000
+2b53:0000000000000000000000000f003f80ffc0ffe0fff0fff0ffe0ffc03f800f00000000000000000000000000
+2b54:0000000000000000000000000f003080c0408020801080108020c04030800f00000000000000000000000000
+2b55:000000003c0001ff8003c3c00600600c003018001818001818001830000c30000c30000c30000c1800181800181800180c003006006003c3c001ff80003c00000000
+2b56:0000000000000000000000000f003fc06060cf30d0b0d0b0cf3060603fc00f00000000000000000000000000
+2b57:000000000000000000001f803fc060606f60d0b0d0b0d0b0d0b06f6060603fc01f8000000000000000000000
+2b58:0000000000000000000000001f803fc030c0606060606060606030c03fc01f80000000000000000000000000
+2b59:000000000000000000001f803fc0606070e0c930c630c630c93070e060603fc01f8000000000000000000000
+2b5a:00000000000000000000038007c00c400c4019f018e03040300060006000c000c00000000000000000000000
+2b5b:00000000000038006c00c600c600030003000180018000c000c003f001e000c0000000000000000000000000
+2b5c:000000000000000000c001e003f000c000c0018001800300030006000600fc00fc0000000000000000000000
+2b5d:0000000000000000fc00fc0006000600030003000180018000c000c003f001e000c000000000000000000000
+2b5e:00000000000003000300060006000c000c001800180033f031f063e06e60f820c00000000000000000000000
+2b5f:00000000000000000000000000000c000c001800180033f031f063e06e60f820c00000000000000000000000
+2b60:000000000000000000000000100030007000ffe0ffe070003000100000000000000000000000000000000000
+2b61:0000000006000f001f803fc00600060006000600060006000600060006000600060000000000000000000000
+2b62:0000000000000000000000000100018001c0ffe0ffe001c00180010000000000000000000000000000000000
+2b63:00000000060006000600060006000600060006000600060006003fc01f800f00060000000000000000000000
+2b64:000000000000000000000000108030c070e0fff0fff070e030c0108000000000000000000000000000000000
+2b65:0000000006000f001f803fc006000600060006000600060006003fc01f800f00060000000000000000000000
+2b66:00000000000000000000f800f000f000f8009c000e000700038001c000e00070002000000000000000000000
+2b67:0000000000000000000001f000f000f001f0039007000e001c0038007000e000400000000000000000000000
+2b68:000000000000000000004000e000700038001c000e000700039001f000f000f001f000000000000000000000
+2b69:000000000000000000000020007000e001c0038007000e009c00f800f000f000f80000000000000000000000
+2b6a:000000000000000000000000100030007000edb0edb070003000100000000000000000000000000000000000
+2b6b:000006000f001f80060006000000000006000600060000000000060006000600000000000600060006000000
+2b6c:000000000000000000000000008000c000e0db70db7000e000c0008000000000000000000000000000000000
+2b6d:0000060006000600000000000600060006000000000006000600060000000000060006001f800f0006000000
+2b6e:0000000000001f000f001f003300610060006000606060606060204030c019800f0000000000000000000000
+2b6f:0000000000000f800f000f800cc0086000600060606060606060204030c019800f0000000000000000000000
+2b70:000000000000000000000000c400cc00dc00fff0fff0dc00cc00c40000000000000000000000000000000000
+2b71:000000003fc03fc006000f001f803fc006000600060006000600060006000600060000000000000000000000
+2b72:0000000000000000000000000230033003b0fff0fff003b00330023000000000000000000000000000000000
+2b73:000000000600060006000600060006000600060006003fc01f800f0006003fc03fc000000000000000000000
+2b76:00000000fc00fc000000f800f000f000f8009c000e000700038001c000e00070002000000000000000000000
+2b77:0000000003f003f0000001f000f000f001f0039007000e001c0038007000e000400000000000000000000000
+2b78:000000000000000000004000e000700038001c000e000700039001f000f000f001f0000003f003f000000000
+2b79:000000000000000000000020007000e001c0038007000e009c00f800f000f000f8000000fc00fc0000000000
+2b7a:0000000000000000000000000000124032407240fff0fff07240324012400000000000000000000000000000
+2b7b:0000000006000f001f803fc00600060006007fe07fe0060006007fe07fe00600060000000000000000000000
+2b7c:0000000000000000000000000000248024c024e0fff0fff024e024c024800000000000000000000000000000
+2b7d:00000000060006007fe07fe0060006007fe07fe00600060006003fc01f800f00060000000000000000000000
+2b7e:0000c400cc00dc00fff0fff0dc00cc00c4000230033003b0fff0fff003b00330023000000000000000000000
+2b7f:00000000fcc0fcc030c078c0fcc030c030c030c030c030c033f031e030c033f033f000000000000000000000
+2b80:000000000000100030007000fff0fff07000308010c000e0fff0fff000e000c0008000000000000000000000
+2b81:000000000000000030c078c0fcc030c030c030c030c030c030c030c033f031e030c000000000000000000000
+2b82:000000000000008000c000e0fff0fff000e010c030807000fff0fff070003000100000000000000000000000
+2b83:000000000000000030c031e033f030c030c030c030c030c030c030c0fcc078c030c000000000000000000000
+2b84:00000000100030007000fff0fff070003000100030007000fff0fff070003000100000000000000000000000
+2b85:000000000000000030c079e0fff030c030c030c030c030c030c030c030c030c030c000000000000000000000
+2b86:00000000008000c000e0fff0fff000e000c0008000c000e0fff0fff000e000c0008000000000000000000000
+2b87:000000000000000030c030c030c030c030c030c030c030c030c030c0fff079e030c000000000000000000000
+2b88:00000f003fc07be073e0e3f0c0008000000000008000c000e3f073e07be03fc00f0000000000000000000000
+2b89:000000000f003fc079e070e0e070c0308010e070e070e070e070e07060606060204000000000000000000000
+2b8a:00000f003fc07de07ce0fc70003000100000000000100030fc707ce07de03fc00f0000000000000000000000
+2b8b:00000000204060606060e070e070e070e070e0708010c030e07070e079e03fc00f0000000000000000000000
+2b8c:00000000100030007000fe00ff8071c0306010600060006001c03f803e000000000000000000000000000000
+2b8d:00000000000000000000018003c007e00ff0c180c180c180c180c180e3807f003e0000000000000000000000
+2b8e:000000000f803f807000c000c000c100c18071c03fe00fe001c0018001000000000000000000000000000000
+2b8f:0000000000000000000007c00fe01c7018301830183018301830ff007e003c00180000000000000000000000
+2b90:00000000000001f001f00030103030607060ffc0ffc070003000100000000000000000000000000000000000
+2b91:000000000000f800f800c000c08060c060e03ff03ff000e000c0008000000000000000000000000000000000
+2b92:000000000000f9f0f9f000300030003002300630cff0cff00600020000000000000000000000000000000000
+2b93:000000000000f9f0f9f0c000c000c000c400c600ff30ff300600040000000000000000000000000000000000
+2b94:00000000000000000000020003001f8023407240f84021f024e02c401f800c00040000000000000000000000
+2b95:00000000000000000000000000000100018001c0ffe0fff0ffe001c001800100000000000000000000000000
+2b97:fff080109f9040205fa046202640264026401680108010800900090009000600060000000000000000000000
+2b98:00000000000000000000000000e003200c40308041007f003f800fc003e000e0000000000000000000000000
+2b99:000000000000000000000000060006000d000d001c801c803c403e40792070a0606000000000000000000000
+2b9a:00000000000000000000000070004c00230010c008200fe01fc03f007c007000000000000000000000000000
+2b9b:000000000000000000000000606050e049e027c023c0138013800b000b000600060000000000000000000000
+2b9c:00000000000000000000000000e003e00fc03f807f007f003f800fc003e000e0000000000000000000000000
+2b9d:000000000000000000000000060006000f000f001f801f803fc03fc079e070e0606000000000000000000000
+2b9e:00000000000000000000000070007c003f001fc00fe00fe01fc03f007c007000000000000000000000000000
+2b9f:000000000000000000000000606070e079e03fc03fc01f801f800f000f000600060000000000000000000000
+2ba0:000000000000000000300030103030307030fff0fff070003000100000000000000000000000000000000000
+2ba1:0000000000000000c000c000c080c0c0c0e0fff0fff000e000c0008000000000000000000000000000000000
+2ba2:0000000000000000100030007000fff0fff07030303010300030003000000000000000000000000000000000
+2ba3:0000000000000000008000c000e0fff0fff0c0e0c0c0c080c000c00000000000000000000000000000000000
+2ba4:000000000c001e003f007f800c000c000c000c000c000c000c000c000c000ff00ff000000000000000000000
+2ba5:00000000030007800fc01fe0030003000300030003000300030003000300ff00ff0000000000000000000000
+2ba6:000000000ff00ff00c000c000c000c000c000c000c000c000c007f803f001e000c0000000000000000000000
+2ba7:00000000ff00ff000300030003000300030003000300030003001fe00fc00780030000000000000000000000
+2ba8:00000000000000000000000000000800181038307ff0ffe07fc0380018000800000000000000000000000000
+2ba9:000000000000000000000000000001008180c1c0ffe07ff03fe001c001800100000000000000000000000000
+2baa:00000000000000000000000000000800180038007fc0ffe07ff0383018100800000000000000000000000000
+2bab:00000000000000000000000000000100018001c03fe07ff0ffe0c1c081800100000000000000000000000000
+2bac:0000000000000000000004000e001f003f807fc00e000e000e000e000e000700038000000000000000000000
+2bad:0000000000000000000004000e001f003f807fc00e000e000e000e000e001c00380000000000000000000000
+2bae:00000000000000000000038007000e000e000e000e000e007fc03f801f000e00040000000000000000000000
+2baf:0000000000000000000038001c000e000e000e000e000e007fc03f801f000e00040000000000000000000000
+2bb0:00000000011001b00150011005100d10151027f0402080404080270014000c00040000000000000000000000
+2bb1:000000008800d800a80088008a008b008a80fe404020201010200e4002800300020000000000000000000000
+2bb2:0000000004000c001400270040808040402027f015100d1005100110015001b0011000000000000000000000
+2bb3:000000000200030002800e40102020104020fe408a808b008a008800a800d800880000000000000000000000
+2bb4:0000000000000800140022004100e38022002200220023f012200a40062003f0000000000000000000000000
+2bb5:00000000000001000280044008201c70044004400440fc40448025004600fc00000000000000000000000000
+2bb6:00000000000003f006200a40122023f0220022002200e3804100220014000800000000000000000000000000
+2bb7:000000000000fc00460025004480fc400440044004401c700820044002800100000000000000000000000000
+2bb8:000000000600090010803fc04020f0f0108010801f80000000001f80108010801f8000000000000000000000
+2bb9:00000000000000000000000000000000fff0801086108f109990b0d0a0508010fff000000000000000000000
+2bba:000000000000000000001ff010101010ff9090909090909090909ff080808080ff8000000000000000000000
+2bbb:000000000000000000001ff01ff01ff0fff09ff09ff09ff09ff09ff080808080ff8000000000000000000000
+2bbc:000000000000000000001ff01ff01ff0fff0fff0fff0fff0fff0fff0ff80ff80ff8000000000000000000000
+2bbd:00000000000000000000fff08010a050909089108610861089109090a0508010fff000000000000000000000
+2bbe:00000000000000000e0031804040404091208a2084208a2091204040404031800e0000000000000000000000
+2bbf:000000000000000000001f803fc060606060d9b0c630c630d9b0606060603fc01f8000000000000000000000
+2bc0:0000000000000000000000003fc03fc03fc03fc03fc03fc03fc03fc03fc03fc0000000000000000000000000
+2bc1:00000000000000000000000006000f001f803fc07fe07fe03fc01f800f000600000000000000000000000000
+2bc2:00000000000000001f801f801f803fc03fc03fc07fe07fe07fe03fc01f800f00060000000000000000000000
+2bc3:0000000000000000000000000f001f803fc07fe07fe07fe07fe03fc01f800f00000000000000000000000000
+2bc4:0000000000000000000006001f803fc03fc07fe07fe0fff0fff07fe07fe03fc03fc01f800600000000000000
+2bc5:00000000000000000000060006000f000f001f801f803fc03fc07fe07fe0fff0fff000000000000000000000
+2bc6:00000000000000000000fff0fff07fe07fe03fc03fc01f801f800f000f000600060000000000000000000000
+2bc7:00000000000000000000003000f003f00ff03ff0fff0fff03ff00ff003f000f0003000000000000000000000
+2bc8:00000000000000000000c000f000fc00ff00ffc0fff0fff0ffc0ff00fc00f000c00000000000000000000000
+2bc9:000000000000000080108020824082808300820086008a009200a200c200fff0020007000880088008800700
+2bca:000000000000000000001f803fc07fe07fe0fff0fff000000000000000000000000000000000000000000000
+2bcb:00000000000000000000000000000000000000000000fff0fff07fe07fe03fc01f8000000000000000000000
+2bcc:00000000000000000000000004000e000e001f007fc0ffe07fc01f000e000e00040000000000000000000000
+2bcd:000000000000000000000000802060c07bc03f803f801f003f803f807bc060c0802000000000000000000000
+2bce:00000000000000000000000004000a000a00110060c0802060c011000a000a00040000000000000000000000
+2bcf:000000000000000000000000802060c05b40248020801100208024805b4060c0802000000000000000000000
+2bd0:00000000000000000000000004007fc0444044404040f1e04040444044407fc0040000000000000000000000
+2bd1:00000000000000000600090010802f4059a08310861086104020264010800900060000000000000000000000
+2bd2:00000000060006003fc03fc0060006003fc03fc0060006003fc03fc006000600060000000000000000000000
+2be8:0000000000000000040004000c000c00fc007c003c001c000c001c001c003800300000000000000000000000
+2be9:0000000000000000020002000300030003f003e003c0038003000380038001c000c000000000000000000000
+2bea:0000000000000000060006000d000d00fdf07c203c401c800d001c801e80394030c000000000000000000000
+2beb:0000000000000000060006000b000b00fbf043e023c013800b001380178029c030c000000000000000000000
+2bec:00000000000000000000084018c039c07bc0fff0fff07bc039c018c008400000000000000000000000000000
+2bed:00000000000006000f001f803fc07fe006000f001f803fc07fe0060006000600060000000000000000000000
+2bee:00000000000000000000084018c039c07bc0fff0fff07bc039c018c008400000000000000000000000000000
+2bef:00000000000006000600060006007fe03fc01f800f0006007fe03fc01f800f00060000000000000000000000
+2bf9:00000000000000000000ffe0ffe000000000ffe0ffe0000071c08a2084208a2071c000000000000000000000
+2bfa:00000000000000000000000000000000000071c08a208a208a2071c000000000000000000000000000000000
+2bfb:0000000000000000000000000000000000006060909096909090606000000000000000000000000000000000
+2bfc:000000000000000000000e001100110011000e00000000000e001100110011000e0000000000000000000000
+2bfd:000000000000000004000e001f003f8004000400040004000e001100110011000e0000000000000000000000
+2bfe:000000000000000000000030003000300030003000300030003000300030fff0fff000000000000000000000
+2bff:00000000000000007fe07fe07fe00600060007e007e007e0060006007fe07fe07fe000000000000000000000
+30a0:0000000000000000000000000000000000000000000000000000003ffffc3ffffc0000000000003ffffc3ffffc000000000000000000000000000000000000000000
+30b3:00000000000000000000000007ffe007ffe000006000006000006000006000006000006000006000006007ffe007ffe0000060000000000000000000000000000000
+30c1:0000000000000000000003e003ffe003fc00000c00000c000ffff80ffff8000c0000180000180000300000300000600000c000000000000000000000000000000000
+30cb:00000000000000000000000001ff8001ff8000000000000000000000000000000000000000000000000000000007fff007fff0000000000000000000000000000000
+30cf:00000000000000000000000000000000030000038000c18000c1c000c0c001c0e00180600180600380700300300700300e0030000000000000000000000000000000
+30f3:0000000000000000000000000e000007000003800001c0000000000000300000700000e0000380001e0000f80007c000070000000000000000000000000000000000
+e0a0:e000e080e1c0e3e0e7f0e1c0e1c0e1c0e1c0e1c0e1c0e1c0c3c087800f003c00f000e000e000e000e000e000
+e0a1:00000000f000600060006000608060807f807f80000070f038603c603660336031e030e0306078f000000000
+e0a2:000000001f803fc030c030c030c030c030c030c07fe07fe079e070e070e079e079e079e079e07fe000000000
+e0a3:000000003f007f8060806000600060807f803f000000000070f038603c603660336031e030e078f000000000
+e0b0:8000c000e000f000f800fc00fe00ff00ff80ffc0ffe0ffe0ffc0ff80ff00fe00fc00f800f000e000c0008000
+e0b1:c0006000300018000c0006000300018000c0006000300030006000c00180030006000c00180030006000c000
+e0b2:00100030007000f001f003f007f00ff01ff03ff07ff07ff03ff01ff00ff007f003f001f000f0007000300010
+e0b3:0030006000c00180030006000c00180030006000c000c0006000300018000c0006000300018000c000600030
+e0b4:e000f800fe00ff00ff80ffc0ffc0ffc0ffe0ffe0ffe0ffe0ffe0ffe0ffc0ffc0ffc0ff80ff00fe00f800e000
+e0b5:f0000c000300018000c000600060006000300030003000300030003000600060006000c0018003000c00f000
+e0b6:007001f007f00ff01ff03ff03ff03ff07ff07ff07ff07ff07ff07ff03ff03ff03ff01ff00ff007f001f00070
+e0b7:00f003000c0018003000600060006000c000c000c000c000c000c000600060006000300018000c00030000f0
+e0b8:80008000c000c000e000e000f000f000f800f800fc00fc00fe00fe00ff00ff00ff80ff80ffc0ffc0ffe0ffe0
+e0b9:c000c0006000600030003000180018000c000c0006000600030003000180018000c000c00060006000300030
+e0ba:00100010003000300070007000f000f001f001f003f003f007f007f00ff00ff01ff01ff03ff03ff07ff07ff0
+e0bb:003000300060006000c000c00180018003000300060006000c000c00180018003000300060006000c000c000
+e0bc:ffe0ffe0ffc0ffc0ff80ff80ff00ff00fe00fe00fc00fc00f800f800f000f000e000e000c000c00080008000
+e0bd:003000300060006000c000c00180018003000300060006000c000c00180018003000300060006000c000c000
+e0be:7ff07ff03ff03ff01ff01ff00ff00ff007f007f003f003f001f001f000f000f0007000700030003000100010
+e0bf:c000c0006000600030003000180018000c000c0006000600030003000180018000c000c00060006000300030
+e0c0:8000f000e700fc00f8e0fff0ff00fc00ff00ff80ffe0fe60fc00ff80ff00f9c0f000f800ff00e3c0c0008000
+e0c1:8000f00067001c0018e007f003000c000300018001e006600c000380070019c0100018001f0063c0c0008000
+e0c2:001000f00e7003f071f0fff00ff003f00ff01ff07ff067f003f01ff00ff039f000f001f00ff03c7000300010
+e0c3:001000f00e6003807180fe000c0003000c0018007800660003001c000e003980008001800f803c6000300010
+e0c4:db20db0000000020d900d90000400100d840d80001000100d800d88000000100c100c80000000000c800c800
+e0c5:4db00db00000400009b009b02000080021b001b00800080001b011b000000800083001300000000001300130
+e0c6:0000ee60ee60ee000060ee00ee00eec00000e680e600e0800600e600e000e4000000e600e600e00008000000
+e0c7:0000677067700770600007700770377000001670067010700600067000700270000006700670007001000000
+e0c8:0000f000c000fe00ff80e000fe00ffe0ff00f000ff80e000fc00e000ff00fff0fc00e000ff00c000f8000000
+e0ca:000000f0003007f01ff0007007f07ff00ff000f01ff0007003f000700ff0fff003f000700ff0003001f00000
+e0cc:c000c000e000e000f000f000e180e180c3c0c3c007e007e0c3c0c3c0e180e180f000f000e000e000c000c000
+e0cd:c00040002000200010001000218021804240c24004200420c24042402180218010001000200020004000c000
+e0ce:ff00ff00fd80fd80fbc0fa60f4f0f4f0ecf0ee600ff00ff0ee60ecf0f4f0f4f0fa60fbc0fd80fd80ff00ff00
+e0cf:0000060006001f801f806f606060f0f0fff0ef706060b0d0dfb0ef70f0f0f9f0f9f0f9f079e039c019800900
+e0d0:00000000000071c08a208a208a2079e071c0000000000000000071c08a208a208a2079e071c0000000000000
+e0d1:fc00fc00ffe0fc20fc20ffe0ffe0ffe0ffe0fc00fc00fc00fc00ffe0fc20fc20ffe0ffe0ffe0ffe0fc00fc00
+e0d2:fff0ffe0ffe0ffc0ffc0ff80ff80ff00ff000000000000000000ff00ff00ff80ff80ffc0ffc0ffe0ffe0fff0
+e0d4:fff07ff07ff03ff03ff01ff01ff00ff00ff000000000000000000ff00ff01ff01ff03ff03ff07ff07ff0fff0
+e800:7770ddd0bbb0eee07770ddd0bbb0eee07770ddd0bbb0eee07770ddd0bbb0eee07770ddd0bbb0eee07770ddd0
+e801:bbb0eee07770ddd0bbb0eee07770ddd0bbb0eee07770ddd0bbb0eee07770ddd0bbb0eee07770ddd0bbb0eee0
+e802:8880222044401110888022204440111088802220444011108880222044401110888022204440111088802220
+e803:4440111088802220444011108880222044401110888022204440111088802220444011108880222044401110
+fb00:000000001ce0273023306310631063006300ffc0630063006300630063006300f78000000000000000000000
+fb01:000000000700098008c018c018c0180018003fc018c018c018c018c018c018c039e000000000000000000000
+fb02:000000000ec013c011c031c031c030c030c07fc030c030c030c030c030c030c079e000000000000000000000
+fb03:0000000019c0266026606660666066006600fff0666066606660666066606660f7f000000000000000000000
+fb04:0000000019a026e026e066e0666066606660ffe0666066606660666066606660f7f000000000000000000000
+fb05:000000000f00198018c030c030c030c030c073f030c030c030c030c030c030c079e000000000000000000000
+fb06:000000000000038007c00cc00cc07ec0c6c0c2f0e0c070c01cc00ec086c0c6c0fc7000000000000000000000
+fff9:0000aaa00000fbe082008200f3c082008200820000000000fbe082208220f3e08020802083e00000aaa00000
+fffa:0000aaa00000fbe082008200f3c082008200820000000000f9c082208220f3e08220822082200000aaa00000
+fffb:0000aaa00000fbe082008200f3c082008200820000000000fbc082208220f3c08220822083c00000aaa00000
+fffc:0000aaa00000fbe082008200f3c082008200820000000000f9e082008200f2008200820081e00000aaa00000
+fffd:06000f001f803fc040204f20d9b0c1b0c1b0c330c630c030c630462040203fc01f800f000600000000000000
+fffe:0000aaa00000fbe082008200f3c082008200820000000000fbe082008200f3c08200820083e00000aaa00000
+ffff:0000aaa00000fbe082008200f3c082008200820000000000fbe082008200f3c08200820082000000aaa00000
diff --git a/sys/arm64/arm64/elf32_machdep.c b/sys/arm64/arm64/elf32_machdep.c
index 5c81c6cdce3d..8f8a934ad520 100644
--- a/sys/arm64/arm64/elf32_machdep.c
+++ b/sys/arm64/arm64/elf32_machdep.c
@@ -225,7 +225,7 @@ freebsd32_fetch_syscall_args(struct thread *td)
sa->args[i] = ap[i];
if (narg > nap) {
if (narg - nap > nitems(args))
- panic("Too many system call arguiments");
+ panic("Too many system call arguments");
error = copyin((void *)td->td_frame->tf_x[13], args,
(narg - nap) * sizeof(int));
if (error != 0)
diff --git a/sys/compat/linuxkpi/common/include/linux/ieee80211.h b/sys/compat/linuxkpi/common/include/linux/ieee80211.h
index b9161c586d07..17041bb03ce8 100644
--- a/sys/compat/linuxkpi/common/include/linux/ieee80211.h
+++ b/sys/compat/linuxkpi/common/include/linux/ieee80211.h
@@ -408,6 +408,14 @@ enum ieee80211_sta_state {
IEEE80211_STA_AUTHORIZED = 4, /* 802.1x */
};
+enum ieee80211_sta_rx_bandwidth {
+ IEEE80211_STA_RX_BW_20 = 0,
+ IEEE80211_STA_RX_BW_40,
+ IEEE80211_STA_RX_BW_80,
+ IEEE80211_STA_RX_BW_160,
+ IEEE80211_STA_RX_BW_320,
+};
+
enum ieee80211_tx_info_flags {
/* XXX TODO .. right shift numbers - not sure where that came from? */
IEEE80211_TX_CTL_AMPDU = BIT(0),
@@ -524,24 +532,24 @@ struct ieee80211_mgmt {
uint16_t beacon_int;
uint16_t capab_info;
uint8_t variable[0];
- } beacon;
+ } __packed beacon;
/* 9.3.3.5 Association Request frame format */
struct {
uint16_t capab_info;
uint16_t listen_interval;
uint8_t variable[0];
- } assoc_req;
+ } __packed assoc_req;
/* 9.3.3.10 Probe Request frame format */
struct {
uint8_t variable[0];
- } probe_req;
+ } __packed probe_req;
/* 9.3.3.11 Probe Response frame format */
struct {
uint64_t timestamp;
uint16_t beacon_int;
uint16_t capab_info;
uint8_t variable[0];
- } probe_resp;
+ } __packed probe_resp;
/* 9.3.3.14 Action frame format */
struct {
/* 9.4.1.11 Action field */
@@ -557,7 +565,7 @@ struct ieee80211_mgmt {
uint8_t tpc_elem_length;
uint8_t tpc_elem_tx_power;
uint8_t tpc_elem_link_margin;
- } tpc_report;
+ } __packed tpc_report;
/* 9.6.8.33 Fine Timing Measurement frame format */
struct {
uint8_t dialog_token;
@@ -567,7 +575,7 @@ struct ieee80211_mgmt {
uint16_t tod_error;
uint16_t toa_error;
uint8_t variable[0];
- } ftm;
+ } __packed ftm;
/* 802.11-2016, 9.6.5.2 ADDBA Request frame format */
struct {
uint8_t action_code;
@@ -577,16 +585,16 @@ struct ieee80211_mgmt {
uint16_t start_seq_num;
/* Optional follows... */
uint8_t variable[0];
- } addba_req;
+ } __packed addba_req;
/* XXX */
struct {
uint8_t dialog_token;
- } wnm_timing_msr;
+ } __packed wnm_timing_msr;
} u;
- } action;
+ } __packed action;
DECLARE_FLEX_ARRAY(uint8_t, body);
} u;
-};
+} __packed __aligned(2);
struct ieee80211_cts { /* net80211::ieee80211_frame_cts */
__le16 frame_control;
diff --git a/sys/compat/linuxkpi/common/include/linux/skbuff.h b/sys/compat/linuxkpi/common/include/linux/skbuff.h
index c8ad90281e34..0f192ceab318 100644
--- a/sys/compat/linuxkpi/common/include/linux/skbuff.h
+++ b/sys/compat/linuxkpi/common/include/linux/skbuff.h
@@ -120,7 +120,7 @@ enum sk_checksum_flags {
CHECKSUM_NONE = 0x00,
CHECKSUM_UNNECESSARY = 0x01,
CHECKSUM_PARTIAL = 0x02,
- CHECKSUM_COMPLETE = 0x04,
+ CHECKSUM_COMPLETE = 0x03,
};
struct skb_frag {
@@ -170,7 +170,7 @@ struct sk_buff {
};
};
uint16_t protocol;
- uint8_t ip_summed;
+ uint8_t ip_summed; /* 2 bit only. */
/* uint8_t */
/* "Scratch" area for layers to store metadata. */
diff --git a/sys/compat/linuxkpi/common/include/linux/string_helpers.h b/sys/compat/linuxkpi/common/include/linux/string_helpers.h
index 1bdff2730361..2c6fe0b1708d 100644
--- a/sys/compat/linuxkpi/common/include/linux/string_helpers.h
+++ b/sys/compat/linuxkpi/common/include/linux/string_helpers.h
@@ -66,4 +66,6 @@ str_enable_disable(bool value)
return "disable";
}
+#define str_disable_enable(_v) str_enable_disable(!(_v))
+
#endif
diff --git a/sys/compat/linuxkpi/common/include/net/mac80211.h b/sys/compat/linuxkpi/common/include/net/mac80211.h
index 0106e6648bd4..8de03410c6b6 100644
--- a/sys/compat/linuxkpi/common/include/net/mac80211.h
+++ b/sys/compat/linuxkpi/common/include/net/mac80211.h
@@ -737,7 +737,7 @@ struct ieee80211_link_sta {
struct ieee80211_he_6ghz_capa he_6ghz_capa;
struct ieee80211_sta_eht_cap eht_cap;
uint8_t rx_nss;
- enum ieee80211_sta_rx_bw bandwidth;
+ enum ieee80211_sta_rx_bandwidth bandwidth;
enum ieee80211_smps_mode smps_mode;
struct ieee80211_sta_agg agg;
struct ieee80211_sta_txpwr txpwr;
diff --git a/sys/compat/linuxkpi/common/src/linux_80211.c b/sys/compat/linuxkpi/common/src/linux_80211.c
index e248588dd275..87390145a296 100644
--- a/sys/compat/linuxkpi/common/src/linux_80211.c
+++ b/sys/compat/linuxkpi/common/src/linux_80211.c
@@ -77,6 +77,8 @@
#include <linux/rculist.h>
#include "linux_80211.h"
+/* #define LKPI_80211_USE_SCANLIST */
+/* #define LKPI_80211_BGSCAN */
#define LKPI_80211_WME
#define LKPI_80211_HW_CRYPTO
#define LKPI_80211_HT
@@ -103,6 +105,10 @@ SYSCTL_DECL(_compat_linuxkpi);
SYSCTL_NODE(_compat_linuxkpi, OID_AUTO, 80211, CTLFLAG_RW | CTLFLAG_MPSAFE, 0,
"LinuxKPI 802.11 compatibility layer");
+static bool lkpi_order_scanlist = false;
+SYSCTL_BOOL(_compat_linuxkpi_80211, OID_AUTO, order_scanlist, CTLFLAG_RW,
+ &lkpi_order_scanlist, 0, "Enable LinuxKPI 802.11 scan list shuffeling");
+
#if defined(LKPI_80211_HW_CRYPTO)
static bool lkpi_hwcrypto = false;
SYSCTL_BOOL(_compat_linuxkpi_80211, OID_AUTO, hw_crypto, CTLFLAG_RDTUN,
@@ -167,6 +173,7 @@ const struct cfg80211_ops linuxkpi_mac80211cfgops = {
static struct lkpi_sta *lkpi_find_lsta_by_ni(struct lkpi_vif *,
struct ieee80211_node *);
#endif
+static void lkpi_sw_scan_task(void *, int);
static void lkpi_80211_txq_tx_one(struct lkpi_sta *, struct mbuf *);
static void lkpi_80211_txq_task(void *, int);
static void lkpi_80211_lhw_rxq_task(void *, int);
@@ -394,7 +401,7 @@ lkpi_80211_dump_stas(SYSCTL_HANDLER_ARGS)
return (0);
}
-static enum ieee80211_sta_rx_bw
+static enum ieee80211_sta_rx_bandwidth
lkpi_cw_to_rx_bw(enum nl80211_chan_width cw)
{
switch (cw) {
@@ -418,7 +425,7 @@ lkpi_cw_to_rx_bw(enum nl80211_chan_width cw)
}
static enum nl80211_chan_width
-lkpi_rx_bw_to_cw(enum ieee80211_sta_rx_bw rx_bw)
+lkpi_rx_bw_to_cw(enum ieee80211_sta_rx_bandwidth rx_bw)
{
switch (rx_bw) {
case IEEE80211_STA_RX_BW_20:
@@ -439,7 +446,7 @@ lkpi_sync_chanctx_cw_from_rx_bw(struct ieee80211_hw *hw,
struct ieee80211_vif *vif, struct ieee80211_sta *sta)
{
struct ieee80211_chanctx_conf *chanctx_conf;
- enum ieee80211_sta_rx_bw old_bw;
+ enum ieee80211_sta_rx_bandwidth old_bw;
uint32_t changed;
chanctx_conf = rcu_dereference_protected(vif->bss_conf.chanctx_conf,
@@ -544,7 +551,7 @@ static void
lkpi_sta_sync_vht_from_ni(struct ieee80211_vif *vif, struct ieee80211_sta *sta,
struct ieee80211_node *ni)
{
- enum ieee80211_sta_rx_bw bw;
+ enum ieee80211_sta_rx_bandwidth bw;
uint32_t width;
int rx_nss;
uint16_t rx_mcs_map;
@@ -955,6 +962,30 @@ lkpi_nl80211_band_to_net80211_band(enum nl80211_band band)
return (0x00);
}
+#ifdef LINUXKPI_DEBUG_80211
+static const char *
+lkpi_nl80211_band_name(enum nl80211_band band)
+{
+ switch (band) {
+ case NL80211_BAND_2GHZ:
+ return "2Ghz";
+ break;
+ case NL80211_BAND_5GHZ:
+ return "5Ghz";
+ break;
+ case NL80211_BAND_60GHZ:
+ return "60Ghz";
+ break;
+ case NL80211_BAND_6GHZ:
+ return "6Ghz";
+ break;
+ default:
+ panic("%s: unsupported band %u\n", __func__, band);
+ break;
+ }
+}
+#endif
+
#if 0
static enum ieee80211_ac_numbers
lkpi_ac_net_to_l80211(int ac)
@@ -1319,6 +1350,7 @@ lkpi_iv_key_delete(struct ieee80211vap *vap, const struct ieee80211_key *k)
lhw = ic->ic_softc;
hw = LHW_TO_HW(lhw);
lvif = VAP_TO_LVIF(vap);
+ vif = LVIF_TO_VIF(lvif);
/*
* Make sure we do not make it here without going through
@@ -1326,6 +1358,23 @@ lkpi_iv_key_delete(struct ieee80211vap *vap, const struct ieee80211_key *k)
*/
lockdep_assert_wiphy(hw->wiphy);
+ /*
+ * While we are assoc we may still send packets. We cannot delete the
+ * keys as otherwise packets could go out unencrypted. Some firmware
+ * does not like this and will fire an assert.
+ * net80211 needs to drive this better but given we want the disassoc
+ * frame out and have to unlock we are open to a race currently.
+ * This check should prevent problems.
+ * How to test: run 800Mbit/s UDP traffic and during that restart your
+ * supplicant. You want to survive that.
+ */
+ if (vif->cfg.assoc) {
+ if (linuxkpi_debug_80211 & D80211_TRACE_HW_CRYPTO)
+ ic_printf(ic, "%d %lu %s: vif still assoc; not deleting keys\n",
+ curthread->td_tid, jiffies, __func__);
+ return (0);
+ }
+
if (IEEE80211_KEY_UNDEFINED(k)) {
ic_printf(ic, "%s: vap %p key %p is undefined: %p %u\n",
__func__, vap, k, k->wk_cipher, k->wk_keyix);
@@ -1370,7 +1419,6 @@ lkpi_iv_key_delete(struct ieee80211vap *vap, const struct ieee80211_key *k)
kc->keyidx, kc->hw_key_idx, kc->flags, IEEE80211_KEY_FLAG_BITS);
#endif
- vif = LVIF_TO_VIF(lvif);
error = lkpi_80211_mo_set_key(hw, DISABLE_KEY, vif, sta, kc);
if (error != 0) {
ic_printf(ic, "%d %lu %s: set_key cmd %d(%s) for sta %6D failed: %d\n",
@@ -1842,13 +1890,13 @@ lkpi_update_dtim_tsf(struct ieee80211_vif *vif, struct ieee80211_node *ni,
vif->bss_conf.beacon_int = 16;
bss_changed |= BSS_CHANGED_BEACON_INT;
}
- if (vif->bss_conf.dtim_period != vap->iv_dtim_period &&
- vap->iv_dtim_period > 0) {
- vif->bss_conf.dtim_period = vap->iv_dtim_period;
+ if (vif->bss_conf.dtim_period != ni->ni_dtim_period &&
+ ni->ni_dtim_period > 0) {
+ vif->bss_conf.dtim_period = ni->ni_dtim_period;
bss_changed |= BSS_CHANGED_BEACON_INFO;
}
- vif->bss_conf.sync_dtim_count = vap->iv_dtim_count;
+ vif->bss_conf.sync_dtim_count = ni->ni_dtim_count;
vif->bss_conf.sync_tsf = le64toh(ni->ni_tstamp.tsf);
/* vif->bss_conf.sync_device_ts = set in linuxkpi_ieee80211_rx. */
@@ -1876,6 +1924,8 @@ lkpi_stop_hw_scan(struct lkpi_hw *lhw, struct ieee80211_vif *vif)
int error;
bool cancel;
+ TRACE_SCAN(lhw->ic, "scan_flags %b", lhw->scan_flags, LKPI_LHW_SCAN_BITS);
+
LKPI_80211_LHW_SCAN_LOCK(lhw);
cancel = (lhw->scan_flags & LKPI_LHW_SCAN_RUNNING) != 0;
LKPI_80211_LHW_SCAN_UNLOCK(lhw);
@@ -2798,6 +2848,14 @@ _lkpi_sta_assoc_to_down(struct ieee80211vap *vap, enum ieee80211_state nstate, i
bss_changed = 0;
bss_changed |= lkpi_disassoc(sta, vif, lhw);
+#ifdef LKPI_80211_HW_CRYPTO
+ /*
+ * In theory we remove keys here but there must not exist any for this
+ * state change until we clean them up again into small steps and no
+ * code duplication.
+ */
+#endif
+
lkpi_lsta_dump(lsta, ni, __func__, __LINE__);
/* Adjust sta and change state (from NONE) to NOTEXIST. */
@@ -3333,6 +3391,16 @@ lkpi_sta_run_to_init(struct ieee80211vap *vap, enum ieee80211_state nstate, int
#ifdef LKPI_80211_HW_CRYPTO
if (lkpi_hwcrypto) {
+ /*
+ * In theory we only need to do this if we changed assoc.
+ * If we were not assoc, there should be no keys and we
+ * should not be here.
+ */
+#ifdef notyet
+ KASSERT((bss_changed & BSS_CHANGED_ASSOC) != 0, ("%s: "
+ "trying to remove keys but were not assoc: %#010jx, lvif %p\n",
+ __func__, (uintmax_t)bss_changed, lvif));
+#endif
error = lkpi_sta_del_keys(hw, vif, lsta);
if (error != 0) {
ic_printf(vap->iv_ic, "%s:%d: lkpi_sta_del_keys "
@@ -3394,6 +3462,9 @@ lkpi_sta_run_to_init(struct ieee80211vap *vap, enum ieee80211_state nstate, int
* 4) call unassign_vif_chanctx
* 5) call lkpi_hw_conf_idle
* 6) call remove_chanctx
+ *
+ * Note: vif->driver_flags & IEEE80211_VIF_REMOVE_AP_AFTER_DISASSOC
+ * might change this.
*/
bss_changed |= lkpi_disassoc(sta, vif, lhw);
@@ -3545,7 +3616,7 @@ lkpi_iv_newstate(struct ieee80211vap *vap, enum ieee80211_state nstate, int arg)
vif = LVIF_TO_VIF(lvif);
/* No need to replicate this in most state handlers. */
- if (ostate == IEEE80211_S_SCAN && nstate != IEEE80211_S_SCAN)
+ if (nstate > IEEE80211_S_SCAN)
lkpi_stop_hw_scan(lhw, vif);
s = sta_state_fsm;
@@ -3824,6 +3895,7 @@ lkpi_ic_vap_create(struct ieee80211com *ic, const char name[IFNAMSIZ],
lvif = malloc(len, M_80211_VAP, M_WAITOK | M_ZERO);
mtx_init(&lvif->mtx, "lvif", NULL, MTX_DEF);
+ TASK_INIT(&lvif->sw_scan_task, 0, lkpi_sw_scan_task, lvif);
INIT_LIST_HEAD(&lvif->lsta_list);
lvif->lvif_bss = NULL;
refcount_init(&lvif->nt_unlocked, 0);
@@ -4062,6 +4134,8 @@ lkpi_ic_vap_delete(struct ieee80211vap *vap)
/* Clear up per-VIF/VAP sysctls. */
sysctl_ctx_free(&lvif->sysctl_ctx);
+ ieee80211_draintask(ic, &lvif->sw_scan_task);
+
LKPI_80211_LHW_LVIF_LOCK(lhw);
TAILQ_REMOVE(&lhw->lvif_head, lvif, lvif_entry);
LKPI_80211_LHW_LVIF_UNLOCK(lhw);
@@ -4303,6 +4377,113 @@ lkpi_scan_ies_add(uint8_t *p, struct ieee80211_scan_ies *scan_ies,
}
static void
+lkpi_enable_hw_scan(struct lkpi_hw *lhw)
+{
+
+ if (lhw->ops->hw_scan) {
+ /*
+ * Advertise full-offload scanning.
+ *
+ * Not limiting to SINGLE_SCAN_ON_ALL_BANDS here as otherwise
+ * we essentially disable hw_scan for all drivers not setting
+ * the flag.
+ */
+ lhw->ic->ic_flags_ext |= IEEE80211_FEXT_SCAN_OFFLOAD;
+ lhw->scan_flags |= LKPI_LHW_SCAN_HW;
+ }
+}
+
+#ifndef LKPI_80211_USE_SCANLIST
+static const uint32_t chan_pri[] = {
+ 5180, 5500, 5745,
+ 5260, 5580, 5660, 5825,
+ 5220, 5300, 5540, 5620, 5700, 5785, 5865,
+ 2437, 2412, 2422, 2462, 2472, 2432, 2452
+};
+
+static int
+lkpi_scan_chan_list_idx(const struct linuxkpi_ieee80211_channel *lc)
+{
+ int i;
+
+ for (i = 0; i < nitems(chan_pri); i++) {
+ if (lc->center_freq == chan_pri[i])
+ return (i);
+ }
+
+ return (-1);
+}
+
+static int
+lkpi_scan_chan_list_comp(const struct linuxkpi_ieee80211_channel *lc1,
+ const struct linuxkpi_ieee80211_channel *lc2)
+{
+ int idx1, idx2;
+
+ /* Find index in list. */
+ idx1 = lkpi_scan_chan_list_idx(lc1);
+ idx2 = lkpi_scan_chan_list_idx(lc2);
+
+ if (idx1 == -1 && idx2 != -1)
+ return (1);
+ if (idx1 != -1 && idx2 == -1)
+ return (-1);
+
+ /* Neither on the list, use center_freq. */
+ if (idx1 == -1 && idx2 == -1)
+ return (lc1->center_freq - lc2->center_freq);
+
+ /* Whichever is first in the list. */
+ return (idx1 - idx2);
+}
+
+static void
+lkpi_scan_chan_list_resort(struct linuxkpi_ieee80211_channel **cpp, size_t nchan)
+{
+ struct linuxkpi_ieee80211_channel *lc, *nc;
+ size_t i, j;
+ int rc;
+
+ for (i = (nchan - 1); i > 0; i--) {
+ for (j = i; j > 0 ; j--) {
+ lc = *(cpp + j);
+ nc = *(cpp + j - 1);
+ rc = lkpi_scan_chan_list_comp(lc, nc);
+ if (rc < 0) {
+ *(cpp + j) = nc;
+ *(cpp + j - 1) = lc;
+ }
+ }
+ }
+}
+
+static bool
+lkpi_scan_chan(struct linuxkpi_ieee80211_channel *c,
+ struct ieee80211com *ic, bool log)
+{
+
+ if ((c->flags & IEEE80211_CHAN_DISABLED) != 0) {
+ if (log)
+ TRACE_SCAN(ic, "Skipping disabled chan "
+ "on band %s [%#x/%u/%#x]",
+ lkpi_nl80211_band_name(c->band), c->hw_value,
+ c->center_freq, c->flags);
+ return (false);
+ }
+ if (isclr(ic->ic_chan_active, ieee80211_mhz2ieee(c->center_freq,
+ lkpi_nl80211_band_to_net80211_band(c->band)))) {
+ if (log)
+ TRACE_SCAN(ic, "Skipping !active chan "
+ "on band %s [%#x/%u/%#x]",
+ lkpi_nl80211_band_name(c->band), c->hw_value,
+ c->center_freq, c->flags);
+ return (false);
+ }
+ return (true);
+}
+#endif
+
+static void
lkpi_ic_scan_start(struct ieee80211com *ic)
{
struct lkpi_hw *lhw;
@@ -4315,35 +4496,52 @@ lkpi_ic_scan_start(struct ieee80211com *ic)
bool is_hw_scan;
lhw = ic->ic_softc;
+ ss = ic->ic_scan;
+ vap = ss->ss_vap;
+ TRACE_SCAN(ic, "scan_flags %b", lhw->scan_flags, LKPI_LHW_SCAN_BITS);
+
LKPI_80211_LHW_SCAN_LOCK(lhw);
if ((lhw->scan_flags & LKPI_LHW_SCAN_RUNNING) != 0) {
/* A scan is still running. */
LKPI_80211_LHW_SCAN_UNLOCK(lhw);
+ TRACE_SCAN(ic, "Trying to start new scan while still running; "
+ "cancelling new net80211 scan; scan_flags %b",
+ lhw->scan_flags, LKPI_LHW_SCAN_BITS);
+ ieee80211_cancel_scan(vap);
return;
}
is_hw_scan = (lhw->scan_flags & LKPI_LHW_SCAN_HW) != 0;
LKPI_80211_LHW_SCAN_UNLOCK(lhw);
- ss = ic->ic_scan;
- vap = ss->ss_vap;
+#if 0
if (vap->iv_state != IEEE80211_S_SCAN) {
- IMPROVE("We need to be able to scan if not in S_SCAN");
+ TODO("We need to be able to scan if not in S_SCAN");
+ TRACE_SCAN(ic, "scan_flags %b iv_state %d",
+ lhw->scan_flags, LKPI_LHW_SCAN_BITS, vap->iv_state);
+ ieee80211_cancel_scan(vap);
return;
}
+#endif
hw = LHW_TO_HW(lhw);
if (!is_hw_scan) {
/* If hw_scan is cleared clear FEXT_SCAN_OFFLOAD too. */
vap->iv_flags_ext &= ~IEEE80211_FEXT_SCAN_OFFLOAD;
-sw_scan:
+
lvif = VAP_TO_LVIF(vap);
vif = LVIF_TO_VIF(lvif);
if (vap->iv_state == IEEE80211_S_SCAN)
lkpi_hw_conf_idle(hw, false);
+ LKPI_80211_LHW_SCAN_LOCK(lhw);
+ lhw->scan_flags |= LKPI_LHW_SCAN_RUNNING;
+ LKPI_80211_LHW_SCAN_UNLOCK(lhw);
+
lkpi_update_mcast_filter(ic);
+ TRACE_SCAN(vap->iv_ic, "Starting SW_SCAN: scan_flags %b",
+ lhw->scan_flags, LKPI_LHW_SCAN_BITS);
lkpi_80211_mo_sw_scan_start(hw, vif, vif->addr);
/* net80211::scan_start() handled PS for us. */
IMPROVE();
@@ -4358,6 +4556,9 @@ sw_scan:
struct cfg80211_scan_6ghz_params *s6gp;
size_t chan_len, nchan, ssids_len, s6ghzlen;
int band, i, ssid_count, common_ie_len;
+#ifndef LKPI_80211_USE_SCANLIST
+ int n;
+#endif
uint32_t band_mask;
uint8_t *ie, *ieend;
bool running;
@@ -4369,7 +4570,8 @@ sw_scan:
band_mask = 0;
nchan = 0;
if (ieee80211_hw_check(hw, SINGLE_SCAN_ON_ALL_BANDS)) {
-#if 0 /* Avoid net80211 scan lists until it has proper scan offload support. */
+#ifdef LKPI_80211_USE_SCANLIST
+ /* Avoid net80211 scan lists until it has proper scan offload support. */
for (i = ss->ss_next; i < ss->ss_last; i++) {
nchan++;
band = lkpi_net80211_chan_to_nl80211_band(
@@ -4387,8 +4589,17 @@ sw_scan:
continue;
}
if (hw->wiphy->bands[band] != NULL) {
- nchan += hw->wiphy->bands[band]->n_channels;
+ struct linuxkpi_ieee80211_channel *channels;
+ int n;
+
band_mask |= (1 << band);
+
+ channels = hw->wiphy->bands[band]->channels;
+ n = hw->wiphy->bands[band]->n_channels;
+ for (i = 0; i < n; i++) {
+ if (lkpi_scan_chan(&channels[i], ic, true))
+ nchan++;
+ }
}
}
#endif
@@ -4427,11 +4638,32 @@ sw_scan:
/* hw_req->req.wdev */
hw_req->req.wiphy = hw->wiphy;
hw_req->req.no_cck = false; /* XXX */
-#if 0
- /* This seems to pessimise default scanning behaviour. */
- hw_req->req.duration_mandatory = TICKS_2_USEC(ss->ss_mindwell);
- hw_req->req.duration = TICKS_2_USEC(ss->ss_maxdwell);
-#endif
+
+ /*
+ * In general setting duration[_mandatory] seems to pessimise
+ * default scanning behaviour. We only use it for BGSCANnig
+ * to keep the dwell times small.
+ * Setting duration_mandatory makes this the maximum dwell
+ * time (otherwise may be shorter). Duration is in TU.
+ */
+ if ((ic->ic_flags_ext & IEEE80211_FEXT_BGSCAN) != 0) {
+ unsigned long dwell;
+
+ if ((ic->ic_caps & IEEE80211_C_BGSCAN) == 0 ||
+ (vap->iv_flags & IEEE80211_F_BGSCAN) == 0)
+ ic_printf(ic, "BGSCAN despite off: %b, %b, %b\n",
+ ic->ic_flags_ext, IEEE80211_FEXT_BITS,
+ vap->iv_flags, IEEE80211_F_BITS,
+ ic->ic_caps, IEEE80211_C_BITS);
+
+ dwell = ss->ss_mindwell;
+ if (dwell == 0)
+ dwell = msecs_to_ticks(20);
+
+ hw_req->req.duration_mandatory = true;
+ hw_req->req.duration = TICKS_2_USEC(dwell) / 1024;
+ }
+
#ifdef __notyet__
hw_req->req.flags |= NL80211_SCAN_FLAG_RANDOM_ADDR;
memcpy(hw_req->req.mac_addr, xxx, IEEE80211_ADDR_LEN);
@@ -4442,11 +4674,12 @@ sw_scan:
hw_req->req.n_channels = nchan;
cpp = (struct linuxkpi_ieee80211_channel **)(hw_req + 1);
lc = (struct linuxkpi_ieee80211_channel *)(cpp + nchan);
+#ifdef LKPI_80211_USE_SCANLIST
for (i = 0; i < nchan; i++) {
*(cpp + i) =
(struct linuxkpi_ieee80211_channel *)(lc + i);
}
-#if 0 /* Avoid net80211 scan lists until it has proper scan offload support. */
+ /* Avoid net80211 scan lists until it has proper scan offload support. */
for (i = 0; i < nchan; i++) {
struct ieee80211_channel *c;
@@ -4459,7 +4692,9 @@ sw_scan:
lc++;
}
#else
- for (band = 0; band < NUM_NL80211_BANDS; band++) {
+ /* Add bands in reverse order for scanning. */
+ n = 0;
+ for (band = NUM_NL80211_BANDS - 1; band >= 0; band--) {
struct ieee80211_supported_band *supband;
struct linuxkpi_ieee80211_channel *channels;
@@ -4474,11 +4709,30 @@ sw_scan:
channels = supband->channels;
for (i = 0; i < supband->n_channels; i++) {
- *lc = channels[i];
- lc++;
+ if (lkpi_scan_chan(&channels[i], ic, false))
+ *(cpp + n++) = &channels[i];
+ }
+ }
+ if (lkpi_order_scanlist)
+ lkpi_scan_chan_list_resort(cpp, nchan);
+
+ if ((linuxkpi_debug_80211 & D80211_SCAN) != 0) {
+ printf("%s:%d: %s SCAN Channel List (nchan=%zu): ",
+ __func__, __LINE__, ic->ic_name, nchan);
+ for (i = 0; i < nchan; i++) {
+ struct linuxkpi_ieee80211_channel *xc;
+
+ xc = *(cpp + i);
+ printf(" %d(%d)",
+ ieee80211_mhz2ieee(xc->center_freq,
+ lkpi_nl80211_band_to_net80211_band(
+ xc->band)),
+ xc->center_freq);
}
+ printf("\n");
}
#endif
+
hw_req->req.n_ssids = ssid_count;
if (hw_req->req.n_ssids > 0) {
ssids = (struct cfg80211_ssid *)lc;
@@ -4505,6 +4759,7 @@ sw_scan:
ieend = lkpi_scan_ies_add(ie, &hw_req->ies, band_mask, vap, hw);
hw_req->req.ie = ie;
hw_req->req.ie_len = ieend - ie;
+ hw_req->req.scan_start = jiffies;
lvif = VAP_TO_LVIF(vap);
vif = LVIF_TO_VIF(lvif);
@@ -4522,13 +4777,30 @@ sw_scan:
LKPI_80211_LHW_SCAN_UNLOCK(lhw);
if (running) {
free(hw_req, M_LKPI80211);
+ TRACE_SCAN(ic, "Trying to start new scan while still "
+ "running (2); cancelling new net80211 scan; "
+ "scan_flags %b",
+ lhw->scan_flags, LKPI_LHW_SCAN_BITS);
+ ieee80211_cancel_scan(vap);
return;
}
lkpi_update_mcast_filter(ic);
+ TRACE_SCAN(ic, "Starting HW_SCAN: scan_flags %b, "
+ "ie_len %d, n_ssids %d, n_chan %d, common_ie_len %d [%d, %d]",
+ lhw->scan_flags, LKPI_LHW_SCAN_BITS, hw_req->req.ie_len,
+ hw_req->req.n_ssids, hw_req->req.n_channels,
+ hw_req->ies.common_ie_len,
+ hw_req->ies.len[NL80211_BAND_2GHZ],
+ hw_req->ies.len[NL80211_BAND_5GHZ]);
error = lkpi_80211_mo_hw_scan(hw, vif, hw_req);
if (error != 0) {
+ bool scan_done;
+ int e;
+
+ TRACE_SCAN(ic, "hw_scan failed; scan_flags %b, error %d",
+ lhw->scan_flags, LKPI_LHW_SCAN_BITS, error);
ieee80211_cancel_scan(vap);
/*
@@ -4545,14 +4817,35 @@ sw_scan:
* So we cannot rely on that behaviour and have to check
* and balance between both code paths.
*/
+ e = 0;
+ scan_done = true;
LKPI_80211_LHW_SCAN_LOCK(lhw);
if ((lhw->scan_flags & LKPI_LHW_SCAN_RUNNING) != 0) {
+
free(lhw->hw_req, M_LKPI80211);
lhw->hw_req = NULL;
+ /*
+ * The ieee80211_cancel_scan() above runs in a
+ * taskq and it may take ages for the previous
+ * scan to clear; starting a new one right away
+ * we run into the problem that the old one is
+ * still active.
+ */
+ e = msleep(lhw, &lhw->scan_mtx, 0, "lhwscanstop", hz);
+ scan_done = (lhw->scan_flags & LKPI_LHW_SCAN_RUNNING) != 0;
+
+ /*
+ * Now we can clear running if no one else did.
+ */
lhw->scan_flags &= ~LKPI_LHW_SCAN_RUNNING;
}
LKPI_80211_LHW_SCAN_UNLOCK(lhw);
lkpi_update_mcast_filter(ic);
+ if (!scan_done) {
+ ic_printf(ic, "ERROR: %s: timeout/error to wait "
+ "for ieee80211_cancel_scan: %d\n", __func__, e);
+ return;
+ }
/*
* XXX-SIGH magic number.
@@ -4560,24 +4853,15 @@ sw_scan:
* not possible. Fall back to sw scan in that case.
*/
if (error == 1) {
- LKPI_80211_LHW_SCAN_LOCK(lhw);
- lhw->scan_flags &= ~LKPI_LHW_SCAN_HW;
- LKPI_80211_LHW_SCAN_UNLOCK(lhw);
/*
- * XXX If we clear this now and later a driver
- * thinks it * can do a hw_scan again, we will
- * currently not re-enable it?
+ * We need to put this into some defered context
+ * the net80211 scan may not be done yet
+ * (ic_flags & IEEE80211_F_SCAN) and we cannot
+ * wait here; if we do scan_curchan_task always
+ * runs after our timeout to finalize the scan.
*/
- vap->iv_flags_ext &= ~IEEE80211_FEXT_SCAN_OFFLOAD;
- ieee80211_start_scan(vap,
- IEEE80211_SCAN_ACTIVE |
- IEEE80211_SCAN_NOPICK |
- IEEE80211_SCAN_ONCE,
- IEEE80211_SCAN_FOREVER,
- ss->ss_mindwell ? ss->ss_mindwell : msecs_to_ticks(20),
- ss->ss_maxdwell ? ss->ss_maxdwell : msecs_to_ticks(200),
- vap->iv_des_nssid, vap->iv_des_ssid);
- goto sw_scan;
+ ieee80211_runtask(ic, &lvif->sw_scan_task);
+ return;
}
ic_printf(ic, "ERROR: %s: hw_scan returned %d\n",
@@ -4587,12 +4871,50 @@ sw_scan:
}
static void
+lkpi_sw_scan_task(void *arg, int pending __unused)
+{
+ struct lkpi_hw *lhw;
+ struct lkpi_vif *lvif;
+ struct ieee80211vap *vap;
+ struct ieee80211_scan_state *ss;
+
+ lvif = arg;
+ vap = LVIF_TO_VAP(lvif);
+ lhw = vap->iv_ic->ic_softc;
+ ss = vap->iv_ic->ic_scan;
+
+ LKPI_80211_LHW_SCAN_LOCK(lhw);
+ /*
+ * We will re-enable this at scan_end calling lkpi_enable_hw_scan().
+ * IEEE80211_FEXT_SCAN_OFFLOAD will be cleared by lkpi_ic_scan_start.
+ */
+ lhw->scan_flags &= ~LKPI_LHW_SCAN_HW;
+ LKPI_80211_LHW_SCAN_UNLOCK(lhw);
+
+ TRACE_SCAN(vap->iv_ic, "Triggering SW_SCAN: pending %d, scan_flags %b",
+ pending, lhw->scan_flags, LKPI_LHW_SCAN_BITS);
+
+ /*
+ * This will call ic_scan_start() and we will get into the right path
+ * unless other scans started in between.
+ */
+ ieee80211_start_scan(vap,
+ IEEE80211_SCAN_ONCE,
+ msecs_to_ticks(10000), /* 10000 ms (=~ 50 chan * 200 ms) */
+ ss->ss_mindwell ? ss->ss_mindwell : msecs_to_ticks(20),
+ ss->ss_maxdwell ? ss->ss_maxdwell : msecs_to_ticks(200),
+ vap->iv_des_nssid, vap->iv_des_ssid);
+}
+
+static void
lkpi_ic_scan_end(struct ieee80211com *ic)
{
struct lkpi_hw *lhw;
bool is_hw_scan;
lhw = ic->ic_softc;
+ TRACE_SCAN(ic, "scan_flags %b", lhw->scan_flags, LKPI_LHW_SCAN_BITS);
+
LKPI_80211_LHW_SCAN_LOCK(lhw);
if ((lhw->scan_flags & LKPI_LHW_SCAN_RUNNING) == 0) {
LKPI_80211_LHW_SCAN_UNLOCK(lhw);
@@ -4621,6 +4943,16 @@ lkpi_ic_scan_end(struct ieee80211com *ic)
if (vap->iv_state == IEEE80211_S_SCAN)
lkpi_hw_conf_idle(hw, true);
}
+
+ /*
+ * In case we disabled the hw_scan in lkpi_ic_scan_start() and
+ * switched to swscan, re-enable hw_scan if available.
+ */
+ lkpi_enable_hw_scan(lhw);
+
+ LKPI_80211_LHW_SCAN_LOCK(lhw);
+ wakeup(lhw);
+ LKPI_80211_LHW_SCAN_UNLOCK(lhw);
}
static void
@@ -4631,6 +4963,10 @@ lkpi_ic_scan_curchan(struct ieee80211_scan_state *ss,
bool is_hw_scan;
lhw = ss->ss_ic->ic_softc;
+ TRACE_SCAN(ss->ss_ic, "scan_flags %b chan %d maxdwell %lu",
+ lhw->scan_flags, LKPI_LHW_SCAN_BITS,
+ ss->ss_ic->ic_curchan->ic_ieee, maxdwell);
+
LKPI_80211_LHW_SCAN_LOCK(lhw);
is_hw_scan = (lhw->scan_flags & LKPI_LHW_SCAN_HW) != 0;
LKPI_80211_LHW_SCAN_UNLOCK(lhw);
@@ -4645,6 +4981,10 @@ lkpi_ic_scan_mindwell(struct ieee80211_scan_state *ss)
bool is_hw_scan;
lhw = ss->ss_ic->ic_softc;
+ TRACE_SCAN(ss->ss_ic, "scan_flags %b chan %d mindwell %lu",
+ lhw->scan_flags, LKPI_LHW_SCAN_BITS,
+ ss->ss_ic->ic_curchan->ic_ieee, ss->ss_mindwell);
+
LKPI_80211_LHW_SCAN_LOCK(lhw);
is_hw_scan = (lhw->scan_flags & LKPI_LHW_SCAN_HW) != 0;
LKPI_80211_LHW_SCAN_UNLOCK(lhw);
@@ -6042,6 +6382,7 @@ linuxkpi_ieee80211_alloc_hw(size_t priv_len, const struct ieee80211_ops *ops)
LKPI_80211_LHW_SCAN_LOCK_INIT(lhw);
LKPI_80211_LHW_TXQ_LOCK_INIT(lhw);
+ spin_lock_init(&lhw->txq_lock);
sx_init_flags(&lhw->lvif_sx, "lhw-lvif", SX_RECURSE | SX_DUPOK);
LKPI_80211_LHW_MC_LOCK_INIT(lhw);
TAILQ_INIT(&lhw->lvif_head);
@@ -6147,6 +6488,7 @@ linuxkpi_ieee80211_iffree(struct ieee80211_hw *hw)
LKPI_80211_LHW_MC_UNLOCK(lhw);
/* Cleanup more of lhw here or in wiphy_free()? */
+ spin_lock_destroy(&lhw->txq_lock);
LKPI_80211_LHW_TXQ_LOCK_DESTROY(lhw);
LKPI_80211_LHW_SCAN_LOCK_DESTROY(lhw);
sx_destroy(&lhw->lvif_sx);
@@ -6255,21 +6597,13 @@ linuxkpi_ieee80211_ifattach(struct ieee80211_hw *hw)
IEEE80211_C_SHSLOT | /* short slot time supported */
IEEE80211_C_SHPREAMBLE /* short preamble supported */
;
-#if 0
- /* Scanning is a different kind of beast to re-work. */
- ic->ic_caps |= IEEE80211_C_BGSCAN;
+
+#ifdef LKPI_80211_BGSCAN
+ if (lhw->ops->hw_scan)
+ ic->ic_caps |= IEEE80211_C_BGSCAN;
#endif
- if (lhw->ops->hw_scan) {
- /*
- * Advertise full-offload scanning.
- *
- * Not limiting to SINGLE_SCAN_ON_ALL_BANDS here as otherwise
- * we essentially disable hw_scan for all drivers not setting
- * the flag.
- */
- ic->ic_flags_ext |= IEEE80211_FEXT_SCAN_OFFLOAD;
- lhw->scan_flags |= LKPI_LHW_SCAN_HW;
- }
+
+ lkpi_enable_hw_scan(lhw);
/* Does HW support Fragmentation offload? */
if (ieee80211_hw_check(hw, SUPPORTS_TX_FRAG))
@@ -6726,13 +7060,19 @@ linuxkpi_ieee80211_scan_completed(struct ieee80211_hw *hw,
ic = lhw->ic;
ss = ic->ic_scan;
+ TRACE_SCAN(ic, "scan_flags %b info { %ju, %6D, aborted %d }",
+ lhw->scan_flags, LKPI_LHW_SCAN_BITS,
+ (uintmax_t)info->scan_start_tsf, info->tsf_bssid, ":",
+ info->aborted);
+
ieee80211_scan_done(ss->ss_vap);
LKPI_80211_LHW_SCAN_LOCK(lhw);
free(lhw->hw_req, M_LKPI80211);
lhw->hw_req = NULL;
lhw->scan_flags &= ~LKPI_LHW_SCAN_RUNNING;
- wakeup(lhw);
+ /* The wakeup(lhw) will be called from lkpi_ic_scan_end(). */
+ /* wakeup(lhw); */
LKPI_80211_LHW_SCAN_UNLOCK(lhw);
return;
@@ -7002,6 +7342,63 @@ lkpi_convert_rx_status(struct ieee80211_hw *hw, struct lkpi_sta *lsta,
}
}
+#ifdef LINUXKPI_DEBUG_80211
+static void
+lkpi_rx_log_beacon(struct mbuf *m, struct lkpi_hw *lhw,
+ struct ieee80211_rx_status *rx_status)
+{
+ struct ieee80211_mgmt *f;
+ uint8_t *e;
+ char ssid[IEEE80211_NWID_LEN * 4 + 1];
+
+ memset(ssid, '\0', sizeof(ssid));
+
+ f = mtod(m, struct ieee80211_mgmt *);
+ e = f->u.beacon.variable;
+ /*
+ * Usually SSID is right after the fixed part and for debugging we will
+ * be fine should we miss it if it is not.
+ */
+ while ((e - (uint8_t *)f) < m->m_len) {
+ if (*e == IEEE80211_ELEMID_SSID)
+ break;
+ e += (2 + *(e + 1));
+ }
+ if (*e == IEEE80211_ELEMID_SSID) {
+ int i, len;
+ char *p;
+
+ p = ssid;
+ len = m->m_len - ((e + 2) - (uint8_t *)f);
+ if (len > *(e + 1))
+ len = *(e + 1);
+ e += 2;
+ for (i = 0; i < len; i++) {
+ /* Printable character? */
+ if (*e >= 0x20 && *e < 0x7f) {
+ *p++ = *e++;
+ } else {
+ snprintf(p, 5, "%#04x", *e++);
+ p += 4;
+ }
+ }
+ *p = '\0';
+ }
+
+ /* We print skb, skb->data, m as we are seeing 'ghost beacons'. */
+ TRACE_SCAN_BEACON(lhw->ic, "Beacon: scan_flags %b, band %s freq %u chan %-4d "
+ "len %d { %#06x %#06x %6D %6D %6D %#06x %ju %u %#06x SSID '%s' }",
+ lhw->scan_flags, LKPI_LHW_SCAN_BITS,
+ lkpi_nl80211_band_name(rx_status->band), rx_status->freq,
+ linuxkpi_ieee80211_frequency_to_channel(rx_status->freq, 0),
+ m->m_pkthdr.len, f->frame_control, f->duration_id,
+ f->da, ":", f->sa, ":", f->bssid, ":", f->seq_ctrl,
+ (uintmax_t)le64_to_cpu(f->u.beacon.timestamp),
+ le16_to_cpu(f->u.beacon.beacon_int),
+ le16_to_cpu(f->u.beacon.capab_info), ssid);
+}
+#endif
+
/* For %list see comment towards the end of the function. */
void
linuxkpi_ieee80211_rx(struct ieee80211_hw *hw, struct sk_buff *skb,
@@ -7058,7 +7455,15 @@ linuxkpi_ieee80211_rx(struct ieee80211_hw *hw, struct sk_buff *skb,
is_beacon = ieee80211_is_beacon(hdr->frame_control);
#ifdef LINUXKPI_DEBUG_80211
- if (is_beacon && (linuxkpi_debug_80211 & D80211_TRACE_RX_BEACONS) == 0)
+ /*
+ * We use the mbuf here as otherwise the variable part might
+ * be in skb frags.
+ */
+ if (is_beacon && ((linuxkpi_debug_80211 & D80211_SCAN_BEACON) != 0))
+ lkpi_rx_log_beacon(m, lhw, rx_status);
+
+ if (is_beacon && (linuxkpi_debug_80211 & D80211_TRACE_RX_BEACONS) == 0 &&
+ (linuxkpi_debug_80211 & D80211_SCAN_BEACON) == 0)
goto no_trace_beacons;
if (linuxkpi_debug_80211 & D80211_TRACE_RX)
@@ -7073,7 +7478,8 @@ linuxkpi_ieee80211_rx(struct ieee80211_hw *hw, struct sk_buff *skb,
hexdump(mtod(m, const void *), m->m_len, "RX (raw) ", 0);
/* Implement a dump_rxcb() !!! */
- if (linuxkpi_debug_80211 & D80211_TRACE_RX)
+ if ((linuxkpi_debug_80211 & D80211_TRACE_RX) != 0 ||
+ (linuxkpi_debug_80211 & D80211_SCAN_BEACON) != 0)
printf("TRACE-RX: %s: RXCB: %ju %ju %u, %b, %u, %#0x, %#0x, "
"%u band %u, %u { %d %d %d %d }, %d, %#x %#x %#x %#x %u %u %u\n",
__func__,
@@ -8124,21 +8530,30 @@ lkpi_ieee80211_wake_queues_locked(struct ieee80211_hw *hw)
void
linuxkpi_ieee80211_wake_queues(struct ieee80211_hw *hw)
{
- wiphy_lock(hw->wiphy);
+ struct lkpi_hw *lhw;
+ unsigned long flags;
+
+ lhw = HW_TO_LHW(hw);
+
+ spin_lock_irqsave(&lhw->txq_lock, flags);
lkpi_ieee80211_wake_queues_locked(hw);
- wiphy_unlock(hw->wiphy);
+ spin_unlock_irqrestore(&lhw->txq_lock, flags);
}
void
linuxkpi_ieee80211_wake_queue(struct ieee80211_hw *hw, int qnum)
{
+ struct lkpi_hw *lhw;
+ unsigned long flags;
KASSERT(qnum < hw->queues, ("%s: qnum %d >= hw->queues %d, hw %p\n",
__func__, qnum, hw->queues, hw));
- wiphy_lock(hw->wiphy);
+ lhw = HW_TO_LHW(hw);
+
+ spin_lock_irqsave(&lhw->txq_lock, flags);
lkpi_ieee80211_wake_queues(hw, qnum);
- wiphy_unlock(hw->wiphy);
+ spin_unlock_irqrestore(&lhw->txq_lock, flags);
}
/* This is just hardware queues. */
diff --git a/sys/compat/linuxkpi/common/src/linux_80211.h b/sys/compat/linuxkpi/common/src/linux_80211.h
index eaf6d804af4c..0dfcd7646c34 100644
--- a/sys/compat/linuxkpi/common/src/linux_80211.h
+++ b/sys/compat/linuxkpi/common/src/linux_80211.h
@@ -59,6 +59,8 @@
#define D80211_IMPROVE_TXQ 0x00000004
#define D80211_TRACE 0x00000010
#define D80211_TRACEOK 0x00000020
+#define D80211_SCAN 0x00000040
+#define D80211_SCAN_BEACON 0x00000080
#define D80211_TRACE_TX 0x00000100
#define D80211_TRACE_TX_DUMP 0x00000200
#define D80211_TRACE_RX 0x00001000
@@ -75,6 +77,20 @@
#define D80211_TRACE_MODE_HE 0x04000000
#define D80211_TRACE_MODE_EHT 0x08000000
+#ifdef LINUXKPI_DEBUG_80211
+#define TRACE_SCAN(ic, fmt, ...) \
+ if (linuxkpi_debug_80211 & D80211_SCAN) \
+ printf("%s:%d: %s SCAN " fmt "\n", \
+ __func__, __LINE__, ic->ic_name, ##__VA_ARGS__)
+#define TRACE_SCAN_BEACON(ic, fmt, ...) \
+ if (linuxkpi_debug_80211 & D80211_SCAN_BEACON) \
+ printf("%s:%d: %s SCAN " fmt "\n", \
+ __func__, __LINE__, ic->ic_name, ##__VA_ARGS__)
+#else
+#define TRACE_SCAN(...) do {} while (0)
+#define TRACE_SCAN_BEACON(...) do {} while (0)
+#endif
+
#define IMPROVE_TXQ(...) \
if (linuxkpi_debug_80211 & D80211_IMPROVE_TXQ) \
printf("%s:%d: XXX LKPI80211 IMPROVE_TXQ\n", __func__, __LINE__)
@@ -191,6 +207,7 @@ struct lkpi_vif {
struct mbuf *, int,
const struct ieee80211_rx_stats *,
int, int);
+ struct task sw_scan_task;
struct list_head lsta_list;
@@ -236,6 +253,7 @@ struct lkpi_hw { /* name it mac80211_sc? */
struct mtx txq_mtx;
uint32_t txq_generation[IEEE80211_NUM_ACS];
TAILQ_HEAD(, lkpi_txq) scheduled_txqs[IEEE80211_NUM_ACS];
+ spinlock_t txq_lock;
/* Deferred RX path. */
struct task rxq_task;
@@ -298,6 +316,9 @@ struct lkpi_hw { /* name it mac80211_sc? */
#define LHW_TO_HW(_lhw) (&(_lhw)->hw)
#define HW_TO_LHW(_hw) container_of(_hw, struct lkpi_hw, hw)
+#define LKPI_LHW_SCAN_BITS \
+ "\010\1RUNING\2HW"
+
struct lkpi_chanctx {
struct list_head entry;
diff --git a/sys/contrib/dev/rtw88/main.c b/sys/contrib/dev/rtw88/main.c
index 021d076808e0..963b73f35350 100644
--- a/sys/contrib/dev/rtw88/main.c
+++ b/sys/contrib/dev/rtw88/main.c
@@ -57,6 +57,62 @@ module_param_named(support_vht, rtw_vht_support, bool, 0644);
MODULE_PARM_DESC(support_vht, "Set to Y to enable VHT support");
#endif
+#if defined(__FreeBSD__)
+/* Macros based on rtw89::core.c. */
+#define RTW88_DEF_CHAN(_freq, _hw_val, _flags, _band) \
+ { .center_freq = _freq, .hw_value = _hw_val, .flags = _flags, .band = _band, }
+#define RTW88_DEF_CHAN_2G(_freq, _hw_val) \
+ RTW88_DEF_CHAN(_freq, _hw_val, 0, NL80211_BAND_2GHZ)
+#define RTW88_DEF_CHAN_5G(_freq, _hw_val) \
+ RTW88_DEF_CHAN(_freq, _hw_val, 0, NL80211_BAND_5GHZ)
+#define RTW88_DEF_CHAN_5G_NO_HT40MINUS(_freq, _hw_val) \
+ RTW88_DEF_CHAN(_freq, _hw_val, IEEE80211_CHAN_NO_HT40MINUS, NL80211_BAND_5GHZ)
+
+static struct ieee80211_channel rtw_channeltable_2g[] = {
+ RTW88_DEF_CHAN_2G(2412, 1),
+ RTW88_DEF_CHAN_2G(2417, 2),
+ RTW88_DEF_CHAN_2G(2422, 3),
+ RTW88_DEF_CHAN_2G(2427, 4),
+ RTW88_DEF_CHAN_2G(2432, 5),
+ RTW88_DEF_CHAN_2G(2437, 6),
+ RTW88_DEF_CHAN_2G(2442, 7),
+ RTW88_DEF_CHAN_2G(2447, 8),
+ RTW88_DEF_CHAN_2G(2452, 9),
+ RTW88_DEF_CHAN_2G(2457, 10),
+ RTW88_DEF_CHAN_2G(2462, 11),
+ RTW88_DEF_CHAN_2G(2467, 12),
+ RTW88_DEF_CHAN_2G(2472, 13),
+ RTW88_DEF_CHAN_2G(2484, 14),
+};
+
+static struct ieee80211_channel rtw_channeltable_5g[] = {
+ RTW88_DEF_CHAN_5G(5180, 36),
+ RTW88_DEF_CHAN_5G(5200, 40),
+ RTW88_DEF_CHAN_5G(5220, 44),
+ RTW88_DEF_CHAN_5G(5240, 48),
+ RTW88_DEF_CHAN_5G(5260, 52),
+ RTW88_DEF_CHAN_5G(5280, 56),
+ RTW88_DEF_CHAN_5G(5300, 60),
+ RTW88_DEF_CHAN_5G(5320, 64),
+ RTW88_DEF_CHAN_5G(5500, 100),
+ RTW88_DEF_CHAN_5G(5520, 104),
+ RTW88_DEF_CHAN_5G(5540, 108),
+ RTW88_DEF_CHAN_5G(5560, 112),
+ RTW88_DEF_CHAN_5G(5580, 116),
+ RTW88_DEF_CHAN_5G(5600, 120),
+ RTW88_DEF_CHAN_5G(5620, 124),
+ RTW88_DEF_CHAN_5G(5640, 128),
+ RTW88_DEF_CHAN_5G(5660, 132),
+ RTW88_DEF_CHAN_5G(5680, 136),
+ RTW88_DEF_CHAN_5G(5700, 140),
+ RTW88_DEF_CHAN_5G(5720, 144),
+ RTW88_DEF_CHAN_5G(5745, 149),
+ RTW88_DEF_CHAN_5G(5765, 153),
+ RTW88_DEF_CHAN_5G(5785, 157),
+ RTW88_DEF_CHAN_5G(5805, 161),
+ RTW88_DEF_CHAN_5G_NO_HT40MINUS(5825, 165),
+};
+#elif deifned(__linux__)
static struct ieee80211_channel rtw_channeltable_2g[] = {
{.center_freq = 2412, .hw_value = 1,},
{.center_freq = 2417, .hw_value = 2,},
@@ -102,6 +158,7 @@ static struct ieee80211_channel rtw_channeltable_5g[] = {
{.center_freq = 5825, .hw_value = 165,
.flags = IEEE80211_CHAN_NO_HT40MINUS},
};
+#endif
static struct ieee80211_rate rtw_ratetable[] = {
{.bitrate = 10, .hw_value = 0x00,},
diff --git a/sys/dev/ath/ath_rate/sample/sample.c b/sys/dev/ath/ath_rate/sample/sample.c
index 291d1ec64ed7..79bf08678249 100644
--- a/sys/dev/ath/ath_rate/sample/sample.c
+++ b/sys/dev/ath/ath_rate/sample/sample.c
@@ -179,7 +179,7 @@ ath_rate_sample_find_min_pktlength(struct ath_softc *sc,
const struct txschedule *sched = &sn->sched[rix0];
int max_pkt_length = 65530; // ATH_AGGR_MAXSIZE
// Note: this may not be true in all cases; need to check?
- int is_ht40 = (an->an_node.ni_chw == IEEE80211_STA_RX_BW_40);
+ int is_ht40 = (an->an_node.ni_chw == NET80211_STA_RX_BW_40);
// Note: not great, but good enough..
int idx = is_ht40 ? MCS_HT40 : MCS_HT20;
@@ -979,7 +979,7 @@ update_stats(struct ath_softc *sc, struct ath_node *an,
const int size_bin = size_to_bin(frame_size);
const int size = bin_to_size(size_bin);
int tt;
- int is_ht40 = (an->an_node.ni_chw == IEEE80211_STA_RX_BW_40);
+ int is_ht40 = (an->an_node.ni_chw == NET80211_STA_RX_BW_40);
int pct;
if (!IS_RATE_DEFINED(sn, rix0))
@@ -1365,7 +1365,7 @@ ath_rate_ctl_reset(struct ath_softc *sc, struct ieee80211_node *ni)
continue;
printf(" %d %s/%d", dot11rate(rt, rix), dot11rate_label(rt, rix),
calc_usecs_unicast_packet(sc, 1600, rix, 0,0,
- (ni->ni_chw == IEEE80211_STA_RX_BW_40)));
+ (ni->ni_chw == NET80211_STA_RX_BW_40)));
}
printf("\n");
}
@@ -1396,7 +1396,7 @@ ath_rate_ctl_reset(struct ath_softc *sc, struct ieee80211_node *ni)
sn->stats[y][rix].perfect_tx_time =
calc_usecs_unicast_packet(sc, size, rix, 0, 0,
- (ni->ni_chw == IEEE80211_STA_RX_BW_40));
+ (ni->ni_chw == NET80211_STA_RX_BW_40));
sn->stats[y][rix].average_tx_time =
sn->stats[y][rix].perfect_tx_time;
}
diff --git a/sys/dev/ath/if_ath_tx_ht.c b/sys/dev/ath/if_ath_tx_ht.c
index e7ee029fecf0..f42058bacb0d 100644
--- a/sys/dev/ath/if_ath_tx_ht.c
+++ b/sys/dev/ath/if_ath_tx_ht.c
@@ -283,7 +283,7 @@ ath_tx_rate_fill_rcflags(struct ath_softc *sc, struct ath_buf *bf)
if (IS_HT_RATE(rate)) {
rc[i].flags |= ATH_RC_HT_FLAG;
- if (ni->ni_chw == IEEE80211_STA_RX_BW_40)
+ if (ni->ni_chw == NET80211_STA_RX_BW_40)
rc[i].flags |= ATH_RC_CW40_FLAG;
/*
@@ -295,13 +295,13 @@ ath_tx_rate_fill_rcflags(struct ath_softc *sc, struct ath_buf *bf)
* and doesn't return the fractional part, so
* we are always "out" by some amount.
*/
- if (ni->ni_chw == IEEE80211_STA_RX_BW_40 &&
+ if (ni->ni_chw == NET80211_STA_RX_BW_40 &&
ieee80211_ht_check_tx_shortgi_40(ni) &&
(bf->bf_flags & ATH_BUF_TOA_PROBE) == 0) {
rc[i].flags |= ATH_RC_SGI_FLAG;
}
- if (ni->ni_chw == IEEE80211_STA_RX_BW_20 &&
+ if (ni->ni_chw == NET80211_STA_RX_BW_20 &&
ieee80211_ht_check_tx_shortgi_20(ni) &&
(bf->bf_flags & ATH_BUF_TOA_PROBE) == 0) {
rc[i].flags |= ATH_RC_SGI_FLAG;
diff --git a/sys/dev/cxgbe/t4_main.c b/sys/dev/cxgbe/t4_main.c
index 9e91250cb61c..9756a6945384 100644
--- a/sys/dev/cxgbe/t4_main.c
+++ b/sys/dev/cxgbe/t4_main.c
@@ -9016,7 +9016,7 @@ sysctl_loadavg(SYSCTL_HANDLER_ARGS)
rc = begin_synchronized_op(sc, NULL, SLEEP_OK | INTR_OK, "t4lavg");
if (rc)
return (rc);
- if (hw_all_ok(sc))
+ if (!hw_all_ok(sc))
rc = ENXIO;
else {
param = V_FW_PARAMS_MNEM(FW_PARAMS_MNEM_DEV) |
diff --git a/sys/dev/gpio/gpio_if.m b/sys/dev/gpio/gpio_if.m
index 5501b2b5c0e7..0b6988ceba79 100644
--- a/sys/dev/gpio/gpio_if.m
+++ b/sys/dev/gpio/gpio_if.m
@@ -62,6 +62,22 @@ CODE {
return (0);
}
+
+ static int
+ gpio_default_get_pin_list(device_t dev, uint32_t *pin_list)
+ {
+ uint32_t maxpin;
+ int err;
+
+ err = GPIO_PIN_MAX(dev, &maxpin);
+ if (err != 0)
+ return (ENXIO);
+
+ for (int i = 0; i <= maxpin; i++)
+ pin_list[i] = i;
+
+ return (0);
+ }
};
HEADER {
@@ -185,3 +201,13 @@ METHOD int pin_config_32 {
uint32_t num_pins;
uint32_t *pin_flags;
} DEFAULT gpio_default_nosupport;
+
+#
+# Get the controller's pin numbers. pin_list is expected to be an array with at
+# least GPIO_PIN_MAX() elements. Populates pin_list from 0 to GPIO_PIN_MAX() by
+# default.
+#
+METHOD int get_pin_list {
+ device_t dev;
+ uint32_t *pin_list;
+} DEFAULT gpio_default_get_pin_list;
diff --git a/sys/dev/gpio/gpiobus.c b/sys/dev/gpio/gpiobus.c
index 5f1f6532a79b..698b5e5fdd01 100644
--- a/sys/dev/gpio/gpiobus.c
+++ b/sys/dev/gpio/gpiobus.c
@@ -319,10 +319,6 @@ gpiobus_add_bus(device_t dev)
busdev = device_add_child(dev, "gpiobus", DEVICE_UNIT_ANY);
if (busdev == NULL)
return (NULL);
- if (device_add_child(dev, "gpioc", DEVICE_UNIT_ANY) == NULL) {
- device_delete_child(dev, busdev);
- return (NULL);
- }
#ifdef FDT
ofw_gpiobus_register_provider(dev);
#endif
@@ -372,6 +368,37 @@ gpiobus_init_softc(device_t dev)
}
int
+gpiobus_add_gpioc(device_t dev)
+{
+ struct gpiobus_ivar *devi;
+ struct gpiobus_softc *sc;
+ device_t gpioc;
+ int err;
+
+ gpioc = BUS_ADD_CHILD(dev, 0, "gpioc", DEVICE_UNIT_ANY);
+ if (gpioc == NULL)
+ return (ENXIO);
+
+ sc = device_get_softc(dev);
+ devi = device_get_ivars(gpioc);
+
+ devi->npins = sc->sc_npins;
+ err = gpiobus_alloc_ivars(devi);
+ if (err != 0) {
+ device_delete_child(dev, gpioc);
+ return (err);
+ }
+
+ err = GPIO_GET_PIN_LIST(sc->sc_dev, devi->pins);
+ if (err != 0) {
+ device_delete_child(dev, gpioc);
+ gpiobus_free_ivars(devi);
+ }
+
+ return (err);
+}
+
+int
gpiobus_alloc_ivars(struct gpiobus_ivar *devi)
{
@@ -562,6 +589,10 @@ gpiobus_attach(device_t dev)
if (err != 0)
return (err);
+ err = gpiobus_add_gpioc(dev);
+ if (err != 0)
+ return (err);
+
/*
* Get parent's pins and mark them as unmapped
*/
@@ -961,7 +992,7 @@ gpiobus_pin_getflags(device_t dev, device_t child, uint32_t pin,
if (pin >= devi->npins)
return (EINVAL);
- return GPIO_PIN_GETFLAGS(sc->sc_dev, devi->pins[pin], flags);
+ return (GPIO_PIN_GETFLAGS(sc->sc_dev, devi->pins[pin], flags));
}
static int
@@ -974,7 +1005,7 @@ gpiobus_pin_getcaps(device_t dev, device_t child, uint32_t pin,
if (pin >= devi->npins)
return (EINVAL);
- return GPIO_PIN_GETCAPS(sc->sc_dev, devi->pins[pin], caps);
+ return (GPIO_PIN_GETCAPS(sc->sc_dev, devi->pins[pin], caps));
}
static int
@@ -987,7 +1018,7 @@ gpiobus_pin_set(device_t dev, device_t child, uint32_t pin,
if (pin >= devi->npins)
return (EINVAL);
- return GPIO_PIN_SET(sc->sc_dev, devi->pins[pin], value);
+ return (GPIO_PIN_SET(sc->sc_dev, devi->pins[pin], value));
}
static int
@@ -1000,7 +1031,7 @@ gpiobus_pin_get(device_t dev, device_t child, uint32_t pin,
if (pin >= devi->npins)
return (EINVAL);
- return GPIO_PIN_GET(sc->sc_dev, devi->pins[pin], value);
+ return (GPIO_PIN_GET(sc->sc_dev, devi->pins[pin], value));
}
static int
@@ -1012,7 +1043,57 @@ gpiobus_pin_toggle(device_t dev, device_t child, uint32_t pin)
if (pin >= devi->npins)
return (EINVAL);
- return GPIO_PIN_TOGGLE(sc->sc_dev, devi->pins[pin]);
+ return (GPIO_PIN_TOGGLE(sc->sc_dev, devi->pins[pin]));
+}
+
+/*
+ * Verify that a child has all the pins they are requesting
+ * to access in their ivars.
+ */
+static bool
+gpiobus_pin_verify_32(struct gpiobus_ivar *devi, uint32_t first_pin,
+ uint32_t num_pins)
+{
+ if (first_pin + num_pins > devi->npins)
+ return (false);
+
+ /* Make sure the pins are consecutive. */
+ for (uint32_t pin = first_pin; pin < first_pin + num_pins - 1; pin++) {
+ if (devi->pins[pin] + 1 != devi->pins[pin + 1])
+ return (false);
+ }
+
+ return (true);
+}
+
+static int
+gpiobus_pin_access_32(device_t dev, device_t child, uint32_t first_pin,
+ uint32_t clear_pins, uint32_t change_pins, uint32_t *orig_pins)
+{
+ struct gpiobus_softc *sc = GPIOBUS_SOFTC(dev);
+ struct gpiobus_ivar *devi = GPIOBUS_IVAR(child);
+
+ if (!gpiobus_pin_verify_32(devi, first_pin, 32))
+ return (EINVAL);
+
+ return (GPIO_PIN_ACCESS_32(sc->sc_dev, devi->pins[first_pin],
+ clear_pins, change_pins, orig_pins));
+}
+
+static int
+gpiobus_pin_config_32(device_t dev, device_t child, uint32_t first_pin,
+ uint32_t num_pins, uint32_t *pin_flags)
+{
+ struct gpiobus_softc *sc = GPIOBUS_SOFTC(dev);
+ struct gpiobus_ivar *devi = GPIOBUS_IVAR(child);
+
+ if (num_pins > 32)
+ return (EINVAL);
+ if (!gpiobus_pin_verify_32(devi, first_pin, num_pins))
+ return (EINVAL);
+
+ return (GPIO_PIN_CONFIG_32(sc->sc_dev,
+ devi->pins[first_pin], num_pins, pin_flags));
}
static int
@@ -1093,6 +1174,8 @@ static device_method_t gpiobus_methods[] = {
DEVMETHOD(gpiobus_pin_get, gpiobus_pin_get),
DEVMETHOD(gpiobus_pin_set, gpiobus_pin_set),
DEVMETHOD(gpiobus_pin_toggle, gpiobus_pin_toggle),
+ DEVMETHOD(gpiobus_pin_access_32,gpiobus_pin_access_32),
+ DEVMETHOD(gpiobus_pin_config_32,gpiobus_pin_config_32),
DEVMETHOD(gpiobus_pin_getname, gpiobus_pin_getname),
DEVMETHOD(gpiobus_pin_setname, gpiobus_pin_setname),
diff --git a/sys/dev/gpio/gpiobus_if.m b/sys/dev/gpio/gpiobus_if.m
index 8bf29839ef4e..890738c4e809 100644
--- a/sys/dev/gpio/gpiobus_if.m
+++ b/sys/dev/gpio/gpiobus_if.m
@@ -107,6 +107,36 @@ METHOD int pin_setflags {
};
#
+# Simultaneously read and/or change up to 32 adjacent pins.
+# If the device cannot change the pins simultaneously, returns EOPNOTSUPP.
+#
+# More details about using this interface can be found in sys/gpio.h
+#
+METHOD int pin_access_32 {
+ device_t dev;
+ device_t child;
+ uint32_t first_pin;
+ uint32_t clear_pins;
+ uint32_t change_pins;
+ uint32_t *orig_pins;
+};
+
+#
+# Simultaneously configure up to 32 adjacent pins.
+# This is intended to change the configuration of all the pins simultaneously,
+# but unlike pin_access_32, this will not fail if the hardware can't do so.
+#
+# More details about using this interface can be found in sys/gpio.h
+#
+METHOD int pin_config_32 {
+ device_t dev;
+ device_t child;
+ uint32_t first_pin;
+ uint32_t num_pins;
+ uint32_t *pin_flags;
+};
+
+#
# Get the pin name
#
METHOD int pin_getname {
diff --git a/sys/dev/gpio/gpiobus_internal.h b/sys/dev/gpio/gpiobus_internal.h
index c198e5f79989..58f862343403 100644
--- a/sys/dev/gpio/gpiobus_internal.h
+++ b/sys/dev/gpio/gpiobus_internal.h
@@ -44,6 +44,7 @@ int gpiobus_acquire_pin(device_t, uint32_t);
void gpiobus_release_pin(device_t, uint32_t);
int gpiobus_child_location(device_t, device_t, struct sbuf *);
device_t gpiobus_add_child_common(device_t, u_int, const char *, int, size_t);
+int gpiobus_add_gpioc(device_t);
extern driver_t gpiobus_driver;
#endif
diff --git a/sys/dev/gpio/gpioc.c b/sys/dev/gpio/gpioc.c
index 87fed38ebe3e..5a60f939dc78 100644
--- a/sys/dev/gpio/gpioc.c
+++ b/sys/dev/gpio/gpioc.c
@@ -45,7 +45,6 @@
#include <dev/gpio/gpiobusvar.h>
-#include "gpio_if.h"
#include "gpiobus_if.h"
#undef GPIOC_DEBUG
@@ -59,7 +58,7 @@
struct gpioc_softc {
device_t sc_dev; /* gpiocX dev */
- device_t sc_pdev; /* gpioX dev */
+ device_t sc_pdev; /* gpiobusX dev */
struct cdev *sc_ctl_dev; /* controller device */
int sc_unit;
int sc_npins;
@@ -69,6 +68,7 @@ struct gpioc_softc {
struct gpioc_pin_intr {
struct gpioc_softc *sc;
gpio_pin_t pin;
+ uint32_t intr_mode;
bool config_locked;
int intr_rid;
struct resource *intr_res;
@@ -112,8 +112,10 @@ struct gpioc_pin_event {
static MALLOC_DEFINE(M_GPIOC, "gpioc", "gpioc device data");
-static int gpioc_allocate_pin_intr(struct gpioc_pin_intr*, uint32_t);
-static int gpioc_release_pin_intr(struct gpioc_pin_intr*);
+static int gpioc_allocate_pin_intr(struct gpioc_softc*,
+ struct gpioc_pin_intr*, uint32_t, uint32_t);
+static int gpioc_release_pin_intr(struct gpioc_softc*,
+ struct gpioc_pin_intr*);
static int gpioc_attach_priv_pin(struct gpioc_cdevpriv*,
struct gpioc_pin_intr*);
static int gpioc_detach_priv_pin(struct gpioc_cdevpriv*,
@@ -191,27 +193,36 @@ number_of_events(struct gpioc_cdevpriv *priv)
}
static int
-gpioc_allocate_pin_intr(struct gpioc_pin_intr *intr_conf, uint32_t flags)
+gpioc_allocate_pin_intr(struct gpioc_softc *sc,
+ struct gpioc_pin_intr *intr_conf, uint32_t pin, uint32_t flags)
{
int err;
intr_conf->config_locked = true;
mtx_unlock(&intr_conf->mtx);
- intr_conf->intr_res = gpio_alloc_intr_resource(intr_conf->pin->dev,
+ MPASS(intr_conf->pin == NULL);
+ err = gpio_pin_get_by_bus_pinnum(sc->sc_pdev, pin, &intr_conf->pin);
+ if (err != 0)
+ goto error_exit;
+
+ intr_conf->intr_res = gpio_alloc_intr_resource(sc->sc_dev,
&intr_conf->intr_rid, RF_ACTIVE, intr_conf->pin, flags);
if (intr_conf->intr_res == NULL) {
err = ENXIO;
- goto error_exit;
+ goto error_pin;
}
- err = bus_setup_intr(intr_conf->pin->dev, intr_conf->intr_res,
+ err = bus_setup_intr(sc->sc_dev, intr_conf->intr_res,
INTR_TYPE_MISC | INTR_MPSAFE, NULL, gpioc_interrupt_handler,
intr_conf, &intr_conf->intr_cookie);
- if (err != 0)
- goto error_exit;
+ if (err != 0) {
+ bus_release_resource(sc->sc_dev, intr_conf->intr_res);
+ intr_conf->intr_res = NULL;
+ goto error_pin;
+ }
- intr_conf->pin->flags = flags;
+ intr_conf->intr_mode = flags;
error_exit:
mtx_lock(&intr_conf->mtx);
@@ -219,10 +230,15 @@ error_exit:
wakeup(&intr_conf->config_locked);
return (err);
+
+error_pin:
+ gpio_pin_release(intr_conf->pin);
+ intr_conf->pin = NULL;
+ goto error_exit;
}
static int
-gpioc_release_pin_intr(struct gpioc_pin_intr *intr_conf)
+gpioc_release_pin_intr(struct gpioc_softc *sc, struct gpioc_pin_intr *intr_conf)
{
int err;
@@ -230,8 +246,8 @@ gpioc_release_pin_intr(struct gpioc_pin_intr *intr_conf)
mtx_unlock(&intr_conf->mtx);
if (intr_conf->intr_cookie != NULL) {
- err = bus_teardown_intr(intr_conf->pin->dev,
- intr_conf->intr_res, intr_conf->intr_cookie);
+ err = bus_teardown_intr(sc->sc_dev, intr_conf->intr_res,
+ intr_conf->intr_cookie);
if (err != 0)
goto error_exit;
else
@@ -239,7 +255,7 @@ gpioc_release_pin_intr(struct gpioc_pin_intr *intr_conf)
}
if (intr_conf->intr_res != NULL) {
- err = bus_release_resource(intr_conf->pin->dev, SYS_RES_IRQ,
+ err = bus_release_resource(sc->sc_dev, SYS_RES_IRQ,
intr_conf->intr_rid, intr_conf->intr_res);
if (err != 0)
goto error_exit;
@@ -249,7 +265,10 @@ gpioc_release_pin_intr(struct gpioc_pin_intr *intr_conf)
}
}
- intr_conf->pin->flags = 0;
+ gpio_pin_release(intr_conf->pin);
+ intr_conf->pin = NULL;
+
+ intr_conf->intr_mode = 0;
err = 0;
error_exit:
@@ -386,7 +405,7 @@ gpioc_get_intr_config(struct gpioc_softc *sc, struct gpioc_cdevpriv *priv,
struct gpioc_privs *priv_link;
uint32_t flags;
- flags = intr_conf->pin->flags;
+ flags = intr_conf->intr_mode;
if (flags == 0)
return (0);
@@ -411,7 +430,7 @@ gpioc_set_intr_config(struct gpioc_softc *sc, struct gpioc_cdevpriv *priv,
int res;
res = 0;
- if (intr_conf->pin->flags == 0 && flags == 0) {
+ if (intr_conf->intr_mode == 0 && flags == 0) {
/* No interrupt configured and none requested: Do nothing. */
return (0);
}
@@ -419,17 +438,17 @@ gpioc_set_intr_config(struct gpioc_softc *sc, struct gpioc_cdevpriv *priv,
while (intr_conf->config_locked == true)
mtx_sleep(&intr_conf->config_locked, &intr_conf->mtx, 0,
"gpicfg", 0);
- if (intr_conf->pin->flags == 0 && flags != 0) {
+ if (intr_conf->intr_mode == 0 && flags != 0) {
/*
* No interrupt is configured, but one is requested: Allocate
* and setup interrupt on the according pin.
*/
- res = gpioc_allocate_pin_intr(intr_conf, flags);
+ res = gpioc_allocate_pin_intr(sc, intr_conf, pin, flags);
if (res == 0)
res = gpioc_attach_priv_pin(priv, intr_conf);
if (res == EEXIST)
res = 0;
- } else if (intr_conf->pin->flags == flags) {
+ } else if (intr_conf->intr_mode == flags) {
/*
* Same interrupt requested as already configured: Attach the
* cdevpriv to the corresponding pin.
@@ -437,14 +456,14 @@ gpioc_set_intr_config(struct gpioc_softc *sc, struct gpioc_cdevpriv *priv,
res = gpioc_attach_priv_pin(priv, intr_conf);
if (res == EEXIST)
res = 0;
- } else if (intr_conf->pin->flags != 0 && flags == 0) {
+ } else if (intr_conf->intr_mode != 0 && flags == 0) {
/*
* Interrupt configured, but none requested: Teardown and
* release the pin when no other cdevpriv is attached. Otherwise
* just detach pin and cdevpriv from each other.
*/
if (gpioc_intr_reconfig_allowed(priv, intr_conf)) {
- res = gpioc_release_pin_intr(intr_conf);
+ res = gpioc_release_pin_intr(sc, intr_conf);
}
if (res == 0)
res = gpioc_detach_priv_pin(priv, intr_conf);
@@ -456,9 +475,10 @@ gpioc_set_intr_config(struct gpioc_softc *sc, struct gpioc_cdevpriv *priv,
if (!gpioc_intr_reconfig_allowed(priv, intr_conf))
res = EBUSY;
else {
- res = gpioc_release_pin_intr(intr_conf);
+ res = gpioc_release_pin_intr(sc, intr_conf);
if (res == 0)
- res = gpioc_allocate_pin_intr(intr_conf, flags);
+ res = gpioc_allocate_pin_intr(sc, intr_conf,
+ pin, flags);
if (res == 0)
res = gpioc_attach_priv_pin(priv, intr_conf);
if (res == EEXIST)
@@ -475,18 +495,16 @@ gpioc_interrupt_handler(void *arg)
{
struct gpioc_pin_intr *intr_conf;
struct gpioc_privs *privs;
- struct gpioc_softc *sc;
sbintime_t evtime;
- uint32_t pin_state;
+ bool pin_state;
intr_conf = arg;
- sc = intr_conf->sc;
/* Capture time and pin state first. */
evtime = sbinuptime();
- if (intr_conf->pin->flags & GPIO_INTR_EDGE_BOTH)
- GPIO_PIN_GET(sc->sc_pdev, intr_conf->pin->pin, &pin_state);
- else if (intr_conf->pin->flags & GPIO_INTR_EDGE_RISING)
+ if (intr_conf->intr_mode & GPIO_INTR_EDGE_BOTH)
+ gpio_pin_is_active(intr_conf->pin, &pin_state);
+ else if (intr_conf->intr_mode & GPIO_INTR_EDGE_RISING)
pin_state = true;
else
pin_state = false;
@@ -575,18 +593,11 @@ gpioc_attach(device_t dev)
sc->sc_pdev = device_get_parent(dev);
sc->sc_unit = device_get_unit(dev);
- err = GPIO_PIN_MAX(sc->sc_pdev, &sc->sc_npins);
- sc->sc_npins++; /* Number of pins is one more than max pin number. */
- if (err != 0)
- return (err);
+ sc->sc_npins = gpiobus_get_npins(dev);
sc->sc_pin_intr = malloc(sizeof(struct gpioc_pin_intr) * sc->sc_npins,
M_GPIOC, M_WAITOK | M_ZERO);
for (int i = 0; i < sc->sc_npins; i++) {
- sc->sc_pin_intr[i].pin = malloc(sizeof(struct gpiobus_pin),
- M_GPIOC, M_WAITOK | M_ZERO);
sc->sc_pin_intr[i].sc = sc;
- sc->sc_pin_intr[i].pin->pin = i;
- sc->sc_pin_intr[i].pin->dev = sc->sc_pdev;
mtx_init(&sc->sc_pin_intr[i].mtx, "gpioc pin", NULL, MTX_DEF);
SLIST_INIT(&sc->sc_pin_intr[i].privs);
}
@@ -610,20 +621,16 @@ static int
gpioc_detach(device_t dev)
{
struct gpioc_softc *sc = device_get_softc(dev);
- int err;
if (sc->sc_ctl_dev)
destroy_dev(sc->sc_ctl_dev);
for (int i = 0; i < sc->sc_npins; i++) {
mtx_destroy(&sc->sc_pin_intr[i].mtx);
- free(sc->sc_pin_intr[i].pin, M_GPIOC);
+ MPASS(sc->sc_pin_intr[i].pin == NULL);
}
free(sc->sc_pin_intr, M_GPIOC);
- if ((err = bus_generic_detach(dev)) != 0)
- return (err);
-
return (0);
}
@@ -655,7 +662,7 @@ gpioc_cdevpriv_dtor(void *data)
KASSERT(consistency == 1,
("inconsistent links between pin config and cdevpriv"));
if (gpioc_intr_reconfig_allowed(priv, pin_link->pin)) {
- gpioc_release_pin_intr(pin_link->pin);
+ gpioc_release_pin_intr(priv->sc, pin_link->pin);
}
mtx_unlock(&pin_link->pin->mtx);
SLIST_REMOVE(&priv->pins, pin_link, gpioc_pins, next);
@@ -778,7 +785,6 @@ static int
gpioc_ioctl(struct cdev *cdev, u_long cmd, caddr_t arg, int fflag,
struct thread *td)
{
- device_t bus;
int max_pin, res;
struct gpioc_softc *sc = cdev->si_drv1;
struct gpioc_cdevpriv *priv;
@@ -789,30 +795,32 @@ gpioc_ioctl(struct cdev *cdev, u_long cmd, caddr_t arg, int fflag,
struct gpio_event_config *evcfg;
uint32_t caps, intrflags;
- bus = GPIO_GET_BUS(sc->sc_pdev);
- if (bus == NULL)
- return (EINVAL);
switch (cmd) {
case GPIOMAXPIN:
- max_pin = -1;
- res = GPIO_PIN_MAX(sc->sc_pdev, &max_pin);
+ res = 0;
+ max_pin = sc->sc_npins - 1;
bcopy(&max_pin, arg, sizeof(max_pin));
break;
case GPIOGETCONFIG:
bcopy(arg, &pin, sizeof(pin));
dprintf("get config pin %d\n", pin.gp_pin);
- res = GPIO_PIN_GETFLAGS(sc->sc_pdev, pin.gp_pin,
+ res = GPIOBUS_PIN_GETFLAGS(sc->sc_pdev, sc->sc_dev, pin.gp_pin,
&pin.gp_flags);
/* Fail early */
- if (res)
+ if (res != 0)
break;
res = devfs_get_cdevpriv((void **)&priv);
- if (res)
+ if (res != 0)
break;
pin.gp_flags |= gpioc_get_intr_config(sc, priv,
pin.gp_pin);
- GPIO_PIN_GETCAPS(sc->sc_pdev, pin.gp_pin, &pin.gp_caps);
- GPIOBUS_PIN_GETNAME(bus, pin.gp_pin, pin.gp_name);
+ res = GPIOBUS_PIN_GETCAPS(sc->sc_pdev, sc->sc_dev, pin.gp_pin,
+ &pin.gp_caps);
+ if (res != 0)
+ break;
+ res = GPIOBUS_PIN_GETNAME(sc->sc_pdev, pin.gp_pin, pin.gp_name);
+ if (res != 0)
+ break;
bcopy(&pin, arg, sizeof(pin));
break;
case GPIOSETCONFIG:
@@ -821,7 +829,8 @@ gpioc_ioctl(struct cdev *cdev, u_long cmd, caddr_t arg, int fflag,
res = devfs_get_cdevpriv((void **)&priv);
if (res != 0)
break;
- res = GPIO_PIN_GETCAPS(sc->sc_pdev, pin.gp_pin, &caps);
+ res = GPIOBUS_PIN_GETCAPS(sc->sc_pdev, sc->sc_dev,
+ pin.gp_pin, &caps);
if (res != 0)
break;
res = gpio_check_flags(caps, pin.gp_flags);
@@ -847,8 +856,8 @@ gpioc_ioctl(struct cdev *cdev, u_long cmd, caddr_t arg, int fflag,
}
if (res != 0)
break;
- res = GPIO_PIN_SETFLAGS(sc->sc_pdev, pin.gp_pin,
- (pin.gp_flags & ~GPIO_INTR_MASK));
+ res = GPIOBUS_PIN_SETFLAGS(sc->sc_pdev, sc->sc_dev, pin.gp_pin,
+ pin.gp_flags & ~GPIO_INTR_MASK);
if (res != 0)
break;
res = gpioc_set_intr_config(sc, priv, pin.gp_pin,
@@ -856,40 +865,43 @@ gpioc_ioctl(struct cdev *cdev, u_long cmd, caddr_t arg, int fflag,
break;
case GPIOGET:
bcopy(arg, &req, sizeof(req));
- res = GPIO_PIN_GET(sc->sc_pdev, req.gp_pin,
+ res = GPIOBUS_PIN_GET(sc->sc_pdev, sc->sc_dev, req.gp_pin,
&req.gp_value);
- dprintf("read pin %d -> %d\n",
+ if (res != 0)
+ break;
+ dprintf("read pin %d -> %d\n",
req.gp_pin, req.gp_value);
bcopy(&req, arg, sizeof(req));
break;
case GPIOSET:
bcopy(arg, &req, sizeof(req));
- res = GPIO_PIN_SET(sc->sc_pdev, req.gp_pin,
+ res = GPIOBUS_PIN_SET(sc->sc_pdev, sc->sc_dev, req.gp_pin,
req.gp_value);
- dprintf("write pin %d -> %d\n",
+ dprintf("write pin %d -> %d\n",
req.gp_pin, req.gp_value);
break;
case GPIOTOGGLE:
bcopy(arg, &req, sizeof(req));
- dprintf("toggle pin %d\n",
+ dprintf("toggle pin %d\n",
req.gp_pin);
- res = GPIO_PIN_TOGGLE(sc->sc_pdev, req.gp_pin);
+ res = GPIOBUS_PIN_TOGGLE(sc->sc_pdev, sc->sc_dev, req.gp_pin);
break;
case GPIOSETNAME:
bcopy(arg, &pin, sizeof(pin));
dprintf("set name on pin %d\n", pin.gp_pin);
- res = GPIOBUS_PIN_SETNAME(bus, pin.gp_pin,
+ res = GPIOBUS_PIN_SETNAME(sc->sc_pdev, pin.gp_pin,
pin.gp_name);
break;
case GPIOACCESS32:
a32 = (struct gpio_access_32 *)arg;
- res = GPIO_PIN_ACCESS_32(sc->sc_pdev, a32->first_pin,
- a32->clear_pins, a32->change_pins, &a32->orig_pins);
+ res = GPIOBUS_PIN_ACCESS_32(sc->sc_pdev, sc->sc_dev,
+ a32->first_pin, a32->clear_pins, a32->change_pins,
+ &a32->orig_pins);
break;
case GPIOCONFIG32:
c32 = (struct gpio_config_32 *)arg;
- res = GPIO_PIN_CONFIG_32(sc->sc_pdev, c32->first_pin,
- c32->num_pins, c32->pin_flags);
+ res = GPIOBUS_PIN_CONFIG_32(sc->sc_pdev, sc->sc_dev,
+ c32->first_pin, c32->num_pins, c32->pin_flags);
break;
case GPIOCONFIGEVENTS:
evcfg = (struct gpio_event_config *)arg;
@@ -1050,9 +1062,6 @@ static device_method_t gpioc_methods[] = {
DEVMETHOD(device_probe, gpioc_probe),
DEVMETHOD(device_attach, gpioc_attach),
DEVMETHOD(device_detach, gpioc_detach),
- DEVMETHOD(device_shutdown, bus_generic_shutdown),
- DEVMETHOD(device_suspend, bus_generic_suspend),
- DEVMETHOD(device_resume, bus_generic_resume),
DEVMETHOD_END
};
@@ -1063,5 +1072,5 @@ driver_t gpioc_driver = {
sizeof(struct gpioc_softc)
};
-DRIVER_MODULE(gpioc, gpio, gpioc_driver, 0, 0);
+DRIVER_MODULE(gpioc, gpiobus, gpioc_driver, 0, 0);
MODULE_VERSION(gpioc, 1);
diff --git a/sys/dev/gpio/ofw_gpiobus.c b/sys/dev/gpio/ofw_gpiobus.c
index b12b78fac18c..da1bfbc268b8 100644
--- a/sys/dev/gpio/ofw_gpiobus.c
+++ b/sys/dev/gpio/ofw_gpiobus.c
@@ -426,6 +426,9 @@ ofw_gpiobus_attach(device_t dev)
err = gpiobus_init_softc(dev);
if (err != 0)
return (err);
+ err = gpiobus_add_gpioc(dev);
+ if (err != 0)
+ return (err);
bus_identify_children(dev);
bus_enumerate_hinted_children(dev);
/*
diff --git a/sys/dev/mwl/if_mwl.c b/sys/dev/mwl/if_mwl.c
index 0e2eb0b2d8fe..c885968dfe15 100644
--- a/sys/dev/mwl/if_mwl.c
+++ b/sys/dev/mwl/if_mwl.c
@@ -4017,7 +4017,7 @@ mkpeerinfo(MWL_HAL_PEERINFO *pi, const struct ieee80211_node *ni)
pi->HTCapabilitiesInfo &= ~IEEE80211_HTCAP_SHORTGI40;
if ((vap->iv_flags_ht & IEEE80211_FHT_SHORTGI20) == 0)
pi->HTCapabilitiesInfo &= ~IEEE80211_HTCAP_SHORTGI20;
- if (ni->ni_chw != IEEE80211_STA_RX_BW_40)
+ if (ni->ni_chw != NET80211_STA_RX_BW_40)
pi->HTCapabilitiesInfo &= ~IEEE80211_HTCAP_CHWIDTH40;
}
return pi;
diff --git a/sys/dev/nvme/nvme.c b/sys/dev/nvme/nvme.c
index 84f365024f13..ead91f0d01fe 100644
--- a/sys/dev/nvme/nvme.c
+++ b/sys/dev/nvme/nvme.c
@@ -295,7 +295,6 @@ nvme_register_consumer(nvme_cons_ns_fn_t ns_fn, nvme_cons_ctrlr_fn_t ctrlr_fn,
void
nvme_unregister_consumer(struct nvme_consumer *consumer)
{
-
consumer->id = INVALID_CONSUMER_ID;
}
diff --git a/sys/dev/nvme/nvme_ahci.c b/sys/dev/nvme/nvme_ahci.c
index 888207a454f7..b06661226d34 100644
--- a/sys/dev/nvme/nvme_ahci.c
+++ b/sys/dev/nvme/nvme_ahci.c
@@ -124,6 +124,5 @@ bad:
static int
nvme_ahci_detach(device_t dev)
{
-
return (nvme_detach(dev));
}
diff --git a/sys/dev/nvme/nvme_ctrlr.c b/sys/dev/nvme/nvme_ctrlr.c
index fd7f00ced14b..49960b0f920a 100644
--- a/sys/dev/nvme/nvme_ctrlr.c
+++ b/sys/dev/nvme/nvme_ctrlr.c
@@ -597,7 +597,6 @@ nvme_ctrlr_construct_namespaces(struct nvme_controller *ctrlr)
static bool
is_log_page_id_valid(uint8_t page_id)
{
-
switch (page_id) {
case NVME_LOG_ERROR:
case NVME_LOG_HEALTH_INFORMATION:
@@ -653,7 +652,6 @@ static void
nvme_ctrlr_log_critical_warnings(struct nvme_controller *ctrlr,
uint8_t state)
{
-
if (state & NVME_CRIT_WARN_ST_AVAILABLE_SPARE)
nvme_printf(ctrlr, "SMART WARNING: available spare space below threshold\n");
@@ -781,7 +779,6 @@ nvme_ctrlr_configure_aer(struct nvme_controller *ctrlr)
static void
nvme_ctrlr_configure_int_coalescing(struct nvme_controller *ctrlr)
{
-
ctrlr->int_coal_time = 0;
TUNABLE_INT_FETCH("hw.nvme.int_coal_time",
&ctrlr->int_coal_time);
@@ -1420,8 +1417,8 @@ nvme_ctrlr_linux_passthru_cmd(struct nvme_controller *ctrlr,
req->cmd.opc = npc->opcode;
req->cmd.fuse = npc->flags;
- req->cmd.rsvd2 = htole16(npc->cdw2);
- req->cmd.rsvd3 = htole16(npc->cdw3);
+ req->cmd.rsvd2 = htole32(npc->cdw2);
+ req->cmd.rsvd3 = htole32(npc->cdw3);
req->cmd.cdw10 = htole32(npc->cdw10);
req->cmd.cdw11 = htole32(npc->cdw11);
req->cmd.cdw12 = htole32(npc->cdw12);
@@ -1776,7 +1773,6 @@ void
nvme_ctrlr_submit_admin_request(struct nvme_controller *ctrlr,
struct nvme_request *req)
{
-
nvme_qpair_submit_request(&ctrlr->adminq, req);
}
@@ -1793,14 +1789,12 @@ nvme_ctrlr_submit_io_request(struct nvme_controller *ctrlr,
device_t
nvme_ctrlr_get_device(struct nvme_controller *ctrlr)
{
-
return (ctrlr->dev);
}
const struct nvme_controller_data *
nvme_ctrlr_get_data(struct nvme_controller *ctrlr)
{
-
return (&ctrlr->cdata);
}
@@ -1853,7 +1847,6 @@ nvme_ctrlr_suspend(struct nvme_controller *ctrlr)
int
nvme_ctrlr_resume(struct nvme_controller *ctrlr)
{
-
/*
* Can't touch failed controllers, so nothing to do to resume.
*/
diff --git a/sys/dev/nvme/nvme_ctrlr_cmd.c b/sys/dev/nvme/nvme_ctrlr_cmd.c
index 993a7718356d..5a44ed425acb 100644
--- a/sys/dev/nvme/nvme_ctrlr_cmd.c
+++ b/sys/dev/nvme/nvme_ctrlr_cmd.c
@@ -281,7 +281,6 @@ nvme_ctrlr_cmd_get_error_page(struct nvme_controller *ctrlr,
struct nvme_error_information_entry *payload, uint32_t num_entries,
nvme_cb_fn_t cb_fn, void *cb_arg)
{
-
KASSERT(num_entries > 0, ("%s called with num_entries==0\n", __func__));
/* Controller's error log page entries is 0-based. */
@@ -302,7 +301,6 @@ nvme_ctrlr_cmd_get_health_information_page(struct nvme_controller *ctrlr,
uint32_t nsid, struct nvme_health_information_page *payload,
nvme_cb_fn_t cb_fn, void *cb_arg)
{
-
nvme_ctrlr_cmd_get_log_page(ctrlr, NVME_LOG_HEALTH_INFORMATION,
nsid, payload, sizeof(*payload), cb_fn, cb_arg);
}
@@ -311,7 +309,6 @@ void
nvme_ctrlr_cmd_get_firmware_page(struct nvme_controller *ctrlr,
struct nvme_firmware_page *payload, nvme_cb_fn_t cb_fn, void *cb_arg)
{
-
nvme_ctrlr_cmd_get_log_page(ctrlr, NVME_LOG_FIRMWARE_SLOT,
NVME_GLOBAL_NAMESPACE_TAG, payload, sizeof(*payload), cb_fn,
cb_arg);
diff --git a/sys/dev/nvme/nvme_ns.c b/sys/dev/nvme/nvme_ns.c
index 3f29382fe42f..e84d2066930e 100644
--- a/sys/dev/nvme/nvme_ns.c
+++ b/sys/dev/nvme/nvme_ns.c
@@ -129,7 +129,6 @@ static int
nvme_ns_close(struct cdev *dev __unused, int flags, int fmt __unused,
struct thread *td)
{
-
return (0);
}
@@ -231,7 +230,6 @@ nvme_ns_get_model_number(struct nvme_namespace *ns)
const struct nvme_namespace_data *
nvme_ns_get_data(struct nvme_namespace *ns)
{
-
return (&ns->data);
}
@@ -631,7 +629,6 @@ nvme_ns_construct(struct nvme_namespace *ns, uint32_t id,
void
nvme_ns_destruct(struct nvme_namespace *ns)
{
-
if (ns->cdev != NULL) {
if (ns->cdev->si_drv2 != NULL)
destroy_dev(ns->cdev->si_drv2);
diff --git a/sys/dev/nvme/nvme_pci.c b/sys/dev/nvme/nvme_pci.c
index 29b49b7df403..c07a68d2f0dc 100644
--- a/sys/dev/nvme/nvme_pci.c
+++ b/sys/dev/nvme/nvme_pci.c
@@ -151,7 +151,6 @@ nvme_pci_probe (device_t device)
static int
nvme_ctrlr_allocate_bar(struct nvme_controller *ctrlr)
{
-
ctrlr->resource_id = PCIR_BAR(0);
ctrlr->resource = bus_alloc_resource_any(ctrlr->dev, SYS_RES_MEMORY,
diff --git a/sys/dev/nvme/nvme_private.h b/sys/dev/nvme/nvme_private.h
index 36f00fedc48e..52f9e12f8f9a 100644
--- a/sys/dev/nvme/nvme_private.h
+++ b/sys/dev/nvme/nvme_private.h
@@ -459,8 +459,7 @@ int nvme_detach(device_t dev);
* vast majority of these without waiting for a tick plus scheduling delays. Since
* these are on startup, this drastically reduces startup time.
*/
-static __inline
-void
+static __inline void
nvme_completion_poll(struct nvme_completion_poll_status *status)
{
int timeout = ticks + 10 * hz;
diff --git a/sys/dev/nvme/nvme_qpair.c b/sys/dev/nvme/nvme_qpair.c
index bd8626e32209..4f2c44da3b4f 100644
--- a/sys/dev/nvme/nvme_qpair.c
+++ b/sys/dev/nvme/nvme_qpair.c
@@ -793,7 +793,6 @@ nvme_admin_qpair_destroy(struct nvme_qpair *qpair)
void
nvme_io_qpair_destroy(struct nvme_qpair *qpair)
{
-
nvme_qpair_destroy(qpair);
}
@@ -1202,7 +1201,6 @@ _nvme_qpair_submit_request(struct nvme_qpair *qpair, struct nvme_request *req)
void
nvme_qpair_submit_request(struct nvme_qpair *qpair, struct nvme_request *req)
{
-
mtx_lock(&qpair->lock);
_nvme_qpair_submit_request(qpair, req);
mtx_unlock(&qpair->lock);
@@ -1226,7 +1224,6 @@ nvme_qpair_enable(struct nvme_qpair *qpair)
void
nvme_qpair_reset(struct nvme_qpair *qpair)
{
-
qpair->sq_head = qpair->sq_tail = qpair->cq_head = 0;
/*
diff --git a/sys/dev/nvme/nvme_sim.c b/sys/dev/nvme/nvme_sim.c
index 4974bb718222..a06774a64761 100644
--- a/sys/dev/nvme/nvme_sim.c
+++ b/sys/dev/nvme/nvme_sim.c
@@ -301,7 +301,6 @@ nvme_sim_action(struct cam_sim *sim, union ccb *ccb)
static void
nvme_sim_poll(struct cam_sim *sim)
{
-
nvme_ctrlr_poll(sim2ctrlr(sim));
}
diff --git a/sys/dev/nvme/nvme_sysctl.c b/sys/dev/nvme/nvme_sysctl.c
index a5a44721f9f9..50d19e730a16 100644
--- a/sys/dev/nvme/nvme_sysctl.c
+++ b/sys/dev/nvme/nvme_sysctl.c
@@ -153,7 +153,6 @@ nvme_sysctl_timeout_period(SYSCTL_HANDLER_ARGS)
static void
nvme_qpair_reset_stats(struct nvme_qpair *qpair)
{
-
/*
* Reset the values. Due to sanity checks in
* nvme_qpair_process_completions, we reset the number of interrupt
diff --git a/sys/dev/rtwn/rtl8812a/r12a_tx.c b/sys/dev/rtwn/rtl8812a/r12a_tx.c
index acb238316559..0ca1ebd37757 100644
--- a/sys/dev/rtwn/rtl8812a/r12a_tx.c
+++ b/sys/dev/rtwn/rtl8812a/r12a_tx.c
@@ -101,12 +101,12 @@ r12a_tx_set_vht_bw(struct rtwn_softc *sc, void *buf, struct ieee80211_node *ni)
prim_chan = r12a_get_primary_channel(sc, ni->ni_chan);
- if (ieee80211_vht_check_tx_bw(ni, IEEE80211_STA_RX_BW_80)) {
+ if (ieee80211_vht_check_tx_bw(ni, NET80211_STA_RX_BW_80)) {
txd->txdw5 |= htole32(SM(R12A_TXDW5_DATA_BW,
R12A_TXDW5_DATA_BW80));
txd->txdw5 |= htole32(SM(R12A_TXDW5_DATA_PRIM_CHAN,
prim_chan));
- } else if (ieee80211_vht_check_tx_bw(ni, IEEE80211_STA_RX_BW_40)) {
+ } else if (ieee80211_vht_check_tx_bw(ni, NET80211_STA_RX_BW_40)) {
txd->txdw5 |= htole32(SM(R12A_TXDW5_DATA_BW,
R12A_TXDW5_DATA_BW40));
txd->txdw5 |= htole32(SM(R12A_TXDW5_DATA_PRIM_CHAN,
diff --git a/sys/dev/tpm/tpm_tis_core.c b/sys/dev/tpm/tpm_tis_core.c
index d8421f8156c9..4159de4daf3b 100644
--- a/sys/dev/tpm/tpm_tis_core.c
+++ b/sys/dev/tpm/tpm_tis_core.c
@@ -97,6 +97,7 @@ tpmtis_attach(device_t dev)
{
struct tpm_sc *sc;
int result;
+ int poll = 0;
sc = device_get_softc(dev);
sc->dev = dev;
@@ -105,6 +106,12 @@ tpmtis_attach(device_t dev)
sx_init(&sc->dev_lock, "TPM driver lock");
sc->buf = malloc(TPM_BUFSIZE, M_TPM20, M_WAITOK);
+ resource_int_value("tpm", device_get_unit(dev), "use_polling", &poll);
+ if (poll != 0) {
+ device_printf(dev, "Using poll method to get TPM operation status \n");
+ goto skip_irq;
+ }
+
sc->irq_rid = 0;
sc->irq_res = bus_alloc_resource_any(dev, SYS_RES_IRQ, &sc->irq_rid,
RF_ACTIVE | RF_SHAREABLE);
diff --git a/sys/dev/usb/usb_hub.c b/sys/dev/usb/usb_hub.c
index e3509862ef54..ee9d8ab0c9bb 100644
--- a/sys/dev/usb/usb_hub.c
+++ b/sys/dev/usb/usb_hub.c
@@ -954,7 +954,8 @@ done:
* packet. This function is called having the "bus_mtx" locked.
*------------------------------------------------------------------------*/
void
-uhub_root_intr(struct usb_bus *bus, const uint8_t *ptr, uint8_t len)
+uhub_root_intr(struct usb_bus *bus,
+ const uint8_t *ptr __unused, uint8_t len __unused)
{
USB_BUS_LOCK_ASSERT(bus, MA_OWNED);
diff --git a/sys/dev/virtio/network/if_vtnet.c b/sys/dev/virtio/network/if_vtnet.c
index ecb3dbb370e5..867da80a53a8 100644
--- a/sys/dev/virtio/network/if_vtnet.c
+++ b/sys/dev/virtio/network/if_vtnet.c
@@ -2551,8 +2551,10 @@ vtnet_txq_enqueue_buf(struct vtnet_txq *txq, struct mbuf **m_head,
error = sglist_append_mbuf(sg, m);
if (error) {
m = m_defrag(m, M_NOWAIT);
- if (m == NULL)
+ if (m == NULL) {
+ sc->vtnet_stats.tx_defrag_failed++;
goto fail;
+ }
*m_head = m;
sc->vtnet_stats.tx_defragged++;
@@ -2568,7 +2570,6 @@ vtnet_txq_enqueue_buf(struct vtnet_txq *txq, struct mbuf **m_head,
return (error);
fail:
- sc->vtnet_stats.tx_defrag_failed++;
m_freem(*m_head);
*m_head = NULL;
@@ -3813,9 +3814,9 @@ vtnet_rx_filter_mac(struct vtnet_softc *sc)
if_printf(ifp, "error setting host MAC filter table\n");
out:
- if (promisc != 0 && vtnet_set_promisc(sc, true) != 0)
+ if (promisc && vtnet_set_promisc(sc, true) != 0)
if_printf(ifp, "cannot enable promiscuous mode\n");
- if (allmulti != 0 && vtnet_set_allmulti(sc, true) != 0)
+ if (allmulti && vtnet_set_allmulti(sc, true) != 0)
if_printf(ifp, "cannot enable all-multicast mode\n");
}
@@ -4100,21 +4101,29 @@ vtnet_setup_rxq_sysctl(struct sysctl_ctx_list *ctx,
stats = &rxq->vtnrx_stats;
- SYSCTL_ADD_UQUAD(ctx, list, OID_AUTO, "ipackets", CTLFLAG_RD,
+ SYSCTL_ADD_UQUAD(ctx, list, OID_AUTO, "ipackets",
+ CTLFLAG_RD | CTLFLAG_STATS,
&stats->vrxs_ipackets, "Receive packets");
- SYSCTL_ADD_UQUAD(ctx, list, OID_AUTO, "ibytes", CTLFLAG_RD,
+ SYSCTL_ADD_UQUAD(ctx, list, OID_AUTO, "ibytes",
+ CTLFLAG_RD | CTLFLAG_STATS,
&stats->vrxs_ibytes, "Receive bytes");
- SYSCTL_ADD_UQUAD(ctx, list, OID_AUTO, "iqdrops", CTLFLAG_RD,
+ SYSCTL_ADD_UQUAD(ctx, list, OID_AUTO, "iqdrops",
+ CTLFLAG_RD | CTLFLAG_STATS,
&stats->vrxs_iqdrops, "Receive drops");
- SYSCTL_ADD_UQUAD(ctx, list, OID_AUTO, "ierrors", CTLFLAG_RD,
+ SYSCTL_ADD_UQUAD(ctx, list, OID_AUTO, "ierrors",
+ CTLFLAG_RD | CTLFLAG_STATS,
&stats->vrxs_ierrors, "Receive errors");
- SYSCTL_ADD_UQUAD(ctx, list, OID_AUTO, "csum", CTLFLAG_RD,
+ SYSCTL_ADD_UQUAD(ctx, list, OID_AUTO, "csum",
+ CTLFLAG_RD | CTLFLAG_STATS,
&stats->vrxs_csum, "Receive checksum offloaded");
- SYSCTL_ADD_UQUAD(ctx, list, OID_AUTO, "csum_failed", CTLFLAG_RD,
+ SYSCTL_ADD_UQUAD(ctx, list, OID_AUTO, "csum_failed",
+ CTLFLAG_RD | CTLFLAG_STATS,
&stats->vrxs_csum_failed, "Receive checksum offload failed");
- SYSCTL_ADD_UQUAD(ctx, list, OID_AUTO, "host_lro", CTLFLAG_RD,
+ SYSCTL_ADD_UQUAD(ctx, list, OID_AUTO, "host_lro",
+ CTLFLAG_RD | CTLFLAG_STATS,
&stats->vrxs_host_lro, "Receive host segmentation offloaded");
- SYSCTL_ADD_UQUAD(ctx, list, OID_AUTO, "rescheduled", CTLFLAG_RD,
+ SYSCTL_ADD_UQUAD(ctx, list, OID_AUTO, "rescheduled",
+ CTLFLAG_RD | CTLFLAG_STATS,
&stats->vrxs_rescheduled,
"Receive interrupt handler rescheduled");
}
@@ -4135,17 +4144,23 @@ vtnet_setup_txq_sysctl(struct sysctl_ctx_list *ctx,
stats = &txq->vtntx_stats;
- SYSCTL_ADD_UQUAD(ctx, list, OID_AUTO, "opackets", CTLFLAG_RD,
+ SYSCTL_ADD_UQUAD(ctx, list, OID_AUTO, "opackets",
+ CTLFLAG_RD | CTLFLAG_STATS,
&stats->vtxs_opackets, "Transmit packets");
- SYSCTL_ADD_UQUAD(ctx, list, OID_AUTO, "obytes", CTLFLAG_RD,
+ SYSCTL_ADD_UQUAD(ctx, list, OID_AUTO, "obytes",
+ CTLFLAG_RD | CTLFLAG_STATS,
&stats->vtxs_obytes, "Transmit bytes");
- SYSCTL_ADD_UQUAD(ctx, list, OID_AUTO, "omcasts", CTLFLAG_RD,
+ SYSCTL_ADD_UQUAD(ctx, list, OID_AUTO, "omcasts",
+ CTLFLAG_RD | CTLFLAG_STATS,
&stats->vtxs_omcasts, "Transmit multicasts");
- SYSCTL_ADD_UQUAD(ctx, list, OID_AUTO, "csum", CTLFLAG_RD,
+ SYSCTL_ADD_UQUAD(ctx, list, OID_AUTO, "csum",
+ CTLFLAG_RD | CTLFLAG_STATS,
&stats->vtxs_csum, "Transmit checksum offloaded");
- SYSCTL_ADD_UQUAD(ctx, list, OID_AUTO, "tso", CTLFLAG_RD,
+ SYSCTL_ADD_UQUAD(ctx, list, OID_AUTO, "tso",
+ CTLFLAG_RD | CTLFLAG_STATS,
&stats->vtxs_tso, "Transmit TCP segmentation offloaded");
- SYSCTL_ADD_UQUAD(ctx, list, OID_AUTO, "rescheduled", CTLFLAG_RD,
+ SYSCTL_ADD_UQUAD(ctx, list, OID_AUTO, "rescheduled",
+ CTLFLAG_RD | CTLFLAG_STATS,
&stats->vtxs_rescheduled,
"Transmit interrupt handler rescheduled");
}
@@ -4170,6 +4185,102 @@ vtnet_setup_queue_sysctl(struct vtnet_softc *sc)
}
}
+static int
+vtnet_sysctl_rx_csum_failed(SYSCTL_HANDLER_ARGS)
+{
+ struct vtnet_softc *sc = (struct vtnet_softc *)arg1;
+ struct vtnet_statistics *stats = &sc->vtnet_stats;
+ struct vtnet_rxq_stats *rxst;
+ int i;
+
+ stats->rx_csum_failed = 0;
+ for (i = 0; i < sc->vtnet_max_vq_pairs; i++) {
+ rxst = &sc->vtnet_rxqs[i].vtnrx_stats;
+ stats->rx_csum_failed += rxst->vrxs_csum_failed;
+ }
+ return (sysctl_handle_64(oidp, NULL, stats->rx_csum_failed, req));
+}
+
+static int
+vtnet_sysctl_rx_csum_offloaded(SYSCTL_HANDLER_ARGS)
+{
+ struct vtnet_softc *sc = (struct vtnet_softc *)arg1;
+ struct vtnet_statistics *stats = &sc->vtnet_stats;
+ struct vtnet_rxq_stats *rxst;
+ int i;
+
+ stats->rx_csum_offloaded = 0;
+ for (i = 0; i < sc->vtnet_max_vq_pairs; i++) {
+ rxst = &sc->vtnet_rxqs[i].vtnrx_stats;
+ stats->rx_csum_offloaded += rxst->vrxs_csum;
+ }
+ return (sysctl_handle_64(oidp, NULL, stats->rx_csum_offloaded, req));
+}
+
+static int
+vtnet_sysctl_rx_task_rescheduled(SYSCTL_HANDLER_ARGS)
+{
+ struct vtnet_softc *sc = (struct vtnet_softc *)arg1;
+ struct vtnet_statistics *stats = &sc->vtnet_stats;
+ struct vtnet_rxq_stats *rxst;
+ int i;
+
+ stats->rx_task_rescheduled = 0;
+ for (i = 0; i < sc->vtnet_max_vq_pairs; i++) {
+ rxst = &sc->vtnet_rxqs[i].vtnrx_stats;
+ stats->rx_task_rescheduled += rxst->vrxs_rescheduled;
+ }
+ return (sysctl_handle_64(oidp, NULL, stats->rx_task_rescheduled, req));
+}
+
+static int
+vtnet_sysctl_tx_csum_offloaded(SYSCTL_HANDLER_ARGS)
+{
+ struct vtnet_softc *sc = (struct vtnet_softc *)arg1;
+ struct vtnet_statistics *stats = &sc->vtnet_stats;
+ struct vtnet_txq_stats *txst;
+ int i;
+
+ stats->tx_csum_offloaded = 0;
+ for (i = 0; i < sc->vtnet_max_vq_pairs; i++) {
+ txst = &sc->vtnet_txqs[i].vtntx_stats;
+ stats->tx_csum_offloaded += txst->vtxs_csum;
+ }
+ return (sysctl_handle_64(oidp, NULL, stats->tx_csum_offloaded, req));
+}
+
+static int
+vtnet_sysctl_tx_tso_offloaded(SYSCTL_HANDLER_ARGS)
+{
+ struct vtnet_softc *sc = (struct vtnet_softc *)arg1;
+ struct vtnet_statistics *stats = &sc->vtnet_stats;
+ struct vtnet_txq_stats *txst;
+ int i;
+
+ stats->tx_tso_offloaded = 0;
+ for (i = 0; i < sc->vtnet_max_vq_pairs; i++) {
+ txst = &sc->vtnet_txqs[i].vtntx_stats;
+ stats->tx_tso_offloaded += txst->vtxs_tso;
+ }
+ return (sysctl_handle_64(oidp, NULL, stats->tx_tso_offloaded, req));
+}
+
+static int
+vtnet_sysctl_tx_task_rescheduled(SYSCTL_HANDLER_ARGS)
+{
+ struct vtnet_softc *sc = (struct vtnet_softc *)arg1;
+ struct vtnet_statistics *stats = &sc->vtnet_stats;
+ struct vtnet_txq_stats *txst;
+ int i;
+
+ stats->tx_task_rescheduled = 0;
+ for (i = 0; i < sc->vtnet_max_vq_pairs; i++) {
+ txst = &sc->vtnet_txqs[i].vtntx_stats;
+ stats->tx_task_rescheduled += txst->vtxs_rescheduled;
+ }
+ return (sysctl_handle_64(oidp, NULL, stats->tx_task_rescheduled, req));
+}
+
static void
vtnet_setup_stat_sysctl(struct sysctl_ctx_list *ctx,
struct sysctl_oid_list *child, struct vtnet_softc *sc)
@@ -4189,69 +4300,75 @@ vtnet_setup_stat_sysctl(struct sysctl_ctx_list *ctx,
stats->tx_task_rescheduled = txaccum.vtxs_rescheduled;
SYSCTL_ADD_UQUAD(ctx, child, OID_AUTO, "mbuf_alloc_failed",
- CTLFLAG_RD, &stats->mbuf_alloc_failed,
+ CTLFLAG_RD | CTLFLAG_STATS, &stats->mbuf_alloc_failed,
"Mbuf cluster allocation failures");
SYSCTL_ADD_UQUAD(ctx, child, OID_AUTO, "rx_frame_too_large",
- CTLFLAG_RD, &stats->rx_frame_too_large,
+ CTLFLAG_RD | CTLFLAG_STATS, &stats->rx_frame_too_large,
"Received frame larger than the mbuf chain");
SYSCTL_ADD_UQUAD(ctx, child, OID_AUTO, "rx_enq_replacement_failed",
- CTLFLAG_RD, &stats->rx_enq_replacement_failed,
+ CTLFLAG_RD | CTLFLAG_STATS, &stats->rx_enq_replacement_failed,
"Enqueuing the replacement receive mbuf failed");
SYSCTL_ADD_UQUAD(ctx, child, OID_AUTO, "rx_mergeable_failed",
- CTLFLAG_RD, &stats->rx_mergeable_failed,
+ CTLFLAG_RD | CTLFLAG_STATS, &stats->rx_mergeable_failed,
"Mergeable buffers receive failures");
SYSCTL_ADD_UQUAD(ctx, child, OID_AUTO, "rx_csum_bad_ethtype",
- CTLFLAG_RD, &stats->rx_csum_bad_ethtype,
+ CTLFLAG_RD | CTLFLAG_STATS, &stats->rx_csum_bad_ethtype,
"Received checksum offloaded buffer with unsupported "
"Ethernet type");
SYSCTL_ADD_UQUAD(ctx, child, OID_AUTO, "rx_csum_bad_ipproto",
- CTLFLAG_RD, &stats->rx_csum_bad_ipproto,
+ CTLFLAG_RD | CTLFLAG_STATS, &stats->rx_csum_bad_ipproto,
"Received checksum offloaded buffer with incorrect IP protocol");
SYSCTL_ADD_UQUAD(ctx, child, OID_AUTO, "rx_csum_bad_offset",
- CTLFLAG_RD, &stats->rx_csum_bad_offset,
+ CTLFLAG_RD | CTLFLAG_STATS, &stats->rx_csum_bad_offset,
"Received checksum offloaded buffer with incorrect offset");
SYSCTL_ADD_UQUAD(ctx, child, OID_AUTO, "rx_csum_bad_proto",
- CTLFLAG_RD, &stats->rx_csum_bad_proto,
+ CTLFLAG_RD | CTLFLAG_STATS, &stats->rx_csum_bad_proto,
"Received checksum offloaded buffer with incorrect protocol");
- SYSCTL_ADD_UQUAD(ctx, child, OID_AUTO, "rx_csum_failed",
- CTLFLAG_RD, &stats->rx_csum_failed,
+ SYSCTL_ADD_PROC(ctx, child, OID_AUTO, "rx_csum_failed",
+ CTLTYPE_U64 | CTLFLAG_RD | CTLFLAG_STATS,
+ sc, 0, vtnet_sysctl_rx_csum_failed, "QU",
"Received buffer checksum offload failed");
- SYSCTL_ADD_UQUAD(ctx, child, OID_AUTO, "rx_csum_offloaded",
- CTLFLAG_RD, &stats->rx_csum_offloaded,
+ SYSCTL_ADD_PROC(ctx, child, OID_AUTO, "rx_csum_offloaded",
+ CTLTYPE_U64 | CTLFLAG_RD | CTLFLAG_STATS,
+ sc, 0, vtnet_sysctl_rx_csum_offloaded, "QU",
"Received buffer checksum offload succeeded");
- SYSCTL_ADD_UQUAD(ctx, child, OID_AUTO, "rx_task_rescheduled",
- CTLFLAG_RD, &stats->rx_task_rescheduled,
+ SYSCTL_ADD_PROC(ctx, child, OID_AUTO, "rx_task_rescheduled",
+ CTLTYPE_U64 | CTLFLAG_RD | CTLFLAG_STATS,
+ sc, 0, vtnet_sysctl_rx_task_rescheduled, "QU",
"Times the receive interrupt task rescheduled itself");
SYSCTL_ADD_UQUAD(ctx, child, OID_AUTO, "tx_csum_unknown_ethtype",
- CTLFLAG_RD, &stats->tx_csum_unknown_ethtype,
+ CTLFLAG_RD | CTLFLAG_STATS, &stats->tx_csum_unknown_ethtype,
"Aborted transmit of checksum offloaded buffer with unknown "
"Ethernet type");
SYSCTL_ADD_UQUAD(ctx, child, OID_AUTO, "tx_csum_proto_mismatch",
- CTLFLAG_RD, &stats->tx_csum_proto_mismatch,
+ CTLFLAG_RD | CTLFLAG_STATS, &stats->tx_csum_proto_mismatch,
"Aborted transmit of checksum offloaded buffer because mismatched "
"protocols");
SYSCTL_ADD_UQUAD(ctx, child, OID_AUTO, "tx_tso_not_tcp",
- CTLFLAG_RD, &stats->tx_tso_not_tcp,
+ CTLFLAG_RD | CTLFLAG_STATS, &stats->tx_tso_not_tcp,
"Aborted transmit of TSO buffer with non TCP protocol");
SYSCTL_ADD_UQUAD(ctx, child, OID_AUTO, "tx_tso_without_csum",
- CTLFLAG_RD, &stats->tx_tso_without_csum,
+ CTLFLAG_RD | CTLFLAG_STATS, &stats->tx_tso_without_csum,
"Aborted transmit of TSO buffer without TCP checksum offload");
SYSCTL_ADD_UQUAD(ctx, child, OID_AUTO, "tx_defragged",
- CTLFLAG_RD, &stats->tx_defragged,
+ CTLFLAG_RD | CTLFLAG_STATS, &stats->tx_defragged,
"Transmit mbufs defragged");
SYSCTL_ADD_UQUAD(ctx, child, OID_AUTO, "tx_defrag_failed",
- CTLFLAG_RD, &stats->tx_defrag_failed,
+ CTLFLAG_RD | CTLFLAG_STATS, &stats->tx_defrag_failed,
"Aborted transmit of buffer because defrag failed");
- SYSCTL_ADD_UQUAD(ctx, child, OID_AUTO, "tx_csum_offloaded",
- CTLFLAG_RD, &stats->tx_csum_offloaded,
+ SYSCTL_ADD_PROC(ctx, child, OID_AUTO, "tx_csum_offloaded",
+ CTLTYPE_U64 | CTLFLAG_RD | CTLFLAG_STATS,
+ sc, 0, vtnet_sysctl_tx_csum_offloaded, "QU",
"Offloaded checksum of transmitted buffer");
- SYSCTL_ADD_UQUAD(ctx, child, OID_AUTO, "tx_tso_offloaded",
- CTLFLAG_RD, &stats->tx_tso_offloaded,
+ SYSCTL_ADD_PROC(ctx, child, OID_AUTO, "tx_tso_offloaded",
+ CTLTYPE_U64 | CTLFLAG_RD | CTLFLAG_STATS,
+ sc, 0, vtnet_sysctl_tx_tso_offloaded, "QU",
"Segmentation offload of transmitted buffer");
- SYSCTL_ADD_UQUAD(ctx, child, OID_AUTO, "tx_task_rescheduled",
- CTLFLAG_RD, &stats->tx_task_rescheduled,
+ SYSCTL_ADD_PROC(ctx, child, OID_AUTO, "tx_task_rescheduled",
+ CTLTYPE_U64 | CTLFLAG_RD | CTLFLAG_STATS,
+ sc, 0, vtnet_sysctl_tx_task_rescheduled, "QU",
"Times the transmit interrupt task rescheduled itself");
}
diff --git a/sys/fs/nfsclient/nfs_clvnops.c b/sys/fs/nfsclient/nfs_clvnops.c
index a8b06fdb261b..eee571a04821 100644
--- a/sys/fs/nfsclient/nfs_clvnops.c
+++ b/sys/fs/nfsclient/nfs_clvnops.c
@@ -3474,7 +3474,7 @@ nfs_advlock(struct vop_advlock_args *ap)
u_quad_t size;
struct nfsmount *nmp;
- error = NFSVOPLOCK(vp, LK_SHARED);
+ error = NFSVOPLOCK(vp, LK_EXCLUSIVE);
if (error != 0)
return (EBADF);
nmp = VFSTONFS(vp->v_mount);
@@ -3511,11 +3511,6 @@ nfs_advlock(struct vop_advlock_args *ap)
cred = p->p_ucred;
else
cred = td->td_ucred;
- NFSVOPLOCK(vp, LK_UPGRADE | LK_RETRY);
- if (VN_IS_DOOMED(vp)) {
- error = EBADF;
- goto out;
- }
/*
* If this is unlocking a write locked region, flush and
diff --git a/sys/fs/tarfs/tarfs_vnops.c b/sys/fs/tarfs/tarfs_vnops.c
index acf18de5ab51..c110107bb210 100644
--- a/sys/fs/tarfs/tarfs_vnops.c
+++ b/sys/fs/tarfs/tarfs_vnops.c
@@ -334,6 +334,10 @@ tarfs_readdir(struct vop_readdir_args *ap)
tnp, tnp->name, uio->uio_offset, uio->uio_resid);
if (uio->uio_offset == TARFS_COOKIE_EOF) {
+ if (eofflag != NULL) {
+ TARFS_DPF(VNODE, "%s: Setting EOF flag\n", __func__);
+ *eofflag = 1;
+ }
TARFS_DPF(VNODE, "%s: EOF\n", __func__);
return (0);
}
diff --git a/sys/kern/kern_thread.c b/sys/kern/kern_thread.c
index 50b040132396..3180c66cb42b 100644
--- a/sys/kern/kern_thread.c
+++ b/sys/kern/kern_thread.c
@@ -1694,8 +1694,10 @@ thread_single_end(struct proc *p, int mode)
thread_unlock(td);
}
}
- KASSERT(mode != SINGLE_BOUNDARY || p->p_boundary_count == 0,
- ("inconsistent boundary count %d", p->p_boundary_count));
+ KASSERT(mode != SINGLE_BOUNDARY || P_SHOULDSTOP(p) ||
+ p->p_boundary_count == 0,
+ ("pid %d proc %p flags %#x inconsistent boundary count %d",
+ p->p_pid, p, p->p_flag, p->p_boundary_count));
PROC_SUNLOCK(p);
wakeup(&p->p_flag);
}
diff --git a/sys/kern/subr_witness.c b/sys/kern/subr_witness.c
index ab47b6ad29a3..a65c3ca128d9 100644
--- a/sys/kern/subr_witness.c
+++ b/sys/kern/subr_witness.c
@@ -57,7 +57,7 @@
* b : public affirmation by word or example of usually
* religious faith or conviction <the heroic witness to divine
* life -- Pilot>
- * 6 capitalized : a member of the Jehovah's Witnesses
+ * 6 capitalized : a member of the Jehovah's Witnesses
*/
/*
@@ -131,7 +131,7 @@
#define LI_SLEEPABLE 0x00040000 /* Lock may be held while sleeping. */
#ifndef WITNESS_COUNT
-#define WITNESS_COUNT 1536
+#define WITNESS_COUNT 1536
#endif
#define WITNESS_HASH_SIZE 251 /* Prime, gives load factor < 2 */
#define WITNESS_PENDLIST (512 + (MAXCPU * 4))
@@ -158,20 +158,18 @@
* These flags go in the witness relationship matrix and describe the
* relationship between any two struct witness objects.
*/
-#define WITNESS_UNRELATED 0x00 /* No lock order relation. */
-#define WITNESS_PARENT 0x01 /* Parent, aka direct ancestor. */
-#define WITNESS_ANCESTOR 0x02 /* Direct or indirect ancestor. */
-#define WITNESS_CHILD 0x04 /* Child, aka direct descendant. */
-#define WITNESS_DESCENDANT 0x08 /* Direct or indirect descendant. */
-#define WITNESS_ANCESTOR_MASK (WITNESS_PARENT | WITNESS_ANCESTOR)
-#define WITNESS_DESCENDANT_MASK (WITNESS_CHILD | WITNESS_DESCENDANT)
-#define WITNESS_RELATED_MASK \
- (WITNESS_ANCESTOR_MASK | WITNESS_DESCENDANT_MASK)
-#define WITNESS_REVERSAL 0x10 /* A lock order reversal has been
- * observed. */
-#define WITNESS_RESERVED1 0x20 /* Unused flag, reserved. */
-#define WITNESS_RESERVED2 0x40 /* Unused flag, reserved. */
-#define WITNESS_LOCK_ORDER_KNOWN 0x80 /* This lock order is known. */
+#define WITNESS_UNRELATED 0x00 /* No lock order relation. */
+#define WITNESS_PARENT 0x01 /* Parent, aka direct ancestor. */
+#define WITNESS_ANCESTOR 0x02 /* Direct or indirect ancestor. */
+#define WITNESS_CHILD 0x04 /* Child, aka direct descendant. */
+#define WITNESS_DESCENDANT 0x08 /* Direct or indirect descendant. */
+#define WITNESS_ANCESTOR_MASK (WITNESS_PARENT | WITNESS_ANCESTOR)
+#define WITNESS_DESCENDANT_MASK (WITNESS_CHILD | WITNESS_DESCENDANT)
+#define WITNESS_RELATED_MASK (WITNESS_ANCESTOR_MASK | WITNESS_DESCENDANT_MASK)
+#define WITNESS_REVERSAL 0x10 /* A lock order reversal has been observed. */
+#define WITNESS_RESERVED1 0x20 /* Unused flag, reserved. */
+#define WITNESS_RESERVED2 0x40 /* Unused flag, reserved. */
+#define WITNESS_LOCK_ORDER_KNOWN 0x80 /* This lock order is known. */
/* Descendant to ancestor flags */
#define WITNESS_DTOA(x) (((x) & WITNESS_RELATED_MASK) >> 2)
@@ -218,20 +216,18 @@ struct lock_list_entry {
* (for example, "vnode interlock").
*/
struct witness {
- char w_name[MAX_W_NAME];
- uint32_t w_index; /* Index in the relationship matrix */
+ char w_name[MAX_W_NAME];
+ uint32_t w_index; /* Index in the relationship matrix */
struct lock_class *w_class;
- STAILQ_ENTRY(witness) w_list; /* List of all witnesses. */
- STAILQ_ENTRY(witness) w_typelist; /* Witnesses of a type. */
- struct witness *w_hash_next; /* Linked list in hash buckets. */
- const char *w_file; /* File where last acquired */
- uint32_t w_line; /* Line where last acquired */
- uint32_t w_refcount;
- uint16_t w_num_ancestors; /* direct/indirect
- * ancestor count */
- uint16_t w_num_descendants; /* direct/indirect
- * descendant count */
- int16_t w_ddb_level;
+ STAILQ_ENTRY(witness) w_list; /* List of all witnesses. */
+ STAILQ_ENTRY(witness) w_typelist; /* Witnesses of a type. */
+ struct witness *w_hash_next; /* Linked list in hash buckets. */
+ const char *w_file; /* File where last acquired */
+ uint32_t w_line; /* Line where last acquired */
+ uint32_t w_refcount;
+ uint16_t w_num_ancestors; /* direct/indirect ancestor count */
+ uint16_t w_num_descendants; /* direct/indirect descendant count */
+ int16_t w_ddb_level;
unsigned w_displayed:1;
unsigned w_reversed:1;
};
@@ -265,7 +261,7 @@ struct witness_lock_order_data {
/*
* The witness lock order data hash table. Keys are witness index tuples
* (struct witness_lock_order_key), elements are lock order data objects
- * (struct witness_lock_order_data).
+ * (struct witness_lock_order_data).
*/
struct witness_lock_order_hash {
struct witness_lock_order_data *wloh_array[WITNESS_LO_HASH_SIZE];
@@ -295,7 +291,6 @@ struct witness_order_list_entry {
static __inline int
witness_lock_type_equal(struct witness *w1, struct witness *w2)
{
-
return ((w1->w_class->lc_flags & (LC_SLEEPLOCK | LC_SPINLOCK)) ==
(w2->w_class->lc_flags & (LC_SLEEPLOCK | LC_SPINLOCK)));
}
@@ -304,7 +299,6 @@ static __inline int
witness_lock_order_key_equal(const struct witness_lock_order_key *a,
const struct witness_lock_order_key *b)
{
-
return (a->from == b->from && a->to == b->to);
}
@@ -415,7 +409,7 @@ SYSCTL_INT(_debug_witness, OID_AUTO, skipspin, CTLFLAG_RDTUN, &witness_skipspin,
int badstack_sbuf_size;
int witness_count = WITNESS_COUNT;
-SYSCTL_INT(_debug_witness, OID_AUTO, witness_count, CTLFLAG_RDTUN,
+SYSCTL_INT(_debug_witness, OID_AUTO, witness_count, CTLFLAG_RDTUN,
&witness_count, 0, "");
/*
@@ -760,7 +754,6 @@ static int witness_spin_warn = 0;
static const char *
fixup_filename(const char *file)
{
-
if (file == NULL)
return (NULL);
while (strncmp(file, "../", 3) == 0)
@@ -835,7 +828,7 @@ witness_startup(void *mem)
w_free_cnt--;
for (i = 0; i < witness_count; i++) {
- memset(w_rmatrix[i], 0, sizeof(*w_rmatrix[i]) *
+ memset(w_rmatrix[i], 0, sizeof(*w_rmatrix[i]) *
(witness_count + 1));
}
@@ -989,16 +982,16 @@ witness_ddb_display_descendants(int(*prnt)(const char *fmt, ...),
{
int i;
- for (i = 0; i < indent; i++)
- prnt(" ");
+ for (i = 0; i < indent; i++)
+ prnt(" ");
prnt("%s (type: %s, depth: %d, active refs: %d)",
w->w_name, w->w_class->lc_name,
w->w_ddb_level, w->w_refcount);
- if (w->w_displayed) {
- prnt(" -- (already displayed)\n");
- return;
- }
- w->w_displayed = 1;
+ if (w->w_displayed) {
+ prnt(" -- (already displayed)\n");
+ return;
+ }
+ w->w_displayed = 1;
if (w->w_file != NULL && w->w_line != 0)
prnt(" -- last acquired @ %s:%d\n", fixup_filename(w->w_file),
w->w_line);
@@ -1079,7 +1072,6 @@ witness_ddb_display(int(*prnt)(const char *fmt, ...))
int
witness_defineorder(struct lock_object *lock1, struct lock_object *lock2)
{
-
if (witness_watch == -1 || KERNEL_PANICKED())
return (0);
@@ -1257,7 +1249,7 @@ witness_checkorder(struct lock_object *lock, int flags, const char *file,
w->w_reversed = 1;
mtx_unlock_spin(&w_mtx);
witness_output(
- "acquiring duplicate lock of same type: \"%s\"\n",
+ "acquiring duplicate lock of same type: \"%s\"\n",
w->w_name);
witness_output(" 1st %s @ %s:%d\n", plock->li_lock->lo_name,
fixup_filename(plock->li_file), plock->li_line);
@@ -1743,7 +1735,7 @@ found:
/*
* In order to reduce contention on w_mtx, we want to keep always an
- * head object into lists so that frequent allocation from the
+ * head object into lists so that frequent allocation from the
* free witness pool (and subsequent locking) is avoided.
* In order to maintain the current code simple, when the head
* object is totally unloaded it means also that we do not have
@@ -1781,7 +1773,7 @@ witness_thread_exit(struct thread *td)
n++;
witness_list_lock(&lle->ll_children[i],
witness_output);
-
+
}
kassert_panic(
"Thread %p cannot exit while holding sleeplocks\n", td);
@@ -1948,7 +1940,6 @@ found:
static void
depart(struct witness *w)
{
-
MPASS(w->w_refcount == 0);
if (w->w_class->lc_flags & LC_SLEEPLOCK) {
w_sleep_cnt--;
@@ -1999,18 +1990,18 @@ adopt(struct witness *parent, struct witness *child)
child->w_num_ancestors++;
}
- /*
- * Find each ancestor of 'pi'. Note that 'pi' itself is counted as
+ /*
+ * Find each ancestor of 'pi'. Note that 'pi' itself is counted as
* an ancestor of 'pi' during this loop.
*/
for (i = 1; i <= w_max_used_index; i++) {
- if ((w_rmatrix[i][pi] & WITNESS_ANCESTOR_MASK) == 0 &&
+ if ((w_rmatrix[i][pi] & WITNESS_ANCESTOR_MASK) == 0 &&
(i != pi))
continue;
/* Find each descendant of 'i' and mark it as a descendant. */
for (j = 1; j <= w_max_used_index; j++) {
- /*
+ /*
* Skip children that are already marked as
* descendants of 'i'.
*/
@@ -2021,7 +2012,7 @@ adopt(struct witness *parent, struct witness *child)
* We are only interested in descendants of 'ci'. Note
* that 'ci' itself is counted as a descendant of 'ci'.
*/
- if ((w_rmatrix[ci][j] & WITNESS_ANCESTOR_MASK) == 0 &&
+ if ((w_rmatrix[ci][j] & WITNESS_ANCESTOR_MASK) == 0 &&
(j != ci))
continue;
w_rmatrix[i][j] |= WITNESS_ANCESTOR;
@@ -2029,16 +2020,16 @@ adopt(struct witness *parent, struct witness *child)
w_data[i].w_num_descendants++;
w_data[j].w_num_ancestors++;
- /*
+ /*
* Make sure we aren't marking a node as both an
- * ancestor and descendant. We should have caught
+ * ancestor and descendant. We should have caught
* this as a lock order reversal earlier.
*/
if ((w_rmatrix[i][j] & WITNESS_ANCESTOR_MASK) &&
(w_rmatrix[i][j] & WITNESS_DESCENDANT_MASK)) {
printf("witness rmatrix paradox! [%d][%d]=%d "
"both ancestor and descendant\n",
- i, j, w_rmatrix[i][j]);
+ i, j, w_rmatrix[i][j]);
kdb_backtrace();
printf("Witness disabled.\n");
witness_watch = -1;
@@ -2047,7 +2038,7 @@ adopt(struct witness *parent, struct witness *child)
(w_rmatrix[j][i] & WITNESS_DESCENDANT_MASK)) {
printf("witness rmatrix paradox! [%d][%d]=%d "
"both ancestor and descendant\n",
- j, i, w_rmatrix[j][i]);
+ j, i, w_rmatrix[j][i]);
kdb_backtrace();
printf("Witness disabled.\n");
witness_watch = -1;
@@ -2124,7 +2115,6 @@ _isitmyx(struct witness *w1, struct witness *w2, int rmask, const char *fname)
static int
isitmychild(struct witness *parent, struct witness *child)
{
-
return (_isitmyx(parent, child, WITNESS_PARENT, __func__));
}
@@ -2134,7 +2124,6 @@ isitmychild(struct witness *parent, struct witness *child)
static int
isitmydescendant(struct witness *ancestor, struct witness *descendant)
{
-
return (_isitmyx(ancestor, descendant, WITNESS_ANCESTOR_MASK,
__func__));
}
@@ -2182,7 +2171,7 @@ witness_get(void)
STAILQ_REMOVE_HEAD(&w_free, w_list);
w_free_cnt--;
index = w->w_index;
- MPASS(index > 0 && index == w_max_used_index+1 &&
+ MPASS(index > 0 && index == w_max_used_index + 1 &&
index < witness_count);
bzero(w, sizeof(*w));
w->w_index = index;
@@ -2194,7 +2183,6 @@ witness_get(void)
static void
witness_free(struct witness *w)
{
-
STAILQ_INSERT_HEAD(&w_free, w, w_list);
w_free_cnt++;
}
@@ -2219,11 +2207,10 @@ witness_lock_list_get(void)
bzero(lle, sizeof(*lle));
return (lle);
}
-
+
static void
witness_lock_list_free(struct lock_list_entry *lle)
{
-
mtx_lock_spin(&w_mtx);
lle->ll_next = w_lock_list_free;
w_lock_list_free = lle;
@@ -2297,7 +2284,6 @@ witness_voutput(const char *fmt, va_list ap)
static int
witness_thread_has_locks(struct thread *td)
{
-
if (td->td_sleeplocks == NULL)
return (0);
return (td->td_sleeplocks->ll_count != 0);
@@ -2573,14 +2559,12 @@ witness_setflag(struct lock_object *lock, int flag, int set)
void
witness_norelease(struct lock_object *lock)
{
-
witness_setflag(lock, LI_NORELEASE, 1);
}
void
witness_releaseok(struct lock_object *lock)
{
-
witness_setflag(lock, LI_NORELEASE, 0);
}
@@ -2588,7 +2572,6 @@ witness_releaseok(struct lock_object *lock)
static void
witness_ddb_list(struct thread *td)
{
-
KASSERT(witness_cold == 0, ("%s: witness_cold", __func__));
KASSERT(kdb_active, ("%s: not in the debugger", __func__));
@@ -2653,7 +2636,6 @@ DB_SHOW_ALIAS_FLAGS(alllocks, db_witness_list_all, DB_CMD_MEMSAFE);
DB_SHOW_COMMAND_FLAGS(witness, db_witness_display, DB_CMD_MEMSAFE)
{
-
witness_ddb_display(db_printf);
}
#endif
@@ -2673,9 +2655,9 @@ sbuf_print_witness_badstacks(struct sbuf *sb, size_t *oldidx)
/* Allocate and init temporary storage space. */
tmp_w1 = malloc(sizeof(struct witness), M_TEMP, M_WAITOK | M_ZERO);
tmp_w2 = malloc(sizeof(struct witness), M_TEMP, M_WAITOK | M_ZERO);
- tmp_data1 = malloc(sizeof(struct witness_lock_order_data), M_TEMP,
+ tmp_data1 = malloc(sizeof(struct witness_lock_order_data), M_TEMP,
M_WAITOK | M_ZERO);
- tmp_data2 = malloc(sizeof(struct witness_lock_order_data), M_TEMP,
+ tmp_data2 = malloc(sizeof(struct witness_lock_order_data), M_TEMP,
M_WAITOK | M_ZERO);
stack_zero(&tmp_data1->wlod_stack);
stack_zero(&tmp_data2->wlod_stack);
@@ -2750,12 +2732,12 @@ restart:
sbuf_printf(sb,
"\nLock order reversal between \"%s\"(%s) and \"%s\"(%s)!\n",
- tmp_w1->w_name, tmp_w1->w_class->lc_name,
+ tmp_w1->w_name, tmp_w1->w_class->lc_name,
tmp_w2->w_name, tmp_w2->w_class->lc_name);
if (data1) {
sbuf_printf(sb,
"Lock order \"%s\"(%s) -> \"%s\"(%s) first seen at:\n",
- tmp_w1->w_name, tmp_w1->w_class->lc_name,
+ tmp_w1->w_name, tmp_w1->w_class->lc_name,
tmp_w2->w_name, tmp_w2->w_class->lc_name);
stack_sbuf_print(sb, &tmp_data1->wlod_stack);
sbuf_putc(sb, '\n');
@@ -2763,7 +2745,7 @@ restart:
if (data2 && data2 != data1) {
sbuf_printf(sb,
"Lock order \"%s\"(%s) -> \"%s\"(%s) first seen at:\n",
- tmp_w2->w_name, tmp_w2->w_class->lc_name,
+ tmp_w2->w_name, tmp_w2->w_class->lc_name,
tmp_w1->w_name, tmp_w1->w_class->lc_name);
stack_sbuf_print(sb, &tmp_data2->wlod_stack);
sbuf_putc(sb, '\n');
@@ -2823,7 +2805,6 @@ sysctl_debug_witness_badstacks(SYSCTL_HANDLER_ARGS)
static int
sbuf_db_printf_drain(void *arg __unused, const char *data, int len)
{
-
return (db_printf("%.*s", len, data));
}
@@ -3068,7 +3049,7 @@ witness_lock_order_get(struct witness *parent, struct witness *child)
& WITNESS_LOCK_ORDER_KNOWN) == 0)
goto out;
- hash = witness_hash_djb2((const char*)&key,
+ hash = witness_hash_djb2((const char *)&key,
sizeof(key)) % w_lohash.wloh_size;
data = w_lohash.wloh_array[hash];
while (data != NULL) {
@@ -3089,7 +3070,6 @@ out:
static int
witness_lock_order_check(struct witness *parent, struct witness *child)
{
-
if (parent != child &&
w_rmatrix[parent->w_index][child->w_index]
& WITNESS_LOCK_ORDER_KNOWN &&
@@ -3115,7 +3095,7 @@ witness_lock_order_add(struct witness *parent, struct witness *child)
& WITNESS_LOCK_ORDER_KNOWN)
return (1);
- hash = witness_hash_djb2((const char*)&key,
+ hash = witness_hash_djb2((const char *)&key,
sizeof(key)) % w_lohash.wloh_size;
w_rmatrix[parent->w_index][child->w_index] |= WITNESS_LOCK_ORDER_KNOWN;
data = w_lofree;
@@ -3134,7 +3114,6 @@ witness_lock_order_add(struct witness *parent, struct witness *child)
static void
witness_increment_graph_generation(void)
{
-
if (witness_cold == 0)
mtx_assert(&w_mtx, MA_OWNED);
w_generation++;
@@ -3143,7 +3122,6 @@ witness_increment_graph_generation(void)
static int
witness_output_drain(void *arg __unused, const char *data, int len)
{
-
witness_output("%.*s", len, data);
return (len);
}
diff --git a/sys/kern/vfs_init.c b/sys/kern/vfs_init.c
index cd30d5cfae47..93ac001af8ad 100644
--- a/sys/kern/vfs_init.c
+++ b/sys/kern/vfs_init.c
@@ -103,6 +103,16 @@ struct vattr va_null;
* Routines having to do with the management of the vnode table.
*/
+void
+vfs_unref_vfsconf(struct vfsconf *vfsp)
+{
+ vfsconf_lock();
+ KASSERT(vfsp->vfc_refcount > 0,
+ ("vfs %p refcount underflow %d", vfsp, vfsp->vfc_refcount));
+ vfsp->vfc_refcount--;
+ vfsconf_unlock();
+}
+
static struct vfsconf *
vfs_byname_locked(const char *name)
{
@@ -123,9 +133,11 @@ vfs_byname(const char *name)
{
struct vfsconf *vfsp;
- vfsconf_slock();
+ vfsconf_lock();
vfsp = vfs_byname_locked(name);
- vfsconf_sunlock();
+ if (vfsp != NULL)
+ vfsp->vfc_refcount++;
+ vfsconf_unlock();
return (vfsp);
}
diff --git a/sys/kern/vfs_mount.c b/sys/kern/vfs_mount.c
index 8e64a7fe966b..13403acacc08 100644
--- a/sys/kern/vfs_mount.c
+++ b/sys/kern/vfs_mount.c
@@ -683,7 +683,6 @@ vfs_mount_alloc(struct vnode *vp, struct vfsconf *vfsp, const char *fspath,
MPASSERT(mp->mnt_vfs_ops == 1, mp,
("vfs_ops should be 1 but %d found", mp->mnt_vfs_ops));
(void) vfs_busy(mp, MBF_NOWAIT);
- atomic_add_acq_int(&vfsp->vfc_refcount, 1);
mp->mnt_op = vfsp->vfc_vfsops;
mp->mnt_vfc = vfsp;
mp->mnt_stat.f_type = vfsp->vfc_typenum;
@@ -731,7 +730,6 @@ vfs_mount_destroy(struct mount *mp)
__FILE__, __LINE__));
MPPASS(mp->mnt_writeopcount == 0, mp);
MPPASS(mp->mnt_secondary_writes == 0, mp);
- atomic_subtract_rel_int(&mp->mnt_vfc->vfc_refcount, 1);
if (!TAILQ_EMPTY(&mp->mnt_nvnodelist)) {
struct vnode *vp;
@@ -769,6 +767,9 @@ vfs_mount_destroy(struct mount *mp)
vfs_free_addrlist(mp->mnt_export);
free(mp->mnt_export, M_MOUNT);
}
+ vfsconf_lock();
+ mp->mnt_vfc->vfc_refcount--;
+ vfsconf_unlock();
crfree(mp->mnt_cred);
uma_zfree(mount_zone, mp);
}
@@ -1133,6 +1134,7 @@ vfs_domount_first(
if (jailed(td->td_ucred) && (!prison_allow(td->td_ucred,
vfsp->vfc_prison_flag) || vp == td->td_ucred->cr_prison->pr_root)) {
vput(vp);
+ vfs_unref_vfsconf(vfsp);
return (EPERM);
}
@@ -1169,6 +1171,7 @@ vfs_domount_first(
}
if (error != 0) {
vput(vp);
+ vfs_unref_vfsconf(vfsp);
return (error);
}
vn_seqc_write_begin(vp);
diff --git a/sys/kern/vfs_subr.c b/sys/kern/vfs_subr.c
index a6e38be89291..57732ddab7d9 100644
--- a/sys/kern/vfs_subr.c
+++ b/sys/kern/vfs_subr.c
@@ -2186,6 +2186,8 @@ freevnode(struct vnode *vp)
{
struct bufobj *bo;
+ ASSERT_VOP_UNLOCKED(vp, __func__);
+
/*
* The vnode has been marked for destruction, so free it.
*
@@ -2222,12 +2224,16 @@ freevnode(struct vnode *vp)
mac_vnode_destroy(vp);
#endif
if (vp->v_pollinfo != NULL) {
+ int error __diagused;
+
/*
* Use LK_NOWAIT to shut up witness about the lock. We may get
* here while having another vnode locked when trying to
* satisfy a lookup and needing to recycle.
*/
- VOP_LOCK(vp, LK_EXCLUSIVE | LK_NOWAIT);
+ error = VOP_LOCK(vp, LK_EXCLUSIVE | LK_NOWAIT);
+ VNASSERT(error == 0, vp,
+ ("freevnode: cannot lock vp %p for pollinfo destroy", vp));
destroy_vpollinfo(vp->v_pollinfo);
VOP_UNLOCK(vp);
vp->v_pollinfo = NULL;
diff --git a/sys/modules/irdma/Makefile b/sys/modules/irdma/Makefile
index b2ffb67ca66f..a9ef6e63d3f2 100644
--- a/sys/modules/irdma/Makefile
+++ b/sys/modules/irdma/Makefile
@@ -1,8 +1,8 @@
.include <bsd.own.mk>
-OFED_INC_DIR = ${.CURDIR}/../../ofed/include
-ICE_DIR = ${.CURDIR}/../../dev/ice
-.PATH: ${.CURDIR}/../../dev/irdma
+OFED_INC_DIR = ${SRCTOP}/sys/ofed/include
+ICE_DIR = ${SRCTOP}/sys/dev/ice
+.PATH: ${SRCTOP}/sys/dev/irdma
KMOD= irdma
SRCS= icrdma.c
diff --git a/sys/net/if.c b/sys/net/if.c
index 202be4794f6e..0fc30488f1e5 100644
--- a/sys/net/if.c
+++ b/sys/net/if.c
@@ -74,7 +74,6 @@
#include <vm/uma.h>
#include <net/bpf.h>
-#include <net/ethernet.h>
#include <net/if.h>
#include <net/if_arp.h>
#include <net/if_clone.h>
diff --git a/sys/net/iflib.c b/sys/net/iflib.c
index 98c59e5de988..308ecad0a846 100644
--- a/sys/net/iflib.c
+++ b/sys/net/iflib.c
@@ -712,7 +712,7 @@ static uint32_t iflib_txq_can_drain(struct ifmp_ring *);
static void iflib_altq_if_start(if_t ifp);
static int iflib_altq_if_transmit(if_t ifp, struct mbuf *m);
#endif
-static int iflib_register(if_ctx_t);
+static void iflib_register(if_ctx_t);
static void iflib_deregister(if_ctx_t);
static void iflib_unregister_vlan_handlers(if_ctx_t ctx);
static uint16_t iflib_get_mbuf_size_for(unsigned int size);
@@ -5136,10 +5136,7 @@ iflib_device_register(device_t dev, void *sc, if_shared_ctx_t sctx, if_ctx_t *ct
ctx->ifc_dev = dev;
ctx->ifc_softc = sc;
- if ((err = iflib_register(ctx)) != 0) {
- device_printf(dev, "iflib_register failed %d\n", err);
- goto fail_ctx_free;
- }
+ iflib_register(ctx);
iflib_add_device_sysctl_pre(ctx);
scctx = &ctx->ifc_softc_ctx;
@@ -5363,7 +5360,6 @@ iflib_device_register(device_t dev, void *sc, if_shared_ctx_t sctx, if_ctx_t *ct
DEBUGNET_SET(ctx->ifc_ifp, iflib);
- if_setgetcounterfn(ctx->ifc_ifp, iflib_if_get_counter);
iflib_add_device_sysctl_post(ctx);
iflib_add_pfil(ctx);
ctx->ifc_flags |= IFC_INIT_DONE;
@@ -5387,7 +5383,6 @@ fail_unlock:
CTX_UNLOCK(ctx);
IFNET_WUNLOCK();
iflib_deregister(ctx);
-fail_ctx_free:
device_set_softc(ctx->ifc_dev, NULL);
if (ctx->ifc_flags & IFC_SC_ALLOCATED)
free(ctx->ifc_softc, M_IFLIB);
@@ -5685,7 +5680,7 @@ _iflib_pre_assert(if_softc_ctx_t scctx)
MPASS(scctx->isc_txrx->ift_rxd_flush);
}
-static int
+static void
iflib_register(if_ctx_t ctx)
{
if_shared_ctx_t sctx = ctx->ifc_sctx;
@@ -5718,6 +5713,7 @@ iflib_register(if_ctx_t ctx)
if_settransmitfn(ifp, iflib_if_transmit);
#endif
if_setqflushfn(ifp, iflib_if_qflush);
+ if_setgetcounterfn(ifp, iflib_if_get_counter);
if_setflags(ifp, IFF_BROADCAST | IFF_SIMPLEX | IFF_MULTICAST);
ctx->ifc_vlan_attach_event =
EVENTHANDLER_REGISTER(vlan_config, iflib_vlan_register, ctx,
@@ -5731,7 +5727,6 @@ iflib_register(if_ctx_t ctx)
ifmedia_init(ctx->ifc_mediap, IFM_IMASK,
iflib_media_change, iflib_media_status);
}
- return (0);
}
static void
diff --git a/sys/net/pfvar.h b/sys/net/pfvar.h
index d6c13470f2eb..cf6d2508cf65 100644
--- a/sys/net/pfvar.h
+++ b/sys/net/pfvar.h
@@ -645,6 +645,7 @@ struct pf_kpool {
int tblidx;
u_int16_t proxy_port[2];
u_int8_t opts;
+ sa_family_t ipv6_nexthop_af;
};
struct pf_rule_actions {
@@ -2680,7 +2681,7 @@ u_short pf_map_addr(sa_family_t, struct pf_krule *,
struct pf_addr *, struct pf_kpool *);
u_short pf_map_addr_sn(u_int8_t, struct pf_krule *,
struct pf_addr *, struct pf_addr *,
- sa_family_t *, struct pfi_kkif **nkif,
+ sa_family_t *, struct pfi_kkif **,
struct pf_addr *, struct pf_kpool *,
pf_sn_types_t);
int pf_get_transaddr_af(struct pf_krule *,
diff --git a/sys/net80211/ieee80211_ddb.c b/sys/net80211/ieee80211_ddb.c
index d96d7988a864..1dd8e38b9896 100644
--- a/sys/net80211/ieee80211_ddb.c
+++ b/sys/net80211/ieee80211_ddb.c
@@ -296,7 +296,7 @@ _db_show_sta(const struct ieee80211_node *ni)
ni->ni_htparam, ni->ni_htctlchan, ni->ni_ht2ndchan);
db_printf("\thtopmode 0x%x htstbc 0x%x chw %d (%s)\n",
ni->ni_htopmode, ni->ni_htstbc,
- ni->ni_chw, ieee80211_ni_chw_to_str(ni->ni_chw));
+ ni->ni_chw, net80211_ni_chw_to_str(ni->ni_chw));
/* XXX ampdu state */
for (i = 0; i < WME_NUM_TID; i++)
diff --git a/sys/net80211/ieee80211_ht.c b/sys/net80211/ieee80211_ht.c
index c28f124648a1..018927a6dad4 100644
--- a/sys/net80211/ieee80211_ht.c
+++ b/sys/net80211/ieee80211_ht.c
@@ -1476,7 +1476,7 @@ ieee80211_ht_wds_init(struct ieee80211_node *ni)
ni->ni_htcap |= IEEE80211_HTCAP_SHORTGI20;
if (IEEE80211_IS_CHAN_HT40(ni->ni_chan)) {
ni->ni_htcap |= IEEE80211_HTCAP_CHWIDTH40;
- ni->ni_chw = IEEE80211_STA_RX_BW_40;
+ ni->ni_chw = NET80211_STA_RX_BW_40;
if (IEEE80211_IS_CHAN_HT40U(ni->ni_chan))
ni->ni_ht2ndchan = IEEE80211_HTINFO_2NDCHAN_ABOVE;
else if (IEEE80211_IS_CHAN_HT40D(ni->ni_chan))
@@ -1484,7 +1484,7 @@ ieee80211_ht_wds_init(struct ieee80211_node *ni)
if (vap->iv_flags_ht & IEEE80211_FHT_SHORTGI40)
ni->ni_htcap |= IEEE80211_HTCAP_SHORTGI40;
} else {
- ni->ni_chw = IEEE80211_STA_RX_BW_20;
+ ni->ni_chw = NET80211_STA_RX_BW_20;
ni->ni_ht2ndchan = IEEE80211_HTINFO_2NDCHAN_NONE;
}
ni->ni_htctlchan = ni->ni_chan->ic_ieee;
@@ -1580,7 +1580,7 @@ ieee80211_ht_node_join(struct ieee80211_node *ni)
if (ni->ni_flags & IEEE80211_NODE_HT) {
vap->iv_ht_sta_assoc++;
- if (ni->ni_chw == IEEE80211_STA_RX_BW_40)
+ if (ni->ni_chw == NET80211_STA_RX_BW_40)
vap->iv_ht40_sta_assoc++;
}
htinfo_update(vap);
@@ -1598,7 +1598,7 @@ ieee80211_ht_node_leave(struct ieee80211_node *ni)
if (ni->ni_flags & IEEE80211_NODE_HT) {
vap->iv_ht_sta_assoc--;
- if (ni->ni_chw == IEEE80211_STA_RX_BW_40)
+ if (ni->ni_chw == NET80211_STA_RX_BW_40)
vap->iv_ht40_sta_assoc--;
}
htinfo_update(vap);
@@ -1827,7 +1827,7 @@ htinfo_update_chw(struct ieee80211_node *ni, int htflags, int vhtflags)
done:
/* update node's (11n) tx channel width */
ni->ni_chw = IEEE80211_IS_CHAN_HT40(ni->ni_chan) ?
- IEEE80211_STA_RX_BW_40 : IEEE80211_STA_RX_BW_20;
+ NET80211_STA_RX_BW_40 : NET80211_STA_RX_BW_20;
return (ret);
}
@@ -2689,11 +2689,11 @@ ht_recv_action_ht_txchwidth(struct ieee80211_node *ni,
* here.
*/
chw = (frm[2] == IEEE80211_A_HT_TXCHWIDTH_2040) ?
- IEEE80211_STA_RX_BW_40 : IEEE80211_STA_RX_BW_20;
+ NET80211_STA_RX_BW_40 : NET80211_STA_RX_BW_20;
IEEE80211_NOTE(ni->ni_vap, IEEE80211_MSG_ACTION | IEEE80211_MSG_11N, ni,
"%s: HT txchwidth, width %d%s (%s)", __func__,
- chw, ni->ni_chw != chw ? "*" : "", ieee80211_ni_chw_to_str(chw));
+ chw, ni->ni_chw != chw ? "*" : "", net80211_ni_chw_to_str(chw));
if (chw != ni->ni_chw) {
/* XXX does this need to change the ht40 station count? */
ni->ni_chw = chw;
@@ -3832,5 +3832,5 @@ ieee80211_ht_check_tx_ht40(const struct ieee80211_node *ni)
return (IEEE80211_IS_CHAN_HT40(bss_chan) &&
IEEE80211_IS_CHAN_HT40(ni->ni_chan) &&
- (ni->ni_chw == IEEE80211_STA_RX_BW_40));
+ (ni->ni_chw == NET80211_STA_RX_BW_40));
}
diff --git a/sys/net80211/ieee80211_node.c b/sys/net80211/ieee80211_node.c
index a201d1b278f0..49ba00299fee 100644
--- a/sys/net80211/ieee80211_node.c
+++ b/sys/net80211/ieee80211_node.c
@@ -2673,7 +2673,7 @@ ieee80211_dump_node(struct ieee80211_node_table *nt __unused,
ni->ni_htctlchan, ni->ni_ht2ndchan);
net80211_printf("\thtopmode %x htstbc %x htchw %d (%s)\n",
ni->ni_htopmode, ni->ni_htstbc,
- ni->ni_chw, ieee80211_ni_chw_to_str(ni->ni_chw));
+ ni->ni_chw, net80211_ni_chw_to_str(ni->ni_chw));
net80211_printf("\tvhtcap %x freq1 %d freq2 %d vhtbasicmcs %x\n",
ni->ni_vhtcap, (int) ni->ni_vht_chan1, (int) ni->ni_vht_chan2,
(int) ni->ni_vht_basicmcs);
@@ -2831,7 +2831,7 @@ ieee80211_node_join(struct ieee80211_node *ni, int resp)
ni->ni_flags & IEEE80211_NODE_QOS ? ", QoS" : "",
/* XXX update for VHT string */
ni->ni_flags & IEEE80211_NODE_HT ?
- (ni->ni_chw == IEEE80211_STA_RX_BW_40 ? ", HT40" : ", HT20") : "",
+ (ni->ni_chw == NET80211_STA_RX_BW_40 ? ", HT40" : ", HT20") : "",
ni->ni_flags & IEEE80211_NODE_AMPDU ? " (+AMPDU)" : "",
ni->ni_flags & IEEE80211_NODE_AMSDU ? " (+AMSDU)" : "",
ni->ni_flags & IEEE80211_NODE_MIMO_RTS ? " (+SMPS-DYN)" :
diff --git a/sys/net80211/ieee80211_node.h b/sys/net80211/ieee80211_node.h
index ef25fa0d7fdd..f1246dd12419 100644
--- a/sys/net80211/ieee80211_node.h
+++ b/sys/net80211/ieee80211_node.h
@@ -109,33 +109,33 @@ enum ieee80211_mesh_mlstate {
"\20\1IDLE\2OPENSNT\2OPENRCV\3CONFIRMRCV\4ESTABLISHED\5HOLDING"
/*
- * This structure is shared with LinuxKPI 802.11 code describing up-to
- * which channel width the station can receive.
+ * This enum was shared with the LinuxKPI enum ieee80211_sta_rx_bandwidth
+ * describing up-to which channel width the station can receive.
* Rather than using hardcoded MHz values for the channel width use an enum with
* flags. This allows us to keep the uint8_t slot for ni_chw in
- * struct ieee80211_node and means we do not have to sync to the value for
- * LinuxKPI.
+ * struct ieee80211_node it means we do not have to sync to the value for
+ * LinuxKPI (just the names).
*
* NB: BW_20 needs to 0 and values need to be sorted! Cannot make it
* bitfield-alike for use with %b.
*/
-enum ieee80211_sta_rx_bw {
- IEEE80211_STA_RX_BW_20 = 0x00,
- IEEE80211_STA_RX_BW_40,
- IEEE80211_STA_RX_BW_80,
- IEEE80211_STA_RX_BW_160,
- IEEE80211_STA_RX_BW_320,
+enum net80211_sta_rx_bw {
+ NET80211_STA_RX_BW_20 = 0x00,
+ NET80211_STA_RX_BW_40,
+ NET80211_STA_RX_BW_80,
+ NET80211_STA_RX_BW_160,
+ NET80211_STA_RX_BW_320,
} __packed;
static inline const char *
-ieee80211_ni_chw_to_str(enum ieee80211_sta_rx_bw bw)
+net80211_ni_chw_to_str(enum net80211_sta_rx_bw bw)
{
switch (bw) {
- case IEEE80211_STA_RX_BW_20: return ("BW_20");
- case IEEE80211_STA_RX_BW_40: return ("BW_40");
- case IEEE80211_STA_RX_BW_80: return ("BW_80");
- case IEEE80211_STA_RX_BW_160: return ("BW_160");
- case IEEE80211_STA_RX_BW_320: return ("BW_320");
+ case NET80211_STA_RX_BW_20: return ("BW_20");
+ case NET80211_STA_RX_BW_40: return ("BW_40");
+ case NET80211_STA_RX_BW_80: return ("BW_80");
+ case NET80211_STA_RX_BW_160: return ("BW_160");
+ case NET80211_STA_RX_BW_320: return ("BW_320");
}
}
@@ -285,7 +285,7 @@ struct ieee80211_node {
uint8_t ni_ht2ndchan; /* HT 2nd channel */
uint8_t ni_htopmode; /* HT operating mode */
uint8_t ni_htstbc; /* HT */
- enum ieee80211_sta_rx_bw ni_chw; /* negotiated channel width */
+ enum net80211_sta_rx_bw ni_chw; /* negotiated channel width */
struct ieee80211_htrateset ni_htrates; /* negotiated ht rate set */
struct ieee80211_tx_ampdu ni_tx_ampdu[WME_NUM_TID];
struct ieee80211_rx_ampdu ni_rx_ampdu[WME_NUM_TID];
diff --git a/sys/net80211/ieee80211_phy.c b/sys/net80211/ieee80211_phy.c
index eb96d74a2bd9..7f53c717152b 100644
--- a/sys/net80211/ieee80211_phy.c
+++ b/sys/net80211/ieee80211_phy.c
@@ -658,26 +658,26 @@ static uint16_t ieee80211_vht_mcs_allowed_list_160[] = {
*
* See 802.11-2020 21.5 (Parameters for VHT-MCSs) for more details.
*
- * @param bw channel bandwidth, via enum ieee80211_sta_rx_bw
+ * @param bw channel bandwidth, via enum net80211_sta_rx_bw
* @param nss number of spatial streams, 1..8
* @returns bitmask of valid MCS rates from 0..9
*/
uint16_t
-ieee80211_phy_vht_get_mcs_mask(enum ieee80211_sta_rx_bw bw, uint8_t nss)
+ieee80211_phy_vht_get_mcs_mask(enum net80211_sta_rx_bw bw, uint8_t nss)
{
if (nss == 0 || nss > 8)
return (0);
switch (bw) {
- case IEEE80211_STA_RX_BW_20:
+ case NET80211_STA_RX_BW_20:
return (ieee80211_vht_mcs_allowed_list_20[nss - 1]);
- case IEEE80211_STA_RX_BW_40:
+ case NET80211_STA_RX_BW_40:
return (ieee80211_vht_mcs_allowed_list_40[nss - 1]);
- case IEEE80211_STA_RX_BW_80:
+ case NET80211_STA_RX_BW_80:
return (ieee80211_vht_mcs_allowed_list_80[nss - 1]);
- case IEEE80211_STA_RX_BW_160:
+ case NET80211_STA_RX_BW_160:
return (ieee80211_vht_mcs_allowed_list_160[nss - 1]);
- case IEEE80211_STA_RX_BW_320:
+ case NET80211_STA_RX_BW_320:
/* invalid for VHT */
return (0);
}
@@ -689,14 +689,14 @@ ieee80211_phy_vht_get_mcs_mask(enum ieee80211_sta_rx_bw bw, uint8_t nss)
*
* See 802.11-2020 21.5 (Parameters for VHT-MCSs) for more details.
*
- * @param bw channel bandwidth, via enum ieee80211_sta_rx_bw
+ * @param bw channel bandwidth, via enum net80211_sta_rx_bw
* @param nss number of spatial streams, 1..8
* @param mcs MCS rate, 0..9
* @retval true if the NSS / MCS / bandwidth combination is valid
* @retval false if the NSS / MCS / bandwidth combination is not valid
*/
bool
-ieee80211_phy_vht_validate_mcs(enum ieee80211_sta_rx_bw bw, uint8_t nss,
+ieee80211_phy_vht_validate_mcs(enum net80211_sta_rx_bw bw, uint8_t nss,
uint8_t mcs)
{
uint16_t mask;
@@ -737,7 +737,7 @@ static struct mcs_entry mcs_entries[] = {
/**
* @brief Calculate the bitrate of the given VHT MCS rate.
*
- * @param bw Channel bandwidth (enum ieee80211_sta_rx_bw)
+ * @param bw Channel bandwidth (enum net80211_sta_rx_bw)
* @param nss Number of spatial streams, 1..8
* @param mcs MCS, 0..9
* @param is_shortgi True if short guard-interval (400nS)
@@ -746,7 +746,7 @@ static struct mcs_entry mcs_entries[] = {
* @returns The bitrate in kbit/sec.
*/
uint32_t
-ieee80211_phy_vht_get_mcs_kbit(enum ieee80211_sta_rx_bw bw,
+ieee80211_phy_vht_get_mcs_kbit(enum net80211_sta_rx_bw bw,
uint8_t nss, uint8_t mcs, bool is_shortgi)
{
uint32_t sym_len, n_carriers;
@@ -773,16 +773,16 @@ ieee80211_phy_vht_get_mcs_kbit(enum ieee80211_sta_rx_bw bw,
* See 802.11-2020 Table 21-5 (Timing-related constraints.)
*/
switch (bw) {
- case IEEE80211_STA_RX_BW_20:
+ case NET80211_STA_RX_BW_20:
n_carriers = 52;
break;
- case IEEE80211_STA_RX_BW_40:
+ case NET80211_STA_RX_BW_40:
n_carriers = 108;
break;
- case IEEE80211_STA_RX_BW_80:
+ case NET80211_STA_RX_BW_80:
n_carriers = 234;
break;
- case IEEE80211_STA_RX_BW_160:
+ case NET80211_STA_RX_BW_160:
n_carriers = 468;
break;
default:
diff --git a/sys/net80211/ieee80211_phy.h b/sys/net80211/ieee80211_phy.h
index 749b082e34e9..391c8bfc5010 100644
--- a/sys/net80211/ieee80211_phy.h
+++ b/sys/net80211/ieee80211_phy.h
@@ -221,13 +221,13 @@ uint32_t ieee80211_compute_duration_ht(uint32_t frameLen,
uint16_t rate, int streams, int isht40,
int isShortGI);
-enum ieee80211_sta_rx_bw;
+enum net80211_sta_rx_bw;
-uint16_t ieee80211_phy_vht_get_mcs_mask(enum ieee80211_sta_rx_bw,
+uint16_t ieee80211_phy_vht_get_mcs_mask(enum net80211_sta_rx_bw,
uint8_t);
-bool ieee80211_phy_vht_validate_mcs(enum ieee80211_sta_rx_bw,
+bool ieee80211_phy_vht_validate_mcs(enum net80211_sta_rx_bw,
uint8_t, uint8_t);
-uint32_t ieee80211_phy_vht_get_mcs_kbit(enum ieee80211_sta_rx_bw,
+uint32_t ieee80211_phy_vht_get_mcs_kbit(enum net80211_sta_rx_bw,
uint8_t, uint8_t, bool);
#endif /* _KERNEL */
diff --git a/sys/net80211/ieee80211_sta.c b/sys/net80211/ieee80211_sta.c
index 463a8b16773b..19e5ffe9a367 100644
--- a/sys/net80211/ieee80211_sta.c
+++ b/sys/net80211/ieee80211_sta.c
@@ -1934,7 +1934,7 @@ sta_recv_mgmt(struct ieee80211_node *ni, struct mbuf *m0, int subtype,
vap->iv_flags&IEEE80211_F_USEPROT ? ", protection" : "",
ni->ni_flags & IEEE80211_NODE_QOS ? ", QoS" : "",
ni->ni_flags & IEEE80211_NODE_HT ?
- (ni->ni_chw == IEEE80211_STA_RX_BW_40 ? ", HT40" : ", HT20") : "",
+ (ni->ni_chw == NET80211_STA_RX_BW_40 ? ", HT40" : ", HT20") : "",
ni->ni_flags & IEEE80211_NODE_AMPDU ? " (+AMPDU)" : "",
ni->ni_flags & IEEE80211_NODE_AMSDU ? " (+AMSDU)" : "",
ni->ni_flags & IEEE80211_NODE_MIMO_RTS ? " (+SMPS-DYN)" :
diff --git a/sys/net80211/ieee80211_vht.c b/sys/net80211/ieee80211_vht.c
index de0b691d4d2a..10a5fc7f08ab 100644
--- a/sys/net80211/ieee80211_vht.c
+++ b/sys/net80211/ieee80211_vht.c
@@ -974,7 +974,7 @@ ieee80211_vht_check_tx_vht40(const struct ieee80211_node *ni)
return (IEEE80211_IS_CHAN_VHT40(bss_chan) &&
IEEE80211_IS_CHAN_VHT40(ni->ni_chan) &&
- (ni->ni_chw == IEEE80211_STA_RX_BW_40));
+ (ni->ni_chw == NET80211_STA_RX_BW_40));
}
/*
@@ -1003,7 +1003,7 @@ ieee80211_vht_check_tx_vht80(const struct ieee80211_node *ni)
*/
return (IEEE80211_IS_CHAN_VHT80(bss_chan) &&
IEEE80211_IS_CHAN_VHT80(ni->ni_chan) &&
- (ni->ni_chw != IEEE80211_STA_RX_BW_20));
+ (ni->ni_chw != NET80211_STA_RX_BW_20));
}
/*
@@ -1030,7 +1030,7 @@ ieee80211_vht_check_tx_vht160(const struct ieee80211_node *ni)
* If a HT TX width action frame sets it to 20MHz
* then reject doing 160MHz.
*/
- if (ni->ni_chw == IEEE80211_STA_RX_BW_20)
+ if (ni->ni_chw == NET80211_STA_RX_BW_20)
return (false);
if (IEEE80211_IS_CHAN_VHT160(bss_chan) &&
@@ -1062,19 +1062,19 @@ ieee80211_vht_check_tx_vht160(const struct ieee80211_node *ni)
*/
bool
ieee80211_vht_check_tx_bw(const struct ieee80211_node *ni,
- enum ieee80211_sta_rx_bw bw)
+ enum net80211_sta_rx_bw bw)
{
switch (bw) {
- case IEEE80211_STA_RX_BW_20:
+ case NET80211_STA_RX_BW_20:
return (ieee80211_vht_check_tx_vht(ni));
- case IEEE80211_STA_RX_BW_40:
+ case NET80211_STA_RX_BW_40:
return (ieee80211_vht_check_tx_vht40(ni));
- case IEEE80211_STA_RX_BW_80:
+ case NET80211_STA_RX_BW_80:
return (ieee80211_vht_check_tx_vht80(ni));
- case IEEE80211_STA_RX_BW_160:
+ case NET80211_STA_RX_BW_160:
return (ieee80211_vht_check_tx_vht160(ni));
- case IEEE80211_STA_RX_BW_320:
+ case NET80211_STA_RX_BW_320:
return (false);
default:
return (false);
@@ -1096,7 +1096,7 @@ ieee80211_vht_check_tx_bw(const struct ieee80211_node *ni,
*/
bool
ieee80211_vht_node_check_tx_valid_mcs(const struct ieee80211_node *ni,
- enum ieee80211_sta_rx_bw bw, uint8_t nss, uint8_t mcs)
+ enum net80211_sta_rx_bw bw, uint8_t nss, uint8_t mcs)
{
uint8_t mc;
diff --git a/sys/net80211/ieee80211_vht.h b/sys/net80211/ieee80211_vht.h
index a1529df4a85b..b9b19fbc6008 100644
--- a/sys/net80211/ieee80211_vht.h
+++ b/sys/net80211/ieee80211_vht.h
@@ -65,8 +65,8 @@ void ieee80211_vht_get_vhtinfo_ie(struct ieee80211_node *ni,
bool ieee80211_vht_check_tx_vht(const struct ieee80211_node *);
bool ieee80211_vht_check_tx_bw(const struct ieee80211_node *,
- enum ieee80211_sta_rx_bw);
+ enum net80211_sta_rx_bw);
bool ieee80211_vht_node_check_tx_valid_mcs(const struct ieee80211_node *,
- enum ieee80211_sta_rx_bw bw, uint8_t, uint8_t);
+ enum net80211_sta_rx_bw bw, uint8_t, uint8_t);
#endif /* _NET80211_IEEE80211_VHT_H_ */
diff --git a/sys/netinet/tcp_syncache.c b/sys/netinet/tcp_syncache.c
index 80e6b53d10df..bec1a0bd14c4 100644
--- a/sys/netinet/tcp_syncache.c
+++ b/sys/netinet/tcp_syncache.c
@@ -102,15 +102,15 @@
#include <security/mac/mac_framework.h>
-VNET_DEFINE_STATIC(int, tcp_syncookies) = 1;
+VNET_DEFINE_STATIC(bool, tcp_syncookies) = true;
#define V_tcp_syncookies VNET(tcp_syncookies)
-SYSCTL_INT(_net_inet_tcp, OID_AUTO, syncookies, CTLFLAG_VNET | CTLFLAG_RW,
+SYSCTL_BOOL(_net_inet_tcp, OID_AUTO, syncookies, CTLFLAG_VNET | CTLFLAG_RW,
&VNET_NAME(tcp_syncookies), 0,
"Use TCP SYN cookies if the syncache overflows");
-VNET_DEFINE_STATIC(int, tcp_syncookiesonly) = 0;
+VNET_DEFINE_STATIC(bool, tcp_syncookiesonly) = false;
#define V_tcp_syncookiesonly VNET(tcp_syncookiesonly)
-SYSCTL_INT(_net_inet_tcp, OID_AUTO, syncookies_only, CTLFLAG_VNET | CTLFLAG_RW,
+SYSCTL_BOOL(_net_inet_tcp, OID_AUTO, syncookies_only, CTLFLAG_VNET | CTLFLAG_RW,
&VNET_NAME(tcp_syncookiesonly), 0,
"Use only TCP SYN cookies");
@@ -553,9 +553,8 @@ syncache_timer(void *xsch)
static inline bool
syncache_cookiesonly(void)
{
-
- return (V_tcp_syncookies && (V_tcp_syncache.paused ||
- V_tcp_syncookiesonly));
+ return ((V_tcp_syncookies && V_tcp_syncache.paused) ||
+ V_tcp_syncookiesonly);
}
/*
@@ -1083,40 +1082,48 @@ syncache_expand(struct in_conninfo *inc, struct tcpopt *to, struct tcphdr *th,
#endif
if (sc == NULL) {
- /*
- * There is no syncache entry, so see if this ACK is
- * a returning syncookie. To do this, first:
- * A. Check if syncookies are used in case of syncache
- * overflows
- * B. See if this socket has had a syncache entry dropped in
- * the recent past. We don't want to accept a bogus
- * syncookie if we've never received a SYN or accept it
- * twice.
- * C. check that the syncookie is valid. If it is, then
- * cobble up a fake syncache entry, and return.
- */
- if (locked && !V_tcp_syncookies) {
- SCH_UNLOCK(sch);
- TCPSTAT_INC(tcps_sc_spurcookie);
- if ((s = tcp_log_addrs(inc, th, NULL, NULL)))
- log(LOG_DEBUG, "%s; %s: Spurious ACK, "
- "segment rejected (syncookies disabled)\n",
- s, __func__);
- goto failed;
- }
- if (locked && !V_tcp_syncookiesonly &&
- sch->sch_last_overflow < time_uptime - SYNCOOKIE_LIFETIME) {
+ if (locked) {
+ /*
+ * The syncache is currently in use (neither disabled,
+ * nor paused), but no entry was found.
+ */
+ if (!V_tcp_syncookies) {
+ /*
+ * Since no syncookies are used in case of
+ * a bucket overflow, don't even check for
+ * a valid syncookie.
+ */
+ SCH_UNLOCK(sch);
+ TCPSTAT_INC(tcps_sc_spurcookie);
+ if ((s = tcp_log_addrs(inc, th, NULL, NULL)))
+ log(LOG_DEBUG, "%s; %s: Spurious ACK, "
+ "segment rejected "
+ "(syncookies disabled)\n",
+ s, __func__);
+ goto failed;
+ }
+ if (sch->sch_last_overflow <
+ time_uptime - SYNCOOKIE_LIFETIME) {
+ /*
+ * Since the bucket did not overflow recently,
+ * don't even check for a valid syncookie.
+ */
+ SCH_UNLOCK(sch);
+ TCPSTAT_INC(tcps_sc_spurcookie);
+ if ((s = tcp_log_addrs(inc, th, NULL, NULL)))
+ log(LOG_DEBUG, "%s; %s: Spurious ACK, "
+ "segment rejected "
+ "(no syncache entry)\n",
+ s, __func__);
+ goto failed;
+ }
SCH_UNLOCK(sch);
- TCPSTAT_INC(tcps_sc_spurcookie);
- if ((s = tcp_log_addrs(inc, th, NULL, NULL)))
- log(LOG_DEBUG, "%s; %s: Spurious ACK, "
- "segment rejected (no syncache entry)\n",
- s, __func__);
- goto failed;
}
- if (locked)
- SCH_UNLOCK(sch);
bzero(&scs, sizeof(scs));
+ /*
+ * Now check, if the syncookie is valid. If it is, create an on
+ * stack syncache entry.
+ */
if (syncookie_expand(inc, sch, &scs, th, to, *lsop, port)) {
sc = &scs;
TCPSTAT_INC(tcps_sc_recvcookie);
@@ -1291,10 +1298,9 @@ syncache_expand(struct in_conninfo *inc, struct tcpopt *to, struct tcphdr *th,
if (__predict_false(*lsop == NULL)) {
TCPSTAT_INC(tcps_sc_aborted);
TCPSTATES_DEC(TCPS_SYN_RECEIVED);
- } else
+ } else if (sc != &scs)
TCPSTAT_INC(tcps_sc_completed);
-/* how do we find the inp for the new socket? */
if (sc != &scs)
syncache_free(sc);
return (1);
@@ -1719,13 +1725,13 @@ syncache_add(struct in_conninfo *inc, struct tcpopt *to, struct tcphdr *th,
if (V_tcp_do_ecn && (tp->t_flags2 & TF2_CANNOT_DO_ECN) == 0)
sc->sc_flags |= tcp_ecn_syncache_add(tcp_get_flags(th), iptos);
- if (V_tcp_syncookies)
+ if (V_tcp_syncookies || V_tcp_syncookiesonly)
sc->sc_iss = syncookie_generate(sch, sc);
else
sc->sc_iss = arc4random();
#ifdef INET6
if (autoflowlabel) {
- if (V_tcp_syncookies)
+ if (V_tcp_syncookies || V_tcp_syncookiesonly)
sc->sc_flowlabel = sc->sc_iss;
else
sc->sc_flowlabel = ip6_randomflowlabel();
diff --git a/sys/netpfil/pf/if_pfsync.c b/sys/netpfil/pf/if_pfsync.c
index 585c196391c0..cfc300d99396 100644
--- a/sys/netpfil/pf/if_pfsync.c
+++ b/sys/netpfil/pf/if_pfsync.c
@@ -605,7 +605,8 @@ pfsync_state_import(union pfsync_state_union *sp, int flags, int msg_version)
rt_kif = rpool_first->kif;
/*
* Guess the AF of the route address, FreeBSD 13 does
- * not support af-to so it should be safe.
+ * not support af-to nor prefer-ipv6-nexthop
+ * so it should be safe.
*/
rt_af = r->af;
} else if (!PF_AZERO(&sp->pfs_1301.rt_addr, sp->pfs_1301.af)) {
@@ -634,8 +635,9 @@ pfsync_state_import(union pfsync_state_union *sp, int flags, int msg_version)
}
rt = sp->pfs_1400.rt;
/*
- * Guess the AF of the route address, FreeBSD 13 does
- * not support af-to so it should be safe.
+ * Guess the AF of the route address, FreeBSD 14 does
+ * not support af-to nor prefer-ipv6-nexthop
+ * so it should be safe.
*/
rt_af = sp->pfs_1400.af;
}
diff --git a/sys/netpfil/pf/pf.c b/sys/netpfil/pf/pf.c
index 8cd4fff95b15..4325835c7671 100644
--- a/sys/netpfil/pf/pf.c
+++ b/sys/netpfil/pf/pf.c
@@ -5960,7 +5960,9 @@ pf_test_rule(struct pf_krule **rm, struct pf_kstate **sm,
if (r->rt) {
/*
* Set act.rt here instead of in pf_rule_to_actions() because
- * it is applied only from the last pass rule.
+ * it is applied only from the last pass rule. For rules
+ * with the prefer-ipv6-nexthop option act.rt_af is a hint
+ * about AF of the forwarded packet and might be changed.
*/
pd->act.rt = r->rt;
if (r->rt == PF_REPLYTO)
@@ -8974,9 +8976,10 @@ pf_route(struct pf_krule *r, struct ifnet *oifp,
struct pf_kstate *s, struct pf_pdesc *pd, struct inpcb *inp)
{
struct mbuf *m0, *m1, *md;
- struct route ro;
- const struct sockaddr *gw = &ro.ro_dst;
- struct sockaddr_in *dst;
+ struct route_in6 ro;
+ union sockaddr_union rt_gw;
+ const union sockaddr_union *gw = (const union sockaddr_union *)&ro.ro_dst;
+ union sockaddr_union *dst;
struct ip *ip;
struct ifnet *ifp = NULL;
int error = 0;
@@ -9071,10 +9074,35 @@ pf_route(struct pf_krule *r, struct ifnet *oifp,
ip = mtod(m0, struct ip *);
bzero(&ro, sizeof(ro));
- dst = (struct sockaddr_in *)&ro.ro_dst;
- dst->sin_family = AF_INET;
- dst->sin_len = sizeof(struct sockaddr_in);
- dst->sin_addr.s_addr = pd->act.rt_addr.v4.s_addr;
+ dst = (union sockaddr_union *)&ro.ro_dst;
+ dst->sin.sin_family = AF_INET;
+ dst->sin.sin_len = sizeof(struct sockaddr_in);
+ dst->sin.sin_addr = ip->ip_dst;
+ if (ifp) { /* Only needed in forward direction and route-to */
+ bzero(&rt_gw, sizeof(rt_gw));
+ ro.ro_flags |= RT_HAS_GW;
+ gw = &rt_gw;
+ switch (pd->act.rt_af) {
+#ifdef INET
+ case AF_INET:
+ rt_gw.sin.sin_family = AF_INET;
+ rt_gw.sin.sin_len = sizeof(struct sockaddr_in);
+ rt_gw.sin.sin_addr.s_addr = pd->act.rt_addr.v4.s_addr;
+ break;
+#endif /* INET */
+#ifdef INET6
+ case AF_INET6:
+ rt_gw.sin6.sin6_family = AF_INET6;
+ rt_gw.sin6.sin6_len = sizeof(struct sockaddr_in6);
+ pf_addrcpy((struct pf_addr *)&rt_gw.sin6.sin6_addr,
+ &pd->act.rt_addr, AF_INET6);
+ break;
+#endif /* INET6 */
+ default:
+ /* Normal af-to without route-to */
+ break;
+ }
+ }
if (pd->dir == PF_IN) {
if (ip->ip_ttl <= IPTTLDEC) {
@@ -9098,10 +9126,10 @@ pf_route(struct pf_krule *r, struct ifnet *oifp,
/* Use the gateway if needed. */
if (nh->nh_flags & NHF_GATEWAY) {
- gw = &nh->gw_sa;
+ gw = (const union sockaddr_union *)&nh->gw_sa;
ro.ro_flags |= RT_HAS_GW;
} else {
- dst->sin_addr = ip->ip_dst;
+ dst->sin.sin_addr = ip->ip_dst;
}
/*
@@ -9126,6 +9154,9 @@ pf_route(struct pf_krule *r, struct ifnet *oifp,
PF_STATE_UNLOCK(s);
}
+ /* It must have been either set from rt_af or from fib4_lookup */
+ KASSERT(gw->sin.sin_family != 0, ("%s: gw address family undetermined", __func__));
+
if (ifp == NULL) {
m0 = pd->m;
pd->m = NULL;
@@ -9210,9 +9241,11 @@ pf_route(struct pf_krule *r, struct ifnet *oifp,
m_clrprotoflags(m0); /* Avoid confusing lower layers. */
md = m0;
- error = pf_dummynet_route(pd, s, r, ifp, gw, &md);
+ error = pf_dummynet_route(pd, s, r, ifp,
+ (const struct sockaddr *)gw, &md);
if (md != NULL) {
- error = (*ifp->if_output)(ifp, md, gw, &ro);
+ error = (*ifp->if_output)(ifp, md,
+ (const struct sockaddr *)gw, (struct route *)&ro);
SDT_PROBE2(pf, ip, route_to, output, ifp, error);
}
goto done;
@@ -9253,9 +9286,11 @@ pf_route(struct pf_krule *r, struct ifnet *oifp,
md = m0;
pd->pf_mtag = pf_find_mtag(md);
error = pf_dummynet_route(pd, s, r, ifp,
- gw, &md);
+ (const struct sockaddr *)gw, &md);
if (md != NULL) {
- error = (*ifp->if_output)(ifp, md, gw, &ro);
+ error = (*ifp->if_output)(ifp, md,
+ (const struct sockaddr *)gw,
+ (struct route *)&ro);
SDT_PROBE2(pf, ip, route_to, output, ifp, error);
}
} else
diff --git a/sys/netpfil/pf/pf.h b/sys/netpfil/pf/pf.h
index 51b3fd6390e1..8edd5a5110a1 100644
--- a/sys/netpfil/pf/pf.h
+++ b/sys/netpfil/pf/pf.h
@@ -131,6 +131,7 @@ enum { PF_ADDR_ADDRMASK, PF_ADDR_NOROUTE, PF_ADDR_DYNIFTL,
#define PF_POOL_TYPEMASK 0x0f
#define PF_POOL_STICKYADDR 0x20
#define PF_POOL_ENDPI 0x40
+#define PF_POOL_IPV6NH 0x80
#define PF_WSCALE_FLAG 0x80
#define PF_WSCALE_MASK 0x0f
diff --git a/sys/netpfil/pf/pf_ioctl.c b/sys/netpfil/pf/pf_ioctl.c
index e5da05a958f6..d395730d6a54 100644
--- a/sys/netpfil/pf/pf_ioctl.c
+++ b/sys/netpfil/pf/pf_ioctl.c
@@ -2276,6 +2276,7 @@ pf_ioctl_addrule(struct pf_krule *rule, uint32_t ticket,
rule->nat.cur = TAILQ_FIRST(&rule->nat.list);
rule->rdr.cur = TAILQ_FIRST(&rule->rdr.list);
rule->route.cur = TAILQ_FIRST(&rule->route.list);
+ rule->route.ipv6_nexthop_af = AF_INET6;
TAILQ_INSERT_TAIL(ruleset->rules[rs_num].inactive.ptr,
rule, entries);
ruleset->rules[rs_num].inactive.rcount++;
diff --git a/sys/netpfil/pf/pf_lb.c b/sys/netpfil/pf/pf_lb.c
index bc9e1dc72902..b8b5157c9b15 100644
--- a/sys/netpfil/pf/pf_lb.c
+++ b/sys/netpfil/pf/pf_lb.c
@@ -545,11 +545,18 @@ pf_map_addr(sa_family_t saf, struct pf_krule *r, struct pf_addr *saddr,
uint64_t hashidx;
int cnt;
sa_family_t wanted_af;
+ u_int8_t pool_type;
+ bool prefer_ipv6_nexthop = rpool->opts & PF_POOL_IPV6NH;
KASSERT(saf != 0, ("%s: saf == 0", __func__));
KASSERT(naf != NULL, ("%s: naf = NULL", __func__));
KASSERT((*naf) != 0, ("%s: *naf = 0", __func__));
+ /*
+ * Given (*naf) is a hint about AF of the forwarded packet.
+ * It might be changed if prefer_ipv6_nexthop is enabled and
+ * the combination of nexthop AF and packet AF allows for it.
+ */
wanted_af = (*naf);
mtx_lock(&rpool->mtx);
@@ -594,19 +601,38 @@ pf_map_addr(sa_family_t saf, struct pf_krule *r, struct pf_addr *saddr,
} else {
raddr = &rpool->cur->addr.v.a.addr;
rmask = &rpool->cur->addr.v.a.mask;
- /*
- * For single addresses check their address family. Unless they
- * have none, which happens when addresses are added with
- * the old ioctl mechanism. In such case trust that the address
- * has the proper AF.
- */
- if (rpool->cur->af && rpool->cur->af != wanted_af) {
- reason = PFRES_MAPFAILED;
- goto done_pool_mtx;
+ }
+
+ /*
+ * For pools with a single host with the prefer-ipv6-nexthop option
+ * we can return pool address of any AF, unless the forwarded packet
+ * is IPv6, then we can return only if pool address is IPv6.
+ * For non-prefer-ipv6-nexthop we can return pool address only
+ * of wanted AF, unless the pool address'es AF is unknown, which
+ * happens in case old ioctls have been used to set up the pool.
+ *
+ * Round-robin pools have their own logic for retrying next addresses.
+ */
+ pool_type = rpool->opts & PF_POOL_TYPEMASK;
+ if (pool_type == PF_POOL_NONE || pool_type == PF_POOL_BITMASK ||
+ ((pool_type == PF_POOL_RANDOM || pool_type == PF_POOL_SRCHASH) &&
+ rpool->cur->addr.type != PF_ADDR_TABLE &&
+ rpool->cur->addr.type != PF_ADDR_DYNIFTL)) {
+ if (prefer_ipv6_nexthop) {
+ if (rpool->cur->af == AF_INET && (*naf) == AF_INET6) {
+ reason = PFRES_MAPFAILED;
+ goto done_pool_mtx;
+ }
+ wanted_af = rpool->cur->af;
+ } else {
+ if (rpool->cur->af != 0 && rpool->cur->af != (*naf)) {
+ reason = PFRES_MAPFAILED;
+ goto done_pool_mtx;
+ }
}
}
- switch (rpool->opts & PF_POOL_TYPEMASK) {
+ switch (pool_type) {
case PF_POOL_NONE:
pf_addrcpy(naddr, raddr, wanted_af);
break;
@@ -631,10 +657,22 @@ pf_map_addr(sa_family_t saf, struct pf_krule *r, struct pf_addr *saddr,
else
rpool->tblidx = (int)arc4random_uniform(cnt);
memset(&rpool->counter, 0, sizeof(rpool->counter));
+ if (prefer_ipv6_nexthop)
+ wanted_af = AF_INET6;
+ retry_other_af_random:
if (pfr_pool_get(kt, &rpool->tblidx, &rpool->counter,
wanted_af, pf_islinklocal, false)) {
- reason = PFRES_MAPFAILED;
- goto done_pool_mtx; /* unsupported */
+ /* Retry with IPv4 nexthop for IPv4 traffic */
+ if (prefer_ipv6_nexthop &&
+ wanted_af == AF_INET6 &&
+ (*naf) == AF_INET) {
+ wanted_af = AF_INET;
+ goto retry_other_af_random;
+ } else {
+ /* no hosts in wanted AF */
+ reason = PFRES_MAPFAILED;
+ goto done_pool_mtx;
+ }
}
pf_addrcpy(naddr, &rpool->counter, wanted_af);
} else if (init_addr != NULL && PF_AZERO(init_addr,
@@ -702,10 +740,22 @@ pf_map_addr(sa_family_t saf, struct pf_krule *r, struct pf_addr *saddr,
else
rpool->tblidx = (int)(hashidx % cnt);
memset(&rpool->counter, 0, sizeof(rpool->counter));
+ if (prefer_ipv6_nexthop)
+ wanted_af = AF_INET6;
+ retry_other_af_srchash:
if (pfr_pool_get(kt, &rpool->tblidx, &rpool->counter,
wanted_af, pf_islinklocal, false)) {
- reason = PFRES_MAPFAILED;
- goto done_pool_mtx; /* unsupported */
+ /* Retry with IPv4 nexthop for IPv4 traffic */
+ if (prefer_ipv6_nexthop &&
+ wanted_af == AF_INET6 &&
+ (*naf) == AF_INET) {
+ wanted_af = AF_INET;
+ goto retry_other_af_srchash;
+ } else {
+ /* no hosts in wanted AF */
+ reason = PFRES_MAPFAILED;
+ goto done_pool_mtx;
+ }
}
pf_addrcpy(naddr, &rpool->counter, wanted_af);
} else {
@@ -718,6 +768,9 @@ pf_map_addr(sa_family_t saf, struct pf_krule *r, struct pf_addr *saddr,
{
struct pf_kpooladdr *acur = rpool->cur;
+ retry_other_af_rr:
+ if (prefer_ipv6_nexthop)
+ wanted_af = rpool->ipv6_nexthop_af;
if (rpool->cur->addr.type == PF_ADDR_TABLE) {
if (!pfr_pool_get(rpool->cur->addr.p.tbl,
&rpool->tblidx, &rpool->counter, wanted_af,
@@ -728,46 +781,55 @@ pf_map_addr(sa_family_t saf, struct pf_krule *r, struct pf_addr *saddr,
&rpool->tblidx, &rpool->counter, wanted_af,
pf_islinklocal, true))
goto get_addr;
- } else if (pf_match_addr(0, raddr, rmask, &rpool->counter,
- wanted_af))
+ } else if (rpool->cur->af == wanted_af &&
+ pf_match_addr(0, raddr, rmask, &rpool->counter, wanted_af))
goto get_addr;
-
+ if (prefer_ipv6_nexthop &&
+ (*naf) == AF_INET && wanted_af == AF_INET6) {
+ /* Reset table index when changing wanted AF. */
+ rpool->tblidx = -1;
+ rpool->ipv6_nexthop_af = AF_INET;
+ goto retry_other_af_rr;
+ }
try_next:
+ /* Reset prefer-ipv6-nexthop search to IPv6 when iterating pools. */
+ rpool->ipv6_nexthop_af = AF_INET6;
if (TAILQ_NEXT(rpool->cur, entries) == NULL)
rpool->cur = TAILQ_FIRST(&rpool->list);
else
rpool->cur = TAILQ_NEXT(rpool->cur, entries);
+ try_next_ipv6_nexthop_rr:
+ /* Reset table index when iterating pools or changing wanted AF. */
rpool->tblidx = -1;
+ if (prefer_ipv6_nexthop)
+ wanted_af = rpool->ipv6_nexthop_af;
if (rpool->cur->addr.type == PF_ADDR_TABLE) {
- if (pfr_pool_get(rpool->cur->addr.p.tbl,
+ if (!pfr_pool_get(rpool->cur->addr.p.tbl,
&rpool->tblidx, &rpool->counter, wanted_af, NULL,
- true)) {
- /* table contains no address of type 'wanted_af' */
- if (rpool->cur != acur)
- goto try_next;
- reason = PFRES_MAPFAILED;
- goto done_pool_mtx;
- }
+ true))
+ goto get_addr;
} else if (rpool->cur->addr.type == PF_ADDR_DYNIFTL) {
- if (pfr_pool_get(rpool->cur->addr.p.dyn->pfid_kt,
- &rpool->tblidx, &rpool->counter, wanted_af,
- pf_islinklocal, true)) {
- /* interface has no address of type 'wanted_af' */
- if (rpool->cur != acur)
- goto try_next;
- reason = PFRES_MAPFAILED;
- goto done_pool_mtx;
- }
+ if (!pfr_pool_get(rpool->cur->addr.p.dyn->pfid_kt,
+ &rpool->tblidx, &rpool->counter, wanted_af, pf_islinklocal,
+ true))
+ goto get_addr;
} else {
- raddr = &rpool->cur->addr.v.a.addr;
- rmask = &rpool->cur->addr.v.a.mask;
- if (rpool->cur->af && rpool->cur->af != wanted_af) {
- reason = PFRES_MAPFAILED;
- goto done_pool_mtx;
+ if (rpool->cur->af == wanted_af) {
+ raddr = &rpool->cur->addr.v.a.addr;
+ rmask = &rpool->cur->addr.v.a.mask;
+ pf_addrcpy(&rpool->counter, raddr, wanted_af);
+ goto get_addr;
}
- pf_addrcpy(&rpool->counter, raddr, wanted_af);
}
-
+ if (prefer_ipv6_nexthop &&
+ (*naf) == AF_INET && wanted_af == AF_INET6) {
+ rpool->ipv6_nexthop_af = AF_INET;
+ goto try_next_ipv6_nexthop_rr;
+ }
+ if (rpool->cur != acur)
+ goto try_next;
+ reason = PFRES_MAPFAILED;
+ goto done_pool_mtx;
get_addr:
pf_addrcpy(naddr, &rpool->counter, wanted_af);
if (init_addr != NULL && PF_AZERO(init_addr, wanted_af))
@@ -777,9 +839,16 @@ pf_map_addr(sa_family_t saf, struct pf_krule *r, struct pf_addr *saddr,
}
}
+ if (wanted_af == 0) {
+ reason = PFRES_MAPFAILED;
+ goto done_pool_mtx;
+ }
+
if (nkif)
*nkif = rpool->cur->kif;
+ (*naf) = wanted_af;
+
done_pool_mtx:
mtx_unlock(&rpool->mtx);
diff --git a/sys/sys/mount.h b/sys/sys/mount.h
index f6480b173a5c..18f85192f6c3 100644
--- a/sys/sys/mount.h
+++ b/sys/sys/mount.h
@@ -1007,6 +1007,7 @@ struct mntarg *mount_argsu(struct mntarg *ma, const char *name, const void *val,
void statfs_scale_blocks(struct statfs *sf, long max_size);
struct vfsconf *vfs_byname(const char *);
struct vfsconf *vfs_byname_kld(const char *, struct thread *td, int *);
+void vfs_unref_vfsconf(struct vfsconf *vfsp);
void vfs_mount_destroy(struct mount *);
void vfs_event_signal(fsid_t *, u_int32_t, intptr_t);
void vfs_freeopts(struct vfsoptlist *opts);
diff --git a/sys/vm/vm_extern.h b/sys/vm/vm_extern.h
index 93ec6014c27d..2b15a01206a2 100644
--- a/sys/vm/vm_extern.h
+++ b/sys/vm/vm_extern.h
@@ -91,6 +91,8 @@ void vm_fault_copy_entry(vm_map_t, vm_map_t, vm_map_entry_t, vm_map_entry_t,
vm_ooffset_t *);
int vm_fault_disable_pagefaults(void);
void vm_fault_enable_pagefaults(int save);
+int vm_fault_hold_pages_e(vm_map_t map, vm_offset_t addr, vm_size_t len,
+ vm_prot_t prot, vm_page_t *ma, int max_count, int *ppages_count);
int vm_fault_quick_hold_pages(vm_map_t map, vm_offset_t addr, vm_size_t len,
vm_prot_t prot, vm_page_t *ma, int max_count);
int vm_fault_trap(vm_map_t map, vm_offset_t vaddr, vm_prot_t fault_type,
diff --git a/sys/vm/vm_fault.c b/sys/vm/vm_fault.c
index 3e57e8d4f1d0..2a27f3e674a4 100644
--- a/sys/vm/vm_fault.c
+++ b/sys/vm/vm_fault.c
@@ -1995,32 +1995,43 @@ vm_fault_prefault(const struct faultstate *fs, vm_offset_t addra,
}
/*
- * Hold each of the physical pages that are mapped by the specified range of
- * virtual addresses, ["addr", "addr" + "len"), if those mappings are valid
- * and allow the specified types of access, "prot". If all of the implied
- * pages are successfully held, then the number of held pages is returned
- * together with pointers to those pages in the array "ma". However, if any
- * of the pages cannot be held, -1 is returned.
+ * Hold each of the physical pages that are mapped by the specified
+ * range of virtual addresses, ["addr", "addr" + "len"), if those
+ * mappings are valid and allow the specified types of access, "prot".
+ * If all of the implied pages are successfully held, then the number
+ * of held pages is assigned to *ppages_count, together with pointers
+ * to those pages in the array "ma". The returned value is zero.
+ *
+ * However, if any of the pages cannot be held, an error is returned,
+ * and no pages are held.
+ * Error values:
+ * ENOMEM - the range is not valid
+ * EINVAL - the provided vm_page array is too small to hold all pages
+ * EAGAIN - a page was not mapped, and the thread is in nofaulting mode
+ * EFAULT - a page with requested permissions cannot be mapped
+ * (more detailed result from vm_fault() is lost)
*/
int
-vm_fault_quick_hold_pages(vm_map_t map, vm_offset_t addr, vm_size_t len,
- vm_prot_t prot, vm_page_t *ma, int max_count)
+vm_fault_hold_pages_e(vm_map_t map, vm_offset_t addr, vm_size_t len,
+ vm_prot_t prot, vm_page_t *ma, int max_count, int *ppages_count)
{
vm_offset_t end, va;
vm_page_t *mp;
- int count;
+ int count, error;
boolean_t pmap_failed;
- if (len == 0)
+ if (len == 0) {
+ *ppages_count = 0;
return (0);
+ }
end = round_page(addr + len);
addr = trunc_page(addr);
if (!vm_map_range_valid(map, addr, end))
- return (-1);
+ return (ENOMEM);
if (atop(end - addr) > max_count)
- panic("vm_fault_quick_hold_pages: count > max_count");
+ return (EINVAL);
count = atop(end - addr);
/*
@@ -2062,19 +2073,49 @@ vm_fault_quick_hold_pages(vm_map_t map, vm_offset_t addr, vm_size_t len,
* the proper behaviour explicitly.
*/
if ((prot & VM_PROT_QUICK_NOFAULT) != 0 &&
- (curthread->td_pflags & TDP_NOFAULTING) != 0)
- goto error;
- for (mp = ma, va = addr; va < end; mp++, va += PAGE_SIZE)
+ (curthread->td_pflags & TDP_NOFAULTING) != 0) {
+ error = EAGAIN;
+ goto fail;
+ }
+ for (mp = ma, va = addr; va < end; mp++, va += PAGE_SIZE) {
if (*mp == NULL && vm_fault(map, va, prot,
- VM_FAULT_NORMAL, mp) != KERN_SUCCESS)
- goto error;
+ VM_FAULT_NORMAL, mp) != KERN_SUCCESS) {
+ error = EFAULT;
+ goto fail;
+ }
+ }
}
- return (count);
-error:
+ *ppages_count = count;
+ return (0);
+fail:
for (mp = ma; mp < ma + count; mp++)
if (*mp != NULL)
vm_page_unwire(*mp, PQ_INACTIVE);
- return (-1);
+ return (error);
+}
+
+ /*
+ * Hold each of the physical pages that are mapped by the specified range of
+ * virtual addresses, ["addr", "addr" + "len"), if those mappings are valid
+ * and allow the specified types of access, "prot". If all of the implied
+ * pages are successfully held, then the number of held pages is returned
+ * together with pointers to those pages in the array "ma". However, if any
+ * of the pages cannot be held, -1 is returned.
+ */
+int
+vm_fault_quick_hold_pages(vm_map_t map, vm_offset_t addr, vm_size_t len,
+ vm_prot_t prot, vm_page_t *ma, int max_count)
+{
+ int error, pages_count;
+
+ error = vm_fault_hold_pages_e(map, addr, len, prot, ma,
+ max_count, &pages_count);
+ if (error != 0) {
+ if (error == EINVAL)
+ panic("vm_fault_quick_hold_pages: count > max_count");
+ return (-1);
+ }
+ return (pages_count);
}
/*
diff --git a/tests/sys/netpfil/pf/route_to.sh b/tests/sys/netpfil/pf/route_to.sh
index 765403dcb79c..872de0dcbb91 100644
--- a/tests/sys/netpfil/pf/route_to.sh
+++ b/tests/sys/netpfil/pf/route_to.sh
@@ -28,6 +28,75 @@
common_dir=$(atf_get_srcdir)/../common
+# We need to somehow test if the random algorithm of pf_map_addr() is working.
+# The table or prefix contains multiple IP next-hop addresses, for each one try
+# to establish up to 10 connections. Fail the test if with this many attempts
+# the "good" target has not been chosen. However this choice is random,
+# the check might still ocasionally fail.
+check_random() {
+ if [ "$1" = "IPv4" ]; then
+ ping_from="${net_clients_4}.1"
+ ping_to="${host_server_4}"
+ else
+ ping_from="${net_clients_6}::1"
+ ping_to="${host_server_6}"
+ fi
+ good_targets="$2"
+ bad_targets="$3"
+
+ port=42000
+ states=$(mktemp) || exit 1
+ for good_target in $good_targets; do
+ found="no"
+ for attempt in $(seq 1 10); do
+ port=$(( port + 1 ))
+ jexec router pfctl -Fs
+ atf_check -s exit:0 ${common_dir}/pft_ping.py \
+ --sendif ${epair_tester}a --replyif ${epair_tester}a \
+ --fromaddr ${ping_from} --to ${ping_to} \
+ --ping-type=tcp3way --send-sport=${port}
+ jexec router pfctl -qvvss | normalize_pfctl_s > $states
+ cat $states
+ if [ -n "${bad_targets}" ]; then
+ for bad_target in $bad_targets; do
+ if grep -qE "route-to: ${bad_target}@" $states; then
+ atf_fail "Bad target ${bad_target} selected!"
+ fi
+ done
+ fi;
+ if grep -qE "route-to: ${good_target}@" $states; then
+ found=yes
+ break
+ fi
+ done
+ if [ "${found}" = "no" ]; then
+ atf_fail "Target ${good_target} not selected after ${attempt} attempts!"
+ fi
+ done
+}
+
+pf_map_addr_common()
+{
+ setup_router_server_nat64
+
+ # Clients will connect from another network behind the router.
+ # This allows for using multiple source addresses.
+ jexec router route add -6 ${net_clients_6}::/${net_clients_6_mask} ${net_tester_6_host_tester}
+ jexec router route add ${net_clients_4}.0/${net_clients_4_mask} ${net_tester_4_host_tester}
+
+ # The servers are reachable over additional IP addresses for
+ # testing of tables and subnets. The addresses are noncontinougnus
+ # for pf_map_addr() counter tests.
+ for i in 0 1 4 5; do
+ a1=$((24 + i))
+ jexec server1 ifconfig ${epair_server1}b inet ${net_server1_4}.${a1}/32 alias
+ jexec server1 ifconfig ${epair_server1}b inet6 ${net_server1_6}::42:${i}/128 alias
+ a2=$((40 + i))
+ jexec server2 ifconfig ${epair_server2}b inet ${net_server2_4}.${a2}/32 alias
+ jexec server2 ifconfig ${epair_server2}b inet6 ${net_server2_6}::42:${i}/128 alias
+ done
+}
+
atf_test_case "v4" "cleanup"
v4_head()
{
@@ -893,36 +962,17 @@ empty_pool_cleanup()
pft_cleanup
}
-
atf_test_case "table_loop" "cleanup"
table_loop_head()
{
atf_set descr 'Check that iterating over tables poperly loops'
atf_set require.user root
- atf_set require.progs python3 scapy
}
table_loop_body()
{
- setup_router_server_nat64
-
- # Clients will connect from another network behind the router.
- # This allows for using multiple source addresses.
- jexec router route add -6 ${net_clients_6}::/${net_clients_6_mask} ${net_tester_6_host_tester}
- jexec router route add ${net_clients_4}.0/${net_clients_4_mask} ${net_tester_4_host_tester}
-
- # The servers are reachable over additional IP addresses for
- # testing of tables and subnets. The addresses are noncontinougnus
- # for pf_map_addr() counter tests.
- for i in 0 1 4 5; do
- a1=$((24 + i))
- jexec server1 ifconfig ${epair_server1}b inet ${net_server1_4}.${a1}/32 alias
- jexec server1 ifconfig ${epair_server1}b inet6 ${net_server1_6}::42:${i}/128 alias
- a2=$((40 + i))
- jexec server2 ifconfig ${epair_server2}b inet ${net_server2_4}.${a2}/32 alias
- jexec server2 ifconfig ${epair_server2}b inet6 ${net_server2_6}::42:${i}/128 alias
- done
+ pf_map_addr_common
jexec router pfctl -e
pft_set_rules router \
@@ -976,6 +1026,612 @@ table_loop_cleanup()
}
+atf_test_case "roundrobin" "cleanup"
+
+roundrobin_head()
+{
+ atf_set descr 'multiple gateways of mixed AF, including prefixes and tables, for IPv6 packets'
+ atf_set require.user root
+}
+
+roundrobin_body()
+{
+ pf_map_addr_common
+
+ # The rule is defined as "inet6 proto tcp" so directly given IPv4 hosts
+ # will be removed from the pool by pfctl. Tables will still be loaded
+ # and pf_map_addr() will only use IPv6 addresses from them. It will
+ # iterate over members of the pool and inside of tables and prefixes.
+
+ jexec router pfctl -e
+ pft_set_rules router \
+ "set debug loud" \
+ "set reassemble yes" \
+ "set state-policy if-bound" \
+ "table <rt_targets> { ${net_server2_4}.40/31 ${net_server2_4}.44 ${net_server2_6}::42:0/127 ${net_server2_6}::42:4 }" \
+ "pass in on ${epair_tester}b \
+ route-to { \
+ (${epair_server1}a ${net_server1_4_host_server}) \
+ (${epair_server2}a <rt_targets_empty>) \
+ (${epair_server1}a ${net_server1_6}::42:0/127) \
+ (${epair_server2}a <rt_targets_empty>) \
+ (${epair_server2}a <rt_targets>) \
+ } \
+ inet6 proto tcp \
+ keep state"
+
+ for port in $(seq 1 6); do
+ port=$((4200 + port))
+ atf_check -s exit:0 ${common_dir}/pft_ping.py \
+ --sendif ${epair_tester}a --replyif ${epair_tester}a \
+ --fromaddr ${net_clients_6}::1 --to ${host_server_6} \
+ --ping-type=tcp3way --send-sport=${port}
+ done
+
+ states=$(mktemp) || exit 1
+ jexec router pfctl -qvvss | normalize_pfctl_s > $states
+
+ for state_regexp in \
+ "${epair_tester}b tcp ${host_server_6}\[9\] <- ${net_clients_6}::1\[4201\] .* route-to: ${net_server1_6}::42:0@${epair_server1}a" \
+ "${epair_tester}b tcp ${host_server_6}\[9\] <- ${net_clients_6}::1\[4202\] .* route-to: ${net_server1_6}::42:1@${epair_server1}a" \
+ "${epair_tester}b tcp ${host_server_6}\[9\] <- ${net_clients_6}::1\[4203\] .* route-to: ${net_server2_6}::42:0@${epair_server2}a" \
+ "${epair_tester}b tcp ${host_server_6}\[9\] <- ${net_clients_6}::1\[4204\] .* route-to: ${net_server2_6}::42:1@${epair_server2}a" \
+ "${epair_tester}b tcp ${host_server_6}\[9\] <- ${net_clients_6}::1\[4205\] .* route-to: ${net_server2_6}::42:4@${epair_server2}a" \
+ "${epair_tester}b tcp ${host_server_6}\[9\] <- ${net_clients_6}::1\[4206\] .* route-to: ${net_server1_6}::42:0@${epair_server1}a" \
+ ; do
+ grep -qE "${state_regexp}" $states || atf_fail "State not found for '${state_regexp}'"
+ done
+}
+
+roundrobin_cleanup()
+{
+ pft_cleanup
+}
+
+atf_test_case "random_table" "cleanup"
+
+random_table_head()
+{
+ atf_set descr 'Pool with random flag and a table for IPv6'
+ atf_set require.user root
+}
+
+random_table_body()
+{
+ pf_map_addr_common
+
+ # The "random" flag will pick random hosts from the table but will
+ # not dive into prefixes, always choosing the 0th address.
+ # Proper address family will be choosen.
+
+ jexec router pfctl -e
+ pft_set_rules router \
+ "set debug loud" \
+ "set reassemble yes" \
+ "set state-policy if-bound" \
+ "table <rt_targets> { ${net_server2_4}.40/31 ${net_server2_4}.44 ${net_server2_6}::42:0/127 ${net_server2_6}::42:4 }" \
+ "pass in on ${epair_tester}b \
+ route-to { (${epair_server2}a <rt_targets>) } random \
+ inet6 proto tcp \
+ keep state"
+
+ good_targets="${net_server2_6}::42:0 ${net_server2_6}::42:4"
+ bad_targets="${net_server2_6}::42:1"
+ check_random IPv6 "${good_targets}" "${bad_targets}"
+}
+
+random_table_cleanup()
+{
+ pft_cleanup
+}
+
+atf_test_case "random_prefix" "cleanup"
+
+random_prefix_head()
+{
+ atf_set descr 'Pool with random flag and a table for IPv4'
+ atf_set require.user root
+}
+
+random_prefix_body()
+{
+ pf_map_addr_common
+
+ # The "random" flag will pick random hosts from given prefix.
+ # The choice being random makes testing it non-trivial. We do 10
+ # attempts to have each target chosen. Hopefully this is enough to have
+ # this test pass often enough.
+
+ jexec router pfctl -e
+ pft_set_rules router \
+ "set debug loud" \
+ "set reassemble yes" \
+ "set state-policy if-bound" \
+ "pass in on ${epair_tester}b \
+ route-to { (${epair_server2}a ${net_server2_6}::42:0/127) } random \
+ inet6 proto tcp \
+ keep state"
+
+ good_targets="${net_server2_6}::42:0 ${net_server2_6}::42:1"
+ check_random IPv6 "${good_targets}"
+}
+
+random_prefix_cleanup()
+{
+ pft_cleanup
+}
+
+atf_test_case "prefer_ipv6_nexthop_single_ipv4" "cleanup"
+
+prefer_ipv6_nexthop_single_ipv4_head()
+{
+ atf_set descr 'prefer-ipv6-nexthop option for a single IPv4 gateway'
+ atf_set require.user root
+}
+
+prefer_ipv6_nexthop_single_ipv4_body()
+{
+ pf_map_addr_common
+
+ # Basic forwarding test for prefer-ipv6-nexthop pool option.
+ # A single IPv4 gateway will work only for IPv4 traffic.
+
+ jexec router pfctl -e
+ pft_set_rules router \
+ "set reassemble yes" \
+ "set state-policy if-bound" \
+ "pass in on ${epair_tester}b \
+ route-to (${epair_server1}a ${net_server1_4_host_server}) prefer-ipv6-nexthop \
+ proto tcp \
+ keep state"
+
+ atf_check -s exit:0 ${common_dir}/pft_ping.py \
+ --sendif ${epair_tester}a --replyif ${epair_tester}a \
+ --fromaddr ${net_clients_4}.1 --to ${host_server_4} \
+ --ping-type=tcp3way --send-sport=4201 \
+
+ atf_check -s exit:1 ${common_dir}/pft_ping.py \
+ --sendif ${epair_tester}a --replyif ${epair_tester}a \
+ --fromaddr ${net_clients_6}::1 --to ${host_server_6} \
+ --ping-type=tcp3way --send-sport=4202
+
+ states=$(mktemp) || exit 1
+ jexec router pfctl -qvvss | normalize_pfctl_s > $states
+
+ for state_regexp in \
+ "${epair_tester}b tcp ${host_server_4}:9 <- ${net_clients_4}.1:4201 .* route-to: ${net_server1_4_host_server}@${epair_server1}a" \
+ ; do
+ grep -qE "${state_regexp}" $states || atf_fail "State not found for '${state_regexp}'"
+ done
+
+ # The IPv6 packet could not have been routed over IPv4 gateway.
+ atf_check -o "match:map-failed +1 +" -x "jexec router pfctl -qvvsi 2> /dev/null"
+}
+
+prefer_ipv6_nexthop_single_ipv4_cleanup()
+{
+ pft_cleanup
+}
+
+atf_test_case "prefer_ipv6_nexthop_single_ipv6" "cleanup"
+
+prefer_ipv6_nexthop_single_ipv6_head()
+{
+ atf_set descr 'prefer-ipv6-nexthop option for a single IPv6 gateway'
+ atf_set require.user root
+}
+
+prefer_ipv6_nexthop_single_ipv6_body()
+{
+ pf_map_addr_common
+
+ # Basic forwarding test for prefer-ipv6-nexthop pool option.
+ # A single IPve gateway will work both for IPv4 and IPv6 traffic.
+
+ jexec router pfctl -e
+ pft_set_rules router \
+ "set reassemble yes" \
+ "set state-policy if-bound" \
+ "pass in on ${epair_tester}b \
+ route-to (${epair_server1}a ${net_server1_6_host_server}) prefer-ipv6-nexthop \
+ proto tcp \
+ keep state"
+
+ atf_check -s exit:0 ${common_dir}/pft_ping.py \
+ --sendif ${epair_tester}a --replyif ${epair_tester}a \
+ --fromaddr ${net_clients_4}.1 --to ${host_server_4} \
+ --ping-type=tcp3way --send-sport=4201 \
+
+ atf_check -s exit:0 ${common_dir}/pft_ping.py \
+ --sendif ${epair_tester}a --replyif ${epair_tester}a \
+ --fromaddr ${net_clients_6}::1 --to ${host_server_6} \
+ --ping-type=tcp3way --send-sport=4202
+
+ states=$(mktemp) || exit 1
+ jexec router pfctl -qvvss | normalize_pfctl_s > $states
+
+ for state_regexp in \
+ "${epair_tester}b tcp ${host_server_4}:9 <- ${net_clients_4}.1:4201 .* route-to: ${net_server1_6_host_server}@${epair_server1}a" \
+ "${epair_tester}b tcp ${host_server_6}\[9\] <- ${net_clients_6}::1\[4202\] .* route-to: ${net_server1_6_host_server}@${epair_server1}a" \
+ ; do
+ grep -qE "${state_regexp}" $states || atf_fail "State not found for '${state_regexp}'"
+ done
+}
+
+prefer_ipv6_nexthop_single_ipv6_cleanup()
+{
+ pft_cleanup
+}
+
+atf_test_case "prefer_ipv6_nexthop_mixed_af_roundrobin_ipv4" "cleanup"
+
+prefer_ipv6_nexthop_mixed_af_roundrobin_ipv4_head()
+{
+ atf_set descr 'prefer-ipv6-nexthop option for multiple gateways of mixed AF with prefixes and tables, round robin selection, for IPv4 packets'
+ atf_set require.user root
+}
+
+prefer_ipv6_nexthop_mixed_af_roundrobin_ipv4_body()
+{
+ pf_map_addr_common
+
+ # pf_map_addr() starts iterating over hosts of the pool from the 2nd
+ # host. This behaviour was here before adding prefer-ipv6-nexthop
+ # support, we test for it. Some targets are hosts and some are tables.
+ # Those are iterated too. Finally the iteration loops back
+ # to the beginning of the pool. Send out IPv4 probes. They will use all
+ # IPv4 and IPv6 addresses from the pool.
+
+ jexec router pfctl -e
+ pft_set_rules router \
+ "set reassemble yes" \
+ "set state-policy if-bound" \
+ "table <rt_targets> { ${net_server2_4}.40/31 ${net_server2_4}.44 ${net_server2_6}::42:4/127 }" \
+ "pass in on ${epair_tester}b \
+ route-to { \
+ (${epair_server1}a ${net_server1_6_host_server}) \
+ (${epair_server1}a ${net_server1_6}::42:0/127) \
+ (${epair_server2}a ${net_server2_4_host_server}) \
+ (${epair_server2}a <rt_targets_empty>) \
+ (${epair_server1}a ${net_server1_4}.24/31) \
+ (${epair_server2}a <rt_targets>) \
+ } prefer-ipv6-nexthop \
+ proto tcp \
+ keep state"
+
+ for port in $(seq 1 12); do
+ port=$((4200 + port))
+ atf_check -s exit:0 ${common_dir}/pft_ping.py \
+ --sendif ${epair_tester}a --replyif ${epair_tester}a \
+ --fromaddr ${net_clients_4}.1 --to ${host_server_4} \
+ --ping-type=tcp3way --send-sport=${port}
+ done
+
+ states=$(mktemp) || exit 1
+ jexec router pfctl -qvvss | normalize_pfctl_s > $states
+
+ for state_regexp in \
+ "${epair_tester}b tcp ${host_server_4}:9 <- ${net_clients_4}.1:4201 .* route-to: ${net_server1_6}::42:0@${epair_server1}a" \
+ "${epair_tester}b tcp ${host_server_4}:9 <- ${net_clients_4}.1:4202 .* route-to: ${net_server1_6}::42:1@${epair_server1}a" \
+ "${epair_tester}b tcp ${host_server_4}:9 <- ${net_clients_4}.1:4203 .* route-to: ${net_server2_4_host_server}@${epair_server2}a" \
+ "${epair_tester}b tcp ${host_server_4}:9 <- ${net_clients_4}.1:4204 .* route-to: ${net_server1_4}.24@${epair_server1}a" \
+ "${epair_tester}b tcp ${host_server_4}:9 <- ${net_clients_4}.1:4205 .* route-to: ${net_server1_4}.25@${epair_server1}a" \
+ "${epair_tester}b tcp ${host_server_4}:9 <- ${net_clients_4}.1:4206 .* route-to: ${net_server2_6}::42:4@${epair_server2}a" \
+ "${epair_tester}b tcp ${host_server_4}:9 <- ${net_clients_4}.1:4207 .* route-to: ${net_server2_6}::42:5@${epair_server2}a" \
+ "${epair_tester}b tcp ${host_server_4}:9 <- ${net_clients_4}.1:4208 .* route-to: ${net_server2_4}.40@${epair_server2}a" \
+ "${epair_tester}b tcp ${host_server_4}:9 <- ${net_clients_4}.1:4209 .* route-to: ${net_server2_4}.41@${epair_server2}a" \
+ "${epair_tester}b tcp ${host_server_4}:9 <- ${net_clients_4}.1:4210 .* route-to: ${net_server2_4}.44@${epair_server2}a" \
+ "${epair_tester}b tcp ${host_server_4}:9 <- ${net_clients_4}.1:4211 .* route-to: ${net_server1_6_host_server}@${epair_server1}a" \
+ "${epair_tester}b tcp ${host_server_4}:9 <- ${net_clients_4}.1:4212 .* route-to: ${net_server1_6}::42:0@${epair_server1}a" \
+ ; do
+ grep -qE "${state_regexp}" $states || atf_fail "State not found for '${state_regexp}'"
+ done
+}
+
+prefer_ipv6_nexthop_mixed_af_roundrobin_ipv4_cleanup()
+{
+ pft_cleanup
+}
+
+prefer_ipv6_nexthop_mixed_af_roundrobin_ipv6_head()
+{
+ atf_set descr 'prefer-ipv6-nexthop option for multiple gateways of mixed AF with prefixes and tables, round-robin selection, for IPv6 packets'
+ atf_set require.user root
+}
+
+prefer_ipv6_nexthop_mixed_af_roundrobin_ipv6_body()
+{
+ pf_map_addr_common
+
+ # The "random" flag will pick random hosts from the table but will
+ # not dive into prefixes, always choosing the 0th address.
+ # Proper address family will be choosen. The choice being random makes
+ # testing it non-trivial. We do 10 attempts to have each target chosen.
+ # Hopefully this is enough to have this test pass often enough.
+
+ # pf_map_addr() starts iterating over hosts of the pool from the 2nd
+ # host. This behaviour was here before adding prefer-ipv6-nexthop
+ # support, we test for it. Some targets are hosts and some are tables.
+ # Those are iterated too. Finally the iteration loops back
+ # to the beginning of the pool. Send out IPv6 probes. They will use only
+ # IPv6 addresses from the pool.
+
+ jexec router pfctl -e
+ pft_set_rules router \
+ "set reassemble yes" \
+ "set state-policy if-bound" \
+ "table <rt_targets> { ${net_server2_4}.40/31 ${net_server2_4}.44 ${net_server2_6}::42:4/127 }" \
+ "pass in on ${epair_tester}b \
+ route-to { \
+ (${epair_server1}a ${net_server1_6_host_server}) \
+ (${epair_server1}a ${net_server1_6}::42:0/127) \
+ (${epair_server2}a ${net_server2_4_host_server}) \
+ (${epair_server2}a <rt_targets_empty>) \
+ (${epair_server1}a ${net_server1_4}.24/31) \
+ (${epair_server2}a <rt_targets>) \
+ } prefer-ipv6-nexthop \
+ proto tcp \
+ keep state"
+
+ for port in $(seq 1 6); do
+ port=$((4200 + port))
+ atf_check -s exit:0 ${common_dir}/pft_ping.py \
+ --sendif ${epair_tester}a --replyif ${epair_tester}a \
+ --fromaddr ${net_clients_6}::1 --to ${host_server_6} \
+ --ping-type=tcp3way --send-sport=${port}
+ done
+
+ states=$(mktemp) || exit 1
+ jexec router pfctl -qvvss | normalize_pfctl_s > $states
+
+ for state_regexp in \
+ "${epair_tester}b tcp ${host_server_6}\[9\] <- ${net_clients_6}::1\[4201\] .* route-to: ${net_server1_6}::42:0@${epair_server1}a" \
+ "${epair_tester}b tcp ${host_server_6}\[9\] <- ${net_clients_6}::1\[4202\] .* route-to: ${net_server1_6}::42:1@${epair_server1}a" \
+ "${epair_tester}b tcp ${host_server_6}\[9\] <- ${net_clients_6}::1\[4203\] .* route-to: ${net_server2_6}::42:4@${epair_server2}a" \
+ "${epair_tester}b tcp ${host_server_6}\[9\] <- ${net_clients_6}::1\[4204\] .* route-to: ${net_server2_6}::42:5@${epair_server2}a" \
+ "${epair_tester}b tcp ${host_server_6}\[9\] <- ${net_clients_6}::1\[4205\] .* route-to: ${net_server1_6_host_server}@${epair_server1}a" \
+ "${epair_tester}b tcp ${host_server_6}\[9\] <- ${net_clients_6}::1\[4206\] .* route-to: ${net_server1_6}::42:0@${epair_server1}a" \
+ ; do
+ grep -qE "${state_regexp}" $states || atf_fail "State not found for '${state_regexp}'"
+ done
+}
+
+prefer_ipv6_nexthop_mixed_af_roundrobin_ipv6_cleanup()
+{
+ pft_cleanup
+}
+
+atf_test_case "prefer_ipv6_nexthop_mixed_af_random_ipv4" "cleanup"
+
+prefer_ipv6_nexthop_mixed_af_random_table_ipv4_head()
+{
+ atf_set descr 'prefer-ipv6-nexthop option for a mixed-af table with random selection for IPv4 packets'
+ atf_set require.user root
+}
+
+prefer_ipv6_nexthop_mixed_af_random_table_ipv4_body()
+{
+ pf_map_addr_common
+
+ # Similarly to the test "random_table" the algorithm will choose
+ # IP addresses from the table not diving into prefixes.
+ # *prefer*-ipv6-nexthop means that IPv6 nexthops are preferred,
+ # so IPv4 ones will not be chosen as long as there are IPv6 ones
+ # available. With this tested there is no need for a test for IPv6-only
+ # next-hops table.
+
+ jexec router pfctl -e
+ pft_set_rules router \
+ "set reassemble yes" \
+ "set state-policy if-bound" \
+ "table <rt_targets> { ${net_server2_4}.40/31 ${net_server2_4}.44 ${net_server2_6}::42:0/127 ${net_server2_6}::42:4 }" \
+ "pass in on ${epair_tester}b \
+ route-to { (${epair_server2}a <rt_targets>) } random prefer-ipv6-nexthop \
+ proto tcp \
+ keep state"
+
+ good_targets="${net_server2_6}::42:0 ${net_server2_6}::42:4"
+ bad_targets="${net_server2_4}.40 ${net_server2_4}.41 ${net_server2_4}.44 ${net_server2_6}::42:1"
+ check_random IPv4 "${good_targets}" "${bad_targets}"
+}
+
+prefer_ipv6_nexthop_mixed_af_random_table_ipv4_cleanup()
+{
+ pft_cleanup
+}
+
+prefer_ipv6_nexthop_ipv4_random_table_ipv4_head()
+{
+ atf_set descr 'prefer-ipv6-nexthop option for an IPv4-only table with random selection for IPv4 packets'
+ atf_set require.user root
+}
+
+prefer_ipv6_nexthop_ipv4_random_table_ipv4_body()
+{
+ pf_map_addr_common
+
+ # Similarly to the test pf_map_addr:random_table the algorithm will
+ # choose IP addresses from the table not diving into prefixes.
+ # There are no IPv6 nexthops in the table, so the algorithm will
+ # fall back to IPv4.
+
+ jexec router pfctl -e
+ pft_set_rules router \
+ "set reassemble yes" \
+ "set state-policy if-bound" \
+ "table <rt_targets> { ${net_server2_4}.40/31 ${net_server2_4}.44 }" \
+ "pass in on ${epair_tester}b \
+ route-to { (${epair_server2}a <rt_targets>) } random prefer-ipv6-nexthop \
+ proto tcp \
+ keep state"
+
+ good_targets="${net_server2_4}.40 ${net_server2_4}.44"
+ bad_targets="${net_server2_4}.41"
+ check_random IPv4 "${good_targets}" "${bad_targets}"
+}
+
+prefer_ipv6_nexthop_ipv4_random_table_ipv4_cleanup()
+{
+ pft_cleanup
+}
+
+prefer_ipv6_nexthop_ipv4_random_table_ipv6_head()
+{
+ atf_set descr 'prefer-ipv6-nexthop option for an IPv4-only table with random selection for IPv6 packets'
+ atf_set require.user root
+}
+
+prefer_ipv6_nexthop_ipv4_random_table_ipv6_body()
+{
+ pf_map_addr_common
+
+ # IPv6 packets can't be forwarded over IPv4 next-hops.
+ # The failure happens in pf_map_addr() and increases the respective
+ # error counter.
+
+ jexec router pfctl -e
+ pft_set_rules router \
+ "set reassemble yes" \
+ "set state-policy if-bound" \
+ "table <rt_targets> { ${net_server2_4}.40/31 ${net_server2_4}.44 }" \
+ "pass in on ${epair_tester}b \
+ route-to { (${epair_server2}a <rt_targets>) } random prefer-ipv6-nexthop \
+ proto tcp \
+ keep state"
+
+ atf_check -s exit:1 ${common_dir}/pft_ping.py \
+ --sendif ${epair_tester}a --replyif ${epair_tester}a \
+ --fromaddr ${net_clients_6}::1 --to ${host_server_6} \
+ --ping-type=tcp3way --send-sport=4201
+
+ atf_check -o "match:map-failed +1 +" -x "jexec router pfctl -qvvsi 2> /dev/null"
+}
+
+prefer_ipv6_nexthop_ipv4_random_table_ipv6_cleanup()
+{
+ pft_cleanup
+}
+
+prefer_ipv6_nexthop_ipv6_random_prefix_ipv4_head()
+{
+ atf_set descr 'prefer-ipv6-nexthop option for an IPv6 prefix with random selection for IPv4 packets'
+ atf_set require.user root
+}
+
+prefer_ipv6_nexthop_ipv6_random_prefix_ipv4_body()
+{
+ pf_map_addr_common
+
+ jexec router pfctl -e
+ pft_set_rules router \
+ "set reassemble yes" \
+ "set state-policy if-bound" \
+ "pass in on ${epair_tester}b \
+ route-to { (${epair_server2}a ${net_server2_6}::42:0/127) } random prefer-ipv6-nexthop \
+ proto tcp \
+ keep state"
+
+ good_targets="${net_server2_6}::42:0 ${net_server2_6}::42:1"
+ check_random IPv4 "${good_targets}"
+}
+
+prefer_ipv6_nexthop_ipv6_random_prefix_ipv4_cleanup()
+{
+ pft_cleanup
+}
+
+prefer_ipv6_nexthop_ipv6_random_prefix_ipv6_head()
+{
+ atf_set descr 'prefer-ipv6-nexthop option for an IPv6 prefix with random selection for IPv6 packets'
+ atf_set require.user root
+}
+
+prefer_ipv6_nexthop_ipv6_random_prefix_ipv6_body()
+{
+ pf_map_addr_common
+
+ jexec router pfctl -e
+ pft_set_rules router \
+ "set reassemble yes" \
+ "set state-policy if-bound" \
+ "pass in on ${epair_tester}b \
+ route-to { (${epair_server2}a ${net_server2_6}::42:0/127) } random prefer-ipv6-nexthop \
+ proto tcp \
+ keep state"
+
+ good_targets="${net_server2_6}::42:0 ${net_server2_6}::42:1"
+ check_random IPv6 "${good_targets}"
+}
+
+prefer_ipv6_nexthop_ipv6_random_prefix_ipv6_cleanup()
+{
+ pft_cleanup
+}
+
+prefer_ipv6_nexthop_ipv4_random_prefix_ipv4_head()
+{
+ atf_set descr 'prefer-ipv6-nexthop option for an IPv4 prefix with random selection for IPv4 packets'
+ atf_set require.user root
+}
+
+prefer_ipv6_nexthop_ipv4_random_prefix_ipv4_body()
+{
+ pf_map_addr_common
+
+ jexec router pfctl -e
+ pft_set_rules router \
+ "set reassemble yes" \
+ "set state-policy if-bound" \
+ "pass in on ${epair_tester}b \
+ route-to { (${epair_server2}a ${net_server2_4}.40/31) } random prefer-ipv6-nexthop \
+ proto tcp \
+ keep state"
+
+ good_targets="${net_server2_4}.40 ${net_server2_4}.41"
+ check_random IPv4 "${good_targets}"
+}
+
+prefer_ipv6_nexthop_ipv4_random_prefix_ipv4_cleanup()
+{
+ pft_cleanup
+}
+
+prefer_ipv6_nexthop_ipv4_random_prefix_ipv6_head()
+{
+ atf_set descr 'prefer-ipv6-nexthop option for an IPv4 prefix with random selection for IPv6 packets'
+ atf_set require.user root
+}
+
+prefer_ipv6_nexthop_ipv4_random_prefix_ipv6_body()
+{
+ pf_map_addr_common
+
+ # IPv6 packets can't be forwarded over IPv4 next-hops.
+ # The failure happens in pf_map_addr() and increases the respective
+ # error counter.
+
+ jexec router pfctl -e
+ pft_set_rules router \
+ "set reassemble yes" \
+ "set state-policy if-bound" \
+ "pass in on ${epair_tester}b \
+ route-to { (${epair_server2}a ${net_server2_4}.40/31) } random prefer-ipv6-nexthop \
+ proto tcp \
+ keep state"
+
+ atf_check -s exit:1 ${common_dir}/pft_ping.py \
+ --sendif ${epair_tester}a --replyif ${epair_tester}a \
+ --fromaddr ${net_clients_6}::1 --to ${host_server_6} \
+ --ping-type=tcp3way --send-sport=4201
+
+ atf_check -o "match:map-failed +1 +" -x "jexec router pfctl -qvvsi 2> /dev/null"
+}
+
+prefer_ipv6_nexthop_ipv4_random_prefix_ipv6_cleanup()
+{
+ pft_cleanup
+}
+
atf_init_test_cases()
{
atf_add_test_case "v4"
@@ -995,5 +1651,25 @@ atf_init_test_cases()
atf_add_test_case "sticky"
atf_add_test_case "ttl"
atf_add_test_case "empty_pool"
+ # Tests for pf_map_addr() without prefer-ipv6-nexthop
atf_add_test_case "table_loop"
+ atf_add_test_case "roundrobin"
+ atf_add_test_case "random_table"
+ atf_add_test_case "random_prefix"
+ # Tests for pf_map_addr() without prefer-ipv6-nexthop
+ # Next hop is a Single IP address
+ atf_add_test_case "prefer_ipv6_nexthop_single_ipv4"
+ atf_add_test_case "prefer_ipv6_nexthop_single_ipv6"
+ # Next hop is tables and prefixes, accessed by the round-robin algorithm
+ atf_add_test_case "prefer_ipv6_nexthop_mixed_af_roundrobin_ipv4"
+ atf_add_test_case "prefer_ipv6_nexthop_mixed_af_roundrobin_ipv6"
+ # Next hop is a table, accessed by the random algorithm
+ atf_add_test_case "prefer_ipv6_nexthop_mixed_af_random_table_ipv4"
+ atf_add_test_case "prefer_ipv6_nexthop_ipv4_random_table_ipv4"
+ atf_add_test_case "prefer_ipv6_nexthop_ipv4_random_table_ipv6"
+ # Next hop is a prefix, accessed by the random algorithm
+ atf_add_test_case "prefer_ipv6_nexthop_ipv6_random_prefix_ipv4"
+ atf_add_test_case "prefer_ipv6_nexthop_ipv6_random_prefix_ipv6"
+ atf_add_test_case "prefer_ipv6_nexthop_ipv4_random_prefix_ipv4"
+ atf_add_test_case "prefer_ipv6_nexthop_ipv4_random_prefix_ipv6"
}
diff --git a/tests/sys/netpfil/pf/src_track.sh b/tests/sys/netpfil/pf/src_track.sh
index ae60a5df809b..e12d0464ee8c 100755
--- a/tests/sys/netpfil/pf/src_track.sh
+++ b/tests/sys/netpfil/pf/src_track.sh
@@ -526,10 +526,12 @@ mixed_af_body()
"block" \
"pass inet6 proto icmp6 icmp6-type { neighbrsol, neighbradv }" \
"pass in on ${epair_tester}b \
- route-to { (${epair_server1}a ${net_server1_4_host_server}) \
- } sticky-address \
- inet6 proto tcp from any to 64:ff9b::/96 \
- af-to inet from ${net_clients_4}.0/${net_clients_4_mask} round-robin sticky-address"
+ route-to { \
+ (${epair_server1}a ${net_server1_4_host_server}) \
+ (${epair_server2}a ${net_server2_6_host_server}) \
+ } prefer-ipv6-nexthop sticky-address \
+ inet6 proto tcp from any to 64:ff9b::/96 \
+ af-to inet from ${net_clients_4}.0/${net_clients_4_mask} round-robin sticky-address"
atf_check -s exit:0 ${common_dir}/pft_ping.py \
--sendif ${epair_tester}a \
@@ -538,6 +540,20 @@ mixed_af_body()
--to 64:ff9b::192.0.2.100 \
--ping-type=tcp3way \
--send-sport=4201
+ atf_check -s exit:0 ${common_dir}/pft_ping.py \
+ --sendif ${epair_tester}a \
+ --replyif ${epair_tester}a \
+ --fromaddr 2001:db8:44::1 \
+ --to 64:ff9b::192.0.2.100 \
+ --ping-type=tcp3way \
+ --send-sport=4202
+ atf_check -s exit:0 ${common_dir}/pft_ping.py \
+ --sendif ${epair_tester}a \
+ --replyif ${epair_tester}a \
+ --fromaddr 2001:db8:44::2 \
+ --to 64:ff9b::192.0.2.100 \
+ --ping-type=tcp3way \
+ --send-sport=4203
states=$(mktemp) || exit 1
jexec router pfctl -qvvss | normalize_pfctl_s > $states
@@ -546,16 +562,22 @@ mixed_af_body()
# States are checked for proper route-to information.
# The route-to gateway is IPv4.
+ # FIXME: Sticky-address is broken for af-to pools!
+ # The SN is created but apparently not used, as seen in states.
for state_regexp in \
- "${epair_tester}b tcp 203.0.113.0:4201 \(2001:db8:44::1\[4201\]\) -> 192.0.2.100:9 \(64:ff9b::c000:264\[9\]\) .* route-to: 198.51.100.18@${epair_server1}a" \
+ "${epair_tester}b tcp 203.0.113.0:4201 \(2001:db8:44::1\[4201\]\) -> 192.0.2.100:9 \(64:ff9b::c000:264\[9\]\) .* route-to: 2001:db8:4202::2@${epair_server2}a" \
+ "${epair_tester}b tcp 203.0.113.1:4202 \(2001:db8:44::1\[4202\]\) -> 192.0.2.100:9 \(64:ff9b::c000:264\[9\]\) .* route-to: 2001:db8:4202::2@${epair_server2}a" \
+ "${epair_tester}b tcp 203.0.113.2:4203 \(2001:db8:44::2\[4203\]\) -> 192.0.2.100:9 \(64:ff9b::c000:264\[9\]\) .* route-to: 198.51.100.18@${epair_server1}a" \
; do
grep -qE "${state_regexp}" $states || atf_fail "State not found for '${state_regexp}'"
done
# Source nodes map IPv6 source address onto IPv4 gateway and IPv4 SNAT address.
for node_regexp in \
- '2001:db8:44::1 -> 203.0.113.0 .* states 1, .* NAT/RDR sticky-address' \
- '2001:db8:44::1 -> 198.51.100.18 .* states 1, .* route sticky-address' \
+ '2001:db8:44::2 -> 203.0.113.2 .* states 1, .* NAT/RDR sticky-address' \
+ '2001:db8:44::2 -> 198.51.100.18 .* states 1, .* route sticky-address' \
+ '2001:db8:44::1 -> 203.0.113.0 .* states 2, .* NAT/RDR sticky-address' \
+ '2001:db8:44::1 -> 2001:db8:4202::2 .* states 2, .* route sticky-address' \
; do
grep -qE "${node_regexp}" $nodes || atf_fail "Source node not found for '${node_regexp}'"
done
diff --git a/tests/sys/netpfil/pf/utils.subr b/tests/sys/netpfil/pf/utils.subr
index 3f8d437920f9..a48f26653f8c 100644
--- a/tests/sys/netpfil/pf/utils.subr
+++ b/tests/sys/netpfil/pf/utils.subr
@@ -274,8 +274,8 @@ setup_router_server_ipv6()
jexec server inetd -p ${PWD}/inetd.pid $inetd_conf
}
-# Create a router and 2 server jails for nat64 and rfc5549 test cases.
-# The router is connected to servers, both are dual-stack, and to the
+# Create a router and 2 server jails for nat64 and prefer-ipv6-nexthop test
+# cases. The router is connected to servers, both are dual-stack, and to the
# tester jail. All links are dual stack.
setup_router_server_nat64()
{
diff --git a/tools/build/mk/OptionalObsoleteFiles.inc b/tools/build/mk/OptionalObsoleteFiles.inc
index fe92cf671ebc..5eea402c4526 100644
--- a/tools/build/mk/OptionalObsoleteFiles.inc
+++ b/tools/build/mk/OptionalObsoleteFiles.inc
@@ -2850,7 +2850,6 @@ OLD_FILES+=usr/lib/libroken.a
OLD_FILES+=usr/lib/libroken.so
OLD_FILES+=usr/lib/libwind.a
OLD_FILES+=usr/lib/libwind.so
-OLD_FILES+=usr/lib/libwind.so.11
OLD_FILES+=usr/libexec/digest-service
OLD_FILES+=usr/libexec/hprop
OLD_FILES+=usr/libexec/hpropd
@@ -3633,6 +3632,7 @@ OLD_LIBS+=usr/lib/libkrb5.so.11
OLD_LIBS+=usr/lib/libprivateheimipcc.so.11
OLD_LIBS+=usr/lib/libprivateheimipcs.so.11
OLD_LIBS+=usr/lib/libroken.so.11
+OLD_LIBS+=usr/lib/libwind.so.11
.endif # ${MK_KERBEROS} == "no" || ${MK_MITKRB5} != "no"
# MIT-specific files that don't exist in Heimdal. These should be removed if
diff --git a/tools/tools/sysbuild/sysbuild.sh b/tools/tools/sysbuild/sysbuild.sh
index 7c3e21c98736..2b3edc9a45ae 100644
--- a/tools/tools/sysbuild/sysbuild.sh
+++ b/tools/tools/sysbuild/sysbuild.sh
@@ -600,7 +600,7 @@ fi
if [ -f /etc/localtime ] ; then
log_it copy localtime
- cp /etc/localtime ${SBMNT}/etc
+ cp -P /etc/localtime ${SBMNT}/etc
if [ -f /var/db/zoneinfo ] ; then
log_it copy zoneinfo
cp /var/db/zoneinfo ${SBMNT}/var/db
diff --git a/usr.bin/patch/pch.c b/usr.bin/patch/pch.c
index 71f73125a8cb..9bc4599026ae 100644
--- a/usr.bin/patch/pch.c
+++ b/usr.bin/patch/pch.c
@@ -1054,7 +1054,7 @@ hunk_done:
p_end = fillnew;
malformed();
}
- if (ch != ' ' && context > 0) {
+ if (ch != ' ' && context >= 0) {
if (context < p_context)
p_context = context;
context = -1000;
diff --git a/usr.bin/patch/tests/unified_patch_test.sh b/usr.bin/patch/tests/unified_patch_test.sh
index 7d4b74182c41..a4b46ef34221 100755
--- a/usr.bin/patch/tests/unified_patch_test.sh
+++ b/usr.bin/patch/tests/unified_patch_test.sh
@@ -25,6 +25,26 @@
# SUCH DAMAGE.
#
+atf_test_case badfuzz
+badfuzz_head()
+{
+ atf_set "descr" "Test for patch(1) erroneously fuzzing away action lines"
+}
+badfuzz_body()
+{
+ # PR 250511 demonstrates a scenario where patch(1) will happily apply a
+ # patch into the wrong location if we have some lines that are still
+ # similar in the trailing context. In the following example, it would
+ # actually replace the underscore before the second series of B\nC\nO
+ # with "Z", when the patch should have been rejected instead.
+ printf "A\nB\nC\nO\n_\nB\nC\nO\n" > file.orig
+ printf "Z\nB\nC\nO\n_\nB\nC\nO\n" > file
+ printf "OK\nDIFF1\nDIFF2\n\n_\nB\nC\nO\n" > file.newer
+
+ atf_check -s not-exit:0 -o save:file.patch diff -u3 file.orig file
+ atf_check -s not-exit:0 -o not-empty patch file.newer file.patch
+}
+
atf_test_case basic
basic_body()
{
@@ -141,6 +161,23 @@ file_removal_body()
atf_check -o inline:"y\n" cat foo
}
+atf_test_case namespace
+namespace_head()
+{
+ atf_set "descr" "Test that patch(1) handles files with spaces in the name"
+}
+namespace_body()
+{
+ echo "ABC" > "with spaces.orig"
+ echo "ZYX" > "with spaces"
+
+ atf_check -s not-exit:0 -o save:spaces.diff \
+ diff -u "with spaces.orig" "with spaces"
+
+ atf_check mv "with spaces.orig" "with spaces"
+ atf_check -o not-empty patch < spaces.diff
+}
+
atf_test_case plinelen
plinelen_body()
{
@@ -161,10 +198,12 @@ EOF
atf_init_test_cases()
{
+ atf_add_test_case badfuzz
atf_add_test_case basic
atf_add_test_case limited_ctx
atf_add_test_case file_creation
atf_add_test_case file_nodupe
atf_add_test_case file_removal
+ atf_add_test_case namespace
atf_add_test_case plinelen
}
diff --git a/usr.bin/w/pr_time.c b/usr.bin/w/pr_time.c
index aef8b5dfaa87..445431fe3ec5 100644
--- a/usr.bin/w/pr_time.c
+++ b/usr.bin/w/pr_time.c
@@ -79,8 +79,13 @@ pr_attime(time_t *started, time_t *now)
(void)wcsftime(buf, sizeof(buf), fmt, &tp);
len = wcslen(buf);
width = wcswidth(buf, len);
- xo_attr("since", "%lu", (unsigned long) *started);
- xo_attr("delta", "%lu", (unsigned long) diff);
+ if (xo_get_style(NULL) == XO_STYLE_XML) {
+ xo_attr("since", "%lu", (unsigned long)*started);
+ xo_attr("delta", "%lu", (unsigned long)diff);
+ } else {
+ xo_emit("{e:login-time-since/%lu}{e:login-time-delta/%lu}",
+ (unsigned long)*started, (unsigned long)diff);
+ }
if (len == width)
xo_emit("{:login-time/%-7.7ls/%ls}", buf);
else if (width < 7)
@@ -100,10 +105,16 @@ pr_attime(time_t *started, time_t *now)
int
pr_idle(time_t idle)
{
+ /* In encoded formats, emit the raw data as well */
+ if (xo_get_style(NULL) == XO_STYLE_XML)
+ xo_attr("seconds", "%lu", (unsigned long) idle);
+ else
+ xo_emit("{e:idle-seconds/%lu}", (unsigned long) idle);
+
/* If idle more than 36 hours, print as a number of days. */
if (idle >= 36 * 3600) {
int days = idle / 86400;
- xo_emit(" {:idle/%dday%s} ", days, days > 1 ? "s" : " " );
+ xo_emit(" {q:idle/%dday%s} ", days, days > 1 ? "s" : " " );
if (days >= 100)
return (2);
if (days >= 10)
@@ -111,16 +122,17 @@ pr_idle(time_t idle)
}
/* If idle more than an hour, print as HH:MM. */
- else if (idle >= 3600)
- xo_emit(" {:idle/%2d:%02d/} ",
+ else if (idle >= 3600) {
+ xo_emit(" {q:idle/%2d:%02d} ",
(int)(idle / 3600), (int)((idle % 3600) / 60));
+ }
else if (idle / 60 == 0)
- xo_emit(" - ");
+ xo_emit(" - {q:idle//0}");
/* Else print the minutes idle. */
else
- xo_emit(" {:idle/%2d} ", (int)(idle / 60));
+ xo_emit(" {q:idle/%2d} ", (int)(idle / 60));
return (0); /* not idle longer than 9 days */
}
diff --git a/usr.sbin/bsdinstall/scripts/jail b/usr.sbin/bsdinstall/scripts/jail
index 4b2882dad477..0c3c7e125fdd 100755
--- a/usr.sbin/bsdinstall/scripts/jail
+++ b/usr.sbin/bsdinstall/scripts/jail
@@ -207,7 +207,7 @@ fi
trap error SIGINT # SIGINT is bad again
bsdinstall config || error "Failed to save config"
cp /etc/resolv.conf $1/etc
-cp /etc/localtime $1/etc
+cp -P /etc/localtime $1/etc
cp /var/db/zoneinfo $1/var/db
# Run post-install script
diff --git a/usr.sbin/devinfo/devinfo.8 b/usr.sbin/devinfo/devinfo.8
index f782b919056c..c34713d367ff 100644
--- a/usr.sbin/devinfo/devinfo.8
+++ b/usr.sbin/devinfo/devinfo.8
@@ -1,4 +1,5 @@
-.\" -*- nroff -*-
+.\"
+.\" SPDX-License-Identifer: BSD-2-Clause
.\"
.\" Copyright (c) 2002 Hiten Pandya
.\" Copyright (c) 2002 Robert N. M. Watson
@@ -25,7 +26,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 January 29, 2025
+.Dd August 28, 2025
.Dt DEVINFO 8
.Os
.Sh NAME
@@ -33,11 +34,14 @@
.Nd print information about system device configuration
.Sh SYNOPSIS
.Nm
+.Op Fl -libxo
.Op Fl rv
.Nm
-.Fl u Op Fl v
-.Nm
+.Op Fl -libxo
.Fl p Ar dev Op Fl v
+.Nm
+.Op Fl -libxo
+.Fl u Op Fl v
.Sh DESCRIPTION
The
.Nm
@@ -46,11 +50,23 @@ in the system, starting from the
.Dq nexus
device.
.Pp
-The following options are accepted.
-.Bl -tag -width indent
+The following options are accepted:
+.Bl -tag -width "--libxo"
+.It Fl -libxo
+Generate output via
+.Xr libxo 3
+in a selection of different human and machine readable formats.
+See
+.Xr xo_options 7
+for details on command line arguments.
+.It Fl p Ar dev
+Display the path of
+.Ar dev
+back to the root of the device tree.
.It Fl r
-Causes hardware resource information (such as IRQ, I/O ports, I/O memory
-addresses) to be also listed, under each device that has reserved those resources.
+Causes hardware resource information
+.Pq such as IRQ, I/O ports, I/O memory addresses
+to be also listed, under each device that has reserved those resources.
.It Fl u
Displays the same information as with
.Fl r
@@ -63,19 +79,22 @@ Display all devices in the driver tree, not just those that are attached or
busy.
Without this flag, only those devices that have attached are reported.
This flag also displays verbose information about each device.
-.It Fl p Ar dev
-Display the path of
-.Ar dev
-back to the root of the device tree.
.El
.Sh SEE ALSO
.Xr systat 1 ,
.Xr devinfo 3 ,
+.Xr libxo 3 ,
+.Xr xo_options 7 ,
.Xr devctl 8 ,
.Xr iostat 8 ,
.Xr pciconf 8 ,
.Xr vmstat 8 ,
.Xr devclass 9 ,
.Xr device 9
+.Sh HISTORY
+The
+.Nm
+utility appeared in
+.Fx 5.0 .
.Sh AUTHORS
.An Mike Smith Aq Mt msmith@FreeBSD.org
diff --git a/usr.sbin/makefs/ffs.c b/usr.sbin/makefs/ffs.c
index c0fcadf11fba..ed94abb7504f 100644
--- a/usr.sbin/makefs/ffs.c
+++ b/usr.sbin/makefs/ffs.c
@@ -591,6 +591,75 @@ ffs_create_image(const char *image, fsinfo_t *fsopts)
return (fsopts->fd);
}
+static void
+ffs_add_size(fsinfo_t *fsopts, size_t file_len)
+{
+ ffs_opt_t *ffs_opts = fsopts->fs_specific;
+ size_t blocks, fs_nindir, overhead;
+ int indir_level;
+
+ blocks = howmany(file_len, ffs_opts->bsize);
+
+ if (blocks <= UFS_NDADDR) {
+ /* Count full blocks. */
+ fsopts->size += rounddown2(file_len, ffs_opts->bsize);
+ /* Calculate fragment size needed. */
+ overhead = howmany(file_len -
+ rounddown2(file_len, ffs_opts->bsize), ffs_opts->fsize);
+
+ /*
+ * A file could have just 1 fragment with size 1/8, 1/4 or 1/2
+ * of bsize.
+ */
+ switch (overhead) {
+ case 0:
+ break;
+ case 1:
+ fsopts->size += ffs_opts->fsize;
+ break;
+ case 2:
+ fsopts->size += 2 * ffs_opts->fsize;
+ break;
+ case 3:
+ case 4:
+ fsopts->size += 4 * ffs_opts->fsize;
+ break;
+ default:
+ fsopts->size += ffs_opts->bsize;
+ break;
+ }
+ return;
+ }
+
+ /* File does not fit into direct blocks, count indirect blocks. */
+ blocks = howmany(file_len - UFS_NDADDR * (size_t)ffs_opts->bsize,
+ ffs_opts->bsize);
+ fs_nindir = (size_t)ffs_opts->bsize / ((ffs_opts->version == 1) ?
+ sizeof(ufs1_daddr_t) : sizeof(ufs2_daddr_t));
+
+ indir_level = overhead = 0;
+ while (blocks > 0 && indir_level < 3) {
+ /* One indirect block is stored in di_ib[] */
+ blocks = howmany(blocks, fs_nindir) - 1;
+ fsopts->size += ffs_opts->bsize * blocks;
+ overhead += blocks + 1;
+ indir_level++;
+ }
+
+ assert(blocks == 0);
+
+ if ((debug & DEBUG_FS_SIZE_DIR_NODE) != 0) {
+ printf("ffs_size_dir: size %jd, using %d levels of indirect "
+ "blocks, overhead %jd blocks\n", (uintmax_t)file_len,
+ indir_level, (uintmax_t)overhead);
+ }
+
+ /*
+ * If the file is big enough to use indirect blocks,
+ * we allocate bsize block for trailing data.
+ */
+ fsopts->size += roundup2(file_len, ffs_opts->bsize);
+}
static void
ffs_size_dir(fsnode *root, fsinfo_t *fsopts)
@@ -622,20 +691,6 @@ ffs_size_dir(fsnode *root, fsinfo_t *fsopts)
e, tmpdir.d_namlen, this, curdirsize); \
} while (0);
-#define ADDSIZE(x) do { \
- if ((size_t)(x) < UFS_NDADDR * (size_t)ffs_opts->bsize) { \
- fsopts->size += roundup((x), ffs_opts->fsize); \
- } else { \
- /* Count space consumed by indirecttion blocks. */ \
- fsopts->size += ffs_opts->bsize * \
- (howmany((x), UFS_NDADDR * ffs_opts->bsize) - 1); \
- /* \
- * If the file is big enough to use indirect blocks, \
- * we allocate bsize block for trailing data. \
- */ \
- fsopts->size += roundup((x), ffs_opts->bsize); \
- } \
-} while (0);
curdirsize = 0;
for (node = root; node != NULL; node = node->next) {
@@ -646,13 +701,13 @@ ffs_size_dir(fsnode *root, fsinfo_t *fsopts)
} else if ((node->inode->flags & FI_SIZED) == 0) {
/* don't count duplicate names */
node->inode->flags |= FI_SIZED;
- if (debug & DEBUG_FS_SIZE_DIR_NODE)
+ if ((debug & DEBUG_FS_SIZE_DIR_NODE) != 0)
printf("ffs_size_dir: `%s' size %lld\n",
node->name,
(long long)node->inode->st.st_size);
fsopts->inodes++;
if (node->type == S_IFREG)
- ADDSIZE(node->inode->st.st_size);
+ ffs_add_size(fsopts, node->inode->st.st_size);
if (node->type == S_IFLNK) {
size_t slen;
@@ -660,13 +715,16 @@ ffs_size_dir(fsnode *root, fsinfo_t *fsopts)
if (slen >= (ffs_opts->version == 1 ?
UFS1_MAXSYMLINKLEN :
UFS2_MAXSYMLINKLEN))
- ADDSIZE(slen);
+ ffs_add_size(fsopts, slen);
}
}
if (node->type == S_IFDIR)
ffs_size_dir(node->child, fsopts);
}
- ADDSIZE(curdirsize);
+ ffs_add_size(fsopts, curdirsize);
+
+ /* Round up to full block to account fragment scattering. */
+ fsopts->size = roundup2(fsopts->size, ffs_opts->bsize);
if (debug & DEBUG_FS_SIZE_DIR)
printf("ffs_size_dir: exit: size %lld inodes %lld\n",
diff --git a/usr.sbin/ngctl/Makefile b/usr.sbin/ngctl/Makefile
index 72a5ccaa96d7..997841272376 100644
--- a/usr.sbin/ngctl/Makefile
+++ b/usr.sbin/ngctl/Makefile
@@ -13,4 +13,9 @@ LIBADD= netgraph
CFLAGS+= -DEDITLINE
LIBADD+= edit pthread
+.if ${MK_JAIL} != "no"
+CFLAGS+= -DJAIL
+LIBADD+= jail
+.endif
+
.include <bsd.prog.mk>
diff --git a/usr.sbin/ngctl/main.c b/usr.sbin/ngctl/main.c
index 7c79e67d8275..b32e4f878b6e 100644
--- a/usr.sbin/ngctl/main.c
+++ b/usr.sbin/ngctl/main.c
@@ -55,6 +55,10 @@
#include <histedit.h>
#include <pthread.h>
#endif
+#ifdef JAIL
+#include <sys/jail.h>
+#include <jail.h>
+#endif
#include <netgraph.h>
@@ -137,16 +141,17 @@ int csock, dsock;
int
main(int ac, char *av[])
{
- char name[NG_NODESIZ];
- int interactive = isatty(0) && isatty(1);
- FILE *fp = NULL;
- int ch, rtn = 0;
+ char name[NG_NODESIZ];
+ int interactive = isatty(0) && isatty(1);
+ FILE *fp = NULL;
+ const char *jail_name = NULL;
+ int ch, rtn = 0;
/* Set default node name */
snprintf(name, sizeof(name), "ngctl%d", getpid());
/* Parse command line */
- while ((ch = getopt(ac, av, "df:n:")) != -1) {
+ while ((ch = getopt(ac, av, "df:j:n:")) != -1) {
switch (ch) {
case 'd':
NgSetDebug(NgSetDebug(-1) + 1);
@@ -157,6 +162,13 @@ main(int ac, char *av[])
else if ((fp = fopen(optarg, "r")) == NULL)
err(EX_NOINPUT, "%s", optarg);
break;
+ case 'j':
+#ifdef JAIL
+ jail_name = optarg;
+#else
+ errx(EX_UNAVAILABLE, "not built with jail support");
+#endif
+ break;
case 'n':
snprintf(name, sizeof(name), "%s", optarg);
break;
@@ -169,6 +181,22 @@ main(int ac, char *av[])
ac -= optind;
av += optind;
+ if (jail_name != NULL) {
+ int jid;
+
+ if (jail_name[0] == '\0')
+ Usage("invalid jail name");
+
+ jid = jail_getid(jail_name);
+
+ if (jid == -1)
+ errx((errno == EPERM) ? EX_NOPERM : EX_NOHOST,
+ "%s", jail_errmsg);
+ if (jail_attach(jid) != 0)
+ errx((errno == EPERM) ? EX_NOPERM : EX_OSERR,
+ "cannot attach to jail");
+ }
+
/* Create a new socket node */
if (NgMkSockNode(name, &csock, &dsock) < 0)
err(EX_OSERR, "can't create node");
@@ -657,6 +685,7 @@ Usage(const char *msg)
if (msg)
warnx("%s", msg);
fprintf(stderr,
- "usage: ngctl [-d] [-f file] [-n name] [command ...]\n");
+ "usage: ngctl [-j jail] [-d] [-f filename] [-n nodename] "
+ "[command [argument ...]]\n");
exit(EX_USAGE);
}
diff --git a/usr.sbin/ngctl/ngctl.8 b/usr.sbin/ngctl/ngctl.8
index 2225c836674a..63b8f58ed3df 100644
--- a/usr.sbin/ngctl/ngctl.8
+++ b/usr.sbin/ngctl/ngctl.8
@@ -31,7 +31,7 @@
.\" OF SUCH DAMAGE.
.\" $Whistle: ngctl.8,v 1.6 1999/01/20 03:19:44 archie Exp $
.\"
-.Dd January 19, 1999
+.Dd August 29, 2025
.Dt NGCTL 8
.Os
.Sh NAME
@@ -39,9 +39,11 @@
.Nd netgraph control utility
.Sh SYNOPSIS
.Nm
+.Op Fl j Ar jail
.Op Fl d
.Op Fl f Ar filename
.Op Fl n Ar nodename
+.Op Ar command Op Ns Ar argument ...
.Op Ar command ...
.Sh DESCRIPTION
The
@@ -73,12 +75,31 @@ form if the originating node supports conversion.
.Pp
The options are as follows:
.Bl -tag -width indent
-.It Fl f Ar nodeinfo
+.It Fl f Ar filename
Read commands from the named file.
A single dash represents the standard input.
Blank lines and lines starting with a
.Dq #
are ignored.
+Note that when the
+.Fl j Ar jail
+option is specified, the file will be opened before attaching to the jail and
+then be processed inside the jail.
+.It Fl j Ar jail
+Perform the actions inside the
+.Ar jail .
+.Pp
+.Nm
+will first attach to the
+.Ar jail
+(by jail id or jail name) before performing the effects.
+.Pp
+This allows netgraph nodes of
+.Ar jail
+to be created, modified, and destroyed even if the
+.Nm
+binary is not available in
+.Ar jail .
.It Fl n Ar nodename
Assign
.Em nodename
diff --git a/usr.sbin/pkg/FreeBSD.conf.latest b/usr.sbin/pkg/FreeBSD.conf.latest
index 91bf02c2610e..ac1636386942 100644
--- a/usr.sbin/pkg/FreeBSD.conf.latest
+++ b/usr.sbin/pkg/FreeBSD.conf.latest
@@ -3,8 +3,8 @@
# create a /usr/local/etc/pkg/repos/FreeBSD.conf file, e.g.:
#
# mkdir -p /usr/local/etc/pkg/repos
-# echo "FreeBSD: { enabled: no }" > /usr/local/etc/pkg/repos/FreeBSD.conf
-# echo "FreeBSD-kmods: { enabled: no }" >> /usr/local/etc/pkg/repos/FreeBSD.conf
+# echo "FreeBSD-ports: { enabled: no }" > /usr/local/etc/pkg/repos/FreeBSD.conf
+# echo "FreeBSD-ports-kmods: { enabled: no }" >> /usr/local/etc/pkg/repos/FreeBSD.conf
#
FreeBSD-ports: {
diff --git a/usr.sbin/pkg/FreeBSD.conf.quarterly b/usr.sbin/pkg/FreeBSD.conf.quarterly
index 4ed590dd04f1..4e26582c6981 100644
--- a/usr.sbin/pkg/FreeBSD.conf.quarterly
+++ b/usr.sbin/pkg/FreeBSD.conf.quarterly
@@ -3,8 +3,8 @@
# create a /usr/local/etc/pkg/repos/FreeBSD.conf file, e.g.:
#
# mkdir -p /usr/local/etc/pkg/repos
-# echo "FreeBSD: { enabled: no }" > /usr/local/etc/pkg/repos/FreeBSD.conf
-# echo "FreeBSD-kmods: { enabled: no }" >> /usr/local/etc/pkg/repos/FreeBSD.conf
+# echo "FreeBSD-ports: { enabled: no }" > /usr/local/etc/pkg/repos/FreeBSD.conf
+# echo "FreeBSD-ports-kmods: { enabled: no }" >> /usr/local/etc/pkg/repos/FreeBSD.conf
#
FreeBSD-ports: {
diff --git a/usr.sbin/pkg/FreeBSD.conf.quarterly-release b/usr.sbin/pkg/FreeBSD.conf.quarterly-release
index 0f8748b89fed..b4a78009f7d2 100644
--- a/usr.sbin/pkg/FreeBSD.conf.quarterly-release
+++ b/usr.sbin/pkg/FreeBSD.conf.quarterly-release
@@ -3,8 +3,8 @@
# create a /usr/local/etc/pkg/repos/FreeBSD.conf file, e.g.:
#
# mkdir -p /usr/local/etc/pkg/repos
-# echo "FreeBSD: { enabled: no }" > /usr/local/etc/pkg/repos/FreeBSD.conf
-# echo "FreeBSD-kmods: { enabled: no }" >> /usr/local/etc/pkg/repos/FreeBSD.conf
+# echo "FreeBSD-ports: { enabled: no }" > /usr/local/etc/pkg/repos/FreeBSD.conf
+# echo "FreeBSD-ports-kmods: { enabled: no }" >> /usr/local/etc/pkg/repos/FreeBSD.conf
#
FreeBSD-ports: {