Skip to content

Commit

Permalink
Zero-initialize the EXPLICIT_ACCESSW objects.
Browse files Browse the repository at this point in the history
This may have fixed a segfault in winpty_open.

Fixes #80
  • Loading branch information
rprichard committed Jun 1, 2016
1 parent 1b439b5 commit cfb0728
Show file tree
Hide file tree
Showing 4 changed files with 12 additions and 4 deletions.
2 changes: 1 addition & 1 deletion Makefile
Original file line number Diff line number Diff line change
Expand Up @@ -125,7 +125,7 @@ install-doc :
mkdir -p $(PREFIX)/share/doc/winpty
install -m 644 -p LICENSE $(PREFIX)/share/doc/winpty
install -m 644 -p README.md $(PREFIX)/share/doc/winpty
install -m 644 -p RELEASES.md $(PREFIX)/share/doc/winpty
install -m 644 -p RELEASES*.md $(PREFIX)/share/doc/winpty

.PHONY : install-include
install-include :
Expand Down
8 changes: 8 additions & 0 deletions RELEASES-0.3.md
Original file line number Diff line number Diff line change
@@ -0,0 +1,8 @@
# Version 0.3.1 (2016-05-31)

This version was released solely to fix a possible crashing bug in 0.3.0.

Bug fixes:

* Fixed an uninitialized memory bug that could have crashed winpty.
[#80](https://github.com/rprichard/winpty/issues/80)
2 changes: 1 addition & 1 deletion VERSION.txt
Original file line number Diff line number Diff line change
@@ -1 +1 @@
0.3.0
0.3.1
4 changes: 2 additions & 2 deletions src/shared/WindowsSecurity.cc
Original file line number Diff line number Diff line change
Expand Up @@ -218,7 +218,7 @@ createPipeSecurityDescriptorOwnerFullControl() {
Sid localSystem;
Sid builtinAdmins;
Sid owner;
std::array<EXPLICIT_ACCESSW, 3> daclEntries;
std::array<EXPLICIT_ACCESSW, 3> daclEntries = {};
Acl dacl;
SecurityDescriptor value;
};
Expand Down Expand Up @@ -258,7 +258,7 @@ createPipeSecurityDescriptorOwnerFullControlEveryoneWrite() {
Sid builtinAdmins;
Sid owner;
Sid everyone;
std::array<EXPLICIT_ACCESSW, 4> daclEntries;
std::array<EXPLICIT_ACCESSW, 4> daclEntries = {};
Acl dacl;
SecurityDescriptor value;
};
Expand Down

0 comments on commit cfb0728

Please sign in to comment.