Merge branch 'tz/fsf-address-update'
authorJunio C Hamano <gitster@pobox.com>
Wed, 15 Nov 2017 03:14:33 +0000 (12:14 +0900)
committerJunio C Hamano <gitster@pobox.com>
Wed, 15 Nov 2017 03:14:34 +0000 (12:14 +0900)
* tz/fsf-address-update:
  Replace Free Software Foundation address in license notices
  Replace Free Software Foundation address in license notices

1  2 
contrib/completion/git-completion.bash
contrib/credential/libsecret/git-credential-libsecret.c
imap-send.c

@@@ -111,8 -111,7 +111,7 @@@ __git (
  #   GNU General Public License for more details.
  #
  #   You should have received a copy of the GNU General Public License
- #   along with this program; if not, write to the Free Software Foundation,
- #   Inc., 59 Temple Place - Suite 330, Boston, MA 02111-1307, USA.
+ #   along with this program; if not, see <http://www.gnu.org/licenses/>.
  #
  #   The latest version of this software can be obtained here:
  #
@@@ -1250,8 -1249,7 +1249,8 @@@ _git_checkout (
        --*)
                __gitcomp "
                        --quiet --ours --theirs --track --no-track --merge
 -                      --conflict= --orphan --patch
 +                      --conflict= --orphan --patch --detach --ignore-skip-worktree-bits
 +                      --recurse-submodules --no-recurse-submodules
                        "
                ;;
        *)
@@@ -2351,7 -2349,6 +2350,7 @@@ _git_config (
                advice.rmHints
                advice.statusHints
                advice.statusUoption
 +              advice.ignoredHook
                alias.
                am.keepcr
                am.threeWay
@@@ -14,8 -14,7 +14,7 @@@
   *  GNU General Public License for more details.
   *
   *  You should have received a copy of the GNU General Public License
-  *  along with this program; if not, write to the Free Software
-  *  Foundation, Inc., 59 Temple Place, Suite 330, Boston, MA  02111-1307  USA
+  *  along with this program; if not, see <http://www.gnu.org/licenses/>.
   */
  
  /*
@@@ -104,7 -103,7 +103,7 @@@ static int keyring_get(struct credentia
        items = secret_service_search_sync(service,
                                           SECRET_SCHEMA_COMPAT_NETWORK,
                                           attributes,
 -                                         SECRET_SEARCH_LOAD_SECRETS,
 +                                         SECRET_SEARCH_LOAD_SECRETS | SECRET_SEARCH_UNLOCK,
                                           NULL,
                                           &error);
        g_hash_table_unref(attributes);
diff --combined imap-send.c
@@@ -18,8 -18,7 +18,7 @@@
   *  GNU General Public License for more details.
   *
   *  You should have received a copy of the GNU General Public License
-  *  along with this program; if not, write to the Free Software
-  *  Foundation, Inc., 59 Temple Place, Suite 330, Boston, MA  02111-1307  USA
+  *  along with this program; if not, see <http://www.gnu.org/licenses/>.
   */
  
  #include "cache.h"
@@@ -684,7 -683,7 +683,7 @@@ static int parse_response_code(struct i
        struct imap *imap = ctx->imap;
        char *arg, *p;
  
 -      if (*s != '[')
 +      if (!s || *s != '[')
                return RESP_OK;         /* no response code */
        s++;
        if (!(p = strchr(s, ']'))) {
        }
        *p++ = 0;
        arg = next_arg(&s);
 +      if (!arg) {
 +              fprintf(stderr, "IMAP error: empty response code\n");
 +              return RESP_BAD;
 +      }
        if (!strcmp("UIDVALIDITY", arg)) {
                if (!(arg = next_arg(&s)) || !(ctx->uidvalidity = atoi(arg))) {
                        fprintf(stderr, "IMAP error: malformed UIDVALIDITY status\n");
@@@ -729,8 -724,7 +728,8 @@@ static int get_cmd_result(struct imap_s
  {
        struct imap *imap = ctx->imap;
        struct imap_cmd *cmdp, **pcmdp;
 -      char *cmd, *arg, *arg1;
 +      char *cmd;
 +      const char *arg, *arg1;
        int n, resp, resp2, tag;
  
        for (;;) {
                        return RESP_BAD;
  
                arg = next_arg(&cmd);
 +              if (!arg) {
 +                      fprintf(stderr, "IMAP error: empty response\n");
 +                      return RESP_BAD;
 +              }
                if (*arg == '*') {
                        arg = next_arg(&cmd);
                        if (!arg) {
                        if (cmdp->cb.cont || cmdp->cb.data)
                                imap->literal_pending = 0;
                        arg = next_arg(&cmd);
 +                      if (!arg)
 +                              arg = "";
                        if (!strcmp("OK", arg))
                                resp = DRV_OK;
                        else {