[Proj] pj_init_plus allocation question

Mikhail Tchernychev misha at mail.geometrics.com
Mon Feb 28 17:29:10 EST 2011



I am sorry, this is my fault. Thank you for explanation.

Best
Mikhail



On 11-02-28 04:26 PM, Mikhail Tchernychev wrote:

> >      Hello List,
> >
> >  It's just appeared to me that pj_allocation_plus does not allocate new
> >  memory each time it is called. Depending on the projection parameters,
> >  it returns already
> >  allocated structure from the previous call.
> >
> >  It means that there should not be matching pj_free call for each
> >  pj_init_plus.
> >
> >  Is it correct?
> >
> >  What is if two +proj=latlong projections with different parameters are
> >  used in the program?
> >  Would proj_init_plus return the same pointer for both of them?
> >
> >  Shall I keep track of all pj_free_calls myself (and possibly reference
> >  count) to clean up?
> >
> >  Unfortunately I could not search proj mail list - it appeared there is
> >  no option to search.
Mikhail,

The proj list would be a better place for this question.

pj_init_plus() will allocate a new PJ object and there should
be a corresponding pj_free() call for each successful call to
pj_init_plus().

I am not sure what lead you to a different conclusion.

Best regards,
-- 
---------------------------------------+-------------------------------------- 
I set the clouds in motion - turn up | Frank Warmerdam, 
warmerdam at pobox.com light and sound - activate the windows | 
http://pobox.com/~warmerdam and watch the world go round - Rush | 
Geospatial Programmer for Rent 
_______________________________________________ FWTools mailing list 
FWTools at lists.maptools.org 
http://lists.maptools.org/mailman/listinfo/fwtools 
http://fwtools.maptools.org/



<html>
<body>
<FONT face=  "Arial" size=  "-1">
PLEASE NOTE: This message, including any attachments, may 
include privileged, confidential and/or inside information. Any 
dissemination, distribution or copy of this communication by   
anyone other than the intended recipient is strictly 
prohibited. If you are not the intended recipient, please 
notify the sender by replying to this message and then delete 
it from your system. Information provided via electronic media 
is not guaranteed against defects including translation and 
transmission errors. The company accepts no liability for any 
damage caused by any virus transmitted by this email.
  
Geometrics Inc.
2190 Fortune Drive
San Jose, CA 95131 USA
</FONT>
</body>
</html>
-------------- next part --------------
An HTML attachment was scrubbed...
URL: http://lists.maptools.org/pipermail/proj/attachments/20110228/1991b32c/attachment.htm 


More information about the Proj mailing list