LibGit2Sharp throwing exception in Azure App Service

0

I have a .NET 4.6 web app running in an Azure App Service in 64 bit. When I hit a controller that calls LibGit2Sharp, I get the following exception:

[BadImageFormatException: An attempt was made to load a program with an incorrect format. (Exception from HRESULT: 0x8007000B)]

And this is the stack trace:

LibGit2Sharp.Core.NativeMethods.git_repository_new(git_repository*& repo):-1
 LibGit2Sharp.Core.Proxy.git_repository_new() in c:\Git\LibGit2Sharp-2\LibGit2Sharp\Core\Proxy.cs:2553
 LibGit2Sharp.Repository.ListRemoteReferences(String url, CredentialsHandler credentialsProvider) in c:\Git\LibGit2Sharp-2\LibGit2Sharp\Repository.cs:633

This code works fine locally, so I just can't figure out what's going wrong.

c#
azure
libgit2sharp
azure-web-app-service
azure-app-service-plans
asked on Stack Overflow Mar 22, 2017 by Dan O'Leary

0 Answers

Nobody has answered this question yet.


User contributions licensed under CC BY-SA 3.0