ref: dfdc52ea7ad0b5950a08d80052dbc667eec3a803
parent: bf74dfbc7ae39b0e7aee35bad63fb219f49e88cb
author: cinap_lenrek <cinap_lenrek@felloff.net>
date: Sun May 17 03:02:44 EDT 2015
libc: use Runemax instead of hardcoded 0x65536 for fmtchar check (thanks qrstuv)
--- a/sys/src/ape/lib/fmt/fmt.c
+++ b/sys/src/ape/lib/fmt/fmt.c
@@ -80,7 +80,7 @@
{
Convfmt *p, *ep;
- if(c<=0 || c>=65536)
+ if(c<=0 || c>Runemax)
return -1;
if(!f)
f = __badfmt;
--- a/sys/src/libc/fmt/fmt.c
+++ b/sys/src/libc/fmt/fmt.c
@@ -61,7 +61,7 @@
{
Convfmt *p, *ep;
- if(c<=0 || c>=65536)
+ if(c<=0 || c>Runemax)
return -1;
if(!f)
f = _badfmt;