diff options
author | simonb <simonb> | 2006-06-27 08:54:24 (GMT) |
---|---|---|
committer | simonb <simonb> | 2006-06-27 08:54:24 (GMT) |
commit | 6dc5ca4e60b80a1d900f87a4e70954cd29cfcee4 (patch) | |
tree | 772fa725f48f376a627670ded338a78363302dd9 /src/FbTk | |
parent | b79d7ee745256eb14d664dcc1a6dac8520c9f490 (diff) | |
download | fluxbox-6dc5ca4e60b80a1d900f87a4e70954cd29cfcee4.zip fluxbox-6dc5ca4e60b80a1d900f87a4e70954cd29cfcee4.tar.bz2 |
some minor code cleanups thanks Slava Semushin (php-coder), who also thanks Mikhail Gusarov
Diffstat (limited to 'src/FbTk')
-rw-r--r-- | src/FbTk/StringUtil.cc | 12 | ||||
-rw-r--r-- | src/FbTk/StringUtil.hh | 1 |
2 files changed, 0 insertions, 13 deletions
diff --git a/src/FbTk/StringUtil.cc b/src/FbTk/StringUtil.cc index 1a6814c..11bd87d 100644 --- a/src/FbTk/StringUtil.cc +++ b/src/FbTk/StringUtil.cc | |||
@@ -58,18 +58,6 @@ namespace FbTk { | |||
58 | namespace StringUtil { | 58 | namespace StringUtil { |
59 | 59 | ||
60 | /** | 60 | /** |
61 | Takes a pointer to string *s as an argument, | ||
62 | creates a new string n, copies s to n and | ||
63 | returns a pointer to n. | ||
64 | */ | ||
65 | char *strdup(const char *s) { | ||
66 | int l = strlen(s) + 1; | ||
67 | char *n = new char[l]; | ||
68 | strncpy(n, s, l); | ||
69 | return n; | ||
70 | } | ||
71 | |||
72 | /** | ||
73 | Tries to find a string in another and | 61 | Tries to find a string in another and |
74 | ignoring the case of the characters | 62 | ignoring the case of the characters |
75 | Returns 0 on success else pointer to str. | 63 | Returns 0 on success else pointer to str. |
diff --git a/src/FbTk/StringUtil.hh b/src/FbTk/StringUtil.hh index c9f6818..b45d6a2 100644 --- a/src/FbTk/StringUtil.hh +++ b/src/FbTk/StringUtil.hh | |||
@@ -30,7 +30,6 @@ namespace FbTk { | |||
30 | 30 | ||
31 | namespace StringUtil { | 31 | namespace StringUtil { |
32 | 32 | ||
33 | char *strdup(const char *); | ||
34 | 33 | ||
35 | /// Similar to `strstr' but this function ignores the case of both strings | 34 | /// Similar to `strstr' but this function ignores the case of both strings |
36 | const char *strcasestr(const char *str, const char *ptn); | 35 | const char *strcasestr(const char *str, const char *ptn); |