{"action":"closed","issue":{"url":"https://api.github.com/repos/att/ast/issues/472","repository_url":"https://api.github.com/repos/att/ast","labels_url":"https://api.github.com/repos/att/ast/issues/472/labels{/name}","comments_url":"https://api.github.com/repos/att/ast/issues/472/comments","events_url":"https://api.github.com/repos/att/ast/issues/472/events","html_url":"https://github.com/att/ast/issues/472","id":314438774,"number":472,"title":"Ksh's .sh.file contains garbage after returning from \"sourcing\" another file.","user":{"login":"kwwall","id":1959835,"avatar_url":"https://avatars0.githubusercontent.com/u/1959835?v=4","gravatar_id":"","url":"https://api.github.com/users/kwwall","html_url":"https://github.com/kwwall","followers_url":"https://api.github.com/users/kwwall/followers","following_url":"https://api.github.com/users/kwwall/following{/other_user}","gists_url":"https://api.github.com/users/kwwall/gists{/gist_id}","starred_url":"https://api.github.com/users/kwwall/starred{/owner}{/repo}","subscriptions_url":"https://api.github.com/users/kwwall/subscriptions","organizations_url":"https://api.github.com/users/kwwall/orgs","repos_url":"https://api.github.com/users/kwwall/repos","events_url":"https://api.github.com/users/kwwall/events{/privacy}","received_events_url":"https://api.github.com/users/kwwall/received_events","type":"User","site_admin":false},"labels":[],"state":"closed","locked":false,"assignee":null,"assignees":[],"milestone":null,"comments":2,"created_at":"2018-04-15T18:19:51Z","updated_at":"2018-04-17T13:12:23Z","closed_at":"2018-04-17T13:12:23Z","author_association":"NONE","body":"These results are based on the lastest AST ksh93, built from sources pulled from GitHub as of a few days ago. In a nutshell, initially ksh's value for .sh.file starts out correctly and is correct while inside a \"sourced\" (i.e., \"dotted\" script; e.g., \". ./foo.ksh\"), one the script returns from the \"sourced\" file, the value of .sh.file now contains garbage. I discovered this while attempting to debug @rocky kshdb.\r\n\r\nAttached is a script (try.ksh) to reproduce this. This is the output of this script is shown here:\r\n\r\n$ ./try.ksh    # Renamed to try.ksh.txt in order to attach to GitHub\r\nThis is KornShell - Version: Version ABIJ 93v- 2014-12-24\r\nLinux Latitude-E4300 4.13.0-38-generic #43-Ubuntu SMP Wed Mar 14 15:20:44 UTC 2018 x86_64 x86_64 x86_64 GNU/Linux\r\nNo LSB modules are available.\r\nDistributor ID:\tUbuntu\r\nDescription:\tUbuntu 17.10\r\nRelease:\t17.10\r\nCodename:\tartful\r\n1: .sh.file = '/home/wallk/try.ksh'\r\n1: .sh.file -- base name = 'try.ksh'\r\n1: PASS\r\nThis is foo.ksh, $0=./try.ksh, .sh.file=/home/wallk/foo.ksh\r\n2: .sh.file = 'Pñ\u001D\u0013d'\r\n2: .sh.file -- base name = 'Pñ\u001D\u0013d'\r\nFAIL\r\n\r\n[try.ksh.txt](https://github.com/att/ast/files/1913143/try.ksh.txt)\r\n"}}
{"actor":{"display_login":"siteshwar"}}