[Top][All Lists]

[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]

[Bug-jwhois] code in jwhois.c

From: Alessandro Spinella (Consulente)
Subject: [Bug-jwhois] code in jwhois.c
Date: Mon, 6 Nov 2017 09:59:08 +0000


looking inside the code have found

jwhois_query(struct s_whois_query *wq, char **text)
if ( (tmp && 0 == strcasecmp(tmp, "true")) || rwhois )
if (tmp2 && 0 == strcasecmp(tmp2, "true"))

that I feel

1) is NOT minimal (anything logical-anded-with zero will result in zero)

2) is even NOT the most readable form (lack of braces around first opreand)

3) moreover, while rwhois is a function with int prototype (as in rwhois.h), 
feel much clear the use of "complete" string : rwhois()

best regards and many thanks for the code; am planning to

a) move the cache into RAM

b) daemonize the progam

to use it as "buffer" for local high rate queries coming from other daemons.

Alessandro Spinella
DRBC - Disaster Recovery e Business Continuity
Tel. : 3476518283
e-mail: address@hidden
e-mail di gruppo: address@hidden
Il contenuto e le informazioni di questo messaggio di posta elettronica sono 
riservate, confidenziali e non vincolanti nè impegnative per Cedacri s.p.a., ne 
è vietata pertanto la diffusione o divulgazione in qualunque modo eseguita. 
Qualora Lei non fosse la persona a cui il presente messaggio è destinato La 
invitiamo ad eliminarlo e a non leggerlo, dandocene gentilmente comunicazione. 
The content, informations and any attachments of this e-mail are classified, 
confidential and not binding neither impegnative for Cedacri S.P.A., the spread 
or spreading in any executed way is prohibited therefore. If you are not named 
recipient, please notify the sender immediately and do not disclose the 
contents to another person, use it for any purpose, or store or copy the 
information in any medium.

reply via email to

[Prev in Thread] Current Thread [Next in Thread]