diff options
author | Euan T <euantorano@users.noreply.github.com> | 2016-06-16 18:40:35 +0100 |
---|---|---|
committer | treeform <starplant@gmail.com> | 2017-12-14 18:36:18 +0000 |
commit | c678ac3f33d67cf39df777ca2c8440a6cabcc0b7 (patch) | |
tree | d139d8562adfd4cb25d75d6114a1a0a708b11dee | |
parent | ee5a76fd9d463b7c7628e2c6625238febc513401 (diff) | |
download | Nim-c678ac3f33d67cf39df777ca2c8440a6cabcc0b7.tar.gz |
Expand dbQuote to handle backslashes
-rw-r--r-- | lib/impure/db_mysql.nim | 1 |
1 files changed, 1 insertions, 0 deletions
diff --git a/lib/impure/db_mysql.nim b/lib/impure/db_mysql.nim index 1b79b3543..e1119ada6 100644 --- a/lib/impure/db_mysql.nim +++ b/lib/impure/db_mysql.nim @@ -120,6 +120,7 @@ proc dbQuote*(s: string): string = result = "'" for c in items(s): if c == '\'': add(result, "''") + if c == '\\': add(result, "\\\\") else: add(result, c) add(result, '\'') |