On 17.04.2016 19:01, br...@apache.org wrote:
> Author: brane
> Date: Sun Apr 17 17:01:19 2016
> New Revision: 1739632
>
> URL: http://svn.apache.org/viewvc?rev=1739632&view=rev
> Log:
> Silence a -Wswitch warning in the reverse-patch code.
>
> * subversion/libsvn_diff/parse-diff.c (svn_diff_parse_next_patch):
>    Add cases for all enumeration values to the switch statement.
>
> Modified:
>     subversion/trunk/subversion/libsvn_diff/parse-diff.c
>
> Modified: subversion/trunk/subversion/libsvn_diff/parse-diff.c
> URL: 
> http://svn.apache.org/viewvc/subversion/trunk/subversion/libsvn_diff/parse-diff.c?rev=1739632&r1=1739631&r2=1739632&view=diff
> ==============================================================================
> --- subversion/trunk/subversion/libsvn_diff/parse-diff.c (original)
> +++ subversion/trunk/subversion/libsvn_diff/parse-diff.c Sun Apr 17 17:01:19 
> 2016
> @@ -2275,11 +2275,14 @@ svn_diff_parse_next_patch(svn_patch_t **
>              patch->operation = svn_diff_op_added;
>              break;
>  
> -          /* ### case svn_diff_op_copied:
> -             ### case svn_diff_op_moved:*/
> -
>            case svn_diff_op_modified:
> -            break; /* Stays modify */
> +            break; /* Stays modified. */
> +
> +          case svn_diff_op_copied:
> +          case svn_diff_op_moved:
> +            break; /* Stays copied or moved, just in the other direction. */
> +          case svn_diff_op_unchanged:
> +            break; /* Stays unchanged, of course. */
>          }
>  
>        ts_tmp = patch->old_executable_bit;


Bert, I think you wrote the original switch statement. I believe my
change is both correct and a no-op (other than silencing the warning)
but would appreciate a second pair of eyes here.

-- Brane

Reply via email to