|
skydivetom wrote: (under Homeland Security).
What does that mean?
|
|
|
|
|
skydivetom wrote: Homeland Security
skydivetom wrote: PLEASE HELP!
Why do I suddenly feel not so safe anymore?
|
|
|
|
|
Actually, you've probably got nothing to worry about. It's much like the safest place to be when a new driver is on the road is in the middle of the road itself, or the safest place to be when out with a new hunter is in front of the target.
"Normal is getting dressed in clothes that you buy for work and driving through traffic in a car that you are still paying for, in order to get to the job you need to pay for the clothes and the car and the house you leave vacant all day so you can afford to live in it." - Ellen Goodman
"To have a respect for ourselves guides our morals; to have deference for others governs our manners." - Laurence Sterne
|
|
|
|
|
Hi, how can i build a program to monitor the registery modifications (hooking advapi.dll)
Hayder Yousif
|
|
|
|
|
I don't know but Microsoft's regmon.exe application manages it no problem. As they're no longer allowed to hide private APIs for their own use, at least in Europe, you could try to find out how regmon works. Hooking ADVAPI sounds plausible but my guess is there's a better way.
Nothing is exactly what it seems but everything with seems can be unpicked.
|
|
|
|
|
RegNotifyChangeKeyValue
...cmk
The idea that I can be presented with a problem, set out to logically solve it with the tools at hand, and wind up with a program that could not be legally used because someone else followed the same logical steps some years ago and filed for a patent on it is horrifying.
- John Carmack
|
|
|
|
|
|
HAve a look at [^].
If the Lord God Almighty had consulted me before embarking upon the Creation, I would have recommended something simpler.
-- Alfonso the Wise, 13th Century King of Castile.
|
|
|
|
|
Dear all,
Could you help me giving a sample of a function which return bitset (Standar Template Library). Please reply as soon as possible. I am waiting...
Thanks.
Regards,
Ian
|
|
|
|
|
There's documentation for this, for instance [^].
If the Lord God Almighty had consulted me before embarking upon the Creation, I would have recommended something simpler.
-- Alfonso the Wise, 13th Century King of Castile.
|
|
|
|
|
std::bitset<8>& CMyClass::foo() const {
return m_bitset;
}
|
|
|
|
|
I want to Print An Image Buffer(640*480) in MFC dialog application.
I can print but, size of Printed Image is not (640*480).
How can I solve the problem? Probably in mapping Problem.
I used :
void PMCToolDlg::OnPrepareDC(CDC* pDC, CPrintInfo* pInfo)
{
if (pDC->IsPrinting())
{
pDC->SetMapMode(MM_ISOTROPIC);
pDC->SetViewportExt(7, 7);
pDC->SetWindowExt(1, 1);
pDC->SetViewportOrg(0,0);
}
}
Thannks in Adance,
Mazhar
|
|
|
|
|
And where are you creating the compatible bitmap to the equivalent size of your dimensions in that mappin mode?
Greetings.
--------
M.D.V.
If something has a solution... Why do we have to worry about?. If it has no solution... For what reason do we have to worry about?
Help me to understand what I'm saying, and I'll explain it better to you
|
|
|
|
|
I see one problem immediately...
From the docs:
"When MM_ISOTROPIC mode is set, an application must call the SetWindowExtEx function before calling SetViewportExtEx"
mazhar_cse wrote: size of Printed Image is not (640*480).
Assuming you get the DC set up properly, and you're not stretching the image
when you render it to the print DC, the resulting image dimensions should be
4480 x 3360.
As far as the size on the printed page - this could be anything.
You haven't taken resolution into consideration here.
Mark
Mark Salsbery
Microsoft MVP - Visual C++
|
|
|
|
|
what we use to handle exceptions in Macintosh programming (xcodeproject)
b'se try and catch(...) never work for MAC. They never caught any exception
Manoj Kumar Chauhan
|
|
|
|
|
Exception handling is a cooperative effort between the OS, the C Library, code injected at compile time by the compiler and your code. One of these is not doing its job. Your next step probably needs to be to find out which. Make sure that C++ exception handling or SEH or both are enabled in your project, that should take care of the Compiler. Make sure if you need SEH that your OS supports it. Make sure you're using a C Library like MSVCRT that has the necessary support in it for Exception handling and if necessary rebuild it with different options to support your OS and the exception handling you need. If all this is good you should be able to debug the exception handling process itself, at least at the assembler level and get some idea of what is and isn't working. All sort of things like switching off Thread Local Storage support can break exception handling, even mixing code compiled on different Visual Studio versions. If your stack works differently on the MAC then stack unwinding is different, even processor register map differences could in theory break an implementation. EH is still a black art I'm afraid and you may need to get your hands dirty if your root problem is not straight forward. Good Luck
Nothing is exactly what it seems but everything with seems can be unpicked.
|
|
|
|
|
Hi,
my compiler is gcc and environment is xcode
I have enabled c++ exception, c++ runtime type, objective-c exceptions and statics are thread safe. But still the exception is not catch. What is SEH? I did not find it.
Manoj Kumar Chauhan
|
|
|
|
|
I know very little about gcc or and even less about exception handling with gcc or xcode so my advice may not be good. Still I would stick to strict ANSI C++ exception handling rules as that is what gcc is most likely to support. You can forget about SEH (Structured Exception Handling) it's an Operating System exception mechanism which may not be available on the MAC and almost certainly not under gcc.
What will work under gcc pretty much anywhere are Standard Library exceptions. Have a look at std::exception and derived classes to see if you can get any examples to work. If you can get a std::exeception to work you can debug through what it does and see how it uses primary exception handling internally. This should give you what you need even if you can't use std::exception directly. Good luck.
Nothing is exactly what it seems but everything with seems can be unpicked.
|
|
|
|
|
Ok Thanks for this info. I think there is some problem with gcc compiler or some special setting which i dont know. I create a new program just to handle divide by zero exception. In project setting i enabled c/c++ exception. In prepocessor macro following line was written
_APPLE_C_SOURCE _NO_EXCEPTION
it prevents the exception. So i removed this line. Also in my program i add following
#undef _NO_NAMESPACE
#undef _NO_EXCEPTION
#undef _NO_TEMPLATE
But after this exception is not caught. Program is simple like
int main(void)
{
try{
vector<int> a;
a.push_back(1);
a.push_back(2);
vector<int> b;
b.push_back(0);
b.push_back(0);
for(int i = 0; i <a.size();i++)
{
="" if(a[i]="" b[i])
="" a[i]="b[i];
" }
="" catch(...)
="" printf("exception="" caught");
="" }
}
i="" think="" there="" is="" something="" which="" should="" be="" define="" in="" preprocessor.=""
<div="" class="ForumSig">Manoj Kumar Chauhan
|
|
|
|
|
MKUser wrote: I think there is something which should be define in preprocessor.
You may well be right. I would be interested to know what it is. It is also worth noting that on some system math exceptions are handled separately. A 'divide by zero' exception may be considered a special floating point exception and be handled by the math library. Check this out if you are using glibc or stdlibc. It's possible that your exception is being handled somewhere but being filtered out before reaching your handler code.
Nothing is exactly what it seems but everything with seems can be unpicked.
|
|
|
|
|
I'm not using stdlib or glib. If if i use them then how should i catch the exception. The problem is i have tried everything to catch the exception but it's not catch.
I also tried to use ObjC/ObjC++ exception and synchronization support but i got error to use them.
Manoj Kumar Chauhan
|
|
|
|
|
MKUser wrote: I'm not using stdlib or glib
That could be the issue. If you use stdlib youd write catch( std::exception ){} and that would catch all the standard library exceptions because they all derive from std::exception. glibc might actually be required for exception handling with GCC C++ compiler to work and this could be the problem. In this case standard C++ exception handling is all you'd need catch(...) syntax might work and I think finally is supported you'd need to check the glibc and GCC docs. ObjC/C++ is an entirely different animal about which I know almost nothing so I won't comment on that except to say that it isn't needed fro C++ exception handling. GCC switches and make settings is where I'd look to enable it but I don't the details on either. I'm just starting to try to get into that myself.
Nothing is exactly what it seems but everything with seems can be unpicked.
|
|
|
|
|
Hello,
I am making an application in which i want buffer to store data.
But i dont know what will be the size of the data at run time.
so how can i initialize that buffer?
Right now i am using HeapAlloc , it works fine but the problem is that when i am destroying the Object then also it is not freeing up the memory. It frees memory when i am closing the application.
So, anybody know how can i solve this problem?
Manish Patel
|
|
|
|
|
use the std::string if u r size not defined
|
|
|
|
|
But std::string will end with NULL, but i want NULL as a char in buffer.
Thanks
Manish Patel
|
|
|
|