WindowsError: exception: access violation

Sathish S sathish at solitontech.com
Fri Jul 22 00:41:54 EDT 2011


Benjamin thanks for replying. i'm not using the python that comes with
cygwin. Its the regular python 2.7.2
To add more info
I'm opening up a zip file within the DLL. The zip file is located in the
same directory.
arg1 is the file name
arg2 is zip password

Thanks,
Sathish


On Fri, Jul 22, 2011 at 7:47 AM, Benjamin Kaplan
<benjamin.kaplan at case.edu>wrote:

> On Thu, Jul 21, 2011 at 6:42 PM, Sathish S <sathish at solitontech.com>
> wrote:
> > Hi Ppl,
> >
> >  I have been trying to call a C DLL built in GCC with cygwin and Eclipse
> IDE
> > from python. Since this DLL was built using cygwin it had the following
> two
> > DLL's as dependency. cygwin1.dll and cyggcc_s-1.dll
> >
> > I'm calling the cygwin_dll_init method in the cygwin1.dll before
> accessing
> > my DLL. When I call one of the methods within my DLL I get the
> WindowsError:
> > exception: access violation... error
> >
> > the functions prototype is like: int function(char *, char *) I'm calling
> > the function as: DLL = cdll.LoadLibrary (DLL_NAME) print
> > DLL.function(c_char_p("string1"),c_char_p("string2)")
> >
> > This error is not consistent with all the stations. I occurs consistently
> in
> > many XP machines, while in Windows 7, this occurs once in a while. In Win
> 7
> > in starts up a Pythonw.exe process when calling function successfully.
> I'm
> > not sure why this error occurs. Any help ??
> >
>
> An access violation is what is usually referred to as a seg fault. It
> means something isn't getting initialized properly. Are you using a
> Cygwin build of Python? Trying to mix Cygwin with normal Windows
> programs doesn't usually work very well.
> --
> http://mail.python.org/mailman/listinfo/python-list
>
-------------- next part --------------
An HTML attachment was scrubbed...
URL: <http://mail.python.org/pipermail/python-list/attachments/20110722/bc152998/attachment-0001.html>


More information about the Python-list mailing list