diff -u -r mp3fs-0.13/src/class.h mp3fs-0.13.org/src/class.h
old
|
new
|
|
171 | 171 | |
172 | 172 | #define CLASS(class,super_class) \ |
173 | 173 | typedef struct class *class; \ |
174 | | /*inline*/ void class ## _init(void); \ |
| 174 | inline void class ## _init(void); \ |
175 | 175 | void class ## _Alloc(class this); \ |
176 | 176 | extern int __ ## class ## _initialised; \ |
177 | 177 | extern struct class __ ## class; \ |
… |
… |
|
209 | 209 | |
210 | 210 | #define VIRTUAL(class,superclass) \ |
211 | 211 | struct class __ ## class; \ |
212 | | /*inline*/ void class ## _init(void) { \ |
| 212 | inline void class ## _init(void) { \ |
213 | 213 | if(!__ ## class ## _initialised) { \ |
214 | 214 | class ## _Alloc(&__ ## class); \ |
215 | 215 | __ ## class ## _initialised = 1; \ |
… |
… |
|
233 | 233 | |
234 | 234 | #define VIRTUAL(class,superclass) \ |
235 | 235 | struct class __ ## class; \ |
236 | | /*inline*/ void class ## _init(void) { \ |
| 236 | inline void class ## _init(void) { \ |
237 | 237 | if(!__ ## class ## _initialised) { \ |
238 | 238 | class ## _Alloc(&__ ## class); \ |
239 | 239 | __ ## class ## _initialised = 1; \ |
… |
… |
|
348 | 348 | #define GET_CLASS(name) \ |
349 | 349 | &__ ## name |
350 | 350 | |
351 | | /*inline*/ void Object_init(void); |
352 | | /*inline*/ void Object_Alloc(Object this); |
| 351 | inline void Object_init(void); |
| 352 | inline void Object_Alloc(Object this); |
353 | 353 | |
354 | 354 | extern struct Object __Object; |
355 | 355 | |
diff -u -r mp3fs-0.13/src/mp3fs.c mp3fs-0.13.org/src/mp3fs.c
old
|
new
|
|
20 | 20 | Foundation, Inc., 675 Mass Ave, Cambridge, MA 02139, USA. |
21 | 21 | */ |
22 | 22 | |
23 | | #define FUSE_USE_VERSION 26 |
| 23 | #define FUSE_USE_VERSION 22 |
24 | 24 | |
25 | 25 | #include <fuse.h> |
26 | 26 | #include <stdio.h> |
… |
… |
|
30 | 30 | #include <fcntl.h> |
31 | 31 | #include <dirent.h> |
32 | 32 | #include <errno.h> |
33 | | /*#include <sys/statfs.h>*/ |
| 33 | #include <sys/statfs.h> |
34 | 34 | |
35 | 35 | #include "transcode.h" |
36 | 36 | #include "talloc.h" |
… |
… |
|
56 | 56 | off_t offset, struct fuse_file_info *fi) { |
57 | 57 | DIR *dp; |
58 | 58 | struct dirent *de; |
59 | | char name[256]; /* *ptr; */ |
| 59 | char name[256], *ptr; |
60 | 60 | |
61 | 61 | DEBUG(logfd, "%s: readdir\n", path); |
62 | 62 | |
… |
… |
|
90 | 90 | } |
91 | 91 | |
92 | 92 | static int mp3fs_getattr(const char *path, struct stat *stbuf) { |
93 | | /* int res; */ |
| 93 | int res; |
94 | 94 | FileTranscoder f; |
95 | 95 | char name[256]; |
96 | 96 | int hold_errno; |
… |
… |
|
161 | 161 | static int mp3fs_read(const char *path, char *buf, size_t size, off_t offset, |
162 | 162 | struct fuse_file_info *fi) { |
163 | 163 | int fd, res; |
164 | | /* struct stat st; */ |
| 164 | struct stat st; |
165 | 165 | FileTranscoder f=NULL; |
166 | 166 | char name[256]; |
167 | 167 | |
… |
… |
|
195 | 195 | return f->Read(f, buf, offset, size); |
196 | 196 | } |
197 | 197 | |
198 | | static int mp3fs_statfs(const char *path, struct statvfs *stbuf) { |
| 198 | static int mp3fs_statfs(const char *path, struct statfs *stbuf) { |
199 | 199 | int res; |
200 | 200 | char name[256]; |
201 | 201 | |
… |
… |
|
204 | 204 | strncpy(name, basepath, sizeof(name)); |
205 | 205 | strncat(name, path, sizeof(name) - strlen(name)); |
206 | 206 | |
207 | | res = statvfs(name, stbuf); |
| 207 | res = statfs(name, stbuf); |
208 | 208 | if(res == -1) |
209 | 209 | return -errno; |
210 | 210 | |
… |
… |
|
269 | 269 | #endif |
270 | 270 | |
271 | 271 | // start FUSE |
272 | | fuse_main(argc-1, argv+1, &mp3fs_ops, NULL); |
| 272 | fuse_main(argc-1, argv+1, &mp3fs_ops); |
273 | 273 | |
274 | 274 | #ifdef __DEBUG__ |
275 | 275 | fclose(logfd); |
diff -u -r mp3fs-0.13/src/transcode.c mp3fs-0.13.org/src/transcode.c
old
|
new
|
|
24 | 24 | #include <fcntl.h> |
25 | 25 | #include <dirent.h> |
26 | 26 | #include <errno.h> |
27 | | /*#include <sys/statfs.h>*/ |
| 27 | #include <sys/statfs.h> |
28 | 28 | |
29 | 29 | #include <FLAC/metadata.h> |
30 | 30 | #ifdef LEGACY_FLAC |
… |
… |
|
159 | 159 | void *client_data) |
160 | 160 | #endif |
161 | 161 | { |
162 | | int len, i/*, count*/; |
| 162 | int len, i, count; |
163 | 163 | FileTranscoder trans = (FileTranscoder)client_data; |
164 | 164 | |
165 | 165 | if(frame->header.blocksize < 1152) { |