Inazuma.Mono.Cecil.PE.ImageWriter.BuildSections C# (CSharp) Method

BuildSections() private method

private BuildSections ( ) : void
return void
		void BuildSections ()
		{
			var has_win32_resources = win32_resources != null;
			if (has_win32_resources)
				sections++;

			text = CreateSection (".text", text_map.GetLength (), null);
			var previous = text;

			if (has_win32_resources) {
				rsrc = CreateSection (".rsrc", (uint) win32_resources.length, previous);

				PatchWin32Resources (win32_resources);
				previous = rsrc;
			}

			if (has_reloc)
				reloc = CreateSection (".reloc", 12u, previous);
		}

Usage Example

Example #1
0
        public static ImageWriter CreateWriter(ModuleDefinition module, MetadataBuilder metadata, Stream stream)
        {
            var writer = new ImageWriter(module, metadata, stream);

            writer.BuildSections();
            return(writer);
        }
All Usage Examples Of Inazuma.Mono.Cecil.PE.ImageWriter::BuildSections