diff options
Diffstat (limited to 'src')
-rw-r--r-- | src/Slit.cc | 10 |
1 files changed, 5 insertions, 5 deletions
diff --git a/src/Slit.cc b/src/Slit.cc index 2c2574e..5d6cf05 100644 --- a/src/Slit.cc +++ b/src/Slit.cc | |||
@@ -22,7 +22,7 @@ | |||
22 | // FROM, OUT OF OR IN CONNECTION WITH THE SOFTWARE OR THE USE OR OTHER | 22 | // FROM, OUT OF OR IN CONNECTION WITH THE SOFTWARE OR THE USE OR OTHER |
23 | // DEALINGS IN THE SOFTWARE. | 23 | // DEALINGS IN THE SOFTWARE. |
24 | 24 | ||
25 | // $Id: Slit.cc,v 1.88 2004/01/30 11:06:25 rathnor Exp $ | 25 | // $Id: Slit.cc,v 1.89 2004/02/06 12:09:14 rathnor Exp $ |
26 | 26 | ||
27 | #include "Slit.hh" | 27 | #include "Slit.hh" |
28 | 28 | ||
@@ -1131,20 +1131,20 @@ void Slit::loadClientList(const char *filename) { | |||
1131 | m_filename = FbTk::StringUtil::expandFilename(filename); | 1131 | m_filename = FbTk::StringUtil::expandFilename(filename); |
1132 | 1132 | ||
1133 | struct stat buf; | 1133 | struct stat buf; |
1134 | if (stat(filename, &buf) != 0) { | 1134 | if (stat(m_filename.c_str(), &buf) != 0) { |
1135 | std::ifstream file(filename); | 1135 | std::ifstream file(m_filename.c_str()); |
1136 | std::string name; | 1136 | std::string name; |
1137 | while (! file.eof()) { | 1137 | while (! file.eof()) { |
1138 | name = ""; | 1138 | name = ""; |
1139 | std::getline(file, name); // get the entire line | 1139 | std::getline(file, name); // get the entire line |
1140 | if (name.size() <= 0) | 1140 | if (name.empty()) |
1141 | continue; | 1141 | continue; |
1142 | 1142 | ||
1143 | // remove whitespaces from start and end | 1143 | // remove whitespaces from start and end |
1144 | FbTk::StringUtil::removeFirstWhitespace(name); | 1144 | FbTk::StringUtil::removeFirstWhitespace(name); |
1145 | 1145 | ||
1146 | // the cleaned string could still be a comment, or blank | 1146 | // the cleaned string could still be a comment, or blank |
1147 | if ( name.size() <= 0 || name[0] == '#' || name[0] == '!' ) | 1147 | if ( name.empty() || name[0] == '#' || name[0] == '!' ) |
1148 | continue; | 1148 | continue; |
1149 | 1149 | ||
1150 | // trailing whitespace won't affect the above test | 1150 | // trailing whitespace won't affect the above test |