Revision 20367 trunk/libraries/libjni-gdal/src/main/java/org/gvsig/jogr/OGRGeometryCollection.java

View differences:

OGRGeometryCollection.java
72 72
	 * Destructor 
73 73
	 */
74 74
	
75
	protected void finalize(){
76
		if(cPtr > 0)
77
			FreeOGRGeometryCollectionNat(cPtr);
75
	protected void finalize() throws OGRFailureException{
76
		if(cPtr == 0)
77
			throw new OGRFailureException("Fallo al acceder al dato.");
78
		
79
		FreeOGRGeometryCollectionNat(cPtr);
78 80
	}
79 81
	 
80 82
	 // Non standard (OGRGeometry).

Also available in: Unified diff