From: gn64_jp Date: Sat, 14 Dec 2013 05:32:01 +0000 (+0900) Subject: tunerec: make buf malloc-ed instead of fixed array X-Git-Url: http://git.osdn.net/view?p=rec10%2Frec10-git.git;a=commitdiff_plain;h=a9612f286df7d9a29ad101d3e59a89908a360008 tunerec: make buf malloc-ed instead of fixed array --- diff --git a/tunerec/tunerec.c b/tunerec/tunerec.c index fad6b6d..822200a 100755 --- a/tunerec/tunerec.c +++ b/tunerec/tunerec.c @@ -235,7 +235,7 @@ void record(int adapter_nr, char* output, int rectime) { void * record_read(void * priv) { ssize_t rt; time_t start_time, current_time; - char buf[DVB_READ_BUFFER_SIZE]; + char* buf = malloc(DVB_READ_BUFFER_SIZE); my_thread_arg* p = (my_thread_arg*)priv; start_time = time(NULL); @@ -272,7 +272,7 @@ void * record_read(void * priv) { void * record_write(void * priv) { ssize_t rt = 0, wt, shift; - char buf[DVB_WRITE_BUFFER_SIZE]; + char* buf = malloc(DVB_WRITE_BUFFER_SIZE); my_thread_arg* p = (my_thread_arg*)priv; while ( 1 ) {