/* partition table tools
- Copyright (C) 2008-2010 Free Software Foundation, Inc.
+ Copyright (C) 2008-2012 Free Software Foundation, Inc.
This program is free software; you can redistribute it and/or modify
it under the terms of the GNU General Public License as published by
int
ptt_write_sector (PedDisk const *disk, void const *buf, size_t buflen)
{
- PED_ASSERT (buflen <= disk->dev->sector_size, return 0);
+ PED_ASSERT (buflen <= disk->dev->sector_size);
/* Allocate a big enough buffer for ped_device_write. */
char *s0 = ped_malloc (disk->dev->sector_size);
if (s0 == NULL)
PedSector n_sectors, void **buf)
{
char *b = ped_malloc (n_sectors * dev->sector_size);
- PED_ASSERT (b != NULL, return 0);
+ PED_ASSERT (b != NULL);
if (!ped_device_read (dev, b, start_sector, n_sectors)) {
free (b);
return 0;
int
ptt_clear_sectors (PedDevice *dev, PedSector start, PedSector n)
{
- PED_ASSERT (dev->sector_size <= sizeof zero, return 0);
+ PED_ASSERT (dev->sector_size <= sizeof zero);
PedSector n_z_sectors = sizeof zero / dev->sector_size;
PedSector n_full = n / n_z_sectors;
PedSector i;
" of %jd"),
part->geom.length,
pt_type,
- UINT32_MAX);
+ pt_lim->max_length);
return 0;
}
" of %jd"),
part->geom.start,
pt_type,
- UINT32_MAX);
+ pt_lim->max_start_sector);
return 0;
}