Lines 840-846
Link Here
|
840 |
inbuffer[index] = inchar; |
840 |
inbuffer[index] = inchar; |
841 |
} |
841 |
} |
842 |
|
842 |
|
843 |
fprintf(stdout, "%*s\n", index, index, inbuffer); |
843 |
fprintf(stdout, "%*s\n", index, inbuffer); |
844 |
return index; |
844 |
return index; |
845 |
} |
845 |
} |
846 |
|
846 |
|
Lines 916-922
Link Here
|
916 |
free(outbuffer); |
916 |
free(outbuffer); |
917 |
|
917 |
|
918 |
if(mode == CDDB_MODE_HTTP) |
918 |
if(mode == CDDB_MODE_HTTP) |
919 |
cddb_skip_http_header(sock); |
919 |
if (cddb_skip_http_header(sock)<0) return -1; |
920 |
|
920 |
|
921 |
if((inbuffer = malloc(256)) == NULL) |
921 |
if((inbuffer = malloc(256)) == NULL) |
922 |
return -1; |
922 |
return -1; |
Lines 1160-1170
Link Here
|
1160 |
cddb_genre(entry->entry_genre), |
1160 |
cddb_genre(entry->entry_genre), |
1161 |
entry->entry_id); |
1161 |
entry->entry_id); |
1162 |
|
1162 |
|
1163 |
send(sock, outbuffer, strlen(outbuffer), 0); |
1163 |
if(send(sock, outbuffer, strlen(outbuffer), 0)<0) { |
|
|
1164 |
free(outbuffer); |
1165 |
return -1; |
1166 |
} |
1167 |
|
1164 |
free(outbuffer); |
1168 |
free(outbuffer); |
1165 |
|
1169 |
|
1166 |
if(mode == CDDB_MODE_HTTP) |
1170 |
if(mode == CDDB_MODE_HTTP) |
1167 |
cddb_skip_http_header(sock); |
1171 |
if (cddb_skip_http_header(sock)<0) return -1; |
1168 |
|
1172 |
|
1169 |
if(cddb_read_token(sock, token) < 0) |
1173 |
if(cddb_read_token(sock, token) < 0) |
1170 |
return -1; |
1174 |
return -1; |