Mercurial > audlegacy-plugins
comparison src/cue/cuesheet.c @ 1978:fa9f85cebade
s/vfs_/aud_vfs_/g
author | William Pitcock <nenolod@atheme.org> |
---|---|
date | Sun, 07 Oct 2007 00:25:33 -0500 |
parents | 5fa26178eaef |
children | 489e32a8e106 |
comparison
equal
deleted
inserted
replaced
1977:5a6b60ceaa0f | 1978:fa9f85cebade |
---|---|
456 track = atoi(_path); | 456 track = atoi(_path); |
457 } | 457 } |
458 cur_cue_track = track; | 458 cur_cue_track = track; |
459 cache_cue_file(path2); //path2 should be uri. | 459 cache_cue_file(path2); //path2 should be uri. |
460 | 460 |
461 if (cue_file == NULL || !vfs_file_test(cue_file, G_FILE_TEST_EXISTS)) | 461 if (cue_file == NULL || !aud_vfs_file_test(cue_file, G_FILE_TEST_EXISTS)) |
462 return; | 462 return; |
463 | 463 |
464 pr = input_check_file(cue_file, FALSE); | 464 pr = input_check_file(cue_file, FALSE); |
465 if (pr == NULL) | 465 if (pr == NULL) |
466 return; | 466 return; |
747 last_cue_track = 0; | 747 last_cue_track = 0; |
748 } | 748 } |
749 | 749 |
750 static void cache_cue_file(char *f) | 750 static void cache_cue_file(char *f) |
751 { | 751 { |
752 VFSFile *file = vfs_fopen(f, "rb"); | 752 VFSFile *file = aud_vfs_fopen(f, "rb"); |
753 gchar line[MAX_CUE_LINE_LENGTH+1]; | 753 gchar line[MAX_CUE_LINE_LENGTH+1]; |
754 | 754 |
755 if(!file) | 755 if(!file) |
756 return; | 756 return; |
757 | 757 |
758 while (TRUE) { | 758 while (TRUE) { |
759 gint p; | 759 gint p; |
760 gint q; | 760 gint q; |
761 | 761 |
762 if (vfs_fgets(line, MAX_CUE_LINE_LENGTH+1, file) == NULL) { | 762 if (aud_vfs_fgets(line, MAX_CUE_LINE_LENGTH+1, file) == NULL) { |
763 vfs_fclose(file); | 763 aud_vfs_fclose(file); |
764 return; | 764 return; |
765 } | 765 } |
766 | 766 |
767 for (p = 0; line[p] && isspace((int) line[p]); p++); | 767 for (p = 0; line[p] && isspace((int) line[p]); p++); |
768 if (!line[p]) | 768 if (!line[p]) |
845 cue_tracks[last_cue_track-1].index = min * 60000 + sec * 1000 + frac * 10; | 845 cue_tracks[last_cue_track-1].index = min * 60000 + sec * 1000 + frac * 10; |
846 } | 846 } |
847 } | 847 } |
848 } | 848 } |
849 | 849 |
850 vfs_fclose(file); | 850 aud_vfs_fclose(file); |
851 } | 851 } |
852 | 852 |
853 static void fix_cue_argument(char *line) | 853 static void fix_cue_argument(char *line) |
854 { | 854 { |
855 if (line[0] == '"') { | 855 if (line[0] == '"') { |