Forráskód Böngészése

presence: init variable to prevent invalid cleanup on error getting presence document

- reported by GH#441
Daniel-Constantin Mierla 9 éve
szülő
commit
d24863d071
1 módosított fájl, 1 hozzáadás és 1 törlés
  1. 1 1
      modules/presence/publish.c

+ 1 - 1
modules/presence/publish.c

@@ -509,7 +509,7 @@ error:
 int update_hard_presentity(str *pres_uri, pres_ev_t *event, str *file_uri, str *filename)
 int update_hard_presentity(str *pres_uri, pres_ev_t *event, str *file_uri, str *filename)
 {
 {
 	int ret = -1, new_t, pidf_result;
 	int ret = -1, new_t, pidf_result;
-	str *pidf_doc;
+	str *pidf_doc = 0;
 	char *sphere = NULL;
 	char *sphere = NULL;
 	presentity_t *pres = NULL;
 	presentity_t *pres = NULL;
 	struct sip_uri parsed_uri;
 	struct sip_uri parsed_uri;