소스 검색

Provide two useful macros for str initialization: STR_STATIC_INIT() and
STR_NULL. Adjust all modules to use those macros where appropriate.

Verified by: md5(1) (those modules, which actually compile)

Maxim Sobolev 20 년 전
부모
커밋
a9b67b6b16
1개의 변경된 파일1개의 추가작업 그리고 1개의 파일을 삭제
  1. 1 1
      modules/db_postgres/res.c

+ 1 - 1
modules/db_postgres/res.c

@@ -173,7 +173,7 @@ static inline void free_rows(db_res_t* res)
 
 static inline int convert_cell(db_con_t* con, db_res_t* res, int row, int col)
 {
-	static str dummy_str = {"", 0};
+	static str dummy_str = STR_STATIC_INIT("");
 	PGresult* pgres;
 	db_val_t* val;
 	int type, pglen;