Skip to content
Projects
Groups
Snippets
Help
Loading...
Help
Support
Keyboard shortcuts
?
Submit feedback
Contribute to GitLab
Sign in
Toggle navigation
V
vlc
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
Commits
3b93bdce
Commit
3b93bdce
authored
Dec 21, 2015
by
Rémi Denis-Courmont
Browse files
Options
Browse Files
Download
Email Patches
Plain Diff
sap: use xrealloc()
parent
67124b22
Changes
1
Show whitespace changes
Inline
Side-by-side
Showing
1 changed file
with
3 additions
and
3 deletions
+3
-3
modules/services_discovery/sap.c
modules/services_discovery/sap.c
+3
-3
No files found.
modules/services_discovery/sap.c
View file @
3b93bdce
...
...
@@ -726,7 +726,7 @@ static int ParseSAP( services_discovery_t *p_sd, const uint8_t *buf,
return
VLC_EGENERIC
;
}
decomp
=
realloc
(
decomp
,
newsize
+
1
);
decomp
=
x
realloc
(
decomp
,
newsize
+
1
);
decomp
[
newsize
]
=
'\0'
;
psz_sdp
=
(
const
char
*
)
decomp
;
len
=
newsize
;
...
...
@@ -1496,7 +1496,7 @@ static int Decompress( const unsigned char *psz_src, unsigned char **_dst, int i
do
{
n
++
;
psz_dst
=
(
unsigned
char
*
)
realloc
(
psz_dst
,
n
*
1000
);
psz_dst
=
x
realloc
(
psz_dst
,
n
*
1000
);
d_stream
.
next_out
=
(
Bytef
*
)
&
psz_dst
[(
n
-
1
)
*
1000
];
d_stream
.
avail_out
=
1000
;
...
...
@@ -1514,7 +1514,7 @@ static int Decompress( const unsigned char *psz_src, unsigned char **_dst, int i
i_dstsize
=
d_stream
.
total_out
;
inflateEnd
(
&
d_stream
);
*
_dst
=
(
unsigned
char
*
)
realloc
(
psz_dst
,
i_dstsize
);
*
_dst
=
x
realloc
(
psz_dst
,
i_dstsize
);
return
i_dstsize
;
#else
...
...
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