run-program decodes and re-encodes environ

Bug #985904 reported by Nikodemus Siivola on 2012-04-19
This bug affects 1 person
Affects Status Importance Assigned to Milestone

Bug Description

...which is about as pointless as it gets. If environ is not explicitly provided as lisp strings, surely we should not start calling posix-environ.

More to the point, it makes things brittle unless c-string-external-format is anything but :latin-1 or another 8-bit encoding.

Stas Boukarev (stassats) wrote :

Here's my attempt, I modified it to pass NULL to spawn on the C side, and when spawn gets NULL, it leaves environ intact. I'm not entirely sure that it's the right way to go. But it works, and it also reduces consing.

tags: added: review
Stas Boukarev (stassats) on 2012-05-22
Changed in sbcl:
status: Triaged → Fix Committed
Stas Boukarev (stassats) wrote :

commit 0395c15ff8394bfaaed03050c1a7a131f197a732
Author: Stas Boukarev <email address hidden>
Date: Tue May 22 22:06:06 2012 +0400

    run-program: Don't decode and re-encode environ.

    Leave environ unchanged when no :environment argument is provided.

Changed in sbcl:
status: Fix Committed → Fix Released
To post a comment you must log in.
This report contains Public information  Edit
Everyone can see this information.

Other bug subscribers