Lines 1-5
Link Here
|
1 |
#include "base/application.h" |
1 |
#include "base/application.h" |
2 |
|
2 |
|
|
|
3 |
#include <libgen.h> |
3 |
#include <linux/limits.h> |
4 |
#include <linux/limits.h> |
4 |
#include <string.h> |
5 |
#include <string.h> |
5 |
|
6 |
|
Lines 11-17
using namespace std;
Link Here
|
11 |
int |
12 |
int |
12 |
application::run(int argc, char **argv) |
13 |
application::run(int argc, char **argv) |
13 |
{ |
14 |
{ |
14 |
string cmd = basename(argv[0]); |
15 |
string cmd = get_basename(argv[0]); |
15 |
|
16 |
|
16 |
if (cmd == string("pdata_tools")) { |
17 |
if (cmd == string("pdata_tools")) { |
17 |
argc--; |
18 |
argc--; |
Lines 49-55
application::usage()
Link Here
|
49 |
} |
50 |
} |
50 |
|
51 |
|
51 |
std::string |
52 |
std::string |
52 |
application::basename(std::string const &path) const |
53 |
application::get_basename(std::string const &path) const |
53 |
{ |
54 |
{ |
54 |
char buffer[PATH_MAX + 1]; |
55 |
char buffer[PATH_MAX + 1]; |
55 |
|
56 |
|