Переглянути джерело

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;