diff options
author | Campbell Barton <ideasman42@gmail.com> | 2010-07-03 21:47:06 +0400 |
---|---|---|
committer | Campbell Barton <ideasman42@gmail.com> | 2010-07-03 21:47:06 +0400 |
commit | 80f6102629b746ea520d3ec54aaa6414c669a998 (patch) | |
tree | 8d254cc92120eca8be6ef5b92af7be3c3626f202 /source/blender/python/generic/bgl.c | |
parent | 9a85435e96af9933b282594b6ad8b23ca598d8bc (diff) |
better reporting for file i/o failier, use system error message in more places: Permission Denied, No space left, File not found etc.
- blend load/save uses os message.
- image load gives os message. (remove check for slash at end of line, just let the os report an error)
- python api load image/font/text raise errors with message (was just retuning None for image and font)
- minor edits to py api errors.
Diffstat (limited to 'source/blender/python/generic/bgl.c')
-rw-r--r-- | source/blender/python/generic/bgl.c | 10 |
1 files changed, 5 insertions, 5 deletions
diff --git a/source/blender/python/generic/bgl.c b/source/blender/python/generic/bgl.c index 806b5a5b3ce..ae19db28011 100644 --- a/source/blender/python/generic/bgl.c +++ b/source/blender/python/generic/bgl.c @@ -322,20 +322,20 @@ static int Buffer_ass_item(PyObject *self, int i, PyObject *v) } if (buf->type==GL_BYTE) { - if (!PyArg_Parse(v, "b;Coordinates must be ints", &buf->buf.asbyte[i])) + if (!PyArg_Parse(v, "b:Coordinates must be ints", &buf->buf.asbyte[i])) return -1; } else if (buf->type==GL_SHORT) { - if (!PyArg_Parse(v, "h;Coordinates must be ints", &buf->buf.asshort[i])) + if (!PyArg_Parse(v, "h:Coordinates must be ints", &buf->buf.asshort[i])) return -1; } else if (buf->type==GL_INT) { - if (!PyArg_Parse(v, "i;Coordinates must be ints", &buf->buf.asint[i])) + if (!PyArg_Parse(v, "i:Coordinates must be ints", &buf->buf.asint[i])) return -1; } else if (buf->type==GL_FLOAT) { - if (!PyArg_Parse(v, "f;Coordinates must be floats", &buf->buf.asfloat[i])) + if (!PyArg_Parse(v, "f:Coordinates must be floats", &buf->buf.asfloat[i])) return -1; } else if (buf->type==GL_DOUBLE) { - if (!PyArg_Parse(v, "d;Coordinates must be floats", &buf->buf.asdouble[i])) + if (!PyArg_Parse(v, "d:Coordinates must be floats", &buf->buf.asdouble[i])) return -1; } return 0; |