{"action":"created","issue":{"url":"https://api.github.com/repos/okbob/pspg/issues/67","repository_url":"https://api.github.com/repos/okbob/pspg","labels_url":"https://api.github.com/repos/okbob/pspg/issues/67/labels{/name}","comments_url":"https://api.github.com/repos/okbob/pspg/issues/67/comments","events_url":"https://api.github.com/repos/okbob/pspg/issues/67/events","html_url":"https://github.com/okbob/pspg/issues/67","id":329614407,"node_id":"MDU6SXNzdWUzMjk2MTQ0MDc=","number":67,"title":"psql '\\s' command to display history causes 'Segmentation fault: 11' on MacOS","user":{"login":"hunsakerbn","id":4139627,"node_id":"MDQ6VXNlcjQxMzk2Mjc=","avatar_url":"https://avatars0.githubusercontent.com/u/4139627?v=4","gravatar_id":"","url":"https://api.github.com/users/hunsakerbn","html_url":"https://github.com/hunsakerbn","followers_url":"https://api.github.com/users/hunsakerbn/followers","following_url":"https://api.github.com/users/hunsakerbn/following{/other_user}","gists_url":"https://api.github.com/users/hunsakerbn/gists{/gist_id}","starred_url":"https://api.github.com/users/hunsakerbn/starred{/owner}{/repo}","subscriptions_url":"https://api.github.com/users/hunsakerbn/subscriptions","organizations_url":"https://api.github.com/users/hunsakerbn/orgs","repos_url":"https://api.github.com/users/hunsakerbn/repos","events_url":"https://api.github.com/users/hunsakerbn/events{/privacy}","received_events_url":"https://api.github.com/users/hunsakerbn/received_events","type":"User","site_admin":false},"labels":[],"state":"open","locked":false,"assignee":null,"assignees":[],"milestone":null,"comments":7,"created_at":"2018-06-05T20:33:50Z","updated_at":"2018-06-06T18:50:27Z","closed_at":null,"author_association":"NONE","body":"When I tried to use '\\s' in psql (with PAGER set to pspg) I got no output.  Further investigation indicated that pspg was exiting with a 'Segmentation fault: 11'. \r\nI tracked this down to pspg.c line 876 (in master):\r\n\t\tdesc->headline_size = strlen(desc->headline);\r\nA fix was not obvious to me."},"comment":{"url":"https://api.github.com/repos/okbob/pspg/issues/comments/395175023","html_url":"https://github.com/okbob/pspg/issues/67#issuecomment-395175023","issue_url":"https://api.github.com/repos/okbob/pspg/issues/67","id":395175023,"node_id":"MDEyOklzc3VlQ29tbWVudDM5NTE3NTAyMw==","user":{"login":"okbob","id":546675,"node_id":"MDQ6VXNlcjU0NjY3NQ==","avatar_url":"https://avatars2.githubusercontent.com/u/546675?v=4","gravatar_id":"","url":"https://api.github.com/users/okbob","html_url":"https://github.com/okbob","followers_url":"https://api.github.com/users/okbob/followers","following_url":"https://api.github.com/users/okbob/following{/other_user}","gists_url":"https://api.github.com/users/okbob/gists{/gist_id}","starred_url":"https://api.github.com/users/okbob/starred{/owner}{/repo}","subscriptions_url":"https://api.github.com/users/okbob/subscriptions","organizations_url":"https://api.github.com/users/okbob/orgs","repos_url":"https://api.github.com/users/okbob/repos","events_url":"https://api.github.com/users/okbob/events{/privacy}","received_events_url":"https://api.github.com/users/okbob/received_events","type":"User","site_admin":false},"created_at":"2018-06-06T18:50:26Z","updated_at":"2018-06-06T18:50:26Z","author_association":"OWNER","body":"2018-06-06 15:48 GMT+02:00 Bruce Hunsaker <notifications@github.com>:\n\n> border_head_row is 1339. The following patch seems to fix it, but it's\n> probably the wrong way to do it.\n>\n\nI don't understand how it is possible, after patching - my patch was\nsimilar to your\n\nhttps://github.com/okbob/pspg/commit/3795670a753f2241d7e8e33a4160da0d169375ac\n\n/*\n* border headline cannot be higher than 1000, to simply find it\n* in first row block. Higher number is surelly wrong, probably\n* some comment.\n*/\nif (desc->border_top_row >= 1000)\ndesc->border_top_row = -1;\n\nif (desc->last_row != -1)\ndesc->maxy = desc->last_row;\n\ndesc->headline_char_size = 0;\n\nif (desc->border_head_row != -1)\n{\n    desc->headline = desc->rows.rows[desc->border_head_row];\n     desc->headline_size = strlen(desc->headline);\n\nSo border_head_row on this problematic place cannot be 1339\n\nMaybe patch was not applyed well?\n\n\n\n\n\n\n> +++ pspg.c 2018-06-06 07:44:16.548963411 -0600\n> @@ -878,6 +878,9 @@\n>\n>     desc->headline_char_size = 0;\n>\n>\n>    -\n>\n>      if (desc->border_head_row >= 10)\n>\n>    -\n>\n>              desc->border_head_row = -1;\n>\n>    -\n>\n>      if (desc->border_head_row != -1)\n>      {\n>              desc->headline = desc->rows.rows[desc->border_head_row];\n>\n>\n> —\n> You are receiving this because you commented.\n> Reply to this email directly, view it on GitHub\n> <https://github.com/okbob/pspg/issues/67#issuecomment-395074825>, or mute\n> the thread\n> <https://github.com/notifications/unsubscribe-auth/AAhXc1gqqkmBltcpy4gke5YPbAvjlE9Pks5t5929gaJpZM4Ubgq1>\n> .\n>\n"}}
{"actor":{"display_login":"okbob"}}