You are viewing a plain text version of this content. The canonical link for it is here.
Posted to commits@subversion.apache.org by rh...@apache.org on 2010/06/07 22:35:55 UTC

svn commit: r952421 - /subversion/trunk/subversion/bindings/javahl/native/CreateJ.cpp

Author: rhuijben
Date: Mon Jun  7 20:35:54 2010
New Revision: 952421

URL: http://svn.apache.org/viewvc?rev=952421&view=rev
Log:
Following up on r952416, fix the javahl build.

* subversion/bindings/javahl/native/CreateJ.cpp
  (CreateJ::Status): Fetch entry to keep old code working.

Modified:
    subversion/trunk/subversion/bindings/javahl/native/CreateJ.cpp

Modified: subversion/trunk/subversion/bindings/javahl/native/CreateJ.cpp
URL: http://svn.apache.org/viewvc/subversion/trunk/subversion/bindings/javahl/native/CreateJ.cpp?rev=952421&r1=952420&r2=952421&view=diff
==============================================================================
--- subversion/trunk/subversion/bindings/javahl/native/CreateJ.cpp (original)
+++ subversion/trunk/subversion/bindings/javahl/native/CreateJ.cpp Mon Jun  7 20:35:54 2010
@@ -567,9 +567,18 @@ CreateJ::Status(svn_wc_context_t *wc_ctx
       if (JNIUtil::isJavaExceptionThrown())
         POP_AND_RETURN_NULL;
 
-      const svn_wc_entry_t *entry = status->entry;
+      const svn_wc_entry_t *entry = NULL;
+
+      if (status->versioned)
+        /* ### This doesn't set enty when _get_entry returns 
+           ### SVN_ERR_NODE_UNEXPECTED_KIND! */
+        SVN_JNI_ERR(svn_wc__get_entry_versioned(&entry, wc_ctx, local_abspath,
+                                                svn_node_unknown, FALSE, FALSE,
+                                                pool, pool));
+
       if (entry != NULL)
         {
+          /* ### Some of these values are also available in status */
           jNodeKind = EnumMapper::mapNodeKind(entry->kind);
           jRevision = entry->revision;
           jLastChangedRevision = entry->cmt_rev;



Re: svn commit: r952421 - /subversion/trunk/subversion/bindings/javahl/native/CreateJ.cpp

Posted by Greg Stein <gs...@gmail.com>.
On Mon, Jun 7, 2010 at 16:35,  <rh...@apache.org> wrote:
>...
> Modified: subversion/trunk/subversion/bindings/javahl/native/CreateJ.cpp
> URL: http://svn.apache.org/viewvc/subversion/trunk/subversion/bindings/javahl/native/CreateJ.cpp?rev=952421&r1=952420&r2=952421&view=diff
> ==============================================================================
> --- subversion/trunk/subversion/bindings/javahl/native/CreateJ.cpp (original)
> +++ subversion/trunk/subversion/bindings/javahl/native/CreateJ.cpp Mon Jun  7 20:35:54 2010
> @@ -567,9 +567,18 @@ CreateJ::Status(svn_wc_context_t *wc_ctx
>       if (JNIUtil::isJavaExceptionThrown())
>         POP_AND_RETURN_NULL;
>
> -      const svn_wc_entry_t *entry = status->entry;
> +      const svn_wc_entry_t *entry = NULL;
> +
> +      if (status->versioned)
> +        /* ### This doesn't set enty when _get_entry returns
> +           ### SVN_ERR_NODE_UNEXPECTED_KIND! */
> +        SVN_JNI_ERR(svn_wc__get_entry_versioned(&entry, wc_ctx, local_abspath,
> +                                                svn_node_unknown, FALSE, FALSE,
> +                                                pool, pool));

Hunh? entry IS set when that error is returned. (and a typo)

Given the above parameters, you'll get UNEXPECTED_KIND if the subdir
is missing/obstructed. The entry will contain the parent stub (yet you
asked for the "real" entry).

>...

Cheers,
-g