Guest User

Untitled

a guest
Mar 4th, 2015
7
0
Never
Not a member of Pastebin yet? Sign Up, it unlocks many cool features!
C 0.43 KB | None | 0 0
  1. typedef struct rom_file {
  2.     char fname[16];
  3.     uint16_t fstart;
  4.     uint16_t fsize;
  5. } rom_file_t;
  6.  
  7. rom_file_t files[ROMDRV_MAX_FILE_COUNT];
  8. uint8_t file_count = 0;
  9.    
  10.    
  11.     uint16_t fnum;
  12.     for (fnum = 0; fnum < file_count; fnum++) {
  13.         if ((files[fnum].fname[0] != 0) && (strcmp((char*)&(files[fnum].fname), path) == 0)) {
  14.             break;
  15.         }
  16.     }
  17.    
  18.     if (fnum == file_count) {
  19.         //debug_puts("ROM FS: File not found!\r\n");
  20.         return NULL;
  21.     }
Advertisement
Add Comment
Please, Sign In to add comment