{"id":112339,"date":"2026-05-19T07:00:00","date_gmt":"2026-05-19T14:00:00","guid":{"rendered":"https:\/\/devblogs.microsoft.com\/oldnewthing\/?p=112339"},"modified":"2026-05-19T20:21:48","modified_gmt":"2026-05-20T03:21:48","slug":"20260519-00","status":"publish","type":"post","link":"https:\/\/devblogs.microsoft.com\/oldnewthing\/20260519-00\/?p=112339","title":{"rendered":"What is the history of the <CODE>ERROR_<WBR>ARENA_<WBR>TRASHED<\/CODE> error code?"},"content":{"rendered":"<p>Error code 7 is <code>ERROR_<wbr \/>ARENA_<wbr \/>TRASHED<\/code>. What does this mean? It sounds like a heavy metal band ran amok and made a mess of the performance area that they rented.<\/p>\n<p>This error message was inherited from MS-DOS. MS-DOS internally kept track of memory in the form of a sequence of variable-sized memory blocks, each prefixed by a 16-byte block known as an <a href=\"https:\/\/github.com\/microsoft\/MS-DOS\/blob\/2d04cacc5322951f187bb17e017c12920ac8ebe2\/v2.0\/source\/DOSSYM.ASM#L636\">arena<\/a>:<\/p>\n<pre>arena   STRUC\r\narena_signature     DB  ?               ; 4D for valid item, 5A for last item\r\narena_owner         DW  ?               ; owner of arena item\r\narena_size          DW  ?               ; size in paragraphs of item\r\narena   ENDS\r\n<\/pre>\n<p>The <code>arena_owner<\/code> is the PDB of the process that allocated the memory, or zero if the memory is free. Each arena signature is <tt>0x4D<\/tt> (ASCII capital M), except for the final one which is <tt>0x5A<\/tt> (ASCII capital Z). Yes, those are the initials of Mark Zbikowski.<\/p>\n<p>When walking through the memory blocks, say, when searching for memory to satisfy an allocation request, if MS-DOS saw that the signature was neither <tt>0x4D<\/tt> nor <tt>0x5A<\/tt>, then it declared that the arenas were &#8220;trashed&#8221; (corrupted)\u00b9 and <a href=\"https:\/\/github.com\/microsoft\/MS-DOS\/blob\/2d04cacc5322951f187bb17e017c12920ac8ebe2\/v2.0\/source\/ALLOC.ASM#L177\"> returned <code>ERROR_<wbr \/>ARENA_<wbr \/>TRASHED<\/code><\/a>.<\/p>\n<p>This is an MS-DOS specific error code. It is not used by Win32.\u00b2<\/p>\n<p>Since it is a vestigial error code (like <a title=\"What is the thread reaper?\" href=\"https:\/\/devblogs.microsoft.com\/oldnewthing\/20231031-00\/?p=108944\"> <code>EMPTY_<wbr \/>THREAD_<wbr \/>REAPER_<wbr \/>LIST<\/code><\/a>), it is a handy error code to use when mocking error conditions, because you can be fairly confident that if you see error 7, it came from your test harness and not from a genuine system error.<\/p>\n<p>The fact that the error message is not used casts suspicions on the many web sites that claim to be able to help you &#8220;fix&#8221; the problem. If you read their explanation of &#8220;what this error means&#8221;, it&#8217;s just a bunch of vague text about how, y&#8217;know, sometimes computers aren&#8217;t doing all that great and they encounter errors, or maybe there is a hardware conflict, or a corrupted system file. But somehow, despite having no idea what the error means, they still are quite confident in the steps you should take to fix it. (Usually performing a system scan, a system file check, and checking for driver updates.)<\/p>\n<p>\u00b9 The use of the slang term &#8220;trashed&#8221; is further evidence that Microsoft developers were <a title=\"The Microsoft\/IBM joint development was built on mutual respect, wait, is respect the right word?\" href=\"https:\/\/devblogs.microsoft.com\/oldnewthing\/20240827-00\/?p=110186\"> just a bunch of undisciplined hackers<\/a>.<\/p>\n<p>\u00b2 Well, at least, it is not used by the Win32 kernel. I do see that there are a few user-mode components which use it to indicate that internal data structures have been corrupted, which is at least in the same spirit as the original meaning of the error.<\/p>\n","protected":false},"excerpt":{"rendered":"<p>The storage control blocks were destroyed.<\/p>\n","protected":false},"author":1069,"featured_media":111744,"comment_status":"open","ping_status":"closed","sticky":false,"template":"","format":"standard","meta":{"_acf_changed":false,"footnotes":""},"categories":[1],"tags":[2],"class_list":["post-112339","post","type-post","status-publish","format-standard","has-post-thumbnail","hentry","category-oldnewthing","tag-history"],"acf":[],"blog_post_summary":"<p>The storage control blocks were destroyed.<\/p>\n","_links":{"self":[{"href":"https:\/\/devblogs.microsoft.com\/oldnewthing\/wp-json\/wp\/v2\/posts\/112339","targetHints":{"allow":["GET"]}}],"collection":[{"href":"https:\/\/devblogs.microsoft.com\/oldnewthing\/wp-json\/wp\/v2\/posts"}],"about":[{"href":"https:\/\/devblogs.microsoft.com\/oldnewthing\/wp-json\/wp\/v2\/types\/post"}],"author":[{"embeddable":true,"href":"https:\/\/devblogs.microsoft.com\/oldnewthing\/wp-json\/wp\/v2\/users\/1069"}],"replies":[{"embeddable":true,"href":"https:\/\/devblogs.microsoft.com\/oldnewthing\/wp-json\/wp\/v2\/comments?post=112339"}],"version-history":[{"count":1,"href":"https:\/\/devblogs.microsoft.com\/oldnewthing\/wp-json\/wp\/v2\/posts\/112339\/revisions"}],"predecessor-version":[{"id":112340,"href":"https:\/\/devblogs.microsoft.com\/oldnewthing\/wp-json\/wp\/v2\/posts\/112339\/revisions\/112340"}],"wp:featuredmedia":[{"embeddable":true,"href":"https:\/\/devblogs.microsoft.com\/oldnewthing\/wp-json\/wp\/v2\/media\/111744"}],"wp:attachment":[{"href":"https:\/\/devblogs.microsoft.com\/oldnewthing\/wp-json\/wp\/v2\/media?parent=112339"}],"wp:term":[{"taxonomy":"category","embeddable":true,"href":"https:\/\/devblogs.microsoft.com\/oldnewthing\/wp-json\/wp\/v2\/categories?post=112339"},{"taxonomy":"post_tag","embeddable":true,"href":"https:\/\/devblogs.microsoft.com\/oldnewthing\/wp-json\/wp\/v2\/tags?post=112339"}],"curies":[{"name":"wp","href":"https:\/\/api.w.org\/{rel}","templated":true}]}}