lists.openwall.net   lists  /  announce  owl-users  owl-dev  john-users  john-dev  passwdqc-users  yescrypt  popa3d-users  /  oss-security  kernel-hardening  musl  sabotage  tlsify  passwords  /  crypt-dev  xvendor  /  Bugtraq  Full-Disclosure  linux-kernel  linux-netdev  linux-ext4  linux-hardening  linux-cve-announce  PHC 
Open Source and information security mailing list archives
 
Hash Suite: Windows password security audit tool. GUI, reports in PDF.
[<prev] [next>] [<thread-prev] [thread-next>] [day] [month] [year] [list]
Message-ID: <alpine.LNX.2.00.1006301147490.13809@pobox.suse.cz>
Date:	Wed, 30 Jun 2010 11:48:30 +0200 (CEST)
From:	Jiri Kosina <jkosina@...e.cz>
To:	"Justin P. Mattock" <justinmattock@...il.com>
Cc:	linux-kernel@...r.kernel.org
Subject: Re: [PATCH]kernel.h Fix #warning message web address.

On Tue, 29 Jun 2010, Justin P. Mattock wrote:

> Playing around with a printk program I noticed that the #warning
> message is incomplete(when using kernel headers for userspace):
> 
>  gcc printk.c -o printk
> In file included from printk.c:3:
> include/linux/kernel.h:733:2: warning: #warning Attempt to use kernel headers from user space, see http:
> 
> My guess for the web address not being displayed is "//" is treated as a comment.
> So after changing "http://" to "www." I get the web address.(using firefox with this
> address takes me right to the location). The warning looks like this:
> 
> In file included from printk.c:3:
> warning: #warning Attempt to use kernel headers from user space, see www.kernelnewbies.org/KernelHeaders 
>  
>  Signed-off-by: Justin P. Mattock <justinmattock@...il.com>
> 
> ---
>  include/linux/kernel.h |    2 +-
>  1 files changed, 1 insertions(+), 1 deletions(-)
> 
> diff --git a/include/linux/kernel.h b/include/linux/kernel.h
> index 8317ec4..768196a 100644
> --- a/include/linux/kernel.h
> +++ b/include/linux/kernel.h
> @@ -730,7 +730,7 @@ extern int do_sysinfo(struct sysinfo *info);
>  
>  #ifndef __EXPORTED_HEADERS__
>  #ifndef __KERNEL__
> -#warning Attempt to use kernel headers from user space, see http://kernelnewbies.org/KernelHeaders
> +#warning Attempt to use kernel headers from user space, see www.kernelnewbies.org/KernelHeaders
>  #endif /* __KERNEL__ */
>  #endif /* __EXPORTED_HEADERS__ */

Hehe, ugly. How about making it a single string? GCC preprocessor 
documentation suggests the same anyway ...

	Neither `#error' nor `#warning' macro-expands its argument.
	Internal whitespace sequences are each replaced with a single space.
	The line must consist of complete tokens.  It is wisest to make the
	argument of these directives be a single string constant; this avoids
	problems with apostrophes and the like.

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

Powered by blists - more mailing lists

Powered by Openwall GNU/*/Linux Powered by OpenVZ