diff options
-rw-r--r-- | src/main.c | 11 |
1 files changed, 11 insertions, 0 deletions
@@ -23,6 +23,7 @@ #include <getopt.h> +#include <limits.h> #include <locale.h> #include <stdlib.h> #include <unistd.h> @@ -172,6 +173,7 @@ int main(int argc, char **argv) char *pub; /* Chemin de la clef publique */ bool welcome; /* Affichage de la bienvenue ? */ + char resolved[PATH_MAX]; /* RĂ©solution de nom de fichier*/ GStudyProject *project; /* Nouveau projet courant */ static struct option long_options[] = { @@ -325,6 +327,15 @@ int main(int argc, char **argv) else { + if (prj_filename != NULL) + { + prj_filename = realpath(prj_filename, resolved); + + if (prj_filename == NULL) + LOG_ERROR_N("realpath"); + + } + if (prj_filename == NULL) project = g_study_project_new(); |