summaryrefslogtreecommitdiff
path: root/contrib/apps/httpserver
diff options
context:
space:
mode:
authorAristo Chen <[email protected]>2026-05-26 07:03:33 +0000
committerTom Rini <[email protected]>2026-06-11 12:00:46 -0600
commit4a4452a03916d8687442b1d0af5098be986e439e (patch)
tree27a702ab806f7f7bdcb4089a048889fe59819381 /contrib/apps/httpserver
parent759968136d68ba178904313c38ad1003525c58ac (diff)
test/py: cover get_basename crash on paths with dotted directories
Add a parametrized regression test for the fix in the previous commit. The test invokes mkimage in auto-FIT mode (-f auto) with a -b argument whose directory component contains a '.' and whose leaf either lacks an extension or is a plain identifier. Before the fix these inputs caused get_basename() to compute a negative length and segfault inside memcpy. The test asserts that mkimage exits successfully and that the fdt sub-image description matches the expected stripped basename, covering "./mydt", "./sub.d/leaf", and "./a.b/c". A control input of "./mydt.dtb" is also exercised to confirm normal extension stripping still works. Signed-off-by: Aristo Chen <[email protected]>
Diffstat (limited to 'contrib/apps/httpserver')
0 files changed, 0 insertions, 0 deletions