# 4.7 p8 - UHT fails with error code: -1073741819

**URL:** <https://forums.unrealengine.com/t/4-7-p8-uht-fails-with-error-code-1073741819/307304>\
**Category:** Programming & Scripting\
**Tags:** unreal-engine\
**Created:** [February 18, 2015, 10:48am UTC](https://forums.unrealengine.com/t/4-7-p8-uht-fails-with-error-code-1073741819/307304 "2015-02-18T10:48:32Z")\
**Posts on this page:** 14\
**Page:** 1

<div class="post-metadata">

**Author:** ![FTC](https://d3kjluh73b9h9o.cloudfront.net/original/4X/2/8/5/28502927f1d97ba1051b3b47ccfe17233bf41ef0.png) [@FTC](https://forums.unrealengine.com/u/FTC)\
**Post date:** [February 18, 2015, 10:48am UTC](https://forums.unrealengine.com/t/4-7-p8-uht-fails-with-error-code-1073741819/307304/1 "2015-02-18T10:48:32Z")

</div>

With the preview 8 release I test updated a big project of ours, but I cannot build it, the UHT keeps crashing with:

```
1>------ Build started: Project: ProjectName, Configuration: Development_Editor x64 ------
1> Parsing headers for ProjectNameEditor
1>Error : Failed to generate code for ProjectNameEditor - error code: -1073741819 (-1073741819)
1> UnrealHeaderTool failed for target 'ProjectNameEditor' (platform: Win64, module info: D:\ProjectName\trunk\UE4\ProjectName\Intermediate\Build\Win64\ProjectNameEditor\Development\UnrealHeaderTool.manifest).
1>C:\Program Files (x86)\MSBuild\Microsoft.Cpp\v4.0\V120\Microsoft.MakeFile.Targets(38,5): error MSB3073: The command ""C:\Program Files\Epic Games\4.7\Engine\Build\BatchFiles\Build.bat" ProjectNameEditor Win64 Development "D:\ProjectName\trunk\UE4\ProjectName\ProjectName.uproject" -rocket" exited with code -1.
========== Build: 0 succeeded, 1 failed, 0 up-to-date, 0 skipped ==========

```

I don’t know what to do, I found a few answers to this problem, but I could not get any of them to work. I tried to remove LOCTEXT macros and source files as best I could, but frankly at this point the project is too large to properly test out every source file and configuration. However compiling does work without a problem in 4.6.

greetings,

---

<div class="post-metadata">

**Author:** ![anonymous\_user\_b666e59e](https://d3kjluh73b9h9o.cloudfront.net/original/4X/2/8/5/28502927f1d97ba1051b3b47ccfe17233bf41ef0.png) [@anonymous\_user\_b666e59e](https://forums.unrealengine.com/u/anonymous_user_b666e59e)\
**Post date:** [February 18, 2015, 7:12pm UTC](https://forums.unrealengine.com/t/4-7-p8-uht-fails-with-error-code-1073741819/307304/2 "2015-02-18T19:12:15Z")

</div>

Hi ,

I tried to reproduce this issue using a code project created in 4.6.1 binary and upgraded to 4.7 preview 8. I was able to build the 4.7 version of the project in Visual Studio without any problems. Would you be able to provide some additional information?

- Does this issue only happen in your project, or do you see the same results in a new project upgraded to 4.7 preview 8?
- Was your project initially created in 4.6.1, or did you make it in an earlier version and then upgraded it to 4.6.1?
- Can you provide the exact steps that you followed when you upgraded your project to try it in 4.7 preview 8?

---

<div class="post-metadata">

**Author:** ![FTC](https://d3kjluh73b9h9o.cloudfront.net/original/4X/2/8/5/28502927f1d97ba1051b3b47ccfe17233bf41ef0.png) [@FTC](https://forums.unrealengine.com/u/FTC)\
**Post date:** [February 18, 2015, 9:59pm UTC](https://forums.unrealengine.com/t/4-7-p8-uht-fails-with-error-code-1073741819/307304/3 "2015-02-18T21:59:36Z")

</div>

- So far none of my other projects had this problem.
- No, I think it goes back as far as 4.4, but then again I have others being even older and they still work.
- I have not done much: Downloaded the new preview, right clicked on the uproject file and chose switch engine. Then I regenerated the visual studio files and attempted a full rebuild of the solution.
- I also tried to create a new project and just copy the code over, but the same crash happens. So my guess is that it has something to do with the code, but I am not at liberty to share it.

Any indication on what the error code means? Are there problem areas to look out for? (e.g. makros)

greetings

---

<div class="post-metadata">

**Author:** ![Goomii](https://d3kjluh73b9h9o.cloudfront.net/original/4X/2/8/5/28502927f1d97ba1051b3b47ccfe17233bf41ef0.png) [@Goomii](https://forums.unrealengine.com/u/Goomii)\
**Post date:** [February 27, 2015, 8:47pm UTC](https://forums.unrealengine.com/t/4-7-p8-uht-fails-with-error-code-1073741819/307304/4 "2015-02-27T20:47:13Z")

</div>

I’m having the same issue on the 4.7.1 hotfix release error code: -1073741819 when I try to build.  
The project was created in 4.5 then upgraded to 4.6 without issue but now on upgrading to 4.7 I get this issue.  
I don’t have any LOCTEXT macros in my code either.  
I also like tried to place the code into a fresh project but ran into the same issue so the problem is in the code somewhere.

The logs from the header tool are cut off so it doesn’t exit cleanly, but it always seems to get cut off at the same spot.  
I attached it below.

If there is anymore info that I can provide like a way to enable more verbose logging please say as I’d love to get past this issue, thanks :\>

Error log from vs2013 community:

```
1>------ Build started: Project: SpaceSloth, Configuration: Development_Editor x64 ------
2>------ Skipped Build: Project: UE4, Configuration: BuiltWithUnrealBuildTool Win32 ------
2>Project not selected to build for this solution configuration 
1> Parsing headers for SpaceSlothEditor
1>Error : Failed to generate code for SpaceSlothEditor - error code: -1073741819 (-1073741819)
1> UnrealHeaderTool failed for target 'SpaceSlothEditor' (platform: Win64, module info: F:\Projects\UE4 Projects\SpaceSloth47\Intermediate\Build\Win64\SpaceSlothEditor\Development\UnrealHeaderTool.manifest).
1>C:\Program Files (x86)\MSBuild\Microsoft.Cpp\v4.0\V120\Microsoft.MakeFile.Targets(38,5): error MSB3073: The command ""F:\Windows_Stuff\Program Files (x86)\Unreal Engine\4.7\Engine\Build\BatchFiles\Build.bat" SpaceSlothEditor Win64 Development "F:\Projects\UE4 Projects\SpaceSloth47\SpaceSloth.uproject" -rocket" exited with code -1.
========== Build: 0 succeeded, 1 failed, 0 up-to-date, 1 skipped ==========

```

UnrealHeaderTool.log

---

<div class="post-metadata">

**Author:** ![FTC](https://d3kjluh73b9h9o.cloudfront.net/original/4X/2/8/5/28502927f1d97ba1051b3b47ccfe17233bf41ef0.png) [@FTC](https://forums.unrealengine.com/u/FTC)\
**Post date:** [March 3, 2015, 11:15am UTC](https://forums.unrealengine.com/t/4-7-p8-uht-fails-with-error-code-1073741819/307304/5 "2015-03-03T11:15:58Z")

</div>

It seems I have found the cause of the crash: Interfaces.

I replaced GENERATED\_UINTERFACE\_BODY with GENERATED\_BODY at some point, probably during the last update and it worked fine until 4.7. Since I corrected the macros everything works fine again and the project compiles.

I also needed to define (not declare) a constructor for the UInterface, which makes me think that something still isn’t completely right with the way interfaces are handled in 4.7.

greetings

---

<div class="post-metadata">

**Author:** ![Goomii](https://d3kjluh73b9h9o.cloudfront.net/original/4X/2/8/5/28502927f1d97ba1051b3b47ccfe17233bf41ef0.png) [@Goomii](https://forums.unrealengine.com/u/Goomii)\
**Post date:** [March 3, 2015, 2:26pm UTC](https://forums.unrealengine.com/t/4-7-p8-uht-fails-with-error-code-1073741819/307304/6 "2015-03-03T14:26:11Z")

</div>

You have just made my day, that fixed the issue for me too.

![](https://d3kjluh73b9h9o.cloudfront.net/original/4X/2/e/3/2e380b6368de45702365af008acd14cf4a5fc825.gif)

---

<div class="post-metadata">

**Author:** ![anonymous\_user\_b666e59e](https://d3kjluh73b9h9o.cloudfront.net/original/4X/2/8/5/28502927f1d97ba1051b3b47ccfe17233bf41ef0.png) [@anonymous\_user\_b666e59e](https://forums.unrealengine.com/u/anonymous_user_b666e59e)\
**Post date:** [March 3, 2015, 7:42pm UTC](https://forums.unrealengine.com/t/4-7-p8-uht-fails-with-error-code-1073741819/307304/7 "2015-03-03T19:42:50Z")

</div>

Hi ,

Thank you for the additional investigation and information that you provided related to this issue. I believe you were able to pinpoint the cause of the issue, and it looks like it may be something inadvertently broken in 4.7. I was able to reproduce the same error message that you reported in 4.7, but when I tried the same code in 4.6.1 it worked fine. I have entered a report of my observations to have this investigated further (UE-11256).

---

<div class="post-metadata">

**Author:** ![gmpreussner\_1](https://d3kjluh73b9h9o.cloudfront.net/original/4X/2/8/5/28502927f1d97ba1051b3b47ccfe17233bf41ef0.png) [@gmpreussner\_1](https://forums.unrealengine.com/u/gmpreussner_1)\
**Post date:** [March 25, 2015, 9:32pm UTC](https://forums.unrealengine.com/t/4-7-p8-uht-fails-with-error-code-1073741819/307304/8 "2015-03-25T21:32:23Z")

</div>

For future reference, error code -1073741819 indicates an access violation inside UHT, which means that we have a bug somewhere. If you run into this again, please let us know, so we can fix it. Thanks!

---

<div class="post-metadata">

**Author:** ![makai](https://d3kjluh73b9h9o.cloudfront.net/original/4X/2/8/5/28502927f1d97ba1051b3b47ccfe17233bf41ef0.png) [@makai](https://forums.unrealengine.com/u/makai)\
**Post date:** [July 20, 2015, 5:56pm UTC](https://forums.unrealengine.com/t/4-7-p8-uht-fails-with-error-code-1073741819/307304/9 "2015-07-20T17:56:15Z")

</div>

hello, i have this problem on 4.81…  
i started on 4.2 or earlier and i followed the advice to create from scratch (just copy the code over to a blank 4.81 project)

> **[Strange Editor Behavior with 4.8](https://forums.unrealengine.com/questions/258427/strange-editor-behavior-with-48.html)**
>
> Hello, first off i want to thank you guys so much for 4.8 and your decision to give UE4 for free! I noticed strange editor behavior i can not explain myself (its only for my project) Sometimes after playing Game in Editor “Play” editors mouse...

now i have this compile error… any help appreciated  
no LocMacros and no GENERATED\_UINTERFACE\_BODY

my class has GENERATED\_UCLASS\_BODY()

---

<div class="post-metadata">

**Author:** ![anonymous\_user\_b666e59e](https://d3kjluh73b9h9o.cloudfront.net/original/4X/2/8/5/28502927f1d97ba1051b3b47ccfe17233bf41ef0.png) [@anonymous\_user\_b666e59e](https://forums.unrealengine.com/u/anonymous_user_b666e59e)\
**Post date:** [July 29, 2015, 6:07pm UTC](https://forums.unrealengine.com/t/4-7-p8-uht-fails-with-error-code-1073741819/307304/10 "2015-07-29T18:07:37Z")

</div>

Hi ,

I just attempted to do what you described (made a project in 4.2.1, then copied all of the source files straight into 4.8.1) and was able to build the project without any problems in Visual Studio (there was a lengthy list of deprecation warnings, but no errors). Is this something that is still a problem for you?

---

<div class="post-metadata">

**Author:** ![makai](https://d3kjluh73b9h9o.cloudfront.net/original/4X/2/8/5/28502927f1d97ba1051b3b47ccfe17233bf41ef0.png) [@makai](https://forums.unrealengine.com/u/makai)\
**Post date:** [July 29, 2015, 8:56pm UTC](https://forums.unrealengine.com/t/4-7-p8-uht-fails-with-error-code-1073741819/307304/11 "2015-07-29T20:56:27Z")

</div>

hey ,  
i don’t know what was wrong, but after some retry it worked.  
But im pretty sure there is still something wrong, maybe by importing the assets i migrated, i migrated the problem with it also.  
to just let you know, im describing it here [Session found in PIE but not in packaged Game - Multiplayer & Networking - Epic Developer Community Forums](https://answers.unrealengine.com/questions/263920/session-found-in-pie-but-not-in-packaged-game.html)

im pretty sure from my research in answerhub and forum, that there is something wrong for old projects converted to the latest version over time.  
there are many people having similar problems.  
thank you epic guys so much for your help and support

---

<div class="post-metadata">

**Author:** ![ambershee](https://d3kjluh73b9h9o.cloudfront.net/original/4X/2/8/5/28502927f1d97ba1051b3b47ccfe17233bf41ef0.png) [@ambershee](https://forums.unrealengine.com/u/ambershee)\
**Post date:** [July 29, 2015, 10:33pm UTC](https://forums.unrealengine.com/t/4-7-p8-uht-fails-with-error-code-1073741819/307304/12 "2015-07-29T22:33:19Z")

</div>

I’ve managed to produce this error code in 4.8.2 - it’s a pretty easy repro.

In Actor.h, try to expose ENetMode GetNetMode() const; to blueprint (e.g. UFUNCTION(BlueprintPure, Category = “Replication”) ) - it is guaranteed to fail.

---

<div class="post-metadata">

**Author:** ![anonymous\_user\_b666e59e](https://d3kjluh73b9h9o.cloudfront.net/original/4X/2/8/5/28502927f1d97ba1051b3b47ccfe17233bf41ef0.png) [@anonymous\_user\_b666e59e](https://forums.unrealengine.com/u/anonymous_user_b666e59e)\
**Post date:** [August 5, 2015, 7:17pm UTC](https://forums.unrealengine.com/t/4-7-p8-uht-fails-with-error-code-1073741819/307304/13 "2015-08-05T19:17:29Z")

</div>

Hi ambershee,

The reason for the error you see there is because the `ENetMode` enum is not marked as a `UENUM`. I have submitted a ticket to have this investigated (UE-19685), but a workaround for now would be to add the `UENUM()` macro above the `ENetMode` enum in source code.

---

<div class="post-metadata">

**Author:** ![anonymous\_user\_b666e59e](https://d3kjluh73b9h9o.cloudfront.net/original/4X/2/8/5/28502927f1d97ba1051b3b47ccfe17233bf41ef0.png) [@anonymous\_user\_b666e59e](https://forums.unrealengine.com/u/anonymous_user_b666e59e)\
**Post date:** [August 11, 2015, 5:53pm UTC](https://forums.unrealengine.com/t/4-7-p8-uht-fails-with-error-code-1073741819/307304/14 "2015-08-11T17:53:25Z")

</div>

Just a quick update. UHT cannot parse types that are native only (ie. not a UCLASS, USTRUCT or UENUM), so this is actually an intentional error message. In our latest internal build, the error message has been expanded to provide some additional clarity for what is happening.
