diff options
Diffstat (limited to 'net/ipv4/tcp_ulp.c')
| -rw-r--r-- | net/ipv4/tcp_ulp.c | 3 | 
1 files changed, 3 insertions, 0 deletions
diff --git a/net/ipv4/tcp_ulp.c b/net/ipv4/tcp_ulp.c index 4849edb62d52..12ab5db2b71c 100644 --- a/net/ipv4/tcp_ulp.c +++ b/net/ipv4/tcp_ulp.c @@ -92,6 +92,9 @@ void tcp_get_available_ulp(char *buf, size_t maxlen)  		offs += snprintf(buf + offs, maxlen - offs,  				 "%s%s",  				 offs == 0 ? "" : " ", ulp_ops->name); + +		if (WARN_ON_ONCE(offs >= maxlen)) +			break;  	}  	rcu_read_unlock();  }  | 
