zsh-workers
 help / color / mirror / code / Atom feed
From: Clint Adams <clint@zsh.org>
To: zsh-workers@sunsite.dk
Subject: PATCH: minor zle_utils fix
Date: Sun, 16 Jan 2005 11:22:47 -0500	[thread overview]
Message-ID: <20050116162247.GA26801@scowler.net> (raw)

I think this should be uncontroversial.  Is zlegetline() meant to
convert zleline to a UTF-8 string and return that?  Then the caller will
need to free it?

Index: Src/Zle/zle_utils.c
===================================================================
RCS file: /cvsroot/zsh/zsh/Src/Zle/zle_utils.c,v
retrieving revision 1.11
diff -u -r1.11 zle_utils.c
--- Src/Zle/zle_utils.c	14 Jan 2005 13:05:25 -0000	1.11
+++ Src/Zle/zle_utils.c	16 Jan 2005 16:17:13 -0000
@@ -67,7 +67,7 @@
 sizeline(int sz)
 {
     while (sz > linesz)
-	zleline = (unsigned char *)realloc(zleline, (linesz *= 4) + 2);
+	zleline = (ZLE_STRING_T)realloc(zleline, (linesz *= 4) + 2);
 }
 
 /*
@@ -85,11 +85,6 @@
     zleline[zlecs++] = chr;
 }
 
-/*
-    return zleline;
-    return zleline;
- */
-
 /**/
 mod_export unsigned char *
 zlegetline(int *ll, int *cs)


             reply	other threads:[~2005-01-16 16:23 UTC|newest]

Thread overview: 6+ messages / expand[flat|nested]  mbox.gz  Atom feed  top
2005-01-16 16:22 Clint Adams [this message]
2005-01-17 10:40 ` Peter Stephenson
2005-01-19  1:26   ` Clint Adams
2005-01-19 10:49     ` Peter Stephenson
2005-01-22  3:35       ` Clint Adams
2005-01-22 16:22       ` Clint Adams

Reply instructions:

You may reply publicly to this message via plain-text email
using any one of the following methods:

* Save the following mbox file, import it into your mail client,
  and reply-to-all from there: mbox

  Avoid top-posting and favor interleaved quoting:
  https://en.wikipedia.org/wiki/Posting_style#Interleaved_style

* Reply using the --to, --cc, and --in-reply-to
  switches of git-send-email(1):

  git send-email \
    --in-reply-to=20050116162247.GA26801@scowler.net \
    --to=clint@zsh.org \
    --cc=zsh-workers@sunsite.dk \
    /path/to/YOUR_REPLY

  https://kernel.org/pub/software/scm/git/docs/git-send-email.html

* If your mail client supports setting the In-Reply-To header
  via mailto: links, try the mailto: link
Be sure your reply has a Subject: header at the top and a blank line before the message body.
Code repositories for project(s) associated with this public inbox

	https://git.vuxu.org/mirror/zsh/

This is a public inbox, see mirroring instructions
for how to clone and mirror all data and code used for this inbox;
as well as URLs for NNTP newsgroup(s).