source: errqueue.c @ 74037d9

barnowl_perlaimdebianowlrelease-1.10release-1.4release-1.5release-1.6release-1.7release-1.8release-1.9
Last change on this file since 74037d9 was ec6ff52, checked in by James M. Kretchmar <kretch@mit.edu>, 21 years ago
Added the 'show errors' command Added the error queue Converted most makemsg's to error instead Started writing an internal VT style (far from done)
  • Property mode set to 100644
File size: 526 bytes
Line 
1#include "owl.h"
2
3void owl_errqueue_init(owl_errqueue *eq)
4{
5  owl_list_create(&(eq->errlist));
6}
7
8void owl_errqueue_append_err(owl_errqueue *eq, char *msg)
9{
10  owl_list_append_element(&(eq->errlist), owl_strdup(msg));
11}
12
13/* fmtext should already be initialized */
14void owl_errqueue_to_fmtext(owl_errqueue *eq, owl_fmtext *fm)
15{
16  int i, j;
17
18  j=owl_list_get_size(&(eq->errlist));
19  for (i=0; i<j; i++) {
20    owl_fmtext_append_normal(fm, owl_list_get_element(&(eq->errlist), i));
21    owl_fmtext_append_normal(fm, "\n");
22  }
23}
Note: See TracBrowser for help on using the repository browser.