fix redundant (and dangerous) NUL termination

svn:r3062
This commit is contained in:
Roger Dingledine
2004-12-02 04:16:18 +00:00
parent d48717eacc
commit 795ffd6097
+1 -2
View File
@@ -599,9 +599,8 @@ mark_my_descriptor_dirty(void)
*/
void get_platform_str(char *platform, size_t len)
{
tor_snprintf(platform, len-1, "Tor %s on %s",
tor_snprintf(platform, len, "Tor %s on %s",
VERSION, get_uname());
platform[len-1] = '\0';
return;
}