/*
* WiFi-Direct UG
*
-* Copyright 2012 Samsung Electronics Co., Ltd
+* Copyright 2012-2013 Samsung Electronics Co., Ltd
-* Licensed under the Flora License, Version 1.0 (the "License");
+* Licensed under the Flora License, Version 1.1 (the "License");
* you may not use this file except in compliance with the License.
* You may obtain a copy of the License at
-* http://www.tizenopensource.org/license
+* http://floralicense.org/license
* Unless required by applicable law or agreed to in writing, software
* distributed under the License is distributed on an "AS IS" BASIS,
}
strncpy(ad->pin_number, pin, 64);
+ ad->pin_number[63] = '\0';
free(pin);
pin = NULL;
WDPOP_LOGD( "button ok: pin [%s]", ad->pin_number);
const char *txt = elm_entry_markup_to_utf8(elm_entry_entry_get((const Evas_Object *) imf_context));
if (NULL != txt) {
WDPOP_LOGD( "* text [%s], len=[%d]", txt, strlen(txt));
- strncpy(ad->pin_number, txt, sizeof(ad->pin_number));
+ strncpy(ad->pin_number, txt, 64);
+ ad->pin_number[63] = '\0';
+ free(txt);
} else {
WDPOP_LOGD( "Err!");
}