aboutsummaryrefslogtreecommitdiff
diff options
context:
space:
mode:
-rw-r--r--ChangeLog.01
-rw-r--r--data/sandbox.bashrc2
-rw-r--r--libsandbox/canonicalize.c8
-rw-r--r--libsandbox/libsandbox.c23
-rw-r--r--libsandbox/libsandbox.h20
-rw-r--r--libsandbox/wrapper-funcs/__xmknod.c21
-rw-r--r--libsandbox/wrapper-funcs/access.c21
-rw-r--r--libsandbox/wrapper-funcs/chmod.c21
-rw-r--r--libsandbox/wrapper-funcs/chown.c21
-rw-r--r--libsandbox/wrapper-funcs/creat.c21
-rw-r--r--libsandbox/wrapper-funcs/creat64.c21
-rw-r--r--libsandbox/wrapper-funcs/execve.c21
-rw-r--r--libsandbox/wrapper-funcs/fopen.c21
-rw-r--r--libsandbox/wrapper-funcs/fopen64.c21
-rw-r--r--libsandbox/wrapper-funcs/getcwd.c21
-rw-r--r--libsandbox/wrapper-funcs/lchown.c21
-rw-r--r--libsandbox/wrapper-funcs/link.c24
-rw-r--r--libsandbox/wrapper-funcs/mkdir.c26
-rw-r--r--libsandbox/wrapper-funcs/mkfifo.c21
-rw-r--r--libsandbox/wrapper-funcs/mknod.c21
-rw-r--r--libsandbox/wrapper-funcs/open.c21
-rw-r--r--libsandbox/wrapper-funcs/open64.c21
-rw-r--r--libsandbox/wrapper-funcs/opendir.c24
-rw-r--r--libsandbox/wrapper-funcs/rename.c21
-rw-r--r--libsandbox/wrapper-funcs/rmdir.c24
-rw-r--r--libsandbox/wrapper-funcs/symlink.c24
-rw-r--r--libsandbox/wrapper-funcs/truncate.c21
-rw-r--r--libsandbox/wrapper-funcs/truncate64.c21
-rw-r--r--libsandbox/wrapper-funcs/unlink.c24
-rw-r--r--libsandbox/wrappers.c23
-rw-r--r--libsandbox/wrappers.h20
-rw-r--r--libsbutil/get_sandbox_debug_log.c24
-rw-r--r--libsbutil/get_sandbox_lib.c21
-rw-r--r--libsbutil/get_sandbox_log.c24
-rw-r--r--libsbutil/get_sandbox_rc.c22
-rw-r--r--libsbutil/get_tmp_dir.c24
-rw-r--r--libsbutil/include/rcscripts/core/services.h18
-rw-r--r--libsbutil/include/rcscripts/rccore.h18
-rw-r--r--libsbutil/include/rcscripts/rcdefines.h.in18
-rw-r--r--libsbutil/include/rcscripts/rctypes.h18
-rw-r--r--libsbutil/include/rcscripts/rcutil.h17
-rw-r--r--libsbutil/include/rcscripts/util/config.h18
-rw-r--r--libsbutil/include/rcscripts/util/debug.h18
-rw-r--r--libsbutil/include/rcscripts/util/dynbuf.h19
-rw-r--r--libsbutil/include/rcscripts/util/file.h18
-rw-r--r--libsbutil/include/rcscripts/util/list.h78
-rw-r--r--libsbutil/include/rcscripts/util/simple-regex.h18
-rw-r--r--libsbutil/include/rcscripts/util/str_list.h18
-rw-r--r--libsbutil/include/rcscripts/util/string.h18
-rw-r--r--libsbutil/is_env_off.c23
-rw-r--r--libsbutil/is_env_on.c23
-rw-r--r--libsbutil/sb_close.c21
-rw-r--r--libsbutil/sb_open.c23
-rw-r--r--libsbutil/sb_read.c21
-rw-r--r--libsbutil/sb_write.c23
-rw-r--r--libsbutil/sbutil.h20
-rw-r--r--libsbutil/src/config.c19
-rw-r--r--libsbutil/src/debug.c19
-rw-r--r--libsbutil/src/dynbuf.c19
-rw-r--r--libsbutil/src/file.c23
-rw-r--r--libsbutil/src/simple-regex.c21
-rw-r--r--libsbutil/src/string.c19
-rw-r--r--localdecls.h1
-rw-r--r--src/environ.c29
-rw-r--r--src/sandbox.c33
-rw-r--r--src/sandbox.h20
66 files changed, 184 insertions, 1203 deletions
diff --git a/ChangeLog.0 b/ChangeLog.0
index bb722d0..d6fcf85 100644
--- a/ChangeLog.0
+++ b/ChangeLog.0
@@ -1,6 +1,5 @@
# ChangeLog for Path Sandbox
# Copyright 1999-2005 Gentoo Foundation; Distributed under the GPL v2
-# $Header$
01 Dec 2005; Martin Schlemmer <azarah@gentoo.org> configure.in, Makefile.am,
localdecls.h, scripts/Makefile.am, scripts/gen_symbol_version_map.awk,
diff --git a/data/sandbox.bashrc b/data/sandbox.bashrc
index 39452d4..4368877 100644
--- a/data/sandbox.bashrc
+++ b/data/sandbox.bashrc
@@ -1,6 +1,5 @@
# Copyright (C) 2001 Geert Bevin, Uwyn, http://www.uwyn.com
# Distributed under the terms of the GNU General Public License, v2 or later
-# $Header$
if [[ -n ${LD_PRELOAD} && ${LD_PRELOAD} != *$SANDBOX_LIB* ]] ; then
export LD_PRELOAD="${SANDBOX_LIB} ${LD_PRELOAD}"
@@ -102,4 +101,3 @@ if [[ ${SANDBOX_INTRACTV} == "1" && -t 1 ]] ; then
done
unset var
fi
-
diff --git a/libsandbox/canonicalize.c b/libsandbox/canonicalize.c
index 3257653..0570d7d 100644
--- a/libsandbox/canonicalize.c
+++ b/libsandbox/canonicalize.c
@@ -17,10 +17,6 @@
Software Foundation, Inc., 59 Temple Place, Suite 330, Boston, MA
02111-1307 USA. */
-/*
- * $Header$
- */
-
#include <stdio.h>
#include <stdlib.h>
#include <string.h>
@@ -53,11 +49,11 @@
holds the same value as the value returned. */
/* Modified: 19 Aug 2002; Martin Schlemmer <azarah@gentoo.org>
- *
+ *
* Cleaned up unneeded stuff, and change so that it will not
* resolve symlinks. Also prepended a 'e' to functions that
* I did not rip out.
- *
+ *
*/
char *
diff --git a/libsandbox/libsandbox.c b/libsandbox/libsandbox.c
index 43e0cd2..49b4313 100644
--- a/libsandbox/libsandbox.c
+++ b/libsandbox/libsandbox.c
@@ -3,28 +3,11 @@
*
* Main libsandbox related functions.
*
- * Copyright 1999-2006 Gentoo Foundation
- *
- *
- * This program is free software; you can redistribute it and/or modify it
- * under the terms of the GNU General Public License as published by the
- * Free Software Foundation version 2 of the License.
- *
- * This program is distributed in the hope that it will be useful, but
- * WITHOUT ANY WARRANTY; without even the implied warranty of
- * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the GNU
- * General Public License for more details.
- *
- * You should have received a copy of the GNU General Public License along
- * with this program; if not, write to the Free Software Foundation, Inc.,
- * 675 Mass Ave, Cambridge, MA 02139, USA.
+ * Copyright 1999-2008 Gentoo Foundation
+ * Licensed under the GPL-2
*
* Partly Copyright (C) 1998-9 Pancrazio `Ezio' de Mauro <p@demauro.net>,
* as some of the InstallWatch code was used.
- *
- *
- * $Header$
- *
*/
/* Uncomment below to enable memory debugging. */
@@ -951,7 +934,7 @@ int before_syscall(const char *func, const char *file)
}
}
- if ((NULL == read && cached_env_vars[1] != read) || NULL == cached_env_vars[1] ||
+ if ((NULL == read && cached_env_vars[1] != read) || NULL == cached_env_vars[1] ||
strcmp(cached_env_vars[1], read) != 0) {
clean_env_entries(&(sbcontext.read_prefixes),
diff --git a/libsandbox/libsandbox.h b/libsandbox/libsandbox.h
index 9605800..ac43a03 100644
--- a/libsandbox/libsandbox.h
+++ b/libsandbox/libsandbox.h
@@ -3,23 +3,8 @@
*
* Defines related to libsandbox.
*
- * Copyright 1999-2006 Gentoo Foundation
- *
- *
- * This program is free software; you can redistribute it and/or modify it
- * under the terms of the GNU General Public License as published by the
- * Free Software Foundation version 2 of the License.
- *
- * This program is distributed in the hope that it will be useful, but
- * WITHOUT ANY WARRANTY; without even the implied warranty of
- * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the GNU
- * General Public License for more details.
- *
- * You should have received a copy of the GNU General Public License along
- * with this program; if not, write to the Free Software Foundation, Inc.,
- * 675 Mass Ave, Cambridge, MA 02139, USA.
- *
- * $Header$
+ * Copyright 1999-2008 Gentoo Foundation
+ * Licensed under the GPL-2
*/
#ifndef __LIBSANDBOX_H__
@@ -51,4 +36,3 @@ char *erealpath(const char *, char *);
char *egetcwd(char *, size_t);
#endif /* __LIBSANDBOX_H__ */
-
diff --git a/libsandbox/wrapper-funcs/__xmknod.c b/libsandbox/wrapper-funcs/__xmknod.c
index ec63c4c..98da369 100644
--- a/libsandbox/wrapper-funcs/__xmknod.c
+++ b/libsandbox/wrapper-funcs/__xmknod.c
@@ -3,29 +3,13 @@
*
* __xmknod() wrapper.
*
- * Copyright 1999-2006 Gentoo Foundation
- *
- *
- * This program is free software; you can redistribute it and/or modify it
- * under the terms of the GNU General Public License as published by the
- * Free Software Foundation version 2 of the License.
- *
- * This program is distributed in the hope that it will be useful, but
- * WITHOUT ANY WARRANTY; without even the implied warranty of
- * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the GNU
- * General Public License for more details.
- *
- * You should have received a copy of the GNU General Public License along
- * with this program; if not, write to the Free Software Foundation, Inc.,
- * 675 Mass Ave, Cambridge, MA 02139, USA.
+ * Copyright 1999-2008 Gentoo Foundation
+ * Licensed under the GPL-2
*
* Partly Copyright (C) 1998-9 Pancrazio `Ezio' de Mauro <p@demauro.net>,
* as some of the InstallWatch code was used.
- *
- * $Header$
*/
-
extern int EXTERN_NAME(int, const char *, __mode_t, __dev_t *);
static int (*WRAPPER_TRUE_NAME) (int, const char *, __mode_t, __dev_t *) = NULL;
@@ -41,4 +25,3 @@ int WRAPPER_NAME(int ver, const char *pathname, __mode_t mode, __dev_t *dev)
return result;
}
-
diff --git a/libsandbox/wrapper-funcs/access.c b/libsandbox/wrapper-funcs/access.c
index c4cd670..acc1e4b 100644
--- a/libsandbox/wrapper-funcs/access.c
+++ b/libsandbox/wrapper-funcs/access.c
@@ -3,29 +3,13 @@
*
* access() wrapper.
*
- * Copyright 1999-2006 Gentoo Foundation
- *
- *
- * This program is free software; you can redistribute it and/or modify it
- * under the terms of the GNU General Public License as published by the
- * Free Software Foundation version 2 of the License.
- *
- * This program is distributed in the hope that it will be useful, but
- * WITHOUT ANY WARRANTY; without even the implied warranty of
- * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the GNU
- * General Public License for more details.
- *
- * You should have received a copy of the GNU General Public License along
- * with this program; if not, write to the Free Software Foundation, Inc.,
- * 675 Mass Ave, Cambridge, MA 02139, USA.
+ * Copyright 1999-2008 Gentoo Foundation
+ * Licensed under the GPL-2
*
* Partly Copyright (C) 1998-9 Pancrazio `Ezio' de Mauro <p@demauro.net>,
* as some of the InstallWatch code was used.
- *
- * $Header$
*/
-
extern int EXTERN_NAME(const char *, int);
static int (*WRAPPER_TRUE_NAME) (const char *, int) = NULL;
@@ -41,4 +25,3 @@ int WRAPPER_NAME(const char *pathname, int mode)
return result;
}
-
diff --git a/libsandbox/wrapper-funcs/chmod.c b/libsandbox/wrapper-funcs/chmod.c
index f49bd57..49f7acc 100644
--- a/libsandbox/wrapper-funcs/chmod.c
+++ b/libsandbox/wrapper-funcs/chmod.c
@@ -3,29 +3,13 @@
*
* chmod() wrapper.
*
- * Copyright 1999-2006 Gentoo Foundation
- *
- *
- * This program is free software; you can redistribute it and/or modify it
- * under the terms of the GNU General Public License as published by the
- * Free Software Foundation version 2 of the License.
- *
- * This program is distributed in the hope that it will be useful, but
- * WITHOUT ANY WARRANTY; without even the implied warranty of
- * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the GNU
- * General Public License for more details.
- *
- * You should have received a copy of the GNU General Public License along
- * with this program; if not, write to the Free Software Foundation, Inc.,
- * 675 Mass Ave, Cambridge, MA 02139, USA.
+ * Copyright 1999-2008 Gentoo Foundation
+ * Licensed under the GPL-2
*
* Partly Copyright (C) 1998-9 Pancrazio `Ezio' de Mauro <p@demauro.net>,
* as some of the InstallWatch code was used.
- *
- * $Header$
*/
-
extern int EXTERN_NAME(const char *, mode_t);
static int (*WRAPPER_TRUE_NAME) (const char *, mode_t) = NULL;
@@ -41,4 +25,3 @@ int WRAPPER_NAME(const char *path, mode_t mode)
return result;
}
-
diff --git a/libsandbox/wrapper-funcs/chown.c b/libsandbox/wrapper-funcs/chown.c
index 6d07bce..1cd95cd 100644
--- a/libsandbox/wrapper-funcs/chown.c
+++ b/libsandbox/wrapper-funcs/chown.c
@@ -3,29 +3,13 @@
*
* chown() wrapper.
*
- * Copyright 1999-2006 Gentoo Foundation
- *
- *
- * This program is free software; you can redistribute it and/or modify it
- * under the terms of the GNU General Public License as published by the
- * Free Software Foundation version 2 of the License.
- *
- * This program is distributed in the hope that it will be useful, but
- * WITHOUT ANY WARRANTY; without even the implied warranty of
- * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the GNU
- * General Public License for more details.
- *
- * You should have received a copy of the GNU General Public License along
- * with this program; if not, write to the Free Software Foundation, Inc.,
- * 675 Mass Ave, Cambridge, MA 02139, USA.
+ * Copyright 1999-2008 Gentoo Foundation
+ * Licensed under the GPL-2
*
* Partly Copyright (C) 1998-9 Pancrazio `Ezio' de Mauro <p@demauro.net>,
* as some of the InstallWatch code was used.
- *
- * $Header$
*/
-
extern int EXTERN_NAME(const char *, uid_t, gid_t);
static int (*WRAPPER_TRUE_NAME) (const char *, uid_t, gid_t) = NULL;
@@ -41,4 +25,3 @@ int WRAPPER_NAME(const char *path, uid_t owner, gid_t group)
return result;
}
-
diff --git a/libsandbox/wrapper-funcs/creat.c b/libsandbox/wrapper-funcs/creat.c
index 19170e6..7d908e7 100644
--- a/libsandbox/wrapper-funcs/creat.c
+++ b/libsandbox/wrapper-funcs/creat.c
@@ -3,29 +3,13 @@
*
* creat() wrapper.
*
- * Copyright 1999-2006 Gentoo Foundation
- *
- *
- * This program is free software; you can redistribute it and/or modify it
- * under the terms of the GNU General Public License as published by the
- * Free Software Foundation version 2 of the License.
- *
- * This program is distributed in the hope that it will be useful, but
- * WITHOUT ANY WARRANTY; without even the implied warranty of
- * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the GNU
- * General Public License for more details.
- *
- * You should have received a copy of the GNU General Public License along
- * with this program; if not, write to the Free Software Foundation, Inc.,
- * 675 Mass Ave, Cambridge, MA 02139, USA.
+ * Copyright 1999-2008 Gentoo Foundation
+ * Licensed under the GPL-2
*
* Partly Copyright (C) 1998-9 Pancrazio `Ezio' de Mauro <p@demauro.net>,
* as some of the InstallWatch code was used.
- *
- * $Header$
*/
-
extern int EXTERN_NAME(const char *, mode_t);
/* XXX: We use the open() call to simulate create() */
/* static int (*WRAPPER_TRUE_NAME) (const char *, mode_t) = NULL; */
@@ -42,4 +26,3 @@ int WRAPPER_NAME(const char *pathname, mode_t mode)
return result;
}
-
diff --git a/libsandbox/wrapper-funcs/creat64.c b/libsandbox/wrapper-funcs/creat64.c
index 728e782..cfd3798 100644
--- a/libsandbox/wrapper-funcs/creat64.c
+++ b/libsandbox/wrapper-funcs/creat64.c
@@ -3,29 +3,13 @@
*
* creat64() wrapper.
*
- * Copyright 1999-2006 Gentoo Foundation
- *
- *
- * This program is free software; you can redistribute it and/or modify it
- * under the terms of the GNU General Public License as published by the
- * Free Software Foundation version 2 of the License.
- *
- * This program is distributed in the hope that it will be useful, but
- * WITHOUT ANY WARRANTY; without even the implied warranty of
- * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the GNU
- * General Public License for more details.
- *
- * You should have received a copy of the GNU General Public License along
- * with this program; if not, write to the Free Software Foundation, Inc.,
- * 675 Mass Ave, Cambridge, MA 02139, USA.
+ * Copyright 1999-2008 Gentoo Foundation
+ * Licensed under the GPL-2
*
* Partly Copyright (C) 1998-9 Pancrazio `Ezio' de Mauro <p@demauro.net>,
* as some of the InstallWatch code was used.
- *
- * $Header$
*/
-
extern int EXTERN_NAME(const char *, __mode_t);
/* XXX: We use the open64() call to simulate create64() */
/* static int (*WRAPPER_TRUE_NAME) (const char *, __mode_t) = NULL; */
@@ -42,4 +26,3 @@ int WRAPPER_NAME(const char *pathname, __mode_t mode)
return result;
}
-
diff --git a/libsandbox/wrapper-funcs/execve.c b/libsandbox/wrapper-funcs/execve.c
index 89f8b4a..757f179 100644
--- a/libsandbox/wrapper-funcs/execve.c
+++ b/libsandbox/wrapper-funcs/execve.c
@@ -3,29 +3,13 @@
*
* execve() wrapper.
*
- * Copyright 1999-2006 Gentoo Foundation
- *
- *
- * This program is free software; you can redistribute it and/or modify it
- * under the terms of the GNU General Public License as published by the
- * Free Software Foundation version 2 of the License.
- *
- * This program is distributed in the hope that it will be useful, but
- * WITHOUT ANY WARRANTY; without even the implied warranty of
- * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the GNU
- * General Public License for more details.
- *
- * You should have received a copy of the GNU General Public License along
- * with this program; if not, write to the Free Software Foundation, Inc.,
- * 675 Mass Ave, Cambridge, MA 02139, USA.
+ * Copyright 1999-2008 Gentoo Foundation
+ * Licensed under the GPL-2
*
* Partly Copyright (C) 1998-9 Pancrazio `Ezio' de Mauro <p@demauro.net>,
* as some of the InstallWatch code was used.
- *
- * $Header$
*/
-
extern int EXTERN_NAME(const char *, char *const[], char *const[]);
static int (*WRAPPER_TRUE_NAME) (const char *, char *const[], char *const[]) = NULL;
@@ -104,4 +88,3 @@ error:
return -1;
}
-
diff --git a/libsandbox/wrapper-funcs/fopen.c b/libsandbox/wrapper-funcs/fopen.c
index ec8de36..4962eee 100644
--- a/libsandbox/wrapper-funcs/fopen.c
+++ b/libsandbox/wrapper-funcs/fopen.c
@@ -3,29 +3,13 @@
*
* fopen() wrapper.
*
- * Copyright 1999-2006 Gentoo Foundation
- *
- *
- * This program is free software; you can redistribute it and/or modify it
- * under the terms of the GNU General Public License as published by the
- * Free Software Foundation version 2 of the License.
- *
- * This program is distributed in the hope that it will be useful, but
- * WITHOUT ANY WARRANTY; without even the implied warranty of
- * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the GNU
- * General Public License for more details.
- *
- * You should have received a copy of the GNU General Public License along
- * with this program; if not, write to the Free Software Foundation, Inc.,
- * 675 Mass Ave, Cambridge, MA 02139, USA.
+ * Copyright 1999-2008 Gentoo Foundation
+ * Licensed under the GPL-2
*
* Partly Copyright (C) 1998-9 Pancrazio `Ezio' de Mauro <p@demauro.net>,
* as some of the InstallWatch code was used.
- *
- * $Header$
*/
-
extern FILE *WRAPPER_NAME(const char *, const char *);
static FILE * (*WRAPPER_TRUE_NAME) (const char *, const char *) = NULL;
@@ -52,4 +36,3 @@ FILE *WRAPPER_NAME(const char *pathname, const char *mode)
return result;
}
-
diff --git a/libsandbox/wrapper-funcs/fopen64.c b/libsandbox/wrapper-funcs/fopen64.c
index fad5a9a..5134822 100644
--- a/libsandbox/wrapper-funcs/fopen64.c
+++ b/libsandbox/wrapper-funcs/fopen64.c
@@ -3,29 +3,13 @@
*
* fopen64() wrapper.
*
- * Copyright 1999-2006 Gentoo Foundation
- *
- *
- * This program is free software; you can redistribute it and/or modify it
- * under the terms of the GNU General Public License as published by the
- * Free Software Foundation version 2 of the License.
- *
- * This program is distributed in the hope that it will be useful, but
- * WITHOUT ANY WARRANTY; without even the implied warranty of
- * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the GNU
- * General Public License for more details.
- *
- * You should have received a copy of the GNU General Public License along
- * with this program; if not, write to the Free Software Foundation, Inc.,
- * 675 Mass Ave, Cambridge, MA 02139, USA.
+ * Copyright 1999-2008 Gentoo Foundation
+ * Licensed under the GPL-2
*
* Partly Copyright (C) 1998-9 Pancrazio `Ezio' de Mauro <p@demauro.net>,
* as some of the InstallWatch code was used.
- *
- * $Header$
*/
-
extern FILE *WRAPPER_NAME(const char *, const char *);
static FILE * (*WRAPPER_TRUE_NAME) (const char *, const char *) = NULL;
@@ -52,4 +36,3 @@ FILE *WRAPPER_NAME(const char *pathname, const char *mode)
return result;
}
-
diff --git a/libsandbox/wrapper-funcs/getcwd.c b/libsandbox/wrapper-funcs/getcwd.c
index bb49953..5cfc50d 100644
--- a/libsandbox/wrapper-funcs/getcwd.c
+++ b/libsandbox/wrapper-funcs/getcwd.c
@@ -3,29 +3,13 @@
*
* getcwd() wrapper.
*
- * Copyright 1999-2006 Gentoo Foundation
- *
- *
- * This program is free software; you can redistribute it and/or modify it
- * under the terms of the GNU General Public License as published by the
- * Free Software Foundation version 2 of the License.
- *
- * This program is distributed in the hope that it will be useful, but
- * WITHOUT ANY WARRANTY; without even the implied warranty of
- * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the GNU
- * General Public License for more details.
- *
- * You should have received a copy of the GNU General Public License along
- * with this program; if not, write to the Free Software Foundation, Inc.,
- * 675 Mass Ave, Cambridge, MA 02139, USA.
+ * Copyright 1999-2008 Gentoo Foundation
+ * Licensed under the GPL-2
*
* Partly Copyright (C) 1998-9 Pancrazio `Ezio' de Mauro <p@demauro.net>,
* as some of the InstallWatch code was used.
- *
- * $Header$
*/
-
extern char *WRAPPER_NAME(char *, size_t);
static char * (*WRAPPER_TRUE_NAME) (char *, size_t) = NULL;
@@ -45,4 +29,3 @@ char *WRAPPER_NAME(char *buf, size_t size)
return result;
}
-
diff --git a/libsandbox/wrapper-funcs/lchown.c b/libsandbox/wrapper-funcs/lchown.c
index 67e6a27..11de578 100644
--- a/libsandbox/wrapper-funcs/lchown.c
+++ b/libsandbox/wrapper-funcs/lchown.c
@@ -3,29 +3,13 @@
*
* lchown() wrapper.
*
- * Copyright 1999-2006 Gentoo Foundation
- *
- *
- * This program is free software; you can redistribute it and/or modify it
- * under the terms of the GNU General Public License as published by the
- * Free Software Foundation version 2 of the License.
- *
- * This program is distributed in the hope that it will be useful, but
- * WITHOUT ANY WARRANTY; without even the implied warranty of
- * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the GNU
- * General Public License for more details.
- *
- * You should have received a copy of the GNU General Public License along
- * with this program; if not, write to the Free Software Foundation, Inc.,
- * 675 Mass Ave, Cambridge, MA 02139, USA.
+ * Copyright 1999-2008 Gentoo Foundation
+ * Licensed under the GPL-2
*
* Partly Copyright (C) 1998-9 Pancrazio `Ezio' de Mauro <p@demauro.net>,
* as some of the InstallWatch code was used.
- *
- * $Header$
*/
-
extern int EXTERN_NAME(const char *, uid_t, gid_t);
static int (*WRAPPER_TRUE_NAME) (const char *, uid_t, gid_t) = NULL;
@@ -41,4 +25,3 @@ int WRAPPER_NAME(const char *path, uid_t owner, gid_t group)
return result;
}
-
diff --git a/libsandbox/wrapper-funcs/link.c b/libsandbox/wrapper-funcs/link.c
index 4386c7e..46cbbe0 100644
--- a/libsandbox/wrapper-funcs/link.c
+++ b/libsandbox/wrapper-funcs/link.c
@@ -3,29 +3,10 @@
*
* link() wrapper.
*
- * Copyright 1999-2006 Gentoo Foundation
- *
- *
- * This program is free software; you can redistribute it and/or modify it
- * under the terms of the GNU General Public License as published by the
- * Free Software Foundation version 2 of the License.
- *
- * This program is distributed in the hope that it will be useful, but
- * WITHOUT ANY WARRANTY; without even the implied warranty of
- * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the GNU
- * General Public License for more details.
- *
- * You should have received a copy of the GNU General Public License along
- * with this program; if not, write to the Free Software Foundation, Inc.,
- * 675 Mass Ave, Cambridge, MA 02139, USA.
- *
- * Partly Copyright (C) 1998-9 Pancrazio `Ezio' de Mauro <p@demauro.net>,
- * as some of the InstallWatch code was used.
- *
- * $Header$
+ * Copyright 1999-2008 Gentoo Foundation
+ * Licensed under the GPL-2
*/
-
extern int EXTERN_NAME(const char *, const char *);
static int (*WRAPPER_TRUE_NAME) (const char *, const char *) = NULL;
@@ -41,4 +22,3 @@ int WRAPPER_NAME(const char *oldpath, const char *newpath)
return result;
}
-
diff --git a/libsandbox/wrapper-funcs/mkdir.c b/libsandbox/wrapper-funcs/mkdir.c
index 8aded02..0c54de4 100644
--- a/libsandbox/wrapper-funcs/mkdir.c
+++ b/libsandbox/wrapper-funcs/mkdir.c
@@ -3,29 +3,10 @@
*
* mkdir() wrapper.
*
- * Copyright 1999-2006 Gentoo Foundation
- *
- *
- * This program is free software; you can redistribute it and/or modify it
- * under the terms of the GNU General Public License as published by the
- * Free Software Foundation version 2 of the License.
- *
- * This program is distributed in the hope that it will be useful, but
- * WITHOUT ANY WARRANTY; without even the implied warranty of
- * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the GNU
- * General Public License for more details.
- *
- * You should have received a copy of the GNU General Public License along
- * with this program; if not, write to the Free Software Foundation, Inc.,
- * 675 Mass Ave, Cambridge, MA 02139, USA.
- *
- * Partly Copyright (C) 1998-9 Pancrazio `Ezio' de Mauro <p@demauro.net>,
- * as some of the InstallWatch code was used.
- *
- * $Header$
+ * Copyright 1999-2008 Gentoo Foundation
+ * Licensed under the GPL-2
*/
-
extern int EXTERN_NAME(const char *, mode_t);
static int (*WRAPPER_TRUE_NAME) (const char *, mode_t) = NULL;
@@ -36,7 +17,7 @@ int WRAPPER_NAME(const char *pathname, mode_t mode)
char canonic[SB_PATH_MAX];
if (-1 == canonicalize(pathname, canonic))
- /* Path is too long to canonicalize, do not fail, but just let
+ /* Path is too long to canonicalize, do not fail, but just let
* the real function handle it (see bug #94630 and #21766). */
if (ENAMETOOLONG != errno)
return -1;
@@ -58,4 +39,3 @@ int WRAPPER_NAME(const char *pathname, mode_t mode)
return result;
}
-
diff --git a/libsandbox/wrapper-funcs/mkfifo.c b/libsandbox/wrapper-funcs/mkfifo.c
index 2c17fd6..94c183c 100644
--- a/libsandbox/wrapper-funcs/mkfifo.c
+++ b/libsandbox/wrapper-funcs/mkfifo.c
@@ -3,29 +3,13 @@
*
* mkfifo() wrapper.
*
- * Copyright 1999-2006 Gentoo Foundation
- *
- *
- * This program is free software; you can redistribute it and/or modify it
- * under the terms of the GNU General Public License as published by the
- * Free Software Foundation version 2 of the License.
- *
- * This program is distributed in the hope that it will be useful, but
- * WITHOUT ANY WARRANTY; without even the implied warranty of
- * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the GNU
- * General Public License for more details.
- *
- * You should have received a copy of the GNU General Public License along
- * with this program; if not, write to the Free Software Foundation, Inc.,
- * 675 Mass Ave, Cambridge, MA 02139, USA.
+ * Copyright 1999-2008 Gentoo Foundation
+ * Licensed under the GPL-2
*
* Partly Copyright (C) 1998-9 Pancrazio `Ezio' de Mauro <p@demauro.net>,
* as some of the InstallWatch code was used.
- *
- * $Header$
*/
-
extern int EXTERN_NAME(const char *, mode_t);
static int (*WRAPPER_TRUE_NAME) (const char *, mode_t) = NULL;
@@ -41,4 +25,3 @@ int WRAPPER_NAME(const char *pathname, mode_t mode)
return result;
}
-
diff --git a/libsandbox/wrapper-funcs/mknod.c b/libsandbox/wrapper-funcs/mknod.c
index f488e47..1aef84c 100644
--- a/libsandbox/wrapper-funcs/mknod.c
+++ b/libsandbox/wrapper-funcs/mknod.c
@@ -3,29 +3,13 @@
*
* mknod() wrapper.
*
- * Copyright 1999-2006 Gentoo Foundation
- *
- *
- * This program is free software; you can redistribute it and/or modify it
- * under the terms of the GNU General Public License as published by the
- * Free Software Foundation version 2 of the License.
- *
- * This program is distributed in the hope that it will be useful, but
- * WITHOUT ANY WARRANTY; without even the implied warranty of
- * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the GNU
- * General Public License for more details.
- *
- * You should have received a copy of the GNU General Public License along
- * with this program; if not, write to the Free Software Foundation, Inc.,
- * 675 Mass Ave, Cambridge, MA 02139, USA.
+ * Copyright 1999-2008 Gentoo Foundation
+ * Licensed under the GPL-2
*
* Partly Copyright (C) 1998-9 Pancrazio `Ezio' de Mauro <p@demauro.net>,
* as some of the InstallWatch code was used.
- *
- * $Header$
*/
-
extern int EXTERN_NAME(const char *, mode_t, dev_t);
static int (*WRAPPER_TRUE_NAME) (const char *, mode_t, dev_t) = NULL;
@@ -41,4 +25,3 @@ int WRAPPER_NAME(const char *pathname, mode_t mode, dev_t dev)
return result;
}
-
diff --git a/libsandbox/wrapper-funcs/open.c b/libsandbox/wrapper-funcs/open.c
index 084a700..0b4f04d 100644
--- a/libsandbox/wrapper-funcs/open.c
+++ b/libsandbox/wrapper-funcs/open.c
@@ -3,29 +3,13 @@
*
* open() wrapper.
*
- * Copyright 1999-2006 Gentoo Foundation
- *
- *
- * This program is free software; you can redistribute it and/or modify it
- * under the terms of the GNU General Public License as published by the
- * Free Software Foundation version 2 of the License.
- *
- * This program is distributed in the hope that it will be useful, but
- * WITHOUT ANY WARRANTY; without even the implied warranty of
- * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the GNU
- * General Public License for more details.
- *
- * You should have received a copy of the GNU General Public License along
- * with this program; if not, write to the Free Software Foundation, Inc.,
- * 675 Mass Ave, Cambridge, MA 02139, USA.
+ * Copyright 1999-2008 Gentoo Foundation
+ * Licensed under the GPL-2
*
* Partly Copyright (C) 1998-9 Pancrazio `Ezio' de Mauro <p@demauro.net>,
* as some of the InstallWatch code was used.
- *
- * $Header$
*/
-
extern int EXTERN_NAME(const char *, int, ...);
static int (*WRAPPER_TRUE_NAME) (const char *, int, ...) = NULL;
@@ -62,4 +46,3 @@ int WRAPPER_NAME(const char *pathname, int flags, ...)
return result;
}
-
diff --git a/libsandbox/wrapper-funcs/open64.c b/libsandbox/wrapper-funcs/open64.c
index 144045f..ff76247 100644
--- a/libsandbox/wrapper-funcs/open64.c
+++ b/libsandbox/wrapper-funcs/open64.c
@@ -3,29 +3,13 @@
*
* open64() wrapper.
*
- * Copyright 1999-2006 Gentoo Foundation
- *
- *
- * This program is free software; you can redistribute it and/or modify it
- * under the terms of the GNU General Public License as published by the
- * Free Software Foundation version 2 of the License.
- *
- * This program is distributed in the hope that it will be useful, but
- * WITHOUT ANY WARRANTY; without even the implied warranty of
- * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the GNU
- * General Public License for more details.
- *
- * You should have received a copy of the GNU General Public License along
- * with this program; if not, write to the Free Software Foundation, Inc.,
- * 675 Mass Ave, Cambridge, MA 02139, USA.
+ * Copyright 1999-2008 Gentoo Foundation
+ * Licensed under the GPL-2
*
* Partly Copyright (C) 1998-9 Pancrazio `Ezio' de Mauro <p@demauro.net>,
* as some of the InstallWatch code was used.
- *
- * $Header$
*/
-
extern int EXTERN_NAME(const char *, int, ...);
static int (*WRAPPER_TRUE_NAME) (const char *, int, ...) = NULL;
@@ -62,4 +46,3 @@ int WRAPPER_NAME(const char *pathname, int flags, ...)
return result;
}
-
diff --git a/libsandbox/wrapper-funcs/opendir.c b/libsandbox/wrapper-funcs/opendir.c
index c757865..6aa6db0 100644
--- a/libsandbox/wrapper-funcs/opendir.c
+++ b/libsandbox/wrapper-funcs/opendir.c
@@ -3,29 +3,10 @@
*
* opendir() wrapper.
*
- * Copyright 1999-2006 Gentoo Foundation
- *
- *
- * This program is free software; you can redistribute it and/or modify it
- * under the terms of the GNU General Public License as published by the
- * Free Software Foundation version 2 of the License.
- *
- * This program is distributed in the hope that it will be useful, but
- * WITHOUT ANY WARRANTY; without even the implied warranty of
- * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the GNU
- * General Public License for more details.
- *
- * You should have received a copy of the GNU General Public License along
- * with this program; if not, write to the Free Software Foundation, Inc.,
- * 675 Mass Ave, Cambridge, MA 02139, USA.
- *
- * Partly Copyright (C) 1998-9 Pancrazio `Ezio' de Mauro <p@demauro.net>,
- * as some of the InstallWatch code was used.
- *
- * $Header$
+ * Copyright 1999-2008 Gentoo Foundation
+ * Licensed under the GPL-2
*/
-
extern DIR *WRAPPER_NAME(const char *);
static DIR * (*WRAPPER_TRUE_NAME) (const char *) = NULL;
@@ -41,4 +22,3 @@ DIR *WRAPPER_NAME(const char *name)
return result;
}
-
diff --git a/libsandbox/wrapper-funcs/rename.c b/libsandbox/wrapper-funcs/rename.c
index cf13738..d7e0fa1 100644
--- a/libsandbox/wrapper-funcs/rename.c
+++ b/libsandbox/wrapper-funcs/rename.c
@@ -3,29 +3,13 @@
*
* rename() wrapper.
*
- * Copyright 1999-2006 Gentoo Foundation
- *
- *
- * This program is free software; you can redistribute it and/or modify it
- * under the terms of the GNU General Public License as published by the
- * Free Software Foundation version 2 of the License.
- *
- * This program is distributed in the hope that it will be useful, but
- * WITHOUT ANY WARRANTY; without even the implied warranty of
- * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the GNU
- * General Public License for more details.
- *
- * You should have received a copy of the GNU General Public License along
- * with this program; if not, write to the Free Software Foundation, Inc.,
- * 675 Mass Ave, Cambridge, MA 02139, USA.
+ * Copyright 1999-2008 Gentoo Foundation
+ * Licensed under the GPL-2
*
* Partly Copyright (C) 1998-9 Pancrazio `Ezio' de Mauro <p@demauro.net>,
* as some of the InstallWatch code was used.
- *
- * $Header$
*/
-
extern int EXTERN_NAME(const char *, const char *);
static int (*WRAPPER_TRUE_NAME) (const char *, const char *) = NULL;
@@ -42,4 +26,3 @@ int WRAPPER_NAME(const char *oldpath, const char *newpath)
return result;
}
-
diff --git a/libsandbox/wrapper-funcs/rmdir.c b/libsandbox/wrapper-funcs/rmdir.c
index ae4aed7..cc736fd 100644
--- a/libsandbox/wrapper-funcs/rmdir.c
+++ b/libsandbox/wrapper-funcs/rmdir.c
@@ -3,29 +3,10 @@
*
* rmdir() wrapper.
*
- * Copyright 1999-2006 Gentoo Foundation
- *
- *
- * This program is free software; you can redistribute it and/or modify it
- * under the terms of the GNU General Public License as published by the
- * Free Software Foundation version 2 of the License.
- *
- * This program is distributed in the hope that it will be useful, but
- * WITHOUT ANY WARRANTY; without even the implied warranty of
- * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the GNU
- * General Public License for more details.
- *
- * You should have received a copy of the GNU General Public License along
- * with this program; if not, write to the Free Software Foundation, Inc.,
- * 675 Mass Ave, Cambridge, MA 02139, USA.
- *
- * Partly Copyright (C) 1998-9 Pancrazio `Ezio' de Mauro <p@demauro.net>,
- * as some of the InstallWatch code was used.
- *
- * $Header$
+ * Copyright 1999-2008 Gentoo Foundation
+ * Licensed under the GPL-2
*/
-
extern int EXTERN_NAME(const char *);
static int (*WRAPPER_TRUE_NAME) (const char *) = NULL;
@@ -41,4 +22,3 @@ int WRAPPER_NAME(const char *pathname)
return result;
}
-
diff --git a/libsandbox/wrapper-funcs/symlink.c b/libsandbox/wrapper-funcs/symlink.c
index 2eecc81..1c7372f 100644
--- a/libsandbox/wrapper-funcs/symlink.c
+++ b/libsandbox/wrapper-funcs/symlink.c
@@ -3,29 +3,10 @@
*
* symlink() wrapper.
*
- * Copyright 1999-2006 Gentoo Foundation
- *
- *
- * This program is free software; you can redistribute it and/or modify it
- * under the terms of the GNU General Public License as published by the
- * Free Software Foundation version 2 of the License.
- *
- * This program is distributed in the hope that it will be useful, but
- * WITHOUT ANY WARRANTY; without even the implied warranty of
- * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the GNU
- * General Public License for more details.
- *
- * You should have received a copy of the GNU General Public License along
- * with this program; if not, write to the Free Software Foundation, Inc.,
- * 675 Mass Ave, Cambridge, MA 02139, USA.
- *
- * Partly Copyright (C) 1998-9 Pancrazio `Ezio' de Mauro <p@demauro.net>,
- * as some of the InstallWatch code was used.
- *
- * $Header$
+ * Copyright 1999-2008 Gentoo Foundation
+ * Licensed under the GPL-2
*/
-
extern int EXTERN_NAME(const char *, const char *);
static int (*WRAPPER_TRUE_NAME) (const char *, const char *) = NULL;
@@ -41,4 +22,3 @@ int WRAPPER_NAME(const char *oldpath, const char *newpath)
return result;
}
-
diff --git a/libsandbox/wrapper-funcs/truncate.c b/libsandbox/wrapper-funcs/truncate.c
index ca15893..5d59bc0 100644
--- a/libsandbox/wrapper-funcs/truncate.c
+++ b/libsandbox/wrapper-funcs/truncate.c
@@ -3,29 +3,13 @@
*
* truncate() wrapper.
*
- * Copyright 1999-2006 Gentoo Foundation
- *
- *
- * This program is free software; you can redistribute it and/or modify it
- * under the terms of the GNU General Public License as published by the
- * Free Software Foundation version 2 of the License.
- *
- * This program is distributed in the hope that it will be useful, but
- * WITHOUT ANY WARRANTY; without even the implied warranty of
- * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the GNU
- * General Public License for more details.
- *
- * You should have received a copy of the GNU General Public License along
- * with this program; if not, write to the Free Software Foundation, Inc.,
- * 675 Mass Ave, Cambridge, MA 02139, USA.
+ * Copyright 1999-2008 Gentoo Foundation
+ * Licensed under the GPL-2
*
* Partly Copyright (C) 1998-9 Pancrazio `Ezio' de Mauro <p@demauro.net>,
* as some of the InstallWatch code was used.
- *
- * $Header$
*/
-
extern int EXTERN_NAME(const char *, TRUNCATE_T);
static int (*WRAPPER_TRUE_NAME) (const char *, TRUNCATE_T) = NULL;
@@ -41,4 +25,3 @@ int WRAPPER_NAME(const char *path, TRUNCATE_T length)
return result;
}
-
diff --git a/libsandbox/wrapper-funcs/truncate64.c b/libsandbox/wrapper-funcs/truncate64.c
index 058a1cb..a5669f6 100644
--- a/libsandbox/wrapper-funcs/truncate64.c
+++ b/libsandbox/wrapper-funcs/truncate64.c
@@ -3,29 +3,13 @@
*
* truncate64() wrapper.
*
- * Copyright 1999-2006 Gentoo Foundation
- *
- *
- * This program is free software; you can redistribute it and/or modify it
- * under the terms of the GNU General Public License as published by the
- * Free Software Foundation version 2 of the License.
- *
- * This program is distributed in the hope that it will be useful, but
- * WITHOUT ANY WARRANTY; without even the implied warranty of
- * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the GNU
- * General Public License for more details.
- *
- * You should have received a copy of the GNU General Public License along
- * with this program; if not, write to the Free Software Foundation, Inc.,
- * 675 Mass Ave, Cambridge, MA 02139, USA.
+ * Copyright 1999-2008 Gentoo Foundation
+ * Licensed under the GPL-2
*
* Partly Copyright (C) 1998-9 Pancrazio `Ezio' de Mauro <p@demauro.net>,
* as some of the InstallWatch code was used.
- *
- * $Header$
*/
-
extern int EXTERN_NAME(const char *, __off64_t);
static int (*WRAPPER_TRUE_NAME) (const char *, __off64_t) = NULL;
@@ -41,4 +25,3 @@ int WRAPPER_NAME(const char *path, __off64_t length)
return result;
}
-
diff --git a/libsandbox/wrapper-funcs/unlink.c b/libsandbox/wrapper-funcs/unlink.c
index 75e341f..a8570ce 100644
--- a/libsandbox/wrapper-funcs/unlink.c
+++ b/libsandbox/wrapper-funcs/unlink.c
@@ -3,29 +3,10 @@
*
* unlink() wrapper.
*
- * Copyright 1999-2006 Gentoo Foundation
- *
- *
- * This program is free software; you can redistribute it and/or modify it
- * under the terms of the GNU General Public License as published by the
- * Free Software Foundation version 2 of the License.
- *
- * This program is distributed in the hope that it will be useful, but
- * WITHOUT ANY WARRANTY; without even the implied warranty of
- * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the GNU
- * General Public License for more details.
- *
- * You should have received a copy of the GNU General Public License along
- * with this program; if not, write to the Free Software Foundation, Inc.,
- * 675 Mass Ave, Cambridge, MA 02139, USA.
- *
- * Partly Copyright (C) 1998-9 Pancrazio `Ezio' de Mauro <p@demauro.net>,
- * as some of the InstallWatch code was used.
- *
- * $Header$
+ * Copyright 1999-2008 Gentoo Foundation
+ * Licensed under the GPL-2
*/
-
extern int EXTERN_NAME(const char *);
static int (*WRAPPER_TRUE_NAME) (const char *) = NULL;
@@ -57,4 +38,3 @@ int WRAPPER_NAME(const char *pathname)
return result;
}
-
diff --git a/libsandbox/wrappers.c b/libsandbox/wrappers.c
index 9e24a2a..051cdcb 100644
--- a/libsandbox/wrappers.c
+++ b/libsandbox/wrappers.c
@@ -3,29 +3,13 @@
*
* Function wrapping functions.
*
- * Copyright 1999-2006 Gentoo Foundation
- *
- *
- * This program is free software; you can redistribute it and/or modify it
- * under the terms of the GNU General Public License as published by the
- * Free Software Foundation version 2 of the License.
- *
- * This program is distributed in the hope that it will be useful, but
- * WITHOUT ANY WARRANTY; without even the implied warranty of
- * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the GNU
- * General Public License for more details.
- *
- * You should have received a copy of the GNU General Public License along
- * with this program; if not, write to the Free Software Foundation, Inc.,
- * 675 Mass Ave, Cambridge, MA 02139, USA.
+ * Copyright 1999-2008 Gentoo Foundation
+ * Licensed under the GPL-2
*
* Partly Copyright (C) 1998-9 Pancrazio `Ezio' de Mauro <p@demauro.net>,
* as some of the InstallWatch code was used.
- *
- * $Header$
*/
-
#include "config.h"
/* Better way would be to only define _GNU_SOURCE when __GLIBC__ is defined,
@@ -130,7 +114,6 @@ char *libsb_getcwd(char *buf, size_t size)
{
check_dlsym(true_getcwd_DEFAULT, symname_getcwd_DEFAULT,
symver_getcwd_DEFAULT);
-
+
return true_getcwd_DEFAULT(buf, size);
}
-
diff --git a/libsandbox/wrappers.h b/libsandbox/wrappers.h
index 474a128..9d2cfb0 100644
--- a/libsandbox/wrappers.h
+++ b/libsandbox/wrappers.h
@@ -3,23 +3,8 @@
*
* Function wrapping functions.
*
- * Copyright 1999-2006 Gentoo Foundation
- *
- *
- * This program is free software; you can redistribute it and/or modify it
- * under the terms of the GNU General Public License as published by the
- * Free Software Foundation version 2 of the License.
- *
- * This program is distributed in the hope that it will be useful, but
- * WITHOUT ANY WARRANTY; without even the implied warranty of
- * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the GNU
- * General Public License for more details.
- *
- * You should have received a copy of the GNU General Public License along
- * with this program; if not, write to the Free Software Foundation, Inc.,
- * 675 Mass Ave, Cambridge, MA 02139, USA.
- *
- * $Header$
+ * Copyright 1999-2008 Gentoo Foundation
+ * Licensed under the GPL-2
*/
#ifndef __WRAPPERS_H__
@@ -34,4 +19,3 @@ int libsb_open(const char *, int, ...);
char *libsb_getcwd(char *, size_t);
#endif /* __WRAPPERS_H__ */
-
diff --git a/libsbutil/get_sandbox_debug_log.c b/libsbutil/get_sandbox_debug_log.c
index 6a9bac2..2f7442a 100644
--- a/libsbutil/get_sandbox_debug_log.c
+++ b/libsbutil/get_sandbox_debug_log.c
@@ -3,30 +3,13 @@
*
* Util functions.
*
- * Copyright 1999-2006 Gentoo Foundation
- *
- *
- * This program is free software; you can redistribute it and/or modify it
- * under the terms of the GNU General Public License as published by the
- * Free Software Foundation version 2 of the License.
- *
- * This program is distributed in the hope that it will be useful, but
- * WITHOUT ANY WARRANTY; without even the implied warranty of
- * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the GNU
- * General Public License for more details.
- *
- * You should have received a copy of the GNU General Public License along
- * with this program; if not, write to the Free Software Foundation, Inc.,
- * 675 Mass Ave, Cambridge, MA 02139, USA.
+ * Copyright 1999-2008 Gentoo Foundation
+ * Licensed under the GPL-2
*
* Some parts might have Copyright:
- *
* Copyright (C) 2002 Brad House <brad@mainstreetsoftworks.com>
- *
- * $Header$
*/
-
#include <errno.h>
#include <stdio.h>
#include <stdlib.h>
@@ -43,7 +26,7 @@ void get_sandbox_debug_log(char *path)
save_errno();
sandbox_debug_log_env = getenv(ENV_SANDBOX_DEBUG_LOG);
-
+
/* THIS CHUNK BREAK THINGS BY DOING THIS:
* SANDBOX_DEBUG_LOG=/tmp/sandbox-app-admin/superadduser-1.0.7-11063.log
*/
@@ -59,4 +42,3 @@ void get_sandbox_debug_log(char *path)
restore_errno();
}
-
diff --git a/libsbutil/get_sandbox_lib.c b/libsbutil/get_sandbox_lib.c
index 8e9b391..375282c 100644
--- a/libsbutil/get_sandbox_lib.c
+++ b/libsbutil/get_sandbox_lib.c
@@ -3,30 +3,13 @@
*
* Util functions.
*
- * Copyright 1999-2006 Gentoo Foundation
- *
- *
- * This program is free software; you can redistribute it and/or modify it
- * under the terms of the GNU General Public License as published by the
- * Free Software Foundation version 2 of the License.
- *
- * This program is distributed in the hope that it will be useful, but
- * WITHOUT ANY WARRANTY; without even the implied warranty of
- * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the GNU
- * General Public License for more details.
- *
- * You should have received a copy of the GNU General Public License along
- * with this program; if not, write to the Free Software Foundation, Inc.,
- * 675 Mass Ave, Cambridge, MA 02139, USA.
+ * Copyright 1999-2008 Gentoo Foundation
+ * Licensed under the GPL-2
*
* Some parts might have Copyright:
- *
* Copyright (C) 2002 Brad House <brad@mainstreetsoftworks.com>
- *
- * $Header$
*/
-
#include <errno.h>
#include <stdio.h>
diff --git a/libsbutil/get_sandbox_log.c b/libsbutil/get_sandbox_log.c
index 74f4400..77f1208 100644
--- a/libsbutil/get_sandbox_log.c
+++ b/libsbutil/get_sandbox_log.c
@@ -3,30 +3,13 @@
*
* Util functions.
*
- * Copyright 1999-2006 Gentoo Foundation
- *
- *
- * This program is free software; you can redistribute it and/or modify it
- * under the terms of the GNU General Public License as published by the
- * Free Software Foundation version 2 of the License.
- *
- * This program is distributed in the hope that it will be useful, but
- * WITHOUT ANY WARRANTY; without even the implied warranty of
- * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the GNU
- * General Public License for more details.
- *
- * You should have received a copy of the GNU General Public License along
- * with this program; if not, write to the Free Software Foundation, Inc.,
- * 675 Mass Ave, Cambridge, MA 02139, USA.
+ * Copyright 1999-2008 Gentoo Foundation
+ * Licensed under the GPL-2
*
* Some parts might have Copyright:
- *
* Copyright (C) 2002 Brad House <brad@mainstreetsoftworks.com>
- *
- * $Header$
*/
-
#include <errno.h>
#include <stdio.h>
#include <stdlib.h>
@@ -43,7 +26,7 @@ void get_sandbox_log(char *path)
save_errno();
sandbox_log_env = getenv(ENV_SANDBOX_LOG);
-
+
/* THIS CHUNK BREAK THINGS BY DOING THIS:
* SANDBOX_LOG=/tmp/sandbox-app-admin/superadduser-1.0.7-11063.log
*/
@@ -59,4 +42,3 @@ void get_sandbox_log(char *path)
restore_errno();
}
-
diff --git a/libsbutil/get_sandbox_rc.c b/libsbutil/get_sandbox_rc.c
index 9771850..cdbdb73 100644
--- a/libsbutil/get_sandbox_rc.c
+++ b/libsbutil/get_sandbox_rc.c
@@ -3,30 +3,13 @@
*
* Util functions.
*
- * Copyright 1999-2006 Gentoo Foundation
- *
- *
- * This program is free software; you can redistribute it and/or modify it
- * under the terms of the GNU General Public License as published by the
- * Free Software Foundation version 2 of the License.
- *
- * This program is distributed in the hope that it will be useful, but
- * WITHOUT ANY WARRANTY; without even the implied warranty of
- * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the GNU
- * General Public License for more details.
- *
- * You should have received a copy of the GNU General Public License along
- * with this program; if not, write to the Free Software Foundation, Inc.,
- * 675 Mass Ave, Cambridge, MA 02139, USA.
+ * Copyright 1999-2008 Gentoo Foundation
+ * Licensed under the GPL-2
*
* Some parts might have Copyright:
- *
* Copyright (C) 2002 Brad House <brad@mainstreetsoftworks.com>
- *
- * $Header$
*/
-
#include <errno.h>
#include <stdio.h>
@@ -38,4 +21,3 @@ void get_sandbox_rc(char *path)
snprintf(path, SB_PATH_MAX, "%s/%s", SANDBOX_BASHRC_PATH, BASHRC_NAME);
restore_errno();
}
-
diff --git a/libsbutil/get_tmp_dir.c b/libsbutil/get_tmp_dir.c
index d804d96..75ee40f 100644
--- a/libsbutil/get_tmp_dir.c
+++ b/libsbutil/get_tmp_dir.c
@@ -3,30 +3,13 @@
*
* Util functions.
*
- * Copyright 1999-2006 Gentoo Foundation
- *
- *
- * This program is free software; you can redistribute it and/or modify it
- * under the terms of the GNU General Public License as published by the
- * Free Software Foundation version 2 of the License.
- *
- * This program is distributed in the hope that it will be useful, but
- * WITHOUT ANY WARRANTY; without even the implied warranty of
- * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the GNU
- * General Public License for more details.
- *
- * You should have received a copy of the GNU General Public License along
- * with this program; if not, write to the Free Software Foundation, Inc.,
- * 675 Mass Ave, Cambridge, MA 02139, USA.
+ * Copyright 1999-2008 Gentoo Foundation
+ * Licensed under the GPL-2
*
* Some parts might have Copyright:
- *
* Copyright (C) 2002 Brad House <brad@mainstreetsoftworks.com>
- *
- * $Header$
*/
-
#include <errno.h>
#include <limits.h>
#include <stdlib.h>
@@ -46,7 +29,6 @@ int get_tmp_dir(char *path)
/* Reset errno in case realpath set it */
restore_errno();
-
+
return 0;
}
-
diff --git a/libsbutil/include/rcscripts/core/services.h b/libsbutil/include/rcscripts/core/services.h
index 4245bab..38b67bc 100644
--- a/libsbutil/include/rcscripts/core/services.h
+++ b/libsbutil/include/rcscripts/core/services.h
@@ -3,23 +3,9 @@
*
* Functions dealing with services.
*
+ * Copyright 1999-2008 Gentoo Foundation
* Copyright 2004-2007 Martin Schlemmer <azarah@nosferatu.za.org>
- *
- *
- * This program is free software; you can redistribute it and/or modify it
- * under the terms of the GNU General Public License as published by the
- * Free Software Foundation version 2 of the License.
- *
- * This program is distributed in the hope that it will be useful, but
- * WITHOUT ANY WARRANTY; without even the implied warranty of
- * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the GNU
- * General Public License for more details.
- *
- * You should have received a copy of the GNU General Public License along
- * with this program; if not, write to the Free Software Foundation, Inc.,
- * 675 Mass Ave, Cambridge, MA 02139, USA.
- *
- * $Header$
+ * Licensed under the GPL-2
*/
#ifndef __RC_SERVICES_H__
diff --git a/libsbutil/include/rcscripts/rccore.h b/libsbutil/include/rcscripts/rccore.h
index 9b6a3ef..aa7a54e 100644
--- a/libsbutil/include/rcscripts/rccore.h
+++ b/libsbutil/include/rcscripts/rccore.h
@@ -3,23 +3,9 @@
*
* Core includes.
*
+ * Copyright 1999-2008 Gentoo Foundation
* Copyright 2004-2007 Martin Schlemmer <azarah@nosferatu.za.org>
- *
- *
- * This program is free software; you can redistribute it and/or modify it
- * under the terms of the GNU General Public License as published by the
- * Free Software Foundation version 2 of the License.
- *
- * This program is distributed in the hope that it will be useful, but
- * WITHOUT ANY WARRANTY; without even the implied warranty of
- * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the GNU
- * General Public License for more details.
- *
- * You should have received a copy of the GNU General Public License along
- * with this program; if not, write to the Free Software Foundation, Inc.,
- * 675 Mass Ave, Cambridge, MA 02139, USA.
- *
- * $Header$
+ * Licensed under the GPL-2
*/
#ifndef __RCCORE_H__
diff --git a/libsbutil/include/rcscripts/rcdefines.h.in b/libsbutil/include/rcscripts/rcdefines.h.in
index 9815873..7c604db 100644
--- a/libsbutil/include/rcscripts/rcdefines.h.in
+++ b/libsbutil/include/rcscripts/rcdefines.h.in
@@ -3,23 +3,9 @@
*
* Core defines.
*
+ * Copyright 1999-2008 Gentoo Foundation
* Copyright 2004-2007 Martin Schlemmer <azarah@nosferatu.za.org>
- *
- *
- * This program is free software; you can redistribute it and/or modify it
- * under the terms of the GNU General Public License as published by the
- * Free Software Foundation version 2 of the License.
- *
- * This program is distributed in the hope that it will be useful, but
- * WITHOUT ANY WARRANTY; without even the implied warranty of
- * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the GNU
- * General Public License for more details.
- *
- * You should have received a copy of the GNU General Public License along
- * with this program; if not, write to the Free Software Foundation, Inc.,
- * 675 Mass Ave, Cambridge, MA 02139, USA.
- *
- * $Header$
+ * Licensed under the GPL-2
*/
#ifndef __RCDEFINES_H__
diff --git a/libsbutil/include/rcscripts/rctypes.h b/libsbutil/include/rcscripts/rctypes.h
index 4ce2118..26400b5 100644
--- a/libsbutil/include/rcscripts/rctypes.h
+++ b/libsbutil/include/rcscripts/rctypes.h
@@ -3,23 +3,9 @@
*
* Misc types and macro's.
*
+ * Copyright 1999-2008 Gentoo Foundation
* Copyright 2004-2007 Martin Schlemmer <azarah@nosferatu.za.org>
- *
- *
- * This program is free software; you can redistribute it and/or modify it
- * under the terms of the GNU General Public License as published by the
- * Free Software Foundation version 2 of the License.
- *
- * This program is distributed in the hope that it will be useful, but
- * WITHOUT ANY WARRANTY; without even the implied warranty of
- * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the GNU
- * General Public License for more details.
- *
- * You should have received a copy of the GNU General Public License along
- * with this program; if not, write to the Free Software Foundation, Inc.,
- * 675 Mass Ave, Cambridge, MA 02139, USA.
- *
- * $Header$
+ * Licensed under the GPL-2
*/
#ifndef __RCTYPES_H__
diff --git a/libsbutil/include/rcscripts/rcutil.h b/libsbutil/include/rcscripts/rcutil.h
index 58fbe97..516d41e 100644
--- a/libsbutil/include/rcscripts/rcutil.h
+++ b/libsbutil/include/rcscripts/rcutil.h
@@ -3,23 +3,8 @@
*
* Util defines.
*
+ * Copyright 1999-2008 Gentoo Foundation
* Copyright 2004-2007 Martin Schlemmer <azarah@nosferatu.za.org>
- *
- *
- * This program is free software; you can redistribute it and/or modify it
- * under the terms of the GNU General Public License as published by the
- * Free Software Foundation version 2 of the License.
- *
- * This program is distributed in the hope that it will be useful, but
- * WITHOUT ANY WARRANTY; without even the implied warranty of
- * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the GNU
- * General Public License for more details.
- *
- * You should have received a copy of the GNU General Public License along
- * with this program; if not, write to the Free Software Foundation, Inc.,
- * 675 Mass Ave, Cambridge, MA 02139, USA.
- *
- * $Header$
*/
#ifndef __RCUTIL_H__
diff --git a/libsbutil/include/rcscripts/util/config.h b/libsbutil/include/rcscripts/util/config.h
index b45ac47..ad392f4 100644
--- a/libsbutil/include/rcscripts/util/config.h
+++ b/libsbutil/include/rcscripts/util/config.h
@@ -3,23 +3,9 @@
*
* Miscellaneous config related macro's and functions.
*
+ * Copyright 1999-2008 Gentoo Foundation
* Copyright 2004-2007 Martin Schlemmer <azarah@nosferatu.za.org>
- *
- *
- * This program is free software; you can redistribute it and/or modify it
- * under the terms of the GNU General Public License as published by the
- * Free Software Foundation version 2 of the License.
- *
- * This program is distributed in the hope that it will be useful, but
- * WITHOUT ANY WARRANTY; without even the implied warranty of
- * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the GNU
- * General Public License for more details.
- *
- * You should have received a copy of the GNU General Public License along
- * with this program; if not, write to the Free Software Foundation, Inc.,
- * 675 Mass Ave, Cambridge, MA 02139, USA.
- *
- * $Header$
+ * Licensed under the GPL-2
*/
#ifndef __RC_CONFIG_H__
diff --git a/libsbutil/include/rcscripts/util/debug.h b/libsbutil/include/rcscripts/util/debug.h
index 522ee25..b177c4f 100644
--- a/libsbutil/include/rcscripts/util/debug.h
+++ b/libsbutil/include/rcscripts/util/debug.h
@@ -3,23 +3,9 @@
*
* Simle debugging/logging macro's and functions.
*
+ * Copyright 1999-2008 Gentoo Foundation
* Copyright 2004-2007 Martin Schlemmer <azarah@nosferatu.za.org>
- *
- *
- * This program is free software; you can redistribute it and/or modify it
- * under the terms of the GNU General Public License as published by the
- * Free Software Foundation version 2 of the License.
- *
- * This program is distributed in the hope that it will be useful, but
- * WITHOUT ANY WARRANTY; without even the implied warranty of
- * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the GNU
- * General Public License for more details.
- *
- * You should have received a copy of the GNU General Public License along
- * with this program; if not, write to the Free Software Foundation, Inc.,
- * 675 Mass Ave, Cambridge, MA 02139, USA.
- *
- * $Header$
+ * Licensed under the GPL-2
*/
#ifndef __RC_DEBUG_H__
diff --git a/libsbutil/include/rcscripts/util/dynbuf.h b/libsbutil/include/rcscripts/util/dynbuf.h
index 1349014..359c3b4 100644
--- a/libsbutil/include/rcscripts/util/dynbuf.h
+++ b/libsbutil/include/rcscripts/util/dynbuf.h
@@ -3,23 +3,9 @@
*
* Dynamic allocated buffers.
*
+ * Copyright 1999-2008 Gentoo Foundation
* Copyright 2004-2007 Martin Schlemmer <azarah@nosferatu.za.org>
- *
- *
- * This program is free software; you can redistribute it and/or modify it
- * under the terms of the GNU General Public License as published by the
- * Free Software Foundation version 2 of the License.
- *
- * This program is distributed in the hope that it will be useful, but
- * WITHOUT ANY WARRANTY; without even the implied warranty of
- * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the GNU
- * General Public License for more details.
- *
- * You should have received a copy of the GNU General Public License along
- * with this program; if not, write to the Free Software Foundation, Inc.,
- * 675 Mass Ave, Cambridge, MA 02139, USA.
- *
- * $Header$
+ * Licensed under the GPL-2
*/
#ifndef __RC_DYNBUF_H__
@@ -64,4 +50,3 @@ inline bool __rc_check_arg_dynbuf (rc_dynbuf_t *dynbuf, const char *file,
__rc_check_arg_dynbuf (_dynbuf, __FILE__, __func__, __LINE__)
#endif /* __RC_DYNBUF_H__ */
-
diff --git a/libsbutil/include/rcscripts/util/file.h b/libsbutil/include/rcscripts/util/file.h
index 7ace060..519ee18 100644
--- a/libsbutil/include/rcscripts/util/file.h
+++ b/libsbutil/include/rcscripts/util/file.h
@@ -3,23 +3,9 @@
*
* Miscellaneous file related macro's and functions.
*
+ * Copyright 1999-2008 Gentoo Foundation
* Copyright 2004-2007 Martin Schlemmer <azarah@nosferatu.za.org>
- *
- *
- * This program is free software; you can redistribute it and/or modify it
- * under the terms of the GNU General Public License as published by the
- * Free Software Foundation version 2 of the License.
- *
- * This program is distributed in the hope that it will be useful, but
- * WITHOUT ANY WARRANTY; without even the implied warranty of
- * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the GNU
- * General Public License for more details.
- *
- * You should have received a copy of the GNU General Public License along
- * with this program; if not, write to the Free Software Foundation, Inc.,
- * 675 Mass Ave, Cambridge, MA 02139, USA.
- *
- * $Header$
+ * Licensed under the GPL-2
*/
#ifndef __RC_FILE_H__
diff --git a/libsbutil/include/rcscripts/util/list.h b/libsbutil/include/rcscripts/util/list.h
index e4c7a74..a1d988b 100644
--- a/libsbutil/include/rcscripts/util/list.h
+++ b/libsbutil/include/rcscripts/util/list.h
@@ -1,11 +1,9 @@
-/*
+/*
* Copied from the Linux kernel source tree, version 2.6.0-test1.
*
* Licensed under the GPL v2 as per the whole kernel source tree.
*
* Ripped out the rcu stuff, as it's not needed.
- *
- * $Header$
*/
#ifndef __LINUX_LIST_H__
@@ -61,7 +59,7 @@ struct list_head {
} while (0)
/*
- * Insert a new entry between two known consecutive entries.
+ * Insert a new entry between two known consecutive entries.
*
* This is only for internal list manipulation where we know
* the prev/next entries already!
@@ -135,7 +133,7 @@ static inline void list_del(struct list_head *entry)
static inline void list_del_init(struct list_head *entry)
{
__list_del(entry->prev, entry->next);
- INIT_LIST_HEAD(entry);
+ INIT_LIST_HEAD(entry);
}
/**
@@ -250,7 +248,7 @@ static inline void list_splice_init(struct list_head *list,
#define list_for_each_prev(pos, head) \
for (pos = (head)->prev, prefetch(pos->prev); pos != (head); \
pos = pos->prev, prefetch(pos->prev))
-
+
/**
* list_for_each_safe - iterate over a list safe against removal of list entry
* @pos: the &struct list_head to use as a loop counter.
@@ -301,44 +299,44 @@ static inline void list_splice_init(struct list_head *list,
&pos->member != (head); \
pos = n, n = list_entry(n->member.next, typeof(*n), member))
-/*
- * Double linked lists with a single pointer list head.
- * Mostly useful for hash tables where the two pointer list head is
+/*
+ * Double linked lists with a single pointer list head.
+ * Mostly useful for hash tables where the two pointer list head is
* too wasteful.
* You lose the ability to access the tail in O(1).
- */
+ */
-struct hlist_head {
- struct hlist_node *first;
-};
+struct hlist_head {
+ struct hlist_node *first;
+};
-struct hlist_node {
- struct hlist_node *next, **pprev;
-};
+struct hlist_node {
+ struct hlist_node *next, **pprev;
+};
-#define HLIST_HEAD_INIT { .first = NULL }
+#define HLIST_HEAD_INIT { .first = NULL }
#define HLIST_HEAD(name) struct hlist_head name = { .first = NULL }
-#define INIT_HLIST_HEAD(ptr) ((ptr)->first = NULL)
+#define INIT_HLIST_HEAD(ptr) ((ptr)->first = NULL)
#define INIT_HLIST_NODE(ptr) ((ptr)->next = NULL, (ptr)->pprev = NULL)
-static __inline__ int hlist_unhashed(struct hlist_node *h)
-{
+static __inline__ int hlist_unhashed(struct hlist_node *h)
+{
return !h->pprev;
-}
+}
-static __inline__ int hlist_empty(struct hlist_head *h)
-{
+static __inline__ int hlist_empty(struct hlist_head *h)
+{
return !h->first;
-}
+}
-static __inline__ void __hlist_del(struct hlist_node *n)
+static __inline__ void __hlist_del(struct hlist_node *n)
{
struct hlist_node *next = n->next;
struct hlist_node **pprev = n->pprev;
- *pprev = next;
- if (next)
+ *pprev = next;
+ if (next)
next->pprev = pprev;
-}
+}
static __inline__ void hlist_del(struct hlist_node *n)
{
@@ -347,30 +345,30 @@ static __inline__ void hlist_del(struct hlist_node *n)
n->pprev = LIST_POISON2;
}
-static __inline__ void hlist_del_init(struct hlist_node *n)
+static __inline__ void hlist_del_init(struct hlist_node *n)
{
if (n->pprev) {
__hlist_del(n);
INIT_HLIST_NODE(n);
}
-}
+}
-static __inline__ void hlist_add_head(struct hlist_node *n, struct hlist_head *h)
-{
+static __inline__ void hlist_add_head(struct hlist_node *n, struct hlist_head *h)
+{
struct hlist_node *first = h->first;
- n->next = first;
- if (first)
+ n->next = first;
+ if (first)
first->pprev = &n->next;
- h->first = n;
- n->pprev = &h->first;
-}
+ h->first = n;
+ n->pprev = &h->first;
+}
/* next must be != NULL */
static __inline__ void hlist_add_before(struct hlist_node *n, struct hlist_node *next)
{
n->pprev = next->pprev;
- n->next = next;
- next->pprev = &n->next;
+ n->next = next;
+ next->pprev = &n->next;
*(n->pprev) = n;
}
@@ -387,7 +385,7 @@ static __inline__ void hlist_add_after(struct hlist_node *n,
/* Cannot easily do prefetch unfortunately */
#define hlist_for_each(pos, head) \
for (pos = (head)->first; pos && ({ prefetch(pos->next); 1; }); \
- pos = pos->next)
+ pos = pos->next)
#define hlist_for_each_safe(pos, n, head) \
for (pos = (head)->first; n = pos ? pos->next : 0, pos; \
diff --git a/libsbutil/include/rcscripts/util/simple-regex.h b/libsbutil/include/rcscripts/util/simple-regex.h
index 56da8b0..f0a6ad7 100644
--- a/libsbutil/include/rcscripts/util/simple-regex.h
+++ b/libsbutil/include/rcscripts/util/simple-regex.h
@@ -3,23 +3,9 @@
*
* Simle regex library.
*
+ * Copyright 1999-2008 Gentoo Foundation
* Copyright 2004-2007 Martin Schlemmer <azarah@nosferatu.za.org>
- *
- *
- * This program is free software; you can redistribute it and/or modify it
- * under the terms of the GNU General Public License as published by the
- * Free Software Foundation version 2 of the License.
- *
- * This program is distributed in the hope that it will be useful, but
- * WITHOUT ANY WARRANTY; without even the implied warranty of
- * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the GNU
- * General Public License for more details.
- *
- * You should have received a copy of the GNU General Public License along
- * with this program; if not, write to the Free Software Foundation, Inc.,
- * 675 Mass Ave, Cambridge, MA 02139, USA.
- *
- * $Header$
+ * Licensed under the GPL-2
*/
#ifndef __RC_SIMPLE_REGEX_H__
diff --git a/libsbutil/include/rcscripts/util/str_list.h b/libsbutil/include/rcscripts/util/str_list.h
index f0c9355..068f902 100644
--- a/libsbutil/include/rcscripts/util/str_list.h
+++ b/libsbutil/include/rcscripts/util/str_list.h
@@ -3,23 +3,9 @@
*
* String list macros.
*
+ * Copyright 1999-2008 Gentoo Foundation
* Copyright 2004-2007 Martin Schlemmer <azarah@nosferatu.za.org>
- *
- *
- * This program is free software; you can redistribute it and/or modify it
- * under the terms of the GNU General Public License as published by the
- * Free Software Foundation version 2 of the License.
- *
- * This program is distributed in the hope that it will be useful, but
- * WITHOUT ANY WARRANTY; without even the implied warranty of
- * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the GNU
- * General Public License for more details.
- *
- * You should have received a copy of the GNU General Public License along
- * with this program; if not, write to the Free Software Foundation, Inc.,
- * 675 Mass Ave, Cambridge, MA 02139, USA.
- *
- * $Header$
+ * Licensed under the GPL-2
*/
#ifndef __RC_STR_LIST_H__
diff --git a/libsbutil/include/rcscripts/util/string.h b/libsbutil/include/rcscripts/util/string.h
index 9753d7a..25546e7 100644
--- a/libsbutil/include/rcscripts/util/string.h
+++ b/libsbutil/include/rcscripts/util/string.h
@@ -3,23 +3,9 @@
*
* Miscellaneous string related macro's and functions.
*
+ * Copyright 1999-2008 Gentoo Foundation
* Copyright 2004-2007 Martin Schlemmer <azarah@nosferatu.za.org>
- *
- *
- * This program is free software; you can redistribute it and/or modify it
- * under the terms of the GNU General Public License as published by the
- * Free Software Foundation version 2 of the License.
- *
- * This program is distributed in the hope that it will be useful, but
- * WITHOUT ANY WARRANTY; without even the implied warranty of
- * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the GNU
- * General Public License for more details.
- *
- * You should have received a copy of the GNU General Public License along
- * with this program; if not, write to the Free Software Foundation, Inc.,
- * 675 Mass Ave, Cambridge, MA 02139, USA.
- *
- * $Header$
+ * Licensed under the GPL-2
*/
#ifndef __RC_STRING_H__
diff --git a/libsbutil/is_env_off.c b/libsbutil/is_env_off.c
index b29e487..e8cd977 100644
--- a/libsbutil/is_env_off.c
+++ b/libsbutil/is_env_off.c
@@ -3,26 +3,10 @@
*
* Util functions.
*
- * Copyright 1999-2006 Gentoo Foundation
- *
- *
- * This program is free software; you can redistribute it and/or modify it
- * under the terms of the GNU General Public License as published by the
- * Free Software Foundation version 2 of the License.
- *
- * This program is distributed in the hope that it will be useful, but
- * WITHOUT ANY WARRANTY; without even the implied warranty of
- * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the GNU
- * General Public License for more details.
- *
- * You should have received a copy of the GNU General Public License along
- * with this program; if not, write to the Free Software Foundation, Inc.,
- * 675 Mass Ave, Cambridge, MA 02139, USA.
- *
- * $Header$
+ * Copyright 1999-2008 Gentoo Foundation
+ * Licensed under the GPL-2
*/
-
#include <errno.h>
#include <stdlib.h>
#include <string.h>
@@ -36,7 +20,6 @@ bool is_env_off (const char *env)
(0 == strncasecmp(getenv(env), "false", 5)) ||
(0 == strncasecmp(getenv(env), "no", 2))))
return TRUE;
-
+
return FALSE;
}
-
diff --git a/libsbutil/is_env_on.c b/libsbutil/is_env_on.c
index 0cfd174..9736779 100644
--- a/libsbutil/is_env_on.c
+++ b/libsbutil/is_env_on.c
@@ -3,26 +3,10 @@
*
* Util functions.
*
- * Copyright 1999-2006 Gentoo Foundation
- *
- *
- * This program is free software; you can redistribute it and/or modify it
- * under the terms of the GNU General Public License as published by the
- * Free Software Foundation version 2 of the License.
- *
- * This program is distributed in the hope that it will be useful, but
- * WITHOUT ANY WARRANTY; without even the implied warranty of
- * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the GNU
- * General Public License for more details.
- *
- * You should have received a copy of the GNU General Public License along
- * with this program; if not, write to the Free Software Foundation, Inc.,
- * 675 Mass Ave, Cambridge, MA 02139, USA.
- *
- * $Header$
+ * Copyright 1999-2008 Gentoo Foundation
+ * Licensed under the GPL-2
*/
-
#include <errno.h>
#include <stdlib.h>
#include <string.h>
@@ -36,7 +20,6 @@ bool is_env_on (const char *env)
(0 == strncasecmp(getenv(env), "true", 4)) ||
(0 == strncasecmp(getenv(env), "yes", 3))))
return TRUE;
-
+
return FALSE;
}
-
diff --git a/libsbutil/sb_close.c b/libsbutil/sb_close.c
index 76045f1..3d9c023 100644
--- a/libsbutil/sb_close.c
+++ b/libsbutil/sb_close.c
@@ -3,26 +3,10 @@
*
* IO functions.
*
- * Copyright 1999-2006 Gentoo Foundation
- *
- *
- * This program is free software; you can redistribute it and/or modify it
- * under the terms of the GNU General Public License as published by the
- * Free Software Foundation version 2 of the License.
- *
- * This program is distributed in the hope that it will be useful, but
- * WITHOUT ANY WARRANTY; without even the implied warranty of
- * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the GNU
- * General Public License for more details.
- *
- * You should have received a copy of the GNU General Public License along
- * with this program; if not, write to the Free Software Foundation, Inc.,
- * 675 Mass Ave, Cambridge, MA 02139, USA.
- *
- * $Header$
+ * Copyright 1999-2008 Gentoo Foundation
+ * Licensed under the GPL-2
*/
-
#include <errno.h>
#include <stdio.h>
#include <sys/stat.h>
@@ -50,4 +34,3 @@ int sb_close(int fd)
return res;
}
-
diff --git a/libsbutil/sb_open.c b/libsbutil/sb_open.c
index 1e5240f..2d9c403 100644
--- a/libsbutil/sb_open.c
+++ b/libsbutil/sb_open.c
@@ -3,26 +3,10 @@
*
* IO functions.
*
- * Copyright 1999-2006 Gentoo Foundation
- *
- *
- * This program is free software; you can redistribute it and/or modify it
- * under the terms of the GNU General Public License as published by the
- * Free Software Foundation version 2 of the License.
- *
- * This program is distributed in the hope that it will be useful, but
- * WITHOUT ANY WARRANTY; without even the implied warranty of
- * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the GNU
- * General Public License for more details.
- *
- * You should have received a copy of the GNU General Public License along
- * with this program; if not, write to the Free Software Foundation, Inc.,
- * 675 Mass Ave, Cambridge, MA 02139, USA.
- *
- * $Header$
+ * Copyright 1999-2008 Gentoo Foundation
+ * Licensed under the GPL-2
*/
-
#include <errno.h>
#include <stdio.h>
#include <sys/stat.h>
@@ -55,7 +39,7 @@ int sb_open(const char *path, int flags, mode_t mode)
do {
fd = sbio_open(path, flags, mode);
} while ((-1 == fd) && (EINTR == errno));
-
+
if ((-1 != fd) && (0 != errno))
/* Do not trigger debugging */
errno = 0;
@@ -65,4 +49,3 @@ int sb_open(const char *path, int flags, mode_t mode)
return fd;
}
-
diff --git a/libsbutil/sb_read.c b/libsbutil/sb_read.c
index c7bc74e..43fe3c7 100644
--- a/libsbutil/sb_read.c
+++ b/libsbutil/sb_read.c
@@ -3,26 +3,10 @@
*
* IO functions.
*
- * Copyright 1999-2006 Gentoo Foundation
- *
- *
- * This program is free software; you can redistribute it and/or modify it
- * under the terms of the GNU General Public License as published by the
- * Free Software Foundation version 2 of the License.
- *
- * This program is distributed in the hope that it will be useful, but
- * WITHOUT ANY WARRANTY; without even the implied warranty of
- * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the GNU
- * General Public License for more details.
- *
- * You should have received a copy of the GNU General Public License along
- * with this program; if not, write to the Free Software Foundation, Inc.,
- * 675 Mass Ave, Cambridge, MA 02139, USA.
- *
- * $Header$
+ * Copyright 1999-2008 Gentoo Foundation
+ * Licensed under the GPL-2
*/
-
#include <errno.h>
#include <stdio.h>
#include <sys/stat.h>
@@ -67,4 +51,3 @@ size_t sb_read(int fd, void *buf, size_t count)
return accum;
}
-
diff --git a/libsbutil/sb_write.c b/libsbutil/sb_write.c
index 53597e0..32f52f1 100644
--- a/libsbutil/sb_write.c
+++ b/libsbutil/sb_write.c
@@ -3,26 +3,10 @@
*
* IO functions.
*
- * Copyright 1999-2006 Gentoo Foundation
- *
- *
- * This program is free software; you can redistribute it and/or modify it
- * under the terms of the GNU General Public License as published by the
- * Free Software Foundation version 2 of the License.
- *
- * This program is distributed in the hope that it will be useful, but
- * WITHOUT ANY WARRANTY; without even the implied warranty of
- * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the GNU
- * General Public License for more details.
- *
- * You should have received a copy of the GNU General Public License along
- * with this program; if not, write to the Free Software Foundation, Inc.,
- * 675 Mass Ave, Cambridge, MA 02139, USA.
- *
- * $Header$
+ * Copyright 1999-2008 Gentoo Foundation
+ * Licensed under the GPL-2
*/
-
#include <errno.h>
#include <stdio.h>
#include <sys/stat.h>
@@ -58,7 +42,6 @@ size_t sb_write(int fd, const void *buf, size_t count)
accum += n;
} while (accum < count);
-
+
return accum;
}
-
diff --git a/libsbutil/sbutil.h b/libsbutil/sbutil.h
index 09a12a3..068f77b 100644
--- a/libsbutil/sbutil.h
+++ b/libsbutil/sbutil.h
@@ -3,27 +3,11 @@
*
* Util defines.
*
- * Copyright 1999-2006 Gentoo Foundation
- *
- *
- * This program is free software; you can redistribute it and/or modify it
- * under the terms of the GNU General Public License as published by the
- * Free Software Foundation version 2 of the License.
- *
- * This program is distributed in the hope that it will be useful, but
- * WITHOUT ANY WARRANTY; without even the implied warranty of
- * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the GNU
- * General Public License for more details.
- *
- * You should have received a copy of the GNU General Public License along
- * with this program; if not, write to the Free Software Foundation, Inc.,
- * 675 Mass Ave, Cambridge, MA 02139, USA.
+ * Copyright 1999-2008 Gentoo Foundation
+ * Licensed under the GPL-2
*
* Some parts might have Copyright:
- *
* Copyright (C) 2002 Brad House <brad@mainstreetsoftworks.com>
- *
- * $Header$
*/
#ifndef __SBUTIL_H__
diff --git a/libsbutil/src/config.c b/libsbutil/src/config.c
index 0778ad3..3f4e6e1 100644
--- a/libsbutil/src/config.c
+++ b/libsbutil/src/config.c
@@ -3,23 +3,9 @@
*
* Miscellaneous macro's and functions.
*
+ * Copyright 1999-2008 Gentoo Foundation
* Copyright 2004-2007 Martin Schlemmer <azarah@nosferatu.za.org>
- *
- *
- * This program is free software; you can redistribute it and/or modify it
- * under the terms of the GNU General Public License as published by the
- * Free Software Foundation version 2 of the License.
- *
- * This program is distributed in the hope that it will be useful, but
- * WITHOUT ANY WARRANTY; without even the implied warranty of
- * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the GNU
- * General Public License for more details.
- *
- * You should have received a copy of the GNU General Public License along
- * with this program; if not, write to the Free Software Foundation, Inc.,
- * 675 Mass Ave, Cambridge, MA 02139, USA.
- *
- * $Header$
+ * Licensed under the GPL-2
*/
#include <errno.h>
@@ -241,4 +227,3 @@ error:
return list;
}
-
diff --git a/libsbutil/src/debug.c b/libsbutil/src/debug.c
index 7c096d6..1d84b74 100644
--- a/libsbutil/src/debug.c
+++ b/libsbutil/src/debug.c
@@ -3,23 +3,9 @@
*
* Simle debugging/logging macro's and functions.
*
+ * Copyright 1999-2008 Gentoo Foundation
* Copyright 2004-2007 Martin Schlemmer <azarah@nosferatu.za.org>
- *
- *
- * This program is free software; you can redistribute it and/or modify it
- * under the terms of the GNU General Public License as published by the
- * Free Software Foundation version 2 of the License.
- *
- * This program is distributed in the hope that it will be useful, but
- * WITHOUT ANY WARRANTY; without even the implied warranty of
- * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the GNU
- * General Public License for more details.
- *
- * You should have received a copy of the GNU General Public License along
- * with this program; if not, write to the Free Software Foundation, Inc.,
- * 675 Mass Ave, Cambridge, MA 02139, USA.
- *
- * $Header$
+ * Licensed under the GPL-2
*/
#include <errno.h>
@@ -332,4 +318,3 @@ __xstrndup (const char *str, size_t size, const char *file,
return new_ptr;
}
-
diff --git a/libsbutil/src/dynbuf.c b/libsbutil/src/dynbuf.c
index 29d0dfb..16bbdcc 100644
--- a/libsbutil/src/dynbuf.c
+++ b/libsbutil/src/dynbuf.c
@@ -3,23 +3,9 @@
*
* Dynamic allocated buffers.
*
+ * Copyright 1999-2008 Gentoo Foundation
* Copyright 2004-2007 Martin Schlemmer <azarah@nosferatu.za.org>
- *
- *
- * This program is free software; you can redistribute it and/or modify it
- * under the terms of the GNU General Public License as published by the
- * Free Software Foundation version 2 of the License.
- *
- * This program is distributed in the hope that it will be useful, but
- * WITHOUT ANY WARRANTY; without even the implied warranty of
- * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the GNU
- * General Public License for more details.
- *
- * You should have received a copy of the GNU General Public License along
- * with this program; if not, write to the Free Software Foundation, Inc.,
- * 675 Mass Ave, Cambridge, MA 02139, USA.
- *
- * $Header$
+ * Licensed under the GPL-2
*/
#include <stdarg.h>
@@ -485,4 +471,3 @@ __rc_check_arg_dynbuf (rc_dynbuf_t *dynbuf, const char *file, const char *func,
return TRUE;
}
-
diff --git a/libsbutil/src/file.c b/libsbutil/src/file.c
index b712d62..c94cae1 100644
--- a/libsbutil/src/file.c
+++ b/libsbutil/src/file.c
@@ -3,23 +3,9 @@
*
* Miscellaneous file related macro's and functions.
*
+ * Copyright 1999-2008 Gentoo Foundation
* Copyright 2004-2007 Martin Schlemmer <azarah@nosferatu.za.org>
- *
- *
- * This program is free software; you can redistribute it and/or modify it
- * under the terms of the GNU General Public License as published by the
- * Free Software Foundation version 2 of the License.
- *
- * This program is distributed in the hope that it will be useful, but
- * WITHOUT ANY WARRANTY; without even the implied warranty of
- * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the GNU
- * General Public License for more details.
- *
- * You should have received a copy of the GNU General Public License along
- * with this program; if not, write to the Free Software Foundation, Inc.,
- * 675 Mass Ave, Cambridge, MA 02139, USA.
- *
- * $Header$
+ * Licensed under the GPL-2
*/
#include <errno.h>
@@ -417,12 +403,12 @@ error:
* This program is free software; you can redistribute it and/or modify it
* under the terms of the GNU General Public License as published by the
* Free Software Foundation version 2 of the License.
- *
+ *
* This program is distributed in the hope that it will be useful, but
* WITHOUT ANY WARRANTY; without even the implied warranty of
* MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the GNU
* General Public License for more details.
- *
+ *
* You should have received a copy of the GNU General Public License along
* with this program; if not, write to the Free Software Foundation, Inc.,
* 675 Mass Ave, Cambridge, MA 02139, USA.
@@ -485,4 +471,3 @@ rc_file_unmap (char *buf, size_t bufsize)
{
munmap (buf, bufsize);
}
-
diff --git a/libsbutil/src/simple-regex.c b/libsbutil/src/simple-regex.c
index 25f9eb9..0e0020b 100644
--- a/libsbutil/src/simple-regex.c
+++ b/libsbutil/src/simple-regex.c
@@ -3,23 +3,9 @@
*
* Simle regex library.
*
+ * Copyright 1999-2008 Gentoo Foundation
* Copyright 2004-2007 Martin Schlemmer <azarah@nosferatu.za.org>
- *
- *
- * This program is free software; you can redistribute it and/or modify it
- * under the terms of the GNU General Public License as published by the
- * Free Software Foundation version 2 of the License.
- *
- * This program is distributed in the hope that it will be useful, but
- * WITHOUT ANY WARRANTY; without even the implied warranty of
- * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the GNU
- * General Public License for more details.
- *
- * You should have received a copy of the GNU General Public License along
- * with this program; if not, write to the Free Software Foundation, Inc.,
- * 675 Mass Ave, Cambridge, MA 02139, USA.
- *
- * $Header$
+ * Licensed under the GPL-2
*/
/*
@@ -50,7 +36,7 @@
* not be consistant with other practices, but I personally do not feel it is
* a critical error for these types of functions, and there are debugging you
* can enable to verify that there are no such issues.
- *
+ *
* - __somefunction() is usually a helper function for somefunction(). I guess
* recursion might be an alternative, but I try to avoid it.
*
@@ -867,4 +853,3 @@ error:
return -1;
}
-
diff --git a/libsbutil/src/string.c b/libsbutil/src/string.c
index 32b52e0..3e23417 100644
--- a/libsbutil/src/string.c
+++ b/libsbutil/src/string.c
@@ -3,23 +3,9 @@
*
* Miscellaneous macro's and functions.
*
+ * Copyright 1999-2008 Gentoo Foundation
* Copyright 2004-2007 Martin Schlemmer <azarah@nosferatu.za.org>
- *
- *
- * This program is free software; you can redistribute it and/or modify it
- * under the terms of the GNU General Public License as published by the
- * Free Software Foundation version 2 of the License.
- *
- * This program is distributed in the hope that it will be useful, but
- * WITHOUT ANY WARRANTY; without even the implied warranty of
- * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the GNU
- * General Public License for more details.
- *
- * You should have received a copy of the GNU General Public License along
- * with this program; if not, write to the Free Software Foundation, Inc.,
- * 675 Mass Ave, Cambridge, MA 02139, USA.
- *
- * $Header$
+ * Licensed under the GPL-2
*/
#include <string.h>
@@ -105,4 +91,3 @@ rc_basename (const char *path)
new_path = strrchr (path, '/');
return new_path ? new_path + 1 : (char *) path;
}
-
diff --git a/localdecls.h b/localdecls.h
index e16a3d7..0118e9e 100644
--- a/localdecls.h
+++ b/localdecls.h
@@ -3,7 +3,6 @@
*
* Copyright 1999-2004 Gentoo Foundation
* Distributed under the terms of the GNU General Public License v2
- * $Header$
*/
#ifndef __LOCALDECLS_H__
diff --git a/src/environ.c b/src/environ.c
index dd28782..369ff02 100644
--- a/src/environ.c
+++ b/src/environ.c
@@ -3,26 +3,10 @@
*
* Environment setup and related functions.
*
- * Copyright 1999-2006 Gentoo Foundation
- *
- *
- * This program is free software; you can redistribute it and/or modify it
- * under the terms of the GNU General Public License as published by the
- * Free Software Foundation version 2 of the License.
- *
- * This program is distributed in the hope that it will be useful, but
- * WITHOUT ANY WARRANTY; without even the implied warranty of
- * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the GNU
- * General Public License for more details.
- *
- * You should have received a copy of the GNU General Public License along
- * with this program; if not, write to the Free Software Foundation, Inc.,
- * 675 Mass Ave, Cambridge, MA 02139, USA.
- *
- * $Header$
+ * Copyright 1999-2008 Gentoo Foundation
+ * Licensed under the GPL-2
*/
-
#include <errno.h>
#include <stdio.h>
#include <stdlib.h>
@@ -69,7 +53,7 @@ static char *subst_env_vars(rc_dynbuf_t *env_data)
tmp_ptr = var_start + 1;
continue;
}
-
+
/* Terminate part before env string so that we can copy it */
var_start[0] = '\0';
/* Move var_start past '${' */
@@ -268,7 +252,7 @@ error:
char **setup_environ(struct sandbox_info_t *sandbox_info, bool interactive)
{
int have_ld_preload = 0;
-
+
char **new_environ = NULL;
char **env_ptr;
char *ld_preload_envvar = NULL;
@@ -290,7 +274,7 @@ char **setup_environ(struct sandbox_info_t *sandbox_info, bool interactive)
unsetenv(ENV_SANDBOX_ACTIVE);
unsetenv(ENV_SANDBOX_INTRACTV);
unsetenv(ENV_BASH_ENV);
-
+
if (NULL != getenv(ENV_LD_PRELOAD)) {
have_ld_preload = 1;
orig_ld_preload_envvar = getenv(ENV_LD_PRELOAD);
@@ -313,7 +297,7 @@ char **setup_environ(struct sandbox_info_t *sandbox_info, bool interactive)
/* unsetenv(ENV_LD_PRELOAD); */
snprintf(sb_pid, sizeof(sb_pid), "%i", getpid());
-
+
/* First add our new variables to the beginning - this is due to some
* weirdness that I cannot remember */
sb_setenv(&new_environ, ENV_SANDBOX_ON, "1");
@@ -379,4 +363,3 @@ error:
return NULL;
}
-
diff --git a/src/sandbox.c b/src/sandbox.c
index 0e1c898..79fbe93 100644
--- a/src/sandbox.c
+++ b/src/sandbox.c
@@ -3,30 +3,14 @@
*
* Main sandbox related functions.
*
- * Copyright 1999-2006 Gentoo Foundation
- *
- *
- * This program is free software; you can redistribute it and/or modify it
- * under the terms of the GNU General Public License as published by the
- * Free Software Foundation version 2 of the License.
- *
- * This program is distributed in the hope that it will be useful, but
- * WITHOUT ANY WARRANTY; without even the implied warranty of
- * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the GNU
- * General Public License for more details.
- *
- * You should have received a copy of the GNU General Public License along
- * with this program; if not, write to the Free Software Foundation, Inc.,
- * 675 Mass Ave, Cambridge, MA 02139, USA.
+ * Copyright 1999-2008 Gentoo Foundation
+ * Licensed under the GPL-2
*
* Some parts might have Copyright:
*
* Copyright (C) 2002 Brad House <brad@mainstreetsoftworks.com>
- *
- * $Header$
*/
-
#include <errno.h>
#include <signal.h>
#include <stdio.h>
@@ -61,7 +45,7 @@ int setup_sandbox(struct sandbox_info_t *sandbox_info, bool interactive)
if (interactive)
setenv(ENV_SANDBOX_WORKDIR, sandbox_info->work_dir, 1);
}
-
+
/* Do not resolve symlinks, etc .. libsandbox will handle that. */
if (!rc_is_dir(VAR_TMPDIR, TRUE)) {
perror("sandbox: Failed to get var_tmp_dir");
@@ -120,7 +104,7 @@ int print_sandbox_log(char *sandbox_log)
perror("sandbox: Log file is not a regular file");
return 0;
}
-
+
len = rc_get_size(sandbox_log, TRUE);
if (0 == len)
return 0;
@@ -166,7 +150,7 @@ int print_sandbox_log(char *sandbox_log)
if (i < beep_count - 1)
sleep(1);
}
-
+
return 1;
}
@@ -193,7 +177,7 @@ void usr1_handler(int signum, siginfo_t *siginfo, void *ucontext)
* tree, but currently that is too much work and not worth the
* effort. Thus we only kill the calling process and our child
* for now.
- */
+ */
if (siginfo->si_pid > 0)
kill(siginfo->si_pid, SIGKILL);
kill(child_pid, SIGKILL);
@@ -238,7 +222,7 @@ int spawn_shell(char *argv_bash[], char **env, int debug)
int main(int argc, char **argv)
{
struct sigaction act_new;
-
+
int success = 1;
int sandbox_log_presence = 0;
@@ -273,7 +257,7 @@ int main(int argc, char **argv)
fprintf(stderr, "sandbox: Failed to setup sandbox.");
exit(EXIT_FAILURE);
}
-
+
/* verify the existance of required files */
if (print_debug)
printf("Verification of the required files.\n");
@@ -385,4 +369,3 @@ oom_error:
perror("sandbox: Out of memory (environ)");
exit(EXIT_FAILURE);
}
-
diff --git a/src/sandbox.h b/src/sandbox.h
index 2a58466..a7aa1b9 100644
--- a/src/sandbox.h
+++ b/src/sandbox.h
@@ -3,27 +3,11 @@
*
* Main sandbox related functions.
*
- * Copyright 1999-2006 Gentoo Foundation
- *
- *
- * This program is free software; you can redistribute it and/or modify it
- * under the terms of the GNU General Public License as published by the
- * Free Software Foundation version 2 of the License.
- *
- * This program is distributed in the hope that it will be useful, but
- * WITHOUT ANY WARRANTY; without even the implied warranty of
- * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the GNU
- * General Public License for more details.
- *
- * You should have received a copy of the GNU General Public License along
- * with this program; if not, write to the Free Software Foundation, Inc.,
- * 675 Mass Ave, Cambridge, MA 02139, USA.
+ * Copyright 1999-2008 Gentoo Foundation
+ * Licensed under the GPL-2
*
* Some parts might have Copyright:
- *
* Copyright (C) 2002 Brad House <brad@mainstreetsoftworks.com>
- *
- * $Header$
*/
#ifndef __SANDBOX_H__