systemd / systemd/systemd

Environment generators fail silently when they encounter double quotes

Open
#5,538 1 comment 0 reactions 0 assignees View on GitHub

Nobody has claimed this yet.

bug 🐛 pid1
Dominant language
C
Stars
16.7k
Forks
4.7k
Avg merge
1d 6h
Merged PRs (30d)
140

Description

Submission type
  • Bug report
  • Request for enhancement (RFE)
systemd version the issue has been seen with

233

Used distribution

Arch Linux (custom systemd build)

In case of bug report: Steps to reproduce the problem

From an environment generator,

echo 'BEFORE=before'
echo 'QUOTED="quoted"'
echo 'AFTER=after'
In case of bug report: Expected behaviour you didn't see

I expected QUOTED to be set to either "quoted" or quoted. Unfortunately, the behavior of environment generators is pretty much undocumented so I don't know which it should have been.

In case of bug report: Unexpected behaviour you saw

BEFORE was set to BEFORE and AFTER was set to after. QUOTED wasn't set at all.

Contributor guide

Open the contributing guide

First steps

  1. Read the whole issue, then the project's contributing guide.
  2. Comment on the issue to say you are picking it up — it saves two people doing the same work.
  3. Fork the repository and make your change on a branch.
  4. Open a pull request that references the issue number.

Research direction

Start by reproducing the environment-generator example with BEFORE, QUOTED, and AFTER variables on the reported systemd version. Trace how environment generators parse the quoted value and determine the intended handling for QUOTED, then verify that the surrounding variables remain set and the behavior is covered by a regression test.

Written by the indexing model from the issue text.

Assessment

Tech stack
c, linux
Domain
operating-systems
Issue type
Bug
Difficulty
3/5
Estimated time
1-2 days
Activity status
Stale
Clarity
Mostly clear
Newbie friendliness
35/100

Get new issues in your inbox

A short digest of beginner-friendly GitHub issues.