Changeset c594489 in mainline for tetris/tetris.c
- Timestamp:
- 2006-05-31T18:54:25Z (19 years ago)
- Branches:
- lfn, master, serial, ticket/834-toolchain-update, topic/msim-upgrade, topic/simplify-dev-export
- Children:
- ad123964
- Parents:
- 1c20e22
- File:
-
- 1 edited
Legend:
- Unmodified
- Added
- Removed
-
tetris/tetris.c
r1c20e22 rc594489 46 46 */ 47 47 48 #include <sys/param.h>48 //#include <sys/param.h> 49 49 #include <sys/time.h> 50 50 #include <sys/types.h> … … 152 152 return (tmp); 153 153 } 154 154 155 static void srandomdev(void) 156 { 157 struct timeval tv; 158 159 gettimeofday(&tv, NULL); 160 srandom(tv.tv_sec + tv.tv_usec / 100000); 161 } 155 162 156 163 int … … 217 224 } 218 225 if (keys[i] == ' ') 219 str lcpy(key_write[i], "<space>", sizeof key_write[i]);226 strncpy(key_write[i], "<space>", sizeof key_write[i]); 220 227 else { 221 228 key_write[i][0] = keys[i]; … … 292 299 scr_msg(key_msg, 0); 293 300 scr_msg(msg, 1); 294 (void) fflush(stdout);301 // (void) fflush(stdout); 295 302 } while (rwait((struct timeval *)NULL) == -1); 296 303 scr_msg(msg, 0);
Note:
See TracChangeset
for help on using the changeset viewer.