mirror of
https://forge.fsky.io/lda/Parsee.git
synced 2026-03-13 10:45:11 +00:00
[FIX] URL encode filenames
This commit is contained in:
parent
e617b5e8d4
commit
e331d110c7
1 changed files with 4 additions and 1 deletions
|
|
@ -1,6 +1,7 @@
|
|||
#include <Parsee.h>
|
||||
|
||||
#include <Cytoplasm/Memory.h>
|
||||
#include <Cytoplasm/Http.h>
|
||||
#include <Cytoplasm/Json.h>
|
||||
#include <Cytoplasm/Util.h>
|
||||
#include <Cytoplasm/Str.h>
|
||||
|
|
@ -725,12 +726,14 @@ ParseeToUnauth(ParseeData *data, char *mxc, char *filename)
|
|||
}
|
||||
else
|
||||
{
|
||||
char *encoded = HttpUrlEncode(filename);
|
||||
l = snprintf(NULL, 0,
|
||||
PATF,
|
||||
data->config->media_base,
|
||||
url->host, url->path, filename,
|
||||
url->host, url->path, encoded,
|
||||
hmac
|
||||
);
|
||||
Free(encoded);
|
||||
}
|
||||
ret = Malloc(l + 3);
|
||||
if (!filename)
|
||||
|
|
|
|||
Loading…
Add table
Add a link
Reference in a new issue