[sr-dev] git:master: srdb1: removed extern inline function prototypes

Daniel-Constantin Mierla miconda at gmail.com
Fri Apr 11 16:22:03 CEST 2014


Module: sip-router
Branch: master
Commit: 5beb495d47fa16ed94c36e340011c09de50db9c7
URL:    http://git.sip-router.org/cgi-bin/gitweb.cgi/sip-router/?a=commit;h=5beb495d47fa16ed94c36e340011c09de50db9c7

Author: Daniel-Constantin Mierla <miconda at gmail.com>
Committer: Daniel-Constantin Mierla <miconda at gmail.com>
Date:   Fri Apr 11 16:18:59 2014 +0200

srdb1: removed extern inline function prototypes

- the .c files are not linked against modules code, thus inline
  replacing request cannot be resolved by compilers, the strict ones
  (e.g., llvm) throw error

---

 lib/srdb1/db_res.c |   12 ++++++------
 lib/srdb1/db_res.h |   12 ++++++------
 2 files changed, 12 insertions(+), 12 deletions(-)

diff --git a/lib/srdb1/db_res.c b/lib/srdb1/db_res.c
index 8d2146e..aa4b026 100644
--- a/lib/srdb1/db_res.c
+++ b/lib/srdb1/db_res.c
@@ -41,7 +41,7 @@
 /*
  * Release memory used by rows
  */
-inline int db_free_rows(db1_res_t* _r)
+int db_free_rows(db1_res_t* _r)
 {
 	int i;
 
@@ -70,7 +70,7 @@ inline int db_free_rows(db1_res_t* _r)
 /*
  * Release memory used by columns
  */
-inline int db_free_columns(db1_res_t* _r)
+int db_free_columns(db1_res_t* _r)
 {
 	int col;
 
@@ -106,7 +106,7 @@ inline int db_free_columns(db1_res_t* _r)
 /*
  * Create a new result structure and initialize it
  */
-inline db1_res_t* db_new_result(void)
+db1_res_t* db_new_result(void)
 {
 	db1_res_t* r = NULL;
 	r = (db1_res_t*)pkg_malloc(sizeof(db1_res_t));
@@ -123,7 +123,7 @@ inline db1_res_t* db_new_result(void)
 /*
  * Release memory used by a result structure
  */
-inline int db_free_result(db1_res_t* _r)
+int db_free_result(db1_res_t* _r)
 {
 	if (!_r)
 	{
@@ -143,7 +143,7 @@ inline int db_free_result(db1_res_t* _r)
  * Allocate storage for column names and type in existing
  * result structure.
  */
-inline int db_allocate_columns(db1_res_t* _r, const unsigned int cols)
+int db_allocate_columns(db1_res_t* _r, const unsigned int cols)
 {
 	RES_NAMES(_r) = (db_key_t*)pkg_malloc(sizeof(db_key_t) * cols);
 	if (!RES_NAMES(_r)) {
@@ -173,7 +173,7 @@ inline int db_allocate_columns(db1_res_t* _r, const unsigned int cols)
  * \param _res result set
  * \return zero on success, negative on errors
  */
-inline int db_allocate_rows(db1_res_t* _res)
+int db_allocate_rows(db1_res_t* _res)
 {
 	int len = sizeof(db_row_t) * RES_ROW_N(_res);
 	RES_ROWS(_res) = (struct db_row*)pkg_malloc(len);
diff --git a/lib/srdb1/db_res.h b/lib/srdb1/db_res.h
index 62fc11c..d802cc3 100644
--- a/lib/srdb1/db_res.h
+++ b/lib/srdb1/db_res.h
@@ -88,7 +88,7 @@ typedef struct db1_res {
  * \param _r the result that should be released
  * \return zero on success, negative on errors
  */
-extern inline int db_free_rows(db1_res_t* _r);
+int db_free_rows(db1_res_t* _r);
 
 
 /**
@@ -98,20 +98,20 @@ extern inline int db_free_rows(db1_res_t* _r);
  * \param _r the result that should be released
  * \return zero on success, negative on errors
  */
-extern inline int db_free_columns(db1_res_t* _r);
+int db_free_columns(db1_res_t* _r);
 
 
 /**
  * Create a new result structure and initialize it.
  * \return a pointer to the new result on success, NULL on errors
  */
-extern inline db1_res_t* db_new_result(void);
+db1_res_t* db_new_result(void);
 
 /**
  * Release memory used by a result structure.
  * \return zero on success, negative on errors
  */
-extern inline int db_free_result(db1_res_t* _r);
+int db_free_result(db1_res_t* _r);
 
 /**
  * Allocate storage for column names and type in existing result structure.
@@ -121,7 +121,7 @@ extern inline int db_free_result(db1_res_t* _r);
  * \param cols number of columns
  * \return zero on success, negative on errors
  */
-extern inline int db_allocate_columns(db1_res_t* _r, const unsigned int cols);
+int db_allocate_columns(db1_res_t* _r, const unsigned int cols);
 
 
 /**
@@ -129,6 +129,6 @@ extern inline int db_allocate_columns(db1_res_t* _r, const unsigned int cols);
  * \param _res result set
  * \return zero on success, negative on errors
  */
-extern inline int db_allocate_rows(db1_res_t* _res);
+int db_allocate_rows(db1_res_t* _res);
 
 #endif /* DB1_RES_H */




More information about the sr-dev mailing list