Hello Gabriel,

I just recently discovered that struct.pack does return a string. Everything
works fine now. Thanks for the heads up!

static PyObject *
sendMessage(PyObject *self, PyObject *args)
{
  char *msg = "";
  int len;
  if (!PyArg_ParseTuple(args, "s#", &msg, &len))
    return NULL;
  ret = sctp_sendmsg(connSock, msg, len, 0, 0, 0x03000000, 0, 0x01, 0, 0);
  return Py_BuildValue("l", ret);
}

----
Alvin Delagon
-- 
http://mail.python.org/mailman/listinfo/python-list

Reply via email to