summaryrefslogtreecommitdiff
path: root/src/media.h
diff options
context:
space:
mode:
authorJaakko Keränen <jaakko.keranen@iki.fi>2020-11-24 22:11:11 +0200
committerJaakko Keränen <jaakko.keranen@iki.fi>2020-11-24 22:11:11 +0200
commit5268fb9f7e1bca4b0fc496ff115c253aea724e49 (patch)
tree8023f45f3538f7966c2f75674a4b14fb4778e79c /src/media.h
parent9421f64ee86e6aec26e05a45bcfc65edd895a8a8 (diff)
Fixed threading issues and data races
The most serious problem was that GmRequest's response body was being accessed while the TlsRequest thread was modifying it. Now the response must always be locked before accessing elsewhere. There were also inefficient data updates in the media players.
Diffstat (limited to 'src/media.h')
-rw-r--r--src/media.h2
1 files changed, 1 insertions, 1 deletions
diff --git a/src/media.h b/src/media.h
index 12334936..ddaa2d3c 100644
--- a/src/media.h
+++ b/src/media.h
@@ -54,7 +54,7 @@ enum iMediaFlags {
54}; 54};
55 55
56void clear_Media (iMedia *); 56void clear_Media (iMedia *);
57void setData_Media (iMedia *, uint16_t linkId, const iString *mime, const iBlock *data, int flags); 57iBool setData_Media (iMedia *, uint16_t linkId, const iString *mime, const iBlock *data, int flags);
58 58
59iMediaId findLinkImage_Media (const iMedia *, uint16_t linkId); 59iMediaId findLinkImage_Media (const iMedia *, uint16_t linkId);
60iBool imageInfo_Media (const iMedia *, iMediaId imageId, iGmImageInfo *info_out); 60iBool imageInfo_Media (const iMedia *, iMediaId imageId, iGmImageInfo *info_out);