summaryrefslogtreecommitdiff
path: root/lib
diff options
context:
space:
mode:
authorAlain Magloire <alainm@gnu.org>2002-03-13 16:52:41 +0000
committerAlain Magloire <alainm@gnu.org>2002-03-13 16:52:41 +0000
commitfc4193991b38d861ca390eebcdeae12f16c1627f (patch)
tree1e9ae41c235d291741d2ce07f2db479b6eab0c3a /lib
parentedc010f2c2c0f875d61a44b6ff82f2768a37f2d8 (diff)
downloadmailutils-fc4193991b38d861ca390eebcdeae12f16c1627f.tar.gz
mailutils-fc4193991b38d861ca390eebcdeae12f16c1627f.tar.bz2
* lib/mu_dmb.c(mu_check_perm): Reinforce
by using (const char *name) in the argument. * pop3d/pop3d.c: The variable state was already use as a global, use "astate" in function pop3_parse_opt().
Diffstat (limited to 'lib')
-rw-r--r--lib/mu_dbm.c8
-rw-r--r--lib/mu_dbm.h4
2 files changed, 6 insertions, 6 deletions
diff --git a/lib/mu_dbm.c b/lib/mu_dbm.c
index 57aa77380..b116b59a2 100644
--- a/lib/mu_dbm.c
+++ b/lib/mu_dbm.c
@@ -1,5 +1,5 @@
/* GNU mailutils - a suite of utilities for electronic mail
- Copyright (C) 1999, 2000, 2001 Free Software Foundation, Inc.
+ Copyright (C) 1999, 2000, 2001, 2002 Free Software Foundation, Inc.
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
@@ -53,12 +53,12 @@ mu_fcheck_perm (int fd, int mode)
}
int
-mu_check_perm (char *name, int mode)
+mu_check_perm (const char *name, int mode)
{
struct stat st;
if (mode == 0)
- return 0;
+ return 0;
if (stat (name, &st) == -1)
{
if (errno == ENOENT)
@@ -68,7 +68,7 @@ mu_check_perm (char *name, int mode)
}
if ((st.st_mode & 0777) != mode)
{
- errno = EPERM;
+ errno = EPERM;
return 1;
}
return 0;
diff --git a/lib/mu_dbm.h b/lib/mu_dbm.h
index 337b3e635..0152e2489 100644
--- a/lib/mu_dbm.h
+++ b/lib/mu_dbm.h
@@ -1,5 +1,5 @@
/* GNU mailutils - a suite of utilities for electronic mail
- Copyright (C) 1999, 2000, 2001 Free Software Foundation, Inc.
+ Copyright (C) 1999, 2000, 2001, 2002 Free Software Foundation, Inc.
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
@@ -75,4 +75,4 @@ DBM_DATUM mu_dbm_nextkey __P((DBM_FILE db, DBM_DATUM key));
#endif
int mu_fcheck_perm __P((int fd, int mode));
-int mu_check_perm __P((char *name, int mode));
+int mu_check_perm __P((const char *name, int mode));

Return to:

Send suggestions and report system problems to the System administrator.