~serge-hallyn/ubuntu/quantal/lxc/lxc-fixapi

« back to all changes in this revision

Viewing changes to debian/patches/0200-liblxc

  • Committer: Serge Hallyn
  • Date: 2012-08-24 02:02:26 UTC
  • Revision ID: serge.hallyn@ubuntu.com-20120824020226-hotaieauojintzww
fix lxcapi_start to not return true when it container failed to start.

Show diffs side-by-side

added added

removed removed

Lines of Context:
1
1
Description: liblxc work by Serge Hallyn
2
2
 
3
 
Index: lxc-api-and-python/runapitests.bash
 
3
Index: lxc/runapitests.bash
4
4
===================================================================
5
5
--- /dev/null   1970-01-01 00:00:00.000000000 +0000
6
 
+++ lxc-api-and-python/runapitests.bash 2012-08-17 20:37:37.040994657 +0000
 
6
+++ lxc/runapitests.bash        2012-08-23 20:55:47.897823000 -0500
7
7
@@ -0,0 +1,32 @@
8
8
+#!/bin/bash
9
9
+
37
37
+done
38
38
+echo "All tests passed"
39
39
+cleanup
40
 
Index: lxc-api-and-python/configure.ac
 
40
Index: lxc/configure.ac
41
41
===================================================================
42
 
--- lxc-api-and-python.orig/configure.ac        2012-08-17 20:30:14.000000000 +0000
43
 
+++ lxc-api-and-python/configure.ac     2012-08-17 20:37:37.044994657 +0000
 
42
--- lxc.orig/configure.ac       2012-08-23 20:55:47.897823000 -0500
 
43
+++ lxc/configure.ac    2012-08-23 20:55:47.897823000 -0500
44
44
@@ -179,6 +179,8 @@
45
45
        src/lxc/lxc-shutdown
46
46
        src/lxc/lxc-destroy
50
50
 ])
51
51
 AC_CONFIG_COMMANDS([default],[[]],[[]])
52
52
 AC_OUTPUT
53
 
Index: lxc-api-and-python/src/Makefile.am
 
53
Index: lxc/src/Makefile.am
54
54
===================================================================
55
 
--- lxc-api-and-python.orig/src/Makefile.am     2012-08-17 20:30:14.000000000 +0000
56
 
+++ lxc-api-and-python/src/Makefile.am  2012-08-17 20:37:37.044994657 +0000
 
55
--- lxc.orig/src/Makefile.am    2012-08-23 20:55:47.897823000 -0500
 
56
+++ lxc/src/Makefile.am 2012-08-23 20:55:47.897823000 -0500
57
57
@@ -1 +1 @@
58
58
-SUBDIRS = lxc 
59
59
+SUBDIRS = lxc tests
60
 
Index: lxc-api-and-python/src/tests/Makefile.am
 
60
Index: lxc/src/tests/Makefile.am
61
61
===================================================================
62
62
--- /dev/null   1970-01-01 00:00:00.000000000 +0000
63
 
+++ lxc-api-and-python/src/tests/Makefile.am    2012-08-17 20:37:37.044994657 +0000
 
63
+++ lxc/src/tests/Makefile.am   2012-08-23 20:55:47.897823000 -0500
64
64
@@ -0,0 +1,17 @@
65
65
+LDADD = ../lxc/liblxc.so -lrt
66
66
+containertests_SOURCES = containertests.c
79
79
+       -DLXCINITDIR=\"$(LXCINITDIR)\"
80
80
+
81
81
+bin_PROGRAMS = containertests locktests startone destroytest saveconfig createtest shutdowntest get_item getkeys
82
 
Index: lxc-api-and-python/src/tests/locktests.c
 
82
Index: lxc/src/tests/locktests.c
83
83
===================================================================
84
84
--- /dev/null   1970-01-01 00:00:00.000000000 +0000
85
 
+++ lxc-api-and-python/src/tests/locktests.c    2012-08-17 20:37:37.044994657 +0000
 
85
+++ lxc/src/tests/locktests.c   2012-08-23 20:55:47.897823000 -0500
86
86
@@ -0,0 +1,239 @@
87
87
+/* liblxcapi
88
88
+ *
323
323
+out:
324
324
+       exit(ret);
325
325
+}
326
 
Index: lxc-api-and-python/src/tests/containertests.c
 
326
Index: lxc/src/tests/containertests.c
327
327
===================================================================
328
328
--- /dev/null   1970-01-01 00:00:00.000000000 +0000
329
 
+++ lxc-api-and-python/src/tests/containertests.c       2012-08-17 20:37:37.044994657 +0000
 
329
+++ lxc/src/tests/containertests.c      2012-08-23 20:55:47.897823000 -0500
330
330
@@ -0,0 +1,257 @@
331
331
+/* liblxcapi
332
332
+ *
585
585
+       lxc_container_put(c);
586
586
+       exit(ret);
587
587
+}
588
 
Index: lxc-api-and-python/src/tests/startone.c
 
588
Index: lxc/src/tests/startone.c
589
589
===================================================================
590
590
--- /dev/null   1970-01-01 00:00:00.000000000 +0000
591
 
+++ lxc-api-and-python/src/tests/startone.c     2012-08-17 20:37:37.044994657 +0000
 
591
+++ lxc/src/tests/startone.c    2012-08-23 20:55:47.897823000 -0500
592
592
@@ -0,0 +1,202 @@
593
593
+/* liblxcapi
594
594
+ *
792
792
+       lxc_container_put(c);
793
793
+       exit(ret);
794
794
+}
795
 
Index: lxc-api-and-python/src/lxc/lxc.h
 
795
Index: lxc/src/lxc/lxc.h
796
796
===================================================================
797
 
--- lxc-api-and-python.orig/src/lxc/lxc.h       2012-08-17 20:30:14.000000000 +0000
798
 
+++ lxc-api-and-python/src/lxc/lxc.h    2012-08-17 20:37:37.044994657 +0000
 
797
--- lxc.orig/src/lxc/lxc.h      2012-08-23 20:55:47.897823000 -0500
 
798
+++ lxc/src/lxc/lxc.h   2012-08-23 20:55:47.897823000 -0500
799
799
@@ -84,6 +84,7 @@
800
800
  * data was readen, < 0 otherwise
801
801
  */
835
835
 #ifdef __cplusplus
836
836
 }
837
837
 #endif
838
 
Index: lxc-api-and-python/src/lxc/lxclock.h
 
838
Index: lxc/src/lxc/lxclock.h
839
839
===================================================================
840
840
--- /dev/null   1970-01-01 00:00:00.000000000 +0000
841
 
+++ lxc-api-and-python/src/lxc/lxclock.h        2012-08-17 20:37:37.044994657 +0000
 
841
+++ lxc/src/lxc/lxclock.h       2012-08-23 20:55:47.897823000 -0500
842
842
@@ -0,0 +1,61 @@
843
843
+/* liblxcapi
844
844
+ *
901
901
+ * -1 and sem_post will leave errno set.
902
902
+ */
903
903
+extern int lxcunlock(sem_t *lock);
904
 
Index: lxc-api-and-python/src/lxc/lxc_wait.c
 
904
Index: lxc/src/lxc/lxc_wait.c
905
905
===================================================================
906
 
--- lxc-api-and-python.orig/src/lxc/lxc_wait.c  2012-08-17 20:30:14.000000000 +0000
907
 
+++ lxc-api-and-python/src/lxc/lxc_wait.c       2012-08-17 20:38:32.204996196 +0000
 
906
--- lxc.orig/src/lxc/lxc_wait.c 2012-08-23 20:55:47.897823000 -0500
 
907
+++ lxc/src/lxc/lxc_wait.c      2012-08-23 20:55:47.897823000 -0500
908
908
@@ -77,25 +77,6 @@
909
909
        .checker  = my_checker,
910
910
 };
990
990
-       return ret;
991
991
+       return lxc_wait(my_args.name, my_args.states, my_args.timeout);
992
992
 }
993
 
Index: lxc-api-and-python/src/lxc/Makefile.am
 
993
Index: lxc/src/lxc/Makefile.am
994
994
===================================================================
995
 
--- lxc-api-and-python.orig/src/lxc/Makefile.am 2012-08-17 20:30:14.000000000 +0000
996
 
+++ lxc-api-and-python/src/lxc/Makefile.am      2012-08-17 20:39:31.072997837 +0000
 
995
--- lxc.orig/src/lxc/Makefile.am        2012-08-23 20:55:47.897823000 -0500
 
996
+++ lxc/src/lxc/Makefile.am     2012-08-23 20:55:47.897823000 -0500
997
997
@@ -13,7 +13,9 @@
998
998
                list.h \
999
999
                log.h \
1041
1041
 
1042
1042
 lxc_attach_SOURCES = lxc_attach.c
1043
1043
 lxc_cgroup_SOURCES = lxc_cgroup.c
1044
 
Index: lxc-api-and-python/src/lxc/state.h
 
1044
Index: lxc/src/lxc/state.h
1045
1045
===================================================================
1046
 
--- lxc-api-and-python.orig/src/lxc/state.h     2012-08-17 20:30:14.000000000 +0000
1047
 
+++ lxc-api-and-python/src/lxc/state.h  2012-08-17 20:37:37.048994657 +0000
 
1046
--- lxc.orig/src/lxc/state.h    2012-08-23 20:55:47.897823000 -0500
 
1047
+++ lxc/src/lxc/state.h 2012-08-23 20:55:47.897823000 -0500
1048
1048
@@ -33,5 +33,6 @@
1049
1049
 
1050
1050
 extern lxc_state_t lxc_str2state(const char *state);
1052
1052
+extern int lxc_wait(char *lxcname, char *states, int timeout);
1053
1053
 
1054
1054
 #endif
1055
 
Index: lxc-api-and-python/src/lxc/lxclock.c
 
1055
Index: lxc/src/lxc/lxclock.c
1056
1056
===================================================================
1057
1057
--- /dev/null   1970-01-01 00:00:00.000000000 +0000
1058
 
+++ lxc-api-and-python/src/lxc/lxclock.c        2012-08-17 20:37:37.048994657 +0000
 
1058
+++ lxc/src/lxc/lxclock.c       2012-08-23 20:55:47.897823000 -0500
1059
1059
@@ -0,0 +1,105 @@
1060
1060
+/* liblxcapi
1061
1061
+ *
1162
1162
+               return -2;
1163
1163
+       return sem_post(sem);
1164
1164
+}
1165
 
Index: lxc-api-and-python/src/lxc/lxccontainer.h
 
1165
Index: lxc/src/lxc/lxccontainer.h
1166
1166
===================================================================
1167
1167
--- /dev/null   1970-01-01 00:00:00.000000000 +0000
1168
 
+++ lxc-api-and-python/src/lxc/lxccontainer.h   2012-08-17 20:37:37.048994657 +0000
 
1168
+++ lxc/src/lxc/lxccontainer.h  2012-08-23 20:55:47.897823000 -0500
1169
1169
@@ -0,0 +1,71 @@
1170
1170
+#include "lxclock.h"
1171
1171
+#include <stdlib.h>
1238
1238
+char ** lxc_get_valid_keys();
1239
1239
+char ** lxc_get_valid_values(char *key);
1240
1240
+#endif
1241
 
Index: lxc-api-and-python/src/lxc/confile.h
 
1241
Index: lxc/src/lxc/confile.h
1242
1242
===================================================================
1243
 
--- lxc-api-and-python.orig/src/lxc/confile.h   2012-08-17 20:30:14.000000000 +0000
1244
 
+++ lxc-api-and-python/src/lxc/confile.h        2012-08-17 20:37:37.048994657 +0000
 
1243
--- lxc.orig/src/lxc/confile.h  2012-08-23 20:55:47.897823000 -0500
 
1244
+++ lxc/src/lxc/confile.h       2012-08-23 20:55:47.897823000 -0500
1245
1245
@@ -27,6 +27,15 @@
1246
1246
 struct lxc_conf;
1247
1247
 struct lxc_list;
1266
1266
+extern int lxc_clear_config_item(struct lxc_conf *c, char *key);
1267
1267
+extern void write_config(FILE *fout, struct lxc_conf *c);
1268
1268
 #endif
1269
 
Index: lxc-api-and-python/src/lxc/lxccontainer.c
 
1269
Index: lxc/src/lxc/lxccontainer.c
1270
1270
===================================================================
1271
1271
--- /dev/null   1970-01-01 00:00:00.000000000 +0000
1272
 
+++ lxc-api-and-python/src/lxc/lxccontainer.c   2012-08-17 20:37:37.048994657 +0000
1273
 
@@ -0,0 +1,912 @@
 
1272
+++ lxc/src/lxc/lxccontainer.c  2012-08-23 21:01:46.422047344 -0500
 
1273
@@ -0,0 +1,904 @@
1274
1274
+/* liblxcapi
1275
1275
+ *
1276
1276
+ * Copyright © 2012 Serge Hallyn <serge.hallyn@ubuntu.com>.
1530
1530
+               "/sbin/init",
1531
1531
+               '\0',
1532
1532
+       };
1533
 
+       bool needreboot;
1534
1533
+
1535
1534
+       /* container exists */
1536
1535
+       if (!c)
1597
1596
+reboot:
1598
1597
+       ret = lxc_start(c->name, argv, conf);
1599
1598
+
1600
 
+       needreboot = false;
1601
 
+       if (lxclock(c->privlock, 0))
1602
 
+               return true;
1603
 
+       conf = c->lxc_conf;
1604
 
+       if (conf && conf->reboot) {
 
1599
+       if (conf->reboot) {
1605
1600
+               INFO("container requested reboot");
1606
1601
+               conf->reboot = 0;
1607
1602
+               if (conf->maincmd_fd)
1608
1603
+                       close(conf->maincmd_fd);
1609
1604
+               conf->maincmd_fd = 0;
1610
 
+               needreboot = true;
1611
 
+       }
1612
 
+       lxcunlock(c->privlock);
1613
 
+       if (needreboot)
1614
1605
+               goto reboot;
 
1606
+       }
1615
1607
+
1616
1608
+       if (daemonize) {
1617
1609
+               lxc_container_put(c);
2183
2175
+                       states[i] = lxc_state2str(i);
2184
2176
+       return MAX_STATE;
2185
2177
+}
2186
 
Index: lxc-api-and-python/src/lxc/confile.c
 
2178
Index: lxc/src/lxc/confile.c
2187
2179
===================================================================
2188
 
--- lxc-api-and-python.orig/src/lxc/confile.c   2012-08-17 20:30:14.000000000 +0000
2189
 
+++ lxc-api-and-python/src/lxc/confile.c        2012-08-17 20:40:57.869000259 +0000
 
2180
--- lxc.orig/src/lxc/confile.c  2012-08-23 20:55:47.897823000 -0500
 
2181
+++ lxc/src/lxc/confile.c       2012-08-23 20:55:47.897823000 -0500
2190
2182
@@ -42,6 +42,7 @@
2191
2183
 
2192
2184
 #include <lxc/log.h>
2878
2870
+       if (c->rootfs.pivot)
2879
2871
+               fprintf(fout, "lxc.pivotdir = %s\n", c->rootfs.pivot);
2880
2872
+}
2881
 
Index: lxc-api-and-python/src/lxc/state.c
 
2873
Index: lxc/src/lxc/state.c
2882
2874
===================================================================
2883
 
--- lxc-api-and-python.orig/src/lxc/state.c     2012-08-17 20:30:14.000000000 +0000
2884
 
+++ lxc-api-and-python/src/lxc/state.c  2012-08-17 20:37:37.052994657 +0000
 
2875
--- lxc.orig/src/lxc/state.c    2012-08-23 20:55:47.897823000 -0500
 
2876
+++ lxc/src/lxc/state.c 2012-08-23 20:55:47.897823000 -0500
2885
2877
@@ -31,9 +31,11 @@
2886
2878
 #include <sys/stat.h>
2887
2879
 #include <sys/file.h>
3003
2995
+       lxc_monitor_close(fd);
3004
2996
+       return ret;
3005
2997
+}
3006
 
Index: lxc-api-and-python/src/tests/destroytest.c
 
2998
Index: lxc/src/tests/destroytest.c
3007
2999
===================================================================
3008
3000
--- /dev/null   1970-01-01 00:00:00.000000000 +0000
3009
 
+++ lxc-api-and-python/src/tests/destroytest.c  2012-08-17 20:37:37.052994657 +0000
 
3001
+++ lxc/src/tests/destroytest.c 2012-08-23 20:55:47.897823000 -0500
3010
3002
@@ -0,0 +1,104 @@
3011
3003
+/* liblxcapi
3012
3004
+ *
3112
3104
+       lxc_container_put(c);
3113
3105
+       exit(ret);
3114
3106
+}
3115
 
Index: lxc-api-and-python/src/lxc/conf.c
 
3107
Index: lxc/src/lxc/conf.c
3116
3108
===================================================================
3117
 
--- lxc-api-and-python.orig/src/lxc/conf.c      2012-08-17 20:30:14.000000000 +0000
3118
 
+++ lxc-api-and-python/src/lxc/conf.c   2012-08-17 20:37:37.052994657 +0000
 
3109
--- lxc.orig/src/lxc/conf.c     2012-08-23 20:55:47.897823000 -0500
 
3110
+++ lxc/src/lxc/conf.c  2012-08-23 20:55:47.897823000 -0500
3119
3111
@@ -105,6 +105,9 @@
3120
3112
 #define PR_CAPBSET_DROP 24
3121
3113
 #endif
3331
3323
+       }
3332
3324
+       return 0;
3333
3325
+}
3334
 
Index: lxc-api-and-python/src/lxc/network.c
 
3326
Index: lxc/src/lxc/network.c
3335
3327
===================================================================
3336
 
--- lxc-api-and-python.orig/src/lxc/network.c   2012-08-17 20:30:14.000000000 +0000
3337
 
+++ lxc-api-and-python/src/lxc/network.c        2012-08-17 20:37:37.052994657 +0000
 
3328
--- lxc.orig/src/lxc/network.c  2012-08-23 20:55:47.897823000 -0500
 
3329
+++ lxc/src/lxc/network.c       2012-08-23 20:55:47.897823000 -0500
3338
3330
@@ -47,6 +47,7 @@
3339
3331
 
3340
3332
 #include "nl.h"
3362
3354
+               return NULL;
3363
3355
+       return lxc_network_types[type];
3364
3356
+}
3365
 
Index: lxc-api-and-python/src/lxc/network.h
 
3357
Index: lxc/src/lxc/network.h
3366
3358
===================================================================
3367
 
--- lxc-api-and-python.orig/src/lxc/network.h   2012-08-17 20:30:14.000000000 +0000
3368
 
+++ lxc-api-and-python/src/lxc/network.h        2012-08-17 20:37:37.056994657 +0000
 
3359
--- lxc.orig/src/lxc/network.h  2012-08-23 20:55:47.897823000 -0500
 
3360
+++ lxc/src/lxc/network.h       2012-08-23 20:55:47.897823000 -0500
3369
3361
@@ -122,4 +122,5 @@
3370
3362
  */
3371
3363
 extern int lxc_neigh_proxy_off(const char *name, int family);
3372
3364
 
3373
3365
+extern const char *lxc_net_type_to_str(int type);
3374
3366
 #endif
3375
 
Index: lxc-api-and-python/src/tests/saveconfig.c
 
3367
Index: lxc/src/tests/saveconfig.c
3376
3368
===================================================================
3377
3369
--- /dev/null   1970-01-01 00:00:00.000000000 +0000
3378
 
+++ lxc-api-and-python/src/tests/saveconfig.c   2012-08-17 20:37:37.056994657 +0000
 
3370
+++ lxc/src/tests/saveconfig.c  2012-08-23 20:55:47.897823000 -0500
3379
3371
@@ -0,0 +1,106 @@
3380
3372
+/* liblxcapi
3381
3373
+ *
3483
3475
+       lxc_container_put(c);
3484
3476
+       exit(ret);
3485
3477
+}
3486
 
Index: lxc-api-and-python/src/tests/createtest.c
 
3478
Index: lxc/src/tests/createtest.c
3487
3479
===================================================================
3488
3480
--- /dev/null   1970-01-01 00:00:00.000000000 +0000
3489
 
+++ lxc-api-and-python/src/tests/createtest.c   2012-08-17 20:37:37.056994657 +0000
 
3481
+++ lxc/src/tests/createtest.c  2012-08-23 20:55:47.897823000 -0500
3490
3482
@@ -0,0 +1,92 @@
3491
3483
+/* liblxcapi
3492
3484
+ *
3580
3572
+       lxc_container_put(c);
3581
3573
+       exit(ret);
3582
3574
+}
3583
 
Index: lxc-api-and-python/src/lxc/monitor.c
 
3575
Index: lxc/src/lxc/monitor.c
3584
3576
===================================================================
3585
 
--- lxc-api-and-python.orig/src/lxc/monitor.c   2012-08-17 20:30:14.000000000 +0000
3586
 
+++ lxc-api-and-python/src/lxc/monitor.c        2012-08-17 20:37:37.056994657 +0000
 
3577
--- lxc.orig/src/lxc/monitor.c  2012-08-23 20:55:47.897823000 -0500
 
3578
+++ lxc/src/lxc/monitor.c       2012-08-23 20:55:47.897823000 -0500
3587
3579
@@ -98,11 +98,28 @@
3588
3580
        return fd;
3589
3581
 }
3626
3618
 int lxc_monitor_close(int fd)
3627
3619
 {
3628
3620
        return close(fd);
3629
 
Index: lxc-api-and-python/src/tests/shutdowntest.c
 
3621
Index: lxc/src/tests/shutdowntest.c
3630
3622
===================================================================
3631
3623
--- /dev/null   1970-01-01 00:00:00.000000000 +0000
3632
 
+++ lxc-api-and-python/src/tests/shutdowntest.c 2012-08-17 20:37:37.056994657 +0000
 
3624
+++ lxc/src/tests/shutdowntest.c        2012-08-23 20:55:47.897823000 -0500
3633
3625
@@ -0,0 +1,93 @@
3634
3626
+
3635
3627
+/* liblxcapi
3724
3716
+       lxc_container_put(c);
3725
3717
+       exit(ret);
3726
3718
+}
3727
 
Index: lxc-api-and-python/src/lxc/conf.h
 
3719
Index: lxc/src/lxc/conf.h
3728
3720
===================================================================
3729
 
--- lxc-api-and-python.orig/src/lxc/conf.h      2012-08-17 20:30:14.000000000 +0000
3730
 
+++ lxc-api-and-python/src/lxc/conf.h   2012-08-17 20:39:10.168997254 +0000
 
3721
--- lxc.orig/src/lxc/conf.h     2012-08-23 20:55:47.897823000 -0500
 
3722
+++ lxc/src/lxc/conf.h  2012-08-23 20:55:47.897823000 -0500
3731
3723
@@ -203,6 +203,8 @@
3732
3724
 enum lxchooks {
3733
3725
        LXCHOOK_PRESTART, LXCHOOK_MOUNT, LXCHOOK_START,
3759
3751
 /*
3760
3752
  * Configure the container from inside
3761
3753
  */
3762
 
Index: lxc-api-and-python/doc/rootfs/Makefile.am
 
3754
Index: lxc/doc/rootfs/Makefile.am
3763
3755
===================================================================
3764
 
--- lxc-api-and-python.orig/doc/rootfs/Makefile.am      2012-08-17 20:30:14.000000000 +0000
3765
 
+++ lxc-api-and-python/doc/rootfs/Makefile.am   2012-08-17 20:37:37.056994657 +0000
 
3756
--- lxc.orig/doc/rootfs/Makefile.am     2012-08-23 20:55:47.897823000 -0500
 
3757
+++ lxc/doc/rootfs/Makefile.am  2012-08-23 20:55:47.897823000 -0500
3766
3758
@@ -1,3 +1,3 @@
3767
3759
 READMEdir=@LXCROOTFSMOUNT@
3768
3760
 
3769
3761
-README_DATA=README
3770
3762
\ No newline at end of file
3771
3763
+README_DATA=
3772
 
Index: lxc-api-and-python/src/tests/get_item.c
 
3764
Index: lxc/src/tests/get_item.c
3773
3765
===================================================================
3774
3766
--- /dev/null   1970-01-01 00:00:00.000000000 +0000
3775
 
+++ lxc-api-and-python/src/tests/get_item.c     2012-08-17 20:37:37.056994657 +0000
 
3767
+++ lxc/src/tests/get_item.c    2012-08-23 20:55:47.897823000 -0500
3776
3768
@@ -0,0 +1,308 @@
3777
3769
+/* liblxcapi
3778
3770
+ *
4082
4074
+       lxc_container_put(c);
4083
4075
+       exit(ret);
4084
4076
+};
4085
 
Index: lxc-api-and-python/src/lxc/commands.c
 
4077
Index: lxc/src/lxc/commands.c
4086
4078
===================================================================
4087
 
--- lxc-api-and-python.orig/src/lxc/commands.c  2012-08-17 20:30:14.000000000 +0000
4088
 
+++ lxc-api-and-python/src/lxc/commands.c       2012-08-17 20:37:37.056994657 +0000
 
4079
--- lxc.orig/src/lxc/commands.c 2012-08-23 20:55:47.897823000 -0500
 
4080
+++ lxc/src/lxc/commands.c      2012-08-23 20:55:47.897823000 -0500
4089
4081
@@ -305,5 +305,6 @@
4090
4082
                close(fd);
4091
4083
        }
4093
4085
+       handler->conf->maincmd_fd = fd;
4094
4086
        return ret;
4095
4087
 }
4096
 
Index: lxc-api-and-python/src/tests/getkeys.c
 
4088
Index: lxc/src/tests/getkeys.c
4097
4089
===================================================================
4098
4090
--- /dev/null   1970-01-01 00:00:00.000000000 +0000
4099
 
+++ lxc-api-and-python/src/tests/getkeys.c      2012-08-17 20:37:37.056994657 +0000
 
4091
+++ lxc/src/tests/getkeys.c     2012-08-23 20:55:47.897823000 -0500
4100
4092
@@ -0,0 +1,71 @@
4101
4093
+/* liblxcapi
4102
4094
+ *