diff options
author | Julian Andres Klode <jak@jak-linux.org> | 2010-05-13 20:42:01 -0700 |
---|---|---|
committer | Evan Nemerson <evan@coeus-group.com> | 2010-05-13 20:42:01 -0700 |
commit | 65a58595c56d61bbff2afb82a64a1996566eef35 (patch) | |
tree | 58b7283930b71b95123c81264336f75f76d5e240 /vapi/sqlite3.vapi | |
parent | 176f57c85e553de21983470353ccdb4aaf41fc4f (diff) | |
download | vala-65a58595c56d61bbff2afb82a64a1996566eef35.tar.gz |
sqlite3: Cast errmsg to char** in C.
Vala's string out arguments are const char**, but sqlite3_exec() and
sqlite3_get_table() expect 'char**'. Add [CCode (type = "char**")] to
cast them to the wanted type, thus avoiding a warning from the C
compiler.
Fixes bug 618457.
Diffstat (limited to 'vapi/sqlite3.vapi')
-rw-r--r-- | vapi/sqlite3.vapi | 4 |
1 files changed, 2 insertions, 2 deletions
diff --git a/vapi/sqlite3.vapi b/vapi/sqlite3.vapi index edff3734f..801154c23 100644 --- a/vapi/sqlite3.vapi +++ b/vapi/sqlite3.vapi @@ -29,7 +29,7 @@ namespace Sqlite { public int busy_timeout (int ms); public int changes (); [CCode (cname = "sqlite3_exec")] - public int _exec (string sql, Callback? sqlite3_callback = null, out unowned string errmsg = null); + public int _exec (string sql, Callback? sqlite3_callback = null, [CCode (type = "char**")] out unowned string errmsg = null); [CCode (cname = "_sqlite3_exec")] public int exec (string sql, Callback? sqlite3_callback = null, out string errmsg = null) { unowned string sqlite_errmsg; @@ -48,7 +48,7 @@ namespace Sqlite { public int total_changes (); public int complete (string sql); [CCode (cname = "sqlite3_get_table")] - public int _get_table (string sql, [CCode (array_length = false)] out unowned string[] resultp, out int nrow, out int ncolumn, out unowned string? errmsg = null); + public int _get_table (string sql, [CCode (array_length = false)] out unowned string[] resultp, out int nrow, out int ncolumn, [CCode (type = "char**")] out unowned string? errmsg = null); private static void free_table ([CCode (array_length = false)] string[] result); [CCode (cname = "_sqlite3_get_table")] public int get_table (string sql, out string[] resultp, out int nrow, out int ncolumn, out string? errmsg = null) { |