Module Name: src Committed By: joerg Date: Tue May 19 12:17:53 UTC 2015
Modified Files: src/sys/sys: ipc.h Log Message: Use __BEGIN_DECLS / __END_DECLS consistently for _KERNEL part too. Don't pollute namespace by including sys/sysctl.h for !_KERNEL part. To generate a diff of this commit: cvs rdiff -u -r1.35 -r1.36 src/sys/sys/ipc.h Please note that diffs are not public domain; they are subject to the copyright notices on the relevant files.
Modified files: Index: src/sys/sys/ipc.h diff -u src/sys/sys/ipc.h:1.35 src/sys/sys/ipc.h:1.36 --- src/sys/sys/ipc.h:1.35 Wed May 13 01:23:10 2015 +++ src/sys/sys/ipc.h Tue May 19 12:17:53 2015 @@ -1,4 +1,4 @@ -/* $NetBSD: ipc.h,v 1.35 2015/05/13 01:23:10 pgoyette Exp $ */ +/* $NetBSD: ipc.h,v 1.36 2015/05/19 12:17:53 joerg Exp $ */ /* * Copyright (c) 1988 University of Utah. @@ -50,7 +50,6 @@ #include <sys/featuretest.h> #include <sys/types.h> -#include <sys/sysctl.h> struct ipc_perm { uid_t uid; /* user id */ @@ -108,14 +107,17 @@ struct ipc_perm_sysctl { #endif #ifdef _KERNEL +#include <sys/sysctl.h> #define IPCID_TO_IX(id) ((id) & 0xffff) #define IPCID_TO_SEQ(id) (((id) >> 16) & 0xffff) struct kauth_cred; +__BEGIN_DECLS int ipcperm(struct kauth_cred *, struct ipc_perm *, int); void sysvipcinit(void); void sysvipcfini(void); +__END_DECLS /* * sysctl helper routine for kern.ipc.sysvipc_info subtree. @@ -135,13 +137,11 @@ void sysvipcfini(void); * Set-up the sysctl routine for COMPAT_50 */ +__BEGIN_DECLS void sysvipc50_set_compat_sysctl(int (*)(SYSCTLFN_PROTO)); +__END_DECLS -#endif /* _KERNEL */ - -#ifndef _KERNEL -#include <sys/cdefs.h> - +#else /* _KERNEL */ __BEGIN_DECLS key_t ftok(const char *, int); __END_DECLS