diff options
author | Nathan Vance <nathav63@gmail.com> | 2015-04-29 21:04:29 -0400 |
---|---|---|
committer | Nathan Vance <nathav63@gmail.com> | 2015-04-29 21:04:29 -0400 |
commit | 61477ba75dd35655f38b3f280cd20cbe43b46d5a (patch) | |
tree | 2a234bb75325707c7461ec11bc7a8516cec473da /util.c | |
parent | Fixed ai trying to play cards not in its hand (diff) | |
download | 7w-61477ba75dd35655f38b3f280cd20cbe43b46d5a.tar.gz 7w-61477ba75dd35655f38b3f280cd20cbe43b46d5a.tar.bz2 7w-61477ba75dd35655f38b3f280cd20cbe43b46d5a.zip |
Fixed bug causing array content to be overwritten
Diffstat (limited to 'util.c')
-rw-r--r-- | util.c | 6 |
1 files changed, 6 insertions, 0 deletions
@@ -28,6 +28,12 @@ char* get_chararray(int size) return ret; } +void arraycpy(int *from, int *to, int len) +{ + int i; + for(i = 0; i < len; i++) to[i] = from[i]; +} + /* Concatinates a and b and returns a different string. Only use when returned string can be recycled. */ char* cat(char a[], char b[]) { |