summaryrefslogtreecommitdiffstats
path: root/src/intrf.c
diff options
context:
space:
mode:
authorChristophe Grenier <grenier@cgsecurity.org>2008-06-01 17:30:03 +0200
committerChristophe Grenier <grenier@cgsecurity.org>2008-06-01 17:30:03 +0200
commit3d61b96643f3a52b0403280cb3ead6bcf9ab2c61 (patch)
tree8ebd5b754bbe1456e4dcd533a1e7534ee1292ee9 /src/intrf.c
parent5ae8782a4baeae7c0a3a9c92492f092665b0a343 (diff)
Compilation fix for system without ncurses
Diffstat (limited to 'src/intrf.c')
-rw-r--r--src/intrf.c28
1 files changed, 14 insertions, 14 deletions
diff --git a/src/intrf.c b/src/intrf.c
index 563cbdf..cbcaf2f 100644
--- a/src/intrf.c
+++ b/src/intrf.c
@@ -86,8 +86,6 @@ extern const char *monstr[];
static char intr_buffer_screen[MAX_LINES][LINE_LENGTH+1];
static int intr_nbr_line=0;
static void set_parent_directory(char *dst_directory);
-static int vaff_txt(int line, WINDOW *window, const char *_format, va_list ap) __attribute__((format(printf, 3, 0)));
-static int wmenuUpdate(WINDOW *window, const int yinfo, int y, int x, const struct MenuItem *menuItems, const unsigned int itemLength, const char *available, const int menuType, unsigned int current);
int screen_buffer_add(const char *_format, ...)
{
@@ -274,8 +272,22 @@ static void set_parent_directory(char *dst_directory)
#endif
}
+static inline char *td_getcwd(char *buf, unsigned long size)
+{
+ /* buf must non-NULL*/
+#ifdef HAVE_GETCWD
+ if(getcwd(buf, size)!=NULL)
+ return buf;
+#endif
+ buf[0]='.';
+ buf[1]='\0';
+ return buf;
+}
+
#ifdef HAVE_NCURSES
#define INTER_DIR (LINES-25+16)
+static int vaff_txt(int line, WINDOW *window, const char *_format, va_list ap) __attribute__((format(printf, 3, 0)));
+static int wmenuUpdate(WINDOW *window, const int yinfo, int y, int x, const struct MenuItem *menuItems, const unsigned int itemLength, const char *available, const int menuType, unsigned int current);
static void dir_aff_entry(WINDOW *window, struct file_info *dir_info);
static int wgetch_nodelay(WINDOW *window);
@@ -1467,18 +1479,6 @@ static int interface_partition_type_ncurses(disk_t *disk_car)
return 0;
}
-static inline char *td_getcwd(char *buf, unsigned long size)
-{
- /* buf must non-NULL*/
-#ifdef HAVE_GETCWD
- if(getcwd(buf, size)!=NULL)
- return buf;
-#endif
- buf[0]='.';
- buf[1]='\0';
- return buf;
-}
-
#if defined(DJGPP) || defined(__OS2__)
void get_dos_drive_list(struct td_list_head *list);