Subject: Re: [PATCH] ares_parse_txt_reply: add `record_start` field

Re: [PATCH] ares_parse_txt_reply: add `record_start` field

From: Daniel Stenberg <daniel_at_haxx.se>
Date: Thu, 28 Jan 2016 16:12:11 +0100 (CET)

On Thu, 28 Jan 2016, David Drysdale wrote:

> Personally, I'd lean towards not including the age / reserved extension
> mechanism. None of the other structures that describe particular resource
> records have it, and the first/rest marker is just an accidental omission
> from the TXT structure, so just having a new, complete, structure seems
> sensible.

> However, I'm happy to defer to Daniel's opinion, so I'd suggest leaving
> as-is for now.

I think I'm inclined to agree with you David. No other funtion has such a
mechanism so it'll just stand out as a weird anomaly. Even though I may have
introduced that thought previously in this thread, I don't think I'm liking it
very much here. Let's make an effort to make clean and understandable function
APIs and we deprecate (primarily by documenting that fact) those that we
replace with better ones.

Then at some point in time we can just cut out the old ones and release c-ares
version 2 without the old cruft.

> - ares_data.c:163: I like to add a /* FALLTHROUGH */ comment for
> deliberate
> case fall through (I have a vague memory that it shuts up some lint
> warning too).

Yes, for example: without that comment the Coverity scanner will warn for it.

-- 
  / daniel.haxx.se
Received on 2016-01-28