|
How to keep the right order of what is sent?
|
|
|
|
|
Have a queue that is accessible from your threads and put the packets to be sent in the queue.
You can poll the queue with a timer to read packets from the queue and send them in the order they were written to the queue.
Don't forget that the queue has to be synchronized with e.g. a critical section in order to prevent data corruption.
Hope this helps
--
Roger
It's supposed to be hard, otherwise anybody could do it!
Regarding CodeProject: "resistance is pointless; you will be assimilated"
|
|
|
|
|
Im my coding i run the aplication by pressing F5,the application get executed and working properly.When i close my application the dubug assertion error is occured.The error is
"Damage:after norml Block(#2523) at 0x00d70ff8"
like this..wats the meaning for this.
|
|
|
|
|
This occurs while using delete to free an allocated block of memory. Mainly because you haven't allocated sufficient amount of memory.
Step through the code to find out where this happens.
An e.g. to reproduce this error
PCHAR pMsg = "Nibu babu thomas is a good boy! OMG!";
PCHAR pCh = new CHAR[ strlen( msg ) ];
strcpy( pCh, pMsg );
delete pCh;
PCHAR pCh = new CHAR[ strlen(msg) <code>+ 1</code> ];
strcpy( pCh, pMsg );
delete pCh;
Nibu thomas
A Developer
Programming tips[^] My site[^]
|
|
|
|
|
There are other causes. In general it means the heap has been corrupted. There are many ways the heap can become corrupted. For example you may allocate some memory but write beyond the end or before the beginning and thus corrupt the CRT's book keeping data.
Steve
|
|
|
|
|
Stephen Hewitt wrote: example you may allocate some memory but write beyond the end
Exactly. That is what is happening in the sample that is given, strcpy puts a NULL char just after the last char which in fact is writing beyond the end.
Nibu thomas
A Developer
Programming tips[^] My site[^]
|
|
|
|
|
Hello everyone?
I wanna display data which is stored in database, as like 3D using OpenGL or Direct3D.
How can I solve this? You have any idea about this???
|
|
|
|
|
Can you be more specific
what data? picture /text?
whitesky
|
|
|
|
|
Could any one help me? I've been having probelms in an animation project and i do not really have an idea on how to render images n stuff. These are the requirements. A person should walk into a car, drive through a stree, leave the car and enter into one of the buildings. If there's anyone out there, please assist.
Regards.
Reuben K.
|
|
|
|
|
This project is VC or 3dMax or MAYA
if isnt VC then
maybe it is some helpful to you (i think a little difficult)
like this of course this isnt perfect anyway
1-you need to poser for personal and you can declare walk in poser
2- import this file to max or maya (of course you need to frames save for example 1 2 3 4,....20)
3- import to maya frame to frame and then assign one maretial to your object
4- you need to declare key frame (for example 3)
5- you need to one motion path
6- i think you need to IK for body (neck,chest,head,...)
whitesky
|
|
|
|
|
WhiteSky wrote: like this of course this isnt perfect anyway
1-you need to poser for personal and you can declare walk in poser
2- import this file to max or maya (of course you need to frames save for example 1 2 3 4,....20)
3- import to maya frame to frame and then assign one maretial to your object
4- you need to declare key frame (for example 3)
5- you need to one motion path
6- i think you need to IK for body (neck,chest,head,...)
Easier said than done!
Nibu thomas
A Developer
Programming tips[^] My site[^]
|
|
|
|
|
yes but its possible
whitesky
|
|
|
|
|
|
not problem use 3dMax it supports poser and he can usign 3dMax i think its easy than MAYA
whitesky
|
|
|
|
|
I am using VC++ 6 with opengl but am a newbie. I'd really appreciate if you sent me some source code for study.
|
|
|
|
|
if you want learning Opengl I suggest use MSDN examples (CUBE) i think its good and
you can find examples in codeproject but if you want to create your example
i think create this project is easy in graphic programs instead visuall c
whitesky
|
|
|
|
|
How can I use a FlexGrid Control while using DLL's
Thank You
|
|
|
|
|
How to swape two strings without using temporary variable. can u help me in code this plz.
|
|
|
|
|
I am not going to write code for you.
you can use this simple logic and write your own code.
A := A + B; // aa+bb
B := A - B; // aa+bb-bb = aa
A := A - B; // aa+bb-aa = bb
Regards
Anil
-- modified at 2:10 Monday 29th May, 2006
|
|
|
|
|
this logic working for integers only, While Applying to strings its giving many errors.
|
|
|
|
|
Hello
This is a logic. how can it give you error
You must not do a + b for string unless its CString.
"aaaa" + "bbbb" what I mean is "aaaabbbb" not the mathmatic part of it.
Any way I think the logic is correct check your code.I can give you code using the logic , but you have got the code done from WhiteSky using different method.
Regards
Anil
-- modified at 2:52 Monday 29th May, 2006
|
|
|
|
|
Hai Anil i got the correct logic regardin this.Anyway Thank u for ur help.
|
|
|
|
|
Each string consists of characters. The characters are easily represented as integers. Need we say more?
Cheers,
Sebastian
--
Contra vim mortem non est medicamen in hortem.
|
|
|
|
|
i guess homework anyway
i test with these examples and it work
<code>
// str1="Is this true";
// str2="i dont know";
// str1="string 1 > string 2";
// str2="yes";
// str1="Inverse";
// str2="String2>String1";
// str1="1";
// str2="1 2 3";
CString str1,str2;
str1="3 2 1";
str2="1 2 3";
int Index1,Index2;
Index1=str1.GetLength();
Index2=str2.GetLength();
if(Index1<Index2)
for(int i=Index1;str1.GetLength()<Index2;i++)
str1.Insert(str1.GetLength(),' ');
else
for(int i=Index2;str2.GetLength()<Index1;i++)
str2.Insert(str2.GetLength(),' ');
for(int i=0;i<str1.GetLength();i++)
{
str2.Insert(str2.GetLength(),str1.Mid(0,1));
str1.Delete(0,1);
str1.Insert(str1.GetLength(),str2.Mid(0,1));
str2.Delete(0,1);
}
MessageBox(str1);
MessageBox(str2);
</code>
|
|
|
|
|
Thank u , iam going to homework on it.
|
|
|
|