zehortigoza pushed a commit to branch master.
commit 2aa703bf03617fb195600b83f05b3ebf7b54a9f5
Author: José Roberto de Souza <[email protected]>
Date: Mon Jul 8 13:42:18 2013 -0300
eldbus-codegen: If substr dont exist in string return string.
CID: 1039339
---
src/codegen/utils.c | 5 +++++
1 file changed, 5 insertions(+)
diff --git a/src/codegen/utils.c b/src/codegen/utils.c
index a020445..de4eb15 100644
--- a/src/codegen/utils.c
+++ b/src/codegen/utils.c
@@ -87,6 +87,11 @@ replace_string(const char *string, const char *substr, const
char *replacement)
Eina_Strbuf *buffer = eina_strbuf_new();
pch = strtok(str_cpy, substr);
+ if (!pch)
+ {
+ eina_strbuf_free(buffer);
+ return str_cpy;
+ }
eina_strbuf_append(buffer, pch);
while ((pch = strtok(NULL, substr)))
--
------------------------------------------------------------------------------
Get your SQL database under version control now!
Version control is standard for application code, but databases havent
caught up. So what steps can you take to put your SQL databases under
version control? Why should you start doing it? Read more to find out.
http://pubads.g.doubleclick.net/gampad/clk?id=49501711&iu=/4140/ostg.clktrk