diff options
author | 2007-01-30 03:52:23 +1000 | |
---|---|---|
committer | 2007-01-30 03:52:23 +1000 | |
commit | 41c9f89fcfb94185ea336d921e45e08953a6faa2 (patch) | |
tree | 88d18e38fdf0c1a73035f81bce27a98a1535f70c /reader.c | |
parent | 7953863b381fc80fc0a246674d15f342d79d19b7 (diff) |
Add memory allocation check
darcs-hash:20070129175223-ac50b-05b933837cf0522889287069d5ed2fcacaf62b6a.gz
Diffstat (limited to 'reader.c')
-rw-r--r-- | reader.c | 6 |
1 files changed, 6 insertions, 0 deletions
@@ -1753,6 +1753,12 @@ static int default_test( wchar_t *b ) void reader_push( wchar_t *name ) { reader_data_t *n = calloc( 1, sizeof( reader_data_t ) ); + + if( !n ) + { + DIE_MEM(); + } + n->name = wcsdup( name ); n->next = data; sb_init( &n->kill_item ); |