/* Alert box for a failed attempt to read a file. "err" is assumed to be a UNIX-style errno.  */
void read_failure_alert_box(const char *filename, int err)
/* Alert box for a failed attempt to read a file. "err" is assumed to be a UNIX-style errno.  */
void read_failure_alert_box(const char *filename, int err)
{
    gchar *display_basename;
    display_basename = g_filename_display_basename(filename);
    simple_message_box(ESD_TYPE_ERROR, NULL, NULL,
                       "An error occurred while reading from the file \"%s\": %s.",
                       display_basename, g_strerror(err));
    g_free(display_basename);
}