[Patch #783050 from Patrick Lynch] The emulation of forkpty() is incorrect;
the master should close the slave fd.

Added a test to test_pty.py that reads from the master_fd after doing
a pty.fork(); without the fix it hangs forever instead of raising an
exception.  (<crossing fingers for the buildbots>)

Backport from trunk rev. 53146.
diff --git a/Misc/NEWS b/Misc/NEWS
index 6036a2d..ff8a082 100644
--- a/Misc/NEWS
+++ b/Misc/NEWS
@@ -154,6 +154,9 @@
 Library
 -------
 
+- Patch #783050: the pty.fork() function now closes the slave fd
+  correctly.
+
 - Patch #1638243: the compiler package is now able to correctly compile
   a with statement; previously, executing code containing a with statement
   compiled by the compiler package crashed the interpreter.