Issue #9277: Struct module: standard bool packing was incorrect if
char is unsigned.  Thanks Stefan Krah for the patch.
diff --git a/Modules/_struct.c b/Modules/_struct.c
index b5f18a9..d55ce0f 100644
--- a/Modules/_struct.c
+++ b/Modules/_struct.c
@@ -867,11 +867,11 @@
 static int
 bp_bool(char *p, PyObject *v, const formatdef *f)
 {
-    char y;
+    int y;
     y = PyObject_IsTrue(v);
     if (y < 0)
         return -1;
-    memcpy(p, (char *)&y, sizeof y);
+    *p = (char)y;
     return 0;
 }