Revision 0bfdcc3a src/sdpfile.c

View differences:

src/sdpfile.c
118 118
{
119 119
	struct mg_connection * conn;
120 120
	struct pssdpfile * psdp;
121
	char sdpfile[MAX_SDPFILENAME_LENGTH];
121 122

  
122 123
	psdp = malloc(sizeof(struct pssdpfile));
123 124
	psdp->ps = ps;
124 125
	snprintf(psdp->path, MAX_PATH_LENGTH, "%s/%s.sdp", c->http_opts.document_root, pstreamer_id(ps));
126
	snprintf(sdpfile, MAX_SDPFILENAME_LENGTH, "%s.sdp", pstreamer_id(ps));
125 127

  
126 128
	conn = mg_connect_http(c->mongoose_srv, sdpfile_handler, ch->sdpfile, NULL, NULL);
127 129
	conn->user_data = (void *) psdp;
128 130

  
129
	return strdup(psdp->path);
131
	return strdup(sdpfile);
130 132
}

Also available in: Unified diff