Changeset 2217 for trunk/yat/utility/FileUtil.cc
- Timestamp:
- Mar 14, 2010, 9:57:53 PM (14 years ago)
- Location:
- trunk
- Files:
-
- 2 edited
Legend:
- Unmodified
- Added
- Removed
-
trunk
- Property svn:mergeinfo changed
/branches/0.6-stable merged: 2203-2204,2207,2212,2215
- Property svn:mergeinfo changed
-
trunk/yat/utility/FileUtil.cc
r2125 r2217 6 6 Copyright (C) 2006 Jari Häkkinen 7 7 Copyright (C) 2007, 2008 Jari Häkkinen, Peter Johansson 8 Copyright (C) 2009 Peter Johansson8 Copyright (C) 2009, 2010 Peter Johansson 9 9 10 10 This file is part of the yat library, http://dev.thep.lu.se/yat … … 66 66 if (!exists()) { 67 67 std::string::size_type pos=path_.find_last_of('/'); 68 tryme = ( (pos!=std::string::npos) ? path_.substr(0,pos) : "." ); 68 if (pos == std::string::npos) 69 tryme = "."; 70 else if (pos == 0) 71 tryme = "/"; 72 else 73 tryme.resize(pos); 69 74 } 70 75
Note: See TracChangeset
for help on using the changeset viewer.