Skip to content

Commit c79a9f0

Browse files
committed
Don't crash if timer is reset.
1 parent 94b686a commit c79a9f0

File tree

1 file changed

+4
-0
lines changed

1 file changed

+4
-0
lines changed

src/main.qc

Lines changed: 4 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -379,6 +379,10 @@ void(float vwidth, float vheight, float notmenu) CSQC_UpdateView =
379379
float slide_offset = 0;
380380
381381
itemtimer_t *timer = PipGetTimer(camera_index);
382+
if (!timer) {
383+
return;
384+
}
385+
382386
item_t *item = timer->item;
383387
384388
if (camera_end == CAMERA_END_RESET && timer->took > camera_start) {

0 commit comments

Comments
 (0)