This is the mail archive of the systemtap@sourceware.org mailing list for the systemtap project.


Index Nav: [Date Index] [Subject Index] [Author Index] [Thread Index]
Message Nav: [Date Prev] [Date Next] [Thread Prev] [Thread Next]
Other format: [Raw text]

[PATCH] Remove systemtap_session::built_uprobes


For the purpose of save_uprobes, it doesn't actually matter whether
uprobes.ko was just built or was pulled from the cache.  If we have the
uprobes_path at all, go ahead and save it.
---
 buildrun.cxx | 4 +---
 main.cxx     | 2 +-
 session.cxx  | 2 --
 session.h    | 1 -
 4 files changed, 2 insertions(+), 7 deletions(-)

diff --git a/buildrun.cxx b/buildrun.cxx
index 67217c3459e5..5d3ab582c058 100644
--- a/buildrun.cxx
+++ b/buildrun.cxx
@@ -602,10 +602,8 @@ make_uprobes (systemtap_session& s)
     clog << _("uprobes rebuild exit code: ") << rc << endl;
   if (rc)
     s.set_try_server ();
-  else {
+  else
     s.uprobes_path = dir + "/uprobes.ko";
-    s.built_uprobes = true;
-  }
   return rc;
 }
 
diff --git a/main.cxx b/main.cxx
index af4be20aa6bf..f88701cba1b8 100644
--- a/main.cxx
+++ b/main.cxx
@@ -990,7 +990,7 @@ passes_0_4 (systemtap_session &s)
 	}
 
       // Copy uprobes module to the current directory.
-      if (s.save_uprobes && s.built_uprobes && !pending_interrupts)
+      if (s.save_uprobes && !s.uprobes_path.empty() && !pending_interrupts)
         {
           rc = create_dir("uprobes");
           if (! rc)
diff --git a/session.cxx b/session.cxx
index e2a518ba0538..ee4e81b72e31 100644
--- a/session.cxx
+++ b/session.cxx
@@ -145,7 +145,6 @@ systemtap_session::systemtap_session ():
   need_uprobes = false;
   need_unwind = false;
   need_symbols = false;
-  built_uprobes = false;
   uprobes_path = "";
   load_only = false;
   skip_badvars = false;
@@ -327,7 +326,6 @@ systemtap_session::systemtap_session (const systemtap_session& other,
   need_uprobes = false;
   need_unwind = false;
   need_symbols = false;
-  built_uprobes = false;
   uprobes_path = "";
   load_only = other.load_only;
   skip_badvars = other.skip_badvars;
diff --git a/session.h b/session.h
index e92fff167e88..63cacc997632 100644
--- a/session.h
+++ b/session.h
@@ -209,7 +209,6 @@ public:
   bool need_uprobes;
   bool need_unwind;
   bool need_symbols;
-  bool built_uprobes;
   std::string uprobes_path;
   std::string uprobes_hash;
   bool load_only; // flight recorder mode
-- 
1.9.3


Index Nav: [Date Index] [Subject Index] [Author Index] [Thread Index]
Message Nav: [Date Prev] [Date Next] [Thread Prev] [Thread Next]