You are viewing a plain text version of this content. The canonical link for it is here.
Posted to dev@subversion.apache.org by Blair Zajac <bl...@orcaware.com> on 2006/04/19 23:51:01 UTC

Re: svn commit: r19421 - trunk/tools/hook-scripts

maxb@tigris.org wrote:
> Author: maxb
> Date: Wed Apr 19 14:53:05 2006
> New Revision: 19421
> 
> Modified:
>    trunk/tools/hook-scripts/commit-email.pl.in
> 
> Log:
> Followup to r19342. Correct operator precedence bug in commit-email.pl.
> 
> * tools/hook-scripts/commit-email.pl.in: Insert parentheses to counter
>     unintuitive operator precedence.
> 
> 
> Modified: trunk/tools/hook-scripts/commit-email.pl.in
> URL: http://svn.collab.net/viewvc/svn/trunk/tools/hook-scripts/commit-email.pl.in?pathrev=19421&r1=19420&r2=19421
> ==============================================================================
> --- trunk/tools/hook-scripts/commit-email.pl.in	(original)
> +++ trunk/tools/hook-scripts/commit-email.pl.in	Wed Apr 19 14:53:05 2006
> @@ -504,7 +504,7 @@
>      my $reply_to        = $project->{reply_to};
>      my $subject_prefix  = $project->{subject_prefix};
>      my $subject         = $subject_base;
> -    my $diff_wanted     = $project->{show_diff} and $mode eq 'commit';
> +    my $diff_wanted     = ($project->{show_diff} and $mode eq 'commit');

Not a big deal, but it may be better just to use the && operator instead, which 
has higher precedence and you don't need the ().

Regards,
Blair

---------------------------------------------------------------------
To unsubscribe, e-mail: dev-unsubscribe@subversion.tigris.org
For additional commands, e-mail: dev-help@subversion.tigris.org