xfs_growfs: drop the unstructed output

Just drop the unstructed output since we can get the structed info
from xfs_info instead.

Signed-off-by: Wanlong Gao <gaowanlong@cn.fujitsu.com>
This commit is contained in:
Wanlong Gao
2012-08-20 16:17:01 +08:00
committed by Richard W.M. Jones
parent 11b78a7107
commit faf548a4bd
2 changed files with 7 additions and 8 deletions

View File

@@ -351,7 +351,7 @@ error:
return ret;
}
char *
int
do_xfs_growfs (const char *path,
int datasec, int logsec, int rtsec,
int64_t datasize, int64_t logsize, int64_t rtsize,
@@ -359,7 +359,7 @@ do_xfs_growfs (const char *path,
{
int r;
char *buf;
char *out = NULL, *err = NULL;
char *err = NULL;
const char *argv[MAX_ARGS];
char datasize_s[64];
char logsize_s[64];
@@ -371,7 +371,7 @@ do_xfs_growfs (const char *path,
buf = sysroot_path (path);
if (buf == NULL) {
reply_with_perror ("malloc");
return NULL;
return -1;
}
ADD_ARG (argv, i, "xfs_growfs");
@@ -444,7 +444,7 @@ do_xfs_growfs (const char *path,
ADD_ARG (argv, i, buf);
ADD_ARG (argv, i, NULL);
r = commandv (&out, &err, argv);
r = commandv (NULL, &err, argv);
free (buf);
if (r == -1) {
reply_with_error ("%s: %s", path, err);
@@ -452,13 +452,12 @@ do_xfs_growfs (const char *path,
}
free (err);
return out;
return 0;
error:
if (buf) free (buf);
if (err) free (err);
if (out) free (out);
return NULL;
return -1;
}
int

View File

@@ -9299,7 +9299,7 @@ in the returned structure is defined by the API." };
{ defaults with
name = "xfs_growfs";
style = RString "info", [Pathname "path"], [OBool "datasec"; OBool "logsec"; OBool "rtsec"; OInt64 "datasize"; OInt64 "logsize"; OInt64 "rtsize"; OInt64 "rtextsize"; OInt "maxpct"];
style = RErr, [Pathname "path"], [OBool "datasec"; OBool "logsec"; OBool "rtsec"; OInt64 "datasize"; OInt64 "logsize"; OInt64 "rtsize"; OInt64 "rtextsize"; OInt "maxpct"];
proc_nr = Some 343;
optional = Some "xfs";
tests = [