Several additions and bug fixes.

diff --git a/tools/winapi_check/winapi_parser.pm b/tools/winapi_check/winapi_parser.pm
index b17e7f7..3ecda04 100644
--- a/tools/winapi_check/winapi_parser.pm
+++ b/tools/winapi_check/winapi_parser.pm
@@ -56,6 +56,10 @@
     my $function_end = sub {
 	my $function = 'winapi_function'->new;
 
+	if(!defined($documentation_line)) {
+	    $documentation_line = 0;
+	}
+
 	$function->file($file);
 	$function->debug_channels([@$debug_channels]);
 	$function->documentation($documentation);