Skip to content
Projects
Groups
Snippets
Help
Loading...
Help
Support
Keyboard shortcuts
?
Submit feedback
Contribute to GitLab
Sign in
Toggle navigation
V
vlc-gpu
Project overview
Project overview
Details
Activity
Releases
Repository
Repository
Files
Commits
Branches
Tags
Contributors
Graph
Compare
Issues
0
Issues
0
List
Boards
Labels
Milestones
Redmine
Redmine
Merge Requests
0
Merge Requests
0
CI / CD
CI / CD
Pipelines
Jobs
Schedules
Operations
Operations
Metrics
Environments
Analytics
Analytics
CI / CD
Repository
Value Stream
Wiki
Wiki
Snippets
Snippets
Members
Members
Collapse sidebar
Close sidebar
Activity
Graph
Create a new issue
Jobs
Commits
Issue Boards
Open sidebar
videolan
vlc-gpu
Commits
4337a2d9
Commit
4337a2d9
authored
May 06, 2010
by
Erwan Tulou
Browse files
Options
Browse Files
Download
Email Patches
Plain Diff
skins2: fix memory leak (a malloc not paired with a free)
parent
a47b7c7a
Changes
2
Hide whitespace changes
Inline
Side-by-side
Showing
2 changed files
with
13 additions
and
6 deletions
+13
-6
modules/gui/skins2/commands/cmd_vars.hpp
modules/gui/skins2/commands/cmd_vars.hpp
+12
-2
modules/gui/skins2/src/vlcproc.cpp
modules/gui/skins2/src/vlcproc.cpp
+1
-4
No files found.
modules/gui/skins2/commands/cmd_vars.hpp
View file @
4337a2d9
...
@@ -71,8 +71,18 @@ class CmdPlaytreeAppend: public CmdGeneric
...
@@ -71,8 +71,18 @@ class CmdPlaytreeAppend: public CmdGeneric
{
{
public:
public:
CmdPlaytreeAppend
(
intf_thread_t
*
pIntf
,
playlist_add_t
*
p_add
)
:
CmdPlaytreeAppend
(
intf_thread_t
*
pIntf
,
playlist_add_t
*
p_add
)
:
CmdGeneric
(
pIntf
),
m_pAdd
(
p_add
)
{
}
CmdGeneric
(
pIntf
),
m_pAdd
(
NULL
)
virtual
~
CmdPlaytreeAppend
()
{
}
{
if
(
p_add
)
{
m_pAdd
=
new
playlist_add_t
;
*
m_pAdd
=
*
p_add
;
}
}
virtual
~
CmdPlaytreeAppend
()
{
delete
m_pAdd
;
}
virtual
void
execute
();
virtual
void
execute
();
virtual
string
getType
()
const
{
return
"playtree append"
;
}
virtual
string
getType
()
const
{
return
"playtree append"
;
}
...
...
modules/gui/skins2/src/vlcproc.cpp
View file @
4337a2d9
...
@@ -287,10 +287,7 @@ int VlcProc::onItemAppend( vlc_object_t *pObj, const char *pVariable,
...
@@ -287,10 +287,7 @@ int VlcProc::onItemAppend( vlc_object_t *pObj, const char *pVariable,
{
{
VlcProc
*
pThis
=
(
VlcProc
*
)
pParam
;
VlcProc
*
pThis
=
(
VlcProc
*
)
pParam
;
playlist_add_t
*
p_add
=
(
playlist_add_t
*
)
malloc
(
sizeof
(
playlist_add_t
*
p_add
=
static_cast
<
playlist_add_t
*>
(
newVal
.
p_address
);
playlist_add_t
)
)
;
memcpy
(
p_add
,
newVal
.
p_address
,
sizeof
(
playlist_add_t
)
)
;
CmdGenericPtr
ptrTree
;
CmdGenericPtr
ptrTree
;
CmdPlaytreeAppend
*
pCmdTree
=
new
CmdPlaytreeAppend
(
pThis
->
getIntf
(),
CmdPlaytreeAppend
*
pCmdTree
=
new
CmdPlaytreeAppend
(
pThis
->
getIntf
(),
...
...
Write
Preview
Markdown
is supported
0%
Try again
or
attach a new file
Attach a file
Cancel
You are about to add
0
people
to the discussion. Proceed with caution.
Finish editing this message first!
Cancel
Please
register
or
sign in
to comment