summaryrefslogtreecommitdiff
path: root/test/stream
diff options
context:
space:
mode:
authorTomi Valkeinen <tomi.valkeinen@ideasonboard.com>2022-08-29 11:44:44 +0300
committerLaurent Pinchart <laurent.pinchart@ideasonboard.com>2022-10-20 02:41:48 +0300
commit662df4ca26cfe9603a2824d31131324c30c8b6bd (patch)
tree9c33fad4ebaaea4b4a9434095061670f79b7c811 /test/stream
parent376adeb7b7e0b75f2fa90b890fe0203d1e268cdf (diff)
libcamera: base: log: Fix use of freed name
LogCategory just stores the char * that was given to it in the constructor, i.e. it refers to memory "outside" LogCategory. If the LogCategory is defined in a .so that is unloaded, then it leads to the LogCategory pointing to freed memory, causing a crash. Fix this by taking a copy of the name by using a std::string instead of just storing the pointer. Signed-off-by: Tomi Valkeinen <tomi.valkeinen@ideasonboard.com> Reviewed-by: Laurent Pinchart <laurent.pinchart@ideasonboard.com> Reviewed-by: Kieran Bingham <kieran.bingham@ideasonboard.com> Signed-off-by: Laurent Pinchart <laurent.pinchart@ideasonboard.com>
Diffstat (limited to 'test/stream')
0 files changed, 0 insertions, 0 deletions