Article View: fr.comp.os.ms-windows.programmation
Article #24Re: Help !! Prog C++ pour connection MYSQL
From: Laurent Oget
Date: Mon, 18 Mar 2002 19:15
Date: Mon, 18 Mar 2002 19:15
37 lines
2527 bytes
2527 bytes
Makmaze <makmaze@invalid.com> writes: > > Je fait que �a. En fait j'ai trouv� qu'un exemple d'utilisation de > cette DLL, cod� en C qui n'utilise qu' une fonction main. Si je fait > pareil avec une seule fonction, l� �a ne plante pas (mais c'est pas ce > que je cherche � faire ). Si si b�bugue mon programme je vois qu'il > plante qu'en je sort de la premi�re fonction qui c'est servie de la > DLL... > au hasard, as tu alloue la memoire necessaire a l'objet MYSQL? mysql_init() a un comportement un peu non intuitif: MYSQL *mysql_init(MYSQL *mysql) Allocates or initializes a MYSQL object suitable for mysql_real_connect(). If mysql is a NULL pointer, the function allocates, initializes, and returns a new object. Otherwise the object is initialized and the address of the object is returned. If mysql_init() allocates a new object, it will be freed when mysql_close() is called to close the connection. ecrire MYSQL* dbh; mysql_init(dbh); conduit a un comportement indefini...... -- Laurent Oget, Ph.D. laurent@oget.net http://oget.net Senior Engineer Zvolve Systems Inc http://zvolve.com Chercheur Associ� Liafa http://liafa.jussieu.fr
Technical Details
Message-ID:
<7ladt58z6v.fsf@zvolve.com>Path:
arc1-ca.pugleaf.net!archiver1.google.com!news1.google.com!newsfeed.stanford.edu!canoe.uoregon.edu!logbridge.uoregon.edu!sunqbc.risq.qc.ca!falcon.america.net!eagle.america.net.POSTED!not-for-mailReferences:
<m21a9ucnc6bo98evnh2m29emgnb7ik2em6@4ax.com> <3c959f9c$0$23196$626a54ce@news.free.fr> <17kb9u4nsu772j9em8g2ja11qusc0akdt0@4ax.com> <3c95d72b$0$23189$626a54ce@news.free.fr> <3qsb9u8abe92hhl66b9a8llb6tu6tub114@4ax.com>Show Full Headers
Complete Article Headers
X-Google-Language: FRENCH,ASCII X-Google-Thread: ffbfc,fb5b11797bbb0e9a X-Google-Attributes: gidffbfc,public X-Google-Thread: 1053e6,fb5b11797bbb0e9a X-Google-Attributes: gid1053e6,public X-Google-Thread: fdcad,fb5b11797bbb0e9a X-Google-Attributes: gidfdcad,public X-Google-ArrivalTime: 2002-03-18 11:15:48 PST Path: arc1-ca.pugleaf.net!archiver1.google.com!news1.google.com!newsfeed.stanford.edu!canoe.uoregon.edu!logbridge.uoregon.edu!sunqbc.risq.qc.ca!falcon.america.net!eagle.america.net.POSTED!not-for-mail Sender: loget@zvisws02 Newsgroups: fr.comp.os.ms-windows.programmation,fr.comp.lang.c++,fr.comp.applications.sgbd Subject: Re: Help !! Prog C++ pour connection MYSQL References: <m21a9ucnc6bo98evnh2m29emgnb7ik2em6@4ax.com> <3c959f9c$0$23196$626a54ce@news.free.fr> <17kb9u4nsu772j9em8g2ja11qusc0akdt0@4ax.com> <3c95d72b$0$23189$626a54ce@news.free.fr> <3qsb9u8abe92hhl66b9a8llb6tu6tub114@4ax.com> From: Laurent Oget <loget@zvolve.com> Message-ID: <7ladt58z6v.fsf@zvolve.com> Lines: 37 X-Newsreader: Gnus v5.7/Emacs 20.7 Date: 18 Mar 2002 14:15:36 -0500 NNTP-Posting-Host: 216.3.26.18 X-Trace: eagle.america.net 1016478942 216.3.26.18 (Mon, 18 Mar 2002 14:15:42 EST) NNTP-Posting-Date: Mon, 18 Mar 2002 14:15:42 EST Organization: 24hoursupport.com