mirror of
https://github.com/curl/curl.git
synced 2026-07-10 16:27:17 +03:00
tidy-up: syntax and code nits
- cmp-pkg-config.sh: replace `-r -f` with `-rf` to match rest of repo. - configure.ac: add double quotes for robustness (not a bug). - curl-openssl.m4: merge nested `if`s. - CurlTests.c: drop `!= 0`, also to sync with m4. - CurlTests.c: replace `example.com` with `localhost` in `gethostbyname()` feature test code. (compile-only, not a bug) - GHA/http3-linux: drop literal `true` from bool expression. - lib650: drop redundant `&`. - move variable/call to left-hand side of equality checks, where missing. - perl: detach `<`/`>` from filename in `open()`, where missing. - schannel: apply two nit fixes lost in rebase. - scripts/verify-release: drop redundant double quotes. - scripts/verify-release: exit with error code on error. - synctime: replace magic numbers with `sizeof()`. - telnet: add missing parentheses to macro value. - tests/Makefile.am: use single quotes. - tool_operate: drop redundant `break` after `return` in VMS code. - unit2413: drop unused NULL pointer + free call. - unit2413: fix duplicate test case name. - urlapi: drop redundant parentheses. - urlapi: drop `CURL_UNCONST()` that became redundant. Closes #22186
This commit is contained in:
parent
a36384ab94
commit
84c5dcdb05
31 changed files with 100 additions and 102 deletions
4
.github/scripts/cmp-config.pl
vendored
4
.github/scripts/cmp-config.pl
vendored
|
|
@ -105,7 +105,7 @@ sub grepit {
|
|||
my ($input, $output) = @_;
|
||||
my @defines;
|
||||
# first get all the #define lines
|
||||
open(F, "<$input");
|
||||
open(F, "<", $input);
|
||||
while(<F>) {
|
||||
if($_ =~ /^#def/) {
|
||||
chomp;
|
||||
|
|
@ -114,7 +114,7 @@ sub grepit {
|
|||
}
|
||||
close(F);
|
||||
|
||||
open(O, ">$output");
|
||||
open(O, ">", $output);
|
||||
|
||||
# output the sorted list through the filter
|
||||
foreach my $d(sort @defines) {
|
||||
|
|
|
|||
2
.github/scripts/cmp-pkg-config.sh
vendored
2
.github/scripts/cmp-pkg-config.sh
vendored
|
|
@ -44,6 +44,6 @@ am=$(mktemp -t autotools.XXX); sort_lists "$1" > "${am}"
|
|||
cm=$(mktemp -t cmake.XXX) ; sort_lists "$2" > "${cm}"
|
||||
diff -u "${am}" "${cm}"
|
||||
res="$?"
|
||||
rm -r -f "${am}" "${cm}"
|
||||
rm -rf "${am}" "${cm}"
|
||||
|
||||
exit "${res}"
|
||||
|
|
|
|||
4
.github/scripts/verify-synopsis.pl
vendored
4
.github/scripts/verify-synopsis.pl
vendored
|
|
@ -45,8 +45,8 @@ sub extract {
|
|||
my $syn = 0;
|
||||
my $l = 0;
|
||||
my $iline = 0;
|
||||
open(F, "<$f");
|
||||
open(O, ">$cfile");
|
||||
open(F, "<", $f);
|
||||
open(O, ">", $cfile);
|
||||
while(<F>) {
|
||||
$iline++;
|
||||
if(/^# SYNOPSIS/) {
|
||||
|
|
|
|||
2
.github/workflows/http3-linux.yml
vendored
2
.github/workflows/http3-linux.yml
vendored
|
|
@ -219,7 +219,7 @@ jobs:
|
|||
run: echo 'needs-build=true' >> "$GITHUB_OUTPUT"
|
||||
|
||||
- name: 'install build prereqs'
|
||||
if: ${{ steps.settings.outputs.needs-build == 'true' }}
|
||||
if: ${{ steps.settings.outputs.needs-build }}
|
||||
timeout-minutes: 2
|
||||
run: |
|
||||
sudo find /etc/apt/sources.list.d -type f -not -name 'ubuntu.sources' -delete -print
|
||||
|
|
|
|||
Loading…
Add table
Add a link
Reference in a new issue