Operation Captive Reference Manual |
---|
storage —
extern GIOChannel *captive_image_iochannel; extern guint64 captive_image_size; guint64 captive_giochannel_size (GIOChannel *channel); gboolean captive_cdrom_init (void); gboolean captive_disk_init (void);
extern GIOChannel *captive_image_iochannel;
The readl GIOChannel to be used for accessing the disk image. It may be either directly captive_options->image_iochannel or the wrapper by giochannel-blind.
extern guint64 captive_image_size;
Size of captive_image_iochannel. Empty files are rejected and therefore this value is always >0 after successful captive_init(). Value is detected by captive_giochannel_size(captive_image_iochannel).
guint64 captive_giochannel_size (GIOChannel *channel);
channel : | |
Returns : |
gboolean captive_cdrom_init (void);
Creates system device "\Device\CdRomd" providing readonly access to the given captive_image_iochannel as emulation of CD-ROM driver.
libcaptive currently supports just one drive and thus "\Device\CdRom0" is always created. It is forbidden to call this function twice.
Returns : | TRUE if the initialization was successful. |
gboolean captive_disk_init (void);
Creates system device "\Device\CaptiveHarddiskd" providing readwrite access to the given captive_image_iochannel as emulation of harddisk driver. reactos initializes "\Device\Harddiskd\Partition0" as the whole disk and each partition it founds by IoReadPartitionTable() it will create as "\Device\Harddiskd\Partition1", "\Device\Harddiskd\Partition2" etc.
libcaptive does not (yet?) support any partitions and it will always create just the disk device for the whole given captive_image_iochannel. As this behaviour is a bit specific we rather create some non-standard name of the device; anyway I have seen some "\Device\HarddiskdVolumed" on W32 system.
captive currently supports just one drive and thus "\Device\CaptiveHarddisk0" is always created. It is forbidden to call this function twice.
Returns : | TRUE if the initialization was successful. |
<< unicode_reactos | ldr_exports >> |