Skip to content

Commit 20b65d6

Browse files
rockoragergdamore
andauthored
Fix dynamic terminfo when an alias is used (#639)
Co-authored-by: Garrett D'Amore <[email protected]>
1 parent 2917c38 commit 20b65d6

File tree

1 file changed

+1
-7
lines changed

1 file changed

+1
-7
lines changed

terminfo/dynamic/dynamic.go

Lines changed: 1 addition & 7 deletions
Original file line numberDiff line numberDiff line change
@@ -185,16 +185,10 @@ func (tc *termcap) setupterm(name string) error {
185185
func LoadTerminfo(name string) (*terminfo.Terminfo, string, error) {
186186
var tc termcap
187187
if err := tc.setupterm(name); err != nil {
188-
if err != nil {
189-
return nil, "", err
190-
}
188+
return nil, "", err
191189
}
192190
t := &terminfo.Terminfo{}
193-
// If this is an alias record, then just emit the alias
194191
t.Name = tc.name
195-
if t.Name != name {
196-
return t, "", nil
197-
}
198192
t.Aliases = tc.aliases
199193
t.Colors = tc.getnum("colors")
200194
t.Columns = tc.getnum("cols")

0 commit comments

Comments
 (0)