diff options
| author | Thomas Schmucker <ts@its1.de> | 2022-01-16 17:02:25 +0100 |
|---|---|---|
| committer | Thomas Schmucker <ts@its1.de> | 2022-01-16 17:02:25 +0100 |
| commit | 011ef70f4c1b6ef8384a3573d93595b42dba4395 (patch) | |
| tree | c5ba35b8b9357c43ea0edb528f8f9d7afba17c00 /avl.c | |
| parent | 1bb9e12dca59f6e97d14c938d37b9b492a9e546f (diff) | |
| download | data-structures-011ef70f4c1b6ef8384a3573d93595b42dba4395.tar.gz data-structures-011ef70f4c1b6ef8384a3573d93595b42dba4395.tar.bz2 data-structures-011ef70f4c1b6ef8384a3573d93595b42dba4395.zip | |
feat: use assert instead an ugly if-error-statement
Diffstat (limited to 'avl.c')
| -rw-r--r-- | avl.c | 4 |
1 files changed, 2 insertions, 2 deletions
| @@ -110,8 +110,8 @@ insert_r(T x, struct tree_node *p, bool *h) | |||
| 110 | p->count++; /* hit counter */ | 110 | p->count++; /* hit counter */ |
| 111 | *h = false; | 111 | *h = false; |
| 112 | } | 112 | } |
| 113 | if ( p == NULL ) | 113 | assert(p != NULL); |
| 114 | ERROR("das hier sollte niemals passieren"); | 114 | |
| 115 | return p; | 115 | return p; |
| 116 | } | 116 | } |
| 117 | /* -->8-- */ | 117 | /* -->8-- */ |
