title: Weird fast fail stack error that seems to depend on number of identical lines of code
body: <p>I have this function here which works as written:</p>
  
  <pre><code>void Material::initializeTextureStringEnumMap() {
      stringEnumMap.emplace("_MainTex", TextureTypes::MainTex);
      stringEnumMap.emplace("_BumpMap", TextureTypes::BumpMap);
      stringEnumMap.emplace("_BumpSpecMap", TextureTypes::BumpSpecMap);
      stringEnumMap.emplace("_DetailsTex", TextureTypes::DetailTex);
      stringEnumMap.emplace("_ShadowTex", TextureTypes::ShadowTex);
      stringEnumMap.emplace("_TranslucencyMap", TextureTypes::TranslucencyMap);
      stringEnumMap.emplace("_DetailAlbedoMap", TextureTypes::DetailAlbedoMap);
      stringEnumMap.emplace("_DetailMask", TextureTypes::DetailMask);
      stringEnumMap.emplace("_DetailNormalMap", TextureTypes::DetailNormalMap);
      stringEnumMap.emplace("_EmissionMap", TextureTypes::EmissionMap);
      stringEnumMap.emplace("_OcclusionMap", TextureTypes::OcclusionMap);
      stringEnumMap.emplace("_ParallaxMap", TextureTypes::ParallaxMap);
      stringEnumMap.emplace("_SpecGlossMap", TextureTypes::SpecGlossMap);
      stringEnumMap.emplace("_MetallicGlossMap", TextureTypes::MetallicGlossMap);
      //stringEnumMap.emplace("_Diffuse", TextureTypes::Diffuse);
  }
  </code></pre>
  
  <p><code>stringEnumMap</code> is a static <code>unordered_map</code> <code>string</code> to <code>enum</code>, if it's not clear from the code.</p>
  
  <p>Now, if you uncomment that last line, the program will fail during runtime, throwing error in <code>gs_report.c</code> at line 220:</p>
  
  <pre><code>if (IsProcessorFeaturePresent(PF_FASTFAIL_AVAILABLE))
          {
              __fastfail(FAST_FAIL_STACK_COOKIE_CHECK_FAILURE);
          }
  </code></pre>
  
  <p>I don't understand why this happens. I read a file that has, among other things, strings in it. I need to apply appropriate enum to the object depending on the string. That's why I created <code>static unordered_map</code> that connects the two.</p>
  
  <p>Any ideas?</p>