Ok some thoughts on the matter:
- Do you really need to use the C interface, which is depricated and asks you to keep track of all pointer related problems yourself? If not, switch to the more newer C++ API and see many of your problems get solved rather quickly.
- Any reason why you would want to use openCV2.4.4? The new release 2.4.5 has many bug fixes, this could be one of them and it could already be solved quite fast. Switch to latest stable release!
- 9 chances out of 10, your problem is related to not reading in the correct xml model. Don't use any relative paths before you know an absolete path is working. So call the SVM->load("D:/SVM.xml"); to make sure this doesn't create your problems.
- Try to avoid using SVM as variable name, since it is actually also a function. Use something like my_svm instead, in order to not mix both up.
Change this and report back please!