mirror of
https://github.com/TurboGit/hubicfuse.git
synced 2026-08-01 18:32:23 +02:00
Makes fuse options shared with the fuseapi.
This is needed to be able to use the fuse credential with the new Hubic API.
This commit is contained in:
@@ -33,6 +33,8 @@ static int debug = 0;
|
||||
static int verify_ssl = 1;
|
||||
static int rhel5_mode = 0;
|
||||
|
||||
extern FuseOptions options;
|
||||
|
||||
#ifdef HAVE_OPENSSL
|
||||
#include <openssl/crypto.h>
|
||||
static pthread_mutex_t *ssl_lockarray;
|
||||
|
||||
@@ -9,6 +9,7 @@
|
||||
#define MAX_PATH_SIZE (1024 + 256 + 3)
|
||||
#define MAX_URL_SIZE (MAX_PATH_SIZE * 3)
|
||||
#define USER_AGENT "CloudFuse"
|
||||
#define OPTION_SIZE 1024
|
||||
|
||||
typedef struct curl_slist curl_slist;
|
||||
|
||||
@@ -23,6 +24,13 @@ typedef struct dir_entry
|
||||
struct dir_entry *next;
|
||||
} dir_entry;
|
||||
|
||||
typedef struct options {
|
||||
char username[OPTION_SIZE];
|
||||
char password[OPTION_SIZE];
|
||||
char cache_timeout[OPTION_SIZE];
|
||||
char verify_ssl[OPTION_SIZE];
|
||||
} FuseOptions;
|
||||
|
||||
void cloudfs_init();
|
||||
void cloudfs_set_credentials(char *username, char *password);
|
||||
int cloufds_connect();
|
||||
|
||||
+1
-9
@@ -17,9 +17,6 @@
|
||||
#include "cloudfsapi.h"
|
||||
#include "config.h"
|
||||
|
||||
|
||||
#define OPTION_SIZE 1024
|
||||
|
||||
static int cache_timeout;
|
||||
|
||||
typedef struct dir_cache
|
||||
@@ -424,12 +421,7 @@ char *get_home_dir()
|
||||
return "~";
|
||||
}
|
||||
|
||||
static struct options {
|
||||
char username[OPTION_SIZE];
|
||||
char password[OPTION_SIZE];
|
||||
char cache_timeout[OPTION_SIZE];
|
||||
char verify_ssl[OPTION_SIZE];
|
||||
} options = {
|
||||
FuseOptions options = {
|
||||
.username = "",
|
||||
.password = "",
|
||||
.cache_timeout = "600",
|
||||
|
||||
Reference in New Issue
Block a user