Eric House
352d87a327
use stream to take apart untrusted message safely
...
add new stream getters that return false if reach EOS and use them to
exit early and safely if incoming SMS msg is misformatted. I'm getting
random garbage meant for other apps perhaps.
2018-07-13 22:41:52 -07:00
Eric House
ebcae1a523
move hashing into memstream impl, and reintroduce the old/broken
...
treatment of the final 8 bits. I'll need to release a version that
still produces the incorrect hash for compatibility with existing
clients that expect it, but that also looks for the correct hash. When
that's out there I can do a new release that sends the correct hash.
2016-01-01 17:57:14 -08:00
Eric House
1346aa6ee5
as proof of concept, skip the first 3 tiles when sorting newly
...
assigned. Later '3' will be replaced by the location of the tray
divider, but that has to be moved from board to model first.
2014-09-29 20:04:54 -07:00
Eric House
318cc52f5a
we need the base64 stuff even when don't have SMS -- for serialization.
2012-07-07 11:05:45 -07:00
Eric House
5104ca6bc5
always sort tiles prior to including in hash -- as a fix for the case
...
where a game is opened that was created by an earlier version that
didn't save assigned tiles in sorted order.
2012-05-05 17:33:07 -07:00
Andy2
c952ebd8e6
cleanup
2011-09-30 06:29:14 -07:00
Andy2
4a12f7a96f
Revert "in attempt to work around non-random rand() in jni world, call back"
...
This reverts commit 99c92e779d
.
Conflicts:
xwords4/android/XWords4/jni/utilwrapper.c
2010-12-07 18:43:53 -08:00
Andy2
99c92e779d
in attempt to work around non-random rand() in jni world, call back
...
into the java world by making it a util_ctxt function. Do same on
linux to test. We'll see how it is -- and can back this commit out if
there's no improvement.
2010-12-02 19:02:36 -08:00
ehouse
ac1a88f603
Add __func__ to what's tracked for allocation in debug builds
2009-01-18 16:37:44 +00:00
ehouse
abeb5376c0
Implement, with help from glib base64 source, routines to turn binary
...
into SMS-compatible strings and back. This should ensure that the
format is cross-platform.
2009-01-05 02:08:55 +00:00
ehouse
f749fdd560
Remove all tabs. No code changes.
2008-05-31 03:26:16 +00:00
ehouse
aad182c2e3
turn stringFromStream into macro to aid logging for leak detection. Debug builds only effected.
2007-03-18 23:31:51 +00:00
ehouse
edd48174a3
Add more consts.
2006-09-24 15:28:15 +00:00
ehouse
d7a2fadd39
modify MEM_DEBUG versions of strdup utils to record the __FILE__ and
...
__LINE__ of callers rather than their own to assist in leak detection.
2006-09-15 07:30:00 +00:00
ehouse
406d746fbf
add LOG_HEX
2006-08-26 20:28:48 +00:00
ehouse
af2eb79a4e
make some ptrs const
2006-08-09 04:48:34 +00:00
ehouse
7614d971c1
randIntArray runs once and returns whether array is modified. Tray calls
...
again until it is. newgame calls once: it's possible that juggling won't
do anything. Still pending: do we tell users when nothing changed, or
leave them to figure out that it's not a bug?
2006-06-27 06:30:44 +00:00
ehouse
f60dade9a0
move randIntArray to strutils, and use instead of similar code to juggle tiles in tray.
2006-06-16 01:19:11 +00:00
ehouse
9b6562e455
make a param const
2006-06-07 01:26:55 +00:00
ehouse
92485783af
update email address in header comments: no code change
2006-01-08 01:25:02 +00:00
ehouse
06e28770d1
make one formal param const
2005-05-29 19:31:09 +00:00
ehouse
af8602f63b
add stringFromStreamHere()
2005-03-19 21:44:09 +00:00
ehouse
5776da0b93
first checkin
2003-11-01 05:35:29 +00:00