The forum

call of duty buffer overrun

Author Replies
LinAGKar Wednesday 7 May 2014 at 17:16
LinAGKarAnonymous

I tried to install Call of Duty 1 (through Steam from the Steam PlayOnLinux script), but every time I try to run it I get an error message about a buffer overrun.
I'm under openSUSE 13.1 64 bit with Intel Graphics 4000 and KDE 4.11.
booman Thursday 8 May 2014 at 0:31
booman

Thank you for posting!  You have confirmed that the "buffer underrun" problem isn't just Debian distros.

There is not permanent fix yet because PlayOnLinux and Wine do not support Pulseaudio.

Wine does offer a temporary fix:  Pulseaudio fix

Here is another tutorial:  Buffer Underrun

† Booman †
Mint 21 64-bit | Nvidia 515| GeForce GTX 1650
Linux for Beginners | PlayOnLinux Guides | PlayOnLinux Explained
LinAGKar Thursday 8 May 2014 at 12:30
LinAGKarAnonymous

Actually it says "buffer overrun", not "buffer underrun"
Title: Microsoft Visual C++ Runtime Library
Full text:

Buffer overrun detected!

Program: ...\Steam\SteamApps\common\Call of Duty\CoDSP.exe

A buffer overrun has been detected which has corrupted the program's internal state. The program cannot safely continue execution and must now be terminated.
booman Thursday 8 May 2014 at 15:03
booman

Oh, that was unexpected. Hmm...

In that case I have a few questions:
1. Can you play any other games in Linux?
2. Do you need to install 32-bit libraries in openSUSE to play 32-bit games?
3. Did you install the Intel proprietary graphics drivers?

† Booman †
Mint 21 64-bit | Nvidia 515| GeForce GTX 1650
Linux for Beginners | PlayOnLinux Guides | PlayOnLinux Explained
LinAGKar Thursday 8 May 2014 at 16:28
LinAGKarAnonymous

Intel has no proprietery Linux driver, the open source driver is the official one. Also I get the same error when trying to run it with nvidia graphics vith bumblebee. And "other games" in general does work. But i suppose it could be some missing libraries.
booman Friday 9 May 2014 at 15:36
booman

ah, so your laptop is one of those dual GPU setups. Those have been difficult to troubleshoot for games. Its hard to enable one and not the other, which is what Bumblebee is for, but I've read a lot of posts about people having problems with them.

You can also post the debug from PlayOnLinux and it may give us a clue about what is going on.

† Booman †
Mint 21 64-bit | Nvidia 515| GeForce GTX 1650
Linux for Beginners | PlayOnLinux Guides | PlayOnLinux Explained
LinAGKar Friday 9 May 2014 at 23:53
LinAGKarAnonymous

Well, as long as you use the Intel IGP, which the screen is connected to, it shouldn't matter that there is another graphics card in there.
As for the PlayOnLinux Debugger, it only seems to give me messages about steam, not the game.
booman Saturday 10 May 2014 at 0:40
booman

Thats fine... open WinSteam and then launch Call of Duty.
When it crashes with the "Buffer Overrun" error, copy everything in the debug an post.
It may even tell us missing libraries.

You may also want to do a manual installation of Steam:  Step-by-step Guide
Then install the libraries that Call of Duty requires.
Probably d3dx9, vcrun2005, corefonts, tahoma, etc

Don't forget you can cut-n-paste the Call Of Duty game folder and paste it to your desktop.  Its in home/.PlayOnLinux/Steam/drive_c/Program Files/Steam/SteamApps/Common

Then after you do the manual installation cut-n-paste it back to the same Common folder and you won't have to download the entire game again.

This way you can also try different versions of Wine as well.
Steam only works with Wine 1.6.2 & 1.7.8 or newer

† Booman †
Mint 21 64-bit | Nvidia 515| GeForce GTX 1650
Linux for Beginners | PlayOnLinux Guides | PlayOnLinux Explained
booman Saturday 10 May 2014 at 0:42
booman

I saw this on WineHQ

Looks like the overflow may be caused by a (surmising) too-lengthy list of OpenGL extensions supported in the most recent NVIDIA drivers. There is an environment variable that can be set to limit the list of extensions to those present in a given driver version. Editing the application launch code to include this environment variable cures the buffer overflow on launch, here. Workaround: In codsp and codmp, change the line $WINE_EXEC $GAME_BINARY "$@" && to __GL_ExtensionStringVersion=17700 $WINE_EXEC $GAME_BINARY "$@" && to limit the extension list to those present in an older (177.00) version of the NVIDIA graphics driver. Works for me.

Quote

also this

The simplest way is to go to your game folder (it should contain CoDSP.exe), open a terminal there and instead of starting the game with wine CoDSP.exe start it with: __GL_ExtensionStringVersion=17700 wine CoDSP.exe (That first character is a double underscore.)

Quote

† Booman †
Mint 21 64-bit | Nvidia 515| GeForce GTX 1650
Linux for Beginners | PlayOnLinux Guides | PlayOnLinux Explained
LinAGKar Sunday 11 May 2014 at 0:40
LinAGKarAnonymous

Ok, that way the game at least starts (at least when using Nvidia graphics). After I installed "d3dx9" (and "vcrun2005", not sure if that was necessary) i could also watch the intro movie, however when it gets to the main menu it either crashes or the graphics gets corrupted and I am forced to kill it. I would try "tahoma", but I am on a very slow Internet connection right now.
Debug output:
[05/11/14 00:34:53] - Running wine-1.7.8 Steam.exe (Working directory : /home/linus/.PlayOnLinux/wineprefix/Steam/drive_c/Program Files/Steam)
[0511/003515:ERROR:resource_bundle.cc(417)] Failed to load C:\Program Files\Steam\bin\chrome.pak
Some features may not be available.
[0511/003515:ERROR:network_change_notifier_win.cc(126)] WSALookupServiceBegin failed with: 8
primus: warning: recreating incompatible pbuffer
primus: warning: recreating incompatible pbuffer
primus: warning: recreating incompatible pbuffer
LinAGKar Sunday 11 May 2014 at 1:08
LinAGKarAnonymous

With "MESA_EXTENSION_MAX_YEAR=2010" the game worked with Intel graphics (though I also had to enable s3tc with "force_s3tc_enable=true"). Now the game seems to work fine.
booman Sunday 11 May 2014 at 5:37
booman

That figures it came down to a driver issue.
I'll never fully understand why laptops need to video chips?
Glad you got it working.

Don't forget to mark this thread as "solved"
Thanks

† Booman †
Mint 21 64-bit | Nvidia 515| GeForce GTX 1650
Linux for Beginners | PlayOnLinux Guides | PlayOnLinux Explained