diff --git a/documentation/bugs.sgml b/documentation/bugs.sgml
index 79607720cda..b493102d9ac 100644
--- a/documentation/bugs.sgml
+++ b/documentation/bugs.sgml
@@ -360,7 +360,7 @@
Separate the last 100 lines to another file using
- tail .
+ tail.
@@ -388,7 +388,7 @@
$ wine -debugmsg +relay [other_options] program_name |& tee filename.out;
-$ tail -100 filename.out > report_file
+$ tail -n 100 filename.out > report_file
@@ -397,7 +397,7 @@
$ wine -debugmsg +relay [other_options] program_name 2>&1 | tee filename.out;
-$ tail -100 filename.out > report_file
+$ tail -n 100 filename.out > report_file
diff --git a/tools/testrun b/tools/testrun
index ac256e061a0..831a82aa972 100755
--- a/tools/testrun
+++ b/tools/testrun
@@ -266,8 +266,8 @@ while ($exe=) {
alarm(1000);# so it doesn't trigger in the diff, kill or find.
system("touch $cwd/runs/${runfile}.out");
- system("$diff $cwd/runs/${runfile}.out $cwd/${runfile}.out|head -$trunclines");
- system("head -$trunclines $cwd/${runfile}.out >$cwd/runs/${runfile}.out");
+ system("$diff $cwd/runs/${runfile}.out $cwd/${runfile}.out|head -n $trunclines");
+ system("head -n $trunclines $cwd/${runfile}.out >$cwd/runs/${runfile}.out");
unlink("$cwd/${runfile}.out");
&kill_subprocesses;
&cleanup_wine_ipc;