mirror of
https://github.com/yann64/haikuports.git
synced 2026-04-08 21:00:05 +02:00
60 lines
1.7 KiB
Plaintext
60 lines
1.7 KiB
Plaintext
From d9e8a975610afbe61c4ed4cbba88a74111d3e302 Mon Sep 17 00:00:00 2001
|
|
From: Jerome Duval <jerome.duval@gmail.com>
|
|
Date: Tue, 9 Mar 2021 23:01:30 +0100
|
|
Subject: gcc2 patch
|
|
|
|
|
|
diff --git a/ogg123/status.c b/ogg123/status.c
|
|
index d696927..61a7369 100644
|
|
--- a/ogg123/status.c
|
|
+++ b/ogg123/status.c
|
|
@@ -171,6 +171,7 @@ int print_statistics_line (stat_format_t stats[])
|
|
#ifdef HAVE_UNISTD_H
|
|
/* If the line would break in the console, truncate it to avoid the break,
|
|
and indicate the truncation by adding points of ellipsis */
|
|
+{
|
|
struct winsize max;
|
|
int ioctlError = ioctl(STDERR_FILENO, TIOCGWINSZ, &max);
|
|
if (!ioctlError) {
|
|
@@ -180,14 +181,17 @@ int print_statistics_line (stat_format_t stats[])
|
|
if (pointsStart < 0) {
|
|
pointsStart = 0;
|
|
}
|
|
+{
|
|
int position;
|
|
for (position = pointsStart; position < limit; position++) {
|
|
str[position] = '.';
|
|
}
|
|
str[position] = 0;
|
|
len = position;
|
|
+}
|
|
}
|
|
}
|
|
+}
|
|
#endif
|
|
|
|
len += sprintf(str+len, "\r");
|
|
diff --git a/ogginfo/codec_theora.c b/ogginfo/codec_theora.c
|
|
index a106f34..43729c9 100644
|
|
--- a/ogginfo/codec_theora.c
|
|
+++ b/ogginfo/codec_theora.c
|
|
@@ -183,6 +183,7 @@ static void theora_end(stream_processor *stream)
|
|
|| (inf->ti.version_minor == 2 && inf->ti.version_subminor > 0)));
|
|
|
|
/* This should be lastgranulepos - startgranulepos, or something like that*/
|
|
+{
|
|
ogg_int64_t iframe=inf->lastgranulepos>>inf->ti.granule_shift;
|
|
ogg_int64_t pframe=inf->lastgranulepos-(iframe<<inf->ti.granule_shift);
|
|
/* The granule position starts at 0 for stream version 3.2.0, but starts at
|
|
@@ -206,6 +207,7 @@ static void theora_end(stream_processor *stream)
|
|
|
|
free(stream->data);
|
|
}
|
|
+}
|
|
|
|
|
|
void theora_start(stream_processor *stream)
|
|
--
|
|
2.30.0
|
|
|