cURL / Mailing Lists / curl-users / Single Mail

curl-users

Re: Metalink support patch for curl

From: Tatsuhiro Tsujikawa <tatsuhiro.t_at_gmail.com>
Date: Sun, 1 Jul 2012 16:35:50 +0900

On Sat, Jun 30, 2012 at 9:33 PM, Tatsuhiro Tsujikawa
<tatsuhiro.t_at_gmail.com> wrote:
> On Sat, Jun 30, 2012 at 3:17 AM, Yang Tse <yangsita_at_gmail.com> wrote:
>> Tatsuhiro Tsujikawa <tatsuhiro.t_at_gmail.com> wrote:
>>
>>> My understanding is that we need version check API, say,
>>> metalink_check_version in libmetalink
>>
>> Yes something like the function you mention, that returns
>> libmetalink's major, minor and patch version numbers for code calling
>> said function. I'm mentioning that version scheme given that it is the
>> one already used in libmetalink.pc.
>>
>>> and do runtime version check
>>> from curl code invoking the new API. Is it correct?
>>
>> Yes. libmetalink run-time version check only needs to be done in curl
>> when option --metalink is used. In case version numbers are lower than
>> some specific version then curl should abort right away.
>>
>
> I added metalink_check_version function for this purpose.
> The attached patch 0002 adds the code which invokes the function when
> --metalink is used. If version requirement is not satisfied, abort the
> program.
>
> In libmetalink, I added new include file metalink/metalink.h which
> includes all header files of public libmetalink headers. The patch
> 0001 makes use of it instead of including individual header file.
>
> I also updated filename check function in libmetalink so that test2017
> to 2022 pass.
>

I updated patch 0002. In this update, I use metalink_get_version to
get major, minor and patch version of libmetalink and do comparison
in curl.
Patch attached.

Best regards,

Tatsuhiro Tsujikawa

> Best regards,
>
> Tatsuhiro Tsujikawa
>
>> Thanks,
>> --
>> -=[Yang]=-
>> -------------------------------------------------------------------
>> List admin: http://cool.haxx.se/list/listinfo/curl-users
>> FAQ: http://curl.haxx.se/docs/faq.html
>> Etiquette: http://curl.haxx.se/mail/etiquette.html

-------------------------------------------------------------------
List admin: http://cool.haxx.se/list/listinfo/curl-users
FAQ: http://curl.haxx.se/docs/faq.html
Etiquette: http://curl.haxx.se/mail/etiquette.html

Received on 2012-07-01