MJPEG rtsp source cause memory leak

please refer to this topic. can you use this method to get a memory leak log? and can you use this method to get a valgrind memory leak analysis log?