Page MenuHomeFreeBSD

Make struct grouptask gt_name member a char array
ClosedPublic

Authored by shurd on Sep 22 2017, 12:34 AM.
Tags
None
Referenced Files
Unknown Object (File)
Sep 22 2024, 7:42 PM
Unknown Object (File)
Sep 22 2024, 5:39 PM
Unknown Object (File)
Sep 21 2024, 8:51 AM
Unknown Object (File)
Sep 21 2024, 8:51 AM
Unknown Object (File)
Sep 21 2024, 8:51 AM
Unknown Object (File)
Sep 21 2024, 8:50 AM
Unknown Object (File)
Sep 19 2024, 5:03 AM
Unknown Object (File)
Sep 6 2024, 9:37 PM
Subscribers

Details

Summary

Previously, it was just a pointer which was copied, but
some callers pass in a stack variable which will go out of scope.
Add GROUPTASK_NAMELEN macro (32) and snprintf() the name into it,
using "grouptask" if name is NULL. We can now safely include
gtask->gt_name in console messages.

Test Plan

Trigger errors and ensure name is printed correctly

Diff Detail

Repository
rS FreeBSD src repository - subversion
Lint
Lint Not Applicable
Unit
Tests Not Applicable