From mboxrd@z Thu Jan 1 00:00:00 1970 Return-Path: Received: (qmail 18052 invoked by alias); 17 Dec 2004 05:30:59 -0000 Mailing-List: contact pthreads-win32-help@sources.redhat.com; run by ezmlm Precedence: bulk List-Subscribe: List-Archive: List-Post: List-Help: , Sender: pthreads-win32-owner@sources.redhat.com Received: (qmail 18040 invoked from network); 17 Dec 2004 05:30:53 -0000 Received: from unknown (HELO serrano.cc.columbia.edu) (128.59.206.20) by sourceware.org with SMTP; 17 Dec 2004 05:30:53 -0000 Received: from columbiasiwh8w (dyn-ec-194-153.dyn.columbia.edu [160.39.194.153]) (user=ds708 mech=LOGIN bits=0) by serrano.cc.columbia.edu (8.13.0/8.13.0) with ESMTP id iBH5UrNu026883 (version=TLSv1/SSLv3 cipher=RC4-MD5 bits=128 verify=NOT) for ; Fri, 17 Dec 2004 00:30:53 -0500 (EST) Message-Id: <200412170530.iBH5UrNu026883@serrano.cc.columbia.edu> From: "Daniel Starin" To: Subject: RE: using mutex_lock / unlock with VS .NET 2003 Date: Fri, 17 Dec 2004 05:30:00 -0000 MIME-Version: 1.0 Content-Type: text/plain; charset="US-ASCII" Content-Transfer-Encoding: 7bit In-Reply-To: <200412170416.iBH4GPiE017610@serrano.cc.columbia.edu> X-No-Spam-Score: Local X-SW-Source: 2004/txt/msg00170.txt.bz2 Ahhh solved my own problem... had to turn off the "Use Managed Extensions" configuration option... anyone care to explain why? Dan -----Original Message----- From: pthreads-win32-owner@sources.redhat.com [mailto:pthreads-win32-owner@sources.redhat.com] On Behalf Of Daniel Starin Sent: Thursday, December 16, 2004 11:17 PM To: pthreads-win32@sources.redhat.com Subject: using mutex_lock / unlock with VS .NET 2003 Hi, The following code compiles and links but fails with the following exception when I run the .exe. (I link to pthreadVC1.lib) Unhandled Exception: System.TypeLoadException: Could not load type pthread_mutex_t_ from assembly pthreadtest, Version=0.0.0.0, Culture=neutral, PublicKeyToken=null. at main() Any suggestions?? Thanks, Dan ------------------------------------- #include #include "winsock2.h" #include pthread_mutex_t mutex = PTHREAD_MUTEX_INITIALIZER; int main () { pthread_mutex_lock(&mutex); printf("hello"); pthread_mutex_unlock(&mutex); return 0; }