<termios.h>: add two new POSIX functions.

musl already added tcgetwinsize() and tcsetwinsize(), but I didn't
notice.

Trivial single-line inlines added to a header that's already written
that way.

Test: treehugger
Change-Id: Iac95ea6a89f3872025c512f7e61987b81d0aafa7
diff --git a/libc/include/termios.h b/libc/include/termios.h
index 853b4eb..7abff5d 100644
--- a/libc/include/termios.h
+++ b/libc/include/termios.h
@@ -149,6 +149,25 @@
 
 #endif
 
+#if __ANDROID_API__ >= 35
+// These two functions were POSIX Issue 8 additions that we can also trivially
+// implement as inlines for older OS version.
+
+/**
+ * tcgetwinsize(3) gets the window size of the given terminal.
+ *
+ * Returns 0 on success and returns -1 and sets `errno` on failure.
+ */
+int tcgetwinsize(int __fd, struct winsize* _Nonnull __size);
+
+/**
+ * tcsetwinsize(3) sets the window size of the given terminal.
+ *
+ * Returns 0 on success and returns -1 and sets `errno` on failure.
+ */
+int tcsetwinsize(int __fd, const struct winsize* _Nonnull __size);
+#endif
+
 __END_DECLS
 
 #include <android/legacy_termios_inlines.h>