diff --git a/lib_acl/CMakeLists.txt b/lib_acl/CMakeLists.txt index 0be3b4887..ac611fbca 100644 --- a/lib_acl/CMakeLists.txt +++ b/lib_acl/CMakeLists.txt @@ -108,7 +108,6 @@ if (${UNIX_OS}) "-D_POSIX_PTHREAD_SEMANTICS" "-DACL_PREPARE_COMPILE" "-Wstrict-prototypes" - "-fvisibility=hidden" ) if (CMAKE_COMPILER_IS_GNUCC) @@ -158,7 +157,6 @@ else() set(CMAKE_SHARED_LINKER_FLAGS "/DYNAMICBASE ws2_32.lib IPHlpApi.lib") endif() -# set(CMAKE_SHARED_LINKER_FLAGS "-fvisibility=hidden") set(lib_output_path ${PROJECT_BINARY_DIR}/lib) set(LIBRARY_OUTPUT_PATH ${lib_output_path}) set(CMAKE_LIBRARY_OUTPUT_DIRECTORY ${lib_output_path}) diff --git a/lib_acl/acl.xcodeproj/project.pbxproj b/lib_acl/acl.xcodeproj/project.pbxproj index d25f5d3bb..2f9dad0cd 100644 --- a/lib_acl/acl.xcodeproj/project.pbxproj +++ b/lib_acl/acl.xcodeproj/project.pbxproj @@ -244,6 +244,7 @@ 0779D5F01DBE073000449438 /* acl_xml_parse.c in Sources */ = {isa = PBXBuildFile; fileRef = 0779D4B21DBE070E00449438 /* acl_xml_parse.c */; }; 0779D5F11DBE073000449438 /* acl_xml_util.c in Sources */ = {isa = PBXBuildFile; fileRef = 0779D4B31DBE070E00449438 /* acl_xml_util.c */; }; 70BD6B8B232B931700E4C798 /* acl_sane_bind.c in Sources */ = {isa = PBXBuildFile; fileRef = 0779D3F91DBE070E00449438 /* acl_sane_bind.c */; }; + 70BD6CA8233520C600E4C798 /* acl_sane_accept.c in Sources */ = {isa = PBXBuildFile; fileRef = 70BD6CA7233520C600E4C798 /* acl_sane_accept.c */; }; /* End PBXBuildFile section */ /* Begin PBXCopyFilesBuildPhase section */ @@ -650,6 +651,7 @@ 07A469F61E6FD4FA002C9B3C /* acl_xml.h */ = {isa = PBXFileReference; fileEncoding = 4; lastKnownFileType = sourcecode.c.h; path = acl_xml.h; sourceTree = ""; }; 07A469F71E6FD4FA002C9B3C /* acl_xml2.h */ = {isa = PBXFileReference; fileEncoding = 4; lastKnownFileType = sourcecode.c.h; path = acl_xml2.h; sourceTree = ""; }; 07A469F81E6FD4FA002C9B3C /* acl_xml3.h */ = {isa = PBXFileReference; fileEncoding = 4; lastKnownFileType = sourcecode.c.h; path = acl_xml3.h; sourceTree = ""; }; + 70BD6CA7233520C600E4C798 /* acl_sane_accept.c */ = {isa = PBXFileReference; fileEncoding = 4; lastKnownFileType = sourcecode.c.c; path = acl_sane_accept.c; sourceTree = ""; }; /* End PBXFileReference section */ /* Begin PBXFrameworksBuildPhase section */ @@ -932,6 +934,7 @@ 0779D3F61DBE070E00449438 /* listen */ = { isa = PBXGroup; children = ( + 70BD6CA7233520C600E4C798 /* acl_sane_accept.c */, 0779D3F71DBE070E00449438 /* acl_fifo_listen.c */, 0779D3F81DBE070E00449438 /* acl_inet_listen.c */, 0779D3F91DBE070E00449438 /* acl_sane_bind.c */, @@ -1716,6 +1719,7 @@ 0779D5A31DBE073000449438 /* acl_write_wait.c in Sources */, 0779D5A41DBE073000449438 /* acl_allocator.c in Sources */, 0779D5A51DBE073000449438 /* acl_dbuf_pool.c in Sources */, + 70BD6CA8233520C600E4C798 /* acl_sane_accept.c in Sources */, 0779D5A61DBE073000449438 /* acl_default_malloc.c in Sources */, 0779D5A71DBE073000449438 /* acl_malloc_glue.c in Sources */, 0779D5A81DBE073000449438 /* acl_mem_hook.c in Sources */, diff --git a/lib_acl_cpp/changes.txt b/lib_acl_cpp/changes.txt index 1ef0e5d03..31303f935 100644 --- a/lib_acl_cpp/changes.txt +++ b/lib_acl_cpp/changes.txt @@ -1,5 +1,9 @@ 修改历史列表: +591) 2019.9.24 +591.1) compile: 使用 cmake 编译的 .so 库不能正常使用,原因是使用了 -fvisibility=hidden +编译选项 + 590) 2019.9.17 590.1) bugfix: 在客户端模式下,需要在 http_aclient::ws_handshake() 中需要调用 set_frame_masking_key() 设置客户端发送数据的掩码 diff --git a/lib_acl_cpp/include/acl_cpp/redis/redis_key.hpp b/lib_acl_cpp/include/acl_cpp/redis/redis_key.hpp index 512d13598..b961b9dd6 100644 --- a/lib_acl_cpp/include/acl_cpp/redis/redis_key.hpp +++ b/lib_acl_cpp/include/acl_cpp/redis/redis_key.hpp @@ -308,7 +308,7 @@ public: * @return {bool} Ƿɹ key ʱ false * true on success, or false be returned */ - bool randmkey(string& buf); + bool randomkey(string& buf); /** * key Ϊ newkey diff --git a/lib_acl_cpp/src/db/db_mysql.cpp b/lib_acl_cpp/src/db/db_mysql.cpp index d5a8f5abc..851b627bf 100644 --- a/lib_acl_cpp/src/db/db_mysql.cpp +++ b/lib_acl_cpp/src/db/db_mysql.cpp @@ -958,6 +958,11 @@ bool db_mysql::commit(void) return false; } +bool db_mysql::rollback(void) +{ + return false; +} + int db_mysql::affect_count(void) const { return 0; diff --git a/lib_acl_cpp/src/db/db_pgsql.cpp b/lib_acl_cpp/src/db/db_pgsql.cpp index 8f3c8308c..e3969bdfa 100644 --- a/lib_acl_cpp/src/db/db_pgsql.cpp +++ b/lib_acl_cpp/src/db/db_pgsql.cpp @@ -691,6 +691,11 @@ bool db_pgsql::commit() return false; } +bool db_pgsql::rollback(void) +{ + return false; +} + int db_pgsql::affect_count() const { return 0; diff --git a/lib_acl_cpp/src/db/db_sqlite.cpp b/lib_acl_cpp/src/db/db_sqlite.cpp index 5a84c6b21..595a1bb52 100644 --- a/lib_acl_cpp/src/db/db_sqlite.cpp +++ b/lib_acl_cpp/src/db/db_sqlite.cpp @@ -785,6 +785,8 @@ bool db_sqlite::set_conf(const char*) { return false; } const char* db_sqlite::get_conf(const char*, string&) { return NULL; } void db_sqlite::show_conf(const char*) {} int db_sqlite::affect_total_count() const { return 0; } +bool db_sqlite::begin_transaction(void) { return false; } +bool db_sqlite::commit(void) { return false; } const char* db_sqlite::dbtype() const { return NULL; } bool db_sqlite::dbopen(const char*) { return false; } bool db_sqlite::is_opened() const { return false; } diff --git a/lib_acl_cpp/src/redis/redis_key.cpp b/lib_acl_cpp/src/redis/redis_key.cpp index 0ed5197dc..d92d2dc0b 100644 --- a/lib_acl_cpp/src/redis/redis_key.cpp +++ b/lib_acl_cpp/src/redis/redis_key.cpp @@ -299,7 +299,7 @@ long long int redis_key::pttl(const char* key) return ret; } -bool redis_key::randmkey(string& buf) +bool redis_key::randomkey(string& buf) { const char* argv[1]; size_t lens[1]; diff --git a/lib_protocol/CMakeLists.txt b/lib_protocol/CMakeLists.txt index 09262724d..d583735a0 100644 --- a/lib_protocol/CMakeLists.txt +++ b/lib_protocol/CMakeLists.txt @@ -74,7 +74,6 @@ if (${UNIX_OS}) "-D_POSIX_PTHREAD_SEMANTICS" "-DACL_PREPARE_COMPILE" "-Wstrict-prototypes" - "-fvisibility=hidden" ) # if (CMAKE_BUILD_TYPE STREQUAL "") diff --git a/lib_protocol/include/http/lib_http_util.h b/lib_protocol/include/http/lib_http_util.h index 5b7ecbd3a..5604b721c 100644 --- a/lib_protocol/include/http/lib_http_util.h +++ b/lib_protocol/include/http/lib_http_util.h @@ -150,7 +150,7 @@ HTTP_API int http_util_req_open(HTTP_UTIL *http_util); * @param http_util {HTTP_UTIL*} * @param data {const char*} η͵ݵַǿ * @param dlen {size_t} data ݳ, 0 - * @param {int} > 0 ʾγɹ͵; -1: ʾʧ, Ӧ + * @return {int} > 0 ʾγɹ͵; -1: ʾʧ, Ӧ * http_util_free رͷڴԴ */ HTTP_API int http_util_put_req_data(HTTP_UTIL *http_util, const char *data, size_t dlen); @@ -215,7 +215,7 @@ HTTP_API int http_util_get_res_body(HTTP_UTIL *http_util, char *buf, size_t size * ij url Ӧתijļ * @param url {const char*} url, : http://www.g.cn * @param dump {const char*} תļ - * @param {int} Ӧݳ, >=0: ʾɹ, -1: ʾʧ + * @return {int} Ӧݳ, >=0: ʾɹ, -1: ʾʧ */ HTTP_API int http_util_dump_url(const char *url, const char *dump); @@ -223,7 +223,7 @@ HTTP_API int http_util_dump_url(const char *url, const char *dump); * ij url Ӧתij * @param url {const char*} url, : http://www.g.cn * @param stream {ACL_VSTREAM *} ת - * @param {int} Ӧݳ, >=0: ʾɹ, -1: ʾʧ + * @return {int} Ӧݳ, >=0: ʾɹ, -1: ʾʧ */ HTTP_API int http_util_dump_url_to_stream(const char *url, ACL_VSTREAM *stream); diff --git a/lib_protocol/include/smtp/smtp_client.h b/lib_protocol/include/smtp/smtp_client.h index 431882818..247b0549b 100644 --- a/lib_protocol/include/smtp/smtp_client.h +++ b/lib_protocol/include/smtp/smtp_client.h @@ -169,7 +169,7 @@ SMTP_API int smtp_send_file(SMTP_CLIENT *client, const char *filepath); /** * SMTP ͸ļʼ * @param client {SMTP_CLIENT*} SMTP Ӷ - * @param int {ACL_VSTREAM*} ʼļ + * @param in {ACL_VSTREAM*} ʼļ * @return {int} 0 ʾɹ(SMTP_CLIENT::smtp_code ʾ룬 * SMTP_CLIENT::buf 洢Ӧ)ʾӦùرӶ */