tin  2.4.5
About: TIN is a threaded NNTP and spool based UseNet newsreader.
  Fossies Dox: tin-2.4.5.tar.xz  ("unofficial" and yet experimental doxygen-generated source code documentation)  

memory.c File Reference
#include "tin.h"
Include dependency graph for memory.c:

Go to the source code of this file.

Functions

static void free_active_arrays (void)
 
static void free_attributes (struct t_attribute *attributes)
 
static void free_scopes_arrays (void)
 
static void free_newnews_array (void)
 
static void free_if_not_default (char **attrib, char *deflt)
 
static void free_input_history (void)
 
void init_alloc (void)
 
void expand_art (void)
 
void expand_active (void)
 
void expand_base (void)
 
void expand_save (void)
 
void expand_scope (void)
 
void expand_newnews (void)
 
void init_screen_array (t_bool allocate)
 
void free_all_arrays (void)
 
void free_art_array (void)
 
void free_scope (int num)
 
void free_save_array (void)
 
void * my_malloc1 (const char *file, int line, size_t size)
 
void * my_calloc1 (const char *file, int line, size_t nmemb, size_t size)
 
void * my_realloc1 (const char *file, int line, void *p, size_t size)
 

Variables

int max_active
 
int num_active = -1
 
int max_newnews
 
int num_newnews = 0
 
int max_art
 
int max_base
 
int max_save
 
int num_save = 0
 
int max_scope
 
int num_scope = -1
 
int * my_group
 
t_artnumbase
 
struct t_groupactive
 
struct t_scopescopes = NULL
 
struct t_newnewsnewnews
 
struct t_articlearts
 
struct t_savesave
 

Function Documentation

◆ expand_active()

void expand_active ( void  )

Definition at line 152 of file memory.c.

References active, max_active, my_calloc, my_group, my_malloc, and my_realloc.

Referenced by group_add().

◆ expand_art()

void expand_art ( void  )

Definition at line 135 of file memory.c.

References arts, max_art, and my_realloc.

Referenced by read_art_headers(), and read_overview().

◆ expand_base()

void expand_base ( void  )

Definition at line 167 of file memory.c.

References base, max_base, and my_realloc.

Referenced by find_base(), and setup_hard_base().

◆ expand_newnews()

void expand_newnews ( void  )

Definition at line 200 of file memory.c.

References max_newnews, my_realloc, and newnews.

Referenced by load_newnews_info().

◆ expand_save()

void expand_save ( void  )

Definition at line 176 of file memory.c.

References max_save, my_realloc, and save.

Referenced by save_and_process_art().

◆ expand_scope()

void expand_scope ( void  )

Definition at line 185 of file memory.c.

References max_scope, my_malloc, my_realloc, num_scope, and scopes.

Referenced by add_scope(), and init_alloc().

◆ free_active_arrays()

static void free_active_arrays ( void  )
static

◆ free_all_arrays()

◆ free_art_array()

◆ free_attributes()

◆ free_if_not_default()

static void free_if_not_default ( char **  attrib,
char *  deflt 
)
static

Definition at line 368 of file memory.c.

References FreeAndNull.

Referenced by free_attributes().

◆ free_input_history()

static void free_input_history ( void  )
static

Definition at line 514 of file memory.c.

References FreeIfNeeded, HIST_MAXNUM, HIST_SIZE, and input_history.

Referenced by free_all_arrays().

◆ free_newnews_array()

static void free_newnews_array ( void  )
static

Definition at line 501 of file memory.c.

References FreeAndNull, newnews, and num_newnews.

Referenced by free_all_arrays().

◆ free_save_array()

void free_save_array ( void  )

Definition at line 485 of file memory.c.

References FALSE, t_save::file, FreeAndNull, t_save::mailbox, num_save, and save.

Referenced by feed_articles(), and free_all_arrays().

◆ free_scope()

void free_scope ( int  num)

◆ free_scopes_arrays()

static void free_scopes_arrays ( void  )
static

Definition at line 446 of file memory.c.

References free_scope(), FreeAndNull, num_scope, and scopes.

Referenced by free_all_arrays().

◆ init_alloc()

◆ init_screen_array()

void init_screen_array ( t_bool  allocate)

Definition at line 210 of file memory.c.

References cCOLS, cLINES, t_screen::col, FreeAndNull, my_malloc, and screen.

Referenced by free_all_arrays(), and set_win_size().

◆ my_calloc1()

void* my_calloc1 ( const char *  file,
int  line,
size_t  nmemb,
size_t  size 
)

Definition at line 552 of file memory.c.

References debug, DEBUG_MEM, error_message(), giveup(), tin_progname, TRUE, and txt_out_of_memory.

◆ my_malloc1()

void* my_malloc1 ( const char *  file,
int  line,
size_t  size 
)

Definition at line 528 of file memory.c.

References debug, DEBUG_MEM, error_message(), giveup(), tin_progname, TRUE, and txt_out_of_memory.

◆ my_realloc1()

void* my_realloc1 ( const char *  file,
int  line,
void *  p,
size_t  size 
)

Definition at line 574 of file memory.c.

References debug, DEBUG_MEM, error_message(), FALSE, giveup(), tin_progname, and txt_out_of_memory.

Variable Documentation

◆ active

◆ arts

struct t_article* arts

Definition at line 69 of file memory.c.

Referenced by arts_selected(), author_search(), body_search(), build_references(), build_sline(), build_thread(), build_tline(), check_start_save_any_news(), collate_subjects(), config_page(), do_auto_select_arts(), do_update(), draw_page(), draw_page_header(), draw_subject_arrow(), draw_thread_arrow(), draw_thread_item(), expand_art(), feed_article(), feed_articles(), filter_articles(), find_artnum(), find_base(), find_response(), free_all_arrays(), free_art_array(), get_feed_key(), get_last_posting_date(), get_save_filename(), get_score_of_thread(), global_get_multiparts(), global_look_for_multipart(), global_look_for_multipart_info(), group_catchup(), group_page(), grp_del_mail_arts(), index_group(), init_alloc(), line_is_tagged(), load_article(), mail_to_author(), make_threads(), new_responses(), next_response(), next_unread(), parse_unread_arts(), post_response(), prev_response(), prev_unread(), print_file(), read_art_headers(), read_overview(), rearrange_siblings(), score_comp_base(), search_group(), set_range(), show_group_title(), show_page(), show_thread_page(), stat_thread(), strfquote(), subject_search(), tag_article(), tag_multipart(), thd_mark_read(), thd_mark_unread(), thread_by_multipart(), thread_by_percentage(), thread_by_reference(), thread_by_subject(), thread_catchup(), thread_mark_postprocess(), thread_page(), thread_tab_pressed(), toggle_read_unread(), undo_auto_select_arts(), undo_selections(), unfilter_articles(), untag_all_articles(), untag_article(), update_thread_page(), valid_artnum(), which_thread(), and write_overview().

◆ base

◆ max_active

int max_active

Definition at line 50 of file memory.c.

Referenced by expand_active(), group_add(), and init_alloc().

◆ max_art

int max_art

Definition at line 54 of file memory.c.

Referenced by expand_art(), init_alloc(), read_art_headers(), and read_overview().

◆ max_base

int max_base

Definition at line 55 of file memory.c.

Referenced by expand_base(), find_base(), init_alloc(), and setup_hard_base().

◆ max_newnews

int max_newnews

Definition at line 52 of file memory.c.

Referenced by expand_newnews(), init_alloc(), and load_newnews_info().

◆ max_save

int max_save

Definition at line 56 of file memory.c.

Referenced by expand_save(), init_alloc(), and save_and_process_art().

◆ max_scope

int max_scope

Definition at line 58 of file memory.c.

Referenced by add_scope(), expand_scope(), and init_alloc().

◆ my_group

◆ newnews

◆ num_active

◆ num_newnews

int num_newnews = 0

◆ num_save

◆ num_scope

◆ save

◆ scopes