# HG changeset patch
# User Robert McIntyre <rlm@mit.edu>
# Date 1357707485 0
# Node ID bd465da5cd0fb01fd697e37c6c6a8fd94180fe3e
# Parent  a0c0ccd22ca52a7d6d5f8e7665788a53e91ef1c3
remove USELESS code.

diff -r a0c0ccd22ca5 -r bd465da5cd0f defaults/hg-wrapper.cpp
--- a/defaults/hg-wrapper.cpp	Wed Jan 09 04:53:59 2013 +0000
+++ b/defaults/hg-wrapper.cpp	Wed Jan 09 04:58:05 2013 +0000
@@ -1,59 +1,13 @@
-#include <stdio.h>
-//#include <stdlib.h>
 #include <cstdlib>
-#include <iostream>
 #include <vector>
 #include <string>
-
-#include <algorithm>
-
 #include <unistd.h>
-//#include <numeric>
-
-
 #include <boost/algorithm/string/join.hpp>
 
-// void print_element(std::string x){
-//   std::cout << x << std::endl;
-// }
-
-
 main( int argc, char ** argv){
-
-  // remove first element of argv, the program's name
   std::vector<std::string> input(argv, argv+argc);
-  
-
-  //std::cout << input.size() << std::endl;
-  
   input[0] = std::string("hg");
-  
-  //input.insert(input.begin(),std::string("hg"));
-  
-  //std::cout << input.size() << std::endl;
-
-  // for(unsigned i = 0; i < input.size(); i++){
-  //   std::cout << input[i] << std::endl;
-    
-  // }
-
-  //for_each(input.begin(),input.end(), print_element);
- 
-
-  // std::string command = 
-  //   accumulate(input.begin(), input.end(), std::string(" "));
-  
   std::string command = boost::algorithm::join(input, " ");
-
-
-  //.c_str();
-
-  //std::cout << command << std::endl;
-
   setreuid( geteuid(),  geteuid() );
-  //envp = 0; /* blocks IFS attack on non-bash shells */
-  //system( "/usr/bin/hg", argv, envp );
   return system(command.c_str());
-  //perror( argv[0] );
-  //return errno;
 }