<div dir="ltr">More detail.. When this happens, Map is not fully initialized and following Vect_* calls with Map can fail unexpectedly, which caused a segmentation fault in this case.</div><div class="gmail_extra"><br><br>
<div class="gmail_quote">On Fri, May 2, 2014 at 1:15 PM, Huidae Cho <span dir="ltr"><<a href="mailto:grass4u@gmail.com" target="_blank">grass4u@gmail.com</a>></span> wrote:<br><blockquote class="gmail_quote" style="margin:0 0 0 .8ex;border-left:1px #ccc solid;padding-left:1ex">
<div dir="ltr">Segmentation fault when you do v.in.db ... output=a@other_mapset because Vect_open_new returns -1 with a warning, not a fatal error, "unable to create new ... is not the current mapset". I didn't check why it's returning -1 instead of throwing a fatal error in this case. I believe that this warning has to be a fatal error if no modules rely on -1 return.<span class="HOEnZb"><font color="#888888"><div>
<br></div><div>Huidae</div></font></span></div><div class="HOEnZb"><div class="h5"><div class="gmail_extra"><br><br><div class="gmail_quote">On Fri, May 2, 2014 at 12:59 PM, Martin Landa <span dir="ltr"><<a href="mailto:landa.martin@gmail.com" target="_blank">landa.martin@gmail.com</a>></span> wrote:<br>
<blockquote class="gmail_quote" style="margin:0 0 0 .8ex;border-left:1px #ccc solid;padding-left:1ex">Hi,<br>
<br>
2014-05-02 18:53 GMT+02:00 <<a href="mailto:svn_grass@osgeo.org" target="_blank">svn_grass@osgeo.org</a>>:<br>
<div><br>
> - Vect_open_new(&Map, outvect->answer, with_z);<br>
> + if (Vect_open_new(&Map, outvect->answer, with_z) == -1)<br>
> + exit(EXIT_FAILURE);<br>
> +<br>
<br>
</div>please provide more info where it fails. Also note that Vect_open_new<br>
calls G_fatal_error() so the most of modules don't check return code<br>
of this function.<br>
<span><font color="#888888"><br>
Martin<br>
<br>
--<br>
Martin Landa * <a href="http://geo.fsv.cvut.cz/gwiki/Landa" target="_blank">http://geo.fsv.cvut.cz/gwiki/Landa</a><br>
</font></span></blockquote></div><br></div>
</div></div></blockquote></div><br></div>