On Mon, Jun 11, 2012 at 11:33 AM,  <i...@apache.org> wrote:
> Author: ivan
> Date: Mon Jun 11 09:33:36 2012
> New Revision: 1348770
>
> URL: http://svn.apache.org/viewvc?rev=1348770&view=rev
> Log:
> Fix compiler warning.
>
> * subversion/libsvn_subr/pool.c
>  (abort_on_pool_failure): Add return statement to make compiler happy.
>
> Modified:
>    subversion/trunk/subversion/libsvn_subr/pool.c
>
> Modified: subversion/trunk/subversion/libsvn_subr/pool.c
> URL: 
> http://svn.apache.org/viewvc/subversion/trunk/subversion/libsvn_subr/pool.c?rev=1348770&r1=1348769&r2=1348770&view=diff
> ==============================================================================
> --- subversion/trunk/subversion/libsvn_subr/pool.c (original)
> +++ subversion/trunk/subversion/libsvn_subr/pool.c Mon Jun 11 09:33:36 2012
> @@ -53,6 +53,7 @@ abort_on_pool_failure(int retcode)
>      And we don't have any of it... */
>   printf("Out of memory - terminating application.\n");
>   abort();
> +  return 0; /* not reached */
>  }
>
>

This change actually *adds* the following warning for (clang on Darwin):
[[[
clang: warning: argument unused during compilation: '-no-cpp-precomp'
subversion/libsvn_subr/pool.c:56:10: warning: will never be executed
      [-Wunreachable-code]
  return 0; /* not reached */
         ^
1 warning generated.
]]]

I know this isn't the only place in our code where we have such
constructions.  Can we do something compiler-specific which then
applies to all such places?

-Hyrum


-- 

uberSVN: Apache Subversion Made Easy
http://www.uberSVN.com/

Reply via email to