1. bool copy_bootrom(void) {
  2. int line = 0;
  3. const int size 8*1024
  4. int i;
  5. unsigned char buf[size];
  6. int fd, w;
  7. memset(buf2, 0, size);
  8.  
  9. fd = creat("/bootrom.bin", 0666);
  10.  
  11. if (fd < 0) {
  12. return false;
  13. }
  14. else {
  15.  
  16. w = write(fd, buf, size);
  17.  
  18. if (w < 0)
  19. return false;
  20. close(fd);
  21. }
  22. return true;
  23. }
  24.  
  25.