Jelajahi Sumber

presence: more use of variable for received_time column instead of static value

Daniel-Constantin Mierla 10 tahun lalu
induk
melakukan
beba457977
1 mengubah file dengan 2 tambahan dan 1 penghapusan
  1. 2 1
      modules/presence/presentity.c

+ 2 - 1
modules/presence/presentity.c

@@ -1022,6 +1022,7 @@ char* get_sphere(str* pres_uri)
 	int n_query_cols = 0;
 	struct sip_uri uri;
 	str body;
+	static str query_str;
 
 
 	if(!sphere_enable)
@@ -1087,7 +1088,7 @@ char* get_sphere(str* pres_uri)
 		return NULL;
 	}
 
-	static str query_str = str_init("received_time");
+	query_str = str_received_time_col;
 	if (pa_dbf.query (pa_db, query_cols, 0, query_vals,
 		 result_cols, n_query_cols, n_result_cols, &query_str ,  &result) < 0) 
 	{