NetBSD-Bugs archive

[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index][Old Index]

PR/58609 CVS commit: src/lib/libedit



The following reply was made to PR bin/58609; it has been noted by GNATS.

From: "Robert Elz" <kre%netbsd.org@localhost>
To: gnats-bugs%gnats.NetBSD.org@localhost
Cc: 
Subject: PR/58609 CVS commit: src/lib/libedit
Date: Tue, 16 Dec 2025 02:40:48 +0000

 Module Name:	src
 Committed By:	kre
 Date:		Tue Dec 16 02:40:48 UTC 2025
 
 Modified Files:
 	src/lib/libedit: editline.3 el.c el.h histedit.h terminal.c vi.c
 
 Log Message:
 [Prereq for PR bin/58609] Add EL_GETENV to libedit
 
 When interacting with the shell, and perhaps other applications,
 editline needs to obtain the values of some environment variables.
 
 Normally getenv(3) does that - but that doesn't work when being
 used in sh(1) as getenv() simply accesses the environment as it
 was when sh(1) was invoked - after that, in sh anyway, that
 environment is simply abandoned (well, kind of) - but certainly
 no changes made by the shell will be reflected there.
 
 To allow editline to obtain current values of environment
 variables, add a new el_set()/el_get() "op" parameter value,
 which can be used to instruct editline which function to use
 for the purpose.   That is EL_GETENV.
 
 This is part of a (long pending, awaiting testing) fix for
 PR bin/58609 - but I'm getting tired of having it sitting uncommitted
 in my source tree - and I think this part is self contained,
 and simple enough, to simply commit.
 
 
 To generate a diff of this commit:
 cvs rdiff -u -r1.103 -r1.104 src/lib/libedit/editline.3 src/lib/libedit/el.c
 cvs rdiff -u -r1.48 -r1.49 src/lib/libedit/el.h
 cvs rdiff -u -r1.63 -r1.64 src/lib/libedit/histedit.h
 cvs rdiff -u -r1.46 -r1.47 src/lib/libedit/terminal.c
 cvs rdiff -u -r1.65 -r1.66 src/lib/libedit/vi.c
 
 Please note that diffs are not public domain; they are subject to the
 copyright notices on the relevant files.
 


Home | Main Index | Thread Index | Old Index