From 54c9e42a5e597a12f9f0cdb6c7caff7d6715f9a4 Mon Sep 17 00:00:00 2001 From: Jim Klimov Date: Sun, 8 Feb 2026 17:50:57 +0000 Subject: [PATCH 1/9] scripts/augeas/gen-nutupsconf-aug.py.in: try to actually catch warnings (e.g. DeprecationWarning) to use correct form of open() [#3256] Signed-off-by: Jim Klimov --- scripts/augeas/gen-nutupsconf-aug.py.in | 12 ++++++++++++ 1 file changed, 12 insertions(+) diff --git a/scripts/augeas/gen-nutupsconf-aug.py.in b/scripts/augeas/gen-nutupsconf-aug.py.in index 29fa19c15d..f2c51a8e56 100755 --- a/scripts/augeas/gen-nutupsconf-aug.py.in +++ b/scripts/augeas/gen-nutupsconf-aug.py.in @@ -27,6 +27,15 @@ import os import re import glob +HAVE_WARNINGS = False +try: + import warnings + warnings.filterwarnings("error") + HAVE_WARNINGS = True +except Exception as x: + # sys.stderr.write("WARNING: failed to import warnings or configure them: %s" % str(x)) + pass + try: # NOTE: Deprecated as of python3.14 import codecs @@ -47,6 +56,9 @@ except Exception as x: HAVE_CODECS = False USE_CODECS = False +if HAVE_WARNINGS: + warnings.resetwarnings() + # Return a sorted list of unique entries, based on the input 'list' def sortUnique(list): newVarList = [] From 9dd88ff7f40ce32ee742a938fba43c08d701bd0b Mon Sep 17 00:00:00 2001 From: Jim Klimov Date: Sun, 8 Feb 2026 17:51:33 +0000 Subject: [PATCH 2/9] scripts/augeas/gen-nutupsconf-aug.py.in: fix ResourceWarnings about unclosed file descriptors [#3256] Signed-off-by: Jim Klimov --- scripts/augeas/gen-nutupsconf-aug.py.in | 4 ++++ 1 file changed, 4 insertions(+) diff --git a/scripts/augeas/gen-nutupsconf-aug.py.in b/scripts/augeas/gen-nutupsconf-aug.py.in index f2c51a8e56..5aa3c1c4e8 100755 --- a/scripts/augeas/gen-nutupsconf-aug.py.in +++ b/scripts/augeas/gen-nutupsconf-aug.py.in @@ -141,9 +141,11 @@ if __name__ == '__main__': defRow = re.findall(r'"([^"]*)",?', varDefine) if (len(defRow) == 1): variableNames.append(defRow[0]) + defFd.close() else: # Remove quotes variableNames.append(row[1].replace('"', '').lstrip()) + fd.close() # Filter multiply defined variables variableNames = sortUnique(variableNames) @@ -160,6 +162,7 @@ if __name__ == '__main__': # 2.1/ Search for the pattern to replace outputText = tplFd.read() + tplFd.close() outputText = outputText.replace('@SPECIFIC_DRV_VARS@', specificVars) # 3/ Output final lens @@ -168,3 +171,4 @@ if __name__ == '__main__': else: outFd = open(outputFilename, mode='w', encoding='utf-8') outFd.write(outputText) + outFd.close() From b05fb12eee065fb38e59c31599f465614c3c175e Mon Sep 17 00:00:00 2001 From: Jim Klimov Date: Sun, 8 Feb 2026 17:55:33 +0000 Subject: [PATCH 3/9] scripts/python/module/setup.py.in: try to actually catch warnings (e.g. DeprecationWarning) to use correct form of open() [#3256] Signed-off-by: Jim Klimov --- scripts/python/module/setup.py.in | 12 ++++++++++++ 1 file changed, 12 insertions(+) diff --git a/scripts/python/module/setup.py.in b/scripts/python/module/setup.py.in index 098e2d43b4..51383d1593 100644 --- a/scripts/python/module/setup.py.in +++ b/scripts/python/module/setup.py.in @@ -10,6 +10,15 @@ import sys here = os.path.abspath(os.path.dirname(__file__)) +HAVE_WARNINGS = False +try: + import warnings + warnings.filterwarnings("error") + HAVE_WARNINGS = True +except Exception as x: + # sys.stderr.write("WARNING: failed to import warnings or configure them: %s" % str(x)) + pass + try: # NOTE: Deprecated as of python3.14 import codecs @@ -30,6 +39,9 @@ except Exception as x: HAVE_CODECS = False USE_CODECS = False +if HAVE_WARNINGS: + warnings.resetwarnings() + # README.txt appears from README.adoc during package or CI build if USE_CODECS: with codecs.open(os.path.join(here, "README.txt"), encoding="utf-8") as fh: From 34f15d9ae138c7d0880632f32790979a833f5d68 Mon Sep 17 00:00:00 2001 From: Jim Klimov Date: Sun, 8 Feb 2026 18:13:25 +0000 Subject: [PATCH 4/9] docs/config-prereqs.txt, docs/nut.dict: update for Fedora 43 [#3311] Signed-off-by: Jim Klimov --- docs/config-prereqs.txt | 60 ++++++++++++++++++++++++++++++++++------- docs/nut.dict | 6 ++++- 2 files changed, 56 insertions(+), 10 deletions(-) diff --git a/docs/config-prereqs.txt b/docs/config-prereqs.txt index 1333939aed..b4adb9d96f 100644 --- a/docs/config-prereqs.txt +++ b/docs/config-prereqs.txt @@ -313,16 +313,21 @@ NOTE: For Jenkins agents, also need to `apt-get install openjdk-21-jdk-headless` You may have to ensure that `/proc` is mounted in the target chroot (or do this from the running container). -CentOS 6 and 7 -~~~~~~~~~~~~~~ +CentOS 6 and 7, Fedora 43 +~~~~~~~~~~~~~~~~~~~~~~~~~ CentOS is another popular baseline among Linux distributions, being a free derivative of the RedHat Linux, upon which many other distros are based as well. These systems typically use the RPM package manager, using directly `rpm` command, or `yum` or `dnf` front-ends depending on their generation. +In fact, most of the instructions directly apply to much newer distributions +like Fedora 43. + For CI farm container setup, prepared root filesystem archives from http://download.proxmox.com/images/system/ worked sufficiently well. +For Fedora, https://images.linuxcontainers.org/images/fedora/43/amd64/default +nightly image was used. Prepare CentOS repository mirrors ^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^ @@ -388,6 +393,7 @@ enable it: :; yum install \ openssh-server openssh-clients +# On CentOS 6/7: :; chkconfig sshd on :; service sshd start @@ -400,8 +406,8 @@ NOTE: Below we request to install generic `python` per system defaults. You may request specifically `python2` or `python3` (or both): current NUT should be compatible with both (2.7+ at least). -NOTE: On CentOS, `libusb` means 0.1.x and `libusbx` means 1.x.x API version -(latter is not available for CentOS 6). +NOTE: On CentOS, `libusb` means 0.1.x (not available on modern Fedora), +and `libusbx` means 1.x.x API version (latter is not available for CentOS 6). NOTE: On CentOS, it seems that development against libi2c/smbus is not supported. Neither the suitable devel packages were found, nor i2c-based @@ -435,6 +441,8 @@ drivers in distro packaging of NUT. Resolution and doc PRs are welcome. # You can find a list of what is (pre-)installed with: # :; rpm -qa | grep -Ei 'perl|python' # Note that CentOS 6 includes python-2.6.x and does not serve newer versions +# For Fedora 43, further packages can be installed to test more: +# :; yum install python3-qt5 python3-setuptools # For spell-checking, highly recommended if you would propose pull requests: :; yum install \ @@ -445,6 +453,10 @@ drivers in distro packaging of NUT. Resolution and doc PRs are welcome. :; yum install \ asciidoc source-highlight python-pygments dblatex +# For PDF generation, you may need explicitly (at least on Fedora 43): +:; yum install \ + texlive 'tex(upquote.sty)' + # For CGI graph generation - massive packages (X11): :; yum install \ gd-devel @@ -454,20 +466,30 @@ drivers in distro packaging of NUT. Resolution and doc PRs are welcome. systemd-devel # NOTE: "libusbx" is the CentOS way of naming "libusb-1.0" (not in CentOS 6) -# vs. the older "libusb" as the package with "libusb-0.1" +# vs. the older "libusb" as the package with "libusb-0.1" (not in recent Fedora) +:; yum install \ + libusb-devel + +:; yum install \ + libusbx-devel + :; yum install \ cppunit-devel \ openssl-devel nss-devel \ augeas augeas-devel \ - libusb-devel libusbx-devel \ glib2-devel \ i2c-tools \ libmodbus-devel \ net-snmp-devel \ - powerman-devel \ freeipmi-devel \ avahi-devel \ neon-devel + +# Not in recent Fedora releases: +:; yum install \ + powerman-devel + +# Not in CentOS, some present in Fedora: #?# is python-augeas needed? exists at least... #?# no (lib)i2c-devel ... #?# no (lib)ipmimonitoring-devel ... would "freeipmi-ipmidetectd" @@ -475,6 +497,11 @@ drivers in distro packaging of NUT. Resolution and doc PRs are welcome. #?# no (lib)gpio(d)-devel - starts with CentOS 8 (or extra repositories #?# for later minor releases of CentOS 7) +# In Fedora: +:; yum install \ + libi2c-devel \ + libgpiod-devel + # Some NUT code related to lua may be currently limited to lua-5.1 # or possibly 5.2; the former is default in CentOS 7 releases... :; yum install \ @@ -482,6 +509,14 @@ drivers in distro packaging of NUT. Resolution and doc PRs are welcome. :; yum install \ bash dash ksh + +# If available: +:; yum install \ + bash-completion + +# In Fedora: +:; yum install \ + busybox ------ NOTE: `busybox` is not packaged for CentOS 7 release; a static binary can @@ -499,8 +534,15 @@ other described environments by adding a symlink `/usr/lib/ccache`: ====== For Jenkins agents, also need to install JDK 17 or newer, which is not available for CentOS 6 nor 7 directly (in distribution packaging). -Alternative packaging, such as Temurin from the Adoptium project, is possible -(checked for at least CentOS 7), see + +In Fedora e.g.: +------ +:; yum install \ + java-21-openjdk-headless +------ + +Alternative packaging for older distros, such as Temurin from the Adoptium +project, is possible (checked for at least CentOS 7), see link:https://adoptium.net/installation/linux/#_centosrhelfedora_instructions[their instructions] for specific details. This may require updated library package versions as dependencies from the OS distribution, so you may also have to make diff --git a/docs/nut.dict b/docs/nut.dict index a88fe53d6d..f71819d51d 100644 --- a/docs/nut.dict +++ b/docs/nut.dict @@ -1,4 +1,4 @@ -personal_ws-1.1 en 3655 utf-8 +personal_ws-1.1 en 3659 utf-8 AAC AAS ABI @@ -3137,6 +3137,7 @@ setproctag setq setuid setupCommands +setuptools setvar setvar's sfr @@ -3335,6 +3336,8 @@ testime testtime testuser testvar +tex +texlive textproc tgcware tgt @@ -3436,6 +3439,7 @@ unstash updateinfo upexia upower +upquote upsBypassCurrent upsBypassPower upsBypassVoltage From c7bd72ddeb72ecfaec1429de7f6da85f15f4fa88 Mon Sep 17 00:00:00 2001 From: Jim Klimov Date: Sun, 8 Feb 2026 19:06:03 +0000 Subject: [PATCH 5/9] drivers/generic_gpio_common.c, drivers/generic_gpio_libgpiod.c, tests/generic_gpio_utest.c: fix more casting from xcalloc() et al [#3297] Signed-off-by: Jim Klimov --- drivers/generic_gpio_common.c | 12 ++++++------ drivers/generic_gpio_libgpiod.c | 6 +++--- tests/generic_gpio_utest.c | 10 +++++----- 3 files changed, 14 insertions(+), 14 deletions(-) diff --git a/drivers/generic_gpio_common.c b/drivers/generic_gpio_common.c index a163f7784e..dc956e04f2 100644 --- a/drivers/generic_gpio_common.c +++ b/drivers/generic_gpio_common.c @@ -75,13 +75,13 @@ struct gpioups_t *generic_gpio_open(const char *chipName) { if (!rules) /* rules is required configuration parameter */ fatalx(EXIT_FAILURE, "UPS status calculation rules not specified"); - upsfdlocal = xcalloc(1, sizeof(*upsfdlocal)); + upsfdlocal = (struct gpioups_t *)xcalloc(1, sizeof(*upsfdlocal)); upsfdlocal->runOptions = 0; /* don't use ROPT_REQRES and ROPT_EVMODE yet */ upsfdlocal->chipName = chipName; get_ups_rules(upsfdlocal, (unsigned char *)rules); - upsfdlocal->upsLinesStates = xcalloc(upsfdlocal->upsLinesCount, sizeof(int)); + upsfdlocal->upsLinesStates = (int *)xcalloc(upsfdlocal->upsLinesCount, sizeof(int)); return upsfdlocal; } @@ -122,7 +122,7 @@ void add_rule_item(struct gpioups_t *upsfdlocal, int newValue) { int subCount = (upsfdlocal->rules[upsfdlocal->rulesCount - 1]) ? upsfdlocal->rules[upsfdlocal->rulesCount - 1]->subCount + 1 : 1; int itemSize = subCount * sizeof(upsfdlocal->rules[0]->cRules[0]) + sizeof(rulesint); - upsfdlocal->rules[upsfdlocal->rulesCount - 1] = xrealloc(upsfdlocal->rules[upsfdlocal->rulesCount - 1], itemSize); + upsfdlocal->rules[upsfdlocal->rulesCount - 1] = (struct rulesint_t *)xrealloc(upsfdlocal->rules[upsfdlocal->rulesCount - 1], itemSize); upsfdlocal->rules[upsfdlocal->rulesCount - 1]->subCount = subCount; upsfdlocal->rules[upsfdlocal->rulesCount - 1]->cRules[subCount - 1] = newValue; } @@ -197,8 +197,8 @@ void get_ups_rules(struct gpioups_t *upsfdlocal, unsigned char *rulesString) { } else { lexStatus = 1; upsfdlocal->rulesCount++; - upsfdlocal->rules = xrealloc(upsfdlocal->rules, (size_t)(sizeof(upsfdlocal->rules[0])*upsfdlocal->rulesCount)); - upsfdlocal->rules[upsfdlocal->rulesCount -1 ] = xcalloc(1, sizeof(rulesint)); + upsfdlocal->rules = (struct rulesint_t **)xrealloc(upsfdlocal->rules, (size_t)(sizeof(upsfdlocal->rules[0])*upsfdlocal->rulesCount)); + upsfdlocal->rules[upsfdlocal->rulesCount -1 ] = (struct rulesint_t *)xcalloc(1, sizeof(rulesint)); strncpy(upsfdlocal->rules[upsfdlocal->rulesCount - 1]->stateName, (char *)(rulesString + startPos), endPos - startPos); upsfdlocal->rules[upsfdlocal->rulesCount - 1]->stateName[endPos - startPos] = 0; } @@ -291,7 +291,7 @@ void get_ups_rules(struct gpioups_t *upsfdlocal, unsigned char *rulesString) { if (!pinOnList) { if (upsfdlocal->rules[i]->cRules[j] >= 0) { upsfdlocal->upsLinesCount++; - upsfdlocal->upsLines = xrealloc(upsfdlocal->upsLines, sizeof(upsfdlocal->upsLines[0])*upsfdlocal->upsLinesCount); + upsfdlocal->upsLines = (int *)xrealloc(upsfdlocal->upsLines, sizeof(upsfdlocal->upsLines[0])*upsfdlocal->upsLinesCount); upsfdlocal->upsLines[upsfdlocal->upsLinesCount - 1] = upsfdlocal->rules[i]->cRules[j]; if (upsfdlocal->upsLines[upsfdlocal->upsLinesCount - 1] > upsfdlocal->upsMaxLine) { upsfdlocal->upsMaxLine = upsfdlocal->upsLines[upsfdlocal->upsLinesCount - 1]; diff --git a/drivers/generic_gpio_libgpiod.c b/drivers/generic_gpio_libgpiod.c index 30c2dd806f..a9c923ed73 100644 --- a/drivers/generic_gpio_libgpiod.c +++ b/drivers/generic_gpio_libgpiod.c @@ -121,7 +121,7 @@ static void reserve_lines_libgpiod(struct gpioups_t *gpioupsfdlocal, int inner) * and check lines numbers validity - consistency with h/w chip */ void gpio_open(struct gpioups_t *gpioupsfdlocal) { - struct libgpiod_data_t *libgpiod_data = xcalloc(1, sizeof(struct libgpiod_data_t)); + struct libgpiod_data_t *libgpiod_data = (struct libgpiod_data_t *)xcalloc(1, sizeof(struct libgpiod_data_t)); gpioupsfdlocal->lib_data = libgpiod_data; #if WITH_LIBGPIO_VERSION < 0x00020000 @@ -129,7 +129,7 @@ void gpio_open(struct gpioups_t *gpioupsfdlocal) { #else /* #if WITH_LIBGPIO_VERSION >= 0x00020000 */ if(!strchr(gpioupsfdlocal->chipName, '/')) { size_t pathNameLen = strlen(gpioupsfdlocal->chipName)+6; - char *pathName = xcalloc(pathNameLen, sizeof(char)); + char *pathName = (char *)xcalloc(pathNameLen, sizeof(char)); strncpy(pathName, "/dev/", pathNameLen); strncat(pathName, gpioupsfdlocal->chipName, pathNameLen); libgpiod_data->gpioChipHandle = gpiod_chip_open(pathName); @@ -182,7 +182,7 @@ void gpio_open(struct gpioups_t *gpioupsfdlocal) { &libgpiod_data->gpioLines ); #else /* #if WITH_LIBGPIO_VERSION >= 0x00020000 */ - libgpiod_data->values = xcalloc(gpioupsfdlocal->upsLinesCount, sizeof(*libgpiod_data->values)); + libgpiod_data->values = (enum gpiod_line_value *)xcalloc(gpioupsfdlocal->upsLinesCount, sizeof(*libgpiod_data->values)); lineSettings = gpiod_line_settings_new(); libgpiod_data->lineConfig = gpiod_line_config_new(); libgpiod_data->config = gpiod_request_config_new(); diff --git a/tests/generic_gpio_utest.c b/tests/generic_gpio_utest.c index 363ee71d18..62b4577dfa 100644 --- a/tests/generic_gpio_utest.c +++ b/tests/generic_gpio_utest.c @@ -238,7 +238,7 @@ int main(int argc, char **argv) { #endif if(fEof!=EOF) { if(!strcmp(testType, "rules")) { - struct gpioups_t *upsfdtest = xcalloc(1, sizeof(*upsfdtest)); + struct gpioups_t *upsfdtest = (struct gpioups_t *)xcalloc(1, sizeof(*upsfdtest)); /* NOTE: here and below, freed by generic_gpio_close(&upsfdtest) */ jmp_result = setjmp(env_buffer); if(jmp_result) { /* test case exiting */ @@ -252,11 +252,11 @@ int main(int argc, char **argv) { if(!strcmp(testType, "states")) { int expectedStateValue; int calculatedStateValue; - struct gpioups_t *upsfdtest = xcalloc(1, sizeof(*upsfdtest)); + struct gpioups_t *upsfdtest = (struct gpioups_t *)xcalloc(1, sizeof(*upsfdtest)); int j; get_ups_rules(upsfdtest, (unsigned char *)rules); - upsfdtest->upsLinesStates = xcalloc(upsfdtest->upsLinesCount, sizeof(int)); + upsfdtest->upsLinesStates = (int *)xcalloc(upsfdtest->upsLinesCount, sizeof(int)); for (j=0; j < upsfdtest->upsLinesCount; j++) { fEof=fscanf(testData, "%d", &upsfdtest->upsLinesStates[j]); } @@ -283,7 +283,7 @@ int main(int argc, char **argv) { char chargeStatus[256]; char chargeLow[256]; char charge[256]; - struct gpioups_t *upsfdtest = xcalloc(1, sizeof(*upsfdtest)); + struct gpioups_t *upsfdtest = (struct gpioups_t *)xcalloc(1, sizeof(*upsfdtest)); int j; /* "volatile" trickery to avoid the likes of: @@ -296,7 +296,7 @@ int main(int argc, char **argv) { const char * volatile currCharge = NULL; get_ups_rules(upsfdtest, (unsigned char *)rules); - upsfdtest->upsLinesStates = xcalloc(upsfdtest->upsLinesCount, sizeof(int)); + upsfdtest->upsLinesStates = (int *)xcalloc(upsfdtest->upsLinesCount, sizeof(int)); for (j = 0; j < upsfdtest->upsLinesCount; j++) { fEof=fscanf(testData, "%d", &upsfdtest->upsLinesStates[j]); } From 96c9acba517b8cb871bbf57f67ed9f41d0dc2c46 Mon Sep 17 00:00:00 2001 From: Jim Klimov Date: Sun, 8 Feb 2026 19:06:21 +0000 Subject: [PATCH 6/9] drivers/nutdrv_qx_voltronic-axpert.c: fix more casting from xcalloc() et al [#3297] Signed-off-by: Jim Klimov --- drivers/nutdrv_qx_voltronic-axpert.c | 8 ++++---- 1 file changed, 4 insertions(+), 4 deletions(-) diff --git a/drivers/nutdrv_qx_voltronic-axpert.c b/drivers/nutdrv_qx_voltronic-axpert.c index c5da6fb5e3..9f2f754ac6 100644 --- a/drivers/nutdrv_qx_voltronic-axpert.c +++ b/drivers/nutdrv_qx_voltronic-axpert.c @@ -2419,7 +2419,7 @@ static int voltronic_sunny_energy_hour(item_t *item, char *command, const size_t return -1; } - buf = xcalloc(commandlen, sizeof(char)); + buf = (char *)xcalloc(commandlen, sizeof(char)); if (!buf) { upsdebugx(2, "%s: cannot allocate buffer", __func__); return -1; @@ -2448,7 +2448,7 @@ static int voltronic_sunny_energy_day(item_t *item, char *command, const size_t return -1; } - buf = xcalloc(commandlen, sizeof(char)); + buf = (char *)xcalloc(commandlen, sizeof(char)); if (!buf) { upsdebugx(2, "%s: cannot allocate buffer", __func__); return -1; @@ -2477,7 +2477,7 @@ static int voltronic_sunny_energy_month(item_t *item, char *command, const size_ return -1; } - buf = xcalloc(commandlen, sizeof(char)); + buf = (char *)xcalloc(commandlen, sizeof(char)); if (!buf) { upsdebugx(2, "%s: cannot allocate buffer", __func__); return -1; @@ -2506,7 +2506,7 @@ static int voltronic_sunny_energy_year(item_t *item, char *command, const size_t return -1; } - buf = xcalloc(commandlen, sizeof(char)); + buf = (char *)xcalloc(commandlen, sizeof(char)); if (!buf) { upsdebugx(2, "%s: cannot allocate buffer", __func__); return -1; From eee929773e6e7b7e9c6e7ca899ecb7d35434a3b6 Mon Sep 17 00:00:00 2001 From: Jim Klimov Date: Sun, 8 Feb 2026 19:09:55 +0000 Subject: [PATCH 7/9] tests/generic_gpio_liblocal.c: gpiod_line_request_get_values(): do not assign plain number to enum variables [#3297] Signed-off-by: Jim Klimov --- tests/generic_gpio_liblocal.c | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/tests/generic_gpio_liblocal.c b/tests/generic_gpio_liblocal.c index 9cce190e0d..6fd1d24570 100644 --- a/tests/generic_gpio_liblocal.c +++ b/tests/generic_gpio_liblocal.c @@ -271,7 +271,7 @@ int gpiod_line_request_get_values( return -1; } for(i=0; i Date: Mon, 9 Feb 2026 10:54:27 +0100 Subject: [PATCH 8/9] docs/download.txt: link to "Finding recent development iteration artifacts" wiki page Signed-off-by: Jim Klimov --- docs/download.txt | 10 +++++++--- 1 file changed, 7 insertions(+), 3 deletions(-) diff --git a/docs/download.txt b/docs/download.txt index a1357f85de..74e1cb8155 100644 --- a/docs/download.txt +++ b/docs/download.txt @@ -79,9 +79,13 @@ workspace to try subsequent iterations), although the latter are now also available for development iterations. See the live Wiki article on -https://github.com/networkupstools/nut/wiki/Building-NUT-for-in%E2%80%90place-upgrades-or-non%E2%80%90disruptive-tests -for latest suggestions for building, testing and installing the latest -NUT code base. +link:https://github.com/networkupstools/nut/wiki/Building-NUT-for-in%E2%80%90place-upgrades-or-non%E2%80%90disruptive-tests[Building +NUT for in-place upgrades or non-disruptive tests] +for the most up-to-date suggestions for building, testing and installing +the latest (or experimental) revisions of the NUT code base, and +link:https://github.com/networkupstools/nut/wiki/Finding-recent-development-iteration-artifacts[Finding +recent development iteration artifacts] about fetching the results of +the hard work done by the NUT CI farm. Code repository ^^^^^^^^^^^^^^^ From 6ebc852d5f5c498952af0503a3e87a8b98367e49 Mon Sep 17 00:00:00 2001 From: Jim Klimov Date: Mon, 9 Feb 2026 10:58:41 +0100 Subject: [PATCH 9/9] clients/upsclient.c: fix void* casting for a NSS build [#3311] Signed-off-by: Jim Klimov --- clients/upsclient.c | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/clients/upsclient.c b/clients/upsclient.c index 1d4851f18e..63bbc7051e 100644 --- a/clients/upsclient.c +++ b/clients/upsclient.c @@ -501,7 +501,7 @@ int upscli_init(int certverify, const char *certpath, void upscli_add_host_cert(const char* hostname, const char* certname, int certverify, int forcessl) { #ifdef WITH_NSS - HOST_CERT_t* cert = xmalloc(sizeof(HOST_CERT_t)); + HOST_CERT_t* cert = (HOST_CERT_t *)xmalloc(sizeof(HOST_CERT_t)); cert->next = first_host_cert; cert->host = xstrdup(hostname); cert->certname = xstrdup(certname);