As uncovered in #132, there is currently a bug when it comes to the CoAP Ping example, introduced by #127. After doing some research, I noticed that this is caused by an incorrect handling of empty message tokens, which are currently identified as invalid. This PR applies a simple fix by returning an empty buffer if a token length of zero should be encountered, resolving not only the ping issue but also other unintended side effects.
As uncovered in #132, there is currently a bug when it comes to the CoAP Ping example, introduced by #127. After doing some research, I noticed that this is caused by an incorrect handling of empty message tokens, which are currently identified as invalid. This PR applies a simple fix by returning an empty buffer if a token length of zero should be encountered, resolving not only the ping issue but also other unintended side effects.