From: reyuki <reyuki@gnuweeb.org>
To: Alviro Iskandar Setiawan <alviro.iskandar@gnuweeb.org>
Cc: Ammar Faizi <ammarfaizi2@gnuweeb.org>,
"GNU/Weeb Mailing List" <gwml@vger.gnuweeb.org>
Subject: Re: [PATCH gwproxy v2 3/3] dnslookup: Initial work for implementation of C-ares-like getaddrinfo function
Date: Sat, 2 Aug 2025 09:06:34 +0700 [thread overview]
Message-ID: <CAADvAgpnWT4eo9O8TQhEvcffBJAdby9uzbJC8W8JSoo++KW_NQ@mail.gmail.com> (raw)
In-Reply-To: <CAOG64qMMV1F5OnD6wXj+xgmqpn59VagC3gBos5ESO7xRs5Qv7g@mail.gmail.com>
On Sat, Aug 2, 2025 at 8:38 AM Alviro Iskandar Setiawan wrote:
> On Fri, Aug 1, 2025 at 8:55 AM Ahmad Gani wrote:
> > + for (size_t i = 0; i < raw_answ.hdr.ancount; i++) {
>
> Don't declare the variable inside the for loop. Instead, do:
>
> size_t i;
> for (i = 0; i < n; i++) {
> something();
> something();
> something();
> }
>
> Apply that to all others for loops.
Alright, I’ll include your requested changes in the v3 patches, along
with the code updates I'm currently working on related to the asynchronous
behavior of gw_ares_getaddrinfo, which I previously discussed with Sir
Ammar [1].
[1]:
- https://lore.gnuweeb.org/gwml/aIwkO9Aw+IFht0vd@biznet-home.integral.gnuweeb.org/
prev parent reply other threads:[~2025-08-02 2:06 UTC|newest]
Thread overview: 10+ messages / expand[flat|nested] mbox.gz Atom feed top
2025-08-01 1:54 [PATCH gwproxy v2 0/3] Initial work for DNS lookup implementation Ahmad Gani
2025-08-01 1:54 ` [PATCH gwproxy v2 1/3] dnslookup: split common functionality and struct into net.c Ahmad Gani
2025-08-01 23:43 ` Alviro Iskandar Setiawan
2025-08-01 23:45 ` Alviro Iskandar Setiawan
2025-08-02 1:08 ` reyuki
2025-08-02 1:34 ` Alviro Iskandar Setiawan
2025-08-01 1:54 ` [PATCH gwproxy v2 2/3] dnslookup: Allow only port string number Ahmad Gani
2025-08-01 1:54 ` [PATCH gwproxy v2 3/3] dnslookup: Initial work for implementation of C-ares-like getaddrinfo function Ahmad Gani
2025-08-02 1:37 ` Alviro Iskandar Setiawan
2025-08-02 2:06 ` reyuki [this message]
Reply instructions:
You may reply publicly to this message via plain-text email
using any one of the following methods:
* Save the following mbox file, import it into your mail client,
and reply-to-all from there: mbox
Avoid top-posting and favor interleaved quoting:
https://en.wikipedia.org/wiki/Posting_style#Interleaved_style
* Reply using the --to, --cc, and --in-reply-to
switches of git-send-email(1):
git send-email \
--in-reply-to=CAADvAgpnWT4eo9O8TQhEvcffBJAdby9uzbJC8W8JSoo++KW_NQ@mail.gmail.com \
--to=reyuki@gnuweeb.org \
--cc=alviro.iskandar@gnuweeb.org \
--cc=ammarfaizi2@gnuweeb.org \
--cc=gwml@vger.gnuweeb.org \
/path/to/YOUR_REPLY
https://kernel.org/pub/software/scm/git/docs/git-send-email.html
* If your mail client supports setting the In-Reply-To header
via mailto: links, try the mailto: link
Be sure your reply has a Subject: header at the top and a blank line
before the message body.
This is a public inbox, see mirroring instructions
for how to clone and mirror all data and code used for this inbox