[gstreamer-bugs] [Bug 172961] valgrind gives a lot of errors on gst-ffmpeg elements

bugzilla-daemon at bugzilla.gnome.org bugzilla-daemon at bugzilla.gnome.org
Thu Apr 7 08:31:10 PDT 2005


Please DO NOT reply to this by email. All additional comments should be made in
the comments box of this bug report.

 http://bugzilla.gnome.org/show_bug.cgi?id=172961
 GStreamer | gst-ffmpeg | Ver: HEAD CVS





------- Additional Comments From Luca Ognibene  2005-04-07 11:31 -------
I don't think that errors that have __GI___libc_freeres (set-freeres.c:49) in
the call trace are important. __libc_freeres is called by valgrind and is not
called in a normal program (check man valgrind). So we have a lot of errors
inside libavcodec. 
I'm able to get rid of all of av_free errors adding:
#undef HAVE_MEMALIGN
#undef MEMALIGN_HACK
to mem.c in libavcodec. This works fine in valgrind but gives every type of
strange errors if i run gst-launch directly. 

I've tried to add:    
AVCodecContext *avctx= av_malloc(sizeof(AVCodecContext));
av_free (avctx);
to _get_caps function in ffenc and valgrind gives error also in this line (the
av_free one).. 
If i s/av_malloc/malloc and s/av_free/free it works fine! So i was thinking in a
problem with valgrind and memalign but a simple:
int
main (int argc, 
      char **argv) {
  void *p;  
  p = memalign (16, 10);  
  free (p);    
  return 0;
}
works fine.. So i've added a:
void *p;
p = memalign (16, 10);
free (p);

to ffenc _get_caps function and... it gives error!! So.. is it a build issue?
but:
I've tried adding to _get_caps:
  void *p;
  posix_memalign (&p, 16, 10);
  free (p);
and this works fine.. any idea? and sorry for the longest comment in the world :)


------- You are receiving this mail because: -------
You are the assignee for the bug.
You are the QA contact for the bug.




More information about the Gstreamer-bugs mailing list