[PATCH 2/6] kernel-doc: init kernel version

From: Randy Dunlap
Date: Wed Oct 24 2007 - 18:16:15 EST


From: Johannes Berg <johannes@xxxxxxxxxxxxxxxx>

The kernel-doc script triggers a perl warning when invoked
without KERNELVERSION in the environment, rather make it use
the string "unknown kernel version" instead.

Signed-off-by: Johannes Berg <johannes@xxxxxxxxxxxxxxxx>
Signed-off-by: Randy Dunlap <randy.dunlap@xxxxxxxxxx>

---
scripts/kernel-doc | 2 +-
1 file changed, 1 insertion(+), 1 deletion(-)

--- linux-2.6.23-git19.orig/scripts/kernel-doc
+++ linux-2.6.23-git19/scripts/kernel-doc
@@ -334,7 +334,7 @@ while ($ARGV[0] =~ m/^-(.*)/) {

# get kernel version from env
sub get_kernel_version() {
- my $version;
+ my $version = 'unknown kernel version';

if (defined($ENV{'KERNELVERSION'})) {
$version = $ENV{'KERNELVERSION'};


--

-
To unsubscribe from this list: send the line "unsubscribe linux-kernel" in
the body of a message to majordomo@xxxxxxxxxxxxxxx
More majordomo info at http://vger.kernel.org/majordomo-info.html
Please read the FAQ at http://www.tux.org/lkml/