filter_none_discards \
filter_stderr \
filter_timestamp \
+ filter_xml \
allexec_prepare_prereq
noinst_HEADERS = fdleak.h
coolo_strlen.stderr.exp coolo_strlen.vgtest \
discard.stderr.exp discard.stdout.exp \
discard.vgtest \
+ double_close_range_xml.stderr.exp \
+ double_close_range_xml.vgtest \
empty-exe.vgtest empty-exe.stderr.exp \
exec-sigmask.vgtest exec-sigmask.stdout.exp \
exec-sigmask.stdout.exp2 exec-sigmask.stdout.exp3 \
faultstatus.vgtest faultstatus.stderr.exp faultstatus.stderr.exp-s390x \
fcntl_setown.vgtest fcntl_setown.stdout.exp fcntl_setown.stderr.exp \
fdleak_cmsg.stderr.exp fdleak_cmsg.vgtest \
+ fdleak_cmsg_xml.stderr.exp fdleak_cmsg_xml.vgtest \
fdleak_creat.stderr.exp fdleak_creat.vgtest \
+ fdleak_creat_xml.stderr.exp fdleak_creat_xml.vgtest \
fdleak_dup.stderr.exp fdleak_dup.vgtest \
+ fdleak_dup_xml.stderr.exp fdleak_dup_xml.vgtest \
fdleak_dup2.stderr.exp fdleak_dup2.vgtest \
+ fdleak_dup2_xml.stderr.exp fdleak_dup2_xml.vgtest \
fdleak_fcntl.stderr.exp fdleak_fcntl.vgtest \
+ fdleak_fcntl_xml.stderr.exp fdleak_fcntl_xml.vgtest \
fdleak_ipv4.stderr.exp fdleak_ipv4.stdout.exp fdleak_ipv4.vgtest \
+ fdleak_ipv4_xml.stderr.exp fdleak_ipv4_xml.stdout.exp \
+ fdleak_ipv4_xml.vgtest \
fdleak_open.stderr.exp fdleak_open.vgtest \
+ fdleak_open_xml.stderr.exp fdleak_open_xml.vgtest \
fdleak_pipe.stderr.exp fdleak_pipe.vgtest \
+ fdleak_pipe_xml.stderr.exp fdleak_pipe_xml.vgtest \
fdleak_socketpair.stderr.exp fdleak_socketpair.vgtest \
+ fdleak_socketpair_xml.stderr.exp fdleak_socketpair_xml.vgtest \
floored.stderr.exp floored.stdout.exp floored.vgtest \
fork.stderr.exp fork.stdout.exp fork.vgtest \
fucomip.stderr.exp fucomip.vgtest \
process_vm_readv_writev.stderr.exp process_vm_readv_writev.vgtest \
sigprocmask.stderr.exp sigprocmask.vgtest \
socket_close.stderr.exp socket_close.vgtest \
+ socket_close_xml.stderr.exp socket_close_xml.vgtest \
file_dclose.stderr.exp file_dclose.vgtest \
+ file_dclose_xml.stderr.exp file_dclose_xml.vgtest \
double_close_range.stderr.exp double_close_range.vgtest
--- /dev/null
+<?xml version="1.0"?>
+
+<valgrindoutput>
+
+<protocolversion>5</protocolversion>
+<protocoltool>none</protocoltool>
+
+<preamble>
+ <line>Nulgrind, the minimal Valgrind tool</line>
+ <line>Copyright...</line>
+ <line>Using Valgrind...</line>
+ <line>Command: ./double_close_range</line>
+</preamble>
+
+<pid>...</pid>
+<ppid>...</ppid>
+<tool>none</tool>
+
+<args>
+ <vargv>
+ <exe>...</exe>
+ <arg>--command-line-only=yes</arg>
+ <arg>--memcheck:leak-check=no</arg>
+ <arg>--tool=none</arg>
+ <arg>-q</arg>
+ <arg>--track-fds=yes</arg>
+ <arg>--xml=yes</arg>
+ <arg>--xml-fd=2</arg>
+ </vargv>
+ <argv>
+ <exe>...</exe>
+ </argv>
+</args>
+
+<status>
+ <state>RUNNING</state>
+ <time>...</time>
+</status>
+
+close fd 3
+Closing range (3, -1).
+Closing range (5, 7).
+Double closing range (5, 7).
+<error>
+ <unique>0x........</unique>
+ <tid>...</tid>
+ <kind>FdBadClose</kind>
+ <fd>5</fd>
+ <path>...</path>
+ <what>...</what>
+ <stack>
+ <frame>
+ <ip>0x........</ip>
+ <obj>...</obj>
+ <fn>main</fn>
+ <dir>...</dir>
+ <file>double_close_range.c</file>
+ <line>33</line>
+ </frame>
+ </stack>
+ <auxwhat>Previously closed</auxwhat>
+ <stack>
+ <frame>
+ <ip>0x........</ip>
+ <obj>...</obj>
+ <fn>main</fn>
+ <dir>...</dir>
+ <file>double_close_range.c</file>
+ <line>29</line>
+ </frame>
+ </stack>
+ <auxwhat>Originally opened</auxwhat>
+ <stack>
+ <frame>
+ <ip>0x........</ip>
+ <obj>...</obj>
+ <fn>main</fn>
+ <dir>...</dir>
+ <file>double_close_range.c</file>
+ <line>26</line>
+ </frame>
+ </stack>
+</error>
+
+<error>
+ <unique>0x........</unique>
+ <tid>...</tid>
+ <kind>FdBadClose</kind>
+ <fd>7</fd>
+ <path>...</path>
+ <what>...</what>
+ <stack>
+ <frame>
+ <ip>0x........</ip>
+ <obj>...</obj>
+ <fn>main</fn>
+ <dir>...</dir>
+ <file>double_close_range.c</file>
+ <line>33</line>
+ </frame>
+ </stack>
+ <auxwhat>Previously closed</auxwhat>
+ <stack>
+ <frame>
+ <ip>0x........</ip>
+ <obj>...</obj>
+ <fn>main</fn>
+ <dir>...</dir>
+ <file>double_close_range.c</file>
+ <line>29</line>
+ </frame>
+ </stack>
+ <auxwhat>Originally opened</auxwhat>
+ <stack>
+ <frame>
+ <ip>0x........</ip>
+ <obj>...</obj>
+ <fn>main</fn>
+ <dir>...</dir>
+ <file>double_close_range.c</file>
+ <line>27</line>
+ </frame>
+ </stack>
+</error>
+
+
+<status>
+ <state>FINISHED</state>
+ <time>...</time>
+</status>
+
+<errorcounts>
+ <pair>
+ <count>1</count>
+ <unique>0x........</unique>
+ </pair>
+ <pair>
+ <count>1</count>
+ <unique>0x........</unique>
+ </pair>
+</errorcounts>
+
+
+</valgrindoutput>
+
--- /dev/null
+prog: double_close_range
+prereq: test -x double_close_range
+vgopts: -q --track-fds=yes --xml=yes --xml-fd=2
+stderr_filter: filter_xml
--- /dev/null
+<?xml version="1.0"?>
+
+<valgrindoutput>
+
+<protocolversion>5</protocolversion>
+<protocoltool>none</protocoltool>
+
+<preamble>
+ <line>Nulgrind, the minimal Valgrind tool</line>
+ <line>Copyright...</line>
+ <line>Using Valgrind...</line>
+ <line>Command: ./fdleak_cmsg</line>
+</preamble>
+
+<pid>...</pid>
+<ppid>...</ppid>
+<tool>none</tool>
+
+<args>
+ <vargv>
+ <exe>...</exe>
+ <arg>--command-line-only=yes</arg>
+ <arg>--memcheck:leak-check=no</arg>
+ <arg>--tool=none</arg>
+ <arg>--track-fds=all</arg>
+ <arg>--xml=yes</arg>
+ <arg>--xml-fd=2</arg>
+ <arg>--child-silent-after-fork=yes</arg>
+ </vargv>
+ <argv>
+ <exe>...</exe>
+ </argv>
+</args>
+
+<status>
+ <state>RUNNING</state>
+ <time>...</time>
+</status>
+
+
+<status>
+ <state>FINISHED</state>
+ <time>...</time>
+</status>
+
+<error>
+ <unique>0x........</unique>
+ <tid>...</tid>
+ <kind>FdNotClosed</kind>
+ <fd>5</fd>
+ <path>...</path>
+ <what>...</what>
+ <stack>
+ <frame>
+ <ip>0x........</ip>
+ <obj>...</obj>
+ <fn>client</fn>
+ <dir>...</dir>
+ <file>fdleak_cmsg.c</file>
+ <line>133</line>
+ </frame>
+ <frame>
+ <ip>0x........</ip>
+ <obj>...</obj>
+ <fn>main</fn>
+ <dir>...</dir>
+ <file>fdleak_cmsg.c</file>
+ <line>174</line>
+ </frame>
+ </stack>
+</error>
+
+<error>
+ <unique>0x........</unique>
+ <tid>...</tid>
+ <kind>FdNotClosed</kind>
+ <fd>4</fd>
+ <path>...</path>
+ <what>...</what>
+ <stack>
+ <frame>
+ <ip>0x........</ip>
+ <obj>...</obj>
+ <fn>client</fn>
+ <dir>...</dir>
+ <file>fdleak_cmsg.c</file>
+ <line>133</line>
+ </frame>
+ <frame>
+ <ip>0x........</ip>
+ <obj>...</obj>
+ <fn>main</fn>
+ <dir>...</dir>
+ <file>fdleak_cmsg.c</file>
+ <line>174</line>
+ </frame>
+ </stack>
+</error>
+
+<error>
+ <unique>0x........</unique>
+ <tid>...</tid>
+ <kind>FdNotClosed</kind>
+ <fd>3</fd>
+ <what>...</what>
+ <stack>
+ <frame>
+ <ip>0x........</ip>
+ <obj>...</obj>
+ <fn>client</fn>
+ <dir>...</dir>
+ <file>fdleak_cmsg.c</file>
+ <line>112</line>
+ </frame>
+ <frame>
+ <ip>0x........</ip>
+ <obj>...</obj>
+ <fn>main</fn>
+ <dir>...</dir>
+ <file>fdleak_cmsg.c</file>
+ <line>174</line>
+ </frame>
+ </stack>
+</error>
+
+<error>
+ <unique>0x........</unique>
+ <tid>...</tid>
+ <kind>FdNotClosed</kind>
+ <fd>2</fd>
+ <path>...</path>
+ <what>...</what>
+</error>
+
+<error>
+ <unique>0x........</unique>
+ <tid>...</tid>
+ <kind>FdNotClosed</kind>
+ <fd>1</fd>
+ <path>...</path>
+ <what>...</what>
+</error>
+
+<error>
+ <unique>0x........</unique>
+ <tid>...</tid>
+ <kind>FdNotClosed</kind>
+ <fd>0</fd>
+ <path>...</path>
+ <what>...</what>
+</error>
+
+
+</valgrindoutput>
+
--- /dev/null
+prog: fdleak_cmsg
+# Program forks, so don't output anything after fork/child.
+# Should maybe be default for xml output?
+vgopts: --track-fds=all --xml=yes --xml-fd=2 --child-silent-after-fork=yes
+args: < /dev/null
+stderr_filter: filter_xml
--- /dev/null
+<?xml version="1.0"?>
+
+<valgrindoutput>
+
+<protocolversion>5</protocolversion>
+<protocoltool>none</protocoltool>
+
+<preamble>
+ <line>Nulgrind, the minimal Valgrind tool</line>
+ <line>Copyright...</line>
+ <line>Using Valgrind...</line>
+ <line>Command: ./fdleak_creat</line>
+</preamble>
+
+<pid>...</pid>
+<ppid>...</ppid>
+<tool>none</tool>
+
+<args>
+ <vargv>
+ <exe>...</exe>
+ <arg>--command-line-only=yes</arg>
+ <arg>--memcheck:leak-check=no</arg>
+ <arg>--tool=none</arg>
+ <arg>--track-fds=all</arg>
+ <arg>--xml=yes</arg>
+ <arg>--xml-fd=2</arg>
+ </vargv>
+ <argv>
+ <exe>...</exe>
+ </argv>
+</args>
+
+<status>
+ <state>RUNNING</state>
+ <time>...</time>
+</status>
+
+
+<status>
+ <state>FINISHED</state>
+ <time>...</time>
+</status>
+
+<error>
+ <unique>0x........</unique>
+ <tid>...</tid>
+ <kind>FdNotClosed</kind>
+ <fd>3</fd>
+ <path>...</path>
+ <what>...</what>
+ <stack>
+ <frame>
+ <ip>0x........</ip>
+ <obj>...</obj>
+ <fn>main</fn>
+ <dir>...</dir>
+ <file>fdleak_creat.c</file>
+ <line>13</line>
+ </frame>
+ </stack>
+</error>
+
+<error>
+ <unique>0x........</unique>
+ <tid>...</tid>
+ <kind>FdNotClosed</kind>
+ <fd>2</fd>
+ <path>...</path>
+ <what>...</what>
+</error>
+
+<error>
+ <unique>0x........</unique>
+ <tid>...</tid>
+ <kind>FdNotClosed</kind>
+ <fd>1</fd>
+ <path>...</path>
+ <what>...</what>
+</error>
+
+<error>
+ <unique>0x........</unique>
+ <tid>...</tid>
+ <kind>FdNotClosed</kind>
+ <fd>0</fd>
+ <path>...</path>
+ <what>...</what>
+</error>
+
+
+</valgrindoutput>
+
--- /dev/null
+prog: fdleak_creat
+vgopts: --track-fds=all --xml=yes --xml-fd=2
+args: < /dev/null
+stderr_filter: filter_xml
--- /dev/null
+<?xml version="1.0"?>
+
+<valgrindoutput>
+
+<protocolversion>5</protocolversion>
+<protocoltool>none</protocoltool>
+
+<preamble>
+ <line>Nulgrind, the minimal Valgrind tool</line>
+ <line>Copyright...</line>
+ <line>Using Valgrind...</line>
+ <line>Command: ./fdleak_dup2</line>
+</preamble>
+
+<pid>...</pid>
+<ppid>...</ppid>
+<tool>none</tool>
+
+<args>
+ <vargv>
+ <exe>...</exe>
+ <arg>--command-line-only=yes</arg>
+ <arg>--memcheck:leak-check=no</arg>
+ <arg>--tool=none</arg>
+ <arg>--track-fds=all</arg>
+ <arg>--xml=yes</arg>
+ <arg>--xml-fd=2</arg>
+ </vargv>
+ <argv>
+ <exe>...</exe>
+ </argv>
+</args>
+
+<status>
+ <state>RUNNING</state>
+ <time>...</time>
+</status>
+
+
+<status>
+ <state>FINISHED</state>
+ <time>...</time>
+</status>
+
+<error>
+ <unique>0x........</unique>
+ <tid>...</tid>
+ <kind>FdNotClosed</kind>
+ <fd>20</fd>
+ <path>...</path>
+ <what>...</what>
+ <stack>
+ <frame>
+ <ip>0x........</ip>
+ <obj>...</obj>
+ <fn>main</fn>
+ <dir>...</dir>
+ <file>fdleak_dup2.c</file>
+ <line>15</line>
+ </frame>
+ </stack>
+</error>
+
+<error>
+ <unique>0x........</unique>
+ <tid>...</tid>
+ <kind>FdNotClosed</kind>
+ <fd>4</fd>
+ <path>...</path>
+ <what>...</what>
+ <stack>
+ <frame>
+ <ip>0x........</ip>
+ <obj>...</obj>
+ <fn>main</fn>
+ <dir>...</dir>
+ <file>fdleak_dup2.c</file>
+ <line>16</line>
+ </frame>
+ </stack>
+</error>
+
+<error>
+ <unique>0x........</unique>
+ <tid>...</tid>
+ <kind>FdNotClosed</kind>
+ <fd>3</fd>
+ <path>...</path>
+ <what>...</what>
+ <stack>
+ <frame>
+ <ip>0x........</ip>
+ <obj>...</obj>
+ <fn>main</fn>
+ <dir>...</dir>
+ <file>fdleak_dup2.c</file>
+ <line>12</line>
+ </frame>
+ </stack>
+</error>
+
+<error>
+ <unique>0x........</unique>
+ <tid>...</tid>
+ <kind>FdNotClosed</kind>
+ <fd>2</fd>
+ <path>...</path>
+ <what>...</what>
+</error>
+
+<error>
+ <unique>0x........</unique>
+ <tid>...</tid>
+ <kind>FdNotClosed</kind>
+ <fd>1</fd>
+ <path>...</path>
+ <what>...</what>
+</error>
+
+<error>
+ <unique>0x........</unique>
+ <tid>...</tid>
+ <kind>FdNotClosed</kind>
+ <fd>0</fd>
+ <path>...</path>
+ <what>...</what>
+</error>
+
+
+</valgrindoutput>
+
--- /dev/null
+prog: fdleak_dup2
+vgopts: --track-fds=all --xml=yes --xml-fd=2
+args: < /dev/null
+stderr_filter: filter_xml
--- /dev/null
+<?xml version="1.0"?>
+
+<valgrindoutput>
+
+<protocolversion>5</protocolversion>
+<protocoltool>none</protocoltool>
+
+<preamble>
+ <line>Nulgrind, the minimal Valgrind tool</line>
+ <line>Copyright...</line>
+ <line>Using Valgrind...</line>
+ <line>Command: ./fdleak_dup</line>
+</preamble>
+
+<pid>...</pid>
+<ppid>...</ppid>
+<tool>none</tool>
+
+<args>
+ <vargv>
+ <exe>...</exe>
+ <arg>--command-line-only=yes</arg>
+ <arg>--memcheck:leak-check=no</arg>
+ <arg>--tool=none</arg>
+ <arg>--track-fds=all</arg>
+ <arg>--xml=yes</arg>
+ <arg>--xml-fd=2</arg>
+ </vargv>
+ <argv>
+ <exe>...</exe>
+ </argv>
+</args>
+
+<status>
+ <state>RUNNING</state>
+ <time>...</time>
+</status>
+
+
+<status>
+ <state>FINISHED</state>
+ <time>...</time>
+</status>
+
+<error>
+ <unique>0x........</unique>
+ <tid>...</tid>
+ <kind>FdNotClosed</kind>
+ <fd>4</fd>
+ <path>...</path>
+ <what>...</what>
+ <stack>
+ <frame>
+ <ip>0x........</ip>
+ <obj>...</obj>
+ <fn>main</fn>
+ <dir>...</dir>
+ <file>fdleak_dup.c</file>
+ <line>12</line>
+ </frame>
+ </stack>
+</error>
+
+<error>
+ <unique>0x........</unique>
+ <tid>...</tid>
+ <kind>FdNotClosed</kind>
+ <fd>3</fd>
+ <path>...</path>
+ <what>...</what>
+ <stack>
+ <frame>
+ <ip>0x........</ip>
+ <obj>...</obj>
+ <fn>main</fn>
+ <dir>...</dir>
+ <file>fdleak_dup.c</file>
+ <line>11</line>
+ </frame>
+ </stack>
+</error>
+
+<error>
+ <unique>0x........</unique>
+ <tid>...</tid>
+ <kind>FdNotClosed</kind>
+ <fd>2</fd>
+ <path>...</path>
+ <what>...</what>
+</error>
+
+<error>
+ <unique>0x........</unique>
+ <tid>...</tid>
+ <kind>FdNotClosed</kind>
+ <fd>1</fd>
+ <path>...</path>
+ <what>...</what>
+</error>
+
+<error>
+ <unique>0x........</unique>
+ <tid>...</tid>
+ <kind>FdNotClosed</kind>
+ <fd>0</fd>
+ <path>...</path>
+ <what>...</what>
+</error>
+
+
+</valgrindoutput>
+
--- /dev/null
+prog: fdleak_dup
+vgopts: --track-fds=all --xml=yes --xml-fd=2
+args: < /dev/null
+stderr_filter: filter_xml
--- /dev/null
+<?xml version="1.0"?>
+
+<valgrindoutput>
+
+<protocolversion>5</protocolversion>
+<protocoltool>none</protocoltool>
+
+<preamble>
+ <line>Nulgrind, the minimal Valgrind tool</line>
+ <line>Copyright...</line>
+ <line>Using Valgrind...</line>
+ <line>Command: ./fdleak_fcntl</line>
+</preamble>
+
+<pid>...</pid>
+<ppid>...</ppid>
+<tool>none</tool>
+
+<args>
+ <vargv>
+ <exe>...</exe>
+ <arg>--command-line-only=yes</arg>
+ <arg>--memcheck:leak-check=no</arg>
+ <arg>--tool=none</arg>
+ <arg>--track-fds=all</arg>
+ <arg>--xml=yes</arg>
+ <arg>--xml-fd=2</arg>
+ </vargv>
+ <argv>
+ <exe>...</exe>
+ </argv>
+</args>
+
+<status>
+ <state>RUNNING</state>
+ <time>...</time>
+</status>
+
+
+<status>
+ <state>FINISHED</state>
+ <time>...</time>
+</status>
+
+<error>
+ <unique>0x........</unique>
+ <tid>...</tid>
+ <kind>FdNotClosed</kind>
+ <fd>4</fd>
+ <path>...</path>
+ <what>...</what>
+ <stack>
+ <frame>
+ <ip>0x........</ip>
+ <obj>...</obj>
+ <fn>main</fn>
+ <dir>...</dir>
+ <file>fdleak_fcntl.c</file>
+ <line>13</line>
+ </frame>
+ </stack>
+</error>
+
+<error>
+ <unique>0x........</unique>
+ <tid>...</tid>
+ <kind>FdNotClosed</kind>
+ <fd>3</fd>
+ <path>...</path>
+ <what>...</what>
+ <stack>
+ <frame>
+ <ip>0x........</ip>
+ <obj>...</obj>
+ <fn>main</fn>
+ <dir>...</dir>
+ <file>fdleak_fcntl.c</file>
+ <line>12</line>
+ </frame>
+ </stack>
+</error>
+
+<error>
+ <unique>0x........</unique>
+ <tid>...</tid>
+ <kind>FdNotClosed</kind>
+ <fd>2</fd>
+ <path>...</path>
+ <what>...</what>
+</error>
+
+<error>
+ <unique>0x........</unique>
+ <tid>...</tid>
+ <kind>FdNotClosed</kind>
+ <fd>1</fd>
+ <path>...</path>
+ <what>...</what>
+</error>
+
+<error>
+ <unique>0x........</unique>
+ <tid>...</tid>
+ <kind>FdNotClosed</kind>
+ <fd>0</fd>
+ <path>...</path>
+ <what>...</what>
+</error>
+
+
+</valgrindoutput>
+
--- /dev/null
+prog: fdleak_fcntl
+vgopts: --track-fds=all --xml=yes --xml-fd=2
+args: < /dev/null
+stderr_filter: filter_xml
--- /dev/null
+<?xml version="1.0"?>
+
+<valgrindoutput>
+
+<protocolversion>5</protocolversion>
+<protocoltool>none</protocoltool>
+
+<preamble>
+ <line>Nulgrind, the minimal Valgrind tool</line>
+ <line>Copyright...</line>
+ <line>Using Valgrind...</line>
+ <line>Command: ./fdleak_ipv4</line>
+</preamble>
+
+<pid>...</pid>
+<ppid>...</ppid>
+<tool>none</tool>
+
+<args>
+ <vargv>
+ <exe>...</exe>
+ <arg>--command-line-only=yes</arg>
+ <arg>--memcheck:leak-check=no</arg>
+ <arg>--tool=none</arg>
+ <arg>--track-fds=yes</arg>
+ <arg>--xml=yes</arg>
+ <arg>--xml-fd=2</arg>
+ <arg>--child-silent-after-fork=yes</arg>
+ </vargv>
+ <argv>
+ <exe>...</exe>
+ </argv>
+</args>
+
+<status>
+ <state>RUNNING</state>
+ <time>...</time>
+</status>
+
+<error>
+ <unique>0x........</unique>
+ <tid>...</tid>
+ <kind>FdBadClose</kind>
+ <fd>4</fd>
+ <what>...</what>
+ <stack>
+ <frame>
+ <ip>0x........</ip>
+ <obj>...</obj>
+ <fn>client</fn>
+ <dir>...</dir>
+ <file>fdleak_ipv4.c</file>
+ <line>70</line>
+ </frame>
+ <frame>
+ <ip>0x........</ip>
+ <obj>...</obj>
+ <fn>main</fn>
+ <dir>...</dir>
+ <file>fdleak_ipv4.c</file>
+ <line>90</line>
+ </frame>
+ </stack>
+ <auxwhat>Previously closed</auxwhat>
+ <stack>
+ <frame>
+ <ip>0x........</ip>
+ <obj>...</obj>
+ <fn>client</fn>
+ <dir>...</dir>
+ <file>fdleak_ipv4.c</file>
+ <line>69</line>
+ </frame>
+ <frame>
+ <ip>0x........</ip>
+ <obj>...</obj>
+ <fn>main</fn>
+ <dir>...</dir>
+ <file>fdleak_ipv4.c</file>
+ <line>90</line>
+ </frame>
+ </stack>
+ <auxwhat>Originally opened</auxwhat>
+ <stack>
+ <frame>
+ <ip>0x........</ip>
+ <obj>...</obj>
+ <fn>client</fn>
+ <dir>...</dir>
+ <file>fdleak_ipv4.c</file>
+ <line>68</line>
+ </frame>
+ <frame>
+ <ip>0x........</ip>
+ <obj>...</obj>
+ <fn>main</fn>
+ <dir>...</dir>
+ <file>fdleak_ipv4.c</file>
+ <line>90</line>
+ </frame>
+ </stack>
+</error>
+
+
+<status>
+ <state>FINISHED</state>
+ <time>...</time>
+</status>
+
+<error>
+ <unique>0x........</unique>
+ <tid>...</tid>
+ <kind>FdNotClosed</kind>
+ <fd>3</fd>
+ <what>...</what>
+ <stack>
+ <frame>
+ <ip>0x........</ip>
+ <obj>...</obj>
+ <fn>client</fn>
+ <dir>...</dir>
+ <file>fdleak_ipv4.c</file>
+ <line>51</line>
+ </frame>
+ <frame>
+ <ip>0x........</ip>
+ <obj>...</obj>
+ <fn>main</fn>
+ <dir>...</dir>
+ <file>fdleak_ipv4.c</file>
+ <line>90</line>
+ </frame>
+ </stack>
+</error>
+
+<errorcounts>
+ <pair>
+ <count>1</count>
+ <unique>0x........</unique>
+ </pair>
+</errorcounts>
+
+<suppcounts>
+</suppcounts>
+
+</valgrindoutput>
+
--- /dev/null
+<?xml version="1.0"?>
+
+<valgrindoutput>
+
+<protocolversion>5</protocolversion>
+<protocoltool>none</protocoltool>
+
+<preamble>
+ <line>Nulgrind, the minimal Valgrind tool</line>
+ <line>Copyright...</line>
+ <line>Using Valgrind...</line>
+ <line>Command: ./fdleak_ipv4</line>
+</preamble>
+
+<pid>...</pid>
+<ppid>...</ppid>
+<tool>none</tool>
+
+<args>
+ <vargv>
+ <exe>...</exe>
+ <arg>--command-line-only=yes</arg>
+ <arg>--memcheck:leak-check=no</arg>
+ <arg>--tool=none</arg>
+ <arg>--track-fds=yes</arg>
+ <arg>--xml=yes</arg>
+ <arg>--xml-fd=2</arg>
+ <arg>--child-silent-after-fork=yes</arg>
+ </vargv>
+ <argv>
+ <exe>...</exe>
+ </argv>
+</args>
+
+<status>
+ <state>RUNNING</state>
+ <time>...</time>
+</status>
+
+<error>
+ <unique>0x........</unique>
+ <tid>...</tid>
+ <kind>FdBadClose</kind>
+ <fd>4</fd>
+ <what>...</what>
+ <stack>
+ <frame>
+ <ip>0x........</ip>
+ <obj>...</obj>
+ <fn>client</fn>
+ <dir>...</dir>
+ <file>fdleak_ipv4.c</file>
+ <line>70</line>
+ </frame>
+ </stack>
+ <auxwhat>Previously closed</auxwhat>
+ <stack>
+ <frame>
+ <ip>0x........</ip>
+ <obj>...</obj>
+ <fn>client</fn>
+ <dir>...</dir>
+ <file>fdleak_ipv4.c</file>
+ <line>69</line>
+ </frame>
+ </stack>
+ <auxwhat>Originally opened</auxwhat>
+ <stack>
+ <frame>
+ <ip>0x........</ip>
+ <obj>...</obj>
+ <fn>client</fn>
+ <dir>...</dir>
+ <file>fdleak_ipv4.c</file>
+ <line>68</line>
+ </frame>
+ </stack>
+</error>
+
+
+<status>
+ <state>FINISHED</state>
+ <time>...</time>
+</status>
+
+<error>
+ <unique>0x........</unique>
+ <tid>...</tid>
+ <kind>FdNotClosed</kind>
+ <fd>3</fd>
+ <what>...</what>
+ <stack>
+ <frame>
+ <ip>0x........</ip>
+ <obj>...</obj>
+ <fn>client</fn>
+ <dir>...</dir>
+ <file>fdleak_ipv4.c</file>
+ <line>51</line>
+ </frame>
+ <frame>
+ <ip>0x........</ip>
+ <obj>...</obj>
+ <fn>main</fn>
+ <dir>...</dir>
+ <file>fdleak_ipv4.c</file>
+ <line>90</line>
+ </frame>
+ </stack>
+</error>
+
+<errorcounts>
+ <pair>
+ <count>1</count>
+ <unique>0x........</unique>
+ </pair>
+</errorcounts>
+
+<suppcounts>
+</suppcounts>
+
+</valgrindoutput>
+
--- /dev/null
+prog: fdleak_ipv4
+# Program forks, so don't output anything after fork/child.
+# Should maybe be default for xml output?
+vgopts: --track-fds=yes --xml=yes --xml-fd=2 --child-silent-after-fork=yes
+args: < /dev/null
+stderr_filter: filter_xml
--- /dev/null
+<?xml version="1.0"?>
+
+<valgrindoutput>
+
+<protocolversion>5</protocolversion>
+<protocoltool>none</protocoltool>
+
+<preamble>
+ <line>Nulgrind, the minimal Valgrind tool</line>
+ <line>Copyright...</line>
+ <line>Using Valgrind...</line>
+ <line>Command: ./fdleak_open</line>
+</preamble>
+
+<pid>...</pid>
+<ppid>...</ppid>
+<tool>none</tool>
+
+<args>
+ <vargv>
+ <exe>...</exe>
+ <arg>--command-line-only=yes</arg>
+ <arg>--memcheck:leak-check=no</arg>
+ <arg>--tool=none</arg>
+ <arg>--track-fds=yes</arg>
+ <arg>--xml=yes</arg>
+ <arg>--xml-fd=2</arg>
+ </vargv>
+ <argv>
+ <exe>...</exe>
+ </argv>
+</args>
+
+<status>
+ <state>RUNNING</state>
+ <time>...</time>
+</status>
+
+
+<status>
+ <state>FINISHED</state>
+ <time>...</time>
+</status>
+
+<error>
+ <unique>0x........</unique>
+ <tid>...</tid>
+ <kind>FdNotClosed</kind>
+ <fd>3</fd>
+ <path>...</path>
+ <what>...</what>
+ <stack>
+ <frame>
+ <ip>0x........</ip>
+ <obj>...</obj>
+ <fn>main</fn>
+ <dir>...</dir>
+ <file>fdleak_open.c</file>
+ <line>9</line>
+ </frame>
+ </stack>
+</error>
+
+
+</valgrindoutput>
+
--- /dev/null
+prog: fdleak_open
+vgopts: --track-fds=yes --xml=yes --xml-fd=2
+args: < /dev/null
+stderr_filter: filter_xml
--- /dev/null
+<?xml version="1.0"?>
+
+<valgrindoutput>
+
+<protocolversion>5</protocolversion>
+<protocoltool>none</protocoltool>
+
+<preamble>
+ <line>Nulgrind, the minimal Valgrind tool</line>
+ <line>Copyright...</line>
+ <line>Using Valgrind...</line>
+ <line>Command: ./fdleak_pipe</line>
+</preamble>
+
+<pid>...</pid>
+<ppid>...</ppid>
+<tool>none</tool>
+
+<args>
+ <vargv>
+ <exe>...</exe>
+ <arg>--command-line-only=yes</arg>
+ <arg>--memcheck:leak-check=no</arg>
+ <arg>--tool=none</arg>
+ <arg>--track-fds=yes</arg>
+ <arg>--xml=yes</arg>
+ <arg>--xml-fd=2</arg>
+ </vargv>
+ <argv>
+ <exe>...</exe>
+ </argv>
+</args>
+
+<status>
+ <state>RUNNING</state>
+ <time>...</time>
+</status>
+
+
+<status>
+ <state>FINISHED</state>
+ <time>...</time>
+</status>
+
+<error>
+ <unique>0x........</unique>
+ <tid>...</tid>
+ <kind>FdNotClosed</kind>
+ <fd>4</fd>
+ <what>...</what>
+ <stack>
+ <frame>
+ <ip>0x........</ip>
+ <obj>...</obj>
+ <fn>main</fn>
+ <dir>...</dir>
+ <file>fdleak_pipe.c</file>
+ <line>10</line>
+ </frame>
+ </stack>
+</error>
+
+<error>
+ <unique>0x........</unique>
+ <tid>...</tid>
+ <kind>FdNotClosed</kind>
+ <fd>3</fd>
+ <what>...</what>
+ <stack>
+ <frame>
+ <ip>0x........</ip>
+ <obj>...</obj>
+ <fn>main</fn>
+ <dir>...</dir>
+ <file>fdleak_pipe.c</file>
+ <line>10</line>
+ </frame>
+ </stack>
+</error>
+
+
+</valgrindoutput>
+
--- /dev/null
+prog: fdleak_pipe
+vgopts: --track-fds=yes --xml=yes --xml-fd=2
+args: < /dev/null
+stderr_filter: filter_xml
--- /dev/null
+<?xml version="1.0"?>
+
+<valgrindoutput>
+
+<protocolversion>5</protocolversion>
+<protocoltool>none</protocoltool>
+
+<preamble>
+ <line>Nulgrind, the minimal Valgrind tool</line>
+ <line>Copyright...</line>
+ <line>Using Valgrind...</line>
+ <line>Command: ./fdleak_socketpair</line>
+</preamble>
+
+<pid>...</pid>
+<ppid>...</ppid>
+<tool>none</tool>
+
+<args>
+ <vargv>
+ <exe>...</exe>
+ <arg>--command-line-only=yes</arg>
+ <arg>--memcheck:leak-check=no</arg>
+ <arg>--tool=none</arg>
+ <arg>--track-fds=yes</arg>
+ <arg>--xml=yes</arg>
+ <arg>--xml-fd=2</arg>
+ </vargv>
+ <argv>
+ <exe>...</exe>
+ </argv>
+</args>
+
+<status>
+ <state>RUNNING</state>
+ <time>...</time>
+</status>
+
+
+<status>
+ <state>FINISHED</state>
+ <time>...</time>
+</status>
+
+<error>
+ <unique>0x........</unique>
+ <tid>...</tid>
+ <kind>FdNotClosed</kind>
+ <fd>4</fd>
+ <what>...</what>
+ <stack>
+ <frame>
+ <ip>0x........</ip>
+ <obj>...</obj>
+ <fn>main</fn>
+ <dir>...</dir>
+ <file>fdleak_socketpair.c</file>
+ <line>13</line>
+ </frame>
+ </stack>
+</error>
+
+<error>
+ <unique>0x........</unique>
+ <tid>...</tid>
+ <kind>FdNotClosed</kind>
+ <fd>3</fd>
+ <what>...</what>
+ <stack>
+ <frame>
+ <ip>0x........</ip>
+ <obj>...</obj>
+ <fn>main</fn>
+ <dir>...</dir>
+ <file>fdleak_socketpair.c</file>
+ <line>13</line>
+ </frame>
+ </stack>
+</error>
+
+
+</valgrindoutput>
+
--- /dev/null
+prog: fdleak_socketpair
+vgopts: --track-fds=yes --xml=yes --xml-fd=2
+args: < /dev/null
+stderr_filter: filter_xml
--- /dev/null
+<?xml version="1.0"?>
+
+<valgrindoutput>
+
+<protocolversion>5</protocolversion>
+<protocoltool>none</protocoltool>
+
+<preamble>
+ <line>Nulgrind, the minimal Valgrind tool</line>
+ <line>Copyright...</line>
+ <line>Using Valgrind...</line>
+ <line>Command: ./file_dclose</line>
+</preamble>
+
+<pid>...</pid>
+<ppid>...</ppid>
+<tool>none</tool>
+
+<args>
+ <vargv>
+ <exe>...</exe>
+ <arg>--command-line-only=yes</arg>
+ <arg>--memcheck:leak-check=no</arg>
+ <arg>--tool=none</arg>
+ <arg>-q</arg>
+ <arg>--track-fds=yes</arg>
+ <arg>--xml=yes</arg>
+ <arg>--xml-fd=2</arg>
+ </vargv>
+ <argv>
+ <exe>...</exe>
+ </argv>
+</args>
+
+<status>
+ <state>RUNNING</state>
+ <time>...</time>
+</status>
+
+close 3
+time passes and we close 3 again
+<error>
+ <unique>0x........</unique>
+ <tid>...</tid>
+ <kind>FdBadClose</kind>
+ <fd>3</fd>
+ <path>...</path>
+ <what>...</what>
+ <stack>
+ <frame>
+ <ip>0x........</ip>
+ <obj>...</obj>
+ <fn>closefile</fn>
+ <dir>...</dir>
+ <file>file_dclose.c</file>
+ <line>17</line>
+ </frame>
+ <frame>
+ <ip>0x........</ip>
+ <obj>...</obj>
+ <fn>main</fn>
+ <dir>...</dir>
+ <file>file_dclose.c</file>
+ <line>35</line>
+ </frame>
+ </stack>
+ <auxwhat>Previously closed</auxwhat>
+ <stack>
+ <frame>
+ <ip>0x........</ip>
+ <obj>...</obj>
+ <fn>main</fn>
+ <dir>...</dir>
+ <file>file_dclose.c</file>
+ <line>31</line>
+ </frame>
+ </stack>
+ <auxwhat>Originally opened</auxwhat>
+ <stack>
+ <frame>
+ <ip>0x........</ip>
+ <obj>...</obj>
+ <fn>openfile</fn>
+ <dir>...</dir>
+ <file>file_dclose.c</file>
+ <line>11</line>
+ </frame>
+ <frame>
+ <ip>0x........</ip>
+ <obj>...</obj>
+ <fn>main</fn>
+ <dir>...</dir>
+ <file>file_dclose.c</file>
+ <line>28</line>
+ </frame>
+ </stack>
+</error>
+
+
+<status>
+ <state>FINISHED</state>
+ <time>...</time>
+</status>
+
+<errorcounts>
+ <pair>
+ <count>1</count>
+ <unique>0x........</unique>
+ </pair>
+</errorcounts>
+
+
+</valgrindoutput>
+
--- /dev/null
+<?xml version="1.0"?>
+
+<valgrindoutput>
+
+<protocolversion>5</protocolversion>
+<protocoltool>none</protocoltool>
+
+<preamble>
+ <line>Nulgrind, the minimal Valgrind tool</line>
+ <line>Copyright...</line>
+ <line>Using Valgrind...</line>
+ <line>Command: ./file_dclose</line>
+</preamble>
+
+<pid>...</pid>
+<ppid>...</ppid>
+<tool>none</tool>
+
+<args>
+ <vargv>
+ <exe>...</exe>
+ <arg>--command-line-only=yes</arg>
+ <arg>--memcheck:leak-check=no</arg>
+ <arg>--tool=none</arg>
+ <arg>-q</arg>
+ <arg>--track-fds=yes</arg>
+ <arg>--xml=yes</arg>
+ <arg>--xml-fd=2</arg>
+ </vargv>
+ <argv>
+ <exe>...</exe>
+ </argv>
+</args>
+
+<status>
+ <state>RUNNING</state>
+ <time>...</time>
+</status>
+
+close 3
+time passes and we close 3 again
+<error>
+ <unique>0x........</unique>
+ <tid>...</tid>
+ <kind>FdBadClose</kind>
+ <fd>3</fd>
+ <path>...</path>
+ <what>...</what>
+ <stack>
+ <frame>
+ <ip>0x........</ip>
+ <obj>...</obj>
+ <fn>closefile</fn>
+ <dir>...</dir>
+ <file>file_dclose.c</file>
+ <line>17</line>
+ </frame>
+ </stack>
+ <auxwhat>Previously closed</auxwhat>
+ <stack>
+ <frame>
+ <ip>0x........</ip>
+ <obj>...</obj>
+ <fn>main</fn>
+ <dir>...</dir>
+ <file>file_dclose.c</file>
+ <line>31</line>
+ </frame>
+ </stack>
+ <auxwhat>Originally opened</auxwhat>
+ <stack>
+ <frame>
+ <ip>0x........</ip>
+ <obj>...</obj>
+ <fn>openfile</fn>
+ <dir>...</dir>
+ <file>file_dclose.c</file>
+ <line>11</line>
+ </frame>
+ </stack>
+</error>
+
+
+<status>
+ <state>FINISHED</state>
+ <time>...</time>
+</status>
+
+<errorcounts>
+ <pair>
+ <count>1</count>
+ <unique>0x........</unique>
+ </pair>
+</errorcounts>
+
+
+</valgrindoutput>
+
--- /dev/null
+prog: file_dclose
+prereq: test -x file_dclose
+vgopts: -q --track-fds=yes --xml=yes --xml-fd=2
+stderr_filter: filter_xml
--- /dev/null
+#! /bin/sh
+
+dir=`dirname $0`
+
+$dir/../../tests/filter_xml_frames |
+perl -p -e "s/<time>.*<\/time>/<time>...<\/time>/s" |
+perl -p -e "s/<what>.*<\/what>/<what>...<\/what>/s" |
+perl -p -e "s/<path>.*<\/path>/<path>...<\/path>/s" |
+perl -p -e "s/<line>Copyright.*<\/line>/<line>Copyright...<\/line>/s" |
+perl -p -e "s/<line>Using Valgrind.*<\/line>/<line>Using Valgrind...<\/line>/s" |
+sed "s/<ppid>[0-9]*<\/ppid>/<ppid>...<\/ppid>/" |
+sed "s/<tid>[0-9]*<\/tid>/<tid>...<\/tid>/" |
+sed "s/<pid>[0-9]*<\/pid>/<pid>...<\/pid>/" |
+sed "s/<obj>.*<\/obj>/<obj>...<\/obj>/" |
+sed "s/<exe>.*<\/exe>/<exe>...<\/exe>/" |
+sed "s/<dir>.*<\/dir>/<dir>...<\/dir>/" |
+sed "s/<ppid>[0-9]*<\/ppid>/<ppid>...<\/ppid>/" |
+sed "s/<unique>0x[0-9a-fA-F]*<\/unique>/<unique>0x........<\/unique>/" |
+sed "s/<ip>0x[0-9a-fA-F]*<\/ip>/<ip>0x........<\/ip>/"
--- /dev/null
+<?xml version="1.0"?>
+
+<valgrindoutput>
+
+<protocolversion>5</protocolversion>
+<protocoltool>none</protocoltool>
+
+<preamble>
+ <line>Nulgrind, the minimal Valgrind tool</line>
+ <line>Copyright...</line>
+ <line>Using Valgrind...</line>
+ <line>Command: ./socket_close</line>
+</preamble>
+
+<pid>...</pid>
+<ppid>...</ppid>
+<tool>none</tool>
+
+<args>
+ <vargv>
+ <exe>...</exe>
+ <arg>--command-line-only=yes</arg>
+ <arg>--memcheck:leak-check=no</arg>
+ <arg>--tool=none</arg>
+ <arg>-q</arg>
+ <arg>--track-fds=yes</arg>
+ <arg>--xml=yes</arg>
+ <arg>--xml-fd=2</arg>
+ </vargv>
+ <argv>
+ <exe>...</exe>
+ </argv>
+</args>
+
+<status>
+ <state>RUNNING</state>
+ <time>...</time>
+</status>
+
+Open socket 3
+close socket_fd 3
+and close the socket again 3
+<error>
+ <unique>0x........</unique>
+ <tid>...</tid>
+ <kind>FdBadClose</kind>
+ <fd>3</fd>
+ <what>...</what>
+ <stack>
+ <frame>
+ <ip>0x........</ip>
+ <obj>...</obj>
+ <fn>main</fn>
+ <dir>...</dir>
+ <file>socket_close.c</file>
+ <line>40</line>
+ </frame>
+ </stack>
+ <auxwhat>Previously closed</auxwhat>
+ <stack>
+ <frame>
+ <ip>0x........</ip>
+ <obj>...</obj>
+ <fn>main</fn>
+ <dir>...</dir>
+ <file>socket_close.c</file>
+ <line>36</line>
+ </frame>
+ </stack>
+ <auxwhat>Originally opened</auxwhat>
+ <stack>
+ <frame>
+ <ip>0x........</ip>
+ <obj>...</obj>
+ <fn>open_socket</fn>
+ <dir>...</dir>
+ <file>socket_close.c</file>
+ <line>17</line>
+ </frame>
+ <frame>
+ <ip>0x........</ip>
+ <obj>...</obj>
+ <fn>main</fn>
+ <dir>...</dir>
+ <file>socket_close.c</file>
+ <line>31</line>
+ </frame>
+ </stack>
+</error>
+
+
+<status>
+ <state>FINISHED</state>
+ <time>...</time>
+</status>
+
+<errorcounts>
+ <pair>
+ <count>1</count>
+ <unique>0x........</unique>
+ </pair>
+</errorcounts>
+
+
+</valgrindoutput>
+
--- /dev/null
+prog: socket_close
+prereq: test -x socket_close
+vgopts: -q --track-fds=yes --xml=yes --xml-fd=2
+stderr_filter: filter_xml