mirror of
https://github.com/owntone/owntone-server.git
synced 2024-12-24 22:25:56 -05:00
More linux fixes
This commit is contained in:
parent
2c029ddd15
commit
1b5e2ca2c4
@ -77,7 +77,7 @@ void daap_handler(WS_CONNINFO *pwsc) {
|
||||
int file_fd;
|
||||
int session_id=0;
|
||||
|
||||
off_t offset;
|
||||
off_t offset=0;
|
||||
off_t file_len;
|
||||
|
||||
close=pwsc->close;
|
||||
@ -85,7 +85,7 @@ void daap_handler(WS_CONNINFO *pwsc) {
|
||||
root=NULL;
|
||||
|
||||
ws_addresponseheader(pwsc,"Accept-Ranges","bytes");
|
||||
ws_addresponseheader(pwsc,"DAAP-Server","iTunes/4.1 (Mac OS X)");
|
||||
ws_addresponseheader(pwsc,"DAAP-Server","mt-daapd/%s",VERSION);
|
||||
ws_addresponseheader(pwsc,"Content-Type","application/x-dmap-tagged");
|
||||
|
||||
if(ws_getvar(pwsc,"session-id")) {
|
||||
@ -239,6 +239,8 @@ void daap_handler(WS_CONNINFO *pwsc) {
|
||||
ws_emitheaders(pwsc);
|
||||
|
||||
config_set_status(pwsc,session_id,"Streaming file '%s'",pmp3->fname);
|
||||
DPRINTF(ERR_INFO,"Streaming %s\n",pmp3->fname);
|
||||
|
||||
if(offset) {
|
||||
lseek(file_fd,offset,SEEK_SET);
|
||||
}
|
||||
|
@ -375,7 +375,7 @@ int scan_gettags(char *file, MP3FILE *pmp3) {
|
||||
used=1;
|
||||
pmp3->genre = utf8_text;
|
||||
DPRINTF(ERR_DEBUG," Genre: %s\n",utf8_text);
|
||||
if(isdigit(pmp3->genre[0])) {
|
||||
if((pmp3->genre) && (isdigit(pmp3->genre[0]))) {
|
||||
genre=atoi(pmp3->genre);
|
||||
free(pmp3->genre);
|
||||
pmp3->genre=strdup(scan_winamp_genre[genre]);
|
||||
|
Loading…
Reference in New Issue
Block a user