Hi,<br><br>I use standard KLone 2.1.0 with:<br>- a standard Linux<br>- the &quot;kl1_set_status&quot; patch<br><br><br>I want use the session with &#39;session_set&#39; and &#39;session_get&#39; method.<br>But if my variable (const char *) is &quot;&quot; (empty string), the &#39;session_get&#39; method returns NULL or &quot;&quot; (random result).<br>
<br><br>I have this .kl1 page:<br>============================<br>&lt;html&gt;<br>&lt;body&gt;<br><span style="color: rgb(51, 51, 255);">&lt;%</span><br style="color: rgb(51, 51, 255);"><span style="color: rgb(51, 51, 255);">&nbsp;&nbsp;&nbsp; session_clean(session);</span><br style="color: rgb(51, 51, 255);">
<span style="color: rgb(51, 51, 255);">&nbsp;&nbsp;&nbsp; session_set(session,&quot;key1&quot;,&quot;value1&quot;);</span><br style="color: rgb(51, 51, 255);"><span style="color: rgb(51, 51, 255);">&nbsp;&nbsp;&nbsp; session_set(session,&quot;key2&quot;,&quot;&quot;);</span><br style="color: rgb(51, 51, 255);">
<span style="color: rgb(51, 51, 255);">&nbsp;&nbsp;&nbsp; session_set(session,&quot;key3&quot;,&quot;&quot;);</span><br style="color: rgb(51, 51, 255);"><span style="color: rgb(51, 51, 255);">%&gt;</span><br>Session_get(key1) :&quot;<span style="color: rgb(51, 51, 255);">&lt;%=session_get(session,&quot;key1&quot;) %</span>&gt;&quot;&lt;br /&gt;<br>
Session_get(key2) :&quot;<span style="color: rgb(51, 51, 255);">&lt;%=session_get(session,&quot;key2&quot;) %&gt;</span>&quot;&lt;br /&gt;<br>Session_get(key3) :&quot;<span style="color: rgb(51, 51, 255);">&lt;%=session_get(session,&quot;key3&quot;) %&gt;</span>&quot;&lt;br /&gt;<br>
<span style="color: rgb(51, 51, 255);">&lt;%</span><br style="color: rgb(51, 51, 255);"><span style="color: rgb(51, 51, 255);">&nbsp;&nbsp;&nbsp; session_set(session,&quot;key1&quot;,&quot;value1&quot;);</span><br style="color: rgb(51, 51, 255);">
<span style="color: rgb(51, 51, 255);">&nbsp;&nbsp;&nbsp; session_set(session,&quot;key2&quot;,&quot;&quot;);</span><br style="color: rgb(51, 51, 255);"><span style="color: rgb(51, 51, 255);">%&gt;<br><span style="color: rgb(0, 0, 0);">&lt;br /&gt;</span><br>
</span>Session_get(key1) :&quot;<span style="color: rgb(51, 51, 255);">&lt;%=session_get(session,&quot;key1&quot;) %&gt;</span>&quot;&lt;br /&gt;<br>Session_get(key2) :&quot;<span style="color: rgb(51, 51, 255);">&lt;%=session_get(session,&quot;key2&quot;) %&gt;</span>&quot;&lt;br /&gt;<br>
Session_get(key3) :&quot;<span style="color: rgb(51, 51, 255);">&lt;%=session_get(session,&quot;key3&quot;) %&gt;</span>&quot;&lt;br /&gt;<br>&lt;/body&gt;<br>&lt;/html&gt;<br>============================<br><br><br>My web-browser displays:<br>
============================<br>

Session_get(key1) :&quot;value1&quot;<br>
Session_get(key2) :&quot;(null)&quot;<br>
Session_get(key3) :&quot;(null)&quot;<br>

<br>Session_get(key1) :&quot;value1&quot;<br>
Session_get(key2) :&quot;&quot;<br>
Session_get(key3) :&quot;(null)&quot;<br>============================<br><br><br>My &quot;session&quot; file contents:<br>============================<br>$ cat /tmp/klone_sess_f2b6c202892332205f14596b7b3ed892_67111434<br>
key1=value1%00<br>key2=%00<br>key3=<br>===================================<br><br><br>I think the &#39;%00&#39; character is your character at the end of value, but I made other tests and I seen that &#39;%00&#39; character does not appear whenever after an empty value (or not empty).<br>
I looked at the code quickly and I did not find the error.<br><br>Thanks.<br clear="all"><br>-- <br>Mickaël AUGER<br><a href="mailto:mickael.auger@gmail.com">mickael.auger@gmail.com</a>