Make the Linux launcher more like the Darwin one in how it reads the
executable headers.  This means it no longer crashes on an empty executable.
Fixes bug 156065.



git-svn-id: svn://svn.valgrind.org/valgrind/trunk@10384 a5019735-40e9-0310-863c-91ae7b9d1cf9
diff --git a/none/tests/empty-exe.vgtest b/none/tests/empty-exe.vgtest
new file mode 100644
index 0000000..71fef2e
--- /dev/null
+++ b/none/tests/empty-exe.vgtest
@@ -0,0 +1,9 @@
+# Bug 162020: running an empty executable used to crash Valgrind.  Note that
+# the (old) crash message gets filtered out, so it's the presence of the
+# blank two lines in the .stderr.exp file that are important -- they
+# indicate it ran to completion.  If the crash occurs, the .stderr.out file
+# is empty.
+prereq: touch empty-exe && chmod u+x empty-exe
+prog: empty-exe
+vgopts:
+cleanup: rm -f empty-exe