Hi -- I'm using helgrind from 3.5.0 on OPENMP code.
I have a lazily malloc'd pthread mutex in a static global variable that helgrind detects. I'd like to disable the warning somehow in code, not with a suppression, so that I can look at more interesting errors. So far I've failed to be able to annotate the code to avoid the warning. Here's the code snippet that helgrind warns me about: static const char * cmd = NULL; /* XXX memleak */ static yarnLock oneshot = NULL; /* XXX memleak */ if (oneshot == NULL) { cmd = rpmExpand("%{?__prelink_undo_cmd}", NULL); VALGRIND_HG_CLEAN_MEMORY(cmd, sizeof(cmd)); oneshot = yarnNewLock(0); VALGRIND_HG_CLEAN_MEMORY(oneshot, sizeof(oneshot)); } yarnPossess(oneshot); The yarnLock is basically a malloc'd posix mutex the way I'm handling. Is there a way to annotate this code to avoid helgrind warnings? 73 de Jeff ------------------------------------------------------------------------------ Let Crystal Reports handle the reporting - Free Crystal Reports 2008 30-Day trial. Simplify your report design, integration and deployment - and focus on what you do best, core application coding. Discover what's new with Crystal Reports now. http://p.sf.net/sfu/bobj-july _______________________________________________ Valgrind-users mailing list Valgrind-users@lists.sourceforge.net https://lists.sourceforge.net/lists/listinfo/valgrind-users