Publishing nanopb-0.4.1
diff --git a/CHANGELOG.txt b/CHANGELOG.txt
index 3561325..e70aa2c 100644
--- a/CHANGELOG.txt
+++ b/CHANGELOG.txt
@@ -1,3 +1,25 @@
+nanopb-0.4.1 (2019-02-02)
+ Fix invalid free() after failed realloc() (GHSA-gcx3-7m76-287p)
+ Avoid overflows in allocation for packed fields.
+ Verify stream size before allocating string / bytes.
+ Add workaround for avr-libc realloc() bug (#475)
+ Fix bug with field numbers >255 (#407)
+ Fix compilation error on platforms without uint8_t (#485)
+ Fix warnings on Python3.8 (#399, #467)
+ Make fixed_count option work when combined with FT_POINTER.
+ Add missing #define for submsg callbacks, add regression test (#472)
+ Fix ImportError when using generator/protoc with Python 3
+ Remove accidental debug code in generator
+ Reduce stack usage (#484)
+ Remove PB_FIELDINFO_WIDTH option (#473)
+ Add nanopb-specific package name option (#422)
+ Add testcase for Any type (#163)
+ Add exclude option also from .proto/.options
+ Set default include path in the grpc_tools protoc wrapper.
+ Add workaround for python-protobuf 3.6.1 bug (#478)
+ Detect invalid wire type when decoding fields.
+ Improved fuzz testing
+
 nanopb-0.4.0 (2019-12-20)
  New field descriptor format.
  Make nanopb_generator automatically compile .proto files (#462)
@@ -37,6 +59,12 @@
  CMake: Split nanopb_out command (#454)
  CMake: install created shared library(dll) in windows to the binary folder (#447)
 
+nanopb-0.3.9.5 (2020-02-02)
+ Fix invalid free() after failed realloc() (GHSA-gcx3-7m76-287p)
+ Add workaround for avr-libc realloc() bug (#475)
+ Fix empty submessages getting encoded in proto3 mode (#395)
+ Avoid overflows in allocation for packed fields.
+
 nanopb-0.3.9.4 (2019-10-13)
  Fix undefined behavior with bool fields (#434)
  Fix enum min/max defines when values are not in order (#405)
@@ -202,6 +230,22 @@
  Added #if version guard to generated files (issue 129)
  Added migration document
 
+nanopb-0.2.9.4 (2020-02-02)
+ Fix invalid free() after failed realloc() (GHSA-gcx3-7m76-287p)
+ Add workaround for avr-libc realloc() bug (#475)
+
+nanopb-0.2.9.3 (2016-06-19)
+ Protect against corrupted _count fields in pb_release (#205)
+
+nanopb-0.2.9.2 (2015-01-24)
+ Fix memory leaks with PB_ENABLE_MALLOC with some submessage hierarchies (issue 138)
+ Fix compilation error with generated initializers for repeated pointer fields
+
+nanopb-0.2.9.1 (2014-09-11)
+ Fix security issue due to size_t overflows. (issue 132)
+ Fix memory leak with duplicated fields and PB_ENABLE_MALLOC
+ Fix crash if pb_release() is called twice.
+
 nanopb-0.2.9 (2014-08-09)
  NOTE: If you are using the -e option with the generator, you have
  to prepend . to the argument to get the same behaviour as before.
diff --git a/CMakeLists.txt b/CMakeLists.txt
index 56a0173..dbfa9a1 100644
--- a/CMakeLists.txt
+++ b/CMakeLists.txt
@@ -2,7 +2,7 @@
 
 project(nanopb C)
 
-set(nanopb_VERSION_STRING 0.4.1-dev)
+set(nanopb_VERSION_STRING nanopb-0.4.1)
 set(nanopb_SOVERSION 0)
 
 string(REPLACE "nanopb-" "" nanopb_VERSION ${nanopb_VERSION_STRING})
diff --git a/conanfile.py b/conanfile.py
index bb77e6d..c2bfb93 100644
--- a/conanfile.py
+++ b/conanfile.py
@@ -3,7 +3,7 @@
 
 class NanoPbConan(ConanFile):
     name = "nanopb"
-    version = "0.4.1-dev"
+    version = "0.4.1"
     license = "zlib"
     url = "https://jpa.kapsi.fi/nanopb/"
     description = "Protocol Buffers with small code size"
diff --git a/extra/poetry/pyproject.toml b/extra/poetry/pyproject.toml
index 152e67d..a312787 100644
--- a/extra/poetry/pyproject.toml
+++ b/extra/poetry/pyproject.toml
@@ -1,6 +1,6 @@
 [tool.poetry]
 name = "nanopb"
-version = "0.4.1-dev"
+version = "0.4.1"
 description = "Nanopb is a small code-size Protocol Buffers implementation in ansi C. It is especially suitable for use in microcontrollers, but fits any memory restricted system."
 authors = ["Petteri Aimonen <jpa@npb.mail.kapsi.fi>"]
 license = "Zlib"
diff --git a/generator/nanopb_generator.py b/generator/nanopb_generator.py
index d227863..274988c 100755
--- a/generator/nanopb_generator.py
+++ b/generator/nanopb_generator.py
@@ -4,7 +4,7 @@
 from __future__ import unicode_literals
 
 '''Generate header file for nanopb from a ProtoBuf FileDescriptorSet.'''
-nanopb_version = "0.4.1-dev"
+nanopb_version = "nanopb-0.4.1"
 
 import sys
 import re
diff --git a/library.json b/library.json
index 1640503..f447490 100644
--- a/library.json
+++ b/library.json
@@ -1,6 +1,6 @@
 {
   "name": "Nanopb",
-  "version": "0.4.0",
+  "version": "0.4.1",
   "keywords": "protocol buffers, protobuf, google",
   "description": "Nanopb is a plain-C implementation of Google's Protocol Buffers data format. It is targeted at 32 bit microcontrollers, but is also fit for other embedded systems with tight (<10 kB ROM, <1 kB RAM) memory constraints.",
   "repository": {
diff --git a/pb.h b/pb.h
index fea0872..8e87b62 100644
--- a/pb.h
+++ b/pb.h
@@ -55,7 +55,7 @@
 
 /* Version of the nanopb library. Just in case you want to check it in
  * your own program. */
-#define NANOPB_VERSION 0.4.1-dev
+#define NANOPB_VERSION nanopb-0.4.1
 
 /* Include all the system headers needed by nanopb. You will need the
  * definitions of the following: