]> git.lyx.org Git - lyx.git/blobdiff - src/support/filetools.C
Add a bunch of c_str() for string stream uses; remove lyxfunc symbol-insert.
[lyx.git] / src / support / filetools.C
index 4230a394f7f9cb2e775472395497e57c378e8174..c9605aa7f8f87dd153982a1565b8ca1601130828 100644 (file)
@@ -58,6 +58,13 @@ using std::pair;
 using std::endl;
 using std::ifstream;
 
+#if 0
+using std::getenv;
+using std::isalpha;
+using std::isalnum;
+using std::popen;
+#endif
+
 extern string system_lyxdir;
 extern string build_lyxdir;
 extern string user_lyxdir;
@@ -290,7 +297,7 @@ i18nLibFileSearch(string const & dir, string const & name,
 string const GetEnv(string const & envname)
 {
         // f.ex. what about error checking?
-        char const * const ch = ::getenv(envname.c_str());
+        char const * const ch = getenv(envname.c_str());
         string const envstr = !ch ? "" : ch;
         return envstr;
 }
@@ -539,7 +546,7 @@ string const MakeAbsPath(string const & RelPath, string const & BasePath)
        // checks for already absolute path
        if (AbsolutePath(RelPath))
 #ifdef __EMX__
-               if(RelPath[0]!= '/' && RelPath[0]!= '\\')
+               if (RelPath[0]!= '/' && RelPath[0]!= '\\')
 #endif
                return RelPath;
 
@@ -739,7 +746,7 @@ string const GetFileContents(string const & fname)
                if (ifs && ofs) {
                        ofs << ifs.rdbuf();
                        ifs.close();
-                       return ofs.str();
+                       return ofs.str().c_str();
                }
        }
        lyxerr << "LyX was not able to read file '" << fname << "'" << endl;