Skip to content
Projects
Groups
Snippets
Help
This project
Loading...
Sign in / Register
Toggle navigation
N
nx-libs
Project
Project
Details
Activity
Cycle Analytics
Repository
Repository
Files
Commits
Branches
Tags
Contributors
Graph
Compare
Charts
Issues
1
Issues
1
List
Board
Labels
Milestones
Merge Requests
0
Merge Requests
0
CI / CD
CI / CD
Pipelines
Jobs
Schedules
Charts
Wiki
Wiki
Members
Members
Collapse sidebar
Close sidebar
Activity
Graph
Charts
Create a new issue
Jobs
Commits
Issue Boards
Open sidebar
dimbor
nx-libs
Commits
447ee157
Commit
447ee157
authored
Oct 02, 2020
by
Ulrich Sibiller
Browse files
Options
Browse Files
Download
Email Patches
Plain Diff
Compext.c: use SAFE_free macro
parent
edb5a918
Expand all
Show whitespace changes
Inline
Side-by-side
Showing
4 changed files
with
20 additions
and
14 deletions
+20
-14
Compext.c
nx-X11/programs/Xserver/hw/nxagent/compext/Compext.c
+0
-0
Jpeg.c
nx-X11/programs/Xserver/hw/nxagent/compext/Jpeg.c
+4
-2
Png.c
nx-X11/programs/Xserver/hw/nxagent/compext/Png.c
+12
-10
Z.c
nx-X11/programs/Xserver/hw/nxagent/compext/Z.c
+4
-2
No files found.
nx-X11/programs/Xserver/hw/nxagent/compext/Compext.c
View file @
447ee157
This diff is collapsed.
Click to expand it.
nx-X11/programs/Xserver/hw/nxagent/compext/Jpeg.c
View file @
447ee157
...
...
@@ -38,6 +38,8 @@
#include "Mask.h"
#include "Jpeg.h"
#include "../Utils.h"
#define PANIC
#define WARNING
#undef TEST
...
...
@@ -277,7 +279,7 @@ char *JpegCompressData(XImage *image, int level, int *compressed_size)
jpegError
);
#endif
free
(
jpegCompBuf
);
SAFE_
free
(
jpegCompBuf
);
return
NULL
;
}
...
...
@@ -326,7 +328,7 @@ char *JpegCompressData(XImage *image, int level, int *compressed_size)
jpegDstDataLen
);
#endif
free
(
jpegCompBuf
);
SAFE_
free
(
jpegCompBuf
);
return
NULL
;
}
...
...
nx-X11/programs/Xserver/hw/nxagent/compext/Png.c
View file @
447ee157
...
...
@@ -34,6 +34,8 @@
#include "Mask.h"
#include "Png.h"
#include "../Utils.h"
#define PANIC
#define WARNING
#undef TEST
...
...
@@ -361,7 +363,7 @@ char *PngCompressData(XImage *image, int *compressed_size)
#endif
png_destroy_write_struct
(
&
png_ptr
,
&
info_ptr
);
free
(
pngCompBuf
);
SAFE_
free
(
pngCompBuf
);
return
NULL
;
}
...
...
@@ -373,7 +375,7 @@ char *PngCompressData(XImage *image, int *compressed_size)
fprintf
(
stderr
,
"******PngCompressData: PANIC! Could not alloc image_index.
\n
"
);
#endif
free
(
pngCompBuf
);
SAFE_
free
(
pngCompBuf
);
return
NULL
;
}
...
...
@@ -475,8 +477,8 @@ char *PngCompressData(XImage *image, int *compressed_size)
png_destroy_write_struct
(
&
png_ptr
,
&
info_ptr
);
free
(
pngCompBuf
);
free
(
image_index
);
SAFE_
free
(
pngCompBuf
);
SAFE_
free
(
image_index
);
return
NULL
;
}
...
...
@@ -500,8 +502,8 @@ char *PngCompressData(XImage *image, int *compressed_size)
(
int
)
(
count
*
sizeof
(
CARD8
)));
#endif
free
(
pngCompBuf
);
free
(
image_index
);
SAFE_
free
(
pngCompBuf
);
SAFE_
free
(
image_index
);
return
NULL
;
}
...
...
@@ -532,8 +534,8 @@ char *PngCompressData(XImage *image, int *compressed_size)
dy
,
h
);
#endif
free
(
srcBuf
);
srcBuf
=
NULL
;
free
(
image_index
);
image_index
=
NULL
;
SAFE_free
(
srcBuf
)
;
SAFE_free
(
image_index
)
;
if
(
setjmp
(
png_jmpbuf
(
png_ptr
)))
{
...
...
@@ -543,7 +545,7 @@ char *PngCompressData(XImage *image, int *compressed_size)
png_destroy_write_struct
(
&
png_ptr
,
&
info_ptr
);
free
(
pngCompBuf
);
SAFE_
free
(
pngCompBuf
);
return
NULL
;
}
...
...
@@ -594,7 +596,7 @@ char *PngCompressData(XImage *image, int *compressed_size)
pngDataLen
);
#endif
free
(
pngCompBuf
);
SAFE_
free
(
pngCompBuf
);
return
NULL
;
}
...
...
nx-X11/programs/Xserver/hw/nxagent/compext/Z.c
View file @
447ee157
...
...
@@ -33,6 +33,8 @@
#include "Z.h"
#include "../Utils.h"
#define PANIC
#define WARNING
#undef TEST
...
...
@@ -129,7 +131,7 @@ char *ZCompressData(const char *plainData, unsigned int plainSize, int threshold
plainSize
,
zError
(
result
));
#endif
free
(
compressedData
);
SAFE_
free
(
compressedData
);
*
compressedSize
=
0
;
...
...
@@ -300,7 +302,7 @@ int ZResetEncoder(void)
#endif
}
free
(
zStream
);
SAFE_
free
(
zStream
);
}
zInitialized
=
0
;
...
...
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