• Global community
    • Language:
      • Deutsch
      • English
      • Español
      • Français
      • Português
  • 日本語コミュニティ
    Dedicated community for Japanese speakers
  • 한국 커뮤니티
    Dedicated community for Korean speakers
Exit
0

Plugin crashing during initialization on ID CC 2014

Community Beginner ,
Jan 27, 2015 Jan 27, 2015

Copy link to clipboard

Copied

Hello everybody,

I ported a plugin from Mac OS 10.8 to Windows 8.

It compiles correctly but at boot InDesign CC 2014 gets an exception in CrtIsValidHeapPointer.

The plugin uses std::string a lot. Is that a problem on Windows?

Thank you for any help!

Luca Severini

TOPICS
SDK

Views

489

Translate

Translate

Report

Report
Community guidelines
Be kind and respectful, give credit to the original source of content, and search for duplicates before posting. Learn more
community guidelines
Community Expert ,
Jan 27, 2015 Jan 27, 2015

Copy link to clipboard

Copied

If this plugin works fine on MAC then it seems to be a problem in Windows project setting. In order to resolve it, i would advice you to cross check the project setting with a sdk supplied sample. Pay special attention to the compiler and the linker settings, seems some flag is not set or set to a wrong value.

Thanks

Manan

Votes

Translate

Translate

Report

Report
Community guidelines
Be kind and respectful, give credit to the original source of content, and search for duplicates before posting. Learn more
community guidelines
Contributor ,
Feb 16, 2015 Feb 16, 2015

Copy link to clipboard

Copied

LATEST

Hey Luca,

Long time no see!

If that happened to one of my plug-ins I'd suspect some memory overwrite, double deallocation, using non-allocated memory, wrong pointer dereference, index overrun, that kind of stuff.

I always compile my plug-ins on Mac and on Windows, and I always find that some bugs can go largely unnoticed on one platform, but are detectable on the other; I frequently alternate from Mac to Windows and back during development as a means of catching more issues.

This seems to be such a case.

Make sure to test with the debug version of InDesign - that will catch a lot of bad behavior. If you are already doing that, or the issue does not show up, you might need to look into the various low-level memory management debugging tools.

Without the debug version, all kinds of bad stuff can happen without you noticing. The debug version has an extensive safety net to catch many, but not all, such issues.

In my experience, such warnings indicate nearly always a real problem and warrant investigation and need to be fixed. Often, you might see them 'go away' by themselves as the code is being worked on, but that normally just means that the memory overwrite has moved to a different area where it is not being detected any more.

My recommendation: don't let this 'slip away'. I've often seen developers poke around aimlessly until the issue suddenly goes away, and assume they've 'fixed it'. That's dangerous. Unless you gain complete understanding of what is happening and why you get the error, you'd be sitting on a time bomb.

Having a repeatable crash is worth a lot: that can help you diagnose where it is coming from.

If you're interested, I am going to PePcon, and we're having a little developer get-together there:

Creative Developers Summit - PePcon

Votes

Translate

Translate

Report

Report
Community guidelines
Be kind and respectful, give credit to the original source of content, and search for duplicates before posting. Learn more
community guidelines