commit 832254f482339762aebcba278e34972cfb01933f parent 22b65257e224f47d9d1dc5c76d989753c06eb68d Author: Remy Noulin <loader2x@gmail.com> Date: Wed, 1 Jan 2025 21:39:26 +0200 fix buffer overflow (by 1 byte) in stripColorsS function update copyright year 2025 LICENSE | 2 +- release/json/libsheepyCSmallArray.h | 2 +- release/json/libsheepyCSmallBool.h | 2 +- release/json/libsheepyCSmallBytes.h | 2 +- release/json/libsheepyCSmallContainer.h | 2 +- release/json/libsheepyCSmallDict.h | 2 +- release/json/libsheepyCSmallDouble.h | 2 +- release/json/libsheepyCSmallInt.h | 2 +- release/json/libsheepyCSmallJson.h | 2 +- release/json/libsheepyCSmallString.h | 2 +- release/json/libsheepyCUndefined.h | 2 +- release/json/recycleContainers.h | 2 +- release/libsheepy.c | 6 +++--- release/libsheepy.h | 4 ++-- release/libsheepyObject.h | 2 +- release/libsheepySmall.c | 2 +- release/libsheepySmall.h | 2 +- src/json/libsheepyCSmallArray.c | 2 +- src/json/libsheepyCSmallArray.h | 2 +- src/json/libsheepyCSmallArrayInternal.h | 2 +- src/json/libsheepyCSmallBool.c | 2 +- src/json/libsheepyCSmallBool.h | 2 +- src/json/libsheepyCSmallBoolInternal.h | 2 +- src/json/libsheepyCSmallBytes.c | 2 +- src/json/libsheepyCSmallBytes.h | 2 +- src/json/libsheepyCSmallBytesInternal.h | 2 +- src/json/libsheepyCSmallContainer.c | 2 +- src/json/libsheepyCSmallContainer.h | 2 +- src/json/libsheepyCSmallContainerInternal.h | 2 +- src/json/libsheepyCSmallDict.c | 2 +- src/json/libsheepyCSmallDict.h | 2 +- src/json/libsheepyCSmallDictInternal.h | 2 +- src/json/libsheepyCSmallDouble.c | 2 +- src/json/libsheepyCSmallDouble.h | 2 +- src/json/libsheepyCSmallDoubleInternal.h | 2 +- src/json/libsheepyCSmallInt.c | 2 +- src/json/libsheepyCSmallInt.h | 2 +- src/json/libsheepyCSmallIntInternal.h | 2 +- src/json/libsheepyCSmallJson.c | 2 +- src/json/libsheepyCSmallJson.h | 2 +- src/json/libsheepyCSmallJsonInternal.h | 2 +- src/json/libsheepyCSmallString.c | 2 +- src/json/libsheepyCSmallString.h | 2 +- src/json/libsheepyCSmallStringInternal.h | 2 +- src/json/libsheepyCUndefined.c | 2 +- src/json/libsheepyCUndefined.h | 2 +- src/json/libsheepyCUndefinedInternal.h | 2 +- src/json/libsheepyObject.c | 2 +- src/json/recycleContainers.h | 2 +- src/libsheepy.c | 6 +++--- src/libsheepy.h | 4 ++-- src/libsheepyObject.h | 2 +- src/libsheepySmall.c | 2 +- src/libsheepySmall.h | 2 +- 54 files changed, 60 insertions(+), 60 deletions(-) Diffstat:
54 files changed, 60 insertions(+), 60 deletions(-)
diff --git a/LICENSE b/LICENSE @@ -1,6 +1,6 @@ MIT License -Copyright (c) 2024 Remy Noulin +Copyright (c) 2025 Remy Noulin Permission is hereby granted, free of charge, to any person obtaining a copy of this software and associated documentation files (the "Software"), to deal diff --git a/release/json/libsheepyCSmallArray.h b/release/json/libsheepyCSmallArray.h @@ -1,6 +1,6 @@ // MIT License // -// Copyright (c) 2024 Remy Noulin +// Copyright (c) 2025 Remy Noulin // // Permission is hereby granted, free of charge, to any person obtaining a copy // of this software and associated documentation files (the "Software"), to deal diff --git a/release/json/libsheepyCSmallBool.h b/release/json/libsheepyCSmallBool.h @@ -1,6 +1,6 @@ // MIT License // -// Copyright (c) 2024 Remy Noulin +// Copyright (c) 2025 Remy Noulin // // Permission is hereby granted, free of charge, to any person obtaining a copy // of this software and associated documentation files (the "Software"), to deal diff --git a/release/json/libsheepyCSmallBytes.h b/release/json/libsheepyCSmallBytes.h @@ -1,6 +1,6 @@ // MIT License // -// Copyright (c) 2024 Remy Noulin +// Copyright (c) 2025 Remy Noulin // // Permission is hereby granted, free of charge, to any person obtaining a copy // of this software and associated documentation files (the "Software"), to deal diff --git a/release/json/libsheepyCSmallContainer.h b/release/json/libsheepyCSmallContainer.h @@ -1,6 +1,6 @@ // MIT License // -// Copyright (c) 2024 Remy Noulin +// Copyright (c) 2025 Remy Noulin // // Permission is hereby granted, free of charge, to any person obtaining a copy // of this software and associated documentation files (the "Software"), to deal diff --git a/release/json/libsheepyCSmallDict.h b/release/json/libsheepyCSmallDict.h @@ -1,6 +1,6 @@ // MIT License // -// Copyright (c) 2024 Remy Noulin +// Copyright (c) 2025 Remy Noulin // // Permission is hereby granted, free of charge, to any person obtaining a copy // of this software and associated documentation files (the "Software"), to deal diff --git a/release/json/libsheepyCSmallDouble.h b/release/json/libsheepyCSmallDouble.h @@ -1,6 +1,6 @@ // MIT License // -// Copyright (c) 2024 Remy Noulin +// Copyright (c) 2025 Remy Noulin // // Permission is hereby granted, free of charge, to any person obtaining a copy // of this software and associated documentation files (the "Software"), to deal diff --git a/release/json/libsheepyCSmallInt.h b/release/json/libsheepyCSmallInt.h @@ -1,6 +1,6 @@ // MIT License // -// Copyright (c) 2024 Remy Noulin +// Copyright (c) 2025 Remy Noulin // // Permission is hereby granted, free of charge, to any person obtaining a copy // of this software and associated documentation files (the "Software"), to deal diff --git a/release/json/libsheepyCSmallJson.h b/release/json/libsheepyCSmallJson.h @@ -1,6 +1,6 @@ // MIT License // -// Copyright (c) 2024 Remy Noulin +// Copyright (c) 2025 Remy Noulin // // Permission is hereby granted, free of charge, to any person obtaining a copy // of this software and associated documentation files (the "Software"), to deal diff --git a/release/json/libsheepyCSmallString.h b/release/json/libsheepyCSmallString.h @@ -1,6 +1,6 @@ // MIT License // -// Copyright (c) 2024 Remy Noulin +// Copyright (c) 2025 Remy Noulin // // Permission is hereby granted, free of charge, to any person obtaining a copy // of this software and associated documentation files (the "Software"), to deal diff --git a/release/json/libsheepyCUndefined.h b/release/json/libsheepyCUndefined.h @@ -1,6 +1,6 @@ // MIT License // -// Copyright (c) 2024 Remy Noulin +// Copyright (c) 2025 Remy Noulin // // Permission is hereby granted, free of charge, to any person obtaining a copy // of this software and associated documentation files (the "Software"), to deal diff --git a/release/json/recycleContainers.h b/release/json/recycleContainers.h @@ -1,6 +1,6 @@ // MIT License // -// Copyright (c) 2024 Remy Noulin +// Copyright (c) 2025 Remy Noulin // // Permission is hereby granted, free of charge, to any person obtaining a copy // of this software and associated documentation files (the "Software"), to deal diff --git a/release/libsheepy.c b/release/libsheepy.c @@ -2,7 +2,7 @@ // // MIT License // -// Copyright (c) 2024 Remy Noulin +// Copyright (c) 2025 Remy Noulin // // Permission is hereby granted, free of charge, to any person obtaining a copy // of this software and associated documentation files (the "Software"), to deal @@ -9622,8 +9622,8 @@ char *stripColorsS(const char *string) { return(NULL); } - size_t len = strlen(string)+1; - r = MALLOC(len); + size_t len = strlen(string); + r = MALLOC(len+1); if (!r) { return(NULL); } diff --git a/release/libsheepy.h b/release/libsheepy.h @@ -1,6 +1,6 @@ // MIT License // -// Copyright (c) 2024 Remy Noulin +// Copyright (c) 2025 Remy Noulin // // Permission is hereby granted, free of charge, to any person obtaining a copy // of this software and associated documentation files (the "Software"), to deal @@ -98,7 +98,7 @@ // version accoring to the version package: Release.Major.minor.patch // https://noulin.net/version/file/README.md.html -#define LIBSHEEPY_VERSION "2.2.16" +#define LIBSHEEPY_VERSION "2.2.16.1" #ifndef SH_PREFIX #define SH_PREFIX(NAME) NAME diff --git a/release/libsheepyObject.h b/release/libsheepyObject.h @@ -1,6 +1,6 @@ // MIT License // -// Copyright (c) 2024 Remy Noulin +// Copyright (c) 2025 Remy Noulin // // Permission is hereby granted, free of charge, to any person obtaining a copy // of this software and associated documentation files (the "Software"), to deal diff --git a/release/libsheepySmall.c b/release/libsheepySmall.c @@ -1,6 +1,6 @@ // MIT License // -// Copyright (c) 2024 Remy Noulin +// Copyright (c) 2025 Remy Noulin // // Permission is hereby granted, free of charge, to any person obtaining a copy // of this software and associated documentation files (the "Software"), to deal diff --git a/release/libsheepySmall.h b/release/libsheepySmall.h @@ -1,6 +1,6 @@ // MIT License // -// Copyright (c) 2024 Remy Noulin +// Copyright (c) 2025 Remy Noulin // // Permission is hereby granted, free of charge, to any person obtaining a copy // of this software and associated documentation files (the "Software"), to deal diff --git a/src/json/libsheepyCSmallArray.c b/src/json/libsheepyCSmallArray.c @@ -1,6 +1,6 @@ // MIT License // -// Copyright (c) 2024 Remy Noulin +// Copyright (c) 2025 Remy Noulin // // Permission is hereby granted, free of charge, to any person obtaining a copy // of this software and associated documentation files (the "Software"), to deal diff --git a/src/json/libsheepyCSmallArray.h b/src/json/libsheepyCSmallArray.h @@ -1,6 +1,6 @@ // MIT License // -// Copyright (c) 2024 Remy Noulin +// Copyright (c) 2025 Remy Noulin // // Permission is hereby granted, free of charge, to any person obtaining a copy // of this software and associated documentation files (the "Software"), to deal diff --git a/src/json/libsheepyCSmallArrayInternal.h b/src/json/libsheepyCSmallArrayInternal.h @@ -1,6 +1,6 @@ // MIT License // -// Copyright (c) 2024 Remy Noulin +// Copyright (c) 2025 Remy Noulin // // Permission is hereby granted, free of charge, to any person obtaining a copy // of this software and associated documentation files (the "Software"), to deal diff --git a/src/json/libsheepyCSmallBool.c b/src/json/libsheepyCSmallBool.c @@ -1,6 +1,6 @@ // MIT License // -// Copyright (c) 2024 Remy Noulin +// Copyright (c) 2025 Remy Noulin // // Permission is hereby granted, free of charge, to any person obtaining a copy // of this software and associated documentation files (the "Software"), to deal diff --git a/src/json/libsheepyCSmallBool.h b/src/json/libsheepyCSmallBool.h @@ -1,6 +1,6 @@ // MIT License // -// Copyright (c) 2024 Remy Noulin +// Copyright (c) 2025 Remy Noulin // // Permission is hereby granted, free of charge, to any person obtaining a copy // of this software and associated documentation files (the "Software"), to deal diff --git a/src/json/libsheepyCSmallBoolInternal.h b/src/json/libsheepyCSmallBoolInternal.h @@ -1,6 +1,6 @@ // MIT License // -// Copyright (c) 2024 Remy Noulin +// Copyright (c) 2025 Remy Noulin // // Permission is hereby granted, free of charge, to any person obtaining a copy // of this software and associated documentation files (the "Software"), to deal diff --git a/src/json/libsheepyCSmallBytes.c b/src/json/libsheepyCSmallBytes.c @@ -1,6 +1,6 @@ // MIT License // -// Copyright (c) 2024 Remy Noulin +// Copyright (c) 2025 Remy Noulin // // Permission is hereby granted, free of charge, to any person obtaining a copy // of this software and associated documentation files (the "Software"), to deal diff --git a/src/json/libsheepyCSmallBytes.h b/src/json/libsheepyCSmallBytes.h @@ -1,6 +1,6 @@ // MIT License // -// Copyright (c) 2024 Remy Noulin +// Copyright (c) 2025 Remy Noulin // // Permission is hereby granted, free of charge, to any person obtaining a copy // of this software and associated documentation files (the "Software"), to deal diff --git a/src/json/libsheepyCSmallBytesInternal.h b/src/json/libsheepyCSmallBytesInternal.h @@ -1,6 +1,6 @@ // MIT License // -// Copyright (c) 2024 Remy Noulin +// Copyright (c) 2025 Remy Noulin // // Permission is hereby granted, free of charge, to any person obtaining a copy // of this software and associated documentation files (the "Software"), to deal diff --git a/src/json/libsheepyCSmallContainer.c b/src/json/libsheepyCSmallContainer.c @@ -1,6 +1,6 @@ // MIT License // -// Copyright (c) 2024 Remy Noulin +// Copyright (c) 2025 Remy Noulin // // Permission is hereby granted, free of charge, to any person obtaining a copy // of this software and associated documentation files (the "Software"), to deal diff --git a/src/json/libsheepyCSmallContainer.h b/src/json/libsheepyCSmallContainer.h @@ -1,6 +1,6 @@ // MIT License // -// Copyright (c) 2024 Remy Noulin +// Copyright (c) 2025 Remy Noulin // // Permission is hereby granted, free of charge, to any person obtaining a copy // of this software and associated documentation files (the "Software"), to deal diff --git a/src/json/libsheepyCSmallContainerInternal.h b/src/json/libsheepyCSmallContainerInternal.h @@ -1,6 +1,6 @@ // MIT License // -// Copyright (c) 2024 Remy Noulin +// Copyright (c) 2025 Remy Noulin // // Permission is hereby granted, free of charge, to any person obtaining a copy // of this software and associated documentation files (the "Software"), to deal diff --git a/src/json/libsheepyCSmallDict.c b/src/json/libsheepyCSmallDict.c @@ -1,6 +1,6 @@ // MIT License // -// Copyright (c) 2024 Remy Noulin +// Copyright (c) 2025 Remy Noulin // // Permission is hereby granted, free of charge, to any person obtaining a copy // of this software and associated documentation files (the "Software"), to deal diff --git a/src/json/libsheepyCSmallDict.h b/src/json/libsheepyCSmallDict.h @@ -1,6 +1,6 @@ // MIT License // -// Copyright (c) 2024 Remy Noulin +// Copyright (c) 2025 Remy Noulin // // Permission is hereby granted, free of charge, to any person obtaining a copy // of this software and associated documentation files (the "Software"), to deal diff --git a/src/json/libsheepyCSmallDictInternal.h b/src/json/libsheepyCSmallDictInternal.h @@ -1,6 +1,6 @@ // MIT License // -// Copyright (c) 2024 Remy Noulin +// Copyright (c) 2025 Remy Noulin // // Permission is hereby granted, free of charge, to any person obtaining a copy // of this software and associated documentation files (the "Software"), to deal diff --git a/src/json/libsheepyCSmallDouble.c b/src/json/libsheepyCSmallDouble.c @@ -1,6 +1,6 @@ // MIT License // -// Copyright (c) 2024 Remy Noulin +// Copyright (c) 2025 Remy Noulin // // Permission is hereby granted, free of charge, to any person obtaining a copy // of this software and associated documentation files (the "Software"), to deal diff --git a/src/json/libsheepyCSmallDouble.h b/src/json/libsheepyCSmallDouble.h @@ -1,6 +1,6 @@ // MIT License // -// Copyright (c) 2024 Remy Noulin +// Copyright (c) 2025 Remy Noulin // // Permission is hereby granted, free of charge, to any person obtaining a copy // of this software and associated documentation files (the "Software"), to deal diff --git a/src/json/libsheepyCSmallDoubleInternal.h b/src/json/libsheepyCSmallDoubleInternal.h @@ -1,6 +1,6 @@ // MIT License // -// Copyright (c) 2024 Remy Noulin +// Copyright (c) 2025 Remy Noulin // // Permission is hereby granted, free of charge, to any person obtaining a copy // of this software and associated documentation files (the "Software"), to deal diff --git a/src/json/libsheepyCSmallInt.c b/src/json/libsheepyCSmallInt.c @@ -1,6 +1,6 @@ // MIT License // -// Copyright (c) 2024 Remy Noulin +// Copyright (c) 2025 Remy Noulin // // Permission is hereby granted, free of charge, to any person obtaining a copy // of this software and associated documentation files (the "Software"), to deal diff --git a/src/json/libsheepyCSmallInt.h b/src/json/libsheepyCSmallInt.h @@ -1,6 +1,6 @@ // MIT License // -// Copyright (c) 2024 Remy Noulin +// Copyright (c) 2025 Remy Noulin // // Permission is hereby granted, free of charge, to any person obtaining a copy // of this software and associated documentation files (the "Software"), to deal diff --git a/src/json/libsheepyCSmallIntInternal.h b/src/json/libsheepyCSmallIntInternal.h @@ -1,6 +1,6 @@ // MIT License // -// Copyright (c) 2024 Remy Noulin +// Copyright (c) 2025 Remy Noulin // // Permission is hereby granted, free of charge, to any person obtaining a copy // of this software and associated documentation files (the "Software"), to deal diff --git a/src/json/libsheepyCSmallJson.c b/src/json/libsheepyCSmallJson.c @@ -1,6 +1,6 @@ // MIT License // -// Copyright (c) 2024 Remy Noulin +// Copyright (c) 2025 Remy Noulin // // Permission is hereby granted, free of charge, to any person obtaining a copy // of this software and associated documentation files (the "Software"), to deal diff --git a/src/json/libsheepyCSmallJson.h b/src/json/libsheepyCSmallJson.h @@ -1,6 +1,6 @@ // MIT License // -// Copyright (c) 2024 Remy Noulin +// Copyright (c) 2025 Remy Noulin // // Permission is hereby granted, free of charge, to any person obtaining a copy // of this software and associated documentation files (the "Software"), to deal diff --git a/src/json/libsheepyCSmallJsonInternal.h b/src/json/libsheepyCSmallJsonInternal.h @@ -1,6 +1,6 @@ // MIT License // -// Copyright (c) 2024 Remy Noulin +// Copyright (c) 2025 Remy Noulin // // Permission is hereby granted, free of charge, to any person obtaining a copy // of this software and associated documentation files (the "Software"), to deal diff --git a/src/json/libsheepyCSmallString.c b/src/json/libsheepyCSmallString.c @@ -1,6 +1,6 @@ // MIT License // -// Copyright (c) 2024 Remy Noulin +// Copyright (c) 2025 Remy Noulin // // Permission is hereby granted, free of charge, to any person obtaining a copy // of this software and associated documentation files (the "Software"), to deal diff --git a/src/json/libsheepyCSmallString.h b/src/json/libsheepyCSmallString.h @@ -1,6 +1,6 @@ // MIT License // -// Copyright (c) 2024 Remy Noulin +// Copyright (c) 2025 Remy Noulin // // Permission is hereby granted, free of charge, to any person obtaining a copy // of this software and associated documentation files (the "Software"), to deal diff --git a/src/json/libsheepyCSmallStringInternal.h b/src/json/libsheepyCSmallStringInternal.h @@ -1,6 +1,6 @@ // MIT License // -// Copyright (c) 2024 Remy Noulin +// Copyright (c) 2025 Remy Noulin // // Permission is hereby granted, free of charge, to any person obtaining a copy // of this software and associated documentation files (the "Software"), to deal diff --git a/src/json/libsheepyCUndefined.c b/src/json/libsheepyCUndefined.c @@ -1,6 +1,6 @@ // MIT License // -// Copyright (c) 2024 Remy Noulin +// Copyright (c) 2025 Remy Noulin // // Permission is hereby granted, free of charge, to any person obtaining a copy // of this software and associated documentation files (the "Software"), to deal diff --git a/src/json/libsheepyCUndefined.h b/src/json/libsheepyCUndefined.h @@ -1,6 +1,6 @@ // MIT License // -// Copyright (c) 2024 Remy Noulin +// Copyright (c) 2025 Remy Noulin // // Permission is hereby granted, free of charge, to any person obtaining a copy // of this software and associated documentation files (the "Software"), to deal diff --git a/src/json/libsheepyCUndefinedInternal.h b/src/json/libsheepyCUndefinedInternal.h @@ -1,6 +1,6 @@ // MIT License // -// Copyright (c) 2024 Remy Noulin +// Copyright (c) 2025 Remy Noulin // // Permission is hereby granted, free of charge, to any person obtaining a copy // of this software and associated documentation files (the "Software"), to deal diff --git a/src/json/libsheepyObject.c b/src/json/libsheepyObject.c @@ -1,6 +1,6 @@ // MIT License // -// Copyright (c) 2024 Remy Noulin +// Copyright (c) 2025 Remy Noulin // // Permission is hereby granted, free of charge, to any person obtaining a copy // of this software and associated documentation files (the "Software"), to deal diff --git a/src/json/recycleContainers.h b/src/json/recycleContainers.h @@ -1,6 +1,6 @@ // MIT License // -// Copyright (c) 2024 Remy Noulin +// Copyright (c) 2025 Remy Noulin // // Permission is hereby granted, free of charge, to any person obtaining a copy // of this software and associated documentation files (the "Software"), to deal diff --git a/src/libsheepy.c b/src/libsheepy.c @@ -2,7 +2,7 @@ // // MIT License // -// Copyright (c) 2024 Remy Noulin +// Copyright (c) 2025 Remy Noulin // // Permission is hereby granted, free of charge, to any person obtaining a copy // of this software and associated documentation files (the "Software"), to deal @@ -9678,8 +9678,8 @@ char *stripColorsS(const char *string) { return(NULL); } - size_t len = strlen(string)+1; - r = MALLOC(len); + size_t len = strlen(string); + r = MALLOC(len+1); if (!r) { return(NULL); } diff --git a/src/libsheepy.h b/src/libsheepy.h @@ -1,6 +1,6 @@ // MIT License // -// Copyright (c) 2024 Remy Noulin +// Copyright (c) 2025 Remy Noulin // // Permission is hereby granted, free of charge, to any person obtaining a copy // of this software and associated documentation files (the "Software"), to deal @@ -98,7 +98,7 @@ // version accoring to the version package: Release.Major.minor.patch // https://noulin.net/version/file/README.md.html -#define LIBSHEEPY_VERSION "2.2.16" +#define LIBSHEEPY_VERSION "2.2.16.1" #ifndef SH_PREFIX #define SH_PREFIX(NAME) NAME diff --git a/src/libsheepyObject.h b/src/libsheepyObject.h @@ -1,6 +1,6 @@ // MIT License // -// Copyright (c) 2024 Remy Noulin +// Copyright (c) 2025 Remy Noulin // // Permission is hereby granted, free of charge, to any person obtaining a copy // of this software and associated documentation files (the "Software"), to deal diff --git a/src/libsheepySmall.c b/src/libsheepySmall.c @@ -1,6 +1,6 @@ // MIT License // -// Copyright (c) 2024 Remy Noulin +// Copyright (c) 2025 Remy Noulin // // Permission is hereby granted, free of charge, to any person obtaining a copy // of this software and associated documentation files (the "Software"), to deal diff --git a/src/libsheepySmall.h b/src/libsheepySmall.h @@ -1,6 +1,6 @@ // MIT License // -// Copyright (c) 2024 Remy Noulin +// Copyright (c) 2025 Remy Noulin // // Permission is hereby granted, free of charge, to any person obtaining a copy // of this software and associated documentation files (the "Software"), to deal