Return-Path: X-Original-To: apmail-jackrabbit-dev-archive@www.apache.org Delivered-To: apmail-jackrabbit-dev-archive@www.apache.org Received: from mail.apache.org (hermes.apache.org [140.211.11.3]) by minotaur.apache.org (Postfix) with SMTP id AD0618F82 for ; Fri, 12 Aug 2011 11:44:59 +0000 (UTC) Received: (qmail 22829 invoked by uid 500); 12 Aug 2011 11:44:59 -0000 Delivered-To: apmail-jackrabbit-dev-archive@jackrabbit.apache.org Received: (qmail 22553 invoked by uid 500); 12 Aug 2011 11:44:51 -0000 Mailing-List: contact dev-help@jackrabbit.apache.org; run by ezmlm Precedence: bulk List-Help: List-Unsubscribe: List-Post: List-Id: Reply-To: dev@jackrabbit.apache.org Delivered-To: mailing list dev@jackrabbit.apache.org Received: (qmail 22545 invoked by uid 99); 12 Aug 2011 11:44:49 -0000 Received: from athena.apache.org (HELO athena.apache.org) (140.211.11.136) by apache.org (qpsmtpd/0.29) with ESMTP; Fri, 12 Aug 2011 11:44:49 +0000 X-ASF-Spam-Status: No, hits=-2000.8 required=5.0 tests=ALL_TRUSTED,RP_MATCHES_RCVD X-Spam-Check-By: apache.org Received: from [140.211.11.116] (HELO hel.zones.apache.org) (140.211.11.116) by apache.org (qpsmtpd/0.29) with ESMTP; Fri, 12 Aug 2011 11:44:47 +0000 Received: from hel.zones.apache.org (hel.zones.apache.org [140.211.11.116]) by hel.zones.apache.org (Postfix) with ESMTP id 21E6CB9A0B for ; Fri, 12 Aug 2011 11:44:27 +0000 (UTC) Date: Fri, 12 Aug 2011 11:44:27 +0000 (UTC) From: "David Buchmann (JIRA)" To: dev@jackrabbit.apache.org Message-ID: <1830198732.32928.1313149467135.JavaMail.tomcat@hel.zones.apache.org> Subject: [jira] [Created] (JCR-3050) NullPointerException on removing a node acquired from search result MIME-Version: 1.0 Content-Type: text/plain; charset=utf-8 Content-Transfer-Encoding: 7bit X-JIRA-FingerPrint: 30527f35849b9dde25b450d4833f0394 NullPointerException on removing a node acquired from search result ------------------------------------------------------------------- Key: JCR-3050 URL: https://issues.apache.org/jira/browse/JCR-3050 Project: Jackrabbit Content Repository Issue Type: Bug Reporter: David Buchmann with a code snipped like the following, i get a NullPointerException in ItemState: Session s = repo.login(sc,workspace); QueryManager qm = s.getWorkspace().getQueryManager(); Query q = qm.createQuery("SELECT * FROM [nt:unstructured]", Query.JCR_SQL2); QueryResult r = q.execute(); NodeIterator i = r.getNodes(); Node n = i.nextNode(); n.remove(); // breaks here with NullPointerException Exception in thread "main" java.lang.NullPointerException at org.apache.jackrabbit.jcr2spi.state.ItemState.getParent(ItemState.java:210) at org.apache.jackrabbit.jcr2spi.operation.Remove.create(Remove.java:98) at org.apache.jackrabbit.jcr2spi.ItemImpl.remove(ItemImpl.java:306) -- This message is automatically generated by JIRA. For more information on JIRA, see: http://www.atlassian.com/software/jira