mirror of
				https://github.com/tmux/tmux.git
				synced 2025-10-26 12:27:15 +00:00 
			
		
		
		
	Trivial code simplification from Tim Ruehsen.
This commit is contained in:
		 Nicholas Marriott
					Nicholas Marriott
				
			
				
					committed by
					
						 Thomas Adam
						Thomas Adam
					
				
			
			
				
	
			
			
			 Thomas Adam
						Thomas Adam
					
				
			
						parent
						
							40505e59f1
						
					
				
				
					commit
					b79f86e32a
				
			
							
								
								
									
										6
									
								
								paste.c
									
									
									
									
									
								
							
							
						
						
									
										6
									
								
								paste.c
									
									
									
									
									
								
							| @@ -161,10 +161,8 @@ paste_print(struct paste_buffer *pb, size_t width) | |||||||
| 		len = width; | 		len = width; | ||||||
|  |  | ||||||
| 	used = strvisx(buf, pb->data, len, VIS_OCTAL|VIS_TAB|VIS_NL); | 	used = strvisx(buf, pb->data, len, VIS_OCTAL|VIS_TAB|VIS_NL); | ||||||
| 	if (pb->size > width || used > width) { | 	if (pb->size > width || used > width) | ||||||
| 		buf[width - 3] = '\0'; | 		strlcpy(buf + width - 3, "...", 4); | ||||||
| 		strlcat(buf, "...", width); |  | ||||||
| 	} |  | ||||||
|  |  | ||||||
| 	return (buf); | 	return (buf); | ||||||
| } | } | ||||||
|   | |||||||
		Reference in New Issue
	
	Block a user