diff options
author | Akira TAGOH <akira@tagoh.org> | 2022-12-05 21:40:26 +0900 |
---|---|---|
committer | Akira TAGOH <akira@tagoh.org> | 2022-12-05 21:40:26 +0900 |
commit | ed6c9cf67b46ce467e17eaeca4738a864e2b2ca3 (patch) | |
tree | 205ea1e077ccf0c0a6297be66161267fd428b05d /src/fcatomic.c | |
parent | 6663fe457dd3edd9dca8430603ffbec1905be4d4 (diff) | |
download | fontconfig-ed6c9cf67b46ce467e17eaeca4738a864e2b2ca3.tar.gz |
Ignore null pointer on Fc*Destroy functions
Fixes https://gitlab.freedesktop.org/fontconfig/fontconfig/-/issues/339
Diffstat (limited to 'src/fcatomic.c')
-rw-r--r-- | src/fcatomic.c | 3 |
1 files changed, 2 insertions, 1 deletions
diff --git a/src/fcatomic.c b/src/fcatomic.c index 5b5e030..be09457 100644 --- a/src/fcatomic.c +++ b/src/fcatomic.c @@ -229,7 +229,8 @@ FcAtomicUnlock (FcAtomic *atomic) void FcAtomicDestroy (FcAtomic *atomic) { - free (atomic); + if (atomic) + free (atomic); } #define __fcatomic__ #include "fcaliastail.h" |