]> granicus.if.org Git - python/commitdiff
Don't accept null bytes in the key.
authorGuido van Rossum <guido@python.org>
Mon, 10 Jun 2002 19:46:18 +0000 (19:46 +0000)
committerGuido van Rossum <guido@python.org>
Mon, 10 Jun 2002 19:46:18 +0000 (19:46 +0000)
Modules/rotormodule.c

index ea91af01bce7091f882e23d36fba3a7aac28246a..0377832918465cb6e71ca1bbd19161a459487ba0 100644 (file)
@@ -597,10 +597,9 @@ rotor_rotor(PyObject *self, PyObject *args)
 {
        Rotorobj *r;
        char *string;
-       int len;
        int num_rotors = 6;
 
-       if (!PyArg_ParseTuple(args, "s#|i:newrotor", &string, &len, &num_rotors))
+       if (!PyArg_ParseTuple(args, "s|i:newrotor", &string, &num_rotors))
                return NULL;
 
        r = rotorobj_new(num_rotors, string);