Thread: Re: [Quickfix-developers] quickfix_api compile errors
Brought to you by:
orenmnero
|
From: <OM...@th...> - 2003-04-23 23:29:56
|
quickfix_api is not ready for use. It is the start of a C api for QF, but is not yet complete. --oren |---------+-----------------------------------------------> | | "John Hollander" | | | <jo...@ma...> | | | Sent by: | | | qui...@li...| | | ceforge.net | | | | | | | | | 04/23/2003 09:37 AM | | | | |---------+-----------------------------------------------> >----------------------------------------------------------------------------------------------| | | | To: "Quickfix \(Development\)" <qui...@li...> | | cc: | | Subject: [Quickfix-developers] quickfix_api compile errors | >----------------------------------------------------------------------------------------------| When attempting to compile the quickfix_api project, I'm getting the following errors: ----------------------------------------------------------------- Compiling... fix_filestore.cpp d:\share\quickfix\src\c\fix_filestore.cpp(58) : error C2660: 'set' : function does not take 1 parameters d:\share\quickfix\src\c\fix_filestore.cpp(65) : error C2664: 'bool __thiscall FIX::MessageStore::get(int,class std::basic_string<char,struct std::char_traits<char>,class std::allocator<char> > &) const' : cannot convert parameter 2 from 'class FIX:: Message' to 'class std::basic_string<char,struct std::char_traits<char>,class std::allocator<char> > &' A reference that is not to 'const' cannot be bound to a non-lvalue d:\share\quickfix\src\c\fix_filestore.cpp(73) : error C2664: 'void __thiscall FIX::MessageStore::get(...) const' : cannot convert parameter 3 ... A reference that is not to 'const' cannot be bound to a non-lvalue fix_memorystore.cpp ... quickfix_api.lib - 6 error(s), 0 warning(s) ----------------------------------------------------------------- The other projects seem to be compiling fine, but this one seems to be trying to reference get and set functions using incorrect, or missing parameters. I can't seem to find any implementation in the MessageStore class for set(*pMessage). Any thoughts? Thanks, John |
|
From: John H. <jo...@ma...> - 2003-04-28 20:16:12
|
Thanks. Could you give me an idea of how far along the api is? Thanks again, John ----- Original Message ----- From: <OM...@th...> To: <jo...@ma...> Cc: "Quickfix (Development)" <qui...@li...>; <qui...@li...> Sent: Wednesday, April 23, 2003 7:29 PM Subject: Re: [Quickfix-developers] quickfix_api compile errors > > quickfix_api is not ready for use. It is the start of a C api for QF, but > is not yet complete. > > --oren > > > > |---------+-----------------------------------------------> > | | "John Hollander" | > | | <jo...@ma...> | > | | Sent by: | > | | qui...@li...| > | | ceforge.net | > | | | > | | | > | | 04/23/2003 09:37 AM | > | | | > |---------+-----------------------------------------------> > >--------------------------------------------------------------------------- -------------------| > | | > | To: "Quickfix \(Development\)" <qui...@li...> | > | cc: | > | Subject: [Quickfix-developers] quickfix_api compile errors | > >--------------------------------------------------------------------------- -------------------| > > > > > When attempting to compile the quickfix_api project, I'm getting the > following errors: > > ----------------------------------------------------------------- > > Compiling... > fix_filestore.cpp > d:\share\quickfix\src\c\fix_filestore.cpp(58) : error C2660: 'set' : > function does not take 1 parameters > d:\share\quickfix\src\c\fix_filestore.cpp(65) : error C2664: 'bool > __thiscall FIX::MessageStore::get(int,class std::basic_string<char,struct > std::char_traits<char>,class std::allocator<char> > &) const' : cannot > convert parameter 2 from 'class FIX:: > Message' to 'class std::basic_string<char,struct > std::char_traits<char>,class std::allocator<char> > &' > A reference that is not to 'const' cannot be bound to a non-lvalue > d:\share\quickfix\src\c\fix_filestore.cpp(73) : error C2664: 'void > __thiscall FIX::MessageStore::get(...) const' : cannot convert parameter 3 > .. > A reference that is not to 'const' cannot be bound to a non-lvalue > fix_memorystore.cpp > .. > quickfix_api.lib - 6 error(s), 0 warning(s) > > ----------------------------------------------------------------- > > The other projects seem to be compiling fine, but this one seems to be > trying to reference get and set functions using incorrect, or missing > parameters. I can't seem to find any implementation in the MessageStore > class for set(*pMessage). Any thoughts? > > Thanks, > > John > > > > > |
|
From: Oren M. <ore...@ya...> - 2003-04-28 20:38:00
|
I did some considerable work on this a month ago. I was able to initiate a fix session and send message (mostly empty). I basically wrapped just enough parts of just enough classes to make this simple prototype possible. Much more work will need to be put in to make it useable in a real system. The priority for this hasn't been very high as most of the demand has been for improving the java API more than anything else. John Hollander <jo...@ma...> wrote:Thanks. Could you give me an idea of how far along the api is? Thanks again, John ----- Original Message ----- From: To: Cc: "Quickfix (Development)" ; Sent: Wednesday, April 23, 2003 7:29 PM Subject: Re: [Quickfix-developers] quickfix_api compile errors > > quickfix_api is not ready for use. It is the start of a C api for QF, but > is not yet complete. > > --oren > > > > |---------+-----------------------------------------------> > | | "John Hollander" | > | | | > | | Sent by: | > | | qui...@li...| > | | ceforge.net | > | | | > | | | > | | 04/23/2003 09:37 AM | > | | | > |---------+-----------------------------------------------> > >--------------------------------------------------------------------------- -------------------| > | | > | To: "Quickfix \(Development\)" | > | cc: | > | Subject: [Quickfix-developers] quickfix_api compile errors | > >--------------------------------------------------------------------------- -------------------| > > > > > When attempting to compile the quickfix_api project, I'm getting the > following errors: > > ----------------------------------------------------------------- > > Compiling... > fix_filestore.cpp > d:\share\quickfix\src\c\fix_filestore.cpp(58) : error C2660: 'set' : > function does not take 1 parameters > d:\share\quickfix\src\c\fix_filestore.cpp(65) : error C2664: 'bool > __thiscall FIX::MessageStore::get(int,class std::basic_string> std::char_traits,class std::allocator > &) const' : cannot > convert parameter 2 from 'class FIX:: > Message' to 'class std::basic_string> std::char_traits,class std::allocator > &' > A reference that is not to 'const' cannot be bound to a non-lvalue > d:\share\quickfix\src\c\fix_filestore.cpp(73) : error C2664: 'void > __thiscall FIX::MessageStore::get(...) const' : cannot convert parameter 3 > .. > A reference that is not to 'const' cannot be bound to a non-lvalue > fix_memorystore.cpp > .. > quickfix_api.lib - 6 error(s), 0 warning(s) > > ----------------------------------------------------------------- > > The other projects seem to be compiling fine, but this one seems to be > trying to reference get and set functions using incorrect, or missing > parameters. I can't seem to find any implementation in the MessageStore > class for set(*pMessage). Any thoughts? > > Thanks, > > John > > > > > ------------------------------------------------------- This sf.net email is sponsored by:ThinkGeek Welcome to geek heaven. http://thinkgeek.com/sf _______________________________________________ Quickfix-developers mailing list Qui...@li... https://lists.sourceforge.net/lists/listinfo/quickfix-developers --------------------------------- Do you Yahoo!? The New Yahoo! Search - Faster. Easier. Bingo. |
|
From: Gene G. <mus...@ya...> - 2003-04-29 14:42:35
|
I have discovered that every TCP/IP connection to my
Linux ThreadedSocketAcceptor based server increases
memory footprint by 4-8K which is not recovered once
the connection closes. After some investigation I have
found that this happens because ThreadedSocketAcceptor
(and possibly other Threaded*) classes create joinable
threads which exit when the socket closes without
either pthread_join or pthread_detach called on them.
On Linux POSIX Threads implementation it is
insufficent to return from joinable thread because
this does not release thread resources back, hence the
leak. pthread_detach has to be used to explicitly
clean-up when joinability is no longer necessary.
On my build I have added the following to Utility.cpp
void thread_detach(int thread)
{
#ifdef _MSC_VER
;
#else
pthread_detach( thread);
#endif
}
and called it here:
void ThreadedSocketAcceptor::removeThread( int s ) {
m_mutex.lock();
thread_detach(m_threads[s]);
m_threads.erase( s );
m_mutex.unlock();
}
This fixed the leak.
Gene
__________________________________
Do you Yahoo!?
The New Yahoo! Search - Faster. Easier. Bingo.
http://search.yahoo.com
|
|
From: Oren M. <ore...@ya...> - 2003-04-29 14:57:10
|
Thanks. This is something I did not know. I'll get
this change into source control.
--- Gene Gorokhovsky <mus...@ya...> wrote:
> I have discovered that every TCP/IP connection to my
> Linux ThreadedSocketAcceptor based server increases
> memory footprint by 4-8K which is not recovered once
> the connection closes. After some investigation I
> have
> found that this happens because
> ThreadedSocketAcceptor
> (and possibly other Threaded*) classes create
> joinable
> threads which exit when the socket closes without
> either pthread_join or pthread_detach called on
> them.
>
> On Linux POSIX Threads implementation it is
> insufficent to return from joinable thread because
> this does not release thread resources back, hence
> the
> leak. pthread_detach has to be used to explicitly
> clean-up when joinability is no longer necessary.
>
> On my build I have added the following to
> Utility.cpp
> void thread_detach(int thread)
> {
> #ifdef _MSC_VER
> ;
> #else
> pthread_detach( thread);
> #endif
> }
>
> and called it here:
>
> void ThreadedSocketAcceptor::removeThread( int s ) {
> m_mutex.lock();
> thread_detach(m_threads[s]);
> m_threads.erase( s );
> m_mutex.unlock();
> }
> This fixed the leak.
>
> Gene
>
> __________________________________
> Do you Yahoo!?
> The New Yahoo! Search - Faster. Easier. Bingo.
> http://search.yahoo.com
__________________________________
Do you Yahoo!?
The New Yahoo! Search - Faster. Easier. Bingo.
http://search.yahoo.com
|