Re: [PATCH] net: bridge: avoid redundant strlen() in show_backup_port()

From
Joe Damato <hidden>
Date
2026-11-17 17:49:20
Also in
bridge
Reply to
Dmitry Antipov, 2026-11-17
On Tue, Nov 17, 2026 at 07:51:06PM +0300, Dmitry Antipov wrote:
In store_backup_port(), prefer strchrnul() over strchr() to
avoid redundant call to strlen().
a couple things:

- i dont't think the change is worth it because it feels like unnecessary
  churn in a path that isn't a hot path. how many bytes are we really avoiding
  counting here?

- commit message mentions store_backup_port but subject line says
  show_backup_port, so commit would need to be respun

but imho i think this should be dropped
Thread (4 messages) 4 messages, 4 authors, last reply 3d ago
Keyboard shortcuts
hback out one level
jnext message in thread / next series-diff position
kprevious message in thread / previous series-diff position
ldrill in
Escclose help / fold thread tree
?toggle this help