Commit 99e20b0e authored by Gabriel Genois's avatar Gabriel Genois

...

parent 0370c914
Pipeline #89 passed with stages
in 56 seconds
......@@ -6,7 +6,7 @@
/* By: ggenois <ggenois@student.le-101.fr> +:+ +: +: +:+ */
/* #+# #+ #+ #+# */
/* Created: 2018/05/19 16:03:09 by ggenois #+# ## ## #+# */
/* Updated: 2018/09/06 17:01:21 by ggenois ### #+. /#+ ###.fr */
/* Updated: 2018/11/03 21:57:42 by ggenois ### #+. /#+ ###.fr */
/* / */
/* / */
/* ************************************************************************** */
......@@ -178,7 +178,7 @@ int main(int argc, char **argv)
//i = ft_printf("Je suis un printf");
//i = ft_printf("%.2s is a string", "");
//i = ft_printf("%s is a string", "");
i = ft_printf("%% %", "test");
i = ft_printf("%S", L"米");
ft_putchar('\n');
ft_putnbr(i);
......
......@@ -6,7 +6,7 @@
/* By: ggenois <ggenois@student.le-101.fr> +:+ +: +: +:+ */
/* #+# #+ #+ #+# */
/* Created: 2018/09/04 13:56:21 by ggenois #+# ## ## #+# */
/* Updated: 2018/09/06 13:02:45 by ggenois ### #+. /#+ ###.fr */
/* Updated: 2018/11/03 21:57:54 by ggenois ### #+. /#+ ###.fr */
/* / */
/* / */
/* ************************************************************************** */
......
......@@ -6,7 +6,7 @@
/* By: ggenois <ggenois@student.le-101.fr> +:+ +: +: +:+ */
/* #+# #+ #+ #+# */
/* Created: 2018/05/19 16:09:47 by ggenois #+# ## ## #+# */
/* Updated: 2018/09/06 14:59:35 by ggenois ### #+. /#+ ###.fr */
/* Updated: 2018/11/03 22:16:41 by ggenois ### #+. /#+ ###.fr */
/* / */
/* / */
/* ************************************************************************** */
......@@ -48,12 +48,13 @@ int ftpf_strings_w(t_pfdata **dt, va_list *data)
else
{
i = 0;
while (s[i] >= 0 && s[i] != L'\0')
i++;
l = i;
while (--i >= 0)
ft_lstadd(&(*dt)->data, ft_lstnew(&s[i], sizeof(wchar_t)));
i = 0;
while (s[i] >= 0 && s[i] != L'\0')
i++;
l = i;
while (--i >= 0)
ft_lstadd(&(*dt)->data, ft_lstnew(&s[i], sizeof(wchar_t)));
}
}
return (l);
......@@ -102,7 +103,6 @@ int ftpf_string_p(t_pfdata **dt, va_list *data)
void ftpf_strings(t_pfdata **dt, va_list *data)
{
int l;
l = ftpf_getlength(dt);
if (l == 3 || (*dt)->t == 'C' || (*dt)->t == 'S')
ftpf_strings_w(dt, data);
......
......@@ -6,7 +6,7 @@
/* By: ggenois <ggenois@student.le-101.fr> +:+ +: +: +:+ */
/* #+# #+ #+ #+# */
/* Created: 2018/05/19 16:09:59 by ggenois #+# ## ## #+# */
/* Updated: 2018/09/06 15:50:55 by ggenois ### #+. /#+ ###.fr */
/* Updated: 2018/11/03 22:15:59 by ggenois ### #+. /#+ ###.fr */
/* / */
/* / */
/* ************************************************************************** */
......@@ -92,12 +92,12 @@ void ftpf_types(char **input, va_list *data, int *size)
ftpf_gettype(&dt);
ftpf_getflagsnw(&dt, data);
ftpf_getprecision(&dt, data);
//ftpf_tmp_printpfdata(&dt);
if (dt->t == 's' || dt->t == 'S' || dt->t == 'p'
|| dt->t == 'c' || dt->t == 'C')
{
ftpf_strings(&dt, data);
ftpf_numbers_put_lefpad(&dt, size);
//ftpf_tmp_printpfdata(&dt);
}
else if (dt->t != '%')
(*size) = (*size) + ftpf_numbers(&dt, data);
......@@ -105,7 +105,7 @@ void ftpf_types(char **input, va_list *data, int *size)
{
percent = ft_strnew(1);
percent[0] = '%';
ft_lstadd(&dt->data, ft_lstnew(percent, 2));
ft_lstadd(&dt->data, ft_lstnew(percent, 1));
free(percent);
ftpf_numbers_put_lefpad(&dt, size);
}
......
No preview for this file type
<?xml version="1.0" encoding="UTF-8"?>
<!DOCTYPE plist PUBLIC "-//Apple Computer//DTD PLIST 1.0//EN" "http://www.apple.com/DTDs/PropertyList-1.0.dtd">
<plist version="1.0">
<dict>
<key>CFBundleDevelopmentRegion</key>
<string>English</string>
<key>CFBundleIdentifier</key>
<string>com.apple.xcode.dsym.testunit</string>
<key>CFBundleInfoDictionaryVersion</key>
<string>6.0</string>
<key>CFBundlePackageType</key>
<string>dSYM</string>
<key>CFBundleSignature</key>
<string>????</string>
<key>CFBundleShortVersionString</key>
<string>1.0</string>
<key>CFBundleVersion</key>
<string>1</string>
</dict>
</plist>
Markdown is supported
0% or
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment