mirror of
https://github.com/pbatard/rufus.git
synced 2024-08-14 23:57:05 +00:00
Merge c59e585147
into f8c6903d21
This commit is contained in:
commit
b288e42f59
33 changed files with 90 additions and 90 deletions
2
configure
vendored
2
configure
vendored
|
@ -1511,7 +1511,7 @@ done
|
|||
{ ac_configure_args0=; unset ac_configure_args0;}
|
||||
{ ac_configure_args1=; unset ac_configure_args1;}
|
||||
|
||||
# When interrupted or exit'd, cleanup temporary files, and complete
|
||||
# When interrupted or exited, cleanup temporary files, and complete
|
||||
# config.log. We remove comments because anyway the quotes in there
|
||||
# would cause problems or look ugly.
|
||||
# WARNING: Use '\'' to represent an apostrophe within the trap.
|
||||
|
|
|
@ -134,7 +134,7 @@ check_timeout:
|
|||
cmpb ds:counter_timeout, 0x00
|
||||
jnz wait_for_keyboard
|
||||
|
||||
boot_fixed_disk: # Timeout occured => boot second bootable disk (non USB)
|
||||
boot_fixed_disk: # Timeout occurred => boot second bootable disk (non USB)
|
||||
call restore_rtc_vect # Remove our RTC override
|
||||
movb ds:partition_table, 0x81 # target we want to swap with 0x80
|
||||
push 0x0080
|
||||
|
|
|
@ -154,7 +154,7 @@ static void FatDateTimeToSystemTime(PLARGE_INTEGER SystemTime, PFAT_DATETIME Fat
|
|||
/* Fix seconds value that might get beyond the bound */
|
||||
if (TimeFields.Second > 59) TimeFields.Second = 0;
|
||||
|
||||
/* Perform ceonversion to system time if possible */
|
||||
/* Perform conversion to system time if possible */
|
||||
if (!RtlTimeFieldsToTime(&TimeFields, SystemTime)) {
|
||||
/* Set to default time if conversion failed */
|
||||
SystemTime->QuadPart = 0;
|
||||
|
@ -280,7 +280,7 @@ static BOOL ExtractFAT(int entry, const char* path)
|
|||
}
|
||||
|
||||
safe_closehandle(hFile);
|
||||
uprintf("Succesfully wrote '%s' (%d bytes)\n", filename, filesize);
|
||||
uprintf("Successfully wrote '%s' (%d bytes)\n", filename, filesize);
|
||||
|
||||
return TRUE;
|
||||
}
|
||||
|
@ -396,7 +396,7 @@ BOOL ExtractFreeDOS(const char* path)
|
|||
// thus we would need to have a separate header with each file's timestamps
|
||||
|
||||
safe_closehandle(hFile);
|
||||
uprintf("Succesfully wrote '%s' (%d bytes)\n", filename, res_size);
|
||||
uprintf("Successfully wrote '%s' (%d bytes)\n", filename, res_size);
|
||||
|
||||
if ((i == 4) || (i == 10) || (i == 16) || (i == 22) || (i == ARRAYSIZE(res_name)-1))
|
||||
UpdateProgress(OP_DOS, -1.0f);
|
||||
|
|
|
@ -639,7 +639,7 @@ static const char* get_kb(void)
|
|||
case 0x00000440: // Kyrgyz Cyrillic
|
||||
return "ky";
|
||||
case 0x00000043:
|
||||
case 0x00000843: // Uzbek Crillic
|
||||
case 0x00000843: // Uzbek Cyrillic
|
||||
return "uz";
|
||||
case 0x00000042:
|
||||
case 0x00000442: // Turkmen
|
||||
|
@ -970,7 +970,7 @@ BOOL SetDOSLocale(const char* path, BOOL bFreeDOS)
|
|||
fprintf(fd, "set PATH=.;\\;\\LOCALE\n");
|
||||
fprintf(fd, "echo Using %s keyboard with %s codepage [%d]\n", kb_to_hr("us"), cp_to_hr(437), 437);
|
||||
fclose(fd);
|
||||
uprintf("Succesfully wrote 'AUTOEXEC.BAT'\n");
|
||||
uprintf("Successfully wrote 'AUTOEXEC.BAT'\n");
|
||||
return TRUE;
|
||||
}
|
||||
|
||||
|
@ -997,7 +997,7 @@ BOOL SetDOSLocale(const char* path, BOOL bFreeDOS)
|
|||
bFreeDOS?"MENU ":"MENUITEM=", bFreeDOS?')':',', kb_to_hr("us"), cp_to_hr(437), 437);
|
||||
fprintf(fd, "%s", bFreeDOS?"MENU\n12?\n":"[1]\ndevice=\\locale\\display.sys con=(ega,,1)\n[2]\n");
|
||||
fclose(fd);
|
||||
uprintf("Succesfully wrote 'CONFIG.SYS'\n");
|
||||
uprintf("Successfully wrote 'CONFIG.SYS'\n");
|
||||
|
||||
// AUTOEXEC.BAT
|
||||
strcpy(filename, path);
|
||||
|
@ -1018,7 +1018,7 @@ BOOL SetDOSLocale(const char* path, BOOL bFreeDOS)
|
|||
fprintf(fd, "keyb %s,,\\locale\\%s\n", kb, kbdrv);
|
||||
fprintf(fd, ":2\n");
|
||||
fclose(fd);
|
||||
uprintf("Succesfully wrote 'AUTOEXEC.BAT'\n");
|
||||
uprintf("Successfully wrote 'AUTOEXEC.BAT'\n");
|
||||
|
||||
return TRUE;
|
||||
}
|
||||
|
|
18
src/format.c
18
src/format.c
|
@ -243,7 +243,7 @@ static void ToValidLabel(WCHAR* name, BOOL bFAT)
|
|||
if (name[i] == '_') j++;
|
||||
if (i<2*j) {
|
||||
// If the final label is mostly underscore, use the proposed label
|
||||
uprintf("FAT label is mostly undercores. Using '%s' label instead.\n", SelectedDrive.proposed_label);
|
||||
uprintf("FAT label is mostly underscores. Using '%s' label instead.\n", SelectedDrive.proposed_label);
|
||||
for(i=0; SelectedDrive.proposed_label[i]!=0; i++)
|
||||
name[i] = SelectedDrive.proposed_label[i];
|
||||
name[i] = 0;
|
||||
|
@ -265,7 +265,7 @@ static void ToValidLabel(WCHAR* name, BOOL bFAT)
|
|||
*
|
||||
* Low order word is calculated: Volume Serial Number is:
|
||||
* Month & Day 12/26 0c1ah
|
||||
* Sec & Hundrenths 41:94 295eh 3578:1d02
|
||||
* Sec & Hundredths 41:94 295eh 3578:1d02
|
||||
* -----
|
||||
* 3578h
|
||||
*
|
||||
|
@ -387,7 +387,7 @@ static BOOL FormatFAT32(DWORD DriveIndex)
|
|||
if (IS_ERROR(FormatStatus)) goto out;
|
||||
if (!DeviceIoControl (hLogicalVolume, IOCTL_DISK_GET_PARTITION_INFO, NULL, 0, &piDrive,
|
||||
sizeof(piDrive), &cbRet, NULL)) {
|
||||
die("Failed to get parition info\n", ERROR_NOT_SUPPORTED);
|
||||
die("Failed to get partition info\n", ERROR_NOT_SUPPORTED);
|
||||
}
|
||||
|
||||
BytesPerSect = dgDrive.BytesPerSector;
|
||||
|
@ -493,7 +493,7 @@ static BOOL FormatFAT32(DWORD DriveIndex)
|
|||
// Sector 6 Backup boot sector
|
||||
// Sector 7 Backup FSInfo sector
|
||||
// Sector 8 Backup 'more boot code'
|
||||
// zero'd sectors upto ReservedSectCount
|
||||
// zeroed sectors upto ReservedSectCount
|
||||
// FAT1 ReservedSectCount to ReservedSectCount + FatSize
|
||||
// ...
|
||||
// FATn ReservedSectCount to ReservedSectCount + FatSize
|
||||
|
@ -525,7 +525,7 @@ static BOOL FormatFAT32(DWORD DriveIndex)
|
|||
die("This drive is too big for large FAT32 format\n", APPERR(ERROR_INVALID_VOLUME_SIZE));
|
||||
}
|
||||
|
||||
// Now we're commited - print some info first
|
||||
// Now we're committed - print some info first
|
||||
uprintf("Size : %s %u sectors\n", SizeToHumanReadable(piDrive.PartitionLength), TotalSectors);
|
||||
uprintf("Cluster size %d bytes, %d Bytes Per Sector\n", SectorsPerCluster*BytesPerSect, BytesPerSect);
|
||||
uprintf("Volume ID is %x:%x\n", VolumeId>>16, VolumeId&0xffff);
|
||||
|
@ -534,7 +534,7 @@ static BOOL FormatFAT32(DWORD DriveIndex)
|
|||
|
||||
// Fix up the FSInfo sector
|
||||
pFAT32FsInfo->dFree_Count = (UserAreaSize/SectorsPerCluster) - 1;
|
||||
pFAT32FsInfo->dNxt_Free = 3; // clusters 0-1 resered, we used cluster 2 for the root dir
|
||||
pFAT32FsInfo->dNxt_Free = 3; // clusters 0-1 reserved, we used cluster 2 for the root dir
|
||||
|
||||
uprintf("%d Free Clusters\n", pFAT32FsInfo->dFree_Count);
|
||||
// Work out the Cluster count
|
||||
|
@ -560,7 +560,7 @@ static BOOL FormatFAT32(DWORD DriveIndex)
|
|||
}
|
||||
}
|
||||
|
||||
uprintf ("Initialising reserved sectors and FATs...\n");
|
||||
uprintf ("Initializing reserved sectors and FATs...\n");
|
||||
// Now we should write the boot sector and fsinfo twice, once at 0 and once at the backup boot sect position
|
||||
for (i=0; i<2; i++) {
|
||||
int SectorStart = (i==0) ? 0 : BackupBootSect;
|
||||
|
@ -994,7 +994,7 @@ static BOOL SetupWinPE(char drive_letter)
|
|||
uprintf("Failed to add SetupSourceDevice in %s\n", dst);
|
||||
goto out;
|
||||
}
|
||||
uprintf("Succesfully added '%s' to %s\n", setupsrcdev, dst);
|
||||
uprintf("Successfully added '%s' to %s\n", setupsrcdev, dst);
|
||||
}
|
||||
|
||||
safe_sprintf(src, sizeof(src), "%c:\\%s\\setupldr.bin", drive_letter, basedir[index]);
|
||||
|
@ -1104,7 +1104,7 @@ static BOOL RemountVolume(char drive_letter)
|
|||
uprintf("Successfully remounted %s on %s\n", &drive_guid[4], drive_name);
|
||||
} else {
|
||||
uprintf("Failed to remount %s on %s\n", &drive_guid[4], drive_name);
|
||||
// This will leave the drive unaccessible and must be flagged as an error
|
||||
// This will leave the drive inaccessible and must be flagged as an error
|
||||
FormatStatus = ERROR_SEVERITY_ERROR|FAC(FACILITY_STORAGE)|APPERR(ERROR_CANT_REMOUNT_VOLUME);
|
||||
return FALSE;
|
||||
}
|
||||
|
|
|
@ -668,7 +668,7 @@ _getopt_internal (argc, argv, optstring, longopts, longind, long_only)
|
|||
}
|
||||
else if (pfound == NULL)
|
||||
{
|
||||
/* First nonexact match found. */
|
||||
/* First inexact match found. */
|
||||
pfound = p;
|
||||
indfound = option_index;
|
||||
}
|
||||
|
@ -676,7 +676,7 @@ _getopt_internal (argc, argv, optstring, longopts, longind, long_only)
|
|||
|| pfound->has_arg != p->has_arg
|
||||
|| pfound->flag != p->flag
|
||||
|| pfound->val != p->val)
|
||||
/* Second or later nonexact match found. */
|
||||
/* Second or later inexact match found. */
|
||||
ambig = 1;
|
||||
}
|
||||
|
||||
|
@ -859,12 +859,12 @@ _getopt_internal (argc, argv, optstring, longopts, longind, long_only)
|
|||
}
|
||||
else if (pfound == NULL)
|
||||
{
|
||||
/* First nonexact match found. */
|
||||
/* First inexact match found. */
|
||||
pfound = p;
|
||||
indfound = option_index;
|
||||
}
|
||||
else
|
||||
/* Second or later nonexact match found. */
|
||||
/* Second or later inexact match found. */
|
||||
ambig = 1;
|
||||
}
|
||||
if (ambig && !exact)
|
||||
|
|
|
@ -208,7 +208,7 @@ LIBCDIO_DEPRECATED(static const driver_id_t CDIO_MAX_DEVICE_DRIVER, "please use
|
|||
/**
|
||||
The following are status codes for completion of a given cdio
|
||||
operation. By design 0 is successful completion and -1 is error
|
||||
completion. This is compatable with ioctl so those routines that
|
||||
completion. This is compatible with ioctl so those routines that
|
||||
call ioctl can just pass the value the get back (cast as this
|
||||
enum). Also, by using negative numbers for errors, the
|
||||
enumeration values below can be used in places where a positive
|
||||
|
@ -267,7 +267,7 @@ LIBCDIO_DEPRECATED(static const driver_id_t CDIO_MAX_DEVICE_DRIVER, "please use
|
|||
Eject media in CD drive if there is a routine to do so.
|
||||
|
||||
@param p_cdio the CD object to be acted upon.
|
||||
If the CD is ejected *p_cdio is free'd and p_cdio set to NULL.
|
||||
If the CD is ejected *p_cdio is freed and p_cdio set to NULL.
|
||||
*/
|
||||
driver_return_code_t cdio_eject_media (CdIo_t **p_cdio);
|
||||
|
||||
|
@ -330,7 +330,7 @@ LIBCDIO_DEPRECATED(static const driver_id_t CDIO_MAX_DEVICE_DRIVER, "please use
|
|||
|
||||
/**
|
||||
Get an array of device names in search_devices that have at least
|
||||
the capabilities listed by the capabities parameter. If
|
||||
the capabilities listed by the capabilities parameter. If
|
||||
search_devices is NULL, then we'll search all possible CD drives.
|
||||
|
||||
Capabilities have two parts to them, a "filesystem" part and an
|
||||
|
@ -347,7 +347,7 @@ LIBCDIO_DEPRECATED(static const driver_id_t CDIO_MAX_DEVICE_DRIVER, "please use
|
|||
|
||||
If "b_any" is set false then every capability listed in the
|
||||
analysis portion of capabilities (i.e. not the basic filesystem)
|
||||
must be satisified. If no analysis capabilities are specified,
|
||||
must be satisfied. If no analysis capabilities are specified,
|
||||
that's a match.
|
||||
|
||||
If "b_any" is set true, then if any of the analysis capabilities
|
||||
|
@ -477,7 +477,7 @@ LIBCDIO_DEPRECATED(static const driver_id_t CDIO_MAX_DEVICE_DRIVER, "please use
|
|||
void cdio_destroy (CdIo_t *p_cdio);
|
||||
|
||||
/**
|
||||
Get a string decribing driver_id.
|
||||
Get a string describing driver_id.
|
||||
|
||||
@param driver_id the driver you want the description for
|
||||
@return a string of driver description
|
||||
|
@ -852,7 +852,7 @@ LIBCDIO_DEPRECATED(static const driver_id_t CDIO_MAX_DEVICE_DRIVER, "please use
|
|||
Set up CD-ROM for reading using the Microsoft Windows driver. The
|
||||
device_name is the some sort of device name.
|
||||
|
||||
NULL is returned on error or there is no Microsof Windows driver.
|
||||
NULL is returned on error or there is no Microsoft Windows driver.
|
||||
*/
|
||||
CdIo_t * cdio_open_am_win32 (const char *psz_source,
|
||||
const char *psz_access_mode);
|
||||
|
@ -1016,11 +1016,11 @@ Return a list of all of the CD-ROM devices that the OS/2 driver
|
|||
int i_drive_speed );
|
||||
|
||||
/**
|
||||
Get the value associatied with key.
|
||||
Get the value associated with key.
|
||||
|
||||
@param p_cdio the CD object queried
|
||||
@param key the key to retrieve
|
||||
@return the value associatd with "key" or NULL if p_cdio is NULL
|
||||
@return the value associated with "key" or NULL if p_cdio is NULL
|
||||
or "key" does not exist.
|
||||
*/
|
||||
const char * cdio_get_arg (const CdIo_t *p_cdio, const char key[]);
|
||||
|
@ -1030,7 +1030,7 @@ Return a list of all of the CD-ROM devices that the OS/2 driver
|
|||
|
||||
@param p_cdio the CD object to set
|
||||
@param key the key to set
|
||||
@param value the value to assocaiate with key
|
||||
@param value the value to associate with key
|
||||
*/
|
||||
driver_return_code_t cdio_set_arg (CdIo_t *p_cdio, const char key[],
|
||||
const char value[]);
|
||||
|
|
|
@ -200,7 +200,7 @@ struct vol_struct_desc_s
|
|||
|
||||
/** Standard Identifier (ECMA 167r3 2/9.1.2) */
|
||||
|
||||
/* The below const definitions are to faciltate debugging of the
|
||||
/* The below const definitions are to facilitate debugging of the
|
||||
values #define'd below. */
|
||||
extern const char VSD_STD_ID_BEA01[sizeof("BEA01")-1];
|
||||
extern const char VSD_STD_ID_BOOT2[sizeof("BOOT2")-1];
|
||||
|
|
|
@ -27,7 +27,7 @@
|
|||
* filesystem library; applications include this.
|
||||
*
|
||||
* See also the ISO-9660 specification. The freely available European
|
||||
* equivalant standard is called ECMA-119.
|
||||
* equivalent standard is called ECMA-119.
|
||||
*/
|
||||
|
||||
|
||||
|
@ -78,7 +78,7 @@ typedef char dchar_t; /*! See section 7.4.1 */
|
|||
program; things are done this way so that in a debugger one can to
|
||||
refer to the enumeration value names such as in a debugger
|
||||
expression and get something. With the more common a \#define
|
||||
mechanism, the name/value assocation is lost at run time.
|
||||
mechanism, the name/value association is lost at run time.
|
||||
*/
|
||||
extern enum iso_enum1_s {
|
||||
ISO_PVD_SECTOR = 16, /**< Sector of Primary Volume Descriptor. */
|
||||
|
@ -121,7 +121,7 @@ extern enum iso_vd_enum_s {
|
|||
ISO_VD_BOOT_RECORD = 0, /**< CD is bootable */
|
||||
ISO_VD_PRIMARY = 1, /**< Is in any ISO-9660 */
|
||||
ISO_VD_SUPPLEMENTARY = 2, /**< Used by Joliet, for example */
|
||||
ISO_VD_PARITION = 3, /**< Indicates a partition of a CD */
|
||||
ISO_VD_PARTITION = 3, /**< Indicates a partition of a CD */
|
||||
ISO_VD_END = 255
|
||||
} iso_vd_enums;
|
||||
|
||||
|
@ -393,7 +393,7 @@ typedef struct iso9660_pvd_s iso9660_pvd_t;
|
|||
/*!
|
||||
\brief ISO-9660 Supplementary Volume Descriptor.
|
||||
|
||||
This is used for Joliet Extentions and is almost the same as the
|
||||
This is used for Joliet Extensions and is almost the same as the
|
||||
the primary descriptor but two unused fields, "unused1" and "unused3
|
||||
become "flags and "escape_sequences" respectively.
|
||||
*/
|
||||
|
@ -437,7 +437,7 @@ struct iso9660_svd_s {
|
|||
achar_t publisher_id[ISO_MAX_PUBLISHER_ID]; /**<
|
||||
Publisher of volume.
|
||||
If the first char-
|
||||
aracter is '_' 0x5F,
|
||||
character is '_' 0x5F,
|
||||
the remaining bytes
|
||||
specify a file
|
||||
containing the user.
|
||||
|
@ -810,7 +810,7 @@ typedef struct _iso9660_s iso9660_t;
|
|||
|
||||
/*!
|
||||
Take psz_path and a version number and turn that into a ISO-9660
|
||||
pathname. (That's just the pathname followd by ";" and the version
|
||||
pathname. (That's just the pathname followed by ";" and the version
|
||||
number. For example, mydir/file.ext -> MYDIR/FILE.EXT;1 for version
|
||||
1. The resulting ISO-9660 pathname is returned.
|
||||
*/
|
||||
|
@ -1115,7 +1115,7 @@ lsn_t iso9660_get_dir_extent(const iso9660_dir_t *p_idr);
|
|||
void iso9660_set_evd (void *pd);
|
||||
|
||||
/*!
|
||||
Return true if ISO 9660 image has extended attrributes (XA).
|
||||
Return true if ISO 9660 image has extended attributes (XA).
|
||||
*/
|
||||
bool iso9660_ifs_is_xa (const iso9660_t * p_iso);
|
||||
|
||||
|
|
|
@ -132,7 +132,7 @@ typedef struct iso_rock_px_s {
|
|||
/*! POSIX device number, PN. A PN is mandatory if the file type
|
||||
recorded in the "PX" File Mode field for a Directory Record
|
||||
indicates a character or block device (ISO_ROCK_ISCHR |
|
||||
ISO_ROCK_ISBLK). This entry is ignored for other (non-Direcotry)
|
||||
ISO_ROCK_ISBLK). This entry is ignored for other (non-Directory)
|
||||
file types. No more than one "PN" is recorded in the System Use Area
|
||||
of a Directory Record.
|
||||
|
||||
|
@ -223,7 +223,7 @@ typedef enum {
|
|||
/*! Time stamp(s) for a file. See Rock Ridge Section 4.1.6 */
|
||||
typedef struct iso_rock_tf_s {
|
||||
uint8_t flags; /**< See ISO_ROCK_TF_* bits above. */
|
||||
uint8_t time_bytes[EMPTY_ARRAY_SIZE]; /**< A homogenious array of
|
||||
uint8_t time_bytes[EMPTY_ARRAY_SIZE]; /**< A homogeneous array of
|
||||
iso9660_ltime_t or
|
||||
iso9660_dtime_t entries
|
||||
depending on flags &
|
||||
|
@ -269,7 +269,7 @@ typedef struct iso_extension_record_s {
|
|||
|
||||
typedef struct iso_rock_time_s {
|
||||
bool b_used; /**< If true, field has been set and is valid.
|
||||
Otherwise remaning fields are meaningless. */
|
||||
Otherwise remaining fields are meaningless. */
|
||||
bool b_longdate; /**< If true date format is a iso9660_ltime_t.
|
||||
Otherwise date is iso9660_dtime_t */
|
||||
union
|
||||
|
@ -361,7 +361,7 @@ int get_rock_ridge_filename(iso9660_dir_t * de, /*out*/ char * retname,
|
|||
*/
|
||||
const char *iso9660_get_rock_attr_str(posix_mode_t st_mode);
|
||||
|
||||
/** These variables are not used, but are defined to facilatate debugging
|
||||
/** These variables are not used, but are defined to facilitate debugging
|
||||
by letting us use enumerations values (which also correspond to
|
||||
\#define's inside a debugged program.
|
||||
*/
|
||||
|
|
|
@ -83,7 +83,7 @@ extern "C" {
|
|||
#define CDIO_CD_MIN_TRACK_NO 1 /**< Smallest CD track number */
|
||||
|
||||
/*! track modes (Table 350)
|
||||
reference: MMC-3 draft revsion - 10g
|
||||
reference: MMC-3 draft revision - 10g
|
||||
*/
|
||||
typedef enum {
|
||||
AUDIO, /**< 2352 byte block length */
|
||||
|
|
|
@ -92,7 +92,7 @@ extern "C" {
|
|||
Advances p_udf_direct to the the next directory entry in the
|
||||
pointed to by p_udf_dir. It also returns this as the value. NULL
|
||||
is returned on reaching the end-of-file or if an error. Also
|
||||
p_udf_dirent is free'd. If the end of is not reached the caller
|
||||
p_udf_dirent is freed. If the end of is not reached the caller
|
||||
must call udf_dirent_free() with p_udf_dirent when done with it to
|
||||
release resources.
|
||||
*/
|
||||
|
|
|
@ -26,7 +26,7 @@
|
|||
/** \brief Opaque characterset converter
|
||||
*/
|
||||
|
||||
typedef struct cdio_charset_coverter_s cdio_charset_coverter_t;
|
||||
typedef struct cdio_charset_converter_s cdio_charset_converter_t;
|
||||
|
||||
/** \brief Create a charset converter
|
||||
* \param src_charset Source charset
|
||||
|
@ -34,7 +34,7 @@ typedef struct cdio_charset_coverter_s cdio_charset_coverter_t;
|
|||
* \returns A newly allocated charset converter
|
||||
*/
|
||||
|
||||
cdio_charset_coverter_t *
|
||||
cdio_charset_converter_t *
|
||||
cdio_charset_converter_create(const char * src_charset,
|
||||
const char * dst_charset);
|
||||
|
||||
|
@ -42,7 +42,7 @@ cdio_charset_converter_create(const char * src_charset,
|
|||
* \param cnv A characterset converter
|
||||
*/
|
||||
|
||||
void cdio_charset_converter_destroy(cdio_charset_coverter_t*cnv);
|
||||
void cdio_charset_converter_destroy(cdio_charset_converter_t*cnv);
|
||||
|
||||
/** \brief Convert a string from one character set to another
|
||||
* \param cnv A charset converter
|
||||
|
@ -50,13 +50,13 @@ void cdio_charset_converter_destroy(cdio_charset_coverter_t*cnv);
|
|||
* \param src_len Length of source string
|
||||
* \param dst Returns destination string
|
||||
* \param dst_len If non NULL, returns the length of the destination string
|
||||
* \returns true if conversion was sucessful, false else.
|
||||
* \returns true if conversion was successful, false else.
|
||||
*
|
||||
* The destination string must be freed by the caller with free().
|
||||
* If you pass -1 for src_len, strlen() will be used.
|
||||
*/
|
||||
|
||||
bool cdio_charset_convert(cdio_charset_coverter_t*cnv,
|
||||
bool cdio_charset_convert(cdio_charset_converter_t*cnv,
|
||||
char * src, int src_len,
|
||||
char ** dst, int * dst_len);
|
||||
|
||||
|
@ -65,7 +65,7 @@ bool cdio_charset_convert(cdio_charset_coverter_t*cnv,
|
|||
* \param dst Returns destination string
|
||||
* \param dst_len If non NULL, returns the length of the destination string
|
||||
* \param dst_charset The characterset to convert to
|
||||
* \returns true if conversion was sucessful, false else.
|
||||
* \returns true if conversion was successful, false else.
|
||||
*
|
||||
* This is a convenience function, which creates a charset converter,
|
||||
* converts one string and destroys the charset converter.
|
||||
|
@ -80,7 +80,7 @@ bool cdio_charset_from_utf8(cdio_utf8_t * src, char ** dst,
|
|||
* \param src_len Length of the source string
|
||||
* \param dst Returns destination string (0 terminated)
|
||||
* \param src_charset The characterset to convert from
|
||||
* \returns true if conversion was sucessful, false else.
|
||||
* \returns true if conversion was successful, false else.
|
||||
*
|
||||
* This is a convenience function, which creates a charset converter,
|
||||
* converts one string and destroys the charset converter. If you pass -1
|
||||
|
@ -94,7 +94,7 @@ bool cdio_charset_to_utf8(const char *src, size_t src_len, cdio_utf8_t **dst,
|
|||
#ifdef _WIN32
|
||||
/** \brief Convert an UTF8 string to UTF-16 (allocate returned string)
|
||||
* \param str Source string
|
||||
* \returns NULL if the conversion was unsuccesful. Caller must free the
|
||||
* \returns NULL if the conversion was unsuccessful. Caller must free the
|
||||
* returned string.
|
||||
* This is a convenience function available on Windows platforms only.
|
||||
*/
|
||||
|
|
|
@ -145,7 +145,7 @@ const char *
|
|||
iso9660_get_xa_attr_str (uint16_t xa_attr);
|
||||
|
||||
/*!
|
||||
Allocates and initalizes a new iso9600_xa_t variable and returns
|
||||
Allocates and initializes a new iso9600_xa_t variable and returns
|
||||
it. The caller should free the returned result.
|
||||
|
||||
@see iso9660_xa
|
||||
|
|
|
@ -233,7 +233,7 @@ _stdio_read(void *user_data, void *buf, size_t count)
|
|||
}
|
||||
|
||||
/*!
|
||||
Deallocate resources assocaited with obj. After this obj is unusable.
|
||||
Deallocate resources associated with obj. After this obj is unusable.
|
||||
*/
|
||||
void
|
||||
cdio_stdio_destroy(CdioDataSource_t *p_obj)
|
||||
|
|
|
@ -32,7 +32,7 @@
|
|||
CdioDataSource_t * cdio_stdio_new(const char psz_path[]);
|
||||
|
||||
/*!
|
||||
Deallocate resources assocaited with obj. After this obj is unusable.
|
||||
Deallocate resources associated with obj. After this obj is unusable.
|
||||
*/
|
||||
void cdio_stdio_destroy(CdioDataSource_t *p_obj);
|
||||
|
||||
|
|
|
@ -141,7 +141,7 @@ extern "C" {
|
|||
const char * (*get_arg) (void *p_env, const char key[]);
|
||||
|
||||
/*!
|
||||
Get the block size for subsequest read requests, via a SCSI MMC
|
||||
Get the block size for subsequent read requests, via a SCSI MMC
|
||||
MODE_SENSE 6 command.
|
||||
*/
|
||||
int (*get_blocksize) ( void *p_env );
|
||||
|
@ -256,7 +256,7 @@ extern "C" {
|
|||
int (*get_track_channels) ( const void *p_env, track_t i_track );
|
||||
|
||||
/*! Return 0 if track is copy protected, 1 if not, or -1 for error
|
||||
or -2 if not implimented (yet). Is this meaningful if not an
|
||||
or -2 if not implemented (yet). Is this meaningful if not an
|
||||
audio track?
|
||||
*/
|
||||
track_flag_t (*get_track_copy_permit) ( void *p_env, track_t i_track );
|
||||
|
@ -311,7 +311,7 @@ extern "C" {
|
|||
bool (*get_track_msf) ( void *p_env, track_t i_track, msf_t *p_msf );
|
||||
|
||||
/*! Return 1 if track has pre-emphasis, 0 if not, or -1 for error
|
||||
or -2 if not implimented (yet). Is this meaningful if not an
|
||||
or -2 if not implemented (yet). Is this meaningful if not an
|
||||
audio track?
|
||||
*/
|
||||
track_flag_t (*get_track_preemphasis)
|
||||
|
@ -475,7 +475,7 @@ extern "C" {
|
|||
on a particular host. */
|
||||
extern CdIo_driver_t CdIo_driver[];
|
||||
|
||||
/* The last valid entry of Cdio_driver. -1 means uninitialzed. -2
|
||||
/* The last valid entry of Cdio_driver. -1 means uninitialized. -2
|
||||
means some sort of error.
|
||||
*/
|
||||
extern int CdIo_last_driver;
|
||||
|
|
|
@ -164,7 +164,7 @@ cdio_get_num_tracks (const CdIo_t *p_cdio)
|
|||
}
|
||||
}
|
||||
|
||||
/*! Find the track which contans lsn.
|
||||
/*! Find the track which contains lsn.
|
||||
CDIO_INVALID_TRACK is returned if the lsn outside of the CD or
|
||||
if there was some error.
|
||||
|
||||
|
|
|
@ -116,16 +116,16 @@ FILE* fopen_utf8(const char* filename, const char* mode)
|
|||
#ifdef HAVE_JOLIET
|
||||
#ifdef HAVE_ICONV
|
||||
#include <iconv.h>
|
||||
struct cdio_charset_coverter_s
|
||||
struct cdio_charset_converter_s
|
||||
{
|
||||
iconv_t ic;
|
||||
};
|
||||
|
||||
cdio_charset_coverter_t *
|
||||
cdio_charset_converter_t *
|
||||
cdio_charset_converter_create(const char * src_charset,
|
||||
const char * dst_charset)
|
||||
{
|
||||
cdio_charset_coverter_t * ret;
|
||||
cdio_charset_converter_t * ret;
|
||||
ret = calloc(1, sizeof(*ret));
|
||||
ret->ic = iconv_open(dst_charset, src_charset);
|
||||
return ret;
|
||||
|
@ -158,7 +158,7 @@ static void bgav_hexdump(uint8_t * data, int len, int linebreak)
|
|||
}
|
||||
#endif
|
||||
|
||||
void cdio_charset_converter_destroy(cdio_charset_coverter_t*cnv)
|
||||
void cdio_charset_converter_destroy(cdio_charset_converter_t*cnv)
|
||||
{
|
||||
iconv_close(cnv->ic);
|
||||
free(cnv);
|
||||
|
@ -246,7 +246,7 @@ do_convert(iconv_t cd, const char * src, int src_len,
|
|||
return true;
|
||||
}
|
||||
|
||||
bool cdio_charset_convert(cdio_charset_coverter_t*cnv,
|
||||
bool cdio_charset_convert(cdio_charset_converter_t*cnv,
|
||||
char * src, int src_len,
|
||||
char ** dst, int * dst_len)
|
||||
{
|
||||
|
|
|
@ -1103,7 +1103,7 @@ iso9660_pathname_valid_p (const char pathname[])
|
|||
|
||||
/*!
|
||||
Take pathname and a version number and turn that into a ISO-9660
|
||||
pathname. (That's just the pathname followd by ";" and the version
|
||||
pathname. (That's just the pathname followed by ";" and the version
|
||||
number. For example, mydir/file.ext -> mydir/file.ext;1 for version
|
||||
1. The resulting ISO-9660 pathname is returned.
|
||||
*/
|
||||
|
|
|
@ -1513,7 +1513,7 @@ iso9660_ifs_find_lsn_with_path(iso9660_t *p_iso, lsn_t i_lsn,
|
|||
}
|
||||
|
||||
/*!
|
||||
Return true if ISO 9660 image has extended attrributes (XA).
|
||||
Return true if ISO 9660 image has extended attributes (XA).
|
||||
*/
|
||||
bool
|
||||
iso9660_ifs_is_xa (const iso9660_t * p_iso)
|
||||
|
|
|
@ -120,7 +120,7 @@ realloc_symlink(/*in/out*/ iso9660_stat_t *p_stat, uint8_t i_grow)
|
|||
|
||||
/* Copy a long or short time from the iso_rock_tf_t into
|
||||
the specified field of a iso_rock_statbuf_t.
|
||||
non-paramater variables are p_stat, rr, and cnt.
|
||||
non-parameter variables are p_stat, rr, and cnt.
|
||||
*/
|
||||
#define add_time(FLAG, TIME_FIELD) \
|
||||
if (rr->u.TF.flags & FLAG) { \
|
||||
|
|
|
@ -81,7 +81,7 @@ setst (mode_t bits, char *chars)
|
|||
'l' for symbolic links
|
||||
's' for sockets
|
||||
'p' for fifos
|
||||
'C' for contigous data files
|
||||
'C' for contiguous data files
|
||||
'-' for regular files
|
||||
'?' for any other file type. */
|
||||
|
||||
|
|
|
@ -77,7 +77,7 @@ const char VSD_STD_ID_TEA01[] = {'T', 'E', 'A', '0', '1'};
|
|||
/*
|
||||
* The UDF specs are pretty clear on how each data structure is made
|
||||
* up, but not very clear on how they relate to each other. Here is
|
||||
* the skinny... This demostrates a filesystem with one file in the
|
||||
* the skinny... This demonstrates a filesystem with one file in the
|
||||
* root directory. Subdirectories are treated just as normal files,
|
||||
* but they have File Id Descriptors of their children as their file
|
||||
* data. As for the Anchor Volume Descriptor Pointer, it can exist in
|
||||
|
@ -220,7 +220,7 @@ udf_ff_traverse(udf_dirent_t *p_udf_dirent, char *psz_token)
|
|||
udf_dirent_t * p_udf_dirent3 =
|
||||
udf_ff_traverse(p_udf_dirent2, next_tok);
|
||||
|
||||
/* if p_udf_dirent3 is null p_udf_dirent2 is free'd. */
|
||||
/* if p_udf_dirent3 is null p_udf_dirent2 is freed. */
|
||||
return p_udf_dirent3;
|
||||
}
|
||||
}
|
||||
|
|
|
@ -228,7 +228,7 @@ typedef unsigned __int64 uintmax_t;
|
|||
|
||||
/* 7.18.4.1 Macros for minimum-width integer constants
|
||||
|
||||
Accoding to Douglas Gwyn <gwyn@arl.mil>:
|
||||
According to Douglas Gwyn <gwyn@arl.mil>:
|
||||
"This spec was changed in ISO/IEC 9899:1999 TC1; in ISO/IEC
|
||||
9899:1999 as initially published, the expansion was required
|
||||
to be an integer constant of precisely matching type, which
|
||||
|
|
|
@ -314,7 +314,7 @@ BOOL DownloadFile(const char* url, const char* file, HWND hProgressDialog)
|
|||
HttpQueryInfoA(hRequest, HTTP_QUERY_STATUS_CODE|HTTP_QUERY_FLAG_NUMBER, (LPVOID)&dwStatus, &dwSize, NULL);
|
||||
if (dwStatus != 200) {
|
||||
error_code = ERROR_INTERNET_ITEM_NOT_FOUND;
|
||||
uprintf("Unable to acess file: Server status %d\n", dwStatus);
|
||||
uprintf("Unable to access file: Server status %d\n", dwStatus);
|
||||
goto out;
|
||||
}
|
||||
dwSize = sizeof(dwTotalSize);
|
||||
|
|
12
src/parser.c
12
src/parser.c
|
@ -90,7 +90,7 @@ static wchar_t* get_token_data_line(const wchar_t* wtoken, wchar_t* wline)
|
|||
return (wline[r] == 0)?NULL:&wline[r];
|
||||
}
|
||||
|
||||
// Parse a file (ANSI or UTF-8 or UTF-16) and return the data for the first occurence of 'token'
|
||||
// Parse a file (ANSI or UTF-8 or UTF-16) and return the data for the first occurrence of 'token'
|
||||
// The returned string is UTF-8 and MUST be freed by the caller
|
||||
char* get_token_data_file(const char* token, const char* filename)
|
||||
{
|
||||
|
@ -135,7 +135,7 @@ out:
|
|||
return ret;
|
||||
}
|
||||
|
||||
// Parse a buffer (ANSI or UTF-8) and return the data for the 'n'th occurence of 'token'
|
||||
// Parse a buffer (ANSI or UTF-8) and return the data for the 'n'th occurrence of 'token'
|
||||
// The returned string is UTF-8 and MUST be freed by the caller
|
||||
char* get_token_data_buffer(const char* token, unsigned int n, const char* buffer, size_t buffer_size)
|
||||
{
|
||||
|
@ -345,7 +345,7 @@ out:
|
|||
if (fd_in != NULL) fclose(fd_in);
|
||||
if (fd_out != NULL) fclose(fd_out);
|
||||
|
||||
// If an insertion occured, delete existing file and use the new one
|
||||
// If an insertion occurred, delete existing file and use the new one
|
||||
if (ret != NULL) {
|
||||
// We're in Windows text mode => Remove CRs if requested
|
||||
fd_in = _wfopen(wtmpname, L"rb");
|
||||
|
@ -375,10 +375,10 @@ out:
|
|||
return ret;
|
||||
}
|
||||
|
||||
// Search for a specific 'src' substring data for all occurences of 'token', and replace
|
||||
// Search for a specific 'src' substring data for all occurrences of 'token', and replace
|
||||
// it with 'rep'. File can be ANSI or UNICODE and is overwritten. Parameters are UTF-8.
|
||||
// The parsed line is of the form: [ ]token[ ]data
|
||||
// Returns a pointer to rep if replacement occured, NULL otherwise
|
||||
// Returns a pointer to rep if replacement occurred, NULL otherwise
|
||||
char* replace_in_token_data(const char* filename, const char* token, const char* src, const char* rep, BOOL dos2unix)
|
||||
{
|
||||
const wchar_t* outmode[] = { L"w", L"w, ccs=UTF-8", L"w, ccs=UTF-16LE" };
|
||||
|
@ -491,7 +491,7 @@ out:
|
|||
if (fd_in != NULL) fclose(fd_in);
|
||||
if (fd_out != NULL) fclose(fd_out);
|
||||
|
||||
// If a replacement occured, delete existing file and use the new one
|
||||
// If a replacement occurred, delete existing file and use the new one
|
||||
if (ret != NULL) {
|
||||
// We're in Windows text mode => Remove CRs if requested
|
||||
fd_in = _wfopen(wtmpname, L"rb");
|
||||
|
|
|
@ -130,7 +130,7 @@ static int64_t last_iso_blocking_status;
|
|||
/*
|
||||
* The following is used to allocate slots within the progress bar
|
||||
* 0 means unused (no operation or no progress allocated to it)
|
||||
* +n means allocate exactly n bars (n percents of the progress bar)
|
||||
* +n means allocate exactly n bars (n percent of the progress bar)
|
||||
* -n means allocate a weighted slot of n from all remaining
|
||||
* bars. Eg if 80 slots remain and the sum of all negative entries
|
||||
* is 10, -4 will allocate 4/10*80 = 32 bars (32%) for OP progress
|
||||
|
@ -207,7 +207,7 @@ static BOOL DefineClusterSizes(void)
|
|||
}
|
||||
|
||||
// FAT 32
|
||||
// > 32GB FAT32 is not supported by MS and FormatEx but is achieved using fat32fomat
|
||||
// > 32GB FAT32 is not supported by MS and FormatEx but is achieved using fat32format
|
||||
// See: http://www.ridgecrop.demon.co.uk/index.htm?fat32format.htm
|
||||
// < 32 MB FAT32 is not allowed by FormatEx, so we don't bother
|
||||
|
||||
|
@ -984,7 +984,7 @@ BOOL CALLBACK ISOProc(HWND hDlg, UINT message, WPARAM wParam, LPARAM lParam)
|
|||
UpdateWindow(hDlg);
|
||||
return TRUE;
|
||||
case UM_ISO_EXIT:
|
||||
// Just hide and recentrer the dialog
|
||||
// Just hide and recenter the dialog
|
||||
ShowWindow(hDlg, SW_HIDE);
|
||||
iso_op_in_progress = FALSE;
|
||||
return TRUE;
|
||||
|
@ -1804,7 +1804,7 @@ static INT_PTR CALLBACK MainCallback(HWND hDlg, UINT message, WPARAM wParam, LPA
|
|||
uprintf("\r\n");
|
||||
GetUSBDevices(DeviceNum);
|
||||
if (!IS_ERROR(FormatStatus)) {
|
||||
// This is the only way to achieve instantenous progress transition to 100%
|
||||
// This is the only way to achieve instantaneous progress transition to 100%
|
||||
SendMessage(hProgress, PBM_SETRANGE, 0, ((MAX_PROGRESS+1)<<16) & 0xFFFF0000);
|
||||
SendMessage(hProgress, PBM_SETPOS, (MAX_PROGRESS+1), 0);
|
||||
SendMessage(hProgress, PBM_SETRANGE, 0, (MAX_PROGRESS<<16) & 0xFFFF0000);
|
||||
|
|
|
@ -63,7 +63,7 @@ BEGIN
|
|||
COMBOBOX IDC_DISK_ID,119,246,73,30,CBS_DROPDOWNLIST | NOT WS_VISIBLE | WS_VSCROLL | WS_TABSTOP
|
||||
CONTROL "Add fixes for old BIOSes (extra partition, align, etc.)",IDC_EXTRA_PARTITION,
|
||||
"Button",BS_AUTOCHECKBOX | WS_TABSTOP,13,235,184,10
|
||||
CONTROL "List fixed (non-flash) or unpartitionned USB disks",IDC_ENABLE_FIXED_DISKS,
|
||||
CONTROL "List fixed (non-flash) or unpartitioned USB disks",IDC_ENABLE_FIXED_DISKS,
|
||||
"Button",BS_AUTOCHECKBOX | WS_TABSTOP,13,222,185,10
|
||||
PUSHBUTTON "Log",IDC_LOG,62,291,18,14
|
||||
END
|
||||
|
|
|
@ -574,7 +574,7 @@ INT_PTR CALLBACK NotificationCallback(HWND hDlg, UINT message, WPARAM wParam, LP
|
|||
}
|
||||
return (INT_PTR)TRUE;
|
||||
case WM_CTLCOLORSTATIC:
|
||||
// Change the background colour for static text and icon
|
||||
// Change the background color for static text and icon
|
||||
SetBkMode((HDC)wParam, TRANSPARENT);
|
||||
if ((HWND)lParam == GetDlgItem(hDlg, IDC_NOTIFICATION_LINE)) {
|
||||
return (INT_PTR)separator_brush;
|
||||
|
|
|
@ -94,7 +94,7 @@ SysType msdos_systypes[] = {
|
|||
{ 0x88, N_("Linux Plaintext") },
|
||||
{ 0x8e, N_("Linux LVM") },
|
||||
{ 0x93, N_("Amoeba") },
|
||||
/*This guys created a seperate partition for badblocks?! */
|
||||
/*This guys created a separate partition for badblocks?! */
|
||||
{ 0x94, N_("Amoeba BBT") },
|
||||
{ 0x9f, N_("BSD/OS") },
|
||||
{ 0xa0, N_("Thinkpad Hibernation") },
|
||||
|
|
|
@ -133,7 +133,7 @@ BOOL InstallSyslinux(DWORD drive_index, char drive_letter)
|
|||
goto out;
|
||||
}
|
||||
|
||||
uprintf("Succesfully wrote '%s'\n", ldlinux_sys);
|
||||
uprintf("Successfully wrote '%s'\n", ldlinux_sys);
|
||||
if (dt != DT_ISO)
|
||||
UpdateProgress(OP_DOS, -1.0f);
|
||||
|
||||
|
@ -203,7 +203,7 @@ BOOL InstallSyslinux(DWORD drive_index, char drive_letter)
|
|||
goto out;
|
||||
}
|
||||
|
||||
uprintf("Succesfully wrote Syslinux boot record\n");
|
||||
uprintf("Successfully wrote Syslinux boot record\n");
|
||||
|
||||
if (dt == DT_SYSLINUX_V5) {
|
||||
fd = fopen(ldlinux_c32, "rb");
|
||||
|
|
|
@ -14,7 +14,7 @@
|
|||
/*
|
||||
* setadv.c
|
||||
*
|
||||
* (Over)write a data item in the auxilliary data vector. To
|
||||
* (Over)write a data item in the auxiliary data vector. To
|
||||
* delete an item, set its length to zero.
|
||||
*
|
||||
* Return 0 on success, -1 on error, and set errno.
|
||||
|
|
Loading…
Add table
Add a link
Reference in a new issue