Welcome to the SRP Forum! Please refer to the SRP Forum FAQ post if you have any questions regarding how the forum works.

SRP_Run_Command crash

One of our sites is getting a "Microsoft Visual C++ Runtime Library: Runtime Error!, Program: OINSIGHT.EXE, abnormal program termination" message, that appears to be happening during an SRP_Run_Command() call. Specifically, an OEPROFILE log shows this occurring in SRPcreateProcess. There is no entry in the Windows Event Log though.

The application is running through a loop, generating thumbnails for a set of images. SRP_Run_Command() is used to run an ImageMagick convert.exe command. This process at this site appears to run slower than we would normally expect, and the crash happens at some point later iteration of the loop. It doesn't appear related to certain data (or images) - it seems to be random.

I'm guessing it's a resource issue on the machines. It does happen on multiple machines, although they could all have similar specs (Windows 7).

Any suggestions on how I can better diagnose this?

SRPutilities v1.5.7
SRPcontrols v4.0.3.2

Cheers, M@

Comments

  • Hey Matt,

    I'm afraid I can't be much help with your question but I am curious about your use of ImageMagick.
    Is this the only site where you're using this or do you use it with greater reliability in other places.

    I have a need to create thumbnails on the fly and whilst I've had some success with this using Imgman, I've hit a wall trying to get it working in production. If you're using it reliably elsewhere then maybe I'll take the alternate route and see whether that works for my needs.
  • Hi Mark,

    There are about 20 sites (about 70 desktops) currently running the latest version of our software, all using ImageMagick the same way. Only one site getting this problem though.

    I had a look at Imgman but had some problems with it. ImageMagick seems more powerful, easy to use, and constantly maintained. I explored all the interfaces - DLL, .NET, OCX, EXE - and found just the command line EXEs to be the most reliable and by far the easiest to use. I have it stored on client machines as the EXE files are quite large.

    I'm not sure I'll find an answer here exactly what is causing our problem, but any ideas on what to look for would be useful.

    Cheers, M@
  • Thanks Matt.

    I've downloaded it. I'll have to schedule some time to play.
  • As you said, it's probably related to resources. Could the original images at this site be particularly large? I'm not sure what else you can do to troubleshoot a crash occurring within a 3rd party utility. All you're doing is resizing these images?
  • Resizing with convert.exe's -thumbnail -auto-orient -background white -flatten options, and converting to BMPs.

    I would have thought that with each call being a separate Windows process (conhost.exe), Windows would be tidying up nicely after each call.
    Also, if it is convert.exe that is crashing then wouldn't the Runtime Error message indicate conhost.exe rather than oinsight.exe ??

    Cheers, M@
  • I do :
    cmd="magick convert ":MagickPath:" -resize 621x798> ": Convtargetfile
    call SRP_Run_Command(CMD)

    There was some chatter about convert.exe being replaced by 'convert' as a command to magick (as above) from Imagemagick 7 , I wonder if that might be the workstation problem...they upgraded.
  • Matt, it's possible SRP_Run_Command is crashing because the child process is failing. I'm not ruling out a bug in SRP_Run_Command, but I can say SRP_Run_Command has been in use regularly for years. Given that this fails on a single machine, I'm inclined to think ImageMagick is failing.
  • Hi Kevin,
    It's happening on multiple workstations, but only at this site - that's the puzzling thing! Also that it's not clear exactly where this crash is happening.

    I need to think up some isolation tests. Eg, batch calls to ImageMagick outside of OI. Not easy when you can't replicate on demand though.
  • Interesting thought, Barry! We've deployed ImageMagick v7.0.1, but aren't using magick.exe . Looks like they've consolidated the command line tools into one (a la SRP_Array ;).

    Cheers, M@
Sign In or Register to comment.