[PATCH] setup: fix handling of -X.Y releases
Corinna Vinschen
corinna-cygwin@cygwin.com
Tue Dec 9 10:34:00 GMT 2014
On Dec 8 16:03, Yaakov Selkowitz wrote:
> The attached patch should fix the reported issue with handling of packages
> with -X.Y release numbers.
>
>
> Yaakov
> 2014-12-08 Yaakov Selkowitz <yselkowitz@...>
>
> * package_source.cc (packagesource::set_canonical): Fix handling
> of package release number containing a period.
>
> Index: package_source.cc
> ===================================================================
> RCS file: /cvs/cygwin-apps/setup/package_source.cc,v
> retrieving revision 2.10
> diff -u -p -r2.10 package_source.cc
> --- package_source.cc 17 Apr 2006 16:13:17 -0000 2.10
> +++ package_source.cc 8 Dec 2014 21:43:15 -0000
> @@ -52,9 +52,9 @@ packagesource::set_canonical (char const
> while (bend && (tmp = strchr (bend + 1, '-')))
> bend = tmp;
> if (bend)
> - bend = strchr (bend, '.');
> + bend = strstr (bend, ".tar");
> else
> - bend = strchr (bstart, '.');
> + bend = strstr (bstart, ".tar");
>
> if (!bend)
> bend = strchr (bstart, '\0');
That's the only change necessary to fix this? Nice. Would it make
sense to extend the search string to ".tar." (trailing dot) to make
sure we're really hitting the suffix? Or does the above code have
to take non-compressed tar archive names into account?
Corinna
--
Corinna Vinschen Please, send mails regarding Cygwin to
Cygwin Maintainer cygwin AT cygwin DOT com
Red Hat
-------------- next part --------------
A non-text attachment was scrubbed...
Name: not available
Type: application/pgp-signature
Size: 819 bytes
Desc: not available
URL: <http://cygwin.com/pipermail/cygwin-apps/attachments/20141209/82b976c3/attachment.sig>
More information about the Cygwin-apps
mailing list