Don't segfault when moving to/off the invalid spot [2].
This commit is contained in:
		
							parent
							
								
									9fbd1cbcaf
								
							
						
					
					
						commit
						548fe23b5d
					
				| @ -155,7 +155,8 @@ void handle_keyboard_event(int key) { | |||||||
|       handle_stock_event(); |       handle_stock_event(); | ||||||
|     } else { |     } else { | ||||||
|       struct card *card; |       struct card *card; | ||||||
|       if ((card = (*cursor_stack(cursor))->card)->face == COVERED) { |       if (cursor_stack(cursor) && | ||||||
|  |             (card = (*cursor_stack(cursor))->card)->face == COVERED) { | ||||||
|         expose_card(card); |         expose_card(card); | ||||||
|         draw_card(card); |         draw_card(card); | ||||||
|       } else { |       } else { | ||||||
|  | |||||||
		Loading…
	
	
			
			x
			
			
		
	
		Reference in New Issue
	
	Block a user