Browse code

db_res renamed to db1_res in files originating from kamailio/db_mysql.

The structure db_res has been renamed in lib/srdb1 to db1_res, thus we need to
change the name of the structure in all files originating from
kamailio/modules/db_mysql (and using lib/srdb1).

Jan Janak authored on 16/02/2009 22:13:16
Showing 6 changed files
... ...
@@ -149,7 +149,7 @@ void db_mysql_close(db1_con_t* _h)
149 149
  * \param _r result set that should be retrieved
150 150
  * \return zero on success, negative value on failure
151 151
  */
152
-static int db_mysql_store_result(const db1_con_t* _h, db_res_t** _r)
152
+static int db_mysql_store_result(const db1_con_t* _h, db1_res_t** _r)
153 153
 {
154 154
 	if ((!_h) || (!_r)) {
155 155
 		LM_ERR("invalid parameter value\n");
... ...
@@ -213,7 +213,7 @@ done:
213 213
  * \param _r result set that should be freed
214 214
  * \return zero on success, negative value on failure
215 215
  */
216
-int db_mysql_free_result(db1_con_t* _h, db_res_t* _r)
216
+int db_mysql_free_result(db1_con_t* _h, db1_res_t* _r)
217 217
 {
218 218
      if ((!_h) || (!_r)) {
219 219
 	     LM_ERR("invalid parameter value\n");
... ...
@@ -245,7 +245,7 @@ int db_mysql_free_result(db1_con_t* _h, db_res_t* _r)
245 245
  */
246 246
 int db_mysql_query(const db1_con_t* _h, const db_key_t* _k, const db_op_t* _op,
247 247
 	     const db_val_t* _v, const db_key_t* _c, const int _n, const int _nc,
248
-	     const db_key_t _o, db_res_t** _r)
248
+	     const db_key_t _o, db1_res_t** _r)
249 249
 {
250 250
 	return db_do_query(_h, _k, _op, _v, _c, _n, _nc, _o, _r,
251 251
 	db_mysql_val2str, db_mysql_submit_query, db_mysql_store_result);
... ...
@@ -266,7 +266,7 @@ int db_mysql_query(const db1_con_t* _h, const db_key_t* _k, const db_op_t* _op,
266 266
  * \param nrows number of fetched rows
267 267
  * \return zero on success, negative value on failure
268 268
  */
269
-int db_mysql_fetch_result(const db1_con_t* _h, db_res_t** _r, const int nrows)
269
+int db_mysql_fetch_result(const db1_con_t* _h, db1_res_t** _r, const int nrows)
270 270
 {
271 271
 	int rows, i;
272 272
 
... ...
@@ -374,7 +374,7 @@ int db_mysql_fetch_result(const db1_con_t* _h, db_res_t** _r, const int nrows)
374 374
  * \param _r result set for storage
375 375
  * \return zero on success, negative value on failure
376 376
  */
377
-int db_mysql_raw_query(const db1_con_t* _h, const str* _s, db_res_t** _r)
377
+int db_mysql_raw_query(const db1_con_t* _h, const str* _s, db1_res_t** _r)
378 378
 {
379 379
 	return db_do_raw_query(_h, _s, _r, db_mysql_submit_query,
380 380
 	db_mysql_store_result);
... ...
@@ -57,7 +57,7 @@ void db_mysql_close(db1_con_t* _h);
57 57
 /*! \brief
58 58
  * Free all memory allocated by get_result
59 59
  */
60
-int db_mysql_free_result(db1_con_t* _h, db_res_t* _r);
60
+int db_mysql_free_result(db1_con_t* _h, db1_res_t* _r);
61 61
 
62 62
 
63 63
 /*! \brief
... ...
@@ -65,19 +65,19 @@ int db_mysql_free_result(db1_con_t* _h, db_res_t* _r);
65 65
  */
66 66
 int db_mysql_query(const db1_con_t* _h, const db_key_t* _k, const db_op_t* _op,
67 67
 	     const db_val_t* _v, const db_key_t* _c, const int _n, const int _nc,
68
-	     const db_key_t _o, db_res_t** _r);
68
+	     const db_key_t _o, db1_res_t** _r);
69 69
 
70 70
 
71 71
 /*! \brief
72 72
  * fetch rows from a result
73 73
  */
74
-int db_mysql_fetch_result(const db1_con_t* _h, db_res_t** _r, const int nrows);
74
+int db_mysql_fetch_result(const db1_con_t* _h, db1_res_t** _r, const int nrows);
75 75
 
76 76
 
77 77
 /*! \brief
78 78
  * Raw SQL query
79 79
  */
80
-int db_mysql_raw_query(const db1_con_t* _h, const str* _s, db_res_t** _r);
80
+int db_mysql_raw_query(const db1_con_t* _h, const str* _s, db1_res_t** _r);
81 81
 
82 82
 
83 83
 /*! \brief
... ...
@@ -50,7 +50,7 @@
50 50
  * \param _r database result set
51 51
  * \return 0 on success, negative on failure
52 52
  */
53
-int db_mysql_get_columns(const db1_con_t* _h, db_res_t* _r)
53
+int db_mysql_get_columns(const db1_con_t* _h, db1_res_t* _r)
54 54
 {
55 55
 	int col;
56 56
 	MYSQL_FIELD* fields;
... ...
@@ -155,7 +155,7 @@ int db_mysql_get_columns(const db1_con_t* _h, db_res_t* _r)
155 155
  * \param _r database result set
156 156
  * \return 0 on success, negative on failure
157 157
  */
158
-static inline int db_mysql_convert_rows(const db1_con_t* _h, db_res_t* _r)
158
+static inline int db_mysql_convert_rows(const db1_con_t* _h, db1_res_t* _r)
159 159
 {
160 160
 	int row;
161 161
 
... ...
@@ -201,7 +201,7 @@ static inline int db_mysql_convert_rows(const db1_con_t* _h, db_res_t* _r)
201 201
  * \param _r database result
202 202
  * \return 0 on success, negative on failure
203 203
  */
204
-int db_mysql_convert_result(const db1_con_t* _h, db_res_t* _r)
204
+int db_mysql_convert_result(const db1_con_t* _h, db1_res_t* _r)
205 205
 {
206 206
 	if ((!_h) || (!_r)) {
207 207
 		LM_ERR("invalid parameter\n");
... ...
@@ -44,7 +44,7 @@
44 44
  * \param _r database result
45 45
  * \return 0 on success, negative on failure
46 46
  */
47
-int db_mysql_convert_result(const db1_con_t* _h, db_res_t* _r);
47
+int db_mysql_convert_result(const db1_con_t* _h, db1_res_t* _r);
48 48
 
49 49
 
50 50
 /*!
... ...
@@ -53,6 +53,6 @@ int db_mysql_convert_result(const db1_con_t* _h, db_res_t* _r);
53 53
  * \param _r database result set
54 54
  * \return 0 on success, negative on failure
55 55
  */
56
-int db_mysql_get_columns(const db1_con_t* _h, db_res_t* _r);
56
+int db_mysql_get_columns(const db1_con_t* _h, db1_res_t* _r);
57 57
 
58 58
 #endif
... ...
@@ -44,7 +44,7 @@
44 44
  * \param _r database result row
45 45
  * \return 0 on success, -1 on failure
46 46
  */
47
-int db_mysql_convert_row(const db1_con_t* _h, db_res_t* _res, db_row_t* _r)
47
+int db_mysql_convert_row(const db1_con_t* _h, db1_res_t* _res, db_row_t* _r)
48 48
 {
49 49
 	unsigned long* lengths;
50 50
 	int i;
... ...
@@ -46,6 +46,6 @@
46 46
  * \param _r database result row
47 47
  * \return 0 on success, -1 on failure
48 48
  */
49
-int db_mysql_convert_row(const db1_con_t* _h, db_res_t* _res, db_row_t* _r);
49
+int db_mysql_convert_row(const db1_con_t* _h, db1_res_t* _res, db_row_t* _r);
50 50
 
51 51
 #endif