leoliu/ggtags — pull request #20 by oblique (2013-11-12 12:19:00+00:00)
Title: Use absolute path for --from-here parameter

I will explain the problem first.

Assume you have the following files:

`/projectpath/a.c`
```
void aa() {
}
```

`/projectpath/b/b.c`
```
void bb() {
aa();
}
```

With your terminal go to the `/projectpath/` and you open the `b/b.c` from there, after that you do `M-.` over `aa();`
Then you will receive the following error:
```
global: cannot get real path name.

Global exited abnormally with code 1 at Tue Nov 12 14:10:40
```

The reason is because the `global` command is executed with the `default-directory` variable set to `/projectpath/`. The expected behavior was to executed with the `default-directory` set to `/projectpath/b`.

I don't know why this is happening, a workaround is to use the absolute path. You can merge my workaround or you can find what sets `default-directory` to `/projectpath/`.