1
0
mirror of https://git.FreeBSD.org/ports.git synced 2025-01-26 09:46:09 +00:00

Include std:: prefix on references to string class for gcc 3.2, which is

pickier that 2.95.x. It's really also the right way to do the code ...
This commit is contained in:
Alan Eldridge 2002-09-10 14:14:02 +00:00
parent f593f06ed2
commit ff4b894d1c
Notes: svn2git 2021-03-31 03:12:20 +00:00
svn path=/head/; revision=66057

View File

@ -42,7 +42,7 @@ struct statfs *G_pmntstat = 0;
struct optmap {
int fl;
string st;
std::string st;
};
static struct optmap omap[] = {
@ -84,7 +84,7 @@ mntent::from_statfs(struct statfs *pst)
strcpy(mnt_type, pst->f_fstypename);
mnt_freq = mnt_passno = 0;
string opts;
std::string opts;
int fl = pst->f_flags;
opts += (fl & MNT_RDONLY) ? "ro" : "rw";
@ -118,11 +118,11 @@ setmntent(const char *, char *)
char *
hasmntopt(const mntent *pmnt, const char *szopt)
{
string opt(szopt);
string mntopts(pmnt->mnt_opts);
std::string opt(szopt);
std::string mntopts(pmnt->mnt_opts);
string::size_type pos = mntopts.find(opt);
const char *szret = (pos == string::npos) ? "" : pmnt->mnt_opts + pos;
std::string::size_type pos = mntopts.find(opt);
const char *szret = (pos == std::string::npos) ? "" : pmnt->mnt_opts + pos;
return const_cast<char *>(szret);
}