Sign Up
Log In
Log In
or
Sign Up
Places
All Projects
Status Monitor
Collapse sidebar
openSUSE:Evergreen:11.2:Test
dosfstools
dosfstools-2.11_determine-sector-size.patch
Overview
Repositories
Revisions
Requests
Users
Attributes
Meta
File dosfstools-2.11_determine-sector-size.patch of Package dosfstools
--- mkdosfs/mkdosfs.c +++ mkdosfs/mkdosfs.c @@ -1424,6 +1424,7 @@ int i = 0, pos, ch; int create = 0; unsigned long long cblocks; + int min_sector_size; if (argc && *argv) { /* What's the program name? */ char *p; @@ -1712,6 +1713,24 @@ ) die ("Will not try to make filesystem on full-disk device '%s' (use -I if wanted)"); + if (sector_size_set) + { + if (ioctl(dev, BLKSSZGET, &min_sector_size) >= 0) + if (sector_size < min_sector_size) + { + sector_size = min_sector_size; + fprintf(stderr, "Warning: sector size was set to %d (minimal for this device)\n", sector_size); + } + } + else + { + if (ioctl(dev, BLKSSZGET, &min_sector_size) >= 0) + { + sector_size = min_sector_size; + sector_size_set = 1; + } + } + establish_params (statbuf.st_rdev,statbuf.st_size); /* Establish the media parameters */
Locations
Projects
Search
Status Monitor
Help
OpenBuildService.org
Documentation
API Documentation
Code of Conduct
Contact
Support
@OBShq
Terms
openSUSE Build Service is sponsored by
The Open Build Service is an
openSUSE project
.
Sign Up
Log In
Places
Places
All Projects
Status Monitor