| 38 | } |
| 39 | |
| 40 | void makebasename(std::string& path) |
| 41 | // Turn a pathname into just the base file name in place. If path doesn't |
| 42 | // contain any /'s then it is unchanged. |
| 43 | { |
| 44 | size_t pos = path.find_last_of('/'); |
| 45 | if(pos != std::string::npos) { |
| 46 | path = path.substr(pos + 1); |
| 47 | } |
| 48 | } |
| 49 | |
| 50 | void makedirname(std::string& path) |
| 51 | // Strip a path down into just a directory name, by removing everything after |