mirror of
				https://github.com/tmux/tmux.git
				synced 2025-11-04 00:56:10 +00:00 
			
		
		
		
	Do not crash on a zero size character.
This commit is contained in:
		@@ -3148,6 +3148,11 @@ window_copy_cellstring(const struct grid_line *gl, u_int px, size_t *size,
 | 
			
		||||
	}
 | 
			
		||||
 | 
			
		||||
	utf8_to_data(gl->extddata[gce->offset].data, &ud);
 | 
			
		||||
	if (ud.size == 0) {
 | 
			
		||||
		*size = 0;
 | 
			
		||||
		*allocated = 0;
 | 
			
		||||
		return (NULL);
 | 
			
		||||
	}
 | 
			
		||||
	*size = ud.size;
 | 
			
		||||
	*allocated = 1;
 | 
			
		||||
 | 
			
		||||
 
 | 
			
		||||
		Reference in New Issue
	
	Block a user