Rainer Müller wrote on Wed, Nov 02, 2016 at 18:29:04 +0100:
> Index: subversion/bindings/swig/perl/libsvn_swig_perl/swigutil_pl.c
> ===================================================================
> --- subversion/bindings/swig/perl/libsvn_swig_perl/swigutil_pl.c      
> (revision 1767623)
> +++ subversion/bindings/swig/perl/libsvn_swig_perl/swigutil_pl.c      
> (working copy)
> @@ -470,9 +470,11 @@ svn_opt_revision_t *svn_swig_pl_set_revision(svn_o
>              if (!end)
>                  maybe_croak(("unknown opt_revision_t string \"%s\": "
>                               "missing closing brace for \"{DATE}\"", input));
> +            char saved = *end;

Do the perl bindings use C89, like libsvn*?  C89 forbids middle-of-block
declarations.

>              *end = '\0';
>              err = svn_parse_date (&matched, &tm,
>                                    input + 1, apr_time_now(), pool);
> +            *end = saved;

The two maybe_croak() calls after this line (one of them in the patch
context, one just below it) would now print two right braces.

>              if (err) {
>                  svn_error_clear (err);
>                  maybe_croak(("unknown opt_revision_t string \"{%s}\": "

Thanks for the patch and log message.  I can't easily test it, but
I think it's correct, modulo the two trivial points above.

Cheers,

Daniel

Reply via email to