aboutsummaryrefslogtreecommitdiff
path: root/server.c
diff options
context:
space:
mode:
authorsotech117 <michael_foiani@brown.edu>2023-09-21 16:57:51 -0400
committersotech117 <michael_foiani@brown.edu>2023-09-21 16:57:51 -0400
commit2707112ffc0b0eed6af8271d32f94e1622203a80 (patch)
tree33f1ce98717cf15c69814b9832f59311ac03f2c0 /server.c
parent97ff64f344c99f76bbed6b934236ee65eda8a9ef (diff)
decent stopping point. failing some more tests - may have to redesign my threads
Diffstat (limited to 'server.c')
-rw-r--r--server.c2
1 files changed, 1 insertions, 1 deletions
diff --git a/server.c b/server.c
index 333f521..7df1f12 100644
--- a/server.c
+++ b/server.c
@@ -353,7 +353,6 @@ void *send_udp_packet_routine(void *arg) {
perror("send_all_udp");
printf("We only sent %d bytes because of the error!\n", bytes_read);
}
-
did_work = 1;
@@ -808,6 +807,7 @@ void seek_stations(int station_num) {
station_t *station_info = &station_data[station_num];
memset(&station_info->fileBuffer, 0, MAX_STREAM_RATE);
int bytes_read = read(station_info->streamFd, &station_info->fileBuffer, MAX_STREAM_RATE);
+ lseek(station_info->streamFd, -16, SEEK_SET);
// printf("station info - bytes read: %d, station_fd: %d, filePath: %s, buffersize: %d\n", bytes_read, station_info->streamFd, station_info->filePath, station_info->fileBufferSize);
// time to restart the file