Easy leakchecks with "make valgrind"
result is readable thanks to the suppression file
This commit is contained in:
parent
3a6968c97c
commit
8ec19f523b
@ -528,7 +528,7 @@ endif
|
||||
|
||||
### And now for the real build rules ###
|
||||
|
||||
.PHONY : all debug release clean depend zip force install uninstall
|
||||
.PHONY : all debug release clean depend zip force install uninstall valgrind
|
||||
|
||||
# This is the list of the objects we want to build. Dependancies are built by "make depend" automatically.
|
||||
OBJS = main.o init.o graph.o sdlscreen.o misc.o special.o \
|
||||
@ -797,5 +797,8 @@ uninstall :
|
||||
|
||||
endif
|
||||
|
||||
valgrind: $(BIN)
|
||||
valgrind --suppressions=../valgrind.grafx2.suppr --leak-check=full --show-leak-kinds=all --num-callers=20 $(BIN)
|
||||
|
||||
-include Makefile.dep
|
||||
|
||||
|
||||
103
valgrind.grafx2.suppr
Normal file
103
valgrind.grafx2.suppr
Normal file
@ -0,0 +1,103 @@
|
||||
{
|
||||
SDL_Init_1
|
||||
Memcheck:Cond
|
||||
...
|
||||
fun:SDL_InitSubSystem
|
||||
fun:SDL_Init
|
||||
fun:Init_program
|
||||
fun:main
|
||||
}
|
||||
{
|
||||
SDL_Init_2
|
||||
Memcheck:Value8
|
||||
...
|
||||
fun:SDL_InitSubSystem
|
||||
fun:SDL_Init
|
||||
fun:Init_program
|
||||
fun:main
|
||||
}
|
||||
{
|
||||
SDL_Init Leaks
|
||||
Memcheck:Leak
|
||||
match-leak-kinds: all
|
||||
...
|
||||
fun:SDL_InitSubSystem
|
||||
fun:SDL_Init
|
||||
...
|
||||
}
|
||||
{
|
||||
SDL_VideoInit Leaks
|
||||
Memcheck:Leak
|
||||
match-leak-kinds: all
|
||||
...
|
||||
fun:SDL_VideoInit
|
||||
...
|
||||
}
|
||||
{
|
||||
SDL_JoystickOpen
|
||||
Memcheck:Cond
|
||||
...
|
||||
fun:SDL_JoystickOpen
|
||||
fun:Init_program
|
||||
fun:main
|
||||
}
|
||||
{
|
||||
SDL_JoystickOpen 2
|
||||
Memcheck:Value8
|
||||
...
|
||||
fun:SDL_JoystickOpen
|
||||
fun:Init_program
|
||||
fun:main
|
||||
}
|
||||
{
|
||||
SDL_WM_SetCaption
|
||||
Memcheck:Cond
|
||||
...
|
||||
fun:SDL_WM_SetCaption
|
||||
fun:Init_program
|
||||
}
|
||||
{
|
||||
SDL_WM_SetCaption_2
|
||||
Memcheck:Param
|
||||
openat(filename)
|
||||
fun:_openat
|
||||
...
|
||||
fun:SDL_WM_SetCaption
|
||||
}
|
||||
{
|
||||
SDK_WM_SetCaption Leaks
|
||||
Memcheck:Leak
|
||||
match-leak-kinds: all
|
||||
...
|
||||
fun:SDL_WM_SetCaption
|
||||
fun:Init_program
|
||||
}
|
||||
{
|
||||
SDL_SetVideoMode
|
||||
Memcheck:Param
|
||||
writev(vector[...])
|
||||
fun:_writev
|
||||
...
|
||||
fun:SDL_SetVideoMode
|
||||
fun:Set_mode_SDL
|
||||
fun:Init_mode_video
|
||||
}
|
||||
{
|
||||
SDL_JoystrickUpdate
|
||||
Memcheck:Param
|
||||
read(count)
|
||||
fun:_read
|
||||
...
|
||||
fun:SDL_JoystickUpdate
|
||||
...
|
||||
fun:main
|
||||
}
|
||||
{
|
||||
SDL_JoystrickUpdate2
|
||||
Memcheck:Cond
|
||||
...
|
||||
fun:SDL_JoystickUpdate
|
||||
...
|
||||
fun:main
|
||||
}
|
||||
|
||||
Loading…
x
Reference in New Issue
Block a user