\f
/* ascii_close_page () and support routines. */
+
+#if HAVE_DECL_SIGWINCH
static struct ascii_driver *the_driver;
static void
{
update_page_size (the_driver, false);
}
+#endif
static bool
ascii_open_page (struct ascii_driver *a)
a->file = fn_open (a->file_name, a->append ? "a" : "w");
if (a->file != NULL)
{
+#if HAVE_DECL_SIGWINCH
if ( isatty (fileno (a->file)))
{
struct sigaction action;
a->auto_length = true;
sigaction (SIGWINCH, &action, NULL);
}
-
+#endif
if (a->init != NULL)
fputs (a->init, a->file);
}
output_title_line (FILE *out, int width, const char *left, const char *right)
{
struct string s = DS_EMPTY_INITIALIZER;
- ds_put_char_multiple (&s, ' ', width);
+ ds_put_byte_multiple (&s, ' ', width);
if (left != NULL)
{
size_t length = MIN (strlen (left), width);
size_t length = MIN (strlen (right), width);
memcpy (ds_end (&s) - length, right, length);
}
- ds_put_char (&s, '\n');
+ ds_put_byte (&s, '\n');
fputs (ds_cstr (&s), out);
ds_destroy (&s);
}