Hello everyone,
I am stuck and confused about macros. I need to define a macro that returns the HOME dir of user. This is what I have so far:as you can see it does not work. If I try to put it into a regular function and try to pass homeDir with return(homeDir)Code:#define GLADE_FILE { \
char *homeDir = getenv("HOME"); \
char *tempi = "/hello.glade"; \
strcat(homeDir, tempi); \
printf("%s", homeDir); \
}
I getAny help would be great,Quote:
home-dir.c:19: warning: return makes integer from pointer without a cast
Thanks in advance.
Brad