Commit Graph

34505 Commits

Author SHA1 Message Date
Viktor Szakats
0d03d7dd09
server: drop two util macros 2025-02-28 17:32:54 +01:00
Viktor Szakats
bbb355f08f
server: drop perror redefine (win32) 2025-02-28 17:32:54 +01:00
Viktor Szakats
84b5f742c1
server: drop sleep macro 2025-02-28 17:32:54 +01:00
Viktor Szakats
3cd6697f2b
mk-bundle-server.pl: handle DEFAULT_CONFIG 2025-02-28 17:32:53 +01:00
Viktor Szakats
3828693f54
make resolve part of the bundle again
Reverts 794642707bbd826161d973a6b62a9d63fb02672f
2025-02-28 17:32:53 +01:00
Viktor Szakats
7bd7628a76
exclude resolve 2025-02-28 17:32:53 +01:00
Viktor Szakats
327428f2af
Revert "disable server bundles (temp)"
This reverts commit 8732f9e38f3b3cb0f303316ea032ea8966a98bd1.
2025-02-28 17:32:53 +01:00
Viktor Szakats
7a74b8ef0f
disable server bundles (temp) 2025-02-28 17:32:53 +01:00
Viktor Szakats
9a89967ad7
do not checksrc generated bundle source 2025-02-28 17:32:53 +01:00
Viktor Szakats
bbbdc2c2f3
add to .gitignore 2025-02-28 17:32:53 +01:00
Viktor Szakats
52ca8acc29
fixup autotools options 2025-02-28 17:32:53 +01:00
Viktor Szakats
2573209213
fixup for cmakelint 2025-02-28 17:32:53 +01:00
Viktor Szakats
8fb6235052
fix to include inet_pton 2025-02-28 17:32:53 +01:00
Viktor Szakats
5a5903a58f
fix undefined sclose() in util.c 2025-02-28 17:32:52 +01:00
Viktor Szakats
e5351b607b
blind fix for double declarations
https://github.com/curl/curl/actions/runs/10801770763/job/29962562524?pr=14772#step:22:16
2025-02-28 17:32:52 +01:00
Viktor Szakats
bde9c60f9b
fixup socket_domain differently, drop unused enum type' 2025-02-28 17:32:52 +01:00
Viktor Szakats
8cfde049ed
mk-bundle-server.pl: avoid collision 2025-02-28 17:32:52 +01:00
Viktor Szakats
2cc6aee8b7
keep resolve tool out of servers
Reason is that it's called from data/test* modules where conditionally
executing either `server/servers disabled` or `server/disabled`
depending on build settings would be problematic.
2025-02-28 17:32:52 +01:00
Viktor Szakats
fbb12eb612
reshuffle first.c use 2025-02-28 17:32:52 +01:00
Viktor Szakats
a695a2141c
my_connectport -> server_connectport 2025-02-28 17:32:52 +01:00
Viktor Szakats
0c4bb05f23
checksrc, build fixups 2025-02-28 17:32:52 +01:00
Viktor Szakats
1b075c7954
fix shadowed variable 2025-02-28 17:32:52 +01:00
Viktor Szakats
f18435b334
sort 2025-02-28 17:32:51 +01:00
Viktor Szakats
4b90317428
server: my_port -> server_port 2025-02-28 17:32:51 +01:00
Viktor Szakats
c46a02c514
fixup serverlogfile 2025-02-28 17:32:51 +01:00
Viktor Szakats
0fe9325541
decollision 2025-02-28 17:32:51 +01:00
Viktor Szakats
052a48ac2d
my_port 2025-02-28 17:32:51 +01:00
Viktor Szakats
d4b6613910
runtests: use bundled server
add server_prog helper

use server_prog()

fixups

fix imports

server_prog -> server_exe

move server_exe to serverhelp.pm

fix typo

delete unused exe_ext imports

serverhelp.pm: autodetect server bundle

try fix for Windows

debug 3

runtests cleanups

runtests cleanups 2

cleanups

drop server_exe log

try fixing ftp server invocations 1
2025-02-28 17:32:51 +01:00
Viktor Szakats
02cf354243
add first.c, first.h to dist 2025-02-28 17:32:51 +01:00
Viktor Szakats
2697c0e1e2
add first.h, first.c 2025-02-28 17:32:51 +01:00
Viktor Szakats
f02a68ffb0
util.c: fix shadowed variable 2025-02-28 17:32:51 +01:00
Viktor Szakats
c62788c846
autotools: add server support 2025-02-28 17:32:50 +01:00
Viktor Szakats
a9dfcf4e8d
cmake support 2025-02-28 17:32:50 +01:00
Viktor Szakats
c532c8eb3a
add server bundler
mk-bundle-server.pl: add .c extension if missing

mk-bundle-server.pl: fixup/simplify
2025-02-28 17:32:50 +01:00
Viktor Szakats
05e745c656
move definition to util.h 2025-02-28 17:32:50 +01:00
Viktor Szakats
e7751571eb
GHA/macos: use quictls in some jobs, other small improvements
- enable quictls in autotools and cmake jobs. autotools requires
  a workaround due to wrong libpath in the quictls pkg-config.
  nghttp3 is offered by Homebrew, but not ngtcp2, to enable H3.

- install `libnghttp2` rather than `nghttp2`.
  `libnghttp2` is preinstalled and smaller. It also avoids detecting
  `nghttpx`, which confuses `pytest`.

- limit `brew unlink openssl` to libressl/quictls jobs.

Closes #16517
2025-02-28 16:58:12 +01:00
Zhaoming Luo
7211576442
tests: fix comment in lib533
Closes #16523
2025-02-28 16:12:20 +01:00
Stefan Eissing
794dfe7fc4
gnutls: fix use of pkcs11 urls for keys/certs
Fixes #16249
Forwarded-to-us-by: Carlos Henrique Lima Melara

Always use `gnutls_certificate_set_x509_key_file2()` for loading keys
and certificates, even without a password, since this function support
pkcs11 urls.

Thanks to @tatsuhiro-t for finding this out.
Help-by: Tatsuhiro Tsujikawa

Closes #16472
2025-02-28 16:08:10 +01:00
Viktor Szakats
049352dd80
cmake: allow CURL_STATIC_CRT with shared libcurl and no curl exe
Follow-up to edfa537100 #16456

Closes #16516
2025-02-28 13:11:41 +01:00
Viktor Szakats
08c7c937dc
tidy-up: prefer return over exit(), fix fallouts
To avoid breaking the control flow and align to majority of code
already using `return`.

`exit()` has the side-effect of suppressing leak detection in cases.
Fix fallouts detected after switching to `return`.

- configure:
  - fix `getaddrinfo` run test to call `freeaddrinfo()` to pacify ASAN,
    and call `WSACleanup()` to deinit winsock2.
  - fix `getifaddrs` run test to call `freeifaddrs()` to pacify ASAN.
- tests/server:
  - setup `atexit(win32_cleanup)` via `win32_init()`.
  - return 2 instead of 1 on winsock2 init failures.
  - sws: goto cleanup instead of `exit()` in `http_connect()`.
    Follow-up to 02dfe71937 #7235
- tests/client/http:
  - cleanup memory to pacify ASAN in `h2-upgrade-extreme`,
    `tls-session-reuse`.
- examples:
  - block_ip: fix memory leak reported by CI.
  - http2-upload: avoid handle leaks.

Untouched `exit()` calls, made from callbacks:
- docs/examples: ephiperfifo.c, ghiper.c, hiperfifo.c
- tests/libtest: lib582.c, lib655.c, lib670.c
- tests/server: tftpd.c

Closes #16507
2025-02-28 13:11:41 +01:00
Stefan Eissing
2e585f5640
test488: set --output-dir
Otherwise the downloaded files land in the `tests` directory and
show up in git status.

Closes #16519
2025-02-28 12:47:31 +01:00
Viktor Szakats
399cb7130a
cmake: drop HAVE_C_FLAG_Wno_long_double logic for ancient Apple gcc
The initial curl CMake commit introduced it in 2009-04-02 via
4c5307b456. Suppressing a stray
`-Wlong-double` warning in `mprintf.c`. This was before Apple switched
to clang, and likely affected the Apple distributed GCC, version 4.2.1
at the time. It applied the workaround to CMake builds only, though
the issue seems build-tool agnostic. Yet, it was not suppressed or
reported for autotools builds.

For these reasons this logic seems obsolete and this patch drops it with
no replacement. It saves a feature detection for GCC builds for macOS.

In PR sub-commits I added (and reverted) in-source suppression. In case
it becomes necessary, that should fix it for all build tools.

Closes #16513
2025-02-28 03:40:40 +01:00
Viktor Szakats
5a021aba41
cmake: improve httpd detection for pytest
Look for `httpd` in addition to `apache2`, like `./configure` does.
It fixes detection with macOS Homebrew for example.

Closes #16515
2025-02-28 03:40:40 +01:00
Viktor Szakats
6913c9b6ab
GHA/linux: improve 'test configs' step, don't set TFLAGS for pytest
- omit comments from th config dump, show filenames for each line.
- `TFLAGS` is not used by pytest, don't set it.

Closes #16514
2025-02-28 03:40:40 +01:00
Daniel Stenberg
953cd694dc
asyn-ares: use the correct port number
Only triggers with old c-ares versions.

Follow-up to 8ded8e5f3f

Closes #16511
2025-02-27 22:18:43 +01:00
Viktor Szakats
af6172c8f2
GHA/linux: merge two package install steps
Merge pytest prereq package install step into the main package install
step, to save install time.

Closes #16509
2025-02-27 20:32:50 +01:00
Daniel Stenberg
8ded8e5f3f
urldata: remove 'hostname' from struct Curl_async
It is unnecessary duplicated information, as the host name being
resolved is already present in conn->host.

Closes #16451
2025-02-27 17:18:43 +01:00
Daniel Stenberg
7007f59caa
GHA: spellcheck curl symbols better
This now makes sure to trim off exact matches for curl symbols and long
curl commanad line options instead of using pattern matching as before.
This should catch typoed names (that still follow the pattern) better.

The cleanspell.pl script is no longer used. cleancmd.pl is used for all
markdown files.

Closes #16504
2025-02-27 13:15:21 +01:00
Daniel Stenberg
a8ad9a5758
docs: minor edits to please the new spellchecker regime 2025-02-27 13:15:21 +01:00
Viktor Szakats
cba83bfb10
runtests: accept CURL_DIRSUFFIX without ending slash
Follow-up to 3585796049 #16452
Closes #16506
2025-02-27 12:11:23 +01:00