Search found 6 matches

by robif
Wed Oct 26, 2005 4:08 am
Forum: PSP Development
Topic: errno & libc
Replies: 4
Views: 3338

Thanks Jim,
this looks great.

Robert
by robif
Sun Oct 16, 2005 9:43 pm
Forum: PSP Development
Topic: libc opendir freezes PSP
Replies: 7
Views: 5024

It seems, you have been right. I have created this sample: /* * PSP Software Development Kit - http://www.pspdev.org * ----------------------------------------------------------------------- * Licensed under the BSD license, see LICENSE in PSPSDK root for details. * * main.c - Sample to desm...
by robif
Sun Oct 16, 2005 4:11 pm
Forum: PSP Development
Topic: libc opendir freezes PSP
Replies: 7
Views: 5024

Re: opendir example

Example where call to opendir froze was this function: static PyObject* PyPSP_listdir(PyObject *self, PyObject *args) { char *path; DIR* dirp; struct dirent* ent; PyObject* ret; if (!PyArg_ParseTuple(args, "s:listdir", &path)&...
by robif
Sun Oct 16, 2005 5:52 am
Forum: PSP Development
Topic: libc opendir freezes PSP
Replies: 7
Views: 5024

libc opendir freezes PSP

It seems that memory that is allocated for DIR structure in opendir() should be initialized to zero, as current implementation causes PSP to freeze. Changing dirp = (DIR *)malloc(sizeof(DIR)); with dirp = (DIR *)calloc(sizeof&am...
by robif
Sun Oct 16, 2005 5:18 am
Forum: PSP Development
Topic: errno & libc
Replies: 4
Views: 3338

Re: Lookup

I agree that it would be better to change newlib's error codes than to perform lookup, as there
are only few values (that i know of) that differ.

Regarding thread safety i'm not sure either. Currently when i compile thread code into Python
PSP seems to freeze. This could be for many reasons...
by robif
Sun Oct 16, 2005 12:20 am
Forum: PSP Development
Topic: errno & libc
Replies: 4
Views: 3338

errno & libc

Hi everybody, first i would like to say hello as i'm new here (been lurking for some time). Recently i started to mess with Python port and noticed that functions in libc do not set errno when sce* functions fail. I think this is not ok as it may break programs that expect non zero value in errno wh...