lucasg/Dependencies · warning

[x] Exception : {0:s}

Error message

[x] Exception : {0:s}

What it means

Companion line to error 0, printed immediately after it by PEManifest.PrettyPrint() (Program.cs:141). It dumps the private Exception field, which the constructor populated with e.ToString() from the XmlException raised by SxsManifest.ParseSxsManifest (Program.cs:122). It gives the exact parser location (line/column) of the malformed manifest. Same warning semantics: non-fatal, stderr only.

Source

Thrown at Dependencies/Program.cs:141

                }
            }
        }


        public void PrettyPrint()
        {
            Console.WriteLine("[-] Manifest for file : {0}", Application.Filepath);

            if (Manifest.Length == 0)
            {
                Console.WriteLine("[x] No embedded pe manifest for file {0:s}", Application.Filepath);
                return;
            }

            if (Exception.Length != 0)
            {
                Console.Error.WriteLine("[x] \"Malformed\" pe manifest for file {0:s} : {1:s}", Application.Filepath, Manifest);
                Console.Error.WriteLine("[x] Exception : {0:s}", Exception);
                return;
            }

            Console.WriteLine(XmlManifest);
        }

        public string Manifest;
        public XDocument XmlManifest;

        // stays private in order not end up in the json output
        private PE Application;
        private string Exception;
    }

    class PEImports : IPrettyPrintable
    {
        public PEImports(PE _Application)
        {

View on GitHub (pinned to 1997a40000)

Solutions

  1. Use the XmlException line/column reported in this output to pinpoint the exact byte that broke parsing.
  2. Fix the manifest at the source and rebuild, then re-run `-manifest` to confirm XmlManifest is produced.
  3. If unfixable, treat the PE as manifest-less and avoid code paths that dereference XmlManifest (which will be null).
Defensive patterns

Strategy: validation

Validate before calling

var pm = new PEManifest(pe);
bool manifestOk = string.IsNullOrEmpty(pm.Manifest) || pm.XmlManifest != null;
if (!manifestOk)
{
    // XmlManifest is null; the constructor stored the XmlException details privately.
    // Surface your own diagnostic instead of relying on PrettyPrint's stderr lines.
    Console.Error.WriteLine($"Manifest parse failed for {pe.Filepath}; raw manifest ignored.");
}

Prevention

When it happens

Trigger: Any invocation that reaches PEManifest.PrettyPrint() with Exception.Length != 0, i.e. the manifest resource was present but failed XML parsing during construction (Program.cs:117-123).

Common situations: Same as error 0: corrupted/truncated/encoding-mangled RT_MANIFEST resources; manifests produced by buggy build tooling or modified post-link.

Related errors


AI-assisted analysis of lucasg/Dependencies@1997a40000 (2026-08-13). Data as JSON: /api/errors/ae5ad6079222b57e. Report an issue: GitHub.