From: Vlad S. <vl...@cr...> - 2006-09-23 21:39:54
|
tclxkeylist.c is the place where i see a lot of such usage Zoran Vasiljevic wrote: > Hi! > > As I expected... > > Begin forwarded message: > >> From: Joe English <jen...@fl...> >> Date: 23. September 2006 19:15:35 MESZ >> To: Tcl Core List <tcl...@li...> >> Subject: Re: [TCLCORE] Can Tcl_GetObjResult() return shared object? >> >> >> Zoran Vasiljevic wrote: >>> I'm not sure about that, but I had a couple of issues >>> which I can only track to the above being true >>> (not 100% confirmed but I suspect seriously). >>> >>> Is/can that be true? >> Yes, that's definitely true. Tcl_GetObjResult() *can* return >> a shared object. >> >>> If yes, one should avoid constructs like: >>> >>> Tcl_SetStringObj(Tcl_GetObjResult(interp), thestring, >>> stringlength); >> Yes, one should absolutely avoid such constructs. >> It can lead to Tcl_Panic()s when you least expect them. >> >> There used to be a number of them in the core, specifically >> the idiom: >> >> Tcl_AppendToObj(Tcl_GetObjResult(interp), ...); >> >> as a replacement for Tcl_AppendResult(). Fortunately most of >> these have been fixed by now. >> >>> and use: >>> >>> Tcl_SetObjResult(interp, Tcl_NewStringObj(thestring, >>> stringlength)); >>> >>> instead [...]? >> Yes, do that instead. >> >> >> --Joe English >> >> ---------------------------------------------------------------------- >> --- >> Take Surveys. Earn Cash. Influence the Future of IT >> Join SourceForge.net's Techsay panel and you'll get the chance to >> share your >> opinions on IT & business topics through brief surveys -- and earn >> cash >> http://www.techsay.com/default.php? >> page=join.php&p=sourceforge&CID=DEVDEV >> _______________________________________________ >> Tcl-Core mailing list >> Tcl...@li... >> https://lists.sourceforge.net/lists/listinfo/tcl-core > > > ------------------------------------------------------------------------- > Take Surveys. Earn Cash. Influence the Future of IT > Join SourceForge.net's Techsay panel and you'll get the chance to share your > opinions on IT & business topics through brief surveys -- and earn cash > http://www.techsay.com/default.php?page=join.php&p=sourceforge&CID=DEVDEV > _______________________________________________ > naviserver-devel mailing list > nav...@li... > https://lists.sourceforge.net/lists/listinfo/naviserver-devel > -- Vlad Seryakov 571 262-8608 office vl...@cr... http://www.crystalballinc.com/vlad/ |