未验证 提交 ec0489a5 编写于 作者: S Stone Tao 提交者: GitHub

Merge pull request #610 from StoneT2000/master

Fixed bug where errors were printed as numbers instead of the string
...@@ -229,7 +229,7 @@ function CTaosInterface (config = null, pass = false) { ...@@ -229,7 +229,7 @@ function CTaosInterface (config = null, pass = false) {
//int taos_errno(TAOS *taos) //int taos_errno(TAOS *taos)
'taos_errno': [ ref.types.int, [ ref.types.void_ptr] ], 'taos_errno': [ ref.types.int, [ ref.types.void_ptr] ],
//char *taos_errstr(TAOS *taos) //char *taos_errstr(TAOS *taos)
'taos_errstr': [ ref.types.char, [ ref.types.void_ptr] ], 'taos_errstr': [ ref.types.char_ptr, [ ref.types.void_ptr] ],
//void taos_stop_query(TAOS_RES *res); //void taos_stop_query(TAOS_RES *res);
'taos_stop_query': [ ref.types.void, [ ref.types.void_ptr] ], 'taos_stop_query': [ ref.types.void, [ ref.types.void_ptr] ],
//char *taos_get_server_info(TAOS *taos); //char *taos_get_server_info(TAOS *taos);
...@@ -399,7 +399,7 @@ CTaosInterface.prototype.errno = function errno(connection) { ...@@ -399,7 +399,7 @@ CTaosInterface.prototype.errno = function errno(connection) {
return this.libtaos.taos_errno(connection); return this.libtaos.taos_errno(connection);
} }
CTaosInterface.prototype.errStr = function errStr(connection) { CTaosInterface.prototype.errStr = function errStr(connection) {
return this.libtaos.taos_errstr(connection); return ref.readCString(this.libtaos.taos_errstr(connection));
} }
// Async // Async
CTaosInterface.prototype.query_a = function query_a(connection, sql, callback, param = ref.ref(ref.NULL)) { CTaosInterface.prototype.query_a = function query_a(connection, sql, callback, param = ref.ref(ref.NULL)) {
......
{ {
"name": "td-connector", "name": "td-connector",
"version": "1.3.1", "version": "1.3.2",
"lockfileVersion": 1, "lockfileVersion": 1,
"requires": true, "requires": true,
"dependencies": { "dependencies": {
......
{ {
"name": "td-connector", "name": "td-connector",
"version": "1.3.1", "version": "1.3.2",
"description": "A Node.js connector for TDengine.", "description": "A Node.js connector for TDengine.",
"main": "tdengine.js", "main": "tdengine.js",
"scripts": { "scripts": {
......
Markdown is supported
0% .
You are about to add 0 people to the discussion. Proceed with caution.
先完成此消息的编辑!
想要评论请 注册