Skip to content
Projects
Groups
Snippets
Help
This project
Loading...
Sign in / Register
Toggle navigation
W
wine-winehq
Project
Project
Details
Activity
Cycle Analytics
Repository
Repository
Files
Commits
Branches
Tags
Contributors
Graph
Compare
Charts
Issues
0
Issues
0
List
Board
Labels
Milestones
Merge Requests
0
Merge Requests
0
CI / CD
CI / CD
Pipelines
Jobs
Schedules
Charts
Registry
Registry
Wiki
Wiki
Snippets
Snippets
Members
Members
Collapse sidebar
Close sidebar
Activity
Graph
Charts
Create a new issue
Jobs
Commits
Issue Boards
Open sidebar
wine
wine-winehq
Commits
173f7bd2
Commit
173f7bd2
authored
Oct 09, 2006
by
Michael Stefaniuc
Committed by
Alexandre Julliard
Oct 10, 2006
Browse files
Options
Browse Files
Download
Email Patches
Plain Diff
janitorial: Remove remaining NULL checks before free() (found by Smatch).
parent
0fb444b5
Show whitespace changes
Inline
Side-by-side
Showing
8 changed files
with
5 additions
and
19 deletions
+5
-19
chm_lib.c
dlls/itss/chm_lib.c
+0
-1
lzx.c
dlls/itss/lzx.c
+0
-1
file.c
dlls/msvcrt/tests/file.c
+2
-2
ungif.c
dlls/oleaut32/ungif.c
+0
-3
audio.c
dlls/winmm/winenas/audio.c
+0
-1
ppl.l
libs/wpp/ppl.l
+1
-5
wpp.c
libs/wpp/wpp.c
+2
-2
perfdata.c
programs/taskmgr/perfdata.c
+0
-4
No files found.
dlls/itss/chm_lib.c
View file @
173f7bd2
...
...
@@ -805,7 +805,6 @@ void chm_close(struct chmFile *h)
h
->
cache_blocks
=
NULL
;
}
if
(
h
->
cache_block_indices
)
free
(
h
->
cache_block_indices
);
h
->
cache_block_indices
=
NULL
;
...
...
dlls/itss/lzx.c
View file @
173f7bd2
...
...
@@ -208,7 +208,6 @@ void LZXteardown(struct LZXstate *pState)
{
if
(
pState
)
{
if
(
pState
->
window
)
free
(
pState
->
window
);
free
(
pState
);
}
...
...
dlls/msvcrt/tests/file.c
View file @
173f7bd2
...
...
@@ -385,7 +385,7 @@ static void test_fgetwc( void )
ok
(
!
(
diff_found
),
"fgetwc difference found in BINARY mode
\n
"
);
ok
(
*
wptr
==
'\n'
,
"Should get newline
\n
"
);
if
(
mytextW
)
free
(
mytextW
);
free
(
mytextW
);
fclose
(
tempfh
);
unlink
(
tempf
);
}
...
...
@@ -481,7 +481,7 @@ static void test_file_put_get( void )
diff_found
|=
(
*
aptr
!=
*
wptr
);
}
ok
(
!
(
diff_found
),
"fgetwc doesn't strip CR in TEXT mode
\n
"
);
if
(
mytextW
)
free
(
mytextW
);
free
(
mytextW
);
fclose
(
tempfh
);
unlink
(
tempf
);
}
...
...
dlls/oleaut32/ungif.c
View file @
173f7bd2
...
...
@@ -231,7 +231,6 @@ FreeSavedImages(GifFileType * GifFile) {
sp
->
ImageDesc
.
ColorMap
=
NULL
;
}
if
(
sp
->
RasterBits
)
free
(
sp
->
RasterBits
);
if
(
sp
->
ExtensionBlocks
)
...
...
@@ -962,10 +961,8 @@ DGifCloseFile(GifFileType * GifFile) {
GifFile
->
SColorMap
=
NULL
;
}
if
(
Private
)
{
free
(
Private
);
Private
=
NULL
;
}
if
(
GifFile
->
SavedImages
)
{
FreeSavedImages
(
GifFile
);
...
...
dlls/winmm/winenas/audio.c
View file @
173f7bd2
...
...
@@ -1379,7 +1379,6 @@ buffer_resize(WINE_WAVEOUT* wwo, int len)
void
*
oldbuf
=
wwo
->
SoundBuffer
;
memcpy
(
newbuf
,
oldbuf
,
wwo
->
BufferUsed
);
wwo
->
SoundBuffer
=
newbuf
;
if
(
oldbuf
!=
NULL
)
free
(
oldbuf
);
}
...
...
libs/wpp/ppl.l
View file @
173f7bd2
...
...
@@ -1249,10 +1249,9 @@ static bufferstackentry_t *pop_buffer(void)
if(pp_status.debug)
fprintf(stderr, "pop_buffer: %s:%d: includelogic added, include_ppp='%s', file='%s'\n", pp_status.input, pp_status.line_number, pp_incl_state.ppp, iep->filename);
}
else
if(bufferstack[bufferstackidx].include_filename)
else
free(bufferstack[bufferstackidx].include_filename);
}
if(pp_incl_state.ppp)
free(pp_incl_state.ppp);
pp_incl_state = bufferstack[bufferstackidx].incl;
pass_data = bufferstack[bufferstackidx].pass_data;
...
...
@@ -1320,11 +1319,8 @@ static void free_macro(macexpstackentry_t *mep)
for(i = 0; i < mep->nargs; i++)
free(mep->args[i]);
if(mep->args)
free(mep->args);
if(mep->nnls)
free(mep->nnls);
if(mep->curarg)
free(mep->curarg);
free(mep);
}
...
...
libs/wpp/wpp.c
View file @
173f7bd2
...
...
@@ -80,7 +80,7 @@ void wpp_add_define( const char *name, const char *value )
{
if
(
!
strcmp
(
def
->
name
,
name
))
{
if
(
def
->
value
)
free
(
def
->
value
);
free
(
def
->
value
);
def
->
value
=
pp_xstrdup
(
value
);
return
;
}
...
...
@@ -103,7 +103,7 @@ void wpp_del_define( const char *name )
{
if
(
!
strcmp
(
def
->
name
,
name
))
{
if
(
def
->
value
)
free
(
def
->
value
);
free
(
def
->
value
);
def
->
value
=
NULL
;
return
;
}
...
...
programs/taskmgr/perfdata.c
View file @
173f7bd2
...
...
@@ -178,9 +178,7 @@ void PerfDataRefresh(void)
/*
* Save system processor time info
*/
if
(
SystemProcessorTimeInfo
)
{
free
(
SystemProcessorTimeInfo
);
}
SystemProcessorTimeInfo
=
SysProcessorTimeInfo
;
/*
...
...
@@ -231,9 +229,7 @@ void PerfDataRefresh(void)
}
/* Now alloc a new PERFDATA array and fill in the data */
if
(
pPerfDataOld
)
{
free
(
pPerfDataOld
);
}
pPerfDataOld
=
pPerfData
;
pPerfData
=
(
PPERFDATA
)
malloc
(
sizeof
(
PERFDATA
)
*
ProcessCount
);
pSPI
=
(
PSYSTEM_PROCESS_INFORMATION
)
pBuffer
;
...
...
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