access-violation

AccessViolationException in Delphi - impossible (check it, unbelievable…)

末鹿安然 提交于 2019-12-13 09:55:03
问题 Delphi XE. Windows 7. There is a function (please see a code below) or I:=0 that causes an AV error in a big project. There is no the error with the same function in a new project!!! I deleted everything from the big project, and I left only a button and that function. It still causes the error... A line with the error: if ISAeroEnabled then // this line is a cause i:=0; // or this line I set breakpoints everywhere (I checked the whole function, I set breakpoints on EACH LINE -> no errors in

Why is there an access violation on connecting to MongoDB from C++?

允我心安 提交于 2019-12-13 09:00:48
问题 When I try to run this little piece of code #include <iostream> #include <bsoncxx/builder/stream/document.hpp> #include <bsoncxx/json.hpp> #include <mongocxx/client.hpp> #include <mongocxx/instance.hpp> int main(int argc, char **argv) { mongocxx::client client{mongocxx::uri{}}; mongocxx::database db = client["xyz"]; std::cout << "Connected to xyz." << std::endl; } I always get this warning Exception thrown at 0x00007FFF7815F1FD (libmongoc-1.0.dll) in Test.exe: 0xC0000005: Access violation

c# changing method's pointers .NET 3.5

自闭症网瘾萝莉.ら 提交于 2019-12-13 08:48:58
问题 I am trying to replace a method in a plugin loader(Like Bukkit for Minecraft) during run-time. I cannot modify the assembly file directly in this instance. The whole purpose is to be able to tell when the methods are being called. And cancel them if necessary. Once my plugin is loaded I run the following code: public static void PluginLoaded() { replace(); } public static void replace() { MethodInfo oldMethod, newMethod; oldMethod = typeof(<other assembly>).GetMethod("<method name>",

Recover From Access Violation Exception

笑着哭i 提交于 2019-12-13 06:17:57
问题 I am using EZTwain (an unmanaged dll) to process some PDF's. I am aware it can only read PDF's that it has created. Unfortunately in the real world it is encountering PDFs which have been created by other libraries. This causes it to fail and throw an AccessViolationException. This in itself is not a huge problem as my C# app continues on its way. Unfortunately when it next comes to this file and tries to reprocess it, it is still locked. Presumably EZTwain is still loaded...in what state i

AccessViolationException when using C++ DLL from C#

廉价感情. 提交于 2019-12-13 04:46:51
问题 I have a C++ DLL for use from C#. I have a function which takes a string passed to it, and I have those set on the C++ function parameters as const char * like so: int __stdcall extract_all_frames(const char* szDestination, float scaleFactor) The main body of this function is copied directly from a working FFmpeg example function so I'm almost certain the problem isn't there. I feel like the problem is in this modification I made to it: //Open file char szFilename[32]; sprintf_s(szFilename,

Error Delphi XE2 - Exception class $C00000005

好久不见. 提交于 2019-12-13 03:57:53
问题 I am getting this error will debugging a project, which used to be in Delphi 7 and I have been upgrading to Delphi XE2, the same error happens in several methods. First chance exception at $006DC660. Exception class $C0000005 with message 'access violation at 0x006dc660 read of address 0xffffffff' This is one of the methods: PFI = ^TFI; TFI = record Id : TToken; Name : TName; Parameters : string; end; function TListFI.IsIn(S: PChar): PFI; function SearchName2(Item: PFI):Boolean; var N1, N2:

Very strange error in my app from component

ぃ、小莉子 提交于 2019-12-13 03:38:44
问题 Ok my application does everything that is it suppeded to do and it does the same thing every time so its not as if testing was gone be that much trouble. it crashes "somtimes" not always. it does this when i hover the mouse over a file in the open file dialog i have recently outputted. not instantly it waits about half second to a second, and i know that is when the openfiledialog brings up data such as file size and when it was created and what type of document it is..(standard)mouse hover

Conditional define to suppress IDE interception of Exceptions in Delphi 6 Pro?

天大地大妈咪最大 提交于 2019-12-12 22:17:07
问题 I know I can use the IDE settings in Delphi Pro 6 to stop the IDE from intercepting and handling Delphi Exceptions (stopping the program and entering Debug mode), but unfortunately that turns off that handling for all Exceptions. The Access Violation Exception is happening in a DLL that I don't have the source code for. I was wondering if there is a conditional symbol I don't know about that I could define/undefine around the offending code block so at least I could turn off Exception

C++: Libcurl curl_easy_init() gives an access violation error and crashes the program

守給你的承諾、 提交于 2019-12-12 14:22:58
问题 I'm trying to use libcurl with a program I'm making, but I'm having some problems with it. So far I've only tried the examples from libcurl's website, but they crash as soon as the program gets to the curl initialization. My current code: #include <iostream> #include <curl/curl.h> int main(int argc, char *argv[]) { CURL *curl; CURLcode res; curl = curl_easy_init(); if(curl) { curl_easy_setopt(curl, CURLOPT_URL, "http://garrysmod.fi/"); res = curl_easy_perform(curl); curl_easy_cleanup(curl); }

'Access violation' when running application through Visual Studio

可紊 提交于 2019-12-12 13:20:24
问题 When I run my command-line application from within Visual Studio, one command always fails with below error: The program '[7316] MyProgram.vshost.exe' has exited with code -1073741819 (0xc0000005) 'Access violation'. When I debug the code, this happens after the last execute line. Meaning the application performs it's function correctly but then crashes. When I build the project and run the exe file in the command-line I get no error and it works fine. The project uses a 3rd party dll which