Changeset 1e242121 in mainline


Ignore:
Timestamp:
2021-08-01T15:06:03Z (3 years ago)
Author:
Jiri Svoboda <jiri@…>
Branches:
master, serial, ticket/834-toolchain-update, topic/msim-upgrade, topic/simplify-dev-export
Children:
ba74416
Parents:
dbb42c9
Message:

Fix asprintf() returning garbage instead of empty string

When pasting an empty string into an empty text entry, this caused
application crash or garbage appearing in the text entry.

File:
1 edited

Legend:

Unmodified
Added
Removed
  • uspace/lib/c/generic/io/asprintf.c

    rdbb42c9 r1e242121  
    8989        va_end(args2);
    9090
    91         if (ret > 0) {
     91        if (ret >= 0) {
    9292                *strp = malloc(ret + 1);
    9393                if (*strp == NULL)
Note: See TracChangeset for help on using the changeset viewer.