diff options
author | jsorg71 <jay.sorg@gmail.com> | 2015-03-12 15:36:31 -0700 |
---|---|---|
committer | jsorg71 <jay.sorg@gmail.com> | 2015-03-12 15:36:31 -0700 |
commit | 4f60b58b176d068e485066d1de0574b2b6cdc5e1 (patch) | |
tree | de7c05934a29f40683709eac5033cdc52590059a /sesman/chansrv | |
parent | 5969e11153a7c186d36361c26b788488e5ddd4a2 (diff) | |
parent | f59c925f8b0a1ee55bf7d7da75f0e20a899c980d (diff) | |
download | xrdp-proprietary-4f60b58b176d068e485066d1de0574b2b6cdc5e1.tar.gz xrdp-proprietary-4f60b58b176d068e485066d1de0574b2b6cdc5e1.zip |
Merge pull request #212 from robertalks/devel
fix possible segfault in chansrv if DISPLAY is not set
Diffstat (limited to 'sesman/chansrv')
-rw-r--r-- | sesman/chansrv/chansrv.c | 4 |
1 files changed, 3 insertions, 1 deletions
diff --git a/sesman/chansrv/chansrv.c b/sesman/chansrv/chansrv.c index af2f6957..29e8c106 100644 --- a/sesman/chansrv/chansrv.c +++ b/sesman/chansrv/chansrv.c @@ -1534,7 +1534,9 @@ main(int argc, char **argv) display_text = g_getenv("DISPLAY"); LOGM((LOG_LEVEL_INFO, "main: DISPLAY env var set to %s", display_text)); - get_display_num_from_display(display_text); + + if (display_text) + get_display_num_from_display(display_text); if (g_display_num == 0) { |