Page MenuHomeFreeBSD

sh: Don't add something to a null pointer
ClosedPublic

Authored by jilles on Jan 23 2022, 9:28 PM.
Tags
None
Referenced Files
F104280870: D34011.diff
Thu, Dec 5, 7:18 PM
Unknown Object (File)
Wed, Nov 27, 11:51 AM
Unknown Object (File)
Mon, Nov 25, 5:44 PM
Unknown Object (File)
Oct 1 2024, 1:26 PM
Unknown Object (File)
Sep 27 2024, 11:02 AM
Unknown Object (File)
Sep 27 2024, 6:16 AM
Unknown Object (File)
Sep 27 2024, 3:42 AM
Unknown Object (File)
Sep 26 2024, 12:29 AM

Details

Summary

Pointer arithmetic on a null pointer is undefined behavior.

The bug can be reproduced by running bin/sh/tests/builtins/wait6.0 with
UBSAN.

Test Plan

kyua test

Diff Detail

Repository
rG FreeBSD src repository
Lint
Lint Skipped
Unit
Tests Skipped