diff options
| author | Michael Forney <mforney@mforney.org> | 2017-06-05 00:14:02 -0700 |
|---|---|---|
| committer | Michael Forney <mforney@mforney.org> | 2017-06-05 21:45:55 -0700 |
| commit | 1f918ac05898529d8a33474f70bf7c61032a9929 (patch) | |
| tree | 50cd5babbd7d75fdac50f71ada682485ac163ddf /pkg/sshfs/patch | |
| parent | 622c42091688fe6658c488d9790d655304086fb7 (diff) | |
sshfs: Update to 2.9
Diffstat (limited to 'pkg/sshfs/patch')
8 files changed, 83 insertions, 87 deletions
diff --git a/pkg/sshfs/patch/0001-Add-nocache.c-stub.patch b/pkg/sshfs/patch/0001-Add-nocache.c-stub.patch index 3f6669d6..ced0e1c4 100644 --- a/pkg/sshfs/patch/0001-Add-nocache.c-stub.patch +++ b/pkg/sshfs/patch/0001-Add-nocache.c-stub.patch @@ -1,4 +1,4 @@ -From d58fbf8ca4a9a72ad8d72c7a6a4d765b419122f6 Mon Sep 17 00:00:00 2001 +From 1d990b641269c1b9be9e03d835444041df6cc0b8 Mon Sep 17 00:00:00 2001 From: Michael Forney <mforney@mforney.org> Date: Sun, 5 Jun 2016 17:13:58 -0700 Subject: [PATCH] Add nocache.c stub @@ -109,5 +109,5 @@ index 0000000..58d7528 + return 0; +} -- -2.9.0 +2.13.1 diff --git a/pkg/sshfs/patch/0002-Use-a-compact-array-and-free-list-for-requests.patch b/pkg/sshfs/patch/0002-Use-a-compact-array-and-free-list-for-requests.patch index 43128eb2..007991ec 100644 --- a/pkg/sshfs/patch/0002-Use-a-compact-array-and-free-list-for-requests.patch +++ b/pkg/sshfs/patch/0002-Use-a-compact-array-and-free-list-for-requests.patch @@ -1,4 +1,4 @@ -From 820d2b71f49667fe5459f5cb4be8240c3ce5ae8a Mon Sep 17 00:00:00 2001 +From 00c4f3a1d34c8fed239e42e5ee66bbd4e678bb7e Mon Sep 17 00:00:00 2001 From: Michael Forney <mforney@mforney.org> Date: Sun, 5 Jun 2016 17:25:36 -0700 Subject: [PATCH] Use a compact array and free list for requests @@ -8,10 +8,10 @@ Subject: [PATCH] Use a compact array and free list for requests 1 file changed, 80 insertions(+), 45 deletions(-) diff --git a/sshfs.c b/sshfs.c -index f41d987..32db6f4 100644 +index 8cde971..14a302d 100644 --- a/sshfs.c +++ b/sshfs.c -@@ -171,6 +171,17 @@ struct request { +@@ -173,6 +173,17 @@ struct request { struct list_head list; }; @@ -29,7 +29,7 @@ index f41d987..32db6f4 100644 struct sshfs_io { int num_reqs; pthread_cond_t finished; -@@ -245,7 +256,7 @@ struct sshfs { +@@ -247,7 +258,7 @@ struct sshfs { int slave; char *host; char *base_path; @@ -38,7 +38,7 @@ index f41d987..32db6f4 100644 pthread_mutex_t lock; pthread_mutex_t lock_write; int processing_thread_started; -@@ -1241,12 +1252,6 @@ static int do_write(struct iovec *iov, size_t count) +@@ -1243,12 +1254,6 @@ static int do_write(struct iovec *iov, size_t count) return 0; } @@ -51,7 +51,7 @@ index f41d987..32db6f4 100644 static void buf_to_iov(const struct buffer *buf, struct iovec *iov) { iov->iov_base = buf->p; -@@ -1339,6 +1344,43 @@ static void request_free(struct request *req) +@@ -1341,6 +1346,43 @@ static void request_free(struct request *req) g_free(req); } @@ -95,7 +95,7 @@ index f41d987..32db6f4 100644 static void chunk_free(struct read_chunk *chunk) { while (!list_empty(&chunk->reqs)) { -@@ -1368,21 +1410,6 @@ static void chunk_put_locked(struct read_chunk *chunk) +@@ -1370,21 +1412,6 @@ static void chunk_put_locked(struct read_chunk *chunk) pthread_mutex_unlock(&sshfs.lock); } @@ -117,7 +117,7 @@ index f41d987..32db6f4 100644 static int process_one_request(void) { int res; -@@ -1399,8 +1426,7 @@ static int process_one_request(void) +@@ -1401,8 +1428,7 @@ static int process_one_request(void) return -1; pthread_mutex_lock(&sshfs.lock); @@ -127,7 +127,7 @@ index f41d987..32db6f4 100644 if (req == NULL) fprintf(stderr, "request %i not found\n", id); else { -@@ -1412,7 +1438,7 @@ static int process_one_request(void) +@@ -1414,7 +1440,7 @@ static int process_one_request(void) sshfs.outstanding_len <= sshfs.max_outstanding_len) { pthread_cond_broadcast(&sshfs.outstanding_cond); } @@ -136,7 +136,7 @@ index f41d987..32db6f4 100644 } pthread_mutex_unlock(&sshfs.lock); if (req != NULL) { -@@ -1473,6 +1499,9 @@ static void close_conn(void) +@@ -1475,6 +1501,9 @@ static void close_conn(void) static void *process_requests(void *data_) { @@ -146,7 +146,7 @@ index f41d987..32db6f4 100644 (void) data_; while (1) { -@@ -1483,7 +1512,20 @@ static void *process_requests(void *data_) +@@ -1485,7 +1514,20 @@ static void *process_requests(void *data_) pthread_mutex_lock(&sshfs.lock); sshfs.processing_thread_started = 0; close_conn(); @@ -168,7 +168,7 @@ index f41d987..32db6f4 100644 sshfs.connver ++; sshfs.outstanding_len = 0; pthread_cond_broadcast(&sshfs.outstanding_cond); -@@ -1631,7 +1673,6 @@ static int sftp_error_to_errno(uint32_t error) +@@ -1633,7 +1675,6 @@ static int sftp_error_to_errno(uint32_t error) static void sftp_detect_uid() { int flags; @@ -176,7 +176,7 @@ index f41d987..32db6f4 100644 uint32_t replid; uint8_t type; struct buffer buf; -@@ -1641,7 +1682,7 @@ static void sftp_detect_uid() +@@ -1643,7 +1684,7 @@ static void sftp_detect_uid() buf_init(&buf, 5); buf_add_string(&buf, "."); buf_to_iov(&buf, &iov[0]); @@ -185,7 +185,7 @@ index f41d987..32db6f4 100644 goto out; buf_clear(&buf); if (sftp_read(&type, &buf) == -1) -@@ -1652,7 +1693,7 @@ static void sftp_detect_uid() +@@ -1654,7 +1695,7 @@ static void sftp_detect_uid() } if (buf_get_uint32(&buf, &replid) == -1) goto out; @@ -194,7 +194,7 @@ index f41d987..32db6f4 100644 fprintf(stderr, "bad reply ID\n"); goto out; } -@@ -1689,7 +1730,6 @@ out: +@@ -1691,7 +1732,6 @@ out: static int sftp_check_root(const char *base_path) { int flags; @@ -202,7 +202,7 @@ index f41d987..32db6f4 100644 uint32_t replid; uint8_t type; struct buffer buf; -@@ -1701,7 +1741,7 @@ static int sftp_check_root(const char *base_path) +@@ -1703,7 +1743,7 @@ static int sftp_check_root(const char *base_path) buf_init(&buf, 0); buf_add_string(&buf, remote_dir); buf_to_iov(&buf, &iov[0]); @@ -211,7 +211,7 @@ index f41d987..32db6f4 100644 goto out; buf_clear(&buf); if (sftp_read(&type, &buf) == -1) -@@ -1712,7 +1752,7 @@ static int sftp_check_root(const char *base_path) +@@ -1714,7 +1754,7 @@ static int sftp_check_root(const char *base_path) } if (buf_get_uint32(&buf, &replid) == -1) goto out; @@ -220,7 +220,7 @@ index f41d987..32db6f4 100644 fprintf(stderr, "bad reply ID\n"); goto out; } -@@ -1903,7 +1943,6 @@ static int sftp_request_send(uint8_t type, struct iovec *iov, size_t count, +@@ -1905,7 +1945,6 @@ static int sftp_request_send(uint8_t type, struct iovec *iov, size_t count, struct request **reqp) { int err; @@ -228,7 +228,7 @@ index f41d987..32db6f4 100644 struct request *req = g_new0(struct request, 1); req->want_reply = want_reply; -@@ -1914,8 +1953,6 @@ static int sftp_request_send(uint8_t type, struct iovec *iov, size_t count, +@@ -1916,8 +1955,6 @@ static int sftp_request_send(uint8_t type, struct iovec *iov, size_t count, pthread_mutex_lock(&sshfs.lock); if (begin_func) begin_func(req); @@ -237,7 +237,7 @@ index f41d987..32db6f4 100644 err = start_processing_thread(); if (err) { pthread_mutex_unlock(&sshfs.lock); -@@ -1926,21 +1963,24 @@ static int sftp_request_send(uint8_t type, struct iovec *iov, size_t count, +@@ -1928,21 +1965,24 @@ static int sftp_request_send(uint8_t type, struct iovec *iov, size_t count, while (sshfs.outstanding_len > sshfs.max_outstanding_len) pthread_cond_wait(&sshfs.outstanding_cond, &sshfs.lock); @@ -266,7 +266,7 @@ index f41d987..32db6f4 100644 pthread_mutex_unlock(&sshfs.lock); if (!rmed && !want_reply) { -@@ -2130,7 +2170,7 @@ static int sftp_readdir_send(struct request **req, struct buffer *handle) +@@ -2132,7 +2172,7 @@ static int sftp_readdir_send(struct request **req, struct buffer *handle) static int sshfs_req_pending(struct request *req) { @@ -275,7 +275,7 @@ index f41d987..32db6f4 100644 return 1; else return 0; -@@ -3336,11 +3376,6 @@ static int processing_init(void) +@@ -3338,11 +3378,6 @@ static int processing_init(void) pthread_mutex_init(&sshfs.lock, NULL); pthread_mutex_init(&sshfs.lock_write, NULL); pthread_cond_init(&sshfs.outstanding_cond, NULL); @@ -288,5 +288,5 @@ index f41d987..32db6f4 100644 } -- -2.9.0 +2.13.1 diff --git a/pkg/sshfs/patch/0003-Use-bool-instead-of-gboolean.patch b/pkg/sshfs/patch/0003-Use-bool-instead-of-gboolean.patch index 39d1e544..422b892e 100644 --- a/pkg/sshfs/patch/0003-Use-bool-instead-of-gboolean.patch +++ b/pkg/sshfs/patch/0003-Use-bool-instead-of-gboolean.patch @@ -1,4 +1,4 @@ -From b8324473e35fbcfec302955456f545572521872b Mon Sep 17 00:00:00 2001 +From 2a59f8d0b96d24dd3dc297ccc9ec6fa146c765d7 Mon Sep 17 00:00:00 2001 From: Michael Forney <mforney@mforney.org> Date: Sun, 5 Jun 2016 17:28:40 -0700 Subject: [PATCH] Use bool instead of gboolean @@ -8,10 +8,10 @@ Subject: [PATCH] Use bool instead of gboolean 1 file changed, 2 insertions(+), 1 deletion(-) diff --git a/sshfs.c b/sshfs.c -index 32db6f4..f43ae5a 100644 +index 14a302d..fc4b775 100644 --- a/sshfs.c +++ b/sshfs.c -@@ -16,6 +16,7 @@ +@@ -18,6 +18,7 @@ # include <fuse_darwin.h> #endif #include <assert.h> @@ -19,7 +19,7 @@ index 32db6f4..f43ae5a 100644 #include <stdio.h> #include <stdlib.h> #include <unistd.h> -@@ -1975,7 +1976,7 @@ static int sftp_request_send(uint8_t type, struct iovec *iov, size_t count, +@@ -1977,7 +1978,7 @@ static int sftp_request_send(uint8_t type, struct iovec *iov, size_t count, err = -EIO; if (sftp_send_iov(type, req->id, iov, count) == -1) { @@ -29,5 +29,5 @@ index 32db6f4..f43ae5a 100644 pthread_mutex_lock(&sshfs.lock); rmed = !!request_table_lookup(&sshfs.reqtab, req->id); -- -2.9.0 +2.13.1 diff --git a/pkg/sshfs/patch/0004-Use-struct-list_head-instead-of-GList.patch b/pkg/sshfs/patch/0004-Use-struct-list_head-instead-of-GList.patch index d028a336..e04e67c7 100644 --- a/pkg/sshfs/patch/0004-Use-struct-list_head-instead-of-GList.patch +++ b/pkg/sshfs/patch/0004-Use-struct-list_head-instead-of-GList.patch @@ -1,4 +1,4 @@ -From 7b8c2f9e7484db2031ff1190b85be085524dfe2b Mon Sep 17 00:00:00 2001 +From 3fb50aef5d683e8101fe1025cfa62f381487628c Mon Sep 17 00:00:00 2001 From: Michael Forney <mforney@mforney.org> Date: Sun, 5 Jun 2016 17:30:20 -0700 Subject: [PATCH] Use struct list_head instead of GList @@ -8,10 +8,10 @@ Subject: [PATCH] Use struct list_head instead of GList 1 file changed, 7 insertions(+), 9 deletions(-) diff --git a/sshfs.c b/sshfs.c -index f43ae5a..14adca5 100644 +index fc4b775..3c69852 100644 --- a/sshfs.c +++ b/sshfs.c -@@ -2180,13 +2180,13 @@ static int sshfs_req_pending(struct request *req) +@@ -2182,13 +2182,13 @@ static int sshfs_req_pending(struct request *req) static int sftp_readdir_async(struct buffer *handle, fuse_cache_dirh_t h, fuse_cache_dirfil_t filler) { @@ -28,7 +28,7 @@ index f43ae5a..14adca5 100644 while (!done || outstanding) { struct request *req; struct buffer name; -@@ -2201,16 +2201,14 @@ static int sftp_readdir_async(struct buffer *handle, fuse_cache_dirh_t h, +@@ -2203,16 +2203,14 @@ static int sftp_readdir_async(struct buffer *handle, fuse_cache_dirh_t h, break; } @@ -48,7 +48,7 @@ index f43ae5a..14adca5 100644 outstanding--; if (done) { -@@ -2244,7 +2242,7 @@ static int sftp_readdir_async(struct buffer *handle, fuse_cache_dirh_t h, +@@ -2246,7 +2244,7 @@ static int sftp_readdir_async(struct buffer *handle, fuse_cache_dirh_t h, } } } @@ -58,5 +58,5 @@ index f43ae5a..14adca5 100644 return err; } -- -2.9.0 +2.13.1 diff --git a/pkg/sshfs/patch/0005-Use-standard-C-functions.patch b/pkg/sshfs/patch/0005-Use-standard-C-functions.patch index e58cc29a..f85f34ea 100644 --- a/pkg/sshfs/patch/0005-Use-standard-C-functions.patch +++ b/pkg/sshfs/patch/0005-Use-standard-C-functions.patch @@ -1,4 +1,4 @@ -From 4714c177e2fde09cfa76609ccaf9c72d62f39bfd Mon Sep 17 00:00:00 2001 +From 71bb2f5ed36aa61bf9891948cc83ef5bbafa69ca Mon Sep 17 00:00:00 2001 From: Michael Forney <mforney@mforney.org> Date: Sun, 5 Jun 2016 17:42:29 -0700 Subject: [PATCH] Use standard C functions @@ -8,10 +8,10 @@ Subject: [PATCH] Use standard C functions 1 file changed, 60 insertions(+), 41 deletions(-) diff --git a/sshfs.c b/sshfs.c -index 14adca5..4f3bfe4 100644 +index 3c69852..e4a44f1 100644 --- a/sshfs.c +++ b/sshfs.c -@@ -637,25 +637,25 @@ static inline void buf_add_path(struct buffer *buf, const char *path) +@@ -639,25 +639,25 @@ static inline void buf_add_path(struct buffer *buf, const char *path) if (sshfs.base_path[0]) { if (path[1]) { if (sshfs.base_path[strlen(sshfs.base_path)-1] != '/') { @@ -47,7 +47,7 @@ index 14adca5..4f3bfe4 100644 } static int buf_check_get(struct buffer *buf, size_t len) -@@ -948,10 +948,9 @@ nobundle: +@@ -950,10 +950,9 @@ nobundle: pathok: #endif @@ -61,7 +61,7 @@ index 14adca5..4f3bfe4 100644 #ifdef __APPLE__ if (!newpreload || setenv("DYLD_INSERT_LIBRARIES", newpreload, 1) == -1) -@@ -962,7 +961,7 @@ pathok: +@@ -964,7 +963,7 @@ pathok: "for ssh nodelay workaround\n"); } #endif /* __APPLE__ */ @@ -70,7 +70,7 @@ index 14adca5..4f3bfe4 100644 return 0; } #endif -@@ -1342,7 +1341,7 @@ static void request_free(struct request *req) +@@ -1344,7 +1343,7 @@ static void request_free(struct request *req) { buf_free(&req->reply); sem_destroy(&req->ready); @@ -79,7 +79,7 @@ index 14adca5..4f3bfe4 100644 } static int request_table_insert(struct request_table *reqtab, struct request *req) -@@ -1390,9 +1389,9 @@ static void chunk_free(struct read_chunk *chunk) +@@ -1392,9 +1391,9 @@ static void chunk_free(struct read_chunk *chunk) rreq = list_entry(chunk->reqs.prev, struct read_req, list); list_del(&rreq->list); buf_free(&rreq->data); @@ -91,7 +91,7 @@ index 14adca5..4f3bfe4 100644 } static void chunk_put(struct read_chunk *chunk) -@@ -1944,8 +1943,10 @@ static int sftp_request_send(uint8_t type, struct iovec *iov, size_t count, +@@ -1946,8 +1945,10 @@ static int sftp_request_send(uint8_t type, struct iovec *iov, size_t count, struct request **reqp) { int err; @@ -103,7 +103,7 @@ index 14adca5..4f3bfe4 100644 req->want_reply = want_reply; req->end_func = end_func; req->data = data; -@@ -2586,7 +2587,9 @@ static int sshfs_open_common(const char *path, mode_t mode, +@@ -2588,7 +2589,9 @@ static int sshfs_open_common(const char *path, mode_t mode, if (fi->flags & O_TRUNC) pflags |= SSH_FXF_TRUNC; @@ -114,7 +114,7 @@ index 14adca5..4f3bfe4 100644 list_init(&sf->write_reqs); pthread_cond_init(&sf->write_finished, NULL); /* Assume random read after open */ -@@ -2628,7 +2631,7 @@ static int sshfs_open_common(const char *path, mode_t mode, +@@ -2630,7 +2633,7 @@ static int sshfs_open_common(const char *path, mode_t mode, fi->fh = (unsigned long) sf; } else { cache_invalidate(path); @@ -123,7 +123,7 @@ index 14adca5..4f3bfe4 100644 } buf_free(&buf); return err; -@@ -2701,7 +2704,7 @@ static void sshfs_file_put(struct sshfs_file *sf) +@@ -2703,7 +2706,7 @@ static void sshfs_file_put(struct sshfs_file *sf) { sf->refs--; if (!sf->refs) @@ -132,7 +132,7 @@ index 14adca5..4f3bfe4 100644 } static void sshfs_file_get(struct sshfs_file *sf) -@@ -2771,9 +2774,11 @@ static void sshfs_read_begin(struct request *req) +@@ -2773,9 +2776,11 @@ static void sshfs_read_begin(struct request *req) static struct read_chunk *sshfs_send_read(struct sshfs_file *sf, size_t size, off_t offset) { @@ -145,7 +145,7 @@ index 14adca5..4f3bfe4 100644 pthread_cond_init(&chunk->sio.finished, NULL); list_init(&chunk->reqs); chunk->size = size; -@@ -2787,7 +2792,9 @@ static struct read_chunk *sshfs_send_read(struct sshfs_file *sf, size_t size, +@@ -2789,7 +2794,9 @@ static struct read_chunk *sshfs_send_read(struct sshfs_file *sf, size_t size, struct read_req *rreq; size_t bsize = size < sshfs.max_read ? size : sshfs.max_read; @@ -156,7 +156,7 @@ index 14adca5..4f3bfe4 100644 rreq->sio = &chunk->sio; rreq->size = bsize; buf_init(&rreq->data, 0); -@@ -2858,7 +2865,7 @@ static int wait_chunk(struct read_chunk *chunk, char *buf, size_t size) +@@ -2860,7 +2867,7 @@ static int wait_chunk(struct read_chunk *chunk, char *buf, size_t size) size -= rreq->res; list_del(&rreq->list); buf_free(&rreq->data); @@ -165,7 +165,7 @@ index 14adca5..4f3bfe4 100644 } } -@@ -3513,9 +3520,10 @@ static int sshfs_opt_proc(void *data, const char *arg, int key, +@@ -3515,9 +3522,10 @@ static int sshfs_opt_proc(void *data, const char *arg, int key, switch (key) { case FUSE_OPT_KEY_OPT: if (is_ssh_opt(arg)) { @@ -178,7 +178,7 @@ index 14adca5..4f3bfe4 100644 return 0; } return 1; -@@ -3528,9 +3536,10 @@ static int sshfs_opt_proc(void *data, const char *arg, int key, +@@ -3530,9 +3538,10 @@ static int sshfs_opt_proc(void *data, const char *arg, int key, return 1; case KEY_PORT: @@ -191,7 +191,7 @@ index 14adca5..4f3bfe4 100644 return 0; case KEY_COMPRESS: -@@ -3538,9 +3547,10 @@ static int sshfs_opt_proc(void *data, const char *arg, int key, +@@ -3540,9 +3549,10 @@ static int sshfs_opt_proc(void *data, const char *arg, int key, return 0; case KEY_CONFIGFILE: @@ -204,7 +204,7 @@ index 14adca5..4f3bfe4 100644 return 0; case KEY_HELP: -@@ -3755,17 +3765,19 @@ static void fsname_remove_commas(char *fsname) +@@ -3757,17 +3767,19 @@ static void fsname_remove_commas(char *fsname) #if FUSE_VERSION >= 27 static char *fsname_escape_commas(char *fsnameold) { @@ -226,7 +226,7 @@ index 14adca5..4f3bfe4 100644 return fsname; } -@@ -4081,15 +4093,20 @@ int main(int argc, char *argv[]) +@@ -4088,15 +4100,20 @@ int main(int argc, char *argv[]) exit(1); } @@ -251,7 +251,7 @@ index 14adca5..4f3bfe4 100644 ssh_add_arg(sshfs.host); if (sshfs.sftp_server) sftp_server = sshfs.sftp_server; -@@ -4125,14 +4142,16 @@ int main(int argc, char *argv[]) +@@ -4132,14 +4149,16 @@ int main(int argc, char *argv[]) fsname = fsname_escape_commas(fsname); else fsname_remove_commas(fsname); @@ -273,5 +273,5 @@ index 14adca5..4f3bfe4 100644 #if FUSE_VERSION >= 26 -- -2.9.0 +2.13.1 diff --git a/pkg/sshfs/patch/0006-Add-missing-includes.patch b/pkg/sshfs/patch/0006-Add-missing-includes.patch index 968d8186..17395add 100644 --- a/pkg/sshfs/patch/0006-Add-missing-includes.patch +++ b/pkg/sshfs/patch/0006-Add-missing-includes.patch @@ -1,4 +1,4 @@ -From e969e57612df9b24df2ac16ac545466fca0989f1 Mon Sep 17 00:00:00 2001 +From dd47e1904e2b7f7359008743769a02a77b4611e2 Mon Sep 17 00:00:00 2001 From: Michael Forney <mforney@mforney.org> Date: Sun, 5 Jun 2016 18:21:02 -0700 Subject: [PATCH] Add missing includes @@ -10,10 +10,10 @@ sys/param.h for MIN 1 file changed, 2 insertions(+) diff --git a/sshfs.c b/sshfs.c -index 4f3bfe4..cd6abf6 100644 +index e4a44f1..dcc3707 100644 --- a/sshfs.c +++ b/sshfs.c -@@ -17,6 +17,7 @@ +@@ -19,6 +19,7 @@ #endif #include <assert.h> #include <stdbool.h> @@ -21,7 +21,7 @@ index 4f3bfe4..cd6abf6 100644 #include <stdio.h> #include <stdlib.h> #include <unistd.h> -@@ -37,6 +38,7 @@ +@@ -39,6 +40,7 @@ #include <sys/socket.h> #include <sys/utsname.h> #include <sys/mman.h> @@ -30,5 +30,5 @@ index 4f3bfe4..cd6abf6 100644 #include <netinet/in.h> #include <netinet/tcp.h> -- -2.9.0 +2.13.1 diff --git a/pkg/sshfs/patch/0007-Disable-uidmap-and-gidmap-support.patch b/pkg/sshfs/patch/0007-Disable-uidmap-and-gidmap-support.patch index 1a232a7d..9ecac7ad 100644 --- a/pkg/sshfs/patch/0007-Disable-uidmap-and-gidmap-support.patch +++ b/pkg/sshfs/patch/0007-Disable-uidmap-and-gidmap-support.patch @@ -1,4 +1,4 @@ -From d12abc4b94f24c52637bcb19f6ac7819cf66af10 Mon Sep 17 00:00:00 2001 +From b35559e8decc8440ed5712c3a74c225946864f38 Mon Sep 17 00:00:00 2001 From: Michael Forney <mforney@mforney.org> Date: Sun, 5 Jun 2016 18:24:16 -0700 Subject: [PATCH] Disable uidmap and gidmap support @@ -8,10 +8,10 @@ Subject: [PATCH] Disable uidmap and gidmap support 1 file changed, 16 insertions(+) diff --git a/sshfs.c b/sshfs.c -index cd6abf6..9af8814 100644 +index dcc3707..0b12ef6 100644 --- a/sshfs.c +++ b/sshfs.c -@@ -242,10 +242,12 @@ struct sshfs { +@@ -244,10 +244,12 @@ struct sshfs { int disable_hardlink; char *uid_file; char *gid_file; @@ -24,7 +24,7 @@ index cd6abf6..9af8814 100644 unsigned max_read; unsigned max_write; unsigned ssh_ver; -@@ -366,7 +368,9 @@ enum { +@@ -368,7 +370,9 @@ enum { enum { IDMAP_NONE, IDMAP_USER, @@ -34,7 +34,7 @@ index cd6abf6..9af8814 100644 }; enum { -@@ -387,7 +391,9 @@ static struct fuse_opt sshfs_opts[] = { +@@ -389,7 +393,9 @@ static struct fuse_opt sshfs_opts[] = { SSHFS_OPT("workaround=%s", workarounds, 0), SSHFS_OPT("idmap=none", idmap, IDMAP_NONE), SSHFS_OPT("idmap=user", idmap, IDMAP_USER), @@ -44,7 +44,7 @@ index cd6abf6..9af8814 100644 SSHFS_OPT("uidfile=%s", uid_file, 0), SSHFS_OPT("gidfile=%s", gid_file, 0), SSHFS_OPT("nomap=ignore", nomap, NOMAP_IGNORE), -@@ -520,6 +526,7 @@ static int list_empty(const struct list_head *head) +@@ -522,6 +528,7 @@ static int list_empty(const struct list_head *head) return head->next == head; } @@ -52,7 +52,7 @@ index cd6abf6..9af8814 100644 /* given a pointer to the uid/gid, and the mapping table, remap the * uid/gid, if necessary */ static inline int translate_id(uint32_t *id, GHashTable *map) -@@ -537,6 +544,7 @@ static inline int translate_id(uint32_t *id, GHashTable *map) +@@ -539,6 +546,7 @@ static inline int translate_id(uint32_t *id, GHashTable *map) abort(); } } @@ -60,7 +60,7 @@ index cd6abf6..9af8814 100644 static inline void buf_init(struct buffer *buf, size_t size) { -@@ -784,12 +792,14 @@ static int buf_get_attrs(struct buffer *buf, struct stat *stbuf, int *flagsp) +@@ -786,12 +794,14 @@ static int buf_get_attrs(struct buffer *buf, struct stat *stbuf, int *flagsp) if (sshfs.remote_uid_detected && uid == sshfs.remote_uid) uid = sshfs.local_uid; #endif /* __APPLE__ */ @@ -75,7 +75,7 @@ index cd6abf6..9af8814 100644 memset(stbuf, 0, sizeof(struct stat)); stbuf->st_mode = mode; -@@ -2486,12 +2496,14 @@ static int sshfs_chown(const char *path, uid_t uid, gid_t gid) +@@ -2488,12 +2498,14 @@ static int sshfs_chown(const char *path, uid_t uid, gid_t gid) if (sshfs.remote_uid_detected && uid == sshfs.local_uid) uid = sshfs.remote_uid; #endif /* __APPLE__ */ @@ -90,7 +90,7 @@ index cd6abf6..9af8814 100644 buf_init(&buf, 0); buf_add_path(&buf, path); -@@ -3805,6 +3817,7 @@ static int ssh_connect(void) +@@ -3807,6 +3819,7 @@ static int ssh_connect(void) return 0; } @@ -98,7 +98,7 @@ index cd6abf6..9af8814 100644 /* number of ':' separated fields in a passwd/group file that we care * about */ #define IDMAP_FIELDS 3 -@@ -3979,6 +3992,7 @@ static inline void load_gid_map(void) +@@ -3981,6 +3994,7 @@ static inline void load_gid_map(void) { read_id_map(sshfs.gid_file, &groupname_to_gid, "gid", &sshfs.gid_map, &sshfs.r_gid_map); } @@ -106,7 +106,7 @@ index cd6abf6..9af8814 100644 #ifdef __APPLE__ int main(int argc, char *argv[], __unused char *envp[], char **exec_path) -@@ -4046,6 +4060,7 @@ int main(int argc, char *argv[]) +@@ -4053,6 +4067,7 @@ int main(int argc, char *argv[]) if (sshfs.idmap == IDMAP_USER) sshfs.detect_uid = 1; @@ -114,7 +114,7 @@ index cd6abf6..9af8814 100644 else if (sshfs.idmap == IDMAP_FILE) { sshfs.uid_map = NULL; sshfs.gid_map = NULL; -@@ -4060,6 +4075,7 @@ int main(int argc, char *argv[]) +@@ -4067,6 +4082,7 @@ int main(int argc, char *argv[]) if (sshfs.gid_file) load_gid_map(); } @@ -123,5 +123,5 @@ index cd6abf6..9af8814 100644 free(sshfs.gid_file); -- -2.9.0 +2.13.1 diff --git a/pkg/sshfs/patch/0008-Remove-remaining-uses-of-glib.patch b/pkg/sshfs/patch/0008-Remove-remaining-uses-of-glib.patch index b21b5d34..914ec726 100644 --- a/pkg/sshfs/patch/0008-Remove-remaining-uses-of-glib.patch +++ b/pkg/sshfs/patch/0008-Remove-remaining-uses-of-glib.patch @@ -1,17 +1,17 @@ -From 4d8a47a8754e549dc75d5201547762718de8ce52 Mon Sep 17 00:00:00 2001 +From 4bbbae8849274c24b3fdbd938876ef0c1afa47f7 Mon Sep 17 00:00:00 2001 From: Michael Forney <mforney@mforney.org> Date: Sun, 5 Jun 2016 18:24:31 -0700 Subject: [PATCH] Remove remaining uses of glib --- - sshfs.c | 5 ----- - 1 file changed, 5 deletions(-) + sshfs.c | 2 -- + 1 file changed, 2 deletions(-) diff --git a/sshfs.c b/sshfs.c -index 9af8814..44c13d1 100644 +index 0b12ef6..2b274bd 100644 --- a/sshfs.c +++ b/sshfs.c -@@ -42,7 +42,6 @@ +@@ -44,7 +44,6 @@ #include <sys/poll.h> #include <netinet/in.h> #include <netinet/tcp.h> @@ -19,18 +19,14 @@ index 9af8814..44c13d1 100644 #include <pwd.h> #include <grp.h> #include <limits.h> -@@ -4011,11 +4010,7 @@ int main(int argc, char *argv[]) - if (!realpath(*exec_path, sshfs_program_path)) { +@@ -4014,7 +4013,6 @@ int main(int argc, char *argv[]) memset(sshfs_program_path, 0, PATH_MAX); } -- -- /* Until this gets fixed somewhere else. */ -- g_slice_set_config(G_SLICE_CONFIG_ALWAYS_MALLOC, TRUE); #endif /* __APPLE__ */ - g_thread_init(NULL); sshfs.blksize = 4096; /* SFTP spec says all servers should allow at least 32k I/O */ -- -2.9.0 +2.13.1 |
