hammer util: rename function to match behavior
authorSimon Schubert <simon.schubert@epfl.ch>
Tue, 4 Aug 2009 14:27:00 +0000 (16:27 +0200)
committerSimon Schubert <corecode@dragonflybsd.org>
Sun, 9 Aug 2009 08:32:27 +0000 (10:32 +0200)
cleanup_snapshots actually creates a snapshot

sbin/hammer/cmd_cleanup.c

index f1ffd9c..e40fc41 100644 (file)
@@ -73,7 +73,7 @@ static void cleanup_softlinks(const char *path, const char *snapshots_path,
                        int arg2, char *arg3);
 static int check_expired(const char *fpath, int arg2);
 
-static int cleanup_snapshots(const char *path, const char *snapshots_path,
+static int create_snapshot(const char *path, const char *snapshots_path,
                              int arg1, int arg2);
 static int cleanup_prune(const char *path, const char *snapshots_path,
                              int arg1, int arg2, int snapshots_disabled);
@@ -296,7 +296,7 @@ do_cleanup(const char *path)
                                printf("run\n");
                                cleanup_softlinks(path, snapshots_path,
                                                  arg2, arg3);
-                               r = cleanup_snapshots(path, snapshots_path,
+                               r = create_snapshot(path, snapshots_path,
                                                  arg1, arg2);
                        } else {
                                printf("skip\n");
@@ -598,7 +598,7 @@ check_expired(const char *fpath, int arg2)
  * Issue a snapshot.
  */
 static int
-cleanup_snapshots(const char *path __unused, const char *snapshots_path,
+create_snapshot(const char *path __unused, const char *snapshots_path,
                  int arg1 __unused, int arg2 __unused)
 {
        int r;