dd: make it recognize not only 'k' but 'K' too;
make it (partially) CONFIG_LFS-aware
This commit is contained in:
@@ -53,14 +53,6 @@ static unsigned long af;
|
||||
static unsigned long rf;
|
||||
static unsigned long sf;
|
||||
|
||||
#ifdef CONFIG_LFS
|
||||
# define LSTAT lstat64
|
||||
# define STRUCT_STAT struct stat64
|
||||
#else
|
||||
# define LSTAT lstat
|
||||
# define STRUCT_STAT struct stat
|
||||
#endif
|
||||
|
||||
struct flags_char {
|
||||
unsigned long flag;
|
||||
char optchar;
|
||||
|
@@ -41,14 +41,6 @@
|
||||
#define OPT_GENERATION 16
|
||||
static int flags;
|
||||
|
||||
#ifdef CONFIG_LFS
|
||||
# define LSTAT lstat64
|
||||
# define STRUCT_STAT struct stat64
|
||||
#else
|
||||
# define LSTAT lstat
|
||||
# define STRUCT_STAT struct stat
|
||||
#endif
|
||||
|
||||
static void list_attributes(const char *name)
|
||||
{
|
||||
unsigned long fsflags;
|
||||
|
@@ -33,13 +33,8 @@ void proceed_question(void)
|
||||
void check_plausibility(const char *device, int force)
|
||||
{
|
||||
int val;
|
||||
#ifdef CONFIG_LFS
|
||||
struct stat64 s;
|
||||
val = stat64(device, &s);
|
||||
#else
|
||||
struct stat s;
|
||||
val = stat(device, &s);
|
||||
#endif
|
||||
STRUCT_STAT s;
|
||||
val = STAT(device, &s);
|
||||
if (force)
|
||||
return;
|
||||
if(val == -1)
|
||||
|
Reference in New Issue
Block a user