Re: [PATCH 3/5] scripts/kconfig/nconf: dynamically alloc dialog_input_result

[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]

 



Hi,

On Mon, Aug 29, 2011 at 7:56 PM, Cheng Renquan <crquan@xxxxxxxxx> wrote:
>  int dialog_inputbox(WINDOW *main_window,
>                const char *title, const char *prompt,
> -               const char *init, char *result, int result_len)
> +               const char *init, char *result, int *result_len)
>  {
This all logic will not work, you need to have the following prototype:

int dialog_inputbox(WINDOW *main_window,
               const char *title, const char *prompt,
               const char *init, char **result, int *result_len)

as realloc(3) will give you a new pointer.

 - Arnaud
--
To unsubscribe from this list: send the line "unsubscribe linux-kbuild" in
the body of a message to majordomo@xxxxxxxxxxxxxxx
More majordomo info at  http://vger.kernel.org/majordomo-info.html


[Index of Archives]     [Linux&nblp;USB Development]     [Linux Media]     [Video for Linux]     [Linux Audio Users]     [Yosemite Secrets]     [Linux Kernel]     [Linux SCSI]

  Powered by Linux