• ベストアンサー

クリティカルエラー Expression: ("Buffer too small", 0)

VC++2005でコンパイルしたアプリですが、実行すると クリティカルエラーの次のメッセージが表示されました。 VCの設定で解決できるものなのでしょうか? Microsoft Visual C++ Debug Library ... Expression: ("Buffer too small", 0) Foi infomation how your program can cause an assertion failure, see the Visual C++ documentation on asserts. (press Retry debug the application)

  • rrhd
  • お礼率2% (1/44)

質問者が選んだベストアンサー

  • ベストアンサー
  • massano1
  • ベストアンサー率40% (4/10)
回答No.2

このメッセージはセキュア関数でバッファを飛ばした時に出ます。 プログラムに問題がありますので、VCの設定ではなく問題部分を 突き止めて修正しなければダメです。

その他の回答 (1)

  • phoenix343
  • ベストアンサー率15% (296/1946)
回答No.1

VCの設定でどうにかなる話ではありません。 簡単な例で言うと、 char sp[4]; strcpy_s( sp, sizeof(sp), "abcdefg" ); こんな感じで確保したメモリサイズを超えるようなアクセスをした場合ですね。 ソースの修正を推奨します。

関連するQ&A

  • ソフトが使えない

    あるソフトを立ちあげようとすると Microsoft Visual C++ Debug Library Debug Assertion Failed!(プログラム名) For information on how your program can cause an assertion failure, see the Visual C++ documentation on asserts. (Press Retry to debug the application) と言うメッセージがでてソフトが使えません。 これは、何のことでしょうか。 使えるようになるのですか。

  • エラー改善法を教えてください

    windowsXPで他人のプログラムを実行しています。 VC7で作成したプログラムをVC9で起動したところ、 ビルド→デバック→実行までは通ったのですが、 アプリケーションの途中で特定の動作を実行すると、 以下のようなエラーが出ます。 Debug Assertion Failed! Program:~\myProg.exe File:C:\Program Files\Microsoft Visual Studio 9.0\VC\include\vector Line:780 Expression:("Standard C++ Libraries Out of Range",0) For information on how your program can cause an assertion failure, see tha Visual C++ documentation on asserts. (Press Retry to debug the application) その後、myProg.exeによってブレークポイントが発生しました となります。 エラーがC:\Program Files\Microsoft Visual Studio 9.0\VC\include\vectorの中では、手のつけようがありません。 どなたかアドバイスお願いします。

  • Microsoft Visual C++ Runtime Library Assertion failedのエラーについて教えてください。

    Microsoft Visual C++ Runtime Library Assertion failedのエラーについてですが、ある時フォルダを開けて約5秒くらいするとこのエラーが必ず発生します・・・。 内容は Assertion failed!   Program:C\WINDOWS\explorer.exe File.../external/boost_1_31_0\boost/shard_ptr.hpp Line:254 Expression:px !=0 For information on how your program can cause an assertion failure,see the Visual C++ documentation on asserts (Press Retry to debug the application - JIT must be enabled) といったエラーがでてきます。全くわたくしじゃ意味もわからずどーしたらいいかわかりませんのでお力お貸しください。宜しく御願い致します。

  • 実行途中でのエラー発生について

    こんばんは。 この掲示板を頻繁に利用させていただいている者です。 Visual C++.NET 2003を利用しソケットプログラミングをしていたところ、突然わけの分からないエラーが途中で発生してしまいます。 [エラー内容] Debug Assertion Failed! File: fprintf.c Line:56 Expression: str != NULL For information on how your program can cause an assertion failure,see the Visual C++ documentation on asserts. (Press Retry to debug the application) 上記のようなエラー内容です。 今まで実行可能であったのに、突然エラーメッセージが発生しました。 Line:56ということから56行目を見たところ、str != NULLという記述もしていませんし、かつその行はコメントを記述しています。 なにか原因があるのでしょうか? よろしくお願いします。

  • デバッグエラー

    今晩和 VC++2005を使ってプログラムを開発しているのですが、デバッグ時に以下のエラーボックスが表示されます Debug Assertion Failed! Program: ... File: mbstowcs.c Line: 69 Expression: s!=NULL For information on how your program can cause an assertion failure, see the Visual C++ documentation on asserts. コンパイルまでは問題なく出来るのですが・・・・ 原因不明でかなりまいっています 御教授お願いします 環境 WindowsXP SP3 Visual Studio 2005 アカデミー サンプルプログラム:http://chihara.naist.jp/people/STAFF/imura/products/labeling内のwindows用サンプル一式

  • occmgr.cppの行410で特定のエラー

    .Net2003で作成したプロジェクトを実行しようとするとoccmgr.cppの行410で特定のエラーが出て実行できません。以下が特定のエラーの内容です。 Debug Assertion Failed!! File occmgr.cpp Line 410 For information on how your program can cause an assertion failure, see the Visual C++ documentation on asserts. どうすればいいかわかりません。 よろしくお願いします。

  • 初心者でわかりません?突然出てきます。

    突然 Microsoft Visual C++ Runtime Library X Assertion failed! Program:C:\WINDOWS\Explorer.EXE File:../external/boost.-1-31-0\boost./shared-ptr.hpp rine:254 Expression:px!=0 For information on how your program can cause an assertion failure.see the Visual C++ documentation on asserts (Press Retry to debug the application-JIT must be enabled) 中止(A) 再試行(R) 無視(I) と出てきます。ぜんぜんの初心者ですのでパニックってます、なにかパソコンに問題が生じてるんでしょうか、私のような者にわかるように教えていただければ幸いです。宜しくお願いいたします。

  • VISTAでスリープ復帰時のエラー

    PC-LN500RG6MというNECのPCを使っていますが、ある日唐突にスリープから復帰する際に、以下のエラーが発生します。 Microsoft visual C++ Runtime Library Assertion failed! Program: C:\Windows\Explorer.EXE File: E:\tools\boost_1_31_0\boost/shared_ptr.hpp Line: 254 Expression: px !=0 For information on how you program can cause an assertion failure,see the Visual C++ documentation on asserts (Press Retry to debug the application -JIT must be enabled) フリーウエアの類はインストールしていませんが、「筆まめ」と「ソニックステージ」をインストールしています。 OSはVISTA HOME premiumです。 何かご存知のかた、教えてください。

  • 起動時のメッセージの意味がわからないのですが・・・。

    McAfeeのウイルスソフトをアンインストールしてから、次の様なメッセージが必ず起動しにでます。 意味がわからないので、対象方法を教えてください! ーーーーーーーーーーーーーーーーーーーーーーー Assertion failed! Program::\program Files\Fujitsu\Sa\bin\mad.exe File:plist.cpp Line:21 Expression:istream.is Valid For information on how your program can cause an assertion failure,see the Visual C++ documentation on asserts (Press Retry to debug thr application JIT must be enabled) 中止  再試行   無視 ----------------------------------------------- ご指導宜しくお願いいたします。

  • 右クリックするとエラーが・・・

    Windows XP Home Editionを使っていますが、いつの間にか「マイコンピュータ」のFDドライブ, HDD, 外付HDD等を右クリックした際、下記のエラーが発生しプロパティ等のメニューが表示されなくなってしまいました。何かよい解決方法がありましたら教えてください。お願いします。 エラー詳細↓↓↓ Debug Assertion Failed Program: C\WINDOWS\explorer.exe file: dbgheap.c line: 1011 Expresstion:_CrtIsValidHeapPointer(pUser Date) _BLOCK_TYPE_IS_VALID(pHead->nBlockUse) For infomation on how your program can cause on assertion failure see the Visual C++ documentation on asserts.

専門家に質問してみよう