void yaffs_callback(char* filename) { char* justfile = basename(filename); if (strlen(justfile) < 30) ui_print(justfile); yaffs_files_count++; if (yaffs_files_total != 0) ui_set_progress((float)yaffs_files_count / (float)yaffs_files_total); ui_reset_text_col(); }
static void yaffs_callback(const char* filename) { if (filename == NULL) return; const char* justfile = basename(filename); char tmp[PATH_MAX]; strcpy(tmp, justfile); if (tmp[strlen(tmp) - 1] == '\n') tmp[strlen(tmp) - 1] = NULL; if (strlen(tmp) < 30) ui_print("%s", tmp); yaffs_files_count++; if (yaffs_files_total != 0) ui_set_progress((float)yaffs_files_count / (float)yaffs_files_total); ui_reset_text_col(); }