From: Randy Dunlap Date: Thu, 7 Feb 2008 08:13:41 +0000 (-0800) Subject: kernel-doc: prevent duplicate description: output X-Git-Tag: v2.6.25-rc1~488 X-Git-Url: http://pilppa.com/gitweb/?a=commitdiff_plain;h=792aa2f2cc4924024e28c9ddf1456434992f9c41;p=linux-2.6-omap-h63xx.git kernel-doc: prevent duplicate description: output Prevent duplicate output of a Description: section when there is a "blank" ("*") line between the initial function name/description line and the "Description:" header. Test case: drivers/scsi/scsi_devinfo.c::scsi_init_devinfo(). Rob Landley hit this while he was producing SCSI kernel-doc. Signed-off-by: Randy Dunlap Signed-off-by: Andrew Morton Signed-off-by: Linus Torvalds --- diff --git a/scripts/kernel-doc b/scripts/kernel-doc index 1c1d350b490..7df099e6d1f 100755 --- a/scripts/kernel-doc +++ b/scripts/kernel-doc @@ -1907,7 +1907,7 @@ sub process_file($) { $newsection = $1; $newcontents = $2; - if ($contents ne "") { + if (($contents ne "") && ($contents ne "\n")) { if (!$in_doc_sect && $verbose) { print STDERR "Warning(${file}:$.): contents before sections\n"; ++$warnings;