Added head_unit tests

This commit is contained in:
James Booth
2012-03-02 01:51:40 +00:00
parent c641ebb8a4
commit a05a65febe
6 changed files with 164 additions and 0 deletions

View File

@@ -20,6 +20,7 @@
*
*/
#include <stdlib.h>
#include <string.h>
#define MAX_HISTORY 100
@@ -30,6 +31,10 @@ static int _pos;
void history_init(void)
{
int i;
for (i = 0; i < _size; i++)
free(_history[i]);
_size = 0;
_pos = -1;
}