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
49f13e0e
Commit
49f13e0e
authored
Mar 28, 2010
by
Rémi Duraffort
Browse files
Options
Browse Files
Download
Email Patches
Plain Diff
Growl: fix a second buffer overflow.
parent
6af8bf05
Changes
1
Show whitespace changes
Inline
Side-by-side
Showing
1 changed file
with
16 additions
and
4 deletions
+16
-4
modules/misc/notify/growl_udp.c
modules/misc/notify/growl_udp.c
+16
-4
No files found.
modules/misc/notify/growl_udp.c
View file @
49f13e0e
...
...
@@ -225,6 +225,17 @@ static int NotifyToGrowl( vlc_object_t *p_this, const char *psz_desc )
if
(
psz_encoded
==
NULL
)
return
false
;
// Check the size of the data
size_t
i_type
=
strlen
(
psz_type
);
size_t
i_title
=
strlen
(
psz_title
);
size_t
i_app
=
strlen
(
APPLICATION_NAME
);
size_t
i_desc
=
strlen
(
psz_desc
);
if
(
12
+
i_type
+
i_title
+
i_desc
+
i_app
>=
GROWL_MAX_LENGTH
+
42
)
{
free
(
psz_encoded
);
return
false
;
}
psz_encoded
[
i
++
]
=
GROWL_PROTOCOL_VERSION
;
psz_encoded
[
i
++
]
=
GROWL_TYPE_NOTIFICATION
;
flags
=
0
;
...
...
@@ -234,14 +245,15 @@ static int NotifyToGrowl( vlc_object_t *p_this, const char *psz_desc )
insertstrlen
(
psz_title
);
insertstrlen
(
psz_desc
);
insertstrlen
(
APPLICATION_NAME
);
strcpy
(
(
char
*
)(
psz_encoded
+
i
),
psz_type
);
i
+=
strlen
(
psz_type
)
;
i
+=
i_type
;
strcpy
(
(
char
*
)(
psz_encoded
+
i
),
psz_title
);
i
+=
strlen
(
psz_title
)
;
i
+=
i_title
;
strcpy
(
(
char
*
)(
psz_encoded
+
i
),
psz_desc
);
i
+=
strlen
(
psz_desc
)
;
i
+=
i_desc
;
strcpy
(
(
char
*
)(
psz_encoded
+
i
),
APPLICATION_NAME
);
i
+=
strlen
(
APPLICATION_NAME
)
;
i
+=
i_app
;
CheckAndSend
(
p_this
,
psz_encoded
,
i
,
GROWL_MAX_LENGTH
+
42
);
free
(
psz_encoded
);
...
...
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