Skip to content
Snippets Groups Projects
Commit 985ed1c8 authored by Colin Walters's avatar Colin Walters
Browse files

console: Drop unused current_text/current_percent

The idea was clearly to avoid useless updates, but we never actually *set* these
values. Drop the code for now to avoid confusion, I'll reimplement this in a
better way.
parent bb7dd4dd
No related branches found
No related tags found
No related merge requests found
...@@ -36,8 +36,6 @@ ...@@ -36,8 +36,6 @@
*/ */
#define MAX_PROGRESSBAR_COLUMNS 20 #define MAX_PROGRESSBAR_COLUMNS 20
static char *current_text = NULL;
static gint current_percent = -1;
static gboolean locked; static gboolean locked;
static gboolean static gboolean
...@@ -154,8 +152,6 @@ glnx_console_lock (GLnxConsoleRef *console) ...@@ -154,8 +152,6 @@ glnx_console_lock (GLnxConsoleRef *console)
locked = console->locked = TRUE; locked = console->locked = TRUE;
current_percent = 0;
if (console->is_tty) if (console->is_tty)
{ {
if (g_once_init_enter (&sigwinch_initialized)) if (g_once_init_enter (&sigwinch_initialized))
...@@ -200,10 +196,6 @@ text_percent_internal (const char *text, ...@@ -200,10 +196,6 @@ text_percent_internal (const char *text,
const guint input_textlen = text ? strlen (text) : 0; const guint input_textlen = text ? strlen (text) : 0;
if (percentage == current_percent
&& g_strcmp0 (text, current_text) == 0)
return;
if (!stdout_is_tty ()) if (!stdout_is_tty ())
{ {
if (text) if (text)
...@@ -332,9 +324,6 @@ glnx_console_unlock (GLnxConsoleRef *console) ...@@ -332,9 +324,6 @@ glnx_console_unlock (GLnxConsoleRef *console)
g_return_if_fail (locked); g_return_if_fail (locked);
g_return_if_fail (console->locked); g_return_if_fail (console->locked);
current_percent = -1;
g_clear_pointer (&current_text, g_free);
if (console->is_tty) if (console->is_tty)
fputc ('\n', stdout); fputc ('\n', stdout);
......
0% Loading or .
You are about to add 0 people to the discussion. Proceed with caution.
Please register or to comment