1 2 3 4 5 6 7 8 9 10 11 12 13 14 15 16 17 18 19 20 21 22 23 24 25 26 27 28 29 30 31 32 33 34 35 36 37 38 39 40 41 42 43 44 45 46 47 48 49 50 51 52 53 54 55 56 57 58 59 60 61 62 63 64 65 66 67 68 69 70 71 72 73 74 75 76 77 78 79 80 81 82 83 84 85 86 87 88 89 90 91 92 93 94 95 96 97 98 99 100 101 102 103 104 105 106 107 108 109 110 111 112 113 114 115 116 117 118 119 120 121 122 123 124 125 126 127 128 129 130 131 132 133 134 135 136 137 138 139 140 141 142 143 144 145 146 147 148 149 150 151 152 153 154 155 156 157 158 159 160 161 162 163 164 165 166 167 168 169 170 171 172 173 174 175 176 177 178 179 180 181 182 183 184 185 186 187 188 189 190 191 192 193 194 195 196 197 198 199 200 201 202 203 204 205 206 207 208 209 210 211 212 213 214 215 216 217 218 219 220 221 222 223 224 225 226 227 228 229 230 231 232 233 234 235 236 237 238 239 240 241 242 243 244 245 246 247 248 249 250 251 252 253 254 255 256 257 258 259 260 261 262 263 264 265 266 267 268 269 270 271 272 273 274 275 276 277 278 279 280 281 282 283 284 285 286 287 288 289 290 291 292 293 294 295 296 297 298 299 300 301 302 303 304 305 306 307 308 309 310 311 312 313 314 315 316 317 318 319 320 321 322 323 324 325 326 327 328 329 330 331 332 333 334 335 336 337 338 339 340 341 342 343 344 345 346 347 348 349 350 351 352 353 354 355 356 357 358 359 360 361 362 363 364 365 366 367 368 369 370 371 372 373 374 375 376 377 378 379 380 381 382 383 384 385 386 387 388 389 390 391 392 393 394 395 396 397 398 399 400 401 402 403 404 405 406 407 408 409 410 411 412 413 414 415 416 417 418 419 420 421 422 423 424 425 426 427 428 429 430 431 432 433 434 435 436 437 438 439 440 441 442 443 444 445 446 447 448 449 450 451 452 453 454 455 456 457 458 459 460 461 462 463 464 465 466 467 468 469 470 471 472 473 474 475 476 477 478 479 480 481 482 483 484 485 486 487 488 489 490 491 492 493 494 495 496 497 498 499 500 501 502 503 504 505 506 507 508 509 510 511 512 513 514 515 516 517 518 519 520 521 522 523 524 525 526 527 528 529 530 531 532 533 534 535 536 537 538 539 540 541 542 543 544 545 546 547 548 549 550 551 552 553 554 555 556 557 558 559 560 561 562 563 564 565 566 567 568 569 570 571 572 573 574 575 576 577 578 579 580 581 582 583 584 585 586 587 588 589 590 591 592 593 594 595 596 597 598 599 600 601 602 603 604 605 606 607 608 609 610 611 612 613 614 615 616 617 618 619 620 621 622 623 624 625 626 627 628 629 630 631 632 633 634 635 636 637 638 639 640 641 642 643 644 645 646 647 648 649 650 651 652 653 654 655 656 657 658 659 660 661 662 663 664 665 666 667 668 669 670 671 672 673 674 675 676 677 678 679 680 681 682 683 684 685 686 687 688 689 690 691 692 693 694 695 696 697 698 699 700 701 702 703 704 705 706 707 708 709 710 711 712 713 714 715 716 717 718 719 720 721 722 723 724 725 726 727 728 729 730 731 732 733 734 735 736 737 738 739 740 741 742 743 744 745 746 747 748 749 750 751 752 753 754 755 756 757 758 759 760 761 762 763 764 765 766 767 768 769 770 771 772 773 774 775 776 777 778 779 780 781 782 783 784 785 786 787 788 789 790 791 792 793 794 795 796 797 798 799 800 801 802 803 804 805 806 807 808 809 810 811 812 813 814 815 816 817 818 819 820 821 822 823 824 825 826 827 828 829 830 831 832 833 834 835 836 837 838 839 840 841 842 843 844 845 846 847 848 849 850 851 852 853 854 855 856 857 858 859 860 861 862 863 864 865 866 867 868 869 870 871 872 873 874 875 876 877 878 879 880 881 882 883 884 885 886 887 888 889 890 891 892 893 894 895 896 897 898 899 900 901 902 903 904 905 906 907 908 909 910 911 912 913 914 915 916 917 918 919 920 921 922 923 924 925 926 927 928 929 930 931 932 933 934 935 936 937 938 939 940 941 942 943 944 945 946 947 948 949 950 951 952 953 954 955 956 957 958 959 960 961 962 963 964 965 966 967 968 969 970 971 972 973 974 975 976 977 978 979 980 981 982 983 984 985 986 987 988 989 990 991 992 993 994 995 996 997 998 999 1000 1001 1002 1003 1004 1005 1006 1007 1008 1009 1010 1011 1012 1013 1014 1015 1016 1017 1018 1019 1020 1021 1022 1023 1024 1025 1026 1027 1028 1029 1030 1031 1032 1033 1034 1035 1036 1037 1038 1039 1040 1041 1042 1043 1044 1045 1046 1047 1048 1049 1050 1051 1052 1053 1054 1055 1056 1057 1058 1059 1060 1061 1062 1063 1064 1065 1066 1067 1068 1069 1070 1071 1072 1073 1074 1075 1076 1077 1078 1079 1080 1081 1082 1083 1084 1085 1086 1087 1088 1089 1090 1091 1092 1093 1094 1095 1096 1097 1098 1099 1100 1101 1102 1103 1104 1105 1106 1107 1108 1109 1110 1111 1112 1113 1114 1115 1116 1117 1118 1119 1120 1121 1122 1123 1124 1125 1126 1127 1128 1129 1130 1131 1132 1133 1134 1135 1136 1137 1138 1139 1140 1141 1142 1143 1144 1145 1146 1147 1148 1149 1150 1151 1152 1153 1154 1155 1156 1157 1158 1159 1160 1161 1162 1163 1164 1165 1166 1167 1168 1169 1170 1171 1172 1173 1174 1175 1176 1177 1178 1179 1180 1181 1182 1183 1184 1185 1186 1187 1188 1189 1190 1191 1192 1193 1194 1195 1196 1197 1198 1199 1200 1201 1202 1203 1204 1205 1206 1207 1208 1209 1210 1211 1212 1213 1214 1215 1216 1217 1218 1219 1220 1221 1222 1223 1224 1225 1226 1227 1228 1229 1230 1231 1232 1233 1234 1235 1236 1237 1238 1239 1240 1241 1242 1243 1244 1245 1246 1247 1248 1249 1250 1251 1252 1253 1254 1255 1256 1257 1258 1259 1260 1261 1262 1263 1264 1265 1266 1267 1268 1269 1270 1271 1272 1273 1274 1275 1276 1277 1278 1279 1280 1281 1282 1283 1284 1285 1286 1287 1288 1289 1290 1291 1292 1293 1294 1295 1296 1297 1298 1299 1300 1301 1302 1303 1304 1305 1306 1307 1308 1309 1310 1311 1312 1313 1314 1315 1316 1317 1318 1319 1320 1321 1322 1323 1324 1325 1326 1327 1328 1329 1330 1331 1332 1333 1334 1335 1336 1337 1338 1339 1340 1341 1342 1343 1344 1345 1346 1347 1348 1349 1350 1351 1352 1353 1354 1355 1356 1357 1358 1359 1360 1361 1362 1363 1364 1365 1366 1367 1368 1369 1370 1371 1372 1373 1374 1375 1376 1377 1378 1379 1380 1381 1382 1383 1384 1385 1386 1387 1388 1389 1390 1391 1392 1393 1394 1395 1396 1397 1398 1399 1400 1401 1402 1403 1404 1405 1406 1407 1408 1409 1410 1411 1412 1413 1414 1415 1416 1417 1418 1419 1420 1421 1422 1423 1424 1425 1426 1427 1428 1429 1430 1431 1432 1433 1434 1435 1436 1437 1438 1439 1440 1441 1442 1443 1444 1445 1446 1447 1448 1449 1450 1451 1452 1453 1454 1455 1456 1457 1458 1459 1460 1461 1462 1463 1464 1465 1466 1467 1468 1469 1470 1471 1472 1473 1474 1475 1476 1477 1478 1479 1480 1481 1482 1483 1484 1485 1486 1487 1488 1489 1490 1491 1492 1493 1494 1495 1496 1497 1498 1499 1500 1501 1502 1503 1504 1505 1506 1507 1508 1509 1510 1511 1512 1513 1514 1515 1516 1517 1518 1519 1520 1521 1522 1523 1524 1525 1526 1527 1528 1529 1530 1531 1532 1533 1534 1535 1536 1537 1538 1539 1540 1541 1542 1543 1544 1545 1546 1547 1548 1549 1550 1551 1552 1553 1554 1555 1556 1557 1558 1559 1560 1561 1562 1563 1564 1565 1566 1567 1568 1569 1570 1571 1572 1573 1574 1575 1576 1577 1578 1579 1580 1581 1582 1583 1584 1585 1586 1587 1588 1589 1590 1591 1592 1593 1594 1595 1596 1597 1598 1599 1600 1601 1602 1603 1604 1605 1606 1607 1608 1609 1610 1611 1612 1613 1614 1615 1616 1617 1618 1619 1620 1621 1622 1623 1624 1625 1626 1627 1628 1629 1630 1631 1632 1633 1634 1635 1636 1637 1638 1639 1640 1641 1642 1643 1644 1645 1646 1647 1648 1649 1650 1651 1652 1653 1654 1655 1656 1657 1658 1659 1660 1661 1662 1663 1664 1665 1666 1667 1668 1669 1670 1671 1672 1673 1674 1675 1676 1677 1678 1679 1680 1681 1682 1683 1684 1685 1686 1687 1688 1689 1690 1691 1692 1693 1694 1695 1696 1697 1698 1699 1700 1701 1702 1703 1704 1705 1706 1707 1708 1709 1710 1711 1712 1713 1714 1715 1716 1717 1718 1719 1720 1721 1722 1723 1724 1725 1726 1727 1728 1729 1730 1731 1732 1733 1734 1735 1736 1737 1738 1739 1740 1741 1742 1743 1744 1745 1746 1747 1748 1749 1750 1751 1752 1753 1754 1755 1756 1757 1758 1759 1760 1761 1762 1763 1764 1765 1766 1767 1768 1769 1770 1771 1772 1773 1774 1775 1776 1777 1778 1779 1780 1781 1782 1783 1784 1785 1786 1787 1788 1789 1790 1791 1792 1793 1794 1795 1796 1797 1798 1799 1800 1801 1802 1803 1804 1805 1806 1807 1808 1809 1810 1811 1812 1813 1814 1815 1816 1817 1818 1819 1820 1821 1822 1823 1824 1825 1826 1827 1828 1829 1830 1831 1832 1833 1834 1835 1836 1837 1838 1839 1840 1841 1842 1843 1844 1845 1846 1847 1848 1849 1850 1851 1852 1853 1854 1855 1856 1857 1858 1859 1860 1861 1862 1863 1864 1865 1866 1867 1868 1869 1870 1871 1872 1873 1874 1875 1876 1877 1878 1879 1880 1881 1882 1883 1884 1885 1886 1887 1888 1889 1890 1891 1892 1893 1894 1895 1896 1897 1898 1899 1900 1901 1902 1903 1904 1905 1906 1907 1908 1909 1910 1911 1912 1913 1914 1915 1916 1917 1918 1919 1920 1921 1922 1923 1924 1925 1926 1927 1928 1929 1930 1931 1932 1933 1934 1935 1936 1937 1938 1939 1940 1941 1942 1943 1944 1945 1946 1947 1948 1949 1950 1951 1952 1953 1954 1955 1956 1957 1958 1959 1960 1961 1962 1963 1964 1965 1966 1967 1968 1969 1970 1971 1972 1973 1974 1975 1976 1977 1978 1979 1980 1981 1982 1983 1984 1985 1986 1987 1988 1989 1990 1991 1992 1993 1994 1995 1996 1997 1998 1999 2000 2001 2002 2003 2004 2005 2006 2007 2008 2009 2010 2011 2012 2013 2014 2015 2016 2017 2018 2019 2020 2021 2022 2023 2024 2025 2026 2027 2028 2029 2030 2031 2032 2033 2034 2035 2036 2037 2038 2039 2040 2041 2042 2043 2044 2045 2046 2047 2048 2049 2050 2051 2052 2053 2054 2055 2056 2057 2058 2059 2060 2061 2062 2063 2064 2065 2066 2067 2068 2069 2070 2071 2072 2073 2074 2075 2076 2077 2078 2079 2080 2081 2082 2083 2084 2085 2086 2087 2088 2089 2090 2091 2092 2093 2094 2095 2096 2097 2098 2099 2100 2101 2102 2103 2104 2105 2106 2107 2108 2109 2110 2111 2112 2113 2114 2115 2116 2117 2118 2119 2120 2121 2122 2123 2124 2125 2126 2127 2128 2129 2130 2131 2132 2133 2134 2135 2136 2137 2138 2139 2140 2141 2142 2143 2144 2145 2146 2147 2148 2149 2150 2151 2152 2153 2154 2155 2156 2157 2158 2159 2160 2161 2162 2163 2164 2165 2166 2167 2168 2169 2170 2171 2172 2173 2174 2175 2176 2177 2178 2179 2180 2181 2182 2183 2184 2185 2186 2187 2188 2189 2190 2191 2192 2193 2194 2195 2196 2197 2198 2199 2200 2201 2202 2203 2204 2205 2206 2207 2208 2209 2210 2211 2212 2213 2214 2215 2216 2217 2218 2219 2220 2221 2222 2223 2224 2225 2226 2227 2228 2229 2230 2231 2232 2233 2234 2235 2236 2237 2238 2239 2240 2241 2242 2243 2244 2245 2246 2247 2248 2249 2250 2251 2252 2253 2254 2255 2256 2257 2258 2259 2260 2261 2262 2263 2264 2265 2266 2267 2268 2269 2270 2271 2272 2273 2274 2275 2276 2277 2278 2279 2280 2281 2282 2283 2284 2285 2286 2287 2288 2289 2290 2291 2292 2293 2294 2295 2296 2297 2298 2299 2300 2301 2302 2303 2304 2305 2306 2307 2308 2309 2310 2311 2312 2313 2314 2315 2316 2317 2318 2319 2320 2321 2322 2323 2324 2325 2326 2327 2328 2329 2330 2331 2332 2333 2334 2335 2336 2337 2338 2339 2340 2341 2342 2343 2344 2345 2346 2347 2348 2349 2350 2351 2352 2353 2354 2355 2356 2357 2358 2359 2360 2361 2362 2363 2364 2365 2366 2367 2368 2369 2370 2371 2372 2373 2374 2375 2376 2377 2378 2379 2380 2381 2382 2383 2384 2385 2386 2387 2388 2389 2390 2391 2392 2393 2394 2395 2396 2397 2398 2399 2400 2401 2402 2403 2404 2405 2406 2407 2408 2409 2410 2411 2412 2413 2414 2415 2416 2417 2418 2419 2420 2421 2422 2423 2424 2425 2426 2427 2428 2429 2430 2431 2432 2433 2434 2435 2436 2437 2438 2439 2440 2441 2442 2443 2444 2445 2446 2447 2448 2449 2450 2451 2452 2453 2454 2455 2456 2457 2458 2459 2460 2461 2462 2463 2464 2465 2466 2467 2468 2469 2470 2471 2472 2473 2474 2475 2476 2477 2478 2479 2480 2481 2482 2483 2484 2485 2486 2487 2488 2489 2490 2491 2492 2493 2494 2495 2496 2497 2498 2499 2500 2501 2502 2503 2504 2505 2506 2507 2508 2509 2510 2511 2512 2513 2514 2515 2516 2517 2518 2519 2520 2521 2522 2523 2524 2525 2526 2527 2528 2529 2530 2531 2532 2533 2534 2535 2536 2537 2538 2539 2540 2541 2542 2543 2544 2545 2546 2547 2548 2549 2550 2551 2552 2553 2554 2555 2556 2557 2558 2559 2560 2561 2562 2563 2564 2565 2566 2567 2568 2569 2570 2571 2572 2573 2574 2575 2576 2577 2578 2579 2580 2581 2582 2583 2584 2585 2586 2587 2588 2589 2590 2591 2592 2593 2594 2595 2596 2597 2598 2599 2600 2601 2602 2603 2604 2605 2606 2607 2608 2609 2610 2611 2612 2613 2614 2615 2616 2617 2618 2619 2620 2621 2622 2623 2624 2625 2626 2627 2628 2629 2630 2631 2632 2633 2634 2635 2636 2637 2638 2639 2640 2641 2642 2643 2644 2645 2646 2647 2648 2649 2650 2651 2652 2653 2654 2655 2656 2657 2658 2659 2660 2661 2662 2663 2664 2665 2666 2667 2668 2669 2670 2671 2672 2673 2674 2675 2676 2677 2678 2679 2680 2681 2682 2683 2684 2685 2686 2687 2688 2689 2690 2691 2692 2693 2694 2695 2696 2697 2698 2699 2700 2701 2702 2703 2704 2705 2706 2707 2708 2709 2710 2711 2712 2713 2714 2715 2716 2717 2718 2719 2720 2721 2722 2723 2724 2725 2726 2727 2728 2729 2730 2731 2732 2733 2734 2735 2736 2737 2738 2739 2740 2741 2742 2743 2744 2745 2746 2747 2748 2749 2750 2751 2752 2753 2754 2755 2756 2757 2758 2759 2760 2761 2762 2763 2764 2765 2766 2767 2768 2769 2770 2771 2772 2773 2774 2775 2776 2777 2778 2779 2780 2781 2782 2783 2784 2785 2786 2787 2788 2789 2790 2791 2792 2793 2794 2795 2796 2797 2798 2799 2800 2801 2802 2803 2804 2805 2806 2807 2808 2809 2810 2811 2812 2813 2814 2815 2816 2817 2818 2819 2820 2821 2822 2823 2824 2825 2826 2827 2828 2829 2830 2831 2832 2833 2834 2835 2836 2837 2838 2839 2840 2841 2842 2843 2844 2845 2846 2847 2848 2849 2850 2851 2852 2853 2854 2855 2856 2857 2858 2859 2860 2861 2862 2863 2864 2865 2866 2867 2868 2869 2870 2871 2872 2873 2874 2875 2876 2877 2878 2879 2880 2881 2882 2883 2884 2885 2886 2887 2888 2889 2890 2891 2892 2893 2894 2895 2896 2897 2898 2899 2900 2901 2902 2903 2904 2905 2906 2907 2908 2909 2910 2911 2912 2913 2914 2915 2916 2917 2918 2919 2920 2921 2922 2923 2924 2925 2926 2927 2928 2929 2930 2931 2932 2933 2934 2935 2936 2937 2938 2939 2940 2941 2942 2943 2944 2945 2946 2947 2948 2949 2950 2951 2952 2953 2954 2955 2956 2957 2958 2959 2960 2961 2962 2963 2964 2965 2966 2967 2968 2969 2970 2971 2972 2973 2974 2975 2976 2977 2978 2979 2980 2981 2982 2983 2984 2985 2986 2987 2988 2989 2990 2991 2992 2993 2994 2995 2996 2997 2998 2999 3000 3001 3002 3003 3004 3005 3006 3007 3008 3009 3010 3011 3012 3013 3014 3015 3016 3017 3018 3019 3020 3021 3022 3023 3024 3025 3026 3027 3028 3029 3030 3031 3032 3033 3034 3035 3036 3037 3038 3039 3040 3041 3042 3043 3044 3045 3046 3047 3048 3049 3050 3051 3052 3053 3054 3055 3056 3057 3058 3059 3060 3061 3062 3063 3064 3065 3066 3067 3068 3069 3070 3071 3072 3073 3074 3075 3076 3077 3078 3079 3080 3081 3082 3083 3084 3085 3086 3087 3088 3089 3090 3091 3092 3093 3094 3095 3096 3097 3098 3099 3100 3101 3102 3103 3104 3105 3106 3107 3108 3109 3110 3111 3112 3113 3114 3115 3116 3117 3118 3119 3120 3121 3122 3123 3124 3125 3126 3127 3128 3129 3130 3131 3132 3133 3134 3135 3136 3137 3138 3139 3140 3141 3142 3143 3144 3145 3146 3147 3148 3149 3150 3151 3152 3153 3154 3155 3156 3157 3158 3159 3160 3161 3162 3163 3164 3165 3166 3167 3168 3169 3170 3171 3172 3173 3174 3175 3176 3177 3178 3179 3180 3181 3182 3183 3184 3185 3186 3187 3188 3189 3190 3191 3192 3193 3194 3195 3196 3197 3198 3199 3200 3201 3202 3203 3204 3205 3206 3207 3208 3209 3210 3211 3212 3213 3214 3215 3216 3217 3218 3219 3220 3221 3222 3223 3224 3225 3226 3227 3228 3229 3230 3231 3232 3233 3234 3235 3236 3237 3238 3239 3240 3241 3242 3243 3244 3245 3246 3247 3248 3249 3250 3251 3252 3253 3254 3255 3256 3257 3258 3259 3260 3261 3262 3263 3264 3265 3266 3267 3268 3269 3270 3271 3272 3273 3274 3275 3276 3277 3278 3279 3280 3281 3282 3283 3284 3285 3286 3287 3288 3289 3290 3291 3292 3293 3294 3295 3296 3297 3298 3299 3300 3301 3302 3303 3304 3305 3306 3307 3308 3309 3310 3311 3312 3313 3314 3315 3316 3317 3318 3319 3320 3321 3322 3323 3324 3325 3326 3327 3328 3329 3330 3331 3332 3333 3334 3335 3336 3337 3338 3339 3340 3341 3342 3343 3344 3345 3346 3347 3348 3349 3350 3351 3352 3353 3354 3355 3356 3357 3358 3359 3360 3361 3362 3363 3364 3365 3366 3367 3368 3369 3370 3371 3372 3373 3374 3375 3376 3377 3378 3379 3380 3381 3382 3383 3384 3385 3386 3387 3388 3389 3390 3391 3392 3393 3394 3395 3396 3397 3398 3399 3400 3401 3402 3403 3404 3405 3406 3407 3408 3409 3410 3411 3412 3413 3414 3415 3416 3417 3418 3419 3420 3421 3422 3423 3424 3425 3426 3427 3428 3429 3430 3431 3432 3433 3434 3435 3436 3437 3438 3439 3440 3441 3442 3443 3444 3445 3446 3447 3448 3449 3450 3451 3452 3453 3454 3455 3456 3457 3458 3459 3460 3461 3462 3463 3464 3465 3466 3467 3468 3469 3470 3471 3472 3473 3474 3475 3476 3477 3478 3479 3480 3481 3482 3483 3484 3485 3486 3487 3488 3489 3490 3491 3492 3493 3494 3495 3496 3497 3498 3499 3500 3501 3502 3503 3504 3505 3506 3507 3508 3509 3510 3511 3512 3513 3514 3515 3516 3517 3518 3519 3520 3521 3522 3523 3524 3525 3526 3527 3528 3529 3530 3531 3532 3533 3534 3535 3536 3537 3538 3539 3540 3541 3542 3543 3544 3545 3546 3547 3548 3549 3550 3551 3552 3553 3554 3555 3556 3557 3558 3559 3560 3561 3562 3563 3564 3565 3566 3567 3568 3569 3570 3571 3572 3573 3574 3575 3576 3577 3578 3579 3580 3581 3582 3583 3584 3585 3586 3587 3588 3589 3590 3591 3592 3593 3594 3595 3596 3597 3598 3599 3600 3601 3602 3603 3604 3605 3606 3607 3608 3609 3610 3611 3612 3613 3614 3615 3616 3617 3618 3619 3620 3621 3622 3623 3624 3625 3626 3627 3628 3629 3630 3631 3632 3633 3634 3635 3636 3637 3638 3639 3640 3641 3642 3643 3644 3645 3646 3647 3648 3649 3650 3651 3652 3653 3654 3655 3656 3657 3658 3659 3660 3661 3662 3663 3664 3665 3666 3667 3668 3669 3670 3671 3672 3673 3674 3675 3676 3677 3678 3679 3680 3681 3682 3683 3684 3685 3686 3687 3688 3689 3690 3691 3692 3693 3694 3695 3696 3697 3698 3699 3700 3701 3702 3703 3704 3705 3706 3707 3708 3709 3710 3711 3712 3713 3714 3715 3716 3717 3718 3719 3720 3721 3722 3723 3724 3725 3726 3727 3728 3729 3730 3731 3732 3733 3734 3735 3736 3737 3738 3739 3740 3741 3742 3743 3744 3745 3746 3747 3748 3749 3750 3751 3752 3753 3754 3755 3756 3757 3758 3759 3760 3761 3762 3763 3764 3765 3766 3767 3768 3769 3770 3771 3772 3773 3774 3775 3776 3777 3778 3779 3780 3781 3782 3783 3784 3785 3786 3787 3788 3789 3790 3791 3792 3793 3794 3795 3796 3797 3798 3799 3800 3801 3802 3803 3804 3805 3806 3807 3808 3809 3810 3811 3812 3813 3814 3815 3816 3817 3818 3819 3820 3821 3822 3823 3824 3825 3826 3827 3828 3829 3830 3831 3832 3833 3834 3835 3836 3837 3838 3839 3840 3841 3842 3843 3844 3845 3846 3847 3848 3849 3850 3851 3852 3853 3854 3855 3856 3857 3858 3859 3860 3861 3862 3863 3864 3865 3866 3867 3868 3869 3870 3871 3872 3873 3874 3875 3876 3877 3878 3879 3880 3881 3882 3883 3884 3885 3886 3887 3888 3889 3890 3891 3892 3893 3894 3895 3896 3897 3898 3899 3900 3901 3902 3903 3904 3905 3906 3907 3908 3909 3910 3911 3912 3913 3914 3915 3916 3917 3918 3919 3920 3921 3922 3923 3924 3925 3926 3927 3928 3929 3930 3931 3932 3933 3934 3935 3936 3937 3938 3939 3940 3941 3942 3943 3944 3945 3946 3947 3948 3949 3950 3951 3952 3953 3954 3955 3956 3957 3958 3959 3960 3961 3962 3963 3964 3965 3966 3967 3968 3969 3970 3971 3972 3973 3974 3975 3976 3977 3978 3979 3980 3981 3982 3983 3984 3985 3986 3987 3988 3989 3990 3991 3992 3993 3994 3995 3996 3997 3998 3999 4000 4001 4002 4003 4004 4005 4006 4007 4008 4009 4010 4011 4012 4013 4014 4015 4016 4017 4018 4019 4020 4021 4022 4023 4024 4025 4026 4027 4028 4029 4030 4031 4032 4033 4034 4035 4036 4037 4038 4039 4040 4041 4042 4043 4044 4045 4046 4047 4048 4049 4050 4051 4052 4053 4054 4055 4056 4057 4058 4059 4060 4061 4062 4063 4064 4065 4066 4067 4068 4069 4070 4071 4072 4073 4074 4075 4076 4077 4078 4079 4080 4081 4082 4083 4084 4085 4086 4087 4088 4089 4090 4091 4092 4093 4094 4095 4096 4097 4098 4099 4100 4101 4102 4103 4104 4105 4106 4107 4108 4109 4110 4111 4112 4113 4114 4115 4116 4117 4118 4119 4120 4121 4122 4123 4124 4125 4126 4127 4128 4129 4130 4131 4132 4133 4134 4135 4136 4137 4138 4139 4140 4141 4142 4143 4144 4145 4146 4147 4148 4149 4150 4151 4152 4153 4154 4155 4156 4157 4158 4159 4160 4161 4162 4163 4164 4165 4166 4167 4168 4169 4170 4171 4172 4173 4174 4175 4176 4177 4178 4179 4180 4181 4182 4183 4184 4185 4186 4187 4188 4189 4190 4191 4192 4193 4194 4195 4196 4197 4198 4199 4200 4201 4202 4203 4204 4205 4206 4207 4208 4209 4210 4211 4212 4213 4214 4215 4216 4217 4218 4219 4220 4221 4222 4223 4224 4225 4226 4227 4228 4229 4230 4231 4232 4233 4234 4235 4236 4237 4238 4239 4240 4241 4242 4243 4244 4245 4246 4247 4248 4249 4250 4251 4252 4253 4254 4255 4256 4257 4258 4259 4260 4261 4262 4263 4264 4265 4266 4267 4268 4269 4270 4271 4272 4273 4274 4275 4276 4277 4278 4279 4280 4281 4282 4283 4284 4285 4286 4287 4288 4289 4290 4291 4292 4293 4294 4295 4296 4297 4298 4299 4300 4301 4302 4303 4304 4305 4306 4307 4308 4309 4310 4311 4312 4313 4314 4315 4316 4317 4318 4319 4320 4321 4322 4323 4324 4325 4326 4327 4328 4329 4330 4331 4332 4333 4334 4335 4336 4337 4338 4339 4340 4341 4342 4343 4344 4345 4346 4347 4348 4349 4350 4351 4352 4353 4354 4355 4356 4357 4358 4359 4360 4361 4362 4363 4364 4365 4366 4367 4368 4369 4370 4371 4372 4373 4374 4375 4376 4377 4378 4379 4380 4381 4382 4383 4384 4385 4386 4387 4388 4389 4390 4391 4392 4393 4394 4395 4396 4397 4398 4399 4400 4401 4402 4403 4404 4405 4406 4407 4408 4409 4410 4411 4412 4413 4414 4415 4416 4417 4418 4419 4420 4421 4422 4423 4424 4425 4426 4427 4428 4429 4430 4431 4432 4433 4434 4435 4436 4437 4438 4439 4440 4441 4442 4443 4444 4445 4446 4447 4448 4449 4450 4451 4452 4453 4454 4455 4456 4457 4458 4459 4460 4461 4462 4463 4464 4465 4466 4467 4468 4469 4470 4471 4472 4473 4474 4475 4476 4477 4478 4479 4480 4481 4482 4483 4484 4485 4486 4487 4488 4489 4490 4491 4492 4493 4494 4495 4496 4497 4498 4499 4500 4501 4502 4503 4504 4505 4506 4507 4508 4509 4510 4511 4512 4513 4514 4515 4516 4517 4518 4519 4520 4521 4522 4523 4524 4525 4526 4527 4528 4529 4530 4531 4532 4533 4534 4535 4536 4537 4538 4539 4540 4541 4542 4543 4544 4545 4546 4547 4548 4549 4550 4551 4552 4553 4554 4555 4556 4557 4558 4559 4560 4561 4562 4563 4564 4565 4566 4567 4568 4569 4570 4571 4572 4573 4574 4575 4576 4577 4578 4579 4580 4581 4582 4583 4584 4585 4586 4587 4588 4589 4590 4591 4592 4593 4594 4595 4596 4597 4598 4599 4600 4601 4602 4603 4604 4605 4606 4607 4608 4609 4610 4611 4612 4613 4614 4615 4616 4617 4618 4619 4620 4621 4622 4623 4624 4625 4626 4627 4628 4629 4630 4631 4632 4633 4634 4635 4636 4637 4638 4639 4640 4641 4642 4643 4644 4645 4646 4647 4648 4649 4650 4651 4652 4653 4654 4655 4656 4657 4658 4659 4660 4661 4662 4663 4664 4665 4666 4667 4668 4669 4670 4671 4672 4673 4674 4675 4676 4677 4678 4679 4680 4681 4682 4683 4684 4685 4686 4687 4688 4689 4690 4691 4692 4693 4694 4695 4696 4697 4698 4699 4700 4701 4702 4703 4704 4705 4706 4707 4708 4709 4710 4711 4712 4713 4714 4715 4716 4717 4718 4719 4720 4721 4722 4723 4724 4725 4726 4727 4728 4729 4730 4731 4732 4733 4734 4735 4736 4737 4738 4739 4740 4741 4742 4743 4744 4745 4746 4747 4748 4749 4750 4751 4752 4753 4754 4755 4756 4757 4758 4759 4760 4761 4762 4763 4764 4765 4766 4767 4768 4769 4770 4771 4772 4773 4774 4775 4776 4777 4778 4779 4780 4781 4782 4783 4784 4785 4786 4787 4788 4789 4790 4791 4792 4793 4794 4795 4796 4797 4798 4799 4800 4801 4802 4803 4804 4805 4806 4807 4808 4809 4810 4811 4812 4813 4814 4815 4816 4817 4818 4819 4820 4821 4822 4823 4824 4825 4826 4827 4828 4829 4830 4831 4832 4833 4834 4835 4836 4837 4838 4839 4840 4841 4842 4843 4844 4845 4846 4847 4848 4849 4850 4851 4852 4853 4854 4855 4856 4857 4858 4859 4860 4861 4862 4863 4864 4865 4866 4867 4868 4869 4870 4871 4872 4873 4874 4875 4876 4877 4878 4879 4880 4881 4882 4883 4884 4885 4886 4887 4888 4889 4890 4891 4892 4893 4894 4895 4896 4897 4898 4899 4900 4901 4902 4903 4904 4905 4906 4907 4908 4909 4910 4911 4912 4913 4914 4915 4916 4917 4918 4919 4920 4921 4922 4923 4924 4925 4926 4927 4928 4929 4930 4931 4932 4933 4934 4935 4936 4937 4938 4939 4940 4941 4942 4943 4944 4945 4946 4947 4948 4949 4950 4951 4952 4953 4954 4955 4956 4957 4958 4959 4960 4961 4962 4963 4964 4965 4966 4967 4968 4969 4970 4971 4972 4973 4974 4975 4976 4977 4978 4979 4980 4981 4982 4983 4984 4985 4986 4987 4988 4989 4990 4991 4992 4993 4994 4995 4996 4997 4998 4999 5000 5001 5002 5003 5004 5005 5006 5007 5008 5009 5010 5011 5012 5013 5014 5015 5016 5017 5018 5019 5020 5021 5022 5023 5024 5025 5026 5027 5028 5029 5030 5031 5032 5033 5034 5035 5036 5037 5038 5039 5040 5041 5042 5043 5044 5045 5046 5047 5048 5049 5050 5051 5052 5053 5054 5055 5056 5057 5058 5059 5060 5061 5062 5063 5064 5065 5066 5067 5068 5069 5070 5071 5072 5073 5074 5075 5076 5077 5078 5079 5080 5081 5082 5083 5084 5085 5086 5087 5088 5089 5090 5091 5092 5093 5094 5095 5096 5097 5098 5099 5100 5101 5102 5103 5104 5105 5106 5107 5108 5109 5110 5111 5112 5113 5114 5115 5116 5117 5118 5119 5120 5121 5122 5123 5124 5125 5126 5127 5128 5129 5130 5131 5132 5133 5134 5135 5136 5137 5138 5139 5140 5141 5142 5143 5144 5145 5146 5147 5148 5149 5150 5151 5152 5153 5154 5155 5156 5157 5158 5159 5160 5161 5162 5163 5164 5165 5166 5167 5168 5169 5170 5171 5172 5173 5174 5175 5176 5177 5178 5179 5180 5181 5182 5183 5184 5185 5186 5187 5188 5189 5190 5191 5192 5193 5194 5195 5196 5197 5198 5199 5200 5201 5202 5203 5204 5205 5206 5207 5208 5209 5210 5211 5212 5213 5214 5215 5216 5217 5218 5219 5220 5221 5222 5223 5224 5225 5226 5227 5228 5229 5230 5231 5232 5233 5234 5235 5236 5237 5238 5239 5240 5241 5242 5243 5244 5245 5246 5247 5248 5249 5250 5251 5252 5253 5254 5255 5256 5257 5258 5259 5260 5261 5262 5263 5264 5265 5266 5267 5268 5269 5270 5271 5272 5273 5274 5275 5276 5277 5278 5279 5280 5281 5282 5283 5284 5285 5286 5287 5288 5289 5290 5291 5292 5293 5294 5295 5296 5297 5298 5299 5300 5301 5302 5303 5304 5305 5306 5307 5308 5309 5310 5311 5312 5313 5314 5315 5316 5317 5318 5319 5320 5321 5322 5323 5324 5325 5326 5327 5328 5329 5330 5331 5332 5333 5334 5335 5336 5337 5338 5339 5340 5341 5342 5343 5344 5345 5346 5347 5348 5349 5350 5351 5352 5353 5354 5355 5356 5357 5358 5359 5360 5361 5362 5363 5364 5365 5366 5367 5368 5369 5370 5371 5372 5373 5374 5375 5376 5377 5378 5379 5380 5381 5382 5383 5384 5385 5386 5387 5388 5389 5390 5391 5392 5393 5394 5395 5396 5397 5398 5399 5400 5401 5402 5403 5404 5405 5406 5407 5408 5409 5410 5411 5412 5413 5414 5415 5416 5417 5418 5419 5420 5421 5422 5423 5424 5425 5426 5427 5428 5429 5430 5431 5432 5433 5434 5435 5436 5437 5438 5439 5440 5441 5442 5443 5444 5445 5446 5447 5448 5449 5450 5451 5452 5453 5454 5455 5456 5457 5458 5459 5460 5461 5462 5463 5464 5465 5466 5467 5468 5469 5470 5471 5472 5473 5474 5475 5476 5477 5478 5479 5480 5481 5482 5483 5484 5485 5486 5487 5488 5489 5490 5491 5492 5493 5494 5495 5496 5497 5498 5499 5500 5501 5502 5503 5504 5505 5506 5507 5508 5509 5510 5511 5512 5513 5514 5515 5516 5517 5518 5519 5520 5521 5522 5523 5524 5525 5526 5527 5528 5529 5530 5531 5532 5533 5534 5535 5536 5537 5538 5539 5540 5541 5542 5543 5544 5545 5546 5547 5548 5549 5550 5551 5552 5553 5554 5555 5556 5557 5558 5559 5560 5561 5562 5563 5564 5565 5566 5567 5568 5569 5570 5571 5572 5573 5574 5575 5576 5577 5578 5579 5580 5581 5582 5583 5584 5585 5586 5587 5588 5589 5590 5591 5592 5593 5594 5595 5596 5597 5598 5599 5600 5601 5602 5603 5604 5605 5606 5607 5608 5609 5610 5611 5612 5613 5614 5615 5616 5617 5618 5619 5620 5621 5622 5623 5624 5625 5626 5627 5628 5629 5630 5631 5632 5633 5634 5635 5636 5637 5638 5639 5640 5641 5642 5643 5644 5645 5646 5647 5648 5649 5650 5651 5652 5653 5654 5655 5656 5657 5658 5659 5660 5661 5662 5663 5664 5665 5666 5667 5668 5669 5670 5671 5672 5673 5674 5675 5676 5677 5678 5679 5680 5681 5682 5683 5684 5685 5686 5687 5688 5689 5690 5691 5692 5693 5694 5695 5696 5697 5698 5699 5700 5701 5702 5703 5704 5705 5706 5707 5708 5709 5710 5711 5712 5713 5714 5715 5716 5717 5718 5719 5720 5721 5722 5723 5724 5725 5726 5727 5728 5729 5730 5731 5732 5733 5734 5735 5736 5737 5738 5739 5740 5741 5742 5743 5744 5745 5746 5747 5748 5749 5750 5751 5752 5753 5754 5755 5756 5757 5758 5759 5760 5761 5762 5763 5764 5765 5766 5767 5768 5769 5770 5771 5772 5773 5774 5775 5776 5777 5778 5779 5780 5781 5782 5783 5784 5785 5786 5787 5788 5789 5790 5791 5792 5793 5794 5795 5796 5797 5798 5799 5800 5801 5802 5803 5804 5805 5806 5807 5808 5809 5810 5811 5812 5813 5814 5815 5816 5817 5818 5819 5820 5821 5822 5823 5824 5825 5826 5827 5828 5829 5830 5831 5832 5833 5834 5835 5836 5837 5838 5839 5840 5841 5842 5843 5844 5845 5846 5847 5848 5849 5850 5851 5852 5853 5854 5855 5856 5857 5858 5859 5860 5861 5862 5863 5864 5865 5866 5867 5868 5869 5870 5871 5872 5873 5874 5875 5876 5877 5878 5879 5880 5881 5882 5883 5884 5885 5886 5887 5888 5889 5890 5891 5892 5893 5894 5895 5896 5897 5898 5899 5900 5901 5902 5903 5904 5905 5906 5907 5908 5909 5910 5911 5912 5913 5914 5915 5916 5917 5918 5919 5920 5921 5922 5923 5924 5925 5926 5927 5928 5929 5930 5931 5932 5933 5934 5935 5936 5937 5938 5939 5940 5941 5942 5943 5944 5945 5946 5947 5948 5949 5950 5951 5952 5953 5954 5955 5956 5957 5958 5959 5960 5961 5962 5963 5964 5965 5966 5967 5968 5969 5970 5971 5972 5973 5974 5975 5976 5977 5978 5979 5980 5981 5982 5983 5984 5985 5986 5987 5988 5989 5990 5991 5992 5993 5994 5995 5996 5997 5998 5999 6000 6001 6002 6003 6004 6005 6006 6007 6008 6009 6010 6011 6012 6013 6014 6015 6016 6017 6018 6019 6020 6021 6022 6023 6024 6025 6026 6027 6028 6029 6030 6031 6032 6033 6034 6035 6036 6037 6038 6039 6040 6041 6042 6043 6044 6045 6046 6047 6048 6049 6050 6051 6052 6053 6054 6055 6056 6057 6058 6059 6060 6061 6062 6063 6064 6065 6066 6067 6068 6069 6070 6071 6072 6073 6074 6075 6076 6077 6078 6079 6080 6081 6082 6083 6084 6085 6086 6087 6088 6089 6090 6091 6092 6093 6094 6095 6096 6097 6098 6099 6100 6101 6102 6103 6104 6105 6106 6107 6108 6109 6110 6111 6112 6113 6114 6115 6116 6117 6118 6119 6120 6121 6122 6123 6124 6125 6126 6127 6128 6129 6130 6131 6132 6133 6134 6135 6136 6137 6138 6139 6140 6141 6142 6143 6144 6145 6146 6147 6148 6149 6150 6151 6152 6153 6154 6155 6156 6157 6158 6159 6160 6161 6162 6163 6164 6165 6166 6167 6168 6169 6170 6171 6172 6173 6174 6175 6176 6177 6178 6179 6180 6181 6182 6183 6184 6185 6186 6187 6188 6189 6190 6191 6192 6193 6194 6195 6196 6197 6198 6199 6200 6201 6202 6203 6204 6205 6206 6207 6208 6209 6210 6211 6212 6213 6214 6215 6216 6217 6218 6219 6220 6221 6222 6223 6224 6225 6226 6227 6228 6229 6230 6231 6232 6233 6234 6235 6236 6237 6238 6239 6240 6241 6242 6243 6244 6245 6246 6247 6248 6249 6250 6251 6252 6253 6254 6255 6256 6257 6258 6259 6260 6261 6262 6263 6264 6265 6266 6267 6268 6269 6270 6271 6272 6273 6274 6275 6276 6277 6278 6279 6280 6281 6282 6283 6284 6285 6286 6287 6288 6289 6290 6291 6292 6293 6294 6295 6296 6297 6298 6299 6300 6301 6302 6303 6304 6305 6306 6307 6308 6309 6310 6311 6312 6313 6314 6315 6316 6317 6318 6319 6320 6321 6322 6323 6324 6325 6326 6327 6328 6329 6330 6331 6332 6333 6334 6335 6336 6337 6338 6339 6340 6341 6342 6343 6344 6345 6346 6347 6348 6349 6350 6351 6352 6353 6354 6355 6356 6357 6358 6359 6360 6361 6362 6363 6364 6365 6366 6367 6368 6369 6370 6371 6372 6373 6374 6375 6376 6377 6378 6379 6380 6381 6382 6383 6384 6385 6386 6387 6388 6389 6390 6391 6392 6393 6394 6395 6396 6397 6398 6399 6400 6401 6402 6403 6404 6405 6406 6407 6408 6409 6410 6411 6412 6413 6414 6415 6416 6417 6418 6419 6420 6421 6422 6423 6424 6425 6426 6427 6428 6429 6430 6431 6432 6433 6434 6435 6436 6437 6438 6439 6440 6441 6442 6443 6444 6445 6446 6447 6448 6449 6450 6451 6452 6453 6454 6455 6456 6457 6458 6459 6460 6461 6462 6463 6464 6465 6466 6467 6468 6469 6470 6471 6472 6473 6474 6475 6476 6477 6478 6479 6480 6481 6482 6483 6484 6485 6486 6487 6488 6489 6490 6491 6492 6493 6494 6495 6496 6497 6498 6499 6500 6501 6502 6503 6504 6505 6506 6507 6508 6509 6510 6511 6512 6513 6514 6515 6516 6517 6518 6519 6520 6521 6522 6523 6524 6525 6526 6527 6528 6529 6530 6531 6532 6533 6534 6535 6536 6537 6538 6539 6540 6541 6542 6543 6544 6545 6546 6547 6548 6549 6550 6551 6552 6553 6554 6555 6556 6557 6558 6559 6560 6561 6562 6563 6564 6565 6566 6567 6568 6569 6570 6571 6572 6573 6574 6575 6576 6577 6578 6579 6580 6581 6582 6583 6584 6585 6586 6587 6588 6589 6590 6591 6592 6593 6594 6595 6596 6597 6598 6599 6600 6601 6602 6603 6604 6605 6606 6607 6608 6609 6610 6611 6612 6613 6614 6615 6616 6617 6618 6619 6620 6621 6622 6623 6624 6625 6626 6627 6628 6629 6630 6631 6632 6633 6634 6635 6636 6637 6638 6639 6640 6641 6642 6643 6644 6645 6646 6647 6648 6649 6650 6651 6652 6653 6654 6655 6656 6657 6658 6659 6660 6661 6662 6663 6664 6665 6666 6667 6668 6669 6670 6671 6672 6673 6674 6675 6676 6677 6678 6679 6680 6681 6682 6683 6684 6685 6686 6687 6688 6689 6690 6691 6692 6693 6694 6695 6696 6697 6698 6699 6700 6701 6702 6703 6704 6705 6706 6707 6708 6709 6710 6711 6712 6713 6714 6715 6716 6717 6718 6719 6720 6721 6722 6723 6724 6725 6726 6727 6728 6729 6730 6731 6732 6733 6734 6735 6736 6737 6738 6739 6740 6741 6742 6743 6744 6745 6746 6747 6748 6749 6750 6751 6752 6753 6754 6755 6756 6757 6758 6759 6760 6761 6762 6763 6764 6765 6766 6767 6768 6769 6770 6771 6772 6773 6774 6775 6776 6777 6778 6779 6780 6781 6782 6783 6784 6785 6786 6787 6788 6789 6790 6791 6792 6793 6794 6795 6796 6797 6798 6799 6800 6801 6802 6803 6804 6805 6806 6807 6808 6809 6810 6811 6812 6813 6814 6815 6816 6817 6818 6819 6820 6821 6822 6823 6824 6825 6826 6827 6828 6829 6830 6831 6832 6833 6834 6835 6836 6837 6838 6839 6840 6841 6842 6843 6844 6845 6846 6847 6848 6849 6850 6851 6852 6853 6854 6855 6856 6857 6858 6859 6860 6861 6862 6863 6864 6865 6866 6867 6868 6869 6870 6871 6872 6873 6874 6875 6876 6877 6878 6879 6880 6881 6882 6883 6884 6885 6886 6887 6888 6889 6890 6891 6892 6893 6894 6895 6896 6897 6898 6899 6900 6901 6902 6903 6904 6905 6906 6907 6908 6909 6910 6911 6912 6913 6914 6915 6916 6917 6918 6919 6920 6921 6922 6923 6924 6925 6926 6927 6928 6929 6930 6931 6932 6933 6934 6935 6936 6937 6938 6939 6940 6941 6942 6943 6944 6945 6946 6947 6948 6949 6950 6951 6952 6953 6954 6955 6956 6957 6958 6959 6960 6961 6962 6963 6964 6965 6966 6967 6968 6969 6970 6971 6972 6973 6974 6975 6976 6977 6978 6979 6980 6981 6982 6983 6984 6985 6986 6987 6988 6989 6990 6991 6992 6993 6994 6995 6996 6997 6998 6999 7000 7001 7002 7003 7004 7005 7006 7007 7008 7009 7010 7011 7012 7013 7014 7015 7016 7017 7018 7019 7020 7021 7022 7023 7024 7025 7026 7027 7028 7029 7030 7031 7032 7033 7034 7035 7036 7037 7038 7039 7040 7041 7042 7043 7044 7045 7046 7047 7048 7049 7050 7051 7052 7053 7054 7055 7056 7057 7058 7059 7060 7061 7062 7063 7064 7065 7066 7067 7068 7069 7070 7071 7072 7073 7074 7075 7076 7077 7078 7079 7080 7081 7082 7083 7084 7085 7086 7087 7088 7089 7090 7091 7092 7093 7094 7095 7096 7097 7098 7099 7100 7101 7102 7103 7104 7105 7106 7107 7108 7109 7110 7111 7112 7113 7114 7115 7116 7117 7118 7119 7120 7121 7122 7123 7124 7125 7126 7127 7128 7129 7130 7131 7132 7133 7134 7135 7136 7137 7138 7139 7140 7141 7142 7143 7144 7145 7146 7147 7148 7149 7150 7151 7152 7153 7154 7155 7156 7157 7158 7159 7160 7161 7162 7163 7164 7165 7166 7167 7168 7169 7170 7171 7172 7173 7174 7175 7176 7177 7178 7179 7180 7181 7182 7183 7184 7185 7186 7187 7188 7189 7190 7191 7192 7193 7194 7195 7196 7197 7198 7199 7200 7201 7202 7203 7204 7205 7206 7207 7208 7209 7210 7211 7212 7213 7214 7215 7216 7217 7218 7219 7220 7221 7222 7223 7224 7225 7226 7227 7228 7229 7230 7231 7232 7233 7234 7235 7236 7237 7238 7239 7240 7241 7242 7243 7244 7245 7246 7247 7248 7249 7250 7251 7252 7253 7254 7255 7256 7257 7258 7259 7260 7261 7262 7263 7264 7265 7266 7267 7268 7269 7270 7271 7272 7273 7274 7275 7276 7277 7278 7279 7280 7281 7282 7283 7284 7285 7286 7287 7288 7289 7290 7291 7292 7293 7294 7295 7296 7297 7298 7299 7300 7301 7302 7303 7304 7305 7306 7307 7308 7309 7310 7311 7312 7313 7314 7315 7316 7317 7318 7319 7320 7321 7322 7323 7324 7325 7326 7327 7328 7329 7330 7331 7332 7333 7334 7335 7336 7337 7338 7339 7340 7341 7342 7343 7344 7345 7346 7347 7348 7349 7350 7351 7352 7353 7354 7355 7356 7357 7358 7359 7360 7361 7362 7363 7364 7365 7366 7367 7368 7369 7370 7371 7372 7373 7374 7375 7376 7377 7378 7379 7380 7381 7382 7383 7384 7385 7386 7387 7388 7389 7390 7391 7392 7393 7394 7395 7396 7397 7398 7399 7400 7401 7402 7403 7404 7405 7406 7407 7408 7409 7410 7411 7412 7413 7414 7415 7416 7417 7418 7419 7420 7421 7422 7423 7424 7425 7426 7427 7428 7429 7430 7431 7432 7433 7434 7435 7436 7437 7438 7439 7440 7441 7442 7443 7444 7445 7446 7447 7448 7449 7450 7451 7452 7453 7454 7455 7456 7457 7458 7459 7460 7461 7462 7463 7464 7465 7466 7467 7468 7469 7470 7471 7472 7473 7474 7475 7476 7477 7478 7479 7480 7481 7482 7483 7484 7485 7486 7487 7488 7489 7490 7491 7492 7493 7494 7495 7496 7497 7498 7499 7500 7501 7502 7503 7504 7505 7506 7507 7508 7509 7510 7511 7512 7513 7514 7515 7516 7517 7518 7519 7520 7521 7522 7523 7524 7525 7526 7527 7528 7529 7530 7531 7532 7533 7534 7535 7536 7537 7538 7539 7540 7541 7542 7543 7544 7545 7546 7547 7548 7549 7550 7551 7552 7553 7554 7555 7556 7557 7558 7559 7560 7561 7562 7563 7564 7565 7566 7567 7568 7569 7570 7571 7572 7573 7574 7575 7576 7577 7578 7579 7580 7581 7582 7583 7584 7585 7586 7587 7588 7589 7590 7591 7592 7593 7594 7595 7596 7597 7598 7599 7600 7601 7602 7603 7604 7605 7606 7607 7608 7609 7610 7611 7612 7613 7614 7615 7616 7617 7618 7619 7620 7621 7622 7623 7624 7625 7626 7627 7628 7629 7630 7631 7632 7633 7634 7635 7636 7637 7638 7639 7640 7641 7642 7643 7644 7645 7646 7647 7648 7649 7650 7651 7652 7653 7654 7655 7656 7657 7658 7659 7660 7661 7662 7663 7664 7665 7666 7667 7668 7669 7670 7671 7672 7673 7674 7675 7676 7677 7678 7679 7680 7681 7682 7683 7684 7685 7686 7687 7688 7689 7690 7691 7692 7693 7694 7695 7696 7697 7698 7699 7700 7701 7702 7703 7704 7705 7706 7707 7708 7709 7710 7711 7712 7713 7714 7715 7716 7717 7718 7719 7720 7721 7722 7723 7724 7725 7726 7727 7728 7729 7730 7731 7732 7733 7734 7735 7736 7737 7738 7739 7740 7741 7742 7743 7744 7745 7746 7747 7748 7749 7750 7751 7752 7753 7754 7755 7756 7757 7758 7759 7760 7761 7762 7763 7764 7765 7766 7767 7768 7769 7770 7771 7772 7773 7774 7775 7776 7777 7778 7779 7780 7781 7782 7783 7784 7785 7786 7787 7788 7789 7790 7791 7792 7793 7794 7795 7796 7797 7798 7799 7800 7801 7802 7803 7804 7805 7806 7807 7808 7809 7810 7811 7812 7813 7814 7815 7816 7817 7818 7819 7820 7821 7822 7823 7824 7825 7826 7827 7828 7829 7830 7831 7832 7833 7834 7835 7836 7837 7838 7839 7840 7841 7842 7843 7844 7845 7846 7847 7848 7849 7850 7851 7852 7853 7854 7855 7856 7857 7858 7859 7860 7861 7862 7863 7864 7865 7866 7867 7868 7869 7870 7871 7872 7873 7874 7875 7876 7877 7878 7879 7880 7881 7882 7883 7884 7885 7886 7887 7888 7889 7890 7891 7892 7893 7894 7895 7896 7897 7898 7899 7900 7901 7902 7903 7904 7905 7906 7907 7908 7909 7910 7911 7912 7913 7914 7915 7916 7917 7918 7919 7920 7921 7922 7923 7924 7925 7926 7927 7928 7929 7930 7931 7932 7933 7934 7935 7936 7937 7938 7939 7940 7941 7942 7943 7944 7945 7946 7947 7948 7949 7950 7951 7952 7953 7954 7955 7956 7957 7958 7959 7960 7961 7962 7963 7964 7965 7966 7967 7968 7969 7970 7971 7972 7973 7974 7975 7976 7977 7978 7979 7980 7981 7982 7983 7984 7985 7986 7987 7988 7989 7990 7991 7992 7993 7994 7995 7996 7997 7998 7999 8000 8001 8002 8003 8004 8005 8006 8007 8008 8009 8010 8011 8012 8013 8014 8015 8016 8017 8018 8019 8020 8021 8022 8023 8024 8025 8026 8027 8028 8029 8030 8031 8032 8033 8034 8035 8036 8037 8038 8039 8040 8041 8042 8043 8044 8045 8046 8047 8048 8049 8050 8051 8052 8053 8054 8055 8056 8057 8058 8059 8060 8061 8062 8063 8064 8065 8066 8067 8068 8069 8070 8071 8072 8073 8074 8075 8076 8077 8078 8079 8080 8081 8082 8083 8084 8085 8086 8087 8088 8089 8090 8091 8092 8093 8094 8095 8096 8097 8098 8099 8100 8101 8102 8103 8104 8105 8106 8107 8108 8109 8110 8111 8112 8113 8114 8115 8116 8117 8118 8119 8120 8121 8122 8123 8124 8125 8126 8127 8128 8129 8130 8131 8132 8133 8134 8135 8136 8137 8138 8139 8140 8141 8142 8143 8144 8145 8146 8147 8148 8149 8150 8151 8152 8153 8154 8155 8156 8157 8158 8159 8160 8161 8162 8163 8164 8165 8166 8167 8168 8169 8170 8171 8172 8173 8174 8175 8176 8177 8178 8179 8180 8181 8182 8183 8184 8185 8186 8187 8188 8189 8190 8191 8192 8193 8194 8195 8196 8197 8198 8199 8200 8201 8202 8203 8204 8205 8206 8207 8208 8209 8210 8211 8212 8213 8214 8215 8216 8217 8218 8219 8220 8221 8222 8223 8224 8225 8226 8227 8228 8229 8230 8231 8232 8233 8234 8235 8236 8237 8238 8239 8240 8241 8242 8243 8244 8245 8246 8247 8248 8249 8250 8251 8252 8253 8254 8255 8256 8257 8258 8259 8260 8261 8262 8263 8264 8265 8266 8267 8268 8269 8270 8271 8272 8273 8274 8275 8276 8277 8278 8279 8280 8281 8282 8283 8284 8285 8286 8287 8288 8289 8290 8291 8292 8293 8294 8295 8296 8297 8298 8299 8300 8301 8302 8303 8304 8305 8306 8307 8308 8309 8310 8311 8312 8313 8314 8315 8316 8317 8318 8319 8320 8321 8322 8323 8324 8325 8326 8327 8328 8329 8330 8331 8332 8333 8334 8335 8336 8337 8338 8339 8340 8341 8342 8343 8344 8345 8346 8347 8348 8349 8350 8351 8352 8353 8354 8355 8356 8357 8358 8359 8360 8361 8362 8363 8364 8365 8366 8367 8368 8369 8370 8371 8372 8373 8374 8375 8376 8377 8378 8379 8380 8381 8382 8383 8384 8385 8386 8387 8388 8389 8390 8391 8392 8393 8394 8395 8396 8397 8398 8399 8400 8401 8402 8403 8404 8405 8406 8407 8408 8409 8410 8411 8412 8413 8414 8415 8416 8417 8418 8419 8420 8421 8422 8423 8424 8425 8426 8427 8428 8429 8430 8431 8432 8433 8434 8435 8436 8437 8438 8439 8440 8441 8442 8443 8444 8445 8446 8447 8448 8449 8450 8451 8452 8453 8454 8455 8456 8457 8458 8459 8460 8461 8462 8463 8464 8465 8466 8467 8468 8469 8470 8471 8472 8473 8474 8475 8476 8477 8478 8479 8480 8481 8482 8483 8484 8485 8486 8487 8488 8489 8490 8491 8492 8493 8494 8495 8496 8497 8498 8499 8500 8501 8502 8503 8504 8505 8506 8507 8508 8509 8510 8511 8512 8513 8514 8515 8516 8517 8518 8519 8520 8521 8522 8523 8524 8525 8526 8527 8528 8529 8530 8531 8532 8533 8534 8535 8536 8537 8538 8539 8540 8541 8542 8543 8544 8545 8546 8547 8548 8549 8550 8551 8552 8553 8554 8555 8556 8557 8558 8559 8560 8561 8562 8563 8564 8565 8566 8567 8568 8569 8570 8571 8572 8573 8574 8575 8576 8577 8578 8579 8580 8581 8582 8583 8584 8585 8586 8587 8588 8589 8590 8591 8592 8593 8594 8595 8596 8597 8598 8599 8600 8601 8602 8603 8604 8605 8606 8607 8608 8609 8610 8611 8612 8613 8614 8615 8616 8617 8618 8619 8620 8621 8622 8623 8624 8625 8626 8627 8628 8629 8630 8631 8632 8633 8634 8635 8636 8637 8638 8639 8640 8641 8642 8643 8644 8645 8646 8647 8648 8649 8650 8651 8652 8653 8654 8655 8656 8657 8658 8659 8660 8661 8662 8663 8664 8665 8666 8667 8668 8669 8670 8671 8672 8673 8674 8675 8676 8677 8678 8679 8680 8681 8682 8683 8684 8685 8686 8687 8688 8689 8690 8691 8692 8693 8694 8695 8696 8697 8698 8699 8700 8701 8702 8703 8704 8705 8706 8707 8708 8709 8710 8711 8712 8713 8714 8715 8716 8717 8718 8719 8720 8721 8722 8723 8724 8725 8726 8727 8728 8729 8730 8731 8732 8733 8734 8735 8736 8737 8738 8739 8740 8741 8742 8743 8744 8745 8746 8747 8748 8749 8750 8751 8752 8753 8754 8755 8756 8757 8758 8759 8760 8761 8762 8763 8764 8765 8766 8767 8768 8769 8770 8771 8772 8773 8774 8775 8776 8777 8778 8779 8780 8781 8782 8783 8784 8785 8786 8787 8788 8789 8790 8791 8792 8793 8794 8795 8796 8797 8798 8799 8800 8801 8802 8803 8804 8805 8806 8807 8808 8809 8810 8811 8812 8813 8814 8815 8816 8817 8818 8819 8820 8821 8822 8823 8824 8825 8826 8827 8828 8829 8830 8831 8832 8833 8834 8835 8836 8837 8838 8839 8840 8841 8842 8843 8844 8845 8846 8847 8848 8849 8850 8851 8852 8853 8854 8855 8856 8857 8858 8859 8860 8861 8862 8863 8864 8865 8866 8867 8868 8869 8870 8871 8872 8873 8874 8875 8876 8877 8878 8879 8880 8881 8882 8883 8884 8885 8886 8887 8888 8889 8890 8891 8892 8893 8894 8895 8896 8897 8898 8899 8900 8901 8902 8903 8904 8905 8906 8907 8908 8909 8910 8911 8912 8913 8914 8915 8916 8917 8918 8919 8920 8921 8922 8923 8924 8925 8926 8927 8928 8929 8930 8931 8932 8933 8934 8935 8936 8937 8938 8939 8940 8941 8942 8943 8944 8945 8946 8947 8948 8949 8950 8951 8952 8953 8954 8955 8956 8957 8958 8959 8960 8961 8962 8963 8964 8965 8966 8967 8968 8969 8970 8971 8972 8973 8974 8975 8976 8977 8978 8979 8980 8981 8982 8983 8984 8985 8986 8987 8988 8989 8990 8991 8992 8993 8994 8995 8996 8997 8998 8999 9000 9001 9002 9003 9004 9005 9006 9007 9008 9009 9010 9011 9012 9013 9014 9015 9016 9017 9018 9019 9020 9021 9022 9023 9024 9025 9026 9027 9028 9029 9030 9031 9032 9033 9034 9035 9036 9037 9038 9039 9040 9041 9042 9043 9044 9045 9046 9047 9048 9049 9050 9051 9052 9053 9054 9055 9056 9057 9058 9059 9060 9061 9062 9063 9064 9065 9066 9067 9068 9069 9070 9071 9072 9073 9074 9075 9076 9077 9078 9079 9080 9081 9082 9083 9084 9085 9086 9087 9088 9089 9090 9091 9092 9093 9094 9095 9096 9097 9098 9099 9100 9101 9102 9103 9104 9105 9106 9107 9108 9109 9110 9111 9112 9113 9114 9115 9116 9117 9118 9119 9120 9121 9122 9123 9124 9125 9126 9127 9128 9129 9130 9131 9132 9133 9134 9135 9136 9137 9138 9139 9140 9141 9142 9143 9144 9145 9146 9147 9148 9149 9150 9151 9152 9153 9154 9155 9156 9157 9158 9159 9160 9161 9162 9163 9164 9165 9166 9167 9168 9169 9170 9171 9172 9173 9174 9175 9176 9177 9178 9179 9180 9181 9182 9183 9184 9185 9186 9187 9188 9189 9190 9191 9192 9193 9194 9195 9196 9197 9198 9199 9200 9201 9202 9203 9204 9205 9206 9207 9208 9209 9210 9211 9212 9213 9214 9215 9216 9217 9218 9219 9220 9221 9222 9223 9224 9225 9226 9227 9228 9229 9230 9231 9232 9233 9234 9235 9236 9237 9238 9239 9240 9241 9242 9243 9244 9245 9246 9247 9248 9249 9250 9251 9252 9253 9254 9255 9256 9257 9258 9259 9260 9261 9262 9263 9264 9265 9266 9267 9268 9269 9270 9271 9272 9273 9274 9275 9276 9277 9278 9279 9280 9281 9282 9283 9284 9285 9286 9287 9288 9289 9290 9291 9292 9293 9294 9295 9296 9297 9298 9299 9300 9301 9302 9303 9304 9305 9306 9307 9308 9309 9310 9311 9312 9313 9314 9315 9316 9317 9318 9319 9320 9321 9322 9323 9324 9325 9326 9327 9328 9329 9330 9331 9332 9333 9334 9335 9336 9337 9338 9339 9340 9341 9342 9343 9344 9345 9346 9347 9348 9349 9350 9351 9352 9353 9354 9355 9356 9357 9358 9359 9360 9361 9362 9363 9364 9365 9366 9367 9368 9369 9370 9371 9372 9373 9374 9375 9376 9377 9378 9379 9380 9381 9382 9383 9384 9385 9386 9387 9388 9389 9390 9391 9392 9393 9394 9395 9396 9397 9398 9399 9400 9401 9402 9403 9404 9405 9406 9407 9408 9409 9410 9411 9412 9413 9414 9415 9416 9417 9418 9419 9420 9421 9422 9423 9424 9425 9426 9427 9428 9429 9430 9431 9432 9433 9434 9435 9436 9437 9438 9439 9440 9441 9442 9443 9444 9445 9446 9447 9448 9449 9450 9451 9452 9453 9454 9455 9456 9457 9458 9459 9460 9461 9462 9463 9464 9465 9466 9467 9468 9469 9470 9471 9472 9473 9474 9475 9476 9477 9478 9479 9480 9481 9482 9483 9484 9485 9486 9487 9488 9489 9490 9491 9492 9493 9494 9495 9496 9497 9498 9499 9500 9501 9502 9503 9504 9505 9506 9507 9508 9509 9510 9511 9512 9513 9514 9515 9516 9517 9518 9519 9520 9521 9522 9523 9524 9525 9526 9527 9528 9529 9530 9531 9532 9533 9534 9535 9536 9537 9538 9539 9540 9541 9542 9543 9544 9545 9546 9547 9548 9549 9550 9551 9552 9553 9554 9555 9556 9557 9558 9559 9560 9561 9562 9563 9564 9565 9566 9567 9568 9569 9570 9571 9572 9573 9574 9575 9576 9577 9578 9579 9580 9581 9582 9583 9584 9585 9586 9587 9588 9589 9590 9591 9592 9593 9594 9595 9596 9597 9598 9599 9600 9601 9602 9603 9604 9605 9606 9607 9608 9609 9610 9611 9612 9613 9614 9615 9616 9617 9618 9619 9620 9621 9622 9623 9624 9625 9626 9627 9628 9629 9630 9631 9632 9633 9634 9635 9636 9637 9638 9639 9640 9641 9642 9643 9644 9645 9646 9647 9648 9649 9650 9651 9652 9653 9654 9655 9656 9657 9658 9659 9660 9661 9662 9663 9664 9665 9666 9667 9668 9669 9670 9671 9672 9673 9674 9675 9676 9677 9678 9679 9680 9681 9682 9683 9684 9685 9686 9687 9688 9689 9690 9691 9692 9693 9694 9695 9696 9697 9698 9699 9700 9701 9702 9703 9704 9705 9706 9707 9708 9709 9710 9711 9712 9713 9714 9715 9716 9717 9718 9719 9720 9721 9722 9723 9724 9725 9726 9727 9728 9729 9730 9731 9732 9733 9734 9735 9736 9737 9738 9739 9740 9741 9742 9743 9744 9745 9746 9747 9748 9749 9750 9751 9752 9753 9754 9755 9756 9757 9758 9759 9760 9761 9762 9763 9764 9765 9766 9767 9768 9769 9770 9771 9772 9773 9774 9775 9776 9777 9778 9779 9780 9781 9782 9783 9784 9785 9786 9787 9788 9789 9790 9791 9792 9793 9794 9795 9796 9797 9798 9799 9800 9801 9802 9803 9804 9805 9806 9807 9808 9809 9810 9811 9812 9813 9814 9815 9816 9817 9818 9819 9820 9821 9822 9823 9824 9825 9826 9827 9828 9829 9830 9831 9832 9833 9834 9835 9836 9837 9838 9839 9840 9841 9842 9843 9844 9845 9846 9847 9848 9849 9850 9851 9852 9853 9854 9855 9856 9857 9858 9859 9860 9861 9862 9863 9864 9865 9866 9867 9868 9869 9870 9871 9872 9873 9874 9875 9876 9877 9878 9879 9880 9881 9882 9883 9884 9885 9886 9887 9888 9889 9890 9891 9892 9893 9894 9895 9896 9897 9898 9899 9900 9901 9902 9903 9904 9905 9906 9907 9908 9909 9910 9911 9912 9913 9914 9915 9916 9917 9918 9919 9920 9921 9922 9923 9924 9925 9926 9927 9928 9929 9930 9931 9932 9933 9934 9935 9936 9937 9938 9939 9940 9941 9942 9943 9944 9945 9946 9947 9948 9949 9950 9951 9952 9953 9954 9955 9956 9957 9958 9959 9960 9961 9962 9963 9964 9965 9966 9967 9968 9969 9970 9971 9972 9973 9974 9975 9976 9977 9978 9979 9980 9981 9982 9983 9984 9985 9986 9987 9988 9989 9990 9991 9992 9993 9994 9995 9996 9997 9998 9999 10000 10001 10002 10003 10004 10005 10006 10007 10008 10009 10010 10011 10012 10013 10014 10015 10016 10017 10018 10019 10020 10021 10022 10023 10024 10025 10026 10027 10028 10029 10030 10031 10032 10033 10034 10035 10036 10037 10038 10039 10040 10041 10042 10043 10044 10045 10046 10047 10048 10049 10050 10051 10052 10053 10054 10055 10056 10057 10058 10059 10060 10061 10062 10063 10064 10065 10066 10067 10068 10069 10070 10071 10072 10073 10074 10075 10076 10077 10078 10079 10080 10081 10082 10083 10084 10085 10086 10087 10088 10089 10090 10091 10092 10093 10094 10095 10096 10097 10098 10099 10100 10101 10102 10103 10104 10105 10106 10107 10108 10109 10110 10111 10112 10113 10114 10115 10116 10117 10118 10119 10120 10121 10122 10123 10124 10125 10126 10127 10128 10129 10130 10131 10132 10133 10134 10135 10136 10137 10138 10139 10140 10141 10142 10143 10144 10145 10146 10147 10148 10149 10150 10151 10152 10153 10154 10155 10156 10157 10158 10159 10160 10161 10162 10163 10164 10165 10166 10167 10168 10169 10170 10171 10172 10173 10174 10175 10176 10177 10178 10179 10180 10181 10182 10183 10184 10185 10186 10187 10188 10189 10190 10191 10192 10193 10194 10195 10196 10197 10198 10199 10200 10201 10202 10203 10204 10205 10206 10207 10208 10209 10210 10211 10212 10213 10214 10215 10216 10217 10218 10219 10220 10221 10222 10223 10224 10225 10226 10227 10228 10229 10230 10231 10232 10233 10234 10235 10236 10237 10238 10239 10240 10241 10242 10243 10244 10245 10246 10247 10248 10249 10250 10251 10252 10253 10254 10255 10256 10257 10258 10259 10260 10261 10262 10263 10264 10265 10266 10267 10268 10269 10270 10271 10272 10273 10274 10275 10276 10277 10278 10279 10280 10281 10282 10283 10284 10285 10286 10287 10288 10289 10290 10291 10292 10293 10294 10295 10296 10297 10298 10299 10300 10301 10302 10303 10304 10305 10306 10307 10308 10309 10310 10311 10312 10313 10314 10315 10316 10317 10318 10319 10320 10321 10322 10323 10324 10325 10326 10327 10328 10329 10330 10331 10332 10333 10334 10335 10336 10337 10338 10339 10340 10341 10342 10343 10344 10345 10346 10347 10348 10349 10350 10351 10352 10353 10354 10355 10356 10357 10358 10359 10360 10361 10362 10363 10364 10365 10366 10367 10368 10369 10370 10371 10372 10373 10374 10375 10376 10377 10378 10379 10380 10381 10382 10383 10384 10385 10386 10387 10388 10389 10390 10391 10392 10393 10394 10395 10396 10397 10398 10399 10400 10401 10402 10403 10404 10405 10406 10407 10408 10409 10410 10411 10412 10413 10414 10415 10416 10417 10418 10419 10420 10421 10422 10423 10424 10425 10426 10427 10428 10429 10430 10431 10432 10433 10434 10435 10436 10437 10438 10439 10440 10441 10442 10443 10444 10445 10446 10447 10448 10449 10450 10451 10452 10453 10454 10455 10456 10457 10458 10459 10460 10461 10462 10463 10464 10465 10466 10467 10468 10469 10470 10471 10472 10473 10474 10475 10476 10477 10478 10479 10480 10481 10482 10483 10484 10485 10486 10487 10488 10489 10490 10491 10492 10493 10494 10495 10496 10497 10498 10499 10500 10501 10502 10503 10504 10505 10506 10507 10508 10509 10510 10511 10512 10513 10514 10515 10516 10517 10518 10519 10520 10521 10522 10523 10524 10525 10526 10527 10528 10529 10530 10531 10532 10533 10534 10535 10536 10537 10538 10539 10540 10541 10542 10543 10544 10545 10546 10547 10548 10549 10550 10551 10552 10553 10554 10555 10556 10557 10558 10559 10560 10561 10562 10563 10564 10565 10566 10567 10568 10569 10570 10571 10572 10573 10574 10575 10576 10577 10578 10579 10580 10581 10582 10583 10584 10585 10586 10587 10588 10589 10590 10591 10592 10593 10594 10595 10596 10597 10598 10599 10600 10601 10602 10603 10604 10605 10606 10607 10608 10609 10610 10611 10612 10613 10614 10615 10616 10617 10618 10619 10620 10621 10622 10623 10624 10625 10626 10627 10628 10629 10630 10631 10632 10633 10634 10635 10636 10637 10638 10639 10640 10641 10642 10643 10644 10645 10646 10647 10648 10649 10650 10651 10652 10653 10654 10655 10656 10657 10658 10659 10660 10661 10662 10663 10664 10665 10666 10667 10668 10669 10670 10671 10672 10673 10674 10675 10676 10677 10678 10679 10680 10681 10682 10683 10684 10685 10686 10687 10688 10689 10690 10691 10692 10693 10694 10695 10696 10697 10698 10699 10700 10701 10702 10703 10704 10705 10706 10707 10708 10709 10710 10711 10712 10713 10714 10715 10716 10717 10718 10719 10720 10721 10722 10723 10724 10725 10726 10727 10728 10729 10730 10731 10732 10733 10734 10735 10736 10737 10738 10739 10740 10741 10742 10743 10744 10745 10746 10747 10748 10749 10750 10751 10752 10753 10754 10755 10756 10757 10758 10759 10760 10761 10762 10763 10764 10765 10766 10767 10768 10769 10770 10771 10772 10773 10774 10775 10776 10777 10778 10779 10780 10781 10782 10783 10784 10785 10786 10787 10788 10789 10790 10791 10792 10793 10794 10795 10796 10797 10798 10799 10800 10801 10802 10803 10804 10805 10806 10807 10808 10809 10810 10811 10812 10813 10814 10815 10816 10817 10818 10819 10820 10821 10822 10823 10824 10825 10826 10827 10828 10829 10830 10831 10832 10833 10834 10835 10836 10837 10838 10839 10840 10841 10842 10843 10844 10845 10846 10847 10848 10849 10850 10851 10852 10853 10854 10855 10856 10857 10858 10859 10860 10861 10862 10863 10864 10865 10866 10867 10868 10869 10870 10871 10872 10873 10874 10875 10876 10877 10878 10879 10880 10881 10882 10883 10884 10885 10886 10887 10888 10889 10890 10891 10892 10893 10894 10895 10896 10897 10898 10899 10900 10901 10902 10903 10904 10905 10906 10907 10908 10909 10910 10911 10912 10913 10914 10915 10916 10917 10918 10919 10920 10921 10922 10923 10924 10925 10926 10927 10928 10929 10930 10931 10932 10933 10934 10935 10936 10937 10938 10939 10940 10941 10942 10943 10944 10945 10946 10947 10948 10949 10950 10951 10952 10953 10954 10955 10956 10957 10958 10959 10960 10961 10962 10963 10964 10965 10966 10967 10968 10969 10970 10971 10972 10973 10974 10975 10976 10977 10978 10979 10980 10981 10982 10983 10984 10985 10986 10987 10988 10989 10990 10991 10992 10993 10994 10995 10996 10997 10998 10999 11000 11001 11002 11003 11004 11005 11006 11007 11008 11009 11010 11011 11012 11013 11014 11015 11016 11017 11018 11019 11020 11021 11022 11023 11024 11025 11026 11027 11028 11029 11030 11031 11032 11033 11034 11035 11036 11037 11038 11039 11040 11041 11042 11043 11044 11045 11046 11047 11048 11049 11050 11051 11052 11053 11054 11055 11056 11057 11058 11059 11060 11061 11062 11063 11064 11065 11066 11067 11068 11069 11070 11071 11072 11073 11074 11075 11076 11077 11078 11079 11080 11081 11082 11083 11084 11085 11086 11087 11088 11089 11090 11091 11092 11093 11094 11095 11096 11097 11098 11099 11100 11101 11102 11103 11104 11105 11106 11107 11108 11109 11110 11111 11112 11113 11114 11115 11116 11117 11118 11119 11120 11121 11122 11123 11124 11125 11126 11127 11128 11129 11130 11131 11132 11133 11134 11135 11136 11137 11138 11139 11140 11141 11142 11143 11144 11145 11146 11147 11148 11149 11150 11151 11152 11153 11154 11155 11156 11157 11158 11159 11160 11161 11162 11163 11164 11165 11166 11167 11168 11169 11170 11171 11172 11173 11174 11175 11176 11177 11178 11179 11180 11181 11182 11183 11184 11185 11186 11187 11188 11189 11190 11191 11192 11193 11194 11195 11196 11197 11198 11199 11200 11201 11202 11203 11204 11205 11206 11207 11208 11209 11210 11211 11212 11213 11214 11215 11216 11217 11218 11219 11220 11221 11222 11223 11224 11225 11226 11227 11228 11229 11230 11231 11232 11233 11234 11235 11236 11237 11238 11239 11240 11241 11242 11243 11244 11245 11246 11247 11248 11249 11250 11251 11252 11253 11254 11255 11256 11257 11258 11259 11260 11261 11262 11263 11264 11265 11266 11267 11268 11269 11270 11271 11272 11273 11274 11275 11276 11277 11278 11279 11280 11281 11282 11283 11284 11285 11286 11287 11288 11289 11290 11291 11292 11293 11294 11295 11296 11297 11298 11299 11300 11301 11302 11303 11304 11305 11306 11307 11308 11309 11310 11311 11312 11313 11314 11315 11316 11317 11318 11319 11320 11321 11322 11323 11324 11325 11326 11327 11328 11329 11330 11331 11332 11333 11334 11335 11336 11337 11338 11339 11340 11341 11342 11343 11344 11345 11346 11347 11348 11349 11350 11351 11352 11353 11354 11355 11356 11357 11358 11359 11360 11361 11362 11363 11364 11365 11366 11367 11368 11369 11370 11371 11372 11373 11374 11375 11376 11377 11378 11379 11380 11381 11382 11383 11384 11385 11386 11387 11388 11389 11390 11391 11392 11393 11394 11395 11396 11397 11398 11399 11400 11401 11402 11403 11404 11405 11406 11407 11408 11409 11410 11411 11412 11413 11414 11415 11416 11417 11418 11419 11420 11421 11422 11423 11424 11425 11426 11427 11428 11429 11430 11431 11432 11433 11434 11435 11436 11437 11438 11439 11440 11441 11442 11443 11444 11445 11446 11447 11448 11449 11450 11451 11452 11453 11454 11455 11456 11457 11458 11459 11460 11461 11462 11463 11464 11465 11466 11467 11468 11469 11470 11471 11472 11473 11474 11475 11476 11477 11478 11479 11480 11481 11482 11483 11484 11485 11486 11487 11488 11489 11490 11491 11492 11493 11494 11495 11496 11497 11498 11499 11500 11501 11502 11503 11504 11505 11506 11507 11508 11509 11510 11511 11512 11513 11514 11515 11516 11517 11518 11519 11520 11521 11522 11523 11524 11525 11526 11527 11528 11529 11530 11531 11532 11533 11534 11535 11536 11537 11538 11539 11540 11541 11542 11543 11544 11545 11546 11547 11548 11549 11550 11551 11552 11553 11554 11555 11556 11557 11558 11559 11560 11561 11562 11563 11564 11565 11566 11567 11568 11569 11570 11571 11572 11573 11574 11575 11576 11577 11578 11579 11580 11581 11582 11583 11584 11585 11586 11587 11588 11589 11590 11591 11592 11593 11594 11595 11596 11597 11598 11599 11600 11601 11602 11603 11604 11605 11606 11607 11608 11609 11610 11611 11612 11613 11614 11615 11616 11617 11618 11619 11620 11621 11622 11623 11624 11625 11626 11627 11628 11629 11630 11631 11632 11633 11634 11635 11636 11637 11638 11639 11640 11641 11642 11643 11644 11645 11646 11647 11648 11649 11650 11651 11652 11653 11654 11655 11656 11657 11658 11659 11660 11661 11662 11663 11664 11665 11666 11667 11668 11669 11670 11671 11672 11673 11674 11675 11676 11677 11678 11679 11680 11681 11682 11683 11684 11685 11686 11687 11688 11689 11690 11691 11692 11693 11694 11695 11696 11697 11698 11699 11700 11701 11702 11703 11704 11705 11706 11707 11708 11709 11710 11711 11712 11713 11714 11715 11716 11717 11718 11719 11720 11721 11722 11723 11724 11725 11726 11727 11728 11729 11730 11731 11732 11733 11734 11735 11736 11737 11738 11739 11740 11741 11742 11743 11744 11745 11746 11747 11748 11749 11750 11751 11752 11753 11754 11755 11756 11757 11758 11759 11760 11761 11762 11763 11764 11765 11766 11767 11768 11769 11770 11771 11772 11773 11774 11775 11776 11777 11778 11779 11780 11781 11782 11783 11784 11785 11786 11787 11788 11789 11790 11791 11792 11793 11794 11795 11796 11797 11798 11799 11800 11801 11802 11803 11804 11805 11806 11807 11808 11809 11810 11811 11812 11813 11814 11815 11816 11817 11818 11819 11820 11821 11822 11823 11824 11825 11826 11827 11828 11829 11830 11831 11832 11833 11834 11835 11836 11837 11838 11839 11840 11841 11842 11843 11844 11845 11846 11847 11848 11849 11850 11851 11852 11853 11854 11855 11856 11857 11858 11859 11860 11861 11862 11863 11864 11865 11866 11867 11868 11869 11870 11871 11872 11873 11874 11875 11876 11877 11878 11879 11880 11881 11882 11883 11884 11885 11886 11887 11888 11889 11890 11891 11892 11893 11894 11895 11896 11897 11898 11899 11900 11901 11902 11903 11904 11905 11906 11907 11908 11909 11910 11911 11912 11913 11914 11915 11916 11917 11918 11919 11920 11921 11922 11923 11924 11925 11926 11927 11928 11929 11930 11931 11932 11933 11934 11935 11936 11937 11938 11939 11940 11941 11942 11943 11944 11945 11946 11947 11948 11949 11950 11951 11952 11953 11954 11955 11956 11957 11958 11959 11960 11961 11962 11963 11964 11965 11966 11967 11968 11969 11970 11971 11972 11973 11974 11975 11976 11977 11978 11979 11980 11981 11982 11983 11984 11985 11986 11987 11988 11989 11990 11991 11992 11993 11994 11995 11996 11997 11998 11999 12000 12001 12002 12003 12004 12005 12006 12007 12008 12009 12010 12011 12012 12013 12014 12015 12016 12017 12018 12019 12020 12021 12022 12023 12024 12025 12026 12027 12028 12029 12030 12031 12032 12033 12034 12035 12036 12037 12038 12039 12040 12041 12042 12043 12044 12045 12046 12047 12048 12049 12050 12051 12052 12053 12054 12055 12056 12057 12058 12059 12060 12061 12062 12063 12064 12065 12066 12067 12068 12069 12070 12071 12072 12073 12074 12075 12076 12077 12078 12079 12080 12081 12082 12083 12084 12085 12086 12087 12088 12089 12090 12091 12092 12093 12094 12095 12096 12097 12098 12099 12100 12101 12102 12103 12104 12105 12106 12107 12108 12109 12110 12111 12112 12113 12114 12115 12116 12117 12118 12119 12120 12121 12122 12123 12124 12125 12126 12127 12128 12129 12130 12131 12132 12133 12134 12135 12136 12137 12138 12139 12140 12141 12142 12143 12144 12145 12146 12147 12148 12149 12150 12151 12152 12153 12154 12155 12156 12157 12158 12159 12160 12161 12162 12163 12164 12165 12166 12167 12168 12169 12170 12171 12172 12173 12174 12175 12176 12177 12178 12179 12180 12181 12182 12183 12184 12185 12186 12187 12188 12189 12190 12191 12192 12193 12194 12195 12196 12197 12198 12199 12200 12201 12202 12203 12204 12205 12206 12207 12208 12209 12210 12211 12212 12213 12214 12215 12216 12217 12218 12219 12220 12221 12222 12223 12224 12225 12226 12227 12228 12229 12230 12231 12232 12233 12234 12235 12236 12237 12238 12239 12240 12241 12242 12243 12244 12245 12246 12247 12248 12249 12250 12251 12252 12253 12254 12255 12256 12257 12258 12259 12260 12261 12262 12263 12264 12265 12266 12267 12268 12269 12270 12271 12272 12273 12274 12275 12276 12277 12278 12279 12280 12281 12282 12283 12284 12285 12286 12287 12288 12289 12290 12291 12292 12293 12294 12295 12296 12297 12298 12299 12300 12301 12302 12303 12304 12305 12306 12307 12308 12309 12310 12311 12312 12313 12314 12315 12316 12317 12318 12319 12320 12321 12322 12323 12324 12325 12326 12327 12328 12329 12330 12331 12332 12333 12334 12335 12336 12337 12338 12339 12340 12341 12342 12343 12344 12345 12346 12347 12348 12349 12350 12351 12352 12353 12354 12355 12356 12357 12358 12359 12360 12361 12362 12363 12364 12365 12366 12367 12368 12369 12370 12371 12372 12373 12374 12375 12376 12377 12378 12379 12380 12381 12382 12383 12384 12385 12386 12387 12388 12389 12390 12391 12392 12393 12394 12395 12396 12397 12398 12399 12400 12401 12402 12403 12404 12405 12406 12407 12408 12409 12410 12411 12412 12413 12414 12415 12416 12417 12418 12419 12420 12421 12422 12423 12424 12425 12426 12427 12428 12429 12430 12431 12432 12433 12434 12435 12436 12437 12438 12439 12440 12441 12442 12443 12444 12445 12446 12447 12448 12449 12450 12451 12452 12453 12454 12455 12456 12457 12458 12459 12460 12461 12462 12463 12464 12465 12466 12467 12468 12469 12470 12471 12472 12473 12474 12475 12476 12477 12478 12479 12480 12481 12482 12483 12484 12485 12486 12487 12488 12489 12490 12491 12492 12493 12494 12495 12496 12497 12498 12499 12500 12501 12502 12503 12504 12505 12506 12507 12508 12509 12510 12511 12512 12513 12514 12515 12516 12517 12518 12519 12520 12521 12522 12523 12524 12525 12526 12527 12528 12529 12530 12531 12532 12533 12534 12535 12536 12537 12538 12539 12540 12541 12542 12543 12544 12545 12546 12547 12548 12549 12550 12551 12552 12553 12554 12555 12556 12557 12558 12559 12560 12561 12562 12563 12564 12565 12566 12567 12568 12569 12570 12571 12572 12573 12574 12575 12576 12577 12578 12579 12580 12581 12582 12583 12584 12585 12586 12587 12588 12589 12590 12591 12592 12593 12594 12595 12596 12597 12598 12599 12600 12601 12602 12603 12604 12605 12606 12607 12608 12609 12610 12611 12612 12613 12614 12615 12616 12617 12618 12619 12620 12621 12622 12623 12624 12625 12626 12627 12628 12629 12630 12631 12632 12633 12634 12635 12636 12637 12638 12639 12640 12641 12642 12643 12644 12645 12646 12647 12648 12649 12650 12651 12652 12653 12654 12655 12656 12657 12658 12659 12660 12661 12662 12663 12664 12665 12666 12667 12668 12669 12670 12671 12672 12673 12674 12675 12676 12677 12678 12679 12680 12681 12682 12683 12684 12685 12686 12687 12688 12689 12690 12691 12692 12693 12694 12695 12696 12697 12698 12699 12700 12701 12702 12703 12704 12705 12706 12707 12708 12709 12710 12711 12712 12713 12714 12715 12716 12717 12718 12719 12720 12721 12722 12723 12724 12725 12726 12727 12728 12729 12730 12731 12732 12733 12734 12735 12736 12737 12738 12739 12740 12741 12742 12743 12744 12745 12746 12747 12748 12749 12750 12751 12752 12753 12754 12755 12756 12757 12758 12759 12760 12761 12762 12763 12764 12765 12766 12767 12768 12769 12770 12771 12772 12773 12774 12775 12776 12777 12778 12779 12780 12781 12782 12783 12784 12785 12786 12787 12788 12789 12790 12791 12792 12793 12794 12795 12796 12797 12798 12799 12800 12801 12802 12803 12804 12805 12806 12807 12808 12809 12810 12811 12812 12813 12814 12815 12816 12817 12818 12819 12820 12821 12822 12823 12824 12825 12826 12827 12828 12829 12830 12831 12832 12833 12834 12835 12836 12837 12838 12839 12840 12841 12842 12843 12844 12845 12846 12847 12848 12849 12850 12851 12852 12853 12854 12855 12856 12857 12858 12859 12860 12861 12862 12863 12864 12865 12866 12867 12868 12869 12870 12871 12872 12873 12874 12875 12876 12877 12878 12879 12880 12881 12882 12883 12884 12885 12886 12887 12888 12889 12890 12891 12892 12893 12894 12895 12896 12897 12898 12899 12900 12901 12902 12903 12904 12905 12906 12907 12908 12909 12910 12911 12912 12913 12914 12915 12916 12917 12918 12919 12920 12921 12922 12923 12924 12925 12926 12927 12928 12929 12930 12931 12932 12933 12934 12935 12936 12937 12938 12939 12940 12941 12942 12943 12944 12945 12946 12947 12948 12949 12950 12951 12952 12953 12954 12955 12956 12957 12958 12959 12960 12961 12962 12963 12964 12965 12966 12967 12968 12969 12970 12971 12972 12973 12974 12975 12976 12977 12978 12979 12980 12981 12982 12983 12984 12985 12986 12987 12988 12989 12990 12991 12992 12993 12994 12995 12996 12997 12998 12999 13000 13001 13002 13003 13004 13005 13006 13007 13008 13009 13010 13011 13012 13013 13014 13015 13016 13017 13018 13019 13020 13021 13022 13023 13024 13025 13026 13027 13028 13029 13030 13031 13032 13033 13034 13035 13036 13037 13038 13039 13040 13041 13042 13043 13044 13045 13046 13047 13048 13049 13050 13051 13052 13053 13054 13055 13056 13057 13058 13059 13060 13061 13062 13063 13064 13065 13066 13067 13068 13069 13070 13071 13072 13073 13074 13075 13076 13077 13078 13079 13080 13081 13082 13083 13084 13085 13086 13087 13088 13089 13090 13091 13092 13093 13094 13095 13096 13097 13098 13099 13100 13101 13102 13103 13104 13105 13106 13107 13108 13109 13110 13111 13112 13113 13114 13115 13116 13117 13118 13119 13120 13121 13122 13123 13124 13125 13126 13127 13128 13129 13130 13131 13132 13133 13134 13135 13136 13137 13138 13139 13140 13141 13142 13143 13144 13145 13146 13147 13148 13149 13150 13151 13152 13153 13154 13155 13156 13157 13158 13159 13160 13161 13162 13163 13164 13165 13166 13167 13168 13169 13170 13171 13172 13173 13174 13175 13176 13177 13178 13179 13180 13181 13182 13183 13184 13185 13186 13187 13188 13189 13190 13191 13192 13193 13194 13195 13196 13197 13198 13199 13200 13201 13202 13203 13204 13205 13206 13207 13208 13209 13210 13211 13212 13213 13214 13215 13216 13217 13218 13219 13220 13221 13222 13223 13224 13225 13226 13227 13228 13229 13230 13231 13232 13233 13234 13235 13236 13237 13238 13239 13240 13241 13242 13243 13244 13245 13246 13247 13248 13249 13250 13251 13252 13253 13254 13255 13256 13257 13258 13259 13260 13261 13262 13263 13264 13265 13266 13267 13268 13269 13270 13271 13272 13273 13274 13275 13276 13277 13278 13279 13280 13281 13282 13283 13284 13285 13286 13287 13288 13289 13290 13291 13292 13293 13294 13295 13296 13297 13298 13299 13300 13301 13302 13303 13304 13305 13306 13307 13308 13309 13310 13311 13312 13313 13314 13315 13316 13317 13318 13319 13320 13321 13322 13323 13324 13325 13326 13327 13328 13329 13330 13331 13332 13333 13334 13335 13336 13337 13338 13339 13340 13341 13342 13343 13344 13345 13346 13347 13348 13349 13350 13351 13352 13353 13354 13355 13356 13357 13358 13359 13360 13361 13362 13363 13364 13365 13366 13367 13368 13369 13370 13371 13372 13373 13374 13375 13376 13377 13378 13379 13380 13381 13382 13383 13384 13385 13386 13387 13388 13389 13390 13391 13392 13393 13394 13395 13396 13397 13398 13399 13400 13401 13402 13403 13404 13405 13406 13407 13408 13409 13410 13411 13412 13413 13414 13415 13416 13417 13418 13419 13420 13421 13422 13423 13424 13425 13426 13427 13428 13429 13430 13431 13432 13433 13434 13435 13436 13437 13438 13439 13440 13441 13442 13443 13444 13445 13446 13447 13448 13449 13450 13451 13452 13453 13454 13455 13456 13457 13458 13459 13460 13461 13462 13463 13464 13465 13466 13467 13468 13469 13470 13471 13472 13473 13474 13475 13476 13477 13478 13479 13480 13481 13482 13483 13484 13485 13486 13487 13488 13489 13490 13491 13492 13493 13494 13495 13496 13497 13498 13499 13500 13501 13502 13503 13504 13505 13506 13507 13508 13509 13510 13511 13512 13513 13514 13515 13516 13517 13518 13519 13520 13521 13522 13523 13524 13525 13526 13527 13528 13529 13530 13531 13532 13533 13534 13535 13536 13537 13538 13539 13540 13541 13542 13543 13544 13545 13546 13547 13548 13549 13550 13551 13552 13553 13554 13555 13556 13557 13558 13559 13560 13561 13562 13563 13564 13565 13566 13567 13568 13569 13570 13571 13572 13573 13574 13575 13576 13577 13578 13579 13580 13581 13582 13583 13584 13585 13586 13587 13588 13589 13590 13591 13592 13593 13594 13595 13596 13597 13598 13599 13600 13601 13602 13603 13604 13605 13606 13607 13608 13609 13610 13611 13612 13613 13614 13615 13616 13617 13618 13619 13620 13621 13622 13623 13624 13625 13626 13627 13628 13629 13630 13631 13632 13633 13634 13635 13636 13637 13638 13639 13640 13641 13642 13643 13644 13645 13646 13647 13648 13649 13650 13651 13652 13653 13654 13655 13656 13657 13658 13659 13660 13661 13662 13663 13664 13665 13666 13667 13668 13669 13670 13671 13672 13673 13674 13675 13676 13677 13678 13679 13680 13681 13682 13683 13684 13685 13686 13687 13688 13689 13690 13691 13692 13693 13694 13695 13696 13697 13698 13699 13700 13701 13702 13703 13704 13705 13706 13707 13708 13709 13710 13711 13712 13713 13714 13715 13716 13717 13718 13719 13720 13721 13722 13723 13724 13725 13726 13727 13728 13729 13730 13731 13732 13733 13734 13735 13736 13737 13738 13739 13740 13741 13742 13743 13744 13745 13746 13747 13748 13749 13750 13751 13752 13753 13754 13755 13756 13757 13758 13759 13760 13761 13762 13763 13764 13765 13766 13767 13768 13769 13770 13771 13772 13773 13774 13775 13776 13777 13778 13779 13780 13781 13782 13783 13784 13785 13786 13787 13788 13789 13790 13791 13792 13793 13794 13795 13796 13797 13798 13799 13800 13801 13802 13803 13804 13805 13806 13807 13808 13809 13810 13811 13812 13813 13814 13815 13816 13817 13818 13819 13820 13821 13822 13823 13824 13825 13826 13827 13828 13829 13830 13831 13832 13833 13834 13835 13836 13837 13838 13839 13840 13841 13842 13843 13844 13845 13846 13847 13848 13849 13850 13851 13852 13853 13854 13855 13856 13857 13858 13859 13860 13861 13862 13863 13864 13865 13866 13867 13868 13869 13870 13871 13872 13873 13874 13875 13876 13877 13878 13879 13880 13881 13882 13883 13884 13885 13886 13887 13888 13889 13890 13891 13892 13893 13894 13895 13896 13897 13898 13899 13900 13901 13902 13903 13904 13905 13906 13907 13908 13909 13910 13911 13912 13913 13914 13915 13916 13917 13918 13919 13920 13921 13922 13923 13924 13925 13926 13927 13928 13929 13930 13931 13932 13933 13934 13935 13936 13937 13938 13939 13940 13941 13942 13943 13944 13945 13946 13947 13948 13949 13950 13951 13952 13953 13954 13955 13956 13957 13958 13959 13960 13961 13962 13963 13964 13965 13966 13967 13968 13969 13970 13971 13972 13973 13974 13975 13976 13977 13978 13979 13980 13981 13982 13983 13984 13985 13986 13987 13988 13989 13990 13991 13992 13993 13994 13995 13996 13997 13998 13999 14000 14001 14002 14003 14004 14005 14006 14007 14008 14009 14010 14011 14012 14013 14014 14015 14016 14017 14018 14019 14020 14021 14022 14023 14024 14025 14026 14027 14028 14029 14030 14031 14032 14033 14034 14035 14036 14037 14038 14039 14040 14041 14042 14043 14044 14045 14046 14047 14048 14049 14050 14051 14052 14053 14054 14055 14056 14057 14058 14059 14060 14061 14062 14063 14064 14065 14066 14067 14068 14069 14070 14071 14072 14073 14074 14075 14076 14077 14078 14079 14080 14081 14082 14083 14084 14085 14086 14087 14088 14089 14090 14091 14092 14093 14094 14095 14096 14097 14098 14099 14100 14101 14102 14103 14104 14105 14106 14107 14108 14109 14110 14111 14112 14113 14114 14115 14116 14117 14118 14119 14120 14121 14122 14123 14124 14125 14126 14127 14128 14129 14130 14131 14132 14133 14134 14135 14136 14137 14138 14139 14140 14141 14142 14143 14144 14145 14146 14147 14148 14149 14150 14151 14152 14153 14154 14155 14156 14157 14158 14159 14160 14161 14162 14163 14164 14165 14166 14167 14168 14169 14170 14171 14172 14173 14174 14175 14176 14177 14178 14179 14180 14181 14182 14183 14184 14185 14186 14187 14188 14189 14190 14191 14192 14193 14194 14195 14196 14197 14198 14199 14200 14201 14202 14203 14204 14205 14206 14207 14208 14209 14210 14211 14212 14213 14214 14215 14216 14217 14218 14219 14220 14221 14222 14223 14224 14225 14226 14227 14228 14229 14230 14231 14232 14233 14234 14235 14236 14237 14238 14239 14240 14241 14242 14243 14244 14245 14246 14247 14248 14249 14250 14251 14252 14253 14254 14255 14256 14257 14258 14259 14260 14261 14262 14263 14264 14265 14266 14267 14268 14269 14270 14271 14272 14273 14274 14275 14276 14277 14278 14279 14280 14281 14282 14283 14284 14285 14286 14287 14288 14289 14290 14291 14292 14293 14294 14295 14296 14297 14298 14299 14300 14301 14302 14303 14304 14305 14306 14307 14308 14309 14310 14311 14312 14313 14314 14315 14316 14317 14318 14319 14320 14321 14322 14323 14324 14325 14326 14327 14328 14329 14330 14331 14332 14333 14334 14335 14336 14337 14338 14339 14340 14341 14342 14343 14344 14345 14346 14347 14348 14349 14350 14351 14352 14353 14354 14355 14356 14357 14358 14359 14360 14361 14362 14363 14364 14365 14366 14367 14368 14369 14370 14371 14372 14373 14374 14375 14376 14377 14378 14379 14380 14381 14382 14383 14384 14385 14386 14387 14388 14389 14390 14391 14392 14393 14394 14395 14396 14397 14398 14399 14400 14401 14402 14403 14404 14405 14406 14407 14408 14409 14410 14411 14412 14413 14414 14415 14416 14417 14418 14419 14420 14421 14422 14423 14424 14425 14426 14427 14428 14429 14430 14431 14432 14433 14434 14435 14436 14437 14438 14439 14440 14441 14442 14443 14444 14445 14446 14447 14448 14449 14450 14451 14452 14453 14454 14455 14456 14457 14458 14459 14460 14461 14462 14463 14464 14465 14466 14467 14468 14469 14470 14471 14472 14473 14474 14475 14476 14477 14478 14479 14480 14481 14482 14483 14484 14485 14486 14487 14488 14489 14490 14491 14492 14493 14494 14495 14496 14497 14498 14499 14500 14501 14502 14503 14504 14505 14506 14507 14508 14509 14510 14511 14512 14513 14514 14515 14516 14517 14518 14519 14520 14521 14522 14523 14524 14525 14526 14527 14528 14529 14530 14531 14532 14533 14534 14535 14536 14537 14538 14539 14540 14541 14542 14543 14544 14545 14546 14547 14548 14549 14550 14551 14552 14553 14554 14555 14556 14557 14558 14559 14560 14561 14562 14563 14564 14565 14566 14567 14568 14569 14570 14571 14572 14573 14574 14575 14576 14577 14578 14579 14580 14581 14582 14583 14584 14585 14586 14587 14588 14589 14590 14591 14592 14593 14594 14595 14596 14597 14598 14599 14600 14601 14602 14603 14604 14605 14606 14607 14608 14609 14610 14611 14612 14613 14614 14615 14616 14617 14618 14619 14620 14621 14622 14623 14624 14625 14626 14627 14628 14629 14630 14631 14632 14633 14634 14635 14636 14637 14638 14639 14640 14641 14642 14643 14644 14645 14646 14647 14648 14649 14650 14651 14652 14653 14654 14655 14656 14657 14658 14659 14660 14661 14662 14663 14664 14665 14666 14667 14668 14669 14670 14671 14672 14673 14674 14675 14676 14677 14678 14679 14680 14681 14682 14683 14684 14685 14686 14687 14688 14689 14690 14691 14692 14693 14694 14695 14696 14697 14698 14699 14700 14701 14702 14703 14704 14705 14706 14707 14708 14709 14710 14711 14712 14713 14714 14715 14716 14717 14718 14719 14720 14721 14722 14723 14724 14725 14726 14727 14728 14729 14730 14731 14732 14733 14734 14735 14736 14737 14738 14739 14740 14741 14742 14743 14744 14745 14746 14747 14748 14749 14750 14751 14752 14753 14754 14755 14756 14757 14758 14759 14760 14761 14762 14763 14764 14765 14766 14767 14768 14769 14770 14771 14772 14773 14774 14775 14776 14777 14778 14779 14780 14781 14782 14783 14784 14785 14786 14787 14788 14789 14790 14791 14792 14793 14794 14795 14796 14797 14798 14799 14800 14801 14802 14803 14804 14805 14806 14807 14808 14809 14810 14811 14812 14813 14814 14815 14816 14817 14818 14819 14820 14821 14822 14823 14824 14825 14826 14827 14828 14829 14830 14831 14832 14833 14834 14835 14836 14837 14838 14839 14840 14841 14842 14843 14844 14845 14846 14847 14848 14849 14850 14851 14852 14853 14854 14855 14856 14857 14858 14859 14860 14861 14862 14863 14864 14865 14866 14867 14868 14869 14870 14871 14872 14873 14874 14875 14876 14877 14878 14879 14880 14881 14882 14883 14884 14885 14886 14887 14888 14889 14890 14891 14892 14893 14894 14895 14896 14897 14898 14899 14900 14901 14902 14903 14904 14905 14906 14907 14908 14909 14910 14911 14912 14913 14914 14915 14916 14917 14918 14919 14920 14921 14922 14923 14924 14925 14926 14927 14928 14929 14930 14931 14932 14933 14934 14935 14936 14937 14938 14939 14940 14941 14942 14943 14944 14945 14946 14947 14948 14949 14950 14951 14952 14953 14954 14955 14956 14957 14958 14959 14960 14961 14962 14963 14964 14965 14966 14967 14968 14969 14970 14971 14972 14973 14974 14975 14976 14977 14978 14979 14980 14981 14982 14983 14984 14985 14986 14987 14988 14989 14990 14991 14992 14993 14994 14995 14996 14997 14998 14999 15000 15001 15002 15003 15004 15005 15006 15007 15008 15009 15010 15011 15012 15013 15014 15015 15016 15017 15018 15019 15020 15021 15022 15023 15024 15025 15026 15027 15028 15029 15030 15031 15032 15033 15034 15035 15036 15037 15038 15039 15040 15041 15042 15043 15044 15045 15046 15047 15048 15049 15050 15051 15052 15053 15054 15055 15056 15057 15058 15059 15060 15061 15062 15063 15064 15065 15066 15067 15068 15069 15070 15071 15072 15073 15074 15075 15076 15077 15078 15079 15080 15081 15082 15083 15084 15085 15086 15087 15088 15089 15090 15091 15092 15093 15094 15095 15096 15097 15098 15099 15100 15101 15102 15103 15104 15105 15106 15107 15108 15109 15110 15111 15112 15113 15114 15115 15116 15117 15118 15119 15120 15121 15122 15123 15124 15125 15126 15127 15128 15129 15130 15131 15132 15133 15134 15135 15136 15137 15138 15139 15140 15141 15142 15143 15144 15145 15146 15147 15148 15149 15150 15151 15152 15153 15154 15155 15156 15157 15158 15159 15160 15161 15162 15163 15164 15165 15166 15167 15168 15169 15170 15171 15172 15173 15174 15175 15176 15177 15178 15179 15180 15181 15182 15183 15184 15185 15186 15187 15188 15189 15190 15191 15192 15193 15194 15195 15196 15197 15198 15199 15200 15201 15202 15203 15204 15205 15206 15207 15208 15209 15210 15211 15212 15213 15214 15215 15216 15217 15218 15219 15220 15221 15222 15223 15224 15225 15226 15227 15228 15229 15230 15231 15232 15233 15234 15235 15236 15237 15238 15239 15240 15241 15242 15243 15244 15245 15246 15247 15248 15249 15250 15251 15252 15253 15254 15255 15256 15257 15258 15259 15260 15261 15262 15263 15264 15265 15266 15267 15268 15269 15270 15271 15272 15273 15274 15275 15276 15277 15278 15279 15280 15281 15282 15283 15284 15285 15286 15287 15288 15289 15290 15291 15292 15293 15294 15295 15296 15297 15298 15299 15300 15301 15302 15303 15304 15305 15306 15307 15308 15309 15310 15311 15312 15313 15314 15315 15316 15317 15318 15319 15320 15321 15322 15323 15324 15325 15326 15327 15328 15329 15330 15331 15332 15333 15334 15335 15336 15337 15338 15339 15340 15341 15342 15343 15344 15345 15346 15347 15348 15349 15350 15351 15352 15353 15354 15355 15356 15357 15358 15359 15360 15361 15362 15363 15364 15365 15366 15367 15368 15369 15370 15371 15372 15373 15374 15375 15376 15377 15378 15379 15380 15381 15382 15383 15384 15385 15386 15387 15388 15389 15390 15391 15392 15393 15394 15395 15396 15397 15398 15399 15400 15401 15402 15403 15404 15405 15406 15407 15408 15409 15410 15411 15412 15413 15414 15415 15416 15417 15418 15419 15420 15421 15422 15423 15424 15425 15426 15427 15428 15429 15430 15431 15432 15433 15434 15435 15436 15437 15438 15439 15440 15441 15442 15443 15444 15445 15446 15447 15448 15449 15450 15451 15452 15453 15454 15455 15456 15457 15458 15459 15460 15461 15462 15463 15464 15465 15466 15467 15468 15469 15470 15471 15472 15473 15474 15475 15476 15477 15478 15479 15480 15481 15482 15483 15484 15485 15486 15487 15488 15489 15490 15491 15492 15493 15494 15495 15496 15497 15498 15499 15500 15501 15502 15503 15504 15505 15506 15507 15508 15509 15510 15511 15512 15513 15514 15515 15516 15517 15518 15519 15520 15521 15522 15523 15524 15525 15526 15527 15528 15529 15530 15531 15532 15533 15534 15535 15536 15537 15538 15539 15540 15541 15542 15543 15544 15545 15546 15547 15548 15549 15550 15551 15552 15553 15554 15555 15556 15557 15558 15559 15560 15561 15562 15563 15564 15565 15566 15567 15568 15569 15570 15571 15572 15573 15574 15575 15576 15577 15578 15579 15580 15581 15582 15583 15584 15585 15586 15587 15588 15589 15590 15591 15592 15593 15594 15595 15596 15597 15598 15599 15600 15601 15602 15603 15604 15605 15606 15607 15608 15609 15610 15611 15612 15613 15614 15615 15616 15617 15618 15619 15620 15621 15622 15623 15624 15625 15626 15627 15628 15629 15630 15631 15632 15633 15634 15635 15636 15637 15638 15639 15640 15641 15642 15643 15644 15645 15646 15647 15648 15649 15650 15651 15652 15653 15654 15655 15656 15657 15658 15659 15660 15661 15662 15663 15664 15665 15666 15667 15668 15669 15670 15671 15672 15673 15674 15675 15676 15677 15678 15679 15680 15681 15682 15683 15684 15685 15686 15687 15688 15689 15690 15691 15692 15693 15694 15695 15696 15697 15698 15699 15700 15701 15702 15703 15704 15705 15706 15707 15708 15709 15710 15711 15712 15713 15714 15715 15716 15717 15718 15719 15720 15721 15722 15723 15724 15725 15726 15727 15728 15729 15730 15731 15732 15733 15734 15735 15736 15737 15738 15739 15740 15741 15742 15743 15744 15745 15746 15747 15748 15749 15750 15751 15752 15753 15754 15755 15756 15757 15758 15759 15760 15761 15762 15763 15764 15765 15766 15767 15768 15769 15770 15771 15772 15773 15774 15775 15776 15777 15778 15779 15780 15781 15782 15783 15784 15785 15786 15787 15788 15789 15790 15791 15792 15793 15794 15795 15796 15797 15798 15799 15800 15801 15802 15803 15804 15805 15806 15807 15808 15809 15810 15811 15812 15813 15814 15815 15816 15817 15818 15819 15820 15821 15822 15823 15824 15825 15826 15827 15828 15829 15830 15831 15832 15833 15834 15835 15836 15837 15838 15839 15840 15841 15842 15843 15844 15845 15846 15847 15848 15849 15850 15851 15852 15853 15854 15855 15856 15857 15858 15859 15860 15861 15862 15863 15864 15865 15866 15867 15868 15869 15870 15871 15872 15873 15874 15875 15876 15877 15878 15879 15880 15881 15882 15883 15884 15885 15886 15887 15888 15889 15890 15891 15892 15893 15894 15895 15896 15897 15898 15899 15900 15901 15902 15903 15904 15905 15906 15907 15908 15909 15910 15911 15912 15913 15914 15915 15916 15917 15918 15919 15920 15921 15922 15923 15924 15925 15926 15927 15928 15929 15930 15931 15932 15933 15934 15935 15936 15937 15938 15939 15940 15941 15942 15943 15944 15945 15946 15947 15948 15949 15950 15951 15952 15953 15954 15955 15956 15957 15958 15959 15960 15961 15962 15963 15964 15965 15966 15967 15968 15969 15970 15971 15972 15973 15974 15975 15976 15977 15978 15979 15980 15981 15982 15983 15984 15985 15986 15987 15988 15989 15990 15991 15992 15993 15994 15995 15996 15997 15998 15999 16000 16001 16002 16003 16004 16005 16006 16007 16008 16009 16010 16011 16012 16013 16014 16015 16016 16017 16018 16019 16020 16021 16022 16023 16024 16025 16026 16027 16028 16029 16030 16031 16032 16033 16034 16035 16036 16037 16038 16039 16040 16041 16042 16043 16044 16045 16046 16047 16048 16049 16050 16051 16052 16053 16054 16055 16056 16057 16058 16059 16060 16061 16062 16063 16064 16065 16066 16067 16068 16069 16070 16071 16072 16073 16074 16075 16076 16077 16078 16079 16080 16081 16082 16083 16084 16085 16086 16087 16088 16089 16090 16091 16092 16093 16094 16095 16096 16097 16098 16099 16100 16101 16102 16103 16104 16105 16106 16107 16108 16109 16110 16111 16112 16113 16114 16115 16116 16117 16118 16119 16120 16121 16122 16123 16124 16125 16126 16127 16128 16129 16130 16131 16132 16133 16134 16135 16136 16137 16138 16139 16140 16141 16142 16143 16144 16145 16146 16147 16148 16149 16150 16151 16152 16153 16154 16155 16156 16157 16158 16159 16160 16161 16162 16163 16164 16165 16166 16167 16168 16169 16170 16171 16172 16173 16174 16175 16176 16177 16178 16179 16180 16181 16182 16183 16184 16185 16186 16187 16188 16189 16190 16191 16192 16193 16194 16195 16196 16197 16198 16199 16200 16201 16202 16203 16204 16205 16206 16207 16208 16209 16210 16211 16212 16213 16214 16215 16216 16217 16218 16219 16220 16221 16222 16223 16224 16225 16226 16227 16228 16229 16230 16231 16232 16233 16234 16235 16236 16237 16238 16239 16240 16241 16242 16243 16244 16245 16246 16247 16248 16249 16250 16251 16252 16253 16254 16255 16256 16257 16258 16259 16260 16261 16262 16263 16264 16265 16266 16267 16268 16269 16270 16271 16272 16273 16274 16275 16276 16277 16278 16279 16280 16281 16282 16283 16284 16285 16286 16287 16288 16289 16290 16291 16292 16293 16294 16295 16296 16297 16298 16299 16300 16301 16302 16303 16304 16305 16306 16307 16308 16309 16310 16311 16312 16313 16314 16315 16316 16317 16318 16319 16320 16321 16322 16323 16324 16325 16326 16327 16328 16329 16330 16331 16332 16333 16334 16335 16336 16337 16338 16339 16340 16341 16342 16343 16344 16345 16346 16347 16348 16349 16350 16351 16352 16353 16354 16355 16356 16357 16358 16359 16360 16361 16362 16363 16364 16365 16366 16367 16368 16369 16370 16371 16372 16373 16374 16375 16376 16377 16378 16379 16380 16381 16382 16383 16384 16385 16386 16387 16388 16389 16390 16391 16392 16393 16394 16395 16396 16397 16398 16399 16400 16401 16402 16403 16404 16405 16406 16407 16408 16409 16410 16411 16412 16413 16414 16415 16416 16417 16418 16419 16420 16421 16422 16423 16424 16425 16426 16427 16428 16429 16430 16431 16432 16433 16434 16435 16436 16437 16438 16439 16440 16441 16442 16443 16444 16445 16446 16447 16448 16449 16450 16451 16452 16453 16454 16455 16456 16457 16458 16459 16460 16461 16462 16463 16464 16465 16466 16467 16468 16469 16470 16471 16472 16473 16474 16475 16476 16477 16478 16479 16480 16481 16482 16483 16484 16485 16486 16487 16488 16489 16490 16491 16492 16493 16494 16495 16496 16497 16498 16499 16500 16501 16502 16503 16504 16505 16506 16507 16508 16509 16510 16511 16512 16513 16514 16515 16516 16517 16518 16519 16520 16521 16522 16523 16524 16525 16526 16527 16528 16529 16530 16531 16532 16533 16534 16535 16536 16537 16538 16539 16540 16541 16542 16543 16544 16545 16546 16547 16548 16549 16550 16551 16552 16553 16554 16555 16556 16557 16558 16559 16560 16561 16562 16563 16564 16565 16566 16567 16568 16569 16570 16571 16572 16573 16574 16575 16576 16577 16578 16579 16580 16581 16582 16583 16584 16585 16586 16587 16588 16589 16590 16591 16592 16593 16594 16595 16596 16597 16598 16599 16600 16601 16602 16603 16604 16605 16606 16607 16608 16609 16610 16611 16612 16613 16614 16615 16616 16617 16618 16619 16620 16621 16622 16623 16624 16625 16626 16627 16628 16629 16630 16631 16632 16633 16634 16635 16636 16637 16638 16639 16640 16641 16642 16643 16644 16645 16646 16647 16648 16649 16650 16651 16652 16653 16654 16655 16656 16657 16658 16659 16660 16661 16662 16663 16664 16665 16666 16667 16668 16669 16670 16671 16672 16673 16674 16675 16676 16677 16678 16679 16680 16681 16682 16683 16684 16685 16686 16687 16688 16689 16690 16691 16692 16693 16694 16695 16696 16697 16698 16699 16700 16701 16702 16703 16704 16705 16706 16707 16708 16709 16710 16711 16712 16713 16714 16715 16716 16717 16718 16719 16720 16721 16722 16723 16724 16725 16726 16727 16728 16729 16730 16731 16732 16733 16734 16735 16736 16737 16738 16739 16740 16741 16742 16743 16744 16745 16746 16747 16748 16749 16750 16751 16752 16753 16754 16755 16756 16757 16758 16759 16760 16761 16762 16763 16764 16765 16766 16767 16768 16769 16770 16771 16772 16773 16774 16775 16776 16777 16778 16779 16780 16781 16782 16783 16784 16785 16786 16787 16788 16789 16790 16791 16792 16793 16794 16795 16796 16797 16798 16799 16800 16801 16802 16803 16804 16805 16806 16807 16808 16809 16810 16811 16812 16813 16814 16815 16816 16817 16818 16819 16820 16821 16822 16823 16824 16825 16826 16827 16828 16829 16830 16831 16832 16833 16834 16835 16836 16837 16838 16839 16840 16841 16842 16843 16844 16845 16846 16847 16848 16849 16850 16851 16852 16853 16854 16855 16856 16857 16858 16859 16860 16861 16862 16863 16864 16865 16866 16867 16868 16869 16870 16871 16872 16873 16874 16875 16876 16877 16878 16879 16880 16881 16882 16883 16884 16885 16886 16887 16888 16889 16890 16891 16892 16893 16894 16895 16896 16897 16898 16899 16900 16901 16902 16903 16904 16905 16906 16907 16908 16909 16910 16911 16912 16913 16914 16915 16916 16917 16918 16919 16920 16921 16922 16923 16924 16925 16926 16927 16928 16929 16930 16931 16932 16933 16934 16935 16936 16937 16938 16939 16940 16941 16942 16943 16944 16945 16946 16947 16948 16949 16950 16951 16952 16953 16954 16955 16956 16957 16958 16959 16960 16961 16962 16963 16964 16965 16966 16967 16968 16969 16970 16971 16972 16973 16974 16975 16976 16977 16978 16979 16980 16981 16982 16983 16984 16985 16986 16987 16988 16989 16990 16991 16992 16993 16994 16995 16996 16997 16998 16999 17000 17001 17002 17003 17004 17005 17006 17007 17008 17009 17010 17011 17012 17013 17014 17015 17016 17017 17018 17019 17020 17021 17022 17023 17024 17025 17026 17027 17028 17029 17030 17031 17032 17033 17034 17035 17036 17037 17038 17039 17040 17041 17042 17043 17044 17045 17046 17047 17048 17049 17050 17051 17052 17053 17054 17055 17056 17057 17058 17059 17060 17061 17062 17063 17064 17065 17066 17067 17068 17069 17070 17071 17072 17073 17074 17075 17076 17077 17078 17079 17080 17081 17082 17083 17084 17085 17086 17087 17088 17089 17090 17091 17092 17093 17094 17095 17096 17097 17098 17099 17100 17101 17102 17103 17104 17105 17106 17107 17108 17109 17110 17111 17112 17113 17114 17115 17116 17117 17118 17119 17120 17121 17122 17123 17124 17125 17126 17127 17128 17129 17130 17131 17132 17133 17134 17135 17136 17137 17138 17139 17140 17141 17142 17143 17144 17145 17146 17147 17148 17149 17150 17151 17152 17153 17154 17155 17156 17157 17158 17159 17160 17161 17162 17163 17164 17165 17166 17167 17168 17169 17170 17171 17172 17173 17174 17175 17176 17177 17178 17179 17180 17181 17182 17183 17184 17185 17186 17187 17188 17189 17190 17191 17192 17193 17194 17195 17196 17197 17198 17199 17200 17201 17202 17203 17204 17205 17206 17207 17208 17209 17210 17211 17212 17213 17214 17215 17216 17217 17218 17219 17220 17221 17222 17223 17224 17225 17226 17227 17228 17229 17230 17231 17232 17233 17234 17235 17236 17237 17238 17239 17240 17241 17242 17243 17244 17245 17246 17247 17248 17249 17250 17251 17252 17253 17254 17255 17256 17257 17258 17259 17260 17261 17262 17263 17264 17265 17266 17267 17268 17269 17270 17271 17272 17273 17274 17275 17276 17277 17278 17279 17280 17281 17282 17283 17284 17285 17286 17287 17288 17289 17290 17291 17292 17293 17294 17295 17296 17297 17298 17299 17300 17301 17302 17303 17304 17305 17306 17307 17308 17309 17310 17311 17312 17313 17314 17315 17316 17317 17318 17319 17320 17321 17322 17323 17324 17325 17326 17327 17328 17329 17330 17331 17332 17333 17334 17335 17336 17337 17338 17339 17340 17341 17342 17343 17344 17345 17346 17347 17348 17349 17350 17351 17352 17353 17354 17355 17356 17357 17358 17359 17360 17361 17362 17363 17364 17365 17366 17367 17368 17369 17370 17371 17372 17373 17374 17375 17376 17377 17378 17379 17380 17381 17382 17383 17384 17385 17386 17387 17388 17389 17390 17391 17392 17393 17394 17395 17396 17397 17398 17399 17400 17401 17402 17403 17404 17405 17406 17407 17408 17409 17410 17411 17412 17413 17414 17415 17416 17417 17418 17419 17420 17421 17422 17423 17424 17425 17426 17427 17428 17429 17430 17431 17432 17433 17434 17435 17436 17437 17438 17439 17440 17441 17442 17443 17444 17445 17446 17447 17448 17449 17450 17451 17452 17453 17454 17455 17456 17457 17458 17459 17460 17461 17462 17463 17464 17465 17466 17467 17468 17469 17470 17471 17472 17473 17474 17475 17476 17477 17478 17479 17480 17481 17482 17483 17484 17485 17486 17487 17488 17489 17490 17491 17492 17493 17494 17495 17496 17497 17498 17499 17500 17501 17502 17503 17504 17505 17506 17507 17508 17509 17510 17511 17512 17513 17514 17515 17516 17517 17518 17519 17520 17521 17522 17523 17524 17525 17526 17527 17528 17529 17530 17531 17532 17533 17534 17535 17536 17537 17538 17539 17540 17541 17542 17543 17544 17545 17546 17547 17548 17549 17550 17551 17552 17553 17554 17555 17556 17557 17558 17559 17560 17561 17562 17563 17564 17565 17566 17567 17568 17569 17570 17571 17572 17573 17574 17575 17576 17577 17578 17579 17580 17581 17582 17583 17584 17585 17586 17587 17588 17589 17590 17591 17592 17593 17594 17595 17596 17597 17598 17599 17600 17601 17602 17603 17604 17605 17606 17607 17608 17609 17610 17611 17612 17613 17614 17615 17616 17617 17618 17619 17620 17621 17622 17623 17624 17625 17626 17627 17628 17629 17630 17631 17632 17633 17634 17635 17636 17637 17638 17639 17640 17641 17642 17643 17644 17645 17646 17647 17648 17649 17650 17651 17652 17653 17654 17655 17656 17657 17658 17659 17660 17661 17662 17663 17664 17665 17666 17667 17668 17669 17670 17671 17672 17673 17674 17675 17676 17677 17678 17679 17680 17681 17682 17683 17684 17685 17686 17687 17688 17689 17690 17691 17692 17693 17694 17695 17696 17697 17698 17699 17700 17701 17702 17703 17704 17705 17706 17707 17708 17709 17710 17711 17712 17713 17714 17715 17716 17717 17718 17719 17720 17721 17722 17723 17724 17725 17726 17727 17728 17729 17730 17731 17732 17733 17734 17735 17736 17737 17738 17739 17740 17741 17742 17743 17744 17745 17746 17747 17748 17749 17750 17751 17752 17753 17754 17755 17756 17757 17758 17759 17760 17761 17762 17763 17764 17765 17766 17767 17768 17769 17770 17771 17772 17773 17774 17775 17776 17777 17778 17779 17780 17781 17782 17783 17784 17785 17786 17787 17788 17789 17790 17791 17792 17793 17794 17795 17796 17797 17798 17799 17800 17801 17802 17803 17804 17805 17806 17807 17808 17809 17810 17811 17812 17813 17814 17815 17816 17817 17818 17819 17820 17821 17822 17823 17824 17825 17826 17827 17828 17829 17830 17831 17832 17833 17834 17835 17836 17837 17838 17839 17840 17841 17842 17843 17844 17845 17846 17847 17848 17849 17850 17851 17852 17853 17854 17855 17856 17857 17858 17859 17860 17861 17862 17863 17864 17865 17866 17867 17868 17869 17870 17871 17872 17873 17874 17875 17876 17877 17878 17879 17880 17881 17882 17883 17884 17885 17886 17887 17888 17889 17890 17891 17892 17893 17894 17895 17896 17897 17898 17899 17900 17901 17902 17903 17904 17905 17906 17907 17908 17909 17910 17911 17912 17913 17914 17915 17916 17917 17918 17919 17920 17921 17922 17923 17924 17925 17926 17927 17928 17929 17930 17931 17932 17933 17934 17935 17936 17937 17938 17939 17940 17941 17942 17943 17944 17945 17946 17947 17948 17949 17950 17951 17952 17953 17954 17955 17956 17957 17958 17959 17960 17961 17962 17963 17964 17965 17966 17967 17968 17969 17970 17971 17972 17973 17974 17975 17976 17977 17978 17979 17980 17981 17982 17983 17984 17985 17986 17987 17988 17989 17990 17991 17992 17993 17994 17995 17996 17997 17998 17999 18000 18001 18002 18003 18004 18005 18006 18007 18008 18009 18010 18011 18012 18013 18014 18015 18016 18017 18018 18019 18020 18021 18022 18023 18024 18025 18026 18027 18028 18029 18030 18031 18032 18033 18034 18035 18036 18037 18038 18039 18040 18041 18042 18043 18044 18045 18046 18047 18048 18049 18050 18051 18052 18053 18054 18055 18056 18057 18058 18059 18060 18061 18062 18063 18064 18065 18066 18067 18068 18069 18070 18071 18072 18073 18074 18075 18076 18077 18078 18079 18080 18081 18082 18083 18084 18085 18086 18087 18088 18089 18090 18091 18092 18093 18094 18095 18096 18097 18098 18099 18100 18101 18102 18103 18104 18105 18106 18107 18108 18109 18110 18111 18112 18113 18114 18115 18116 18117 18118 18119 18120 18121 18122 18123 18124 18125 18126 18127 18128 18129 18130 18131 18132 18133 18134 18135 18136 18137 18138 18139 18140 18141 18142 18143 18144 18145 18146 18147 18148 18149 18150 18151 18152 18153 18154 18155 18156 18157 18158 18159 18160 18161 18162 18163 18164 18165 18166 18167 18168 18169 18170 18171 18172 18173 18174 18175 18176 18177 18178 18179 18180 18181 18182 18183 18184 18185 18186 18187 18188 18189 18190 18191 18192 18193 18194 18195 18196 18197 18198 18199 18200 18201 18202 18203 18204 18205 18206 18207 18208 18209 18210 18211 18212 18213 18214 18215 18216 18217 18218 18219 18220 18221 18222 18223 18224 18225 18226 18227 18228 18229 18230 18231 18232 18233 18234 18235 18236 18237 18238 18239 18240 18241 18242 18243 18244 18245 18246 18247 18248 18249 18250 18251 18252 18253 18254 18255 18256 18257 18258 18259 18260 18261 18262 18263 18264 18265 18266 18267 18268 18269 18270 18271 18272 18273 18274 18275 18276 18277 18278 18279 18280 18281 18282 18283 18284 18285 18286 18287 18288 18289 18290 18291 18292 18293 18294 18295 18296 18297 18298 18299 18300 18301 18302 18303 18304 18305 18306 18307 18308 18309 18310 18311 18312 18313 18314 18315 18316 18317 18318 18319 18320 18321 18322 18323 18324 18325 18326 18327 18328 18329 18330 18331 18332 18333 18334 18335 18336 18337 18338 18339 18340 18341 18342 18343 18344 18345 18346 18347 18348 18349 18350 18351 18352 18353 18354 18355 18356 18357 18358 18359 18360 18361 18362 18363 18364 18365 18366 18367 18368 18369 18370 18371 18372 18373 18374 18375 18376 18377 18378 18379 18380 18381 18382 18383 18384 18385 18386 18387 18388 18389 18390 18391 18392 18393 18394 18395 18396 18397 18398 18399 18400 18401 18402 18403 18404 18405 18406 18407 18408 18409 18410 18411 18412 18413 18414 18415 18416 18417 18418 18419 18420 18421 18422 18423 18424 18425 18426 18427 18428 18429 18430 18431 18432 18433 18434 18435 18436 18437 18438 18439 18440 18441 18442 18443 18444 18445 18446 18447 18448 18449 18450 18451 18452 18453 18454 18455 18456 18457 18458 18459 18460 18461 18462 18463 18464 18465 18466 18467 18468 18469 18470 18471 18472 18473 18474 18475 18476 18477 18478 18479 18480 18481 18482 18483 18484 18485 18486 18487 18488 18489 18490 18491 18492 18493 18494 18495 18496 18497 18498 18499 18500 18501 18502 18503 18504 18505 18506 18507 18508 18509 18510 18511 18512 18513 18514 18515 18516 18517 18518 18519 18520 18521 18522 18523 18524 18525 18526 18527 18528 18529 18530 18531 18532 18533 18534 18535 18536 18537 18538 18539 18540 18541 18542 18543 18544 18545 18546 18547 18548 18549 18550 18551 18552 18553 18554 18555 18556 18557 18558 18559 18560 18561 18562 18563 18564 18565 18566 18567 18568 18569 18570 18571 18572 18573 18574 18575 18576 18577 18578 18579 18580 18581 18582 18583 18584 18585 18586 18587 18588 18589 18590 18591 18592 18593 18594 18595 18596 18597 18598 18599 18600 18601 18602 18603 18604 18605 18606 18607 18608 18609 18610 18611 18612 18613 18614 18615 18616 18617 18618 18619 18620 18621 18622 18623 18624 18625 18626 18627 18628 18629 18630 18631 18632 18633 18634 18635 18636 18637 18638 18639 18640 18641 18642 18643 18644 18645 18646 18647 18648 18649 18650 18651 18652 18653 18654 18655 18656 18657 18658 18659 18660 18661 18662 18663 18664 18665 18666 18667 18668 18669 18670 18671 18672 18673 18674 18675 18676 18677 18678 18679 18680 18681 18682 18683 18684 18685 18686 18687 18688 18689 18690 18691 18692 18693 18694 18695 18696 18697 18698 18699 18700 18701 18702 18703 18704 18705 18706 18707 18708 18709 18710 18711 18712 18713 18714 18715 18716 18717 18718 18719 18720 18721 18722 18723 18724 18725 18726 18727 18728 18729 18730 18731 18732 18733 18734 18735 18736 18737 18738 18739 18740 18741 18742 18743 18744 18745 18746 18747 18748 18749 18750 18751 18752 18753 18754 18755 18756 18757 18758 18759 18760 18761 18762 18763 18764 18765 18766 18767 18768 18769 18770 18771 18772 18773 18774 18775 18776 18777 18778 18779 18780 18781 18782 18783 18784 18785 18786 18787 18788 18789 18790 18791 18792 18793 18794 18795 18796 18797 18798 18799 18800 18801 18802 18803 18804 18805 18806 18807 18808 18809 18810 18811 18812 18813 18814 18815 18816 18817 18818 18819 18820 18821 18822 18823 18824 18825 18826 18827 18828 18829 18830 18831 18832 18833 18834 18835 18836 18837 18838 18839 18840 18841 18842 18843 18844 18845 18846 18847 18848 18849 18850 18851 18852 18853 18854 18855 18856 18857 18858 18859 18860 18861 18862 18863 18864 18865 18866 18867 18868 18869 18870 18871 18872 18873 18874 18875 18876 18877 18878 18879 18880 18881 18882 18883 18884 18885 18886 18887 18888 18889 18890 18891 18892 18893 18894 18895 18896 18897 18898 18899 18900 18901 18902 18903 18904 18905 18906 18907 18908 18909 18910 18911 18912 18913 18914 18915 18916 18917 18918 18919 18920 18921 18922 18923 18924 18925 18926 18927 18928 18929 18930 18931 18932 18933 18934 18935 18936 18937 18938 18939 18940 18941 18942 18943 18944 18945 18946 18947 18948 18949 18950 18951 18952 18953 18954 18955 18956 18957 18958 18959 18960 18961 18962 18963 18964 18965 18966 18967 18968 18969 18970 18971 18972 18973 18974 18975 18976 18977 18978 18979 18980 18981 18982 18983 18984 18985 18986 18987 18988 18989 18990 18991 18992 18993 18994 18995 18996 18997 18998 18999 19000 19001 19002 19003 19004 19005 19006 19007 19008 19009 19010 19011 19012 19013 19014 19015 19016 19017 19018 19019 19020 19021 19022 19023 19024 19025 19026 19027 19028 19029 19030 19031 19032 19033 19034 19035 19036 19037 19038 19039 19040 19041 19042 19043 19044 19045 19046 19047 19048 19049 19050 19051 19052 19053 19054 19055 19056 19057 19058 19059 19060 19061 19062 19063 19064 19065 19066 19067 19068 19069 19070 19071 19072 19073 19074 19075 19076 19077 19078 19079 19080 19081 19082 19083 19084 19085 19086 19087 19088 19089 19090 19091 19092 19093 19094 19095 19096 19097 19098 19099 19100 19101 19102 19103 19104 19105 19106 19107 19108 19109 19110 19111 19112 19113 19114 19115 19116 19117 19118 19119 19120 19121 19122 19123 19124 19125 19126 19127 19128 19129 19130 19131 19132 19133 19134 19135 19136 19137 19138 19139 19140 19141 19142 19143 19144 19145 19146 19147 19148 19149 19150 19151 19152 19153 19154 19155 19156 19157 19158 19159 19160 19161 19162 19163 19164 19165 19166 19167 19168 19169 19170 19171 19172 19173 19174 19175 19176 19177 19178 19179 19180 19181 19182 19183 19184 19185 19186 19187 19188 19189 19190 19191 19192 19193 19194 19195 19196 19197 19198 19199 19200 19201 19202 19203 19204 19205 19206 19207 19208 19209 19210 19211 19212 19213 19214 19215 19216 19217 19218 19219 19220 19221 19222 19223 19224 19225 19226 19227 19228 19229 19230 19231 19232 19233 19234 19235 19236 19237 19238 19239 19240 19241 19242 19243 19244 19245 19246 19247 19248 19249 19250 19251 19252 19253 19254 19255 19256 19257 19258 19259 19260 19261 19262 19263 19264 19265 19266 19267 19268 19269 19270 19271 19272 19273 19274 19275 19276 19277 19278 19279 19280 19281 19282 19283 19284 19285 19286 19287 19288 19289 19290 19291 19292 19293 19294 19295 19296 19297 19298 19299 19300 19301 19302 19303 19304 19305 19306 19307 19308 19309 19310 19311 19312 19313 19314 19315 19316 19317 19318 19319 19320 19321 19322 19323 19324 19325 19326 19327 19328 19329 19330 19331 19332 19333 19334 19335 19336 19337 19338 19339 19340 19341 19342 19343 19344 19345 19346 19347 19348 19349 19350 19351 19352 19353 19354 19355 19356 19357 19358 19359 19360 19361 19362 19363 19364 19365 19366 19367 19368 19369 19370 19371 19372 19373 19374 19375 19376 19377 19378 19379 19380 19381 19382 19383 19384 19385 19386 19387 19388 19389 19390 19391 19392 19393 19394 19395 19396 19397 19398 19399 19400 19401 19402 19403 19404 19405 19406 19407 19408 19409 19410 19411 19412 19413 19414 19415 19416 19417 19418 19419 19420 19421 19422 19423 19424 19425 19426 19427 19428 19429 19430 19431 19432 19433 19434 19435 19436 19437 19438 19439 19440 19441 19442 19443 19444 19445 19446 19447 19448 19449 19450 19451 19452 19453 19454 19455 19456 19457 19458 19459 19460 19461 19462 19463 19464 19465 19466 19467 19468 19469 19470 19471 19472 19473 19474 19475 19476 19477 19478 19479 19480 19481 19482 19483 19484 19485 19486 19487 19488 19489 19490 19491 19492 19493 19494 19495 19496 19497 19498 19499 19500 19501 19502 19503 19504 19505 19506 19507 19508 19509 19510 19511 19512 19513 19514 19515 19516 19517 19518 19519 19520 19521 19522 19523 19524 19525 19526 19527 19528 19529 19530 19531 19532 19533 19534 19535 19536 19537 19538 19539 19540 19541 19542 19543 19544 19545 19546 19547 19548 19549 19550 19551 19552 19553 19554 19555 19556 19557 19558 19559 19560 19561 19562 19563 19564 19565 19566 19567 19568 19569 19570 19571 19572 19573 19574 19575 19576 19577 19578 19579 19580 19581 19582 19583 19584 19585 19586 19587 19588 19589 19590 19591 19592 19593 19594 19595 19596 19597 19598 19599 19600 19601 19602 19603 19604 19605 19606 19607 19608 19609 19610 19611 19612 19613 19614 19615 19616 19617 19618 19619 19620 19621 19622 19623 19624 19625 19626 19627 19628 19629 19630 19631 19632 19633 19634 19635 19636 19637 19638 19639 19640 19641 19642 19643 19644 19645 19646 19647 19648 19649 19650 19651 19652 19653 19654 19655 19656 19657 19658 19659 19660 19661 19662 19663 19664 19665 19666 19667 19668 19669 19670 19671 19672 19673 19674 19675 19676 19677 19678 19679 19680 19681 19682 19683 19684 19685 19686 19687 19688 19689 19690 19691 19692 19693 19694 19695 19696 19697 19698 19699 19700 19701 19702 19703 19704 19705 19706 19707 19708 19709 19710 19711 19712 19713 19714 19715 19716 19717 19718 19719 19720 19721 19722 19723 19724 19725 19726 19727 19728 19729 19730 19731 19732 19733 19734 19735 19736 19737 19738 19739 19740 19741 19742 19743 19744 19745 19746 19747 19748 19749 19750 19751 19752 19753 19754 19755 19756 19757 19758 19759 19760 19761 19762 19763 19764 19765 19766 19767 19768 19769 19770 19771 19772 19773 19774 19775 19776 19777 19778 19779 19780 19781 19782 19783 19784 19785 19786 19787 19788 19789 19790 19791 19792 19793 19794 19795 19796 19797 19798 19799 19800 19801 19802 19803 19804 19805 19806 19807 19808 19809 19810 19811 19812 19813 19814 19815 19816 19817 19818 19819 19820 19821 19822 19823 19824 19825 19826 19827 19828 19829 19830 19831 19832 19833 19834 19835 19836 19837 19838 19839 19840 19841 19842 19843 19844 19845 19846 19847 19848 19849 19850 19851 19852 19853 19854 19855 19856 19857 19858 19859 19860 19861 19862 19863 19864 19865 19866 19867 19868 19869 19870 19871 19872 19873 19874 19875 19876 19877 19878 19879 19880 19881 19882 19883 19884 19885 19886 19887 19888 19889 19890 19891 19892 19893 19894 19895 19896 19897 19898 19899 19900 19901 19902 19903 19904 19905 19906 19907 19908 19909 19910 19911 19912 19913 19914 19915 19916 19917 19918 19919 19920 19921 19922 19923 19924 19925 19926 19927 19928 19929 19930 19931 19932 19933 19934 19935 19936 19937 19938 19939 19940 19941 19942 19943 19944 19945 19946 19947 19948 19949 19950 19951 19952 19953 19954 19955 19956 19957 19958 19959 19960 19961 19962 19963 19964 19965 19966 19967 19968 19969 19970 19971 19972 19973 19974 19975 19976 19977 19978 19979 19980 19981 19982 19983 19984 19985 19986 19987 19988 19989 19990 19991 19992 19993 19994 19995 19996 19997 19998 19999 20000 20001 20002 20003 20004 20005 20006 20007 20008 20009 20010 20011 20012 20013 20014 20015 20016 20017 20018 20019 20020 20021 20022 20023 20024 20025 20026 20027 20028 20029 20030 20031 20032 20033 20034 20035 20036 20037 20038 20039 20040 20041 20042 20043 20044 20045 20046 20047 20048 20049 20050 20051 20052 20053 20054 20055 20056 20057 20058 20059 20060 20061 20062 20063 20064 20065 20066 20067 20068 20069 20070 20071 20072 20073 20074 20075 20076 20077 20078 20079 20080 20081 20082 20083 20084 20085 20086 20087 20088 20089 20090 20091 20092 20093 20094 20095 20096 20097 20098 20099 20100 20101 20102 20103 20104 20105 20106 20107 20108 20109 20110 20111 20112 20113 20114 20115 20116 20117 20118 20119 20120 20121 20122 20123 20124 20125 20126 20127 20128 20129 20130 20131 20132 20133 20134 20135 20136 20137 20138 20139 20140 20141 20142 20143 20144 20145 20146 20147 20148 20149 20150 20151 20152 20153 20154 20155 20156 20157 20158 20159 20160 20161 20162 20163 20164 20165 20166 20167 20168 20169 20170 20171 20172 20173 20174 20175 20176 20177 20178 20179 20180 20181 20182 20183 20184 20185 20186 20187 20188 20189 20190 20191 20192 20193 20194 20195 20196 20197 20198 20199 20200 20201 20202 20203 20204 20205 20206 20207 20208 20209 20210 20211 20212 20213 20214 20215 20216 20217 20218 20219 20220 20221 20222 20223 20224 20225 20226 20227 20228 20229 20230 20231 20232 20233 20234 20235 20236 20237 20238 20239 20240 20241 20242 20243 20244 20245 20246 20247 20248 20249 20250 20251 20252 20253 20254 20255 20256 20257 20258 20259 20260 20261 20262 20263 20264 20265 20266 20267 20268 20269 20270 20271 20272 20273 20274 20275 20276 20277 20278 20279 20280 20281 20282 20283 20284 20285 20286 20287 20288 20289 20290 20291 20292 20293 20294 20295 20296 20297 20298 20299 20300 20301 20302 20303 20304 20305 20306 20307 20308 20309 20310 20311 20312 20313 20314 20315 20316 20317 20318 20319 20320 20321 20322 20323 20324 20325 20326 20327 20328 20329 20330 20331 20332 20333 20334 20335 20336 20337 20338 20339 20340 20341 20342 20343 20344 20345 20346 20347 20348 20349 20350 20351 20352 20353 20354 20355 20356 20357 20358 20359 20360 20361 20362 20363 20364 20365 20366 20367 20368 20369 20370 20371 20372 20373 20374 20375 20376 20377 20378 20379 20380 20381 20382 20383 20384 20385 20386 20387 20388 20389 20390 20391 20392 20393 20394 20395 20396 20397 20398 20399 20400 20401 20402 20403 20404 20405 20406 20407 20408 20409 20410 20411 20412 20413 20414 20415 20416 20417 20418 20419 20420 20421 20422 20423 20424 20425 20426 20427 20428 20429 20430 20431 20432 20433 20434 20435 20436 20437 20438 20439 20440 20441 20442 20443 20444 20445 20446 20447 20448 20449 20450 20451 20452 20453 20454 20455 20456 20457 20458 20459 20460 20461 20462 20463 20464 20465 20466 20467 20468 20469 20470 20471 20472 20473 20474 20475 20476 20477 20478 20479 20480 20481 20482 20483 20484 20485 20486 20487 20488 20489 20490 20491 20492 20493 20494 20495 20496 20497 20498 20499 20500 20501 20502 20503 20504 20505 20506 20507 20508 20509 20510 20511 20512 20513 20514 20515 20516 20517 20518 20519 20520 20521 20522 20523 20524 20525 20526 20527 20528 20529 20530 20531 20532 20533 20534 20535 20536 20537 20538 20539 20540 20541 20542 20543 20544 20545 20546 20547 20548 20549 20550 20551 20552 20553 20554 20555 20556 20557 20558 20559 20560 20561 20562 20563 20564 20565 20566 20567 20568 20569 20570 20571 20572 20573 20574 20575 20576 20577 20578 20579 20580 20581 20582 20583 20584 20585 20586 20587 20588 20589 20590 20591 20592 20593 20594 20595 20596 20597 20598 20599 20600 20601 20602 20603 20604 20605 20606 20607 20608 20609 20610 20611 20612 20613 20614 20615 20616 20617 20618 20619 20620 20621 20622 20623 20624 20625 20626 20627 20628 20629 20630 20631 20632 20633 20634 20635 20636 20637 20638 20639 20640 20641 20642 20643 20644 20645 20646 20647 20648 20649 20650 20651 20652 20653 20654 20655 20656 20657 20658 20659 20660 20661 20662 20663 20664 20665 20666 20667 20668 20669 20670 20671 20672 20673 20674 20675 20676 20677 20678 20679 20680 20681 20682 20683 20684 20685 20686 20687 20688 20689 20690 20691 20692 20693 20694 20695 20696 20697 20698 20699 20700 20701 20702 20703 20704 20705 20706 20707 20708 20709 20710 20711 20712 20713 20714 20715 20716 20717 20718 20719 20720 20721 20722 20723 20724 20725 20726 20727 20728 20729 20730 20731 20732 20733 20734 20735 20736 20737 20738 20739 20740 20741 20742 20743 20744 20745 20746 20747 20748 20749 20750 20751 20752 20753 20754 20755 20756 20757 20758 20759 20760 20761 20762 20763 20764 20765 20766 20767 20768 20769 20770 20771 20772 20773 20774 20775 20776 20777 20778 20779 20780 20781 20782 20783 20784 20785 20786 20787 20788 20789 20790 20791 20792 20793 20794 20795 20796 20797 20798 20799 20800 20801 20802 20803 20804 20805 20806 20807 20808 20809 20810 20811 20812 20813 20814 20815 20816 20817 20818 20819 20820 20821 20822 20823 20824 20825 20826 20827 20828 20829 20830 20831 20832 20833 20834 20835 20836 20837 20838 20839 20840 20841 20842 20843 20844 20845 20846 20847 20848 20849 20850 20851 20852 20853 20854 20855 20856 20857 20858 20859 20860 20861 20862 20863 20864 20865 20866 20867 20868 20869 20870 20871 20872 20873 20874 20875 20876 20877 20878 20879 20880 20881 20882 20883 20884 20885 20886 20887 20888 20889 20890 20891 20892 20893 20894 20895 20896 20897 20898 20899 20900 20901 20902 20903 20904 20905 20906 20907 20908 20909 20910 20911 20912 20913 20914 20915 20916 20917 20918 20919 20920 20921 20922 20923 20924 20925 20926 20927 20928 20929 20930 20931 20932 20933 20934 20935 20936 20937 20938 20939 20940 20941 20942 20943 20944 20945 20946 20947 20948 20949 20950 20951 20952 20953 20954 20955 20956 20957 20958 20959 20960 20961 20962 20963 20964 20965 20966 20967 20968 20969 20970 20971 20972 20973 20974 20975 20976 20977 20978 20979 20980 20981 20982 20983 20984 20985 20986 20987 20988 20989 20990 20991 20992 20993 20994 20995 20996 20997 20998 20999 21000 21001 21002 21003 21004 21005 21006 21007 21008 21009 21010 21011 21012 21013 21014 21015 21016 21017 21018 21019 21020 21021 21022 21023 21024 21025 21026 21027 21028 21029 21030 21031 21032 21033 21034 21035 21036 21037 21038 21039 21040 21041 21042 21043 21044 21045 21046 21047 21048 21049 21050 21051 21052 21053 21054 21055 21056 21057 21058 21059 21060 21061 21062 21063 21064 21065 21066 21067 21068 21069 21070 21071 21072 21073 21074 21075 21076 21077 21078 21079 21080 21081 21082 21083 21084 21085 21086 21087 21088 21089 21090 21091 21092 21093 21094 21095 21096 21097 21098 21099 21100 21101 21102 21103 21104 21105 21106 21107 21108 21109 21110 21111 21112 21113 21114 21115 21116 21117 21118 21119 21120 21121 21122 21123 21124 21125 21126 21127 21128 21129 21130 21131 21132 21133 21134 21135 21136 21137 21138 21139 21140 21141 21142 21143 21144 21145 21146 21147 21148 21149 21150 21151 21152 21153 21154 21155 21156 21157 21158 21159 21160 21161 21162 21163 21164 21165 21166 21167 21168 21169 21170 21171 21172 21173 21174 21175 21176 21177 21178 21179 21180 21181 21182 21183 21184 21185 21186 21187 21188 21189 21190 21191 21192 21193 21194 21195 21196 21197 21198 21199 21200 21201 21202 21203 21204 21205 21206 21207 21208 21209 21210 21211 21212 21213 21214 21215 21216 21217 21218 21219 21220 21221 21222 21223 21224 21225 21226 21227 21228 21229 21230 21231 21232 21233 21234 21235 21236 21237 21238 21239 21240 21241 21242 21243 21244 21245 21246 21247 21248 21249 21250 21251 21252 21253 21254 21255 21256 21257 21258 21259 21260 21261 21262 21263 21264 21265 21266 21267 21268 21269 21270 21271 21272 21273 21274 21275 21276 21277 21278 21279 21280 21281 21282 21283 21284 21285 21286 21287 21288 21289 21290 21291 21292 21293 21294 21295 21296 21297 21298 21299 21300 21301 21302 21303 21304 21305 21306 21307 21308 21309 21310 21311 21312 21313 21314 21315 21316 21317 21318 21319 21320 21321 21322 21323 21324 21325 21326 21327 21328 21329 21330 21331 21332 21333 21334 21335 21336 21337 21338 21339 21340 21341 21342 21343 21344 21345 21346 21347 21348 21349 21350 21351 21352 21353 21354 21355 21356 21357 21358 21359 21360 21361 21362 21363 21364 21365 21366 21367 21368 21369 21370 21371 21372 21373 21374 21375 21376 21377 21378 21379 21380 21381 21382 21383 21384 21385 21386 21387 21388 21389 21390 21391 21392 21393 21394 21395 21396 21397 21398 21399 21400 21401 21402 21403 21404 21405 21406 21407 21408 21409 21410 21411 21412 21413 21414 21415 21416 21417 21418 21419 21420 21421 21422 21423 21424 21425 21426 21427 21428 21429 21430 21431 21432 21433 21434 21435 21436 21437 21438 21439 21440 21441 21442 21443 21444 21445 21446 21447 21448 21449 21450 21451 21452 21453 21454 21455 21456 21457 21458 21459 21460 21461 21462 21463 21464 21465 21466 21467 21468 21469 21470 21471 21472 21473 21474 21475 21476 21477 21478 21479 21480 21481 21482 21483 21484 21485 21486 21487 21488 21489 21490 21491 21492 21493 21494 21495 21496 21497 21498 21499 21500 21501 21502 21503 21504 21505 21506 21507 21508 21509 21510 21511 21512 21513 21514 21515 21516 21517 21518 21519 21520 21521 21522 21523 21524 21525 21526 21527 21528 21529 21530 21531 21532 21533 21534 21535 21536 21537 21538 21539 21540 21541 21542 21543 21544 21545 21546 21547 21548 21549 21550 21551 21552 21553 21554 21555 21556 21557 21558 21559 21560 21561 21562 21563 21564 21565 21566 21567 21568 21569 21570 21571 21572 21573 21574 21575 21576 21577 21578 21579 21580 21581 21582 21583 21584 21585 21586 21587 21588 21589 21590 21591 21592 21593 21594 21595 21596 21597 21598 21599 21600 21601 21602 21603 21604 21605 21606 21607 21608 21609 21610 21611 21612 21613 21614 21615 21616 21617 21618 21619 21620 21621 21622 21623 21624 21625 21626 21627 21628 21629 21630 21631 21632 21633 21634 21635 21636 21637 21638 21639 21640 21641 21642 21643 21644 21645 21646 21647 21648 21649 21650 21651 21652 21653 21654 21655 21656 21657 21658 21659 21660 21661 21662 21663 21664 21665 21666 21667 21668 21669 21670 21671 21672 21673 21674 21675 21676 21677 21678 21679 21680 21681 21682 21683 21684 21685 21686 21687 21688 21689 21690 21691 21692 21693 21694 21695 21696 21697 21698 21699 21700 21701 21702 21703 21704 21705 21706 21707 21708 21709 21710 21711 21712 21713 21714 21715 21716 21717 21718 21719 21720 21721 21722 21723 21724 21725 21726 21727 21728 21729 21730 21731 21732 21733 21734 21735 21736 21737 21738 21739 21740 21741 21742 21743 21744 21745 21746 21747 21748 21749 21750 21751 21752 21753 21754 21755 21756 21757 21758 21759 21760 21761 21762 21763 21764 21765 21766 21767 21768 21769 21770 21771 21772 21773 21774 21775 21776 21777 21778 21779 21780 21781 21782 21783 21784 21785 21786 21787 21788 21789 21790 21791 21792 21793 21794 21795 21796 21797 21798 21799 21800 21801 21802 21803 21804 21805 21806 21807 21808 21809 21810 21811 21812 21813 21814 21815 21816 21817 21818 21819 21820 21821 21822 21823 21824 21825 21826 21827 21828 21829 21830 21831 21832 21833 21834 21835 21836 21837 21838 21839 21840 21841 21842 21843 21844 21845 21846 21847 21848 21849 21850 21851 21852 21853 21854 21855 21856 21857 21858 21859 21860 21861 21862 21863 21864 21865 21866 21867 21868 21869 21870 21871 21872 21873 21874 21875 21876 21877 21878 21879 21880 21881 21882 21883 21884 21885 21886 21887 21888 21889 21890 21891 21892 21893 21894 21895 21896 21897 21898 21899 21900 21901 21902 21903 21904 21905 21906 21907 21908 21909 21910 21911 21912 21913 21914 21915 21916 21917 21918 21919 21920 21921 21922 21923 21924 21925 21926 21927 21928 21929 21930 21931 21932 21933 21934 21935 21936 21937 21938 21939 21940 21941 21942 21943 21944 21945 21946 21947 21948 21949 21950 21951 21952 21953 21954 21955 21956 21957 21958 21959 21960 21961 21962 21963 21964 21965 21966 21967 21968 21969 21970 21971 21972 21973 21974 21975 21976 21977 21978 21979 21980 21981 21982 21983 21984 21985 21986 21987 21988 21989 21990 21991 21992 21993 21994 21995 21996 21997 21998 21999 22000 22001 22002 22003 22004 22005 22006 22007 22008 22009 22010 22011 22012 22013 22014 22015 22016 22017 22018 22019 22020 22021 22022 22023 22024 22025 22026 22027 22028 22029 22030 22031 22032 22033 22034 22035 22036 22037 22038 22039 22040 22041 22042 22043 22044 22045 22046 22047 22048 22049 22050 22051 22052 22053 22054 22055 22056 22057 22058 22059 22060 22061 22062 22063 22064 22065 22066 22067 22068 22069 22070 22071 22072 22073 22074 22075 22076 22077 22078 22079 22080 22081 22082 22083 22084 22085 22086 22087 22088 22089 22090 22091 22092 22093 22094 22095 22096 22097 22098 22099 22100 22101 22102 22103 22104 22105 22106 22107 22108 22109 22110 22111 22112 22113 22114 22115 22116 22117 22118 22119 22120 22121 22122 22123 22124 22125 22126 22127 22128 22129 22130 22131 22132 22133 22134 22135 22136 22137 22138 22139 22140 22141 22142 22143 22144 22145 22146 22147 22148 22149 22150 22151 22152 22153 22154 22155 22156 22157 22158 22159 22160 22161 22162 22163 22164 22165 22166 22167 22168 22169 22170 22171 22172 22173 22174 22175 22176 22177 22178 22179 22180 22181 22182 22183 22184 22185 22186 22187 22188 22189 22190 22191 22192 22193 22194 22195 22196 22197 22198 22199 22200 22201 22202 22203 22204 22205 22206 22207 22208 22209 22210 22211 22212 22213 22214 22215 22216 22217 22218 22219 22220 22221 22222 22223 22224 22225 22226 22227 22228 22229 22230 22231 22232 22233 22234 22235 22236 22237 22238 22239 22240 22241 22242 22243 22244 22245 22246 22247 22248 22249 22250 22251 22252 22253 22254 22255 22256 22257 22258 22259 22260 22261 22262 22263 22264 22265 22266 22267 22268 22269 22270 22271 22272 22273 22274 22275 22276 22277 22278 22279 22280 22281 22282 22283 22284 22285 22286 22287 22288 22289 22290 22291 22292 22293 22294 22295 22296 22297 22298 22299 22300 22301 22302 22303 22304 22305 22306 22307 22308 22309 22310 22311 22312 22313 22314 22315 22316 22317 22318 22319 22320 22321 22322 22323 22324 22325 22326 22327 22328 22329 22330 22331 22332 22333 22334 22335 22336 22337 22338 22339 22340 22341 22342 22343 22344 22345 22346 22347 22348 22349 22350 22351 22352 22353 22354 22355 22356 22357 22358 22359 22360 22361 22362 22363 22364 22365 22366 22367 22368 22369 22370 22371 22372 22373 22374 22375 22376 22377 22378 22379 22380 22381 22382 22383 22384 22385 22386 22387 22388 22389 22390 22391 22392 22393 22394 22395 22396 22397 22398 22399 22400 22401 22402 22403 22404 22405 22406 22407 22408 22409 22410 22411 22412 22413 22414 22415 22416 22417 22418 22419 22420 22421 22422 22423 22424 22425 22426 22427 22428 22429 22430 22431 22432 22433 22434 22435 22436 22437 22438 22439 22440 22441 22442 22443 22444 22445 22446 22447 22448 22449 22450 22451 22452 22453 22454 22455 22456 22457 22458 22459 22460 22461 22462 22463 22464 22465 22466 22467 22468 22469 22470 22471 22472 22473 22474 22475 22476 22477 22478 22479 22480 22481 22482 22483 22484 22485 22486 22487 22488 22489 22490 22491 22492 22493 22494 22495 22496 22497 22498 22499 22500 22501 22502 22503 22504 22505 22506 22507 22508 22509 22510 22511 22512 22513 22514 22515 22516 22517 22518 22519 22520 22521 22522 22523 22524 22525 22526 22527 22528 22529 22530 22531 22532 22533 22534 22535 22536 22537 22538 22539 22540 22541 22542 22543 22544 22545 22546 22547 22548 22549 22550 22551 22552 22553 22554 22555 22556 22557 22558 22559 22560 22561 22562 22563 22564 22565 22566 22567 22568 22569 22570 22571 22572 22573 22574 22575 22576 22577 22578 22579 22580 22581 22582 22583 22584 22585 22586 22587 22588 22589 22590 22591 22592 22593 22594 22595 22596 22597 22598 22599 22600 22601 22602 22603 22604 22605 22606 22607 22608 22609 22610 22611 22612 22613 22614 22615 22616 22617 22618 22619 22620 22621 22622 22623 22624 22625 22626 22627 22628 22629 22630 22631 22632 22633 22634 22635 22636 22637 22638 22639 22640 22641 22642 22643 22644 22645 22646 22647 22648 22649 22650 22651 22652 22653 22654 22655 22656 22657 22658 22659 22660 22661 22662 22663 22664 22665 22666 22667 22668 22669 22670 22671 22672 22673 22674 22675 22676 22677 22678 22679 22680 22681 22682 22683 22684 22685 22686 22687 22688 22689 22690 22691 22692 22693 22694 22695 22696 22697 22698 22699 22700 22701 22702 22703 22704 22705 22706 22707 22708 22709 22710 22711 22712 22713 22714 22715 22716 22717 22718 22719 22720 22721 22722 22723 22724 22725 22726 22727 22728 22729 22730 22731 22732 22733 22734 22735 22736 22737 22738 22739 22740 22741 22742 22743 22744 22745 22746 22747 22748 22749 22750 22751 22752 22753 22754 22755 22756 22757 22758 22759 22760 22761 22762 22763 22764 22765 22766 22767 22768 22769 22770 22771 22772 22773 22774 22775 22776 22777 22778 22779 22780 22781 22782 22783 22784 22785 22786 22787 22788 22789 22790 22791 22792 22793 22794 22795 22796 22797 22798 22799 22800 22801 22802 22803 22804 22805 22806 22807 22808 22809 22810 22811 22812 22813 22814 22815 22816 22817 22818 22819 22820 22821 22822 22823 22824 22825 22826 22827 22828 22829 22830 22831 22832 22833 22834 22835 22836 22837 22838 22839 22840 22841 22842 22843 22844 22845 22846 22847 22848 22849 22850 22851 22852 22853 22854 22855 22856 22857 22858 22859 22860 22861 22862 22863 22864 22865 22866 22867 22868 22869 22870 22871 22872 22873 22874 22875 22876 22877 22878 22879 22880 22881 22882 22883 22884 22885 22886 22887 22888 22889 22890 22891 22892 22893 22894 22895 22896 22897 22898 22899 22900 22901 22902 22903 22904 22905 22906 22907 22908 22909 22910 22911 22912 22913 22914 22915 22916 22917 22918 22919 22920 22921 22922 22923 22924 22925 22926 22927 22928 22929 22930 22931 22932 22933 22934 22935 22936 22937 22938 22939 22940 22941 22942 22943 22944 22945 22946 22947 22948 22949 22950 22951 22952 22953 22954 22955 22956 22957 22958 22959 22960 22961 22962 22963 22964 22965 22966 22967 22968 22969 22970 22971 22972 22973 22974 22975 22976 22977 22978 22979 22980 22981 22982 22983 22984 22985 22986 22987 22988 22989 22990 22991 22992 22993 22994 22995 22996 22997 22998 22999 23000 23001 23002 23003 23004 23005 23006 23007 23008 23009 23010 23011 23012 23013 23014 23015 23016 23017 23018 23019 23020 23021 23022 23023 23024 23025 23026 23027 23028 23029 23030 23031 23032 23033 23034 23035 23036 23037 23038 23039 23040 23041 23042 23043 23044 23045 23046 23047 23048 23049 23050 23051 23052 23053 23054 23055 23056 23057 23058 23059 23060 23061 23062 23063 23064 23065 23066 23067 23068 23069 23070 23071 23072 23073 23074 23075 23076 23077 23078 23079 23080 23081 23082 23083 23084 23085 23086 23087 23088 23089 23090 23091 23092 23093 23094 23095 23096 23097 23098 23099 23100 23101 23102 23103 23104 23105 23106 23107 23108 23109 23110 23111 23112 23113 23114 23115 23116 23117 23118 23119 23120 23121 23122 23123 23124 23125 23126 23127 23128 23129 23130 23131 23132 23133 23134 23135 23136 23137 23138 23139 23140 23141 23142 23143 23144 23145 23146 23147 23148 23149 23150 23151 23152 23153 23154 23155 23156 23157 23158 23159 23160 23161 23162 23163 23164 23165 23166 23167 23168 23169 23170 23171 23172 23173 23174 23175 23176 23177 23178 23179 23180 23181 23182 23183 23184 23185 23186 23187 23188 23189 23190 23191 23192 23193 23194 23195 23196 23197 23198 23199 23200 23201 23202 23203 23204 23205 23206 23207 23208 23209 23210 23211 23212 23213 23214 23215 23216 23217 23218 23219 23220 23221 23222 23223 23224 23225 23226 23227 23228 23229 23230 23231 23232 23233 23234 23235 23236 23237 23238 23239 23240 23241 23242 23243 23244 23245 23246 23247 23248 23249 23250 23251 23252 23253 23254 23255 23256 23257 23258 23259 23260 23261 23262 23263 23264 23265 23266 23267 23268 23269 23270 23271 23272 23273 23274 23275 23276 23277 23278 23279 23280 23281 23282 23283 23284 23285 23286 23287 23288 23289 23290 23291 23292 23293 23294 23295 23296 23297 23298 23299 23300 23301 23302 23303 23304 23305 23306 23307 23308 23309 23310 23311 23312 23313 23314 23315 23316 23317 23318 23319 23320 23321 23322 23323 23324 23325 23326 23327 23328 23329 23330 23331 23332 23333 23334 23335 23336 23337 23338 23339 23340 23341 23342 23343 23344 23345 23346 23347 23348 23349 23350 23351 23352 23353 23354 23355 23356 23357 23358 23359 23360 23361 23362 23363 23364 23365 23366 23367 23368 23369 23370 23371 23372 23373 23374 23375 23376 23377 23378 23379 23380 23381 23382 23383 23384 23385 23386 23387 23388 23389 23390 23391 23392 23393 23394 23395 23396 23397 23398 23399 23400 23401 23402 23403 23404 23405 23406 23407 23408 23409 23410 23411 23412 23413 23414 23415 23416 23417 23418 23419 23420 23421 23422 23423 23424 23425 23426 23427 23428 23429 23430 23431 23432 23433 23434 23435 23436 23437 23438 23439 23440 23441 23442 23443 23444 23445 23446 23447 23448 23449 23450 23451 23452 23453 23454 23455 23456 23457 23458 23459 23460 23461 23462 23463 23464 23465 23466 23467 23468 23469 23470 23471 23472 23473 23474 23475 23476 23477 23478 23479 23480 23481 23482 23483 23484 23485 23486 23487 23488 23489 23490 23491 23492 23493 23494 23495 23496 23497 23498 23499 23500 23501 23502 23503 23504 23505 23506 23507 23508 23509 23510 23511 23512 23513 23514 23515 23516 23517 23518 23519 23520 23521 23522 23523 23524 23525 23526 23527 23528 23529 23530 23531 23532 23533 23534 23535 23536 23537 23538 23539 23540 23541 23542 23543 23544 23545 23546 23547 23548 23549 23550 23551 23552 23553 23554 23555 23556 23557 23558 23559 23560 23561 23562 23563 23564 23565 23566 23567 23568 23569 23570 23571 23572 23573 23574 23575 23576 23577 23578 23579 23580 23581 23582 23583 23584 23585 23586 23587 23588 23589 23590 23591 23592 23593 23594 23595 23596 23597 23598 23599 23600 23601 23602 23603 23604 23605 23606 23607 23608 23609 23610 23611 23612 23613 23614 23615 23616 23617 23618 23619 23620 23621 23622 23623 23624 23625 23626 23627 23628 23629 23630 23631 23632 23633 23634 23635 23636 23637 23638 23639 23640 23641 23642 23643 23644 23645 23646 23647 23648 23649 23650 23651 23652 23653 23654 23655 23656 23657 23658 23659 23660 23661 23662 23663 23664 23665 23666 23667 23668 23669 23670 23671 23672 23673 23674 23675 23676 23677 23678 23679 23680 23681 23682 23683 23684 23685 23686 23687 23688 23689 23690 23691 23692 23693 23694 23695 23696 23697 23698 23699 23700 23701 23702 23703 23704 23705 23706 23707 23708 23709 23710 23711 23712 23713 23714 23715 23716 23717 23718 23719 23720 23721 23722 23723 23724 23725 23726 23727 23728 23729 23730 23731 23732 23733 23734 23735 23736 23737 23738 23739 23740 23741 23742 23743 23744 23745 23746 23747 23748 23749 23750 23751 23752 23753 23754 23755 23756 23757 23758 23759 23760 23761 23762 23763 23764 23765 23766 23767 23768 23769 23770 23771 23772 23773 23774 23775 23776 23777 23778 23779 23780 23781 23782 23783 23784 23785 23786 23787 23788 23789 23790 23791 23792 23793 23794 23795 23796 23797 23798 23799 23800 23801 23802 23803 23804 23805 23806 23807 23808 23809 23810 23811 23812 23813 23814 23815 23816 23817 23818 23819 23820 23821 23822 23823 23824 23825 23826 23827 23828 23829 23830 23831 23832 23833 23834 23835 23836 23837 23838 23839 23840 23841 23842 23843 23844 23845 23846 23847 23848 23849 23850 23851 23852 23853 23854 23855 23856 23857 23858 23859 23860 23861 23862 23863 23864 23865 23866 23867 23868 23869 23870 23871 23872 23873 23874 23875 23876 23877 23878 23879 23880 23881 23882 23883 23884 23885 23886 23887 23888 23889 23890 23891 23892 23893 23894 23895 23896 23897 23898 23899 23900 23901 23902 23903 23904 23905 23906 23907 23908 23909 23910 23911 23912 23913 23914 23915 23916 23917 23918 23919 23920 23921 23922 23923 23924 23925 23926 23927 23928 23929 23930 23931 23932 23933 23934 23935 23936 23937 23938 23939 23940 23941 23942 23943 23944 23945 23946 23947 23948 23949 23950 23951 23952 23953 23954 23955 23956 23957 23958 23959 23960 23961 23962 23963 23964 23965 23966 23967 23968 23969 23970 23971 23972 23973 23974 23975 23976 23977 23978 23979 23980 23981 23982 23983 23984 23985 23986 23987 23988 23989 23990 23991 23992 23993 23994 23995 23996 23997 23998 23999 24000 24001 24002 24003 24004 24005 24006 24007 24008 24009 24010 24011 24012 24013 24014 24015 24016 24017 24018 24019 24020 24021 24022 24023 24024 24025 24026 24027 24028 24029 24030 24031 24032 24033 24034 24035 24036 24037 24038 24039 24040 24041 24042 24043 24044 24045 24046 24047 24048 24049 24050 24051 24052 24053 24054 24055 24056 24057 24058 24059 24060 24061 24062 24063 24064 24065 24066 24067 24068 24069 24070 24071 24072 24073 24074 24075 24076 24077 24078 24079 24080 24081 24082 24083 24084 24085 24086 24087 24088 24089 24090 24091 24092 24093 24094 24095 24096 24097 24098 24099 24100 24101 24102 24103 24104 24105 24106 24107 24108 24109 24110 24111 24112 24113 24114 24115 24116 24117 24118 24119 24120 24121 24122 24123 24124 24125 24126 24127 24128 24129 24130 24131 24132 24133 24134 24135 24136 24137 24138 24139 24140 24141 24142 24143 24144 24145 24146 24147 24148 24149 24150 24151 24152 24153 24154 24155 24156 24157 24158 24159 24160 24161 24162 24163 24164 24165 24166 24167 24168 24169 24170 24171 24172 24173 24174 24175 24176 24177 24178 24179 24180 24181 24182 24183 24184 24185 24186 24187 24188 24189 24190 24191 24192 24193 24194 24195 24196 24197 24198 24199 24200 24201 24202 24203 24204 24205 24206 24207 24208 24209 24210 24211 24212 24213 24214 24215 24216 24217 24218 24219 24220 24221 24222 24223 24224 24225 24226 24227 24228 24229 24230 24231 24232 24233 24234 24235 24236 24237 24238 24239 24240 24241 24242 24243 24244 24245 24246 24247 24248 24249 24250 24251 24252 24253 24254 24255 24256 24257 24258 24259 24260 24261 24262 24263 24264 24265 24266 24267 24268 24269 24270 24271 24272 24273 24274 24275 24276 24277 24278 24279 24280 24281 24282 24283 24284 24285 24286 24287 24288 24289 24290 24291 24292 24293 24294 24295 24296 24297 24298 24299 24300 24301 24302 24303 24304 24305 24306 24307 24308 24309 24310 24311 24312 24313 24314 24315 24316 24317 24318 24319 24320 24321 24322 24323 24324 24325 24326 24327 24328 24329 24330 24331 24332 24333 24334 24335 24336 24337 24338 24339 24340 24341 24342 24343 24344 24345 24346 24347 24348 24349 24350 24351 24352 24353 24354 24355 24356 24357 24358 24359 24360 24361 24362 24363 24364 24365 24366 24367 24368 24369 24370 24371 24372 24373 24374 24375 24376 24377 24378 24379 24380 24381 24382 24383 24384 24385 24386 24387 24388 24389 24390 24391 24392 24393 24394 24395 24396 24397 24398 24399 24400 24401 24402 24403 24404 24405 24406 24407 24408 24409 24410 24411 24412 24413 24414 24415 24416 24417 24418 24419 24420 24421 24422 24423 24424 24425 24426 24427 24428 24429 24430 24431 24432 24433 24434 24435 24436 24437 24438 24439 24440 24441 24442 24443 24444 24445 24446 24447 24448 24449 24450 24451 24452 24453 24454 24455 24456 24457 24458 24459 24460 24461 24462 24463 24464 24465 24466 24467 24468 24469 24470 24471 24472 24473 24474 24475 24476 24477 24478 24479 24480 24481 24482 24483 24484 24485 24486 24487 24488 24489 24490 24491 24492 24493 24494 24495 24496 24497 24498 24499 24500 24501 24502 24503 24504 24505 24506 24507 24508 24509 24510 24511 24512 24513 24514 24515 24516 24517 24518 24519 24520 24521 24522 24523 24524 24525 24526 24527 24528 24529 24530 24531 24532 24533 24534 24535 24536 24537 24538 24539 24540 24541 24542 24543 24544 24545 24546 24547 24548 24549 24550 24551 24552 24553 24554 24555 24556 24557 24558 24559 24560 24561 24562 24563 24564 24565 24566 24567 24568 24569 24570 24571 24572 24573 24574 24575 24576 24577 24578 24579 24580 24581 24582 24583 24584 24585 24586 24587 24588 24589 24590 24591 24592 24593 24594 24595 24596 24597 24598 24599 24600 24601 24602 24603 24604 24605 24606 24607 24608 24609 24610 24611 24612 24613 24614 24615 24616 24617 24618 24619 24620 24621 24622 24623 24624 24625 24626 24627 24628 24629 24630 24631 24632 24633 24634 24635 24636 24637 24638 24639 24640 24641 24642 24643 24644 24645 24646 24647 24648 24649 24650 24651 24652 24653 24654 24655 24656 24657 24658 24659 24660 24661 24662 24663 24664 24665 24666 24667 24668 24669 24670 24671 24672 24673 24674 24675 24676 24677 24678 24679 24680 24681 24682 24683 24684 24685 24686 24687 24688 24689 24690 24691 24692 24693 24694 24695 24696 24697 24698 24699 24700 24701 24702 24703 24704 24705 24706 24707 24708 24709 24710 24711 24712 24713 24714 24715 24716 24717 24718 24719 24720 24721 24722 24723 24724 24725 24726 24727 24728 24729 24730 24731 24732 24733 24734 24735 24736 24737 24738 24739 24740 24741 24742 24743 24744 24745 24746 24747 24748 24749 24750 24751 24752 24753 24754 24755 24756 24757 24758 24759 24760 24761 24762 24763 24764 24765 24766 24767 24768 24769 24770 24771 24772 24773 24774 24775 24776 24777 24778 24779 24780 24781 24782 24783 24784 24785 24786 24787 24788 24789 24790 24791 24792 24793 24794 24795 24796 24797 24798 24799 24800 24801 24802 24803 24804 24805 24806 24807 24808 24809 24810 24811 24812 24813 24814 24815 24816 24817 24818 24819 24820 24821 24822 24823 24824 24825 24826 24827 24828 24829 24830 24831 24832 24833 24834 24835 24836 24837 24838 24839 24840 24841 24842 24843 24844 24845 24846 24847 24848 24849 24850 24851 24852 24853 24854 24855 24856 24857 24858 24859 24860 24861 24862 24863 24864 24865 24866 24867 24868 24869 24870 24871 24872 24873 24874 24875 24876 24877 24878 24879 24880 24881 24882 24883 24884 24885 24886 24887 24888 24889 24890 24891 24892 24893 24894 24895 24896 24897 24898 24899 24900 24901 24902 24903 24904 24905 24906 24907 24908 24909 24910 24911 24912 24913 24914 24915 24916 24917 24918 24919 24920 24921 24922 24923 24924 24925 24926 24927 24928 24929 24930 24931 24932 24933 24934 24935 24936 24937 24938 24939 24940 24941 24942 24943 24944 24945 24946 24947 24948 24949 24950 24951 24952 24953 24954 24955 24956 24957 24958 24959 24960 24961 24962 24963 24964 24965 24966 24967 24968 24969 24970 24971 24972 24973 24974 24975 24976 24977 24978 24979 24980 24981 24982 24983 24984 24985 24986 24987 24988 24989 24990 24991 24992 24993 24994 24995 24996 24997 24998 24999 25000 25001 25002 25003 25004 25005 25006 25007 25008 25009 25010 25011 25012 25013 25014 25015 25016 25017 25018 25019 25020 25021 25022 25023 25024 25025 25026 25027 25028 25029 25030 25031 25032 25033 25034 25035 25036 25037 25038 25039 25040 25041 25042 25043 25044 25045 25046 25047 25048 25049 25050 25051 25052 25053 25054 25055 25056 25057 25058 25059 25060 25061 25062 25063 25064 25065 25066 25067 25068 25069 25070 25071 25072 25073 25074 25075 25076 25077 25078 25079 25080 25081 25082 25083 25084 25085 25086 25087 25088 25089 25090 25091 25092 25093 25094 25095 25096 25097 25098 25099 25100 25101 25102 25103 25104 25105 25106 25107 25108 25109 25110 25111 25112 25113 25114 25115 25116 25117 25118 25119 25120 25121 25122 25123 25124 25125 25126 25127 25128 25129 25130 25131 25132 25133 25134 25135 25136 25137 25138 25139 25140 25141 25142 25143 25144 25145 25146 25147 25148 25149 25150 25151 25152 25153 25154 25155 25156 25157 25158 25159 25160 25161 25162 25163 25164 25165 25166 25167 25168 25169 25170 25171 25172 25173 25174 25175 25176 25177 25178 25179 25180 25181 25182 25183 25184 25185 25186 25187 25188 25189 25190 25191 25192 25193 25194 25195 25196 25197 25198 25199 25200 25201 25202 25203 25204 25205 25206 25207 25208 25209 25210 25211 25212 25213 25214 25215 25216 25217 25218 25219 25220 25221 25222 25223 25224 25225 25226 25227 25228 25229 25230 25231 25232 25233 25234 25235 25236 25237 25238 25239 25240 25241 25242 25243 25244 25245 25246 25247 25248 25249 25250 25251 25252 25253 25254 25255 25256 25257 25258 25259 25260 25261 25262 25263 25264 25265 25266 25267 25268 25269 25270 25271 25272 25273 25274 25275 25276 25277 25278 25279 25280 25281 25282 25283 25284 25285 25286 25287 25288 25289 25290 25291 25292 25293 25294 25295 25296 25297 25298 25299 25300 25301 25302 25303 25304 25305 25306 25307 25308 25309 25310 25311 25312 25313 25314 25315 25316 25317 25318 25319 25320 25321 25322 25323 25324 25325 25326 25327 25328 25329 25330 25331 25332 25333 25334 25335 25336 25337 25338 25339 25340 25341 25342 25343 25344 25345 25346 25347 25348 25349 25350 25351 25352 25353 25354 25355 25356 25357 25358 25359 25360 25361 25362 25363 25364 25365 25366 25367 25368 25369 25370 25371 25372 25373 25374 25375 25376 25377 25378 25379 25380 25381 25382 25383 25384 25385 25386 25387 25388 25389 25390 25391 25392 25393 25394 25395 25396 25397 25398 25399 25400 25401 25402 25403 25404 25405 25406 25407 25408 25409 25410 25411 25412 25413 25414 25415 25416 25417 25418 25419 25420 25421 25422 25423 25424 25425 25426 25427 25428 25429 25430 25431 25432 25433 25434 25435 25436 25437 25438 25439 25440 25441 25442 25443 25444 25445 25446 25447 25448 25449 25450 25451 25452 25453 25454 25455 25456 25457 25458 25459 25460 25461 25462 25463 25464 25465 25466 25467 25468 25469 25470 25471 25472 25473 25474 25475 25476 25477 25478 25479 25480 25481 25482 25483 25484 25485 25486 25487 25488 25489 25490 25491 25492 25493 25494 25495 25496 25497 25498 25499 25500 25501 25502 25503 25504 25505 25506 25507 25508 25509 25510 25511 25512 25513 25514 25515 25516 25517 25518 25519 25520 25521 25522 25523 25524 25525 25526 25527 25528 25529 25530 25531 25532 25533 25534 25535 25536 25537 25538 25539 25540 25541 25542 25543 25544 25545 25546 25547 25548 25549 25550 25551 25552 25553 25554 25555 25556 25557 25558 25559 25560 25561 25562 25563 25564 25565 25566 25567 25568 25569 25570 25571 25572 25573 25574 25575 25576 25577 25578 25579 25580 25581 25582 25583 25584 25585 25586 25587 25588 25589 25590 25591 25592 25593 25594 25595 25596 25597 25598 25599 25600 25601 25602 25603 25604 25605 25606 25607 25608 25609 25610 25611 25612 25613 25614 25615 25616 25617 25618 25619 25620 25621 25622 25623 25624 25625 25626 25627 25628 25629 25630 25631 25632 25633 25634 25635 25636 25637 25638 25639 25640 25641 25642 25643 25644 25645 25646 25647 25648 25649 25650 25651 25652 25653 25654 25655 25656 25657 25658 25659 25660 25661 25662 25663 25664 25665 25666 25667 25668 25669 25670 25671 25672 25673 25674 25675 25676 25677 25678 25679 25680 25681 25682 25683 25684 25685 25686 25687 25688 25689 25690 25691 25692 25693 25694 25695 25696 25697 25698 25699 25700 25701 25702 25703 25704 25705 25706 25707 25708 25709 25710 25711 25712 25713 25714 25715 25716 25717 25718 25719 25720 25721 25722 25723 25724 25725 25726 25727 25728 25729 25730 25731 25732 25733 25734 25735 25736 25737 25738 25739 25740 25741 25742 25743 25744 25745 25746 25747 25748 25749 25750 25751 25752 25753 25754 25755 25756 25757 25758 25759 25760 25761 25762 25763 25764 25765 25766 25767 25768 25769 25770 25771 25772 25773 25774 25775 25776 25777 25778 25779 25780 25781 25782 25783 25784 25785 25786 25787 25788 25789 25790 25791 25792 25793 25794 25795 25796 25797 25798 25799 25800 25801 25802 25803 25804 25805 25806 25807 25808 25809 25810 25811 25812 25813 25814 25815 25816 25817 25818 25819 25820 25821 25822 25823 25824 25825 25826 25827 25828 25829 25830 25831 25832 25833 25834 25835 25836 25837 25838 25839 25840 25841 25842 25843 25844 25845 25846 25847 25848 25849 25850 25851 25852 25853 25854 25855 25856 25857 25858 25859 25860 25861 25862 25863 25864 25865 25866 25867 25868 25869 25870 25871 25872 25873 25874 25875 25876 25877 25878 25879 25880 25881 25882 25883 25884 25885 25886 25887 25888 25889 25890 25891 25892 25893 25894 25895 25896 25897 25898 25899 25900 25901 25902 25903 25904 25905 25906 25907 25908 25909 25910 25911 25912 25913 25914 25915 25916 25917 25918 25919 25920 25921 25922 25923 25924 25925 25926 25927 25928 25929 25930 25931 25932 25933 25934 25935 25936 25937 25938 25939 25940 25941 25942 25943 25944 25945 25946 25947 25948 25949 25950 25951 25952 25953 25954 25955 25956 25957 25958 25959 25960 25961 25962 25963 25964 25965 25966 25967 25968 25969 25970 25971 25972 25973 25974 25975 25976 25977 25978 25979 25980 25981 25982 25983 25984 25985 25986 25987 25988 25989 25990 25991 25992 25993 25994 25995 25996 25997 25998 25999 26000 26001 26002 26003 26004 26005 26006 26007 26008 26009 26010 26011 26012 26013 26014 26015 26016 26017 26018 26019 26020 26021 26022 26023 26024 26025 26026 26027 26028 26029 26030 26031 26032 26033 26034 26035 26036 26037 26038 26039 26040 26041 26042 26043 26044 26045 26046 26047 26048 26049 26050 26051 26052 26053 26054 26055 26056 26057 26058 26059 26060 26061 26062 26063 26064 26065 26066 26067 26068 26069 26070 26071 26072 26073 26074 26075 26076 26077 26078 26079 26080 26081 26082 26083 26084 26085 26086 26087 26088 26089 26090 26091 26092 26093 26094 26095 26096 26097 26098 26099 26100 26101 26102 26103 26104 26105 26106 26107 26108 26109 26110 26111 26112 26113 26114 26115 26116 26117 26118 26119 26120 26121 26122 26123 26124 26125 26126 26127 26128 26129 26130 26131 26132 26133 26134 26135 26136 26137 26138 26139 26140 26141 26142 26143 26144 26145 26146 26147 26148 26149 26150 26151 26152 26153 26154 26155 26156 26157 26158 26159 26160 26161 26162 26163 26164 26165 26166 26167 26168 26169 26170 26171 26172 26173 26174 26175 26176 26177 26178 26179 26180 26181 26182 26183 26184 26185 26186 26187 26188 26189 26190 26191 26192 26193 26194 26195 26196 26197 26198 26199 26200 26201 26202 26203 26204 26205 26206 26207 26208 26209 26210 26211 26212 26213 26214 26215 26216 26217 26218 26219 26220 26221 26222 26223 26224 26225 26226 26227 26228 26229 26230 26231 26232 26233 26234 26235 26236 26237 26238 26239 26240 26241 26242 26243 26244 26245 26246 26247 26248 26249 26250 26251 26252 26253 26254 26255 26256 26257 26258 26259 26260 26261 26262 26263 26264 26265 26266 26267 26268 26269 26270 26271 26272 26273 26274 26275 26276 26277 26278 26279 26280 26281 26282 26283 26284 26285 26286 26287 26288 26289 26290 26291 26292 26293 26294 26295 26296 26297 26298 26299 26300 26301 26302 26303 26304 26305 26306 26307 26308 26309 26310 26311 26312 26313 26314 26315 26316 26317 26318 26319 26320 26321 26322 26323 26324 26325 26326 26327 26328 26329 26330 26331 26332 26333 26334 26335 26336 26337 26338 26339 26340 26341 26342 26343 26344 26345 26346 26347 26348 26349 26350 26351 26352 26353 26354 26355 26356 26357 26358 26359 26360 26361 26362 26363 26364 26365 26366 26367 26368 26369 26370 26371 26372 26373 26374 26375 26376 26377 26378 26379 26380 26381 26382 26383 26384 26385 26386 26387 26388 26389 26390 26391 26392 26393 26394 26395 26396 26397 26398 26399 26400 26401 26402 26403 26404 26405 26406 26407 26408 26409 26410 26411 26412 26413 26414 26415 26416 26417 26418 26419 26420 26421 26422 26423 26424 26425 26426 26427 26428 26429 26430 26431 26432 26433 26434 26435 26436 26437 26438 26439 26440 26441 26442 26443 26444 26445 26446 26447 26448 26449 26450 26451 26452 26453 26454 26455 26456 26457 26458 26459 26460 26461 26462 26463 26464 26465 26466 26467 26468 26469 26470 26471 26472 26473 26474 26475 26476 26477 26478 26479 26480 26481 26482 26483 26484 26485 26486 26487 26488 26489 26490 26491 26492 26493 26494 26495 26496 26497 26498 26499 26500 26501 26502 26503 26504 26505 26506 26507 26508 26509 26510 26511 26512 26513 26514 26515 26516 26517 26518 26519 26520 26521 26522 26523 26524 26525 26526 26527 26528 26529 26530 26531 26532 26533 26534 26535 26536 26537 26538 26539 26540 26541 26542 26543 26544 26545 26546 26547 26548 26549 26550 26551 26552 26553 26554 26555 26556 26557 26558 26559 26560 26561 26562 26563 26564 26565 26566 26567 26568 26569 26570 26571 26572 26573 26574 26575 26576 26577 26578 26579 26580 26581 26582 26583 26584 26585 26586 26587 26588 26589 26590 26591 26592 26593 26594 26595 26596 26597 26598 26599 26600 26601 26602 26603 26604 26605 26606 26607 26608 26609 26610 26611 26612 26613 26614 26615 26616 26617 26618 26619 26620 26621 26622 26623 26624 26625 26626 26627 26628 26629 26630 26631 26632 26633 26634 26635 26636 26637 26638 26639 26640 26641 26642 26643 26644 26645 26646 26647 26648 26649 26650 26651 26652 26653 26654 26655 26656 26657 26658 26659 26660 26661 26662 26663 26664 26665 26666 26667 26668 26669 26670 26671 26672 26673 26674 26675 26676 26677 26678 26679 26680 26681 26682 26683 26684 26685 26686 26687 26688 26689 26690 26691 26692 26693 26694 26695 26696 26697 26698 26699 26700 26701 26702 26703 26704 26705 26706 26707 26708 26709 26710 26711 26712 26713 26714 26715 26716 26717 26718 26719 26720 26721 26722 26723 26724 26725 26726 26727 26728 26729 26730 26731 26732 26733 26734 26735 26736 26737 26738 26739 26740 26741 26742 26743 26744 26745 26746 26747 26748 26749 26750 26751 26752 26753 26754 26755 26756 26757 26758 26759 26760 26761 26762 26763 26764 26765 26766 26767 26768 26769 26770 26771 26772 26773 26774 26775 26776 26777 26778 26779 26780 26781 26782 26783 26784 26785 26786 26787 26788 26789 26790 26791 26792 26793 26794 26795 26796 26797 26798 26799 26800 26801 26802 26803 26804 26805 26806 26807 26808 26809 26810 26811 26812 26813 26814 26815 26816 26817 26818 26819 26820 26821 26822 26823 26824 26825 26826 26827 26828 26829 26830 26831 26832 26833 26834 26835 26836 26837 26838 26839 26840 26841 26842 26843 26844 26845 26846 26847 26848 26849 26850 26851 26852 26853 26854 26855 26856 26857 26858 26859 26860 26861 26862 26863 26864 26865 26866 26867 26868 26869 26870 26871 26872 26873 26874 26875 26876 26877 26878 26879 26880 26881 26882 26883 26884 26885 26886 26887 26888 26889 26890 26891 26892 26893 26894 26895 26896 26897 26898 26899 26900 26901 26902 26903 26904 26905 26906 26907 26908 26909 26910 26911 26912 26913 26914 26915 26916 26917 26918 26919 26920 26921 26922 26923 26924 26925 26926 26927 26928 26929 26930 26931 26932 26933 26934 26935 26936 26937 26938 26939 26940 26941 26942 26943 26944 26945 26946 26947 26948 26949 26950 26951 26952 26953 26954 26955 26956 26957 26958 26959 26960 26961 26962 26963 26964 26965 26966 26967 26968 26969 26970 26971 26972 26973 26974 26975 26976 26977 26978 26979 26980 26981 26982 26983 26984 26985 26986 26987 26988 26989 26990 26991 26992 26993 26994 26995 26996 26997 26998 26999 27000 27001 27002 27003 27004 27005 27006 27007 27008 27009 27010 27011 27012 27013 27014 27015 27016 27017 27018 27019 27020 27021 27022 27023 27024 27025 27026 27027 27028 27029 27030 27031 27032 27033 27034 27035 27036 27037 27038 27039 27040 27041 27042 27043 27044 27045 27046 27047 27048 27049 27050 27051 27052 27053 27054 27055 27056 27057 27058 27059 27060 27061 27062 27063 27064 27065 27066 27067 27068 27069 27070 27071 27072 27073 27074 27075 27076 27077 27078 27079 27080 27081 27082 27083 27084 27085 27086 27087 27088 27089 27090 27091 27092 27093 27094 27095 27096 27097 27098 27099 27100 27101 27102 27103 27104 27105 27106 27107 27108 27109 27110 27111 27112 27113 27114 27115 27116 27117 27118 27119 27120 27121 27122 27123 27124 27125 27126 27127 27128 27129 27130 27131 27132 27133 27134 27135 27136 27137 27138 27139 27140 27141 27142 27143 27144 27145 27146 27147 27148 27149 27150 27151 27152 27153 27154 27155 27156 27157 27158 27159 27160 27161 27162 27163 27164 27165 27166 27167 27168 27169 27170 27171 27172 27173 27174 27175 27176 27177 27178 27179 27180 27181 27182 27183 27184 27185 27186 27187 27188 27189 27190 27191 27192 27193 27194 27195 27196 27197 27198 27199 27200 27201 27202 27203 27204 27205 27206 27207 27208 27209 27210 27211 27212 27213 27214 27215 27216 27217 27218 27219 27220 27221 27222 27223 27224 27225 27226 27227 27228 27229 27230 27231 27232 27233 27234 27235 27236 27237 27238 27239 27240 27241 27242 27243 27244 27245 27246 27247 27248 27249 27250 27251 27252 27253 27254 27255 27256 27257 27258 27259 27260 27261 27262 27263 27264 27265 27266 27267 27268 27269 27270 27271 27272 27273 27274 27275 27276 27277 27278 27279 27280 27281 27282 27283 27284 27285 27286 27287 27288 27289 27290 27291 27292 27293 27294 27295 27296 27297 27298 27299 27300 27301 27302 27303 27304 27305 27306 27307 27308 27309 27310 27311 27312 27313 27314 27315 27316 27317 27318 27319 27320 27321 27322 27323 27324 27325 27326 27327 27328 27329 27330 27331 27332 27333 27334 27335 27336 27337 27338 27339 27340 27341 27342 27343 27344 27345 27346 27347 27348 27349 27350 27351 27352 27353 27354 27355 27356 27357 27358 27359 27360 27361 27362 27363 27364 27365 27366 27367 27368 27369 27370 27371 27372 27373 27374 27375 27376 27377 27378 27379 27380 27381 27382 27383 27384 27385 27386 27387 27388 27389 27390 27391 27392 27393 27394 27395 27396 27397 27398 27399 27400 27401 27402 27403 27404 27405 27406 27407 27408 27409 27410 27411 27412 27413 27414 27415 27416 27417 27418 27419 27420 27421 27422 27423 27424 27425 27426 27427 27428 27429 27430 27431 27432 27433 27434 27435 27436 27437 27438 27439 27440 27441 27442 27443 27444 27445 27446 27447 27448 27449 27450 27451 27452 27453 27454 27455 27456 27457 27458 27459 27460 27461 27462 27463 27464 27465 27466 27467 27468 27469 27470 27471 27472 27473 27474 27475 27476 27477 27478 27479 27480 27481 27482 27483 27484 27485 27486 27487 27488 27489 27490 27491 27492 27493 27494 27495 27496 27497 27498 27499 27500 27501 27502 27503 27504 27505 27506 27507 27508 27509 27510 27511 27512 27513 27514 27515 27516 27517 27518 27519 27520 27521 27522 27523 27524 27525 27526 27527 27528 27529 27530 27531 27532 27533 27534 27535 27536 27537 27538 27539 27540 27541 27542 27543 27544 27545 27546 27547 27548 27549 27550 27551 27552 27553 27554 27555 27556 27557 27558 27559 27560 27561 27562 27563 27564 27565 27566 27567 27568 27569 27570 27571 27572 27573 27574 27575 27576 27577 27578 27579 27580 27581 27582 27583 27584 27585 27586 27587 27588 27589 27590 27591 27592 27593 27594 27595 27596 27597 27598 27599 27600 27601 27602 27603 27604 27605 27606 27607 27608 27609 27610 27611 27612 27613 27614 27615 27616 27617 27618 27619 27620 27621 27622 27623 27624 27625 27626 27627 27628 27629 27630 27631 27632 27633 27634 27635 27636 27637 27638 27639 27640 27641 27642 27643 27644 27645 27646 27647 27648 27649 27650 27651 27652 27653 27654 27655 27656 27657 27658 27659 27660 27661 27662 27663 27664 27665 27666 27667 27668 27669 27670 27671 27672 27673 27674 27675 27676 27677 27678 27679 27680 27681 27682 27683 27684 27685 27686 27687 27688 27689 27690 27691 27692 27693 27694 27695 27696 27697 27698 27699 27700 27701 27702 27703 27704 27705 27706 27707 27708 27709 27710 27711 27712 27713 27714 27715 27716 27717 27718 27719 27720 27721 27722 27723 27724 27725 27726 27727 27728 27729 27730 27731 27732 27733 27734 27735 27736 27737 27738 27739 27740 27741 27742 27743 27744 27745 27746 27747 27748 27749 27750 27751 27752 27753 27754 27755 27756 27757 27758 27759 27760 27761 27762 27763 27764 27765 27766 27767 27768 27769 27770 27771 27772 27773 27774 27775 27776 27777 27778 27779 27780 27781 27782 27783 27784 27785 27786 27787 27788 27789 27790 27791 27792 27793 27794 27795 27796 27797 27798 27799 27800 27801 27802 27803 27804 27805 27806 27807 27808 27809 27810 27811 27812 27813 27814 27815 27816 27817 27818 27819 27820 27821 27822 27823 27824 27825 27826 27827 27828 27829 27830 27831 27832 27833 27834 27835 27836 27837 27838 27839 27840 27841 27842 27843 27844 27845 27846 27847 27848 27849 27850 27851 27852 27853 27854 27855 27856 27857 27858 27859 27860 27861 27862 27863 27864 27865 27866 27867 27868 27869 27870 27871 27872 27873 27874 27875 27876 27877 27878 27879 27880 27881 27882 27883 27884 27885 27886 27887 27888 27889 27890 27891 27892 27893 27894 27895 27896 27897 27898 27899 27900 27901 27902 27903 27904 27905 27906 27907 27908 27909 27910 27911 27912 27913 27914 27915 27916 27917 27918 27919 27920 27921 27922 27923 27924 27925 27926 27927 27928 27929 27930 27931 27932 27933 27934 27935 27936 27937 27938 27939 27940 27941 27942 27943 27944 27945 27946 27947 27948 27949 27950 27951 27952 27953 27954 27955 27956 27957 27958 27959 27960 27961 27962 27963 27964 27965 27966 27967 27968 27969 27970 27971 27972 27973 27974 27975 27976 27977 27978 27979 27980 27981 27982 27983 27984 27985 27986 27987 27988 27989 27990 27991 27992 27993 27994 27995 27996 27997 27998 27999 28000 28001 28002 28003 28004 28005 28006 28007 28008 28009 28010 28011 28012 28013 28014 28015 28016 28017 28018 28019 28020 28021 28022 28023 28024 28025 28026 28027 28028 28029 28030 28031 28032 28033 28034 28035 28036 28037 28038 28039 28040 28041 28042 28043 28044 28045 28046 28047 28048 28049 28050 28051 28052 28053 28054 28055 28056 28057 28058 28059 28060 28061 28062 28063 28064 28065 28066 28067 28068 28069 28070 28071 28072 28073 28074 28075 28076 28077 28078 28079 28080 28081 28082 28083 28084 28085 28086 28087 28088 28089 28090 28091 28092 28093 28094 28095 28096 28097 28098 28099 28100 28101 28102 28103 28104 28105 28106 28107 28108 28109 28110 28111 28112 28113 28114 28115 28116 28117 28118 28119 28120 28121 28122 28123 28124 28125 28126 28127 28128 28129 28130 28131 28132 28133 28134 28135 28136 28137 28138 28139 28140 28141 28142 28143 28144 28145 28146 28147 28148 28149 28150 28151 28152 28153 28154 28155 28156 28157 28158 28159 28160 28161 28162 28163 28164 28165 28166 28167 28168 28169 28170 28171 28172 28173 28174 28175 28176 28177 28178 28179 28180 28181 28182 28183 28184 28185 28186 28187 28188 28189 28190 28191 28192 28193 28194 28195 28196 28197 28198 28199 28200 28201 28202 28203 28204 28205 28206 28207 28208 28209 28210 28211 28212 28213 28214 28215 28216 28217 28218 28219 28220 28221 28222 28223 28224 28225 28226 28227 28228 28229 28230 28231 28232 28233 28234 28235 28236 28237 28238 28239 28240 28241 28242 28243 28244 28245 28246 28247 28248 28249 28250 28251 28252 28253 28254 28255 28256 28257 28258 28259 28260 28261 28262 28263 28264 28265 28266 28267 28268 28269 28270 28271 28272 28273 28274 28275 28276 28277 28278 28279 28280 28281 28282 28283 28284 28285 28286 28287 28288 28289 28290 28291 28292 28293 28294 28295 28296 28297 28298 28299 28300 28301 28302 28303 28304 28305 28306 28307 28308 28309 28310 28311 28312 28313 28314 28315 28316 28317 28318 28319 28320 28321 28322 28323 28324 28325 28326 28327 28328 28329 28330 28331 28332 28333 28334 28335 28336 28337 28338 28339 28340 28341 28342 28343 28344 28345 28346 28347 28348 28349 28350 28351 28352 28353 28354 28355 28356 28357 28358 28359 28360 28361 28362 28363 28364 28365 28366 28367 28368 28369 28370 28371 28372 28373 28374 28375 28376 28377 28378 28379 28380 28381 28382 28383 28384 28385 28386 28387 28388 28389 28390 28391 28392 28393 28394 28395 28396 28397 28398 28399 28400 28401 28402 28403 28404 28405 28406 28407 28408 28409 28410 28411 28412 28413 28414 28415 28416 28417 28418 28419 28420 28421 28422 28423 28424 28425 28426 28427 28428 28429 28430 28431 28432 28433 28434 28435 28436 28437 28438 28439 28440 28441 28442 28443 28444 28445 28446 28447 28448 28449 28450 28451 28452 28453 28454 28455 28456 28457 28458 28459 28460 28461 28462 28463 28464 28465 28466 28467 28468 28469 28470 28471 28472 28473 28474 28475 28476 28477 28478 28479 28480 28481 28482 28483 28484 28485 28486 28487 28488 28489 28490 28491 28492 28493 28494 28495 28496 28497 28498 28499 28500 28501 28502 28503 28504 28505 28506 28507 28508 28509 28510 28511 28512 28513 28514 28515 28516 28517 28518 28519 28520 28521 28522 28523 28524 28525 28526 28527 28528 28529 28530 28531 28532 28533 28534 28535 28536 28537 28538 28539 28540 28541 28542 28543 28544 28545 28546 28547 28548 28549 28550 28551 28552 28553 28554 28555 28556 28557 28558 28559 28560 28561 28562 28563 28564 28565 28566 28567 28568 28569 28570 28571 28572 28573 28574 28575 28576 28577 28578 28579 28580 28581 28582 28583 28584 28585 28586 28587 28588 28589 28590 28591 28592 28593 28594 28595 28596 28597 28598 28599 28600 28601 28602 28603 28604 28605 28606 28607 28608 28609 28610 28611 28612 28613 28614 28615 28616 28617 28618 28619 28620 28621 28622 28623 28624 28625 28626 28627 28628 28629 28630 28631 28632 28633 28634 28635 28636 28637 28638 28639 28640 28641 28642 28643 28644 28645 28646 28647 28648 28649 28650 28651 28652 28653 28654 28655 28656 28657 28658 28659 28660 28661 28662 28663 28664 28665 28666 28667 28668 28669 28670 28671 28672 28673 28674 28675 28676 28677 28678 28679 28680 28681 28682 28683 28684 28685 28686 28687 28688 28689 28690 28691 28692 28693 28694 28695 28696 28697 28698 28699 28700 28701 28702 28703 28704 28705 28706 28707 28708 28709 28710 28711 28712 28713 28714 28715 28716 28717 28718 28719 28720 28721 28722 28723 28724 28725 28726 28727 28728 28729 28730 28731 28732 28733 28734 28735 28736 28737 28738 28739 28740 28741 28742 28743 28744 28745 28746 28747 28748 28749 28750 28751 28752 28753 28754 28755 28756 28757 28758 28759 28760 28761 28762 28763 28764 28765 28766 28767 28768 28769 28770 28771 28772 28773 28774 28775 28776 28777 28778 28779 28780 28781 28782 28783 28784 28785 28786 28787 28788 28789 28790 28791 28792 28793 28794 28795 28796 28797 28798 28799 28800 28801 28802 28803 28804 28805 28806 28807 28808 28809 28810 28811 28812 28813 28814 28815 28816 28817 28818 28819 28820 28821 28822 28823 28824 28825 28826 28827 28828 28829 28830 28831 28832 28833 28834 28835 28836 28837 28838 28839 28840 28841 28842 28843 28844 28845 28846 28847 28848 28849 28850 28851 28852 28853 28854 28855 28856 28857 28858 28859 28860 28861 28862 28863 28864 28865 28866 28867 28868 28869 28870 28871 28872 28873 28874 28875 28876 28877 28878 28879 28880 28881 28882 28883 28884 28885 28886 28887 28888 28889 28890 28891 28892 28893 28894 28895 28896 28897 28898 28899 28900 28901 28902 28903 28904 28905 28906 28907 28908 28909 28910 28911 28912 28913 28914 28915 28916 28917 28918 28919 28920 28921 28922 28923 28924 28925 28926 28927 28928 28929 28930 28931 28932 28933 28934 28935 28936 28937 28938 28939 28940 28941 28942 28943 28944 28945 28946 28947 28948 28949 28950 28951 28952 28953 28954 28955 28956 28957 28958 28959 28960 28961 28962 28963 28964 28965 28966 28967 28968 28969 28970 28971 28972 28973 28974 28975 28976 28977 28978 28979 28980 28981 28982 28983 28984 28985 28986 28987 28988 28989 28990 28991 28992 28993 28994 28995 28996 28997 28998 28999 29000 29001 29002 29003 29004 29005 29006 29007 29008 29009 29010 29011 29012 29013 29014 29015 29016 29017 29018 29019 29020 29021 29022 29023 29024 29025 29026 29027 29028 29029 29030 29031 29032 29033 29034 29035 29036 29037 29038 29039 29040 29041 29042 29043 29044 29045 29046 29047 29048 29049 29050 29051 29052 29053 29054 29055 29056 29057 29058 29059 29060 29061 29062 29063 29064 29065 29066 29067 29068 29069 29070 29071 29072 29073 29074 29075 29076 29077 29078 29079 29080 29081 29082 29083 29084 29085 29086 29087 29088 29089 29090 29091 29092 29093 29094 29095 29096 29097 29098 29099 29100 29101 29102 29103 29104 29105 29106 29107 29108 29109 29110 29111 29112 29113 29114 29115 29116 29117 29118 29119 29120 29121 29122 29123 29124 29125 29126 29127 29128 29129 29130 29131 29132 29133 29134 29135 29136 29137 29138 29139 29140 29141 29142 29143 29144 29145 29146 29147 29148 29149 29150 29151 29152 29153 29154 29155 29156 29157 29158 29159 29160 29161 29162 29163 29164 29165 29166 29167 29168 29169 29170 29171 29172 29173 29174 29175 29176 29177 29178 29179 29180 29181 29182 29183 29184 29185 29186 29187 29188 29189 29190 29191 29192 29193 29194 29195 29196 29197 29198 29199 29200 29201 29202 29203 29204 29205 29206 29207 29208 29209 29210 29211 29212 29213 29214 29215 29216 29217 29218 29219 29220 29221 29222 29223 29224 29225 29226 29227 29228 29229 29230 29231 29232 29233 29234 29235 29236 29237 29238 29239 29240 29241 29242 29243 29244 29245 29246 29247 29248 29249 29250 29251 29252 29253 29254 29255 29256 29257 29258 29259 29260 29261 29262 29263 29264 29265 29266 29267 29268 29269 29270 29271 29272 29273 29274 29275 29276 29277 29278 29279 29280 29281 29282 29283 29284 29285 29286 29287 29288 29289 29290 29291 29292 29293 29294 29295 29296 29297 29298 29299 29300 29301 29302 29303 29304 29305 29306 29307 29308 29309 29310 29311 29312 29313 29314 29315 29316 29317 29318 29319 29320 29321 29322 29323 29324 29325 29326 29327 29328 29329 29330 29331 29332 29333 29334 29335 29336 29337 29338 29339 29340 29341 29342 29343 29344 29345 29346 29347 29348 29349 29350 29351 29352 29353 29354 29355 29356 29357 29358 29359 29360 29361 29362 29363 29364 29365 29366 29367 29368 29369 29370 29371 29372 29373 29374 29375 29376 29377 29378 29379 29380 29381 29382 29383 29384 29385 29386 29387 29388 29389 29390 29391 29392 29393 29394 29395 29396 29397 29398 29399 29400 29401 29402 29403 29404 29405 29406 29407 29408 29409 29410 29411 29412 29413 29414 29415 29416 29417 29418 29419 29420 29421 29422 29423 29424 29425 29426 29427 29428 29429 29430 29431 29432 29433 29434 29435 29436 29437 29438 29439 29440 29441 29442 29443 29444 29445 29446 29447 29448 29449 29450 29451 29452 29453 29454 29455 29456 29457 29458 29459 29460 29461 29462 29463 29464 29465 29466 29467 29468 29469 29470 29471 29472 29473 29474 29475 29476 29477 29478 29479 29480 29481 29482 29483 29484 29485 29486 29487 29488 29489 29490 29491 29492 29493 29494 29495 29496 29497 29498 29499 29500 29501 29502 29503 29504 29505 29506 29507 29508 29509 29510 29511 29512 29513 29514 29515 29516 29517 29518 29519 29520 29521 29522 29523 29524 29525 29526 29527 29528 29529 29530 29531 29532 29533 29534 29535 29536 29537 29538 29539 29540 29541 29542 29543 29544 29545 29546 29547 29548 29549 29550 29551 29552 29553 29554 29555 29556 29557 29558 29559 29560 29561 29562 29563 29564 29565 29566 29567 29568 29569 29570 29571 29572 29573 29574 29575 29576 29577 29578 29579 29580 29581 29582 29583 29584 29585 29586 29587 29588 29589 29590 29591 29592 29593 29594 29595 29596 29597 29598 29599 29600 29601 29602 29603 29604 29605 29606 29607 29608 29609 29610 29611 29612 29613 29614 29615 29616 29617 29618 29619 29620 29621 29622 29623 29624 29625 29626 29627 29628 29629 29630 29631 29632 29633 29634 29635 29636 29637 29638 29639 29640 29641 29642 29643 29644 29645 29646 29647 29648 29649 29650 29651 29652 29653 29654 29655 29656 29657 29658 29659 29660 29661 29662 29663 29664 29665 29666 29667 29668 29669 29670 29671 29672 29673 29674 29675 29676 29677 29678 29679 29680 29681 29682 29683 29684 29685 29686 29687 29688 29689 29690 29691 29692 29693 29694 29695 29696 29697 29698 29699 29700 29701 29702 29703 29704 29705 29706 29707 29708 29709 29710 29711 29712 29713 29714 29715 29716 29717 29718 29719 29720 29721 29722 29723 29724 29725 29726 29727 29728 29729 29730 29731 29732 29733 29734 29735 29736 29737 29738 29739 29740 29741 29742 29743 29744 29745 29746 29747 29748 29749 29750 29751 29752 29753 29754 29755 29756 29757 29758 29759 29760 29761 29762 29763 29764 29765 29766 29767 29768 29769 29770 29771 29772 29773 29774 29775 29776 29777 29778 29779 29780 29781 29782 29783 29784 29785 29786 29787 29788 29789 29790 29791 29792 29793 29794 29795 29796 29797 29798 29799 29800 29801 29802 29803 29804 29805 29806 29807 29808 29809 29810 29811 29812 29813 29814 29815 29816 29817 29818 29819 29820 29821 29822 29823 29824 29825 29826 29827 29828 29829 29830 29831 29832 29833 29834 29835 29836 29837 29838 29839 29840 29841 29842 29843 29844 29845 29846 29847 29848 29849 29850 29851 29852 29853 29854 29855 29856 29857 29858 29859 29860 29861 29862 29863 29864 29865 29866 29867 29868 29869 29870 29871 29872 29873 29874 29875 29876 29877 29878 29879 29880 29881 29882 29883 29884 29885 29886 29887 29888 29889 29890 29891 29892 29893 29894 29895 29896 29897 29898 29899 29900 29901 29902 29903 29904 29905 29906 29907 29908 29909 29910 29911 29912 29913 29914 29915 29916 29917 29918 29919 29920 29921 29922 29923 29924 29925 29926 29927 29928 29929 29930 29931 29932 29933 29934 29935 29936 29937 29938 29939 29940 29941 29942 29943 29944 29945 29946 29947 29948 29949 29950 29951 29952 29953 29954 29955 29956 29957 29958 29959 29960 29961 29962 29963 29964 29965 29966 29967 29968 29969 29970 29971 29972 29973 29974 29975 29976 29977 29978 29979 29980 29981 29982 29983 29984 29985 29986 29987 29988 29989 29990 29991 29992 29993 29994 29995 29996 29997 29998 29999 30000 30001 30002 30003 30004 30005 30006 30007 30008 30009 30010 30011 30012 30013 30014 30015 30016 30017 30018 30019 30020 30021 30022 30023 30024 30025 30026 30027 30028 30029 30030 30031 30032 30033 30034 30035 30036 30037 30038 30039 30040 30041 30042 30043 30044 30045 30046 30047 30048 30049 30050 30051 30052 30053 30054 30055 30056 30057 30058 30059 30060 30061 30062 30063 30064 30065 30066 30067 30068 30069 30070 30071 30072 30073 30074 30075 30076 30077 30078 30079 30080 30081 30082 30083 30084 30085 30086 30087 30088 30089 30090 30091 30092 30093 30094 30095 30096 30097 30098 30099 30100 30101 30102 30103 30104 30105 30106 30107 30108 30109 30110 30111 30112 30113 30114 30115 30116 30117 30118 30119 30120 30121 30122 30123 30124 30125 30126 30127 30128 30129 30130 30131 30132 30133 30134 30135 30136 30137 30138 30139 30140 30141 30142 30143 30144 30145 30146 30147 30148 30149 30150 30151 30152 30153 30154 30155 30156 30157 30158 30159 30160 30161 30162 30163 30164 30165 30166 30167 30168 30169 30170 30171 30172 30173 30174 30175 30176 30177 30178 30179 30180 30181 30182 30183 30184 30185 30186 30187 30188 30189 30190 30191 30192 30193 30194 30195 30196 30197 30198 30199 30200 30201 30202 30203 30204 30205 30206 30207 30208 30209 30210 30211 30212 30213 30214 30215 30216 30217 30218 30219 30220 30221 30222 30223 30224 30225 30226 30227 30228 30229 30230 30231 30232 30233 30234 30235 30236 30237 30238 30239 30240 30241 30242 30243 30244 30245 30246 30247 30248 30249 30250 30251 30252 30253 30254 30255 30256 30257 30258 30259 30260 30261 30262 30263 30264 30265 30266 30267 30268 30269 30270 30271 30272 30273 30274 30275 30276 30277 30278 30279 30280 30281 30282 30283 30284 30285 30286 30287 30288 30289 30290 30291 30292 30293 30294 30295 30296 30297 30298 30299 30300 30301 30302 30303 30304 30305 30306 30307 30308 30309 30310 30311 30312 30313 30314 30315 30316 30317 30318 30319 30320 30321 30322 30323 30324 30325 30326 30327 30328 30329 30330 30331 30332 30333 30334 30335 30336 30337 30338 30339 30340 30341 30342 30343 30344 30345 30346 30347 30348 30349 30350 30351 30352 30353 30354 30355 30356 30357 30358 30359 30360 30361 30362 30363 30364 30365 30366 30367 30368 30369 30370 30371 30372 30373 30374 30375 30376 30377 30378 30379 30380 30381 30382 30383 30384 30385 30386 30387 30388 30389 30390 30391 30392 30393 30394 30395 30396 30397 30398 30399 30400 30401 30402 30403 30404 30405 30406 30407 30408 30409 30410 30411 30412 30413 30414 30415 30416 30417 30418 30419 30420 30421 30422 30423 30424 30425 30426 30427 30428 30429 30430 30431 30432 30433 30434 30435 30436 30437 30438 30439 30440 30441 30442 30443 30444 30445 30446 30447 30448 30449 30450 30451 30452 30453 30454 30455 30456 30457 30458 30459 30460 30461 30462 30463 30464 30465 30466 30467 30468 30469 30470 30471 30472 30473 30474 30475 30476 30477 30478 30479 30480 30481 30482 30483 30484 30485 30486 30487 30488 30489 30490 30491 30492 30493 30494 30495 30496 30497 30498 30499 30500 30501 30502 30503 30504 30505 30506 30507 30508 30509 30510 30511 30512 30513 30514 30515 30516 30517 30518 30519 30520 30521 30522 30523 30524 30525 30526 30527 30528 30529 30530 30531 30532 30533 30534 30535 30536 30537 30538 30539 30540 30541 30542 30543 30544 30545 30546 30547 30548 30549 30550 30551 30552 30553 30554 30555 30556 30557 30558 30559 30560 30561 30562 30563 30564 30565 30566 30567 30568 30569 30570 30571 30572 30573 30574 30575 30576 30577 30578 30579 30580 30581 30582 30583 30584 30585 30586 30587 30588 30589 30590 30591 30592 30593 30594 30595 30596 30597 30598 30599 30600 30601 30602 30603 30604 30605 30606 30607 30608 30609 30610 30611 30612 30613 30614 30615 30616 30617 30618 30619 30620 30621 30622 30623 30624 30625 30626 30627 30628 30629 30630 30631 30632 30633 30634 30635 30636 30637 30638 30639 30640 30641 30642 30643 30644 30645 30646 30647 30648 30649 30650 30651 30652 30653 30654 30655 30656 30657 30658 30659 30660 30661 30662 30663 30664 30665 30666 30667 30668 30669 30670 30671 30672 30673 30674 30675 30676 30677 30678 30679 30680 30681 30682 30683 30684 30685 30686 30687 30688 30689 30690 30691 30692 30693 30694 30695 30696 30697 30698 30699 30700 30701 30702 30703 30704 30705 30706 30707 30708 30709 30710 30711 30712 30713 30714 30715 30716 30717 30718 30719 30720 30721 30722 30723 30724 30725 30726 30727 30728 30729 30730 30731 30732 30733 30734 30735 30736 30737 30738 30739 30740 30741 30742 30743 30744 30745 30746 30747 30748 30749 30750 30751 30752 30753 30754 30755 30756 30757 30758 30759 30760 30761 30762 30763 30764 30765 30766 30767 30768 30769 30770 30771 30772 30773 30774 30775 30776 30777 30778 30779 30780 30781 30782 30783 30784 30785 30786 30787 30788 30789 30790 30791 30792 30793 30794 30795 30796 30797 30798 30799 30800 30801 30802 30803 30804 30805 30806 30807 30808 30809 30810 30811 30812 30813 30814 30815 30816 30817 30818 30819 30820 30821 30822 30823 30824 30825 30826 30827 30828 30829 30830 30831 30832 30833 30834 30835 30836 30837 30838 30839 30840 30841 30842 30843 30844 30845 30846 30847 30848 30849 30850 30851 30852 30853 30854 30855 30856 30857 30858 30859 30860 30861 30862 30863 30864 30865 30866 30867 30868 30869 30870 30871 30872 30873 30874 30875 30876 30877 30878 30879 30880 30881 30882 30883 30884 30885 30886 30887 30888 30889 30890 30891 30892 30893 30894 30895 30896 30897 30898 30899 30900 30901 30902 30903 30904 30905 30906 30907 30908 30909 30910 30911 30912 30913 30914 30915 30916 30917 30918 30919 30920 30921 30922 30923 30924 30925 30926 30927 30928 30929 30930 30931 30932 30933 30934 30935 30936 30937 30938 30939 30940 30941 30942 30943 30944 30945 30946 30947 30948 30949 30950 30951 30952 30953 30954 30955 30956 30957 30958 30959 30960 30961 30962 30963 30964 30965 30966 30967 30968 30969 30970 30971 30972 30973 30974 30975 30976 30977 30978 30979 30980 30981 30982 30983 30984 30985 30986 30987 30988 30989 30990 30991 30992 30993 30994 30995 30996 30997 30998 30999 31000 31001 31002 31003 31004 31005 31006 31007 31008 31009 31010 31011 31012 31013 31014 31015 31016 31017 31018 31019 31020 31021 31022 31023 31024 31025 31026 31027 31028 31029 31030 31031 31032 31033 31034 31035 31036 31037 31038 31039 31040 31041 31042 31043 31044 31045 31046 31047 31048 31049 31050 31051 31052 31053 31054 31055 31056 31057 31058 31059 31060 31061 31062 31063 31064 31065 31066 31067 31068 31069 31070 31071 31072 31073 31074 31075 31076 31077 31078 31079 31080 31081 31082 31083 31084 31085 31086 31087 31088 31089 31090 31091 31092 31093 31094 31095 31096 31097 31098 31099 31100 31101 31102 31103 31104 31105 31106 31107 31108 31109 31110 31111 31112 31113 31114 31115 31116 31117 31118 31119 31120 31121 31122 31123 31124 31125 31126 31127 31128 31129 31130 31131 31132 31133 31134 31135 31136 31137 31138 31139 31140 31141 31142 31143 31144 31145 31146 31147 31148 31149 31150 31151 31152 31153 31154 31155 31156 31157 31158 31159 31160 31161 31162 31163 31164 31165 31166 31167 31168 31169 31170 31171 31172 31173 31174 31175 31176 31177 31178 31179 31180 31181 31182 31183 31184 31185 31186 31187 31188 31189 31190 31191 31192 31193 31194 31195 31196 31197 31198 31199 31200 31201 31202 31203 31204 31205 31206 31207 31208 31209 31210 31211 31212 31213 31214 31215 31216 31217 31218 31219 31220 31221 31222 31223 31224 31225 31226 31227 31228 31229 31230 31231 31232 31233 31234 31235 31236 31237 31238 31239 31240 31241 31242 31243 31244 31245 31246 31247 31248 31249 31250 31251 31252 31253 31254 31255 31256 31257 31258 31259 31260 31261 31262 31263 31264 31265 31266 31267 31268 31269 31270 31271 31272 31273 31274 31275 31276 31277 31278 31279 31280 31281 31282 31283 31284 31285 31286 31287 31288 31289 31290 31291 31292 31293 31294 31295 31296 31297 31298 31299 31300 31301 31302 31303 31304 31305 31306 31307 31308 31309 31310 31311 31312 31313 31314 31315 31316 31317 31318 31319 31320 31321 31322 31323 31324 31325 31326 31327 31328 31329 31330 31331 31332 31333 31334 31335 31336 31337 31338 31339 31340 31341 31342 31343 31344 31345 31346 31347 31348 31349 31350 31351 31352 31353 31354 31355 31356 31357 31358 31359 31360 31361 31362 31363 31364 31365 31366 31367 31368 31369 31370 31371 31372 31373 31374 31375 31376 31377 31378 31379 31380 31381 31382 31383 31384 31385 31386 31387 31388 31389 31390 31391 31392 31393 31394 31395 31396 31397 31398 31399 31400 31401 31402 31403 31404 31405 31406 31407 31408 31409 31410 31411 31412 31413 31414 31415 31416 31417 31418 31419 31420 31421 31422 31423 31424 31425 31426 31427 31428 31429 31430 31431 31432 31433 31434 31435 31436 31437 31438 31439 31440 31441 31442 31443 31444 31445 31446 31447 31448 31449 31450 31451 31452 31453 31454 31455 31456 31457 31458 31459 31460 31461 31462 31463 31464 31465 31466 31467 31468 31469 31470 31471 31472 31473 31474 31475 31476 31477 31478 31479 31480 31481 31482 31483 31484 31485 31486 31487 31488 31489 31490 31491 31492 31493 31494 31495 31496 31497 31498 31499 31500 31501 31502 31503 31504 31505 31506 31507 31508 31509 31510 31511 31512 31513 31514 31515 31516 31517 31518 31519 31520 31521 31522 31523 31524 31525 31526 31527 31528 31529 31530 31531 31532 31533 31534 31535 31536 31537 31538 31539 31540 31541 31542 31543 31544 31545 31546 31547 31548 31549 31550 31551 31552 31553 31554 31555 31556 31557 31558 31559 31560 31561 31562 31563 31564 31565 31566 31567 31568 31569 31570 31571 31572 31573 31574 31575 31576 31577 31578 31579 31580 31581 31582 31583 31584 31585 31586 31587 31588 31589 31590 31591 31592 31593 31594 31595 31596 31597 31598 31599 31600 31601 31602 31603 31604 31605 31606 31607 31608 31609 31610 31611 31612 31613 31614 31615 31616 31617 31618 31619 31620 31621 31622 31623 31624 31625 31626 31627 31628 31629 31630 31631 31632 31633 31634 31635 31636 31637 31638 31639 31640 31641 31642 31643 31644 31645 31646 31647 31648 31649 31650 31651 31652 31653 31654 31655 31656 31657 31658 31659 31660 31661 31662 31663 31664 31665 31666 31667 31668 31669 31670 31671 31672 31673 31674 31675 31676 31677 31678 31679 31680 31681 31682 31683 31684 31685 31686 31687 31688 31689 31690 31691 31692 31693 31694 31695 31696 31697 31698 31699 31700 31701 31702 31703 31704 31705 31706 31707 31708 31709 31710 31711 31712 31713 31714 31715 31716 31717 31718 31719 31720 31721 31722 31723 31724 31725 31726 31727 31728 31729 31730 31731 31732 31733 31734 31735 31736 31737 31738 31739 31740 31741 31742 31743 31744 31745 31746 31747 31748 31749 31750 31751 31752 31753 31754 31755 31756 31757 31758 31759 31760 31761 31762 31763 31764 31765 31766 31767 31768 31769 31770 31771 31772 31773 31774 31775 31776 31777 31778 31779 31780 31781 31782 31783 31784 31785 31786 31787 31788 31789 31790 31791 31792 31793 31794 31795 31796 31797 31798 31799 31800 31801 31802 31803 31804 31805 31806 31807 31808 31809 31810 31811 31812 31813 31814 31815 31816 31817 31818 31819 31820 31821 31822 31823 31824 31825 31826 31827 31828 31829 31830 31831 31832 31833 31834 31835 31836 31837 31838 31839 31840 31841 31842 31843 31844 31845 31846 31847 31848 31849 31850 31851 31852 31853 31854 31855 31856 31857 31858 31859 31860 31861 31862 31863 31864 31865 31866 31867 31868 31869 31870 31871 31872 31873 31874 31875 31876 31877 31878 31879 31880 31881 31882 31883 31884 31885 31886 31887 31888 31889 31890 31891 31892 31893 31894 31895 31896 31897 31898 31899 31900 31901 31902 31903 31904 31905 31906 31907 31908 31909 31910 31911 31912 31913 31914 31915 31916 31917 31918 31919 31920 31921 31922 31923 31924 31925 31926 31927 31928 31929 31930 31931 31932 31933 31934 31935 31936 31937 31938 31939 31940 31941 31942 31943 31944 31945 31946 31947 31948 31949 31950 31951 31952 31953 31954 31955 31956 31957 31958 31959 31960 31961 31962 31963 31964 31965 31966 31967 31968 31969 31970 31971 31972 31973 31974 31975 31976 31977 31978 31979 31980 31981 31982 31983 31984 31985 31986 31987 31988 31989 31990 31991 31992 31993 31994 31995 31996 31997 31998 31999 32000 32001 32002 32003 32004 32005 32006 32007 32008 32009 32010 32011 32012 32013 32014 32015 32016 32017 32018 32019 32020 32021 32022 32023 32024 32025 32026 32027 32028 32029 32030 32031 32032 32033 32034 32035 32036 32037 32038 32039 32040 32041 32042 32043 32044 32045 32046 32047 32048 32049 32050 32051 32052 32053 32054 32055 32056 32057 32058 32059 32060 32061 32062 32063 32064 32065 32066 32067 32068 32069 32070 32071 32072 32073 32074 32075 32076 32077 32078 32079 32080 32081 32082 32083 32084 32085 32086 32087 32088 32089 32090 32091 32092 32093 32094 32095 32096 32097 32098 32099 32100 32101 32102 32103 32104 32105 32106 32107 32108 32109 32110 32111 32112 32113 32114 32115 32116 32117 32118 32119 32120 32121 32122 32123 32124 32125 32126 32127 32128 32129 32130 32131 32132 32133 32134 32135 32136 32137 32138 32139 32140 32141 32142 32143 32144 32145 32146 32147 32148 32149 32150 32151 32152 32153 32154 32155 32156 32157 32158 32159 32160 32161 32162 32163 32164 32165 32166 32167 32168 32169 32170 32171 32172 32173 32174 32175 32176 32177 32178 32179 32180 32181 32182 32183 32184 32185 32186 32187 32188 32189 32190 32191 32192 32193 32194 32195 32196 32197 32198 32199 32200 32201 32202 32203 32204 32205 32206 32207 32208 32209 32210 32211 32212 32213 32214 32215 32216 32217 32218 32219 32220 32221 32222 32223 32224 32225 32226 32227 32228 32229 32230 32231 32232 32233 32234 32235 32236 32237 32238 32239 32240 32241 32242 32243 32244 32245 32246 32247 32248 32249 32250 32251 32252 32253 32254 32255 32256 32257 32258 32259 32260 32261 32262 32263 32264 32265 32266 32267 32268 32269 32270 32271 32272 32273 32274 32275 32276 32277 32278 32279 32280 32281 32282 32283 32284 32285 32286 32287 32288 32289 32290 32291 32292 32293 32294 32295 32296 32297 32298 32299 32300 32301 32302 32303 32304 32305 32306 32307 32308 32309 32310 32311 32312 32313 32314 32315 32316 32317 32318 32319 32320 32321 32322 32323 32324 32325 32326 32327 32328 32329 32330 32331 32332 32333 32334 32335 32336 32337 32338 32339 32340 32341 32342 32343 32344 32345 32346 32347 32348 32349 32350 32351 32352 32353 32354 32355 32356 32357 32358 32359 32360 32361 32362 32363 32364 32365 32366 32367 32368 32369 32370 32371 32372 32373 32374 32375 32376 32377 32378 32379 32380 32381 32382 32383 32384 32385 32386 32387 32388 32389 32390 32391 32392 32393 32394 32395 32396 32397 32398 32399 32400 32401 32402 32403 32404 32405 32406 32407 32408 32409 32410 32411 32412 32413 32414 32415 32416 32417 32418 32419 32420 32421 32422 32423 32424 32425 32426 32427 32428 32429 32430 32431 32432 32433 32434 32435 32436 32437 32438 32439 32440 32441 32442 32443 32444 32445 32446 32447 32448 32449 32450 32451 32452 32453 32454 32455 32456 32457 32458 32459 32460 32461 32462 32463 32464 32465 32466 32467 32468 32469 32470 32471 32472 32473 32474 32475 32476 32477 32478 32479 32480 32481 32482 32483 32484 32485 32486 32487 32488 32489 32490 32491 32492 32493 32494 32495 32496 32497 32498 32499 32500 32501 32502 32503 32504 32505 32506 32507 32508 32509 32510 32511 32512 32513 32514 32515 32516 32517 32518 32519 32520 32521 32522 32523 32524 32525 32526 32527 32528 32529 32530 32531 32532 32533 32534 32535 32536 32537 32538 32539 32540 32541 32542 32543 32544 32545 32546 32547 32548 32549 32550 32551 32552 32553 32554 32555 32556 32557 32558 32559 32560 32561 32562 32563 32564 32565 32566 32567 32568 32569 32570 32571 32572 32573 32574 32575 32576 32577 32578 32579 32580 32581 32582 32583 32584 32585 32586 32587 32588 32589 32590 32591 32592 32593 32594 32595 32596 32597 32598 32599 32600 32601 32602 32603 32604 32605 32606 32607 32608 32609 32610 32611 32612 32613 32614 32615 32616 32617 32618 32619 32620 32621 32622 32623 32624 32625 32626 32627 32628 32629 32630 32631 32632 32633 32634 32635 32636 32637 32638 32639 32640 32641 32642 32643 32644 32645 32646 32647 32648 32649 32650 32651 32652 32653 32654 32655 32656 32657 32658 32659 32660 32661 32662 32663 32664 32665 32666 32667 32668 32669 32670 32671 32672 32673 32674 32675 32676 32677 32678 32679 32680 32681 32682 32683 32684 32685 32686 32687 32688 32689 32690 32691 32692 32693 32694 32695 32696 32697 32698 32699 32700 32701 32702 32703 32704 32705 32706 32707 32708 32709 32710 32711 32712 32713 32714 32715 32716 32717 32718 32719 32720 32721 32722 32723 32724 32725 32726 32727 32728 32729 32730 32731 32732 32733 32734 32735 32736 32737 32738 32739 32740 32741 32742 32743 32744 32745 32746 32747 32748 32749 32750 32751 32752 32753 32754 32755 32756 32757 32758 32759 32760 32761 32762 32763 32764 32765 32766 32767 32768 32769 32770 32771 32772 32773 32774 32775 32776 32777 32778 32779 32780 32781 32782 32783 32784 32785 32786 32787 32788 32789 32790 32791 32792 32793 32794 32795 32796 32797 32798 32799 32800 32801 32802 32803 32804 32805 32806 32807 32808 32809 32810 32811 32812 32813 32814 32815 32816 32817 32818 32819 32820 32821 32822 32823 32824 32825 32826 32827 32828 32829 32830 32831 32832 32833 32834 32835 32836 32837 32838 32839 32840 32841 32842 32843 32844 32845 32846 32847 32848 32849 32850 32851 32852 32853 32854 32855 32856 32857 32858 32859 32860 32861 32862 32863 32864 32865 32866 32867 32868 32869 32870 32871 32872 32873 32874 32875 32876 32877 32878 32879 32880 32881 32882 32883 32884 32885 32886 32887 32888 32889 32890 32891 32892 32893 32894 32895 32896 32897 32898 32899 32900 32901 32902 32903 32904 32905 32906 32907 32908 32909 32910 32911 32912 32913 32914 32915 32916 32917 32918 32919 32920 32921 32922 32923 32924 32925 32926 32927 32928 32929 32930 32931 32932 32933 32934 32935 32936 32937 32938 32939 32940 32941 32942 32943 32944 32945 32946 32947 32948 32949 32950 32951 32952 32953 32954 32955 32956 32957 32958 32959 32960 32961 32962 32963 32964 32965 32966 32967 32968 32969 32970 32971 32972 32973 32974 32975 32976 32977 32978 32979 32980 32981 32982 32983 32984 32985 32986 32987 32988 32989 32990 32991 32992 32993 32994 32995 32996 32997 32998 32999 33000 33001 33002 33003 33004 33005 33006 33007 33008 33009 33010 33011 33012 33013 33014 33015 33016 33017 33018 33019 33020 33021 33022 33023 33024 33025 33026 33027 33028 33029 33030 33031 33032 33033 33034 33035 33036 33037 33038 33039 33040 33041 33042 33043 33044 33045 33046 33047 33048 33049 33050 33051 33052 33053 33054 33055 33056 33057 33058 33059 33060 33061 33062 33063 33064 33065 33066 33067 33068 33069 33070 33071 33072 33073 33074 33075 33076 33077 33078 33079 33080 33081 33082 33083 33084 33085 33086 33087 33088 33089 33090 33091 33092 33093 33094 33095 33096 33097 33098 33099 33100 33101 33102 33103 33104 33105 33106 33107 33108 33109 33110 33111 33112 33113 33114 33115 33116 33117 33118 33119 33120 33121 33122 33123 33124 33125 33126 33127 33128 33129 33130 33131 33132 33133 33134 33135 33136 33137 33138 33139 33140 33141 33142 33143 33144 33145 33146 33147 33148 33149 33150 33151 33152 33153 33154 33155 33156 33157 33158 33159 33160 33161 33162 33163 33164 33165 33166 33167 33168 33169 33170 33171 33172 33173 33174 33175 33176 33177 33178 33179 33180 33181 33182 33183 33184 33185 33186 33187 33188 33189 33190 33191 33192 33193 33194 33195 33196 33197 33198 33199 33200 33201 33202 33203 33204 33205 33206 33207 33208 33209 33210 33211 33212 33213 33214 33215 33216 33217 33218 33219 33220 33221 33222 33223 33224 33225 33226 33227 33228 33229 33230 33231 33232 33233 33234 33235 33236 33237 33238 33239 33240 33241 33242 33243 33244 33245 33246 33247 33248 33249 33250 33251 33252 33253 33254 33255 33256 33257 33258 33259 33260 33261 33262 33263 33264 33265 33266 33267 33268 33269 33270 33271 33272 33273 33274 33275 33276 33277 33278 33279 33280 33281 33282 33283 33284 33285 33286 33287 33288 33289 33290 33291 33292 33293 33294 33295 33296 33297 33298 33299 33300 33301 33302 33303 33304 33305 33306 33307 33308 33309 33310 33311 33312 33313 33314 33315 33316 33317 33318 33319 33320 33321 33322 33323 33324 33325 33326 33327 33328 33329 33330 33331 33332 33333 33334 33335 33336 33337 33338 33339 33340 33341 33342 33343 33344 33345 33346 33347 33348 33349 33350 33351 33352 33353 33354 33355 33356 33357 33358 33359 33360 33361 33362 33363 33364 33365 33366 33367 33368 33369 33370 33371 33372 33373 33374 33375 33376 33377 33378 33379 33380 33381 33382 33383 33384 33385 33386 33387 33388 33389 33390 33391 33392 33393 33394 33395 33396 33397 33398 33399 33400 33401 33402 33403 33404 33405 33406 33407 33408 33409 33410 33411 33412 33413 33414 33415 33416 33417 33418 33419 33420 33421 33422 33423 33424 33425 33426 33427 33428 33429 33430 33431 33432 33433 33434 33435 33436 33437 33438 33439 33440 33441 33442 33443 33444 33445 33446 33447 33448 33449 33450 33451 33452 33453 33454 33455 33456 33457 33458 33459 33460 33461 33462 33463 33464 33465 33466 33467 33468 33469 33470 33471 33472 33473 33474 33475 33476 33477 33478 33479 33480 33481 33482 33483 33484 33485 33486 33487 33488 33489 33490 33491 33492 33493 33494 33495 33496 33497 33498 33499 33500 33501 33502 33503 33504 33505 33506 33507 33508 33509 33510 33511 33512 33513 33514 33515 33516 33517 33518 33519 33520 33521 33522 33523 33524 33525 33526 33527 33528 33529 33530 33531 33532 33533 33534 33535 33536 33537 33538 33539 33540 33541 33542 33543 33544 33545 33546 33547 33548 33549 33550 33551 33552 33553 33554 33555 33556 33557 33558 33559 33560 33561 33562 33563 33564 33565 33566 33567 33568 33569 33570 33571 33572 33573 33574 33575 33576 33577 33578 33579 33580 33581 33582 33583 33584 33585 33586 33587 33588 33589 33590 33591 33592 33593 33594 33595 33596 33597 33598 33599 33600 33601 33602 33603 33604 33605 33606 33607 33608 33609 33610 33611 33612 33613 33614 33615 33616 33617 33618 33619 33620 33621 33622 33623 33624 33625 33626 33627 33628 33629 33630 33631 33632 33633 33634 33635 33636 33637 33638 33639 33640 33641 33642 33643 33644 33645 33646 33647 33648 33649 33650 33651 33652 33653 33654 33655 33656 33657 33658 33659 33660 33661 33662 33663 33664 33665 33666 33667 33668 33669 33670 33671 33672 33673 33674 33675 33676 33677 33678 33679 33680 33681 33682 33683 33684 33685 33686 33687 33688 33689 33690 33691 33692 33693 33694 33695 33696 33697 33698 33699 33700 33701 33702 33703 33704 33705 33706 33707 33708 33709 33710 33711 33712 33713 33714 33715 33716 33717 33718 33719 33720 33721 33722 33723 33724 33725 33726 33727 33728 33729 33730 33731 33732 33733 33734 33735 33736 33737 33738 33739 33740 33741 33742 33743 33744 33745 33746 33747 33748 33749 33750 33751 33752 33753 33754 33755 33756 33757 33758 33759 33760 33761 33762 33763 33764 33765 33766 33767 33768 33769 33770 33771 33772 33773 33774 33775 33776 33777 33778 33779 33780 33781 33782 33783 33784 33785 33786 33787 33788 33789 33790 33791 33792 33793 33794 33795 33796 33797 33798 33799 33800 33801 33802 33803 33804 33805 33806 33807 33808 33809 33810 33811 33812 33813 33814 33815 33816 33817 33818 33819 33820 33821 33822 33823 33824 33825 33826 33827 33828 33829 33830 33831 33832 33833 33834 33835 33836 33837 33838 33839 33840 33841 33842 33843 33844 33845 33846 33847 33848 33849 33850 33851 33852 33853 33854 33855 33856 33857 33858 33859 33860 33861 33862 33863 33864 33865 33866 33867 33868 33869 33870 33871 33872 33873 33874 33875 33876 33877 33878 33879 33880 33881 33882 33883 33884 33885 33886 33887 33888 33889 33890 33891 33892 33893 33894 33895 33896 33897 33898 33899 33900 33901 33902 33903 33904 33905 33906 33907 33908 33909 33910 33911 33912 33913 33914 33915 33916 33917 33918 33919 33920 33921 33922 33923 33924 33925 33926 33927 33928 33929 33930 33931 33932 33933 33934 33935 33936 33937 33938 33939 33940 33941 33942 33943 33944 33945 33946 33947 33948 33949 33950 33951 33952 33953 33954 33955 33956 33957 33958 33959 33960 33961 33962 33963 33964 33965 33966 33967 33968 33969 33970 33971 33972 33973 33974 33975 33976 33977 33978 33979 33980 33981 33982 33983 33984 33985 33986 33987 33988 33989 33990 33991 33992 33993 33994 33995 33996 33997 33998 33999 34000 34001 34002 34003 34004 34005 34006 34007 34008 34009 34010 34011 34012 34013 34014 34015 34016 34017 34018 34019 34020 34021 34022 34023 34024 34025 34026 34027 34028 34029 34030 34031 34032 34033 34034 34035 34036 34037 34038 34039 34040 34041 34042 34043 34044 34045 34046 34047 34048 34049 34050 34051 34052 34053 34054 34055 34056 34057 34058 34059 34060 34061 34062 34063 34064 34065 34066 34067 34068 34069 34070 34071 34072 34073 34074 34075 34076 34077 34078 34079 34080 34081 34082 34083 34084 34085 34086 34087 34088 34089 34090 34091 34092 34093 34094 34095 34096 34097 34098 34099 34100 34101 34102 34103 34104 34105 34106 34107 34108 34109 34110 34111 34112 34113 34114 34115 34116 34117 34118 34119 34120 34121 34122 34123 34124 34125 34126 34127 34128 34129 34130 34131 34132 34133 34134 34135 34136 34137 34138 34139 34140 34141 34142 34143 34144 34145 34146 34147 34148 34149 34150 34151 34152 34153 34154 34155 34156 34157 34158 34159 34160 34161 34162 34163 34164 34165 34166 34167 34168 34169 34170 34171 34172 34173 34174 34175 34176 34177 34178 34179 34180 34181 34182 34183 34184 34185 34186 34187 34188 34189 34190 34191 34192 34193 34194 34195 34196 34197 34198 34199 34200 34201 34202 34203 34204 34205 34206 34207 34208 34209 34210 34211 34212 34213 34214 34215 34216 34217 34218 34219 34220 34221 34222 34223 34224 34225 34226 34227 34228 34229 34230 34231 34232 34233 34234 34235 34236 34237 34238 34239 34240 34241 34242 34243 34244 34245 34246 34247 34248 34249 34250 34251 34252 34253 34254 34255 34256 34257 34258 34259 34260 34261 34262 34263 34264 34265 34266 34267 34268 34269 34270 34271 34272 34273 34274 34275 34276 34277 34278 34279 34280 34281 34282 34283 34284 34285 34286 34287 34288 34289 34290 34291 34292 34293 34294 34295 34296 34297 34298 34299 34300 34301 34302 34303 34304 34305 34306 34307 34308 34309 34310 34311 34312 34313 34314 34315 34316 34317 34318 34319 34320 34321 34322 34323 34324 34325 34326 34327 34328 34329 34330 34331 34332 34333 34334 34335 34336 34337 34338 34339 34340 34341 34342 34343 34344 34345 34346 34347 34348 34349 34350 34351 34352 34353 34354 34355 34356 34357 34358 34359 34360 34361 34362 34363 34364 34365 34366 34367 34368 34369 34370 34371 34372 34373 34374 34375 34376 34377 34378 34379 34380 34381 34382 34383 34384 34385 34386 34387 34388 34389 34390 34391 34392 34393 34394 34395 34396 34397 34398 34399 34400 34401 34402 34403 34404 34405 34406 34407 34408 34409 34410 34411 34412 34413 34414 34415 34416 34417 34418 34419 34420 34421 34422 34423 34424 34425 34426 34427 34428 34429 34430 34431 34432 34433 34434 34435 34436 34437 34438 34439 34440 34441 34442 34443 34444 34445 34446 34447 34448 34449 34450 34451 34452 34453 34454 34455 34456 34457 34458 34459 34460 34461 34462 34463 34464 34465 34466 34467 34468 34469 34470 34471 34472 34473 34474 34475 34476 34477 34478 34479 34480 34481 34482 34483 34484 34485 34486 34487 34488 34489 34490 34491 34492 34493 34494 34495 34496 34497 34498 34499 34500 34501 34502 34503 34504 34505 34506 34507 34508 34509 34510 34511 34512 34513 34514 34515 34516 34517 34518 34519 34520 34521 34522 34523 34524 34525 34526 34527 34528 34529 34530 34531 34532 34533 34534 34535 34536 34537 34538 34539 34540 34541 34542 34543 34544 34545 34546 34547 34548 34549 34550 34551 34552 34553 34554 34555 34556 34557 34558 34559 34560 34561 34562 34563 34564 34565 34566 34567 34568 34569 34570 34571 34572 34573 34574 34575 34576 34577 34578 34579 34580 34581 34582 34583 34584 34585 34586 34587 34588 34589 34590 34591 34592 34593 34594 34595 34596 34597 34598 34599 34600 34601 34602 34603 34604 34605 34606 34607 34608 34609 34610 34611 34612 34613 34614 34615 34616 34617 34618 34619 34620 34621 34622 34623 34624 34625 34626 34627 34628 34629 34630 34631 34632 34633 34634 34635 34636 34637 34638 34639 34640 34641 34642 34643 34644 34645 34646 34647 34648 34649 34650 34651 34652 34653 34654 34655 34656 34657 34658 34659 34660 34661 34662 34663 34664 34665 34666 34667 34668 34669 34670 34671 34672 34673 34674 34675 34676 34677 34678 34679 34680 34681 34682 34683 34684 34685 34686 34687 34688 34689 34690 34691 34692 34693 34694 34695 34696 34697 34698 34699 34700 34701 34702 34703 34704 34705 34706 34707 34708 34709 34710 34711 34712 34713 34714 34715 34716 34717 34718 34719 34720 34721 34722 34723 34724 34725 34726 34727 34728 34729 34730 34731 34732 34733 34734 34735 34736 34737 34738 34739 34740 34741 34742 34743 34744 34745 34746 34747 34748 34749 34750 34751 34752 34753 34754 34755 34756 34757 34758 34759 34760 34761 34762 34763 34764 34765 34766 34767 34768 34769 34770 34771 34772 34773 34774 34775 34776 34777 34778 34779 34780 34781 34782 34783 34784 34785 34786 34787 34788 34789 34790 34791 34792 34793 34794 34795 34796 34797 34798 34799 34800 34801 34802 34803 34804 34805 34806 34807 34808 34809 34810 34811 34812 34813 34814 34815 34816 34817 34818 34819 34820 34821 34822 34823 34824 34825 34826 34827 34828 34829 34830 34831 34832 34833 34834 34835 34836 34837 34838 34839 34840 34841 34842 34843 34844 34845 34846 34847 34848 34849 34850 34851 34852 34853 34854 34855 34856 34857 34858 34859 34860 34861 34862 34863 34864 34865 34866 34867 34868 34869 34870 34871 34872 34873 34874 34875 34876 34877 34878 34879 34880 34881 34882 34883 34884 34885 34886 34887 34888 34889 34890 34891 34892 34893 34894 34895 34896 34897 34898 34899 34900 34901 34902 34903 34904 34905 34906 34907 34908 34909 34910 34911 34912 34913 34914 34915 34916 34917 34918 34919 34920 34921 34922 34923 34924 34925 34926 34927 34928 34929 34930 34931 34932 34933 34934 34935 34936 34937 34938 34939 34940 34941 34942 34943 34944 34945 34946 34947 34948 34949 34950 34951 34952 34953 34954 34955 34956 34957 34958 34959 34960 34961 34962 34963 34964 34965 34966 34967 34968 34969 34970 34971 34972 34973 34974 34975 34976 34977 34978 34979 34980 34981 34982 34983 34984 34985 34986 34987 34988 34989 34990 34991 34992 34993 34994 34995 34996 34997 34998 34999 35000 35001 35002 35003 35004 35005 35006 35007 35008 35009 35010 35011 35012 35013 35014 35015 35016 35017 35018 35019 35020 35021 35022 35023 35024 35025 35026 35027 35028 35029 35030 35031 35032 35033 35034 35035 35036 35037 35038 35039 35040 35041 35042 35043 35044 35045 35046 35047 35048 35049 35050 35051 35052 35053 35054 35055 35056 35057 35058 35059 35060 35061 35062 35063 35064 35065 35066 35067 35068 35069 35070 35071 35072 35073 35074 35075 35076 35077 35078 35079 35080 35081 35082 35083 35084 35085 35086 35087 35088 35089 35090 35091 35092 35093 35094 35095 35096 35097 35098 35099 35100 35101 35102 35103 35104 35105 35106 35107 35108 35109 35110 35111 35112 35113 35114 35115 35116 35117 35118 35119 35120 35121 35122 35123 35124 35125 35126 35127 35128 35129 35130 35131 35132 35133 35134 35135 35136 35137 35138 35139 35140 35141 35142 35143 35144 35145 35146 35147 35148 35149 35150 35151 35152 35153 35154 35155 35156 35157 35158 35159 35160 35161 35162 35163 35164 35165 35166 35167 35168 35169 35170 35171 35172 35173 35174 35175 35176 35177 35178 35179 35180 35181 35182 35183 35184 35185 35186 35187 35188 35189 35190 35191 35192 35193 35194 35195 35196 35197 35198 35199 35200 35201 35202 35203 35204 35205 35206 35207 35208 35209 35210 35211 35212 35213 35214 35215 35216 35217 35218 35219 35220 35221 35222 35223 35224 35225 35226 35227 35228 35229 35230 35231 35232 35233 35234 35235 35236 35237 35238 35239 35240 35241 35242 35243 35244 35245 35246 35247 35248 35249 35250 35251 35252 35253 35254 35255 35256 35257 35258 35259 35260 35261 35262 35263 35264 35265 35266 35267 35268 35269 35270 35271 35272 35273 35274 35275 35276 35277 35278 35279 35280 35281 35282 35283 35284 35285 35286 35287 35288 35289 35290 35291 35292 35293 35294 35295 35296 35297 35298 35299 35300 35301 35302 35303 35304 35305 35306 35307 35308 35309 35310 35311 35312 35313 35314 35315 35316 35317 35318 35319 35320 35321 35322 35323 35324 35325 35326 35327 35328 35329 35330 35331 35332 35333 35334 35335 35336 35337 35338 35339 35340 35341 35342 35343 35344 35345 35346 35347 35348 35349 35350 35351 35352 35353 35354 35355 35356 35357 35358 35359 35360 35361 35362 35363 35364 35365 35366 35367 35368 35369 35370 35371 35372 35373 35374 35375 35376 35377 35378 35379 35380 35381 35382 35383 35384 35385 35386 35387 35388 35389 35390 35391 35392 35393 35394 35395 35396 35397 35398 35399 35400 35401 35402 35403 35404 35405 35406 35407 35408 35409 35410 35411 35412 35413 35414 35415 35416 35417 35418 35419 35420 35421 35422 35423 35424 35425 35426 35427 35428 35429 35430 35431 35432 35433 35434 35435 35436 35437 35438 35439 35440 35441 35442 35443 35444 35445 35446 35447 35448 35449 35450 35451 35452 35453 35454 35455 35456 35457 35458 35459 35460 35461 35462 35463 35464 35465 35466 35467 35468 35469 35470 35471 35472 35473 35474 35475 35476 35477 35478 35479 35480 35481 35482 35483 35484 35485 35486 35487 35488 35489 35490 35491 35492 35493 35494 35495 35496 35497 35498 35499 35500 35501 35502 35503 35504 35505 35506 35507 35508 35509 35510 35511 35512 35513 35514 35515 35516 35517 35518 35519 35520 35521 35522 35523 35524 35525 35526 35527 35528 35529 35530 35531 35532 35533 35534 35535 35536 35537 35538 35539 35540 35541 35542 35543 35544 35545 35546 35547 35548 35549 35550 35551 35552 35553 35554 35555 35556 35557 35558 35559 35560 35561 35562 35563 35564 35565 35566 35567 35568 35569 35570 35571 35572 35573 35574 35575 35576 35577 35578 35579 35580 35581 35582 35583 35584 35585 35586 35587 35588 35589 35590 35591 35592 35593 35594 35595 35596 35597 35598 35599 35600 35601 35602 35603 35604 35605 35606 35607 35608 35609 35610 35611 35612 35613 35614 35615 35616 35617 35618 35619 35620 35621 35622 35623 35624 35625 35626 35627 35628 35629 35630 35631 35632 35633 35634 35635 35636 35637 35638 35639 35640 35641 35642 35643 35644 35645 35646 35647 35648 35649 35650 35651 35652 35653 35654 35655 35656 35657 35658 35659 35660 35661 35662 35663 35664 35665 35666 35667 35668 35669 35670 35671 35672 35673 35674 35675 35676 35677 35678 35679 35680 35681 35682 35683 35684 35685 35686 35687 35688 35689 35690 35691 35692 35693 35694 35695 35696 35697 35698 35699 35700 35701 35702 35703 35704 35705 35706 35707 35708 35709 35710 35711 35712 35713 35714 35715 35716 35717 35718 35719 35720 35721 35722 35723 35724 35725 35726 35727 35728 35729 35730 35731 35732 35733 35734 35735 35736 35737 35738 35739 35740 35741 35742 35743 35744 35745 35746 35747 35748 35749 35750 35751 35752 35753 35754 35755 35756 35757 35758 35759 35760 35761 35762 35763 35764 35765 35766 35767 35768 35769 35770 35771 35772 35773 35774 35775 35776 35777 35778 35779 35780 35781 35782 35783 35784 35785 35786 35787 35788 35789 35790 35791 35792 35793 35794 35795 35796 35797 35798 35799 35800 35801 35802 35803 35804 35805 35806 35807 35808 35809 35810 35811 35812 35813 35814 35815 35816 35817 35818 35819 35820 35821 35822 35823 35824 35825 35826 35827 35828 35829 35830 35831 35832 35833 35834 35835 35836 35837 35838 35839 35840 35841 35842 35843 35844 35845 35846 35847 35848 35849 35850 35851 35852 35853 35854 35855 35856 35857 35858 35859 35860 35861 35862 35863 35864 35865 35866 35867 35868 35869 35870 35871 35872 35873 35874 35875 35876 35877 35878 35879 35880 35881 35882 35883 35884 35885 35886 35887 35888 35889 35890 35891 35892 35893 35894 35895 35896 35897 35898 35899 35900 35901 35902 35903 35904 35905 35906 35907 35908 35909 35910 35911 35912 35913 35914 35915 35916 35917 35918 35919 35920 35921 35922 35923 35924 35925 35926 35927 35928 35929 35930 35931 35932 35933 35934 35935 35936 35937 35938 35939 35940 35941 35942 35943 35944 35945 35946 35947 35948 35949 35950 35951 35952 35953 35954 35955 35956 35957 35958 35959 35960 35961 35962 35963 35964 35965 35966 35967 35968 35969 35970 35971 35972 35973 35974 35975 35976 35977 35978 35979 35980 35981 35982 35983 35984 35985 35986 35987 35988 35989 35990 35991 35992 35993 35994 35995 35996 35997 35998 35999 36000 36001 36002 36003 36004 36005 36006 36007 36008 36009 36010 36011 36012 36013 36014 36015 36016 36017 36018 36019 36020 36021 36022 36023 36024 36025 36026 36027 36028 36029 36030 36031 36032 36033 36034 36035 36036 36037 36038 36039 36040 36041 36042 36043 36044 36045 36046 36047 36048 36049 36050 36051 36052 36053 36054 36055 36056 36057 36058 36059 36060 36061 36062 36063 36064 36065 36066 36067 36068 36069 36070 36071 36072 36073 36074 36075 36076 36077 36078 36079 36080 36081 36082 36083 36084 36085 36086 36087 36088 36089 36090 36091 36092 36093 36094 36095 36096 36097 36098 36099 36100 36101 36102 36103 36104 36105 36106 36107 36108 36109 36110 36111 36112 36113 36114 36115 36116 36117 36118 36119 36120 36121 36122 36123 36124 36125 36126 36127 36128 36129 36130 36131 36132 36133 36134 36135 36136 36137 36138 36139 36140 36141 36142 36143 36144 36145 36146 36147 36148 36149 36150 36151 36152 36153 36154 36155 36156 36157 36158 36159 36160 36161 36162 36163 36164 36165 36166 36167 36168 36169 36170 36171 36172 36173 36174 36175 36176 36177 36178 36179 36180 36181 36182 36183 36184 36185 36186 36187 36188 36189 36190 36191 36192 36193 36194 36195 36196 36197 36198 36199 36200 36201 36202 36203 36204 36205 36206 36207 36208 36209 36210 36211 36212 36213 36214 36215 36216 36217 36218 36219 36220 36221 36222 36223 36224 36225 36226 36227 36228 36229 36230 36231 36232 36233 36234 36235 36236 36237 36238 36239 36240 36241 36242 36243 36244 36245 36246 36247 36248 36249 36250 36251 36252 36253 36254 36255 36256 36257 36258 36259 36260 36261 36262 36263 36264 36265 36266 36267 36268 36269 36270 36271 36272 36273 36274 36275 36276 36277 36278 36279 36280 36281 36282 36283 36284 36285 36286 36287 36288 36289 36290 36291 36292 36293 36294 36295 36296 36297 36298 36299 36300 36301 36302 36303 36304 36305 36306 36307 36308 36309 36310 36311 36312 36313 36314 36315 36316 36317 36318 36319 36320 36321 36322 36323 36324 36325 36326 36327 36328 36329 36330 36331 36332 36333 36334 36335 36336 36337 36338 36339 36340 36341 36342 36343 36344 36345 36346 36347 36348 36349 36350 36351 36352 36353 36354 36355 36356 36357 36358 36359 36360 36361 36362 36363 36364 36365 36366 36367 36368 36369 36370 36371 36372 36373 36374 36375 36376 36377 36378 36379 36380 36381 36382 36383 36384 36385 36386 36387 36388 36389 36390 36391 36392 36393 36394 36395 36396 36397 36398 36399 36400 36401 36402 36403 36404 36405 36406 36407 36408 36409 36410 36411 36412 36413 36414 36415 36416 36417 36418 36419 36420 36421 36422 36423 36424 36425 36426 36427 36428 36429 36430 36431 36432 36433 36434 36435 36436 36437 36438 36439 36440 36441 36442 36443 36444 36445 36446 36447 36448 36449 36450 36451 36452 36453 36454 36455 36456 36457 36458 36459 36460 36461 36462 36463 36464 36465 36466 36467 36468 36469 36470 36471 36472 36473 36474 36475 36476 36477 36478 36479 36480 36481 36482 36483 36484 36485 36486 36487 36488 36489 36490 36491 36492 36493 36494 36495 36496 36497 36498 36499 36500 36501 36502 36503 36504 36505 36506 36507 36508 36509 36510 36511 36512 36513 36514 36515 36516 36517 36518 36519 36520 36521 36522 36523 36524 36525 36526 36527 36528 36529 36530 36531 36532 36533 36534 36535 36536 36537 36538 36539 36540 36541 36542 36543 36544 36545 36546 36547 36548 36549 36550 36551 36552 36553 36554 36555 36556 36557 36558 36559 36560 36561 36562 36563 36564 36565 36566 36567 36568 36569 36570 36571 36572 36573 36574 36575 36576 36577 36578 36579 36580 36581 36582 36583 36584 36585 36586 36587 36588 36589 36590 36591 36592 36593 36594 36595 36596 36597 36598 36599 36600 36601 36602 36603 36604 36605 36606 36607 36608 36609 36610 36611 36612 36613 36614 36615 36616 36617 36618 36619 36620 36621 36622 36623 36624 36625 36626 36627 36628 36629 36630 36631 36632 36633 36634 36635 36636 36637 36638 36639 36640 36641 36642 36643 36644 36645 36646 36647 36648 36649 36650 36651 36652 36653 36654 36655 36656 36657 36658 36659 36660 36661 36662 36663 36664 36665 36666 36667 36668 36669 36670 36671 36672 36673 36674 36675 36676 36677 36678 36679 36680 36681 36682 36683 36684 36685 36686 36687 36688 36689 36690 36691 36692 36693 36694 36695 36696 36697 36698 36699 36700 36701 36702 36703 36704 36705 36706 36707 36708 36709 36710 36711 36712 36713 36714 36715 36716 36717 36718 36719 36720 36721 36722 36723 36724 36725 36726 36727 36728 36729 36730 36731 36732 36733 36734 36735 36736 36737 36738 36739 36740 36741 36742 36743 36744 36745 36746 36747 36748 36749 36750 36751 36752 36753 36754 36755 36756 36757 36758 36759 36760 36761 36762 36763 36764 36765 36766 36767 36768 36769 36770 36771 36772 36773 36774 36775 36776 36777 36778 36779 36780 36781 36782 36783 36784 36785 36786 36787 36788 36789 36790 36791 36792 36793 36794 36795 36796 36797 36798 36799 36800 36801 36802 36803 36804 36805 36806 36807 36808 36809 36810 36811 36812 36813 36814 36815 36816 36817 36818 36819 36820 36821 36822 36823 36824 36825 36826 36827 36828 36829 36830 36831 36832 36833 36834 36835 36836 36837 36838 36839 36840 36841 36842 36843 36844 36845 36846 36847 36848 36849 36850 36851 36852 36853 36854 36855 36856 36857 36858 36859 36860 36861 36862 36863 36864 36865 36866 36867 36868 36869 36870 36871 36872 36873 36874 36875 36876 36877 36878 36879 36880 36881 36882 36883 36884 36885 36886 36887 36888 36889 36890 36891 36892 36893 36894 36895 36896 36897 36898 36899 36900 36901 36902 36903 36904 36905 36906 36907 36908 36909 36910 36911 36912 36913 36914 36915 36916 36917 36918 36919 36920 36921 36922 36923 36924 36925 36926 36927 36928 36929 36930 36931 36932 36933 36934 36935 36936 36937 36938 36939 36940 36941 36942 36943 36944 36945 36946 36947 36948 36949 36950 36951 36952 36953 36954 36955 36956 36957 36958 36959 36960 36961 36962 36963 36964 36965 36966 36967 36968 36969 36970 36971 36972 36973 36974 36975 36976 36977 36978 36979 36980 36981 36982 36983 36984 36985 36986 36987 36988 36989 36990 36991 36992 36993 36994 36995 36996 36997 36998 36999 37000 37001 37002 37003 37004 37005 37006 37007 37008 37009 37010 37011 37012 37013 37014 37015 37016 37017 37018 37019 37020 37021 37022 37023 37024 37025 37026 37027 37028 37029 37030 37031 37032 37033 37034 37035 37036 37037 37038 37039 37040 37041 37042 37043 37044 37045 37046 37047 37048 37049 37050 37051 37052 37053 37054 37055 37056 37057 37058 37059 37060 37061 37062 37063 37064 37065 37066 37067 37068 37069 37070 37071 37072 37073 37074 37075 37076 37077 37078 37079 37080 37081 37082 37083 37084 37085 37086 37087 37088 37089 37090 37091 37092 37093 37094 37095 37096 37097 37098 37099 37100 37101 37102 37103 37104 37105 37106 37107 37108 37109 37110 37111 37112 37113 37114 37115 37116 37117 37118 37119 37120 37121 37122 37123 37124 37125 37126 37127 37128 37129 37130 37131 37132 37133 37134 37135 37136 37137 37138 37139 37140 37141 37142 37143 37144 37145 37146 37147 37148 37149 37150 37151 37152 37153 37154 37155 37156 37157 37158 37159 37160 37161 37162 37163 37164 37165 37166 37167 37168 37169 37170 37171 37172 37173 37174 37175 37176 37177 37178 37179 37180 37181 37182 37183 37184 37185 37186 37187 37188 37189 37190 37191 37192 37193 37194 37195 37196 37197 37198 37199 37200 37201 37202 37203 37204 37205 37206 37207 37208 37209 37210 37211 37212 37213 37214 37215 37216 37217 37218 37219 37220 37221 37222 37223 37224 37225 37226 37227 37228 37229 37230 37231 37232 37233 37234 37235 37236 37237 37238 37239 37240 37241 37242 37243 37244 37245 37246 37247 37248 37249 37250 37251 37252 37253 37254 37255 37256 37257 37258 37259 37260 37261 37262 37263 37264 37265 37266 37267 37268 37269 37270 37271 37272 37273 37274 37275 37276 37277 37278 37279 37280 37281 37282 37283 37284 37285 37286 37287 37288 37289 37290 37291 37292 37293 37294 37295 37296 37297 37298 37299 37300 37301 37302 37303 37304 37305 37306 37307 37308 37309 37310 37311 37312 37313 37314 37315 37316 37317 37318 37319 37320 37321 37322 37323 37324 37325 37326 37327 37328 37329 37330 37331 37332 37333 37334 37335 37336 37337 37338 37339 37340 37341 37342 37343 37344 37345 37346 37347 37348 37349 37350 37351 37352 37353 37354 37355 37356 37357 37358 37359 37360 37361 37362 37363 37364 37365 37366 37367 37368 37369 37370 37371 37372 37373 37374 37375 37376 37377 37378 37379 37380 37381 37382 37383 37384 37385 37386 37387 37388 37389 37390 37391 37392 37393 37394 37395 37396 37397 37398 37399 37400 37401 37402 37403 37404 37405 37406 37407 37408 37409 37410 37411 37412 37413 37414 37415 37416 37417 37418 37419 37420 37421 37422 37423 37424 37425 37426 37427 37428 37429 37430 37431 37432 37433 37434 37435 37436 37437 37438 37439 37440 37441 37442 37443 37444 37445 37446 37447 37448 37449 37450 37451 37452 37453 37454 37455 37456 37457 37458 37459 37460 37461 37462 37463 37464 37465 37466 37467 37468 37469 37470 37471 37472 37473 37474 37475 37476 37477 37478 37479 37480 37481 37482 37483 37484 37485 37486 37487 37488 37489 37490 37491 37492 37493 37494 37495 37496 37497 37498 37499 37500 37501 37502 37503 37504 37505 37506 37507 37508 37509 37510 37511 37512 37513 37514 37515 37516 37517 37518 37519 37520 37521 37522 37523 37524 37525 37526 37527 37528 37529 37530 37531 37532 37533 37534 37535 37536 37537 37538 37539 37540 37541 37542 37543 37544 37545 37546 37547 37548 37549 37550 37551 37552 37553 37554 37555 37556 37557 37558 37559 37560 37561 37562 37563 37564 37565 37566 37567 37568 37569 37570 37571 37572 37573 37574 37575 37576 37577 37578 37579 37580 37581 37582 37583 37584 37585 37586 37587 37588 37589 37590 37591 37592 37593 37594 37595 37596 37597 37598 37599 37600 37601 37602 37603 37604 37605 37606 37607 37608 37609 37610 37611 37612 37613 37614 37615 37616 37617 37618 37619 37620 37621 37622 37623 37624 37625 37626 37627 37628 37629 37630 37631 37632 37633 37634 37635 37636 37637 37638 37639 37640 37641 37642 37643 37644 37645 37646 37647 37648 37649 37650 37651 37652 37653 37654 37655 37656 37657 37658 37659 37660 37661 37662 37663 37664 37665 37666 37667 37668 37669 37670 37671 37672 37673 37674 37675 37676 37677 37678 37679 37680 37681 37682 37683 37684 37685 37686 37687 37688 37689 37690 37691 37692 37693 37694 37695 37696 37697 37698 37699 37700 37701 37702 37703 37704 37705 37706 37707 37708 37709 37710 37711 37712 37713 37714 37715 37716 37717 37718 37719 37720 37721 37722 37723 37724 37725 37726 37727 37728 37729 37730 37731 37732 37733 37734 37735 37736 37737 37738 37739 37740 37741 37742 37743 37744 37745 37746 37747 37748 37749 37750 37751 37752 37753 37754 37755 37756 37757 37758 37759 37760 37761 37762 37763 37764 37765 37766 37767 37768 37769 37770 37771 37772 37773 37774 37775 37776 37777 37778 37779 37780 37781 37782 37783 37784 37785 37786 37787 37788 37789 37790 37791 37792 37793 37794 37795 37796 37797 37798 37799 37800 37801 37802 37803 37804 37805 37806 37807 37808 37809 37810 37811 37812 37813 37814 37815 37816 37817 37818 37819 37820 37821 37822 37823 37824 37825 37826 37827 37828 37829 37830 37831 37832 37833 37834 37835 37836 37837 37838 37839 37840 37841 37842 37843 37844 37845 37846 37847 37848 37849 37850 37851 37852 37853 37854 37855 37856 37857 37858 37859 37860 37861 37862 37863 37864 37865 37866 37867 37868 37869 37870 37871 37872 37873 37874 37875 37876 37877 37878 37879 37880 37881 37882 37883 37884 37885 37886 37887 37888 37889 37890 37891 37892 37893 37894 37895 37896 37897 37898 37899 37900 37901 37902 37903 37904 37905 37906 37907 37908 37909 37910 37911 37912 37913 37914 37915 37916 37917 37918 37919 37920 37921 37922 37923 37924 37925 37926 37927 37928 37929 37930 37931 37932 37933 37934 37935 37936 37937 37938 37939 37940 37941 37942 37943 37944 37945 37946 37947 37948 37949 37950 37951 37952 37953 37954 37955 37956 37957 37958 37959 37960 37961 37962 37963 37964 37965 37966 37967 37968 37969 37970 37971 37972 37973 37974 37975 37976 37977 37978 37979 37980 37981 37982 37983 37984 37985 37986 37987 37988 37989 37990 37991 37992 37993 37994 37995 37996 37997 37998 37999 38000 38001 38002 38003 38004 38005 38006 38007 38008 38009 38010 38011 38012 38013 38014 38015 38016 38017 38018 38019 38020 38021 38022 38023 38024 38025 38026 38027 38028 38029 38030 38031 38032 38033 38034 38035 38036 38037 38038 38039 38040 38041 38042 38043 38044 38045 38046 38047 38048 38049 38050 38051 38052 38053 38054 38055 38056 38057 38058 38059 38060 38061 38062 38063 38064 38065 38066 38067 38068 38069 38070 38071 38072 38073 38074 38075 38076 38077 38078 38079 38080 38081 38082 38083 38084 38085 38086 38087 38088 38089 38090 38091 38092 38093 38094 38095 38096 38097 38098 38099 38100 38101 38102 38103 38104 38105 38106 38107 38108 38109 38110 38111 38112 38113 38114 38115 38116 38117 38118 38119 38120 38121 38122 38123 38124 38125 38126 38127 38128 38129 38130 38131 38132 38133 38134 38135 38136 38137 38138 38139 38140 38141 38142 38143 38144 38145 38146 38147 38148 38149 38150 38151 38152 38153 38154 38155 38156 38157 38158 38159 38160 38161 38162 38163 38164 38165 38166 38167 38168 38169 38170 38171 38172 38173 38174 38175 38176 38177 38178 38179 38180 38181 38182 38183 38184 38185 38186 38187 38188 38189 38190 38191 38192 38193 38194 38195 38196 38197 38198 38199 38200 38201 38202 38203 38204 38205 38206 38207 38208 38209 38210 38211 38212 38213 38214 38215 38216 38217 38218 38219 38220 38221 38222 38223 38224 38225 38226 38227 38228 38229 38230 38231 38232 38233 38234 38235 38236 38237 38238 38239 38240 38241 38242 38243 38244 38245 38246 38247 38248 38249 38250 38251 38252 38253 38254 38255 38256 38257 38258 38259 38260 38261 38262 38263 38264 38265 38266 38267 38268 38269 38270 38271 38272 38273 38274 38275 38276 38277 38278 38279 38280 38281 38282 38283 38284 38285 38286 38287 38288 38289 38290 38291 38292 38293 38294 38295 38296 38297 38298 38299 38300 38301 38302 38303 38304 38305 38306 38307 38308 38309 38310 38311 38312 38313 38314 38315 38316 38317 38318 38319 38320 38321 38322 38323 38324 38325 38326 38327 38328 38329 38330 38331 38332 38333 38334 38335 38336 38337 38338 38339 38340 38341 38342 38343 38344 38345 38346 38347 38348 38349 38350 38351 38352 38353 38354 38355 38356 38357 38358 38359 38360 38361 38362 38363 38364 38365 38366 38367 38368 38369 38370 38371 38372 38373 38374 38375 38376 38377 38378 38379 38380 38381 38382 38383 38384 38385 38386 38387 38388 38389 38390 38391 38392 38393 38394 38395 38396 38397 38398 38399 38400 38401 38402 38403 38404 38405 38406 38407 38408 38409 38410 38411 38412 38413 38414 38415 38416 38417 38418 38419 38420 38421 38422 38423 38424 38425 38426 38427 38428 38429 38430 38431 38432 38433 38434 38435 38436 38437 38438 38439 38440 38441 38442 38443 38444 38445 38446 38447 38448 38449 38450 38451 38452 38453 38454 38455 38456 38457 38458 38459 38460 38461 38462 38463 38464 38465 38466 38467 38468 38469 38470 38471 38472 38473 38474 38475 38476 38477 38478 38479 38480 38481 38482 38483 38484 38485 38486 38487 38488 38489 38490 38491 38492 38493 38494 38495 38496 38497 38498 38499 38500 38501 38502 38503 38504 38505 38506 38507 38508 38509 38510 38511 38512 38513 38514 38515 38516 38517 38518 38519 38520 38521 38522 38523 38524 38525 38526 38527 38528 38529 38530 38531 38532 38533 38534 38535 38536 38537 38538 38539 38540 38541 38542 38543 38544 38545 38546 38547 38548 38549 38550 38551 38552 38553 38554 38555 38556 38557 38558 38559 38560 38561 38562 38563 38564 38565 38566 38567 38568 38569 38570 38571 38572 38573 38574 38575 38576 38577 38578 38579 38580 38581 38582 38583 38584 38585 38586 38587 38588 38589 38590 38591 38592 38593 38594 38595 38596 38597 38598 38599 38600 38601 38602 38603 38604 38605 38606 38607 38608 38609 38610 38611 38612 38613 38614 38615 38616 38617 38618 38619 38620 38621 38622 38623 38624 38625 38626 38627 38628 38629 38630 38631 38632 38633 38634 38635 38636 38637 38638 38639 38640 38641 38642 38643 38644 38645 38646 38647 38648 38649 38650 38651 38652 38653 38654 38655 38656 38657 38658 38659 38660 38661 38662 38663 38664 38665 38666 38667 38668 38669 38670 38671 38672 38673 38674 38675 38676 38677 38678 38679 38680 38681 38682 38683 38684 38685 38686 38687 38688 38689 38690 38691 38692 38693 38694 38695 38696 38697 38698 38699 38700 38701 38702 38703 38704 38705 38706 38707 38708 38709 38710 38711 38712 38713 38714 38715 38716 38717 38718 38719 38720 38721 38722 38723 38724 38725 38726 38727 38728 38729 38730 38731 38732 38733 38734 38735 38736 38737 38738 38739 38740 38741 38742 38743 38744 38745 38746 38747 38748 38749 38750 38751 38752 38753 38754 38755 38756 38757 38758 38759 38760 38761 38762 38763 38764 38765 38766 38767 38768 38769 38770 38771 38772 38773 38774 38775 38776 38777 38778 38779 38780 38781 38782 38783 38784 38785 38786 38787 38788 38789 38790 38791 38792 38793 38794 38795 38796 38797 38798 38799 38800 38801 38802 38803 38804 38805 38806 38807 38808 38809 38810 38811 38812 38813 38814 38815 38816 38817 38818 38819 38820 38821 38822 38823 38824 38825 38826 38827 38828 38829 38830 38831 38832 38833 38834 38835 38836 38837 38838 38839 38840 38841 38842 38843 38844 38845 38846 38847 38848 38849 38850 38851 38852 38853 38854 38855 38856 38857 38858 38859 38860 38861 38862 38863 38864 38865 38866 38867 38868 38869 38870 38871 38872 38873 38874 38875 38876 38877 38878 38879 38880 38881 38882 38883 38884 38885 38886 38887 38888 38889 38890 38891 38892 38893 38894 38895 38896 38897 38898 38899 38900 38901 38902 38903 38904 38905 38906 38907 38908 38909 38910 38911 38912 38913 38914 38915 38916 38917 38918 38919 38920 38921 38922 38923 38924 38925 38926 38927 38928 38929 38930 38931 38932 38933 38934 38935 38936 38937 38938 38939 38940 38941 38942 38943 38944 38945 38946 38947 38948 38949 38950 38951 38952 38953 38954 38955 38956 38957 38958 38959 38960 38961 38962 38963 38964 38965 38966 38967 38968 38969 38970 38971 38972 38973 38974 38975 38976 38977 38978 38979 38980 38981 38982 38983 38984 38985 38986 38987 38988 38989 38990 38991 38992 38993 38994 38995 38996 38997 38998 38999 39000 39001 39002 39003 39004 39005 39006 39007 39008 39009 39010 39011 39012 39013 39014 39015 39016 39017 39018 39019 39020 39021 39022 39023 39024 39025 39026 39027 39028 39029 39030 39031 39032 39033 39034 39035 39036 39037 39038 39039 39040 39041 39042 39043 39044 39045 39046 39047 39048 39049 39050 39051 39052 39053 39054 39055 39056 39057 39058 39059 39060 39061 39062 39063 39064 39065 39066 39067 39068 39069 39070 39071 39072 39073 39074 39075 39076 39077 39078 39079 39080 39081 39082 39083 39084 39085 39086 39087 39088 39089 39090 39091 39092 39093 39094 39095 39096 39097 39098 39099 39100 39101 39102 39103 39104 39105 39106 39107 39108 39109 39110 39111 39112 39113 39114 39115 39116 39117 39118 39119 39120 39121 39122 39123 39124 39125 39126 39127 39128 39129 39130 39131 39132 39133 39134 39135 39136 39137 39138 39139 39140 39141 39142 39143 39144 39145 39146 39147 39148 39149 39150 39151 39152 39153 39154 39155 39156 39157 39158 39159 39160 39161 39162 39163 39164 39165 39166 39167 39168 39169 39170 39171 39172 39173 39174 39175 39176 39177 39178 39179 39180 39181 39182 39183 39184 39185 39186 39187 39188 39189 39190 39191 39192 39193 39194 39195 39196 39197 39198 39199 39200 39201 39202 39203 39204 39205 39206 39207 39208 39209 39210 39211 39212 39213 39214 39215 39216 39217 39218 39219 39220 39221 39222 39223 39224 39225 39226 39227 39228 39229 39230 39231 39232 39233 39234 39235 39236 39237 39238 39239 39240 39241 39242 39243 39244 39245 39246 39247 39248 39249 39250 39251 39252 39253 39254 39255 39256 39257 39258 39259 39260 39261 39262 39263 39264 39265 39266 39267 39268 39269 39270 39271 39272 39273 39274 39275 39276 39277 39278 39279 39280 39281 39282 39283 39284 39285 39286 39287 39288 39289 39290 39291 39292 39293 39294 39295 39296 39297 39298 39299 39300 39301 39302 39303 39304 39305 39306 39307 39308 39309 39310 39311 39312 39313 39314 39315 39316 39317 39318 39319 39320 39321 39322 39323 39324 39325 39326 39327 39328 39329 39330 39331 39332 39333 39334 39335 39336 39337 39338 39339 39340 39341 39342 39343 39344 39345 39346 39347 39348 39349 39350 39351 39352 39353 39354 39355 39356 39357 39358 39359 39360 39361 39362 39363 39364 39365 39366 39367 39368 39369 39370 39371 39372 39373 39374 39375 39376 39377 39378 39379 39380 39381 39382 39383 39384 39385 39386 39387 39388 39389 39390 39391 39392 39393 39394 39395 39396 39397 39398 39399 39400 39401 39402 39403 39404 39405 39406 39407 39408 39409 39410 39411 39412 39413 39414 39415 39416 39417 39418 39419 39420 39421 39422 39423 39424 39425 39426 39427 39428 39429 39430 39431 39432 39433 39434 39435 39436 39437 39438 39439 39440 39441 39442 39443 39444 39445 39446 39447 39448 39449 39450 39451 39452 39453 39454 39455 39456 39457 39458 39459 39460 39461 39462 39463 39464 39465 39466 39467 39468 39469 39470 39471 39472 39473 39474 39475 39476 39477 39478 39479 39480 39481 39482 39483 39484 39485 39486 39487 39488 39489 39490 39491 39492 39493 39494 39495 39496 39497 39498 39499 39500 39501 39502 39503 39504 39505 39506 39507 39508 39509 39510 39511 39512 39513 39514 39515 39516 39517 39518 39519 39520 39521 39522 39523 39524 39525 39526 39527 39528 39529 39530 39531 39532 39533 39534 39535 39536 39537 39538 39539 39540 39541 39542 39543 39544 39545 39546 39547 39548 39549 39550 39551 39552 39553 39554 39555 39556 39557 39558 39559 39560 39561 39562 39563 39564 39565 39566 39567 39568 39569 39570 39571 39572 39573 39574 39575 39576 39577 39578 39579 39580 39581 39582 39583 39584 39585 39586 39587 39588 39589 39590 39591 39592 39593 39594 39595 39596 39597 39598 39599 39600 39601 39602 39603 39604 39605 39606 39607 39608 39609 39610 39611 39612 39613 39614 39615 39616 39617 39618 39619 39620 39621 39622 39623 39624 39625 39626 39627 39628 39629 39630 39631 39632 39633 39634 39635 39636 39637 39638 39639 39640 39641 39642 39643 39644 39645 39646 39647 39648 39649 39650 39651 39652 39653 39654 39655 39656 39657 39658 39659 39660 39661 39662 39663 39664 39665 39666 39667 39668 39669 39670 39671 39672 39673 39674 39675 39676 39677 39678 39679 39680 39681 39682 39683 39684 39685 39686 39687 39688 39689 39690 39691 39692 39693 39694 39695 39696 39697 39698 39699 39700 39701 39702 39703 39704 39705 39706 39707 39708 39709 39710 39711 39712 39713 39714 39715 39716 39717 39718 39719 39720 39721 39722 39723 39724 39725 39726 39727 39728 39729 39730 39731 39732 39733 39734 39735 39736 39737 39738 39739 39740 39741 39742 39743 39744 39745 39746 39747 39748 39749 39750 39751 39752 39753 39754 39755 39756 39757 39758 39759 39760 39761 39762 39763 39764 39765 39766 39767 39768 39769 39770 39771 39772 39773 39774 39775 39776 39777 39778 39779 39780 39781 39782 39783 39784 39785 39786 39787 39788 39789 39790 39791 39792 39793 39794 39795 39796 39797 39798 39799 39800 39801 39802 39803 39804 39805 39806 39807 39808 39809 39810 39811 39812 39813 39814 39815 39816 39817 39818 39819 39820 39821 39822 39823 39824 39825 39826 39827 39828 39829 39830 39831 39832 39833 39834 39835 39836 39837 39838 39839 39840 39841 39842 39843 39844 39845 39846 39847 39848 39849 39850 39851 39852 39853 39854 39855 39856 39857 39858 39859 39860 39861 39862 39863 39864 39865 39866 39867 39868 39869 39870 39871 39872 39873 39874 39875 39876 39877 39878 39879 39880 39881 39882 39883 39884 39885 39886 39887 39888 39889 39890 39891 39892 39893 39894 39895 39896 39897 39898 39899 39900 39901 39902 39903 39904 39905 39906 39907 39908 39909 39910 39911 39912 39913 39914 39915 39916 39917 39918 39919 39920 39921 39922 39923 39924 39925 39926 39927 39928 39929 39930 39931 39932 39933 39934 39935 39936 39937 39938 39939 39940 39941 39942 39943 39944 39945 39946 39947 39948 39949 39950 39951 39952 39953 39954 39955 39956 39957 39958 39959 39960 39961 39962 39963 39964 39965 39966 39967 39968 39969 39970 39971 39972 39973 39974 39975 39976 39977 39978 39979 39980 39981 39982 39983 39984 39985 39986 39987 39988 39989 39990 39991 39992 39993 39994 39995 39996 39997 39998 39999 40000 40001 40002 40003 40004 40005 40006 40007 40008 40009 40010 40011 40012 40013 40014 40015 40016 40017 40018 40019 40020 40021 40022 40023 40024 40025 40026 40027 40028 40029 40030 40031 40032 40033 40034 40035 40036 40037 40038 40039 40040 40041 40042 40043 40044 40045 40046 40047 40048 40049 40050 40051 40052 40053 40054 40055 40056 40057 40058 40059 40060 40061 40062 40063 40064 40065 40066 40067 40068 40069 40070 40071 40072 40073 40074 40075 40076 40077 40078 40079 40080 40081 40082 40083 40084 40085 40086 40087 40088 40089 40090 40091 40092 40093 40094 40095 40096 40097 40098 40099 40100 40101 40102 40103 40104 40105 40106 40107 40108 40109 40110 40111 40112 40113 40114 40115 40116 40117 40118 40119 40120 40121 40122 40123 40124 40125 40126 40127 40128 40129 40130 40131 40132 40133 40134 40135 40136 40137 40138 40139 40140 40141 40142 40143 40144 40145 40146 40147 40148 40149 40150 40151 40152 40153 40154 40155 40156 40157 40158 40159 40160 40161 40162 40163 40164 40165 40166 40167 40168 40169 40170 40171 40172 40173 40174 40175 40176 40177 40178 40179 40180 40181 40182 40183 40184 40185 40186 40187 40188 40189 40190 40191 40192 40193 40194 40195 40196 40197 40198 40199 40200 40201 40202 40203 40204 40205 40206 40207 40208 40209 40210 40211 40212 40213 40214 40215 40216 40217 40218 40219 40220 40221 40222 40223 40224 40225 40226 40227 40228 40229 40230 40231 40232 40233 40234 40235 40236 40237 40238 40239 40240 40241 40242 40243 40244 40245 40246 40247 40248 40249 40250 40251 40252 40253 40254 40255 40256 40257 40258 40259 40260 40261 40262 40263 40264 40265 40266 40267 40268 40269 40270 40271 40272 40273 40274 40275 40276 40277 40278 40279 40280 40281 40282 40283 40284 40285 40286 40287 40288 40289 40290 40291 40292 40293 40294 40295 40296 40297 40298 40299 40300 40301 40302 40303 40304 40305 40306 40307 40308 40309 40310 40311 40312 40313 40314 40315 40316 40317 40318 40319 40320 40321 40322 40323 40324 40325 40326 40327 40328 40329 40330 40331 40332 40333 40334 40335 40336 40337 40338 40339 40340 40341 40342 40343 40344 40345 40346 40347 40348 40349 40350 40351 40352 40353 40354 40355 40356 40357 40358 40359 40360 40361 40362 40363 40364 40365 40366 40367 40368 40369 40370 40371 40372 40373 40374 40375 40376 40377 40378 40379 40380 40381 40382 40383 40384 40385 40386 40387 40388 40389 40390 40391 40392 40393 40394 40395 40396 40397 40398 40399 40400 40401 40402 40403 40404 40405 40406 40407 40408 40409 40410 40411 40412 40413 40414 40415 40416 40417 40418 40419 40420 40421 40422 40423 40424 40425 40426 40427 40428 40429 40430 40431 40432 40433 40434 40435 40436 40437 40438 40439 40440 40441 40442 40443 40444 40445 40446 40447 40448 40449 40450 40451 40452 40453 40454 40455 40456 40457 40458 40459 40460 40461 40462 40463 40464 40465 40466 40467 40468 40469 40470 40471 40472 40473 40474 40475 40476 40477 40478 40479 40480 40481 40482 40483 40484 40485 40486 40487 40488 40489 40490 40491 40492 40493 40494 40495 40496 40497 40498 40499 40500 40501 40502 40503 40504 40505 40506 40507 40508 40509 40510 40511 40512 40513 40514 40515 40516 40517 40518 40519 40520 40521 40522 40523 40524 40525 40526 40527 40528 40529 40530 40531 40532 40533 40534 40535 40536 40537 40538 40539 40540 40541 40542 40543 40544 40545 40546 40547 40548 40549 40550 40551 40552 40553 40554 40555 40556 40557 40558 40559 40560 40561 40562 40563 40564 40565 40566 40567 40568 40569 40570 40571 40572 40573 40574 40575 40576 40577 40578 40579 40580 40581 40582 40583 40584 40585 40586 40587 40588 40589 40590 40591 40592 40593 40594 40595 40596 40597 40598 40599 40600 40601 40602 40603 40604 40605 40606 40607 40608 40609 40610 40611 40612 40613 40614 40615 40616 40617 40618 40619 40620 40621 40622 40623 40624 40625 40626 40627 40628 40629 40630 40631 40632 40633 40634 40635 40636 40637 40638 40639 40640 40641 40642 40643 40644 40645 40646 40647 40648 40649 40650 40651 40652 40653 40654 40655 40656 40657 40658 40659 40660 40661 40662 40663 40664 40665 40666 40667 40668 40669 40670 40671 40672 40673 40674 40675 40676 40677 40678 40679 40680 40681 40682 40683 40684 40685 40686 40687 40688 40689 40690 40691 40692 40693 40694 40695 40696 40697 40698 40699 40700 40701 40702 40703 40704 40705 40706 40707 40708 40709 40710 40711 40712 40713 40714 40715 40716 40717 40718 40719 40720 40721 40722 40723 40724 40725 40726 40727 40728 40729 40730 40731 40732 40733 40734 40735 40736 40737 40738 40739 40740 40741 40742 40743 40744 40745 40746 40747 40748 40749 40750 40751 40752 40753 40754 40755 40756 40757 40758 40759 40760 40761 40762 40763 40764 40765 40766 40767 40768 40769 40770 40771 40772 40773 40774 40775 40776 40777 40778 40779 40780 40781 40782 40783 40784 40785 40786 40787 40788 40789 40790 40791 40792 40793 40794 40795 40796 40797 40798 40799 40800 40801 40802 40803 40804 40805 40806 40807 40808 40809 40810 40811 40812 40813 40814 40815 40816 40817 40818 40819 40820 40821 40822 40823 40824 40825 40826 40827 40828 40829 40830 40831 40832 40833 40834 40835 40836 40837 40838 40839 40840 40841 40842 40843 40844 40845 40846 40847 40848 40849 40850 40851 40852 40853 40854 40855 40856 40857 40858 40859 40860 40861 40862 40863 40864 40865 40866 40867 40868 40869 40870 40871 40872 40873 40874 40875 40876 40877 40878 40879 40880 40881 40882 40883 40884 40885 40886 40887 40888 40889 40890 40891 40892 40893 40894 40895 40896 40897 40898 40899 40900 40901 40902 40903 40904 40905 40906 40907 40908 40909 40910 40911 40912 40913 40914 40915 40916 40917 40918 40919 40920 40921 40922 40923 40924 40925 40926 40927 40928 40929 40930 40931 40932 40933 40934 40935 40936 40937 40938 40939 40940 40941 40942 40943 40944 40945 40946 40947 40948 40949 40950 40951 40952 40953 40954 40955 40956 40957 40958 40959 40960 40961 40962 40963 40964 40965 40966 40967 40968 40969 40970 40971 40972 40973 40974 40975 40976 40977 40978 40979 40980 40981 40982 40983 40984 40985 40986 40987 40988 40989 40990 40991 40992 40993 40994 40995 40996 40997 40998 40999 41000 41001 41002 41003 41004 41005 41006 41007 41008 41009 41010 41011 41012 41013 41014 41015 41016 41017 41018 41019 41020 41021 41022 41023 41024 41025 41026 41027 41028 41029 41030 41031 41032 41033 41034 41035 41036 41037 41038 41039 41040 41041 41042 41043 41044 41045 41046 41047 41048 41049 41050 41051 41052 41053 41054 41055 41056 41057 41058 41059 41060 41061 41062 41063 41064 41065 41066 41067 41068 41069 41070 41071 41072 41073 41074 41075 41076 41077 41078 41079 41080 41081 41082 41083 41084 41085 41086 41087 41088 41089 41090 41091 41092 41093 41094 41095 41096 41097 41098 41099 41100 41101 41102 41103 41104 41105 41106 41107 41108 41109 41110 41111 41112 41113 41114 41115 41116 41117 41118 41119 41120 41121 41122 41123 41124 41125 41126 41127 41128 41129 41130 41131 41132 41133 41134 41135 41136 41137 41138 41139 41140 41141 41142 41143 41144 41145 41146 41147 41148 41149 41150 41151 41152 41153 41154 41155 41156 41157 41158 41159 41160 41161 41162 41163 41164 41165 41166 41167 41168 41169 41170 41171 41172 41173 41174 41175 41176 41177 41178 41179 41180 41181 41182 41183 41184 41185 41186 41187 41188 41189 41190 41191 41192 41193 41194 41195 41196 41197 41198 41199 41200 41201 41202 41203 41204 41205 41206 41207 41208 41209 41210 41211 41212 41213 41214 41215 41216 41217 41218 41219 41220 41221 41222 41223 41224 41225 41226 41227 41228 41229 41230 41231 41232 41233 41234 41235 41236 41237 41238 41239 41240 41241 41242 41243 41244 41245 41246 41247 41248 41249 41250 41251 41252 41253 41254 41255 41256 41257 41258 41259 41260 41261 41262 41263 41264 41265 41266 41267 41268 41269 41270 41271 41272 41273 41274 41275 41276 41277 41278 41279 41280 41281 41282 41283 41284 41285 41286 41287 41288 41289 41290 41291 41292 41293 41294 41295 41296 41297 41298 41299 41300 41301 41302 41303 41304 41305 41306 41307 41308 41309 41310 41311 41312 41313 41314 41315 41316 41317 41318 41319 41320 41321 41322 41323 41324 41325 41326 41327 41328 41329 41330 41331 41332 41333 41334 41335 41336 41337 41338 41339 41340 41341 41342 41343 41344 41345 41346 41347 41348 41349 41350 41351 41352 41353 41354 41355 41356 41357 41358 41359 41360 41361 41362 41363 41364 41365 41366 41367 41368 41369 41370 41371 41372 41373 41374 41375 41376 41377 41378 41379 41380 41381 41382 41383 41384 41385 41386 41387 41388 41389 41390 41391 41392 41393 41394 41395 41396 41397 41398 41399 41400 41401 41402 41403 41404 41405 41406 41407 41408 41409 41410 41411 41412 41413 41414 41415 41416 41417 41418 41419 41420 41421 41422 41423 41424 41425 41426 41427 41428 41429 41430 41431 41432 41433 41434 41435 41436 41437 41438 41439 41440 41441 41442 41443 41444 41445 41446 41447 41448 41449 41450 41451 41452 41453 41454 41455 41456 41457 41458 41459 41460 41461 41462 41463 41464 41465 41466 41467 41468 41469 41470 41471 41472 41473 41474 41475 41476 41477 41478 41479 41480 41481 41482 41483 41484 41485 41486 41487 41488 41489 41490 41491 41492 41493 41494 41495 41496 41497 41498 41499 41500 41501 41502 41503 41504 41505 41506 41507 41508 41509 41510 41511 41512 41513 41514 41515 41516 41517 41518 41519 41520 41521 41522 41523 41524 41525 41526 41527 41528 41529 41530 41531 41532 41533 41534 41535 41536 41537 41538 41539 41540 41541 41542 41543 41544 41545 41546 41547 41548 41549 41550 41551 41552 41553 41554 41555 41556 41557 41558 41559 41560 41561 41562 41563 41564 41565 41566 41567 41568 41569 41570 41571 41572 41573 41574 41575 41576 41577 41578 41579 41580 41581 41582 41583 41584 41585 41586 41587 41588 41589 41590 41591 41592 41593 41594 41595 41596 41597 41598 41599 41600 41601 41602 41603 41604 41605 41606 41607 41608 41609 41610 41611 41612 41613 41614 41615 41616 41617 41618 41619 41620 41621 41622 41623 41624 41625 41626 41627 41628 41629 41630 41631 41632 41633 41634 41635 41636 41637 41638 41639 41640 41641 41642 41643 41644 41645 41646 41647 41648 41649 41650 41651 41652 41653 41654 41655 41656 41657 41658 41659 41660 41661 41662 41663 41664 41665 41666 41667 41668 41669 41670 41671 41672 41673 41674 41675 41676 41677 41678 41679 41680 41681 41682 41683 41684 41685 41686 41687 41688 41689 41690 41691 41692 41693 41694 41695 41696 41697 41698 41699 41700 41701 41702 41703 41704 41705 41706 41707 41708 41709 41710 41711 41712 41713 41714 41715 41716 41717 41718 41719 41720 41721 41722 41723 41724 41725 41726 41727 41728 41729 41730 41731 41732 41733 41734 41735 41736 41737 41738 41739 41740 41741 41742 41743 41744 41745 41746 41747 41748 41749 41750 41751 41752 41753 41754 41755 41756 41757 41758 41759 41760 41761 41762 41763 41764 41765 41766 41767 41768 41769 41770 41771 41772 41773 41774 41775 41776 41777 41778 41779 41780 41781 41782 41783 41784 41785 41786 41787 41788 41789 41790 41791 41792 41793 41794 41795 41796 41797 41798 41799 41800 41801 41802 41803 41804 41805 41806 41807 41808 41809 41810 41811 41812 41813 41814 41815 41816 41817 41818 41819 41820 41821 41822 41823 41824 41825 41826 41827 41828 41829 41830 41831 41832 41833 41834 41835 41836 41837 41838 41839 41840 41841 41842 41843 41844 41845 41846 41847 41848 41849 41850 41851 41852 41853 41854 41855 41856 41857 41858 41859 41860 41861 41862 41863 41864 41865 41866 41867 41868 41869 41870 41871 41872 41873 41874 41875 41876 41877 41878 41879 41880 41881 41882 41883 41884 41885 41886 41887 41888 41889 41890 41891 41892 41893 41894 41895 41896 41897 41898 41899 41900 41901 41902 41903 41904 41905 41906 41907 41908 41909 41910 41911 41912 41913 41914 41915 41916 41917 41918 41919 41920 41921 41922 41923 41924 41925 41926 41927 41928 41929 41930 41931 41932 41933 41934 41935 41936 41937 41938 41939 41940 41941 41942 41943 41944 41945 41946 41947 41948 41949 41950 41951 41952 41953 41954 41955 41956 41957 41958 41959 41960 41961 41962 41963 41964 41965 41966 41967 41968 41969 41970 41971 41972 41973 41974 41975 41976 41977 41978 41979 41980 41981 41982 41983 41984 41985 41986 41987 41988 41989 41990 41991 41992 41993 41994 41995 41996 41997 41998 41999 42000 42001 42002 42003 42004 42005 42006 42007 42008 42009 42010 42011 42012 42013 42014 42015 42016 42017 42018 42019 42020 42021 42022 42023 42024 42025 42026 42027 42028 42029 42030 42031 42032 42033 42034 42035 42036 42037 42038 42039 42040 42041 42042 42043 42044 42045 42046 42047 42048 42049 42050 42051 42052 42053 42054 42055 42056 42057 42058 42059 42060 42061 42062 42063 42064 42065 42066 42067 42068 42069 42070 42071 42072 42073 42074 42075 42076 42077 42078 42079 42080 42081 42082 42083 42084 42085 42086 42087 42088 42089 42090 42091 42092 42093 42094 42095 42096 42097 42098 42099 42100 42101 42102 42103 42104 42105 42106 42107 42108 42109 42110 42111 42112 42113 42114 42115 42116 42117 42118 42119 42120 42121 42122 42123 42124 42125 42126 42127 42128 42129 42130 42131 42132 42133 42134 42135 42136 42137 42138 42139 42140 42141 42142 42143 42144 42145 42146 42147 42148 42149 42150 42151 42152 42153 42154 42155 42156 42157 42158 42159 42160 42161 42162 42163 42164 42165 42166 42167 42168 42169 42170 42171 42172 42173 42174 42175 42176 42177 42178 42179 42180 42181 42182 42183 42184 42185 42186 42187 42188 42189 42190 42191 42192 42193 42194 42195 42196 42197 42198 42199 42200 42201 42202 42203 42204 42205 42206 42207 42208 42209 42210 42211 42212 42213 42214 42215 42216 42217 42218 42219 42220 42221 42222 42223 42224 42225 42226 42227 42228 42229 42230 42231 42232 42233 42234 42235 42236 42237 42238 42239 42240 42241 42242 42243 42244 42245 42246 42247 42248 42249 42250 42251 42252 42253 42254 42255 42256 42257 42258 42259 42260 42261 42262 42263 42264 42265 42266 42267 42268 42269 42270 42271 42272 42273 42274 42275 42276 42277 42278 42279 42280 42281 42282 42283 42284 42285 42286 42287 42288 42289 42290 42291 42292 42293 42294 42295 42296 42297 42298 42299 42300 42301 42302 42303 42304 42305 42306 42307 42308 42309 42310 42311 42312 42313 42314 42315 42316 42317 42318 42319 42320 42321 42322 42323 42324 42325 42326 42327 42328 42329 42330 42331 42332 42333 42334 42335 42336 42337 42338 42339 42340 42341 42342 42343 42344 42345 42346 42347 42348 42349 42350 42351 42352 42353 42354 42355 42356 42357 42358 42359 42360 42361 42362 42363 42364 42365 42366 42367 42368 42369 42370 42371 42372 42373 42374 42375 42376 42377 42378 42379 42380 42381 42382 42383 42384 42385 42386 42387 42388 42389 42390 42391 42392 42393 42394 42395 42396 42397 42398 42399 42400 42401 42402 42403 42404 42405 42406 42407 42408 42409 42410 42411 42412 42413 42414 42415 42416 42417 42418 42419 42420 42421 42422 42423 42424 42425 42426 42427 42428 42429 42430 42431 42432 42433 42434 42435 42436 42437 42438 42439 42440 42441 42442 42443 42444 42445 42446 42447 42448 42449 42450 42451 42452 42453 42454 42455 42456 42457 42458 42459 42460 42461 42462 42463 42464 42465 42466 42467 42468 42469 42470 42471 42472 42473 42474 42475 42476 42477 42478 42479 42480 42481 42482 42483 42484 42485 42486 42487 42488 42489 42490 42491 42492 42493 42494 42495 42496 42497 42498 42499 42500 42501 42502 42503 42504 42505 42506 42507 42508 42509 42510 42511 42512 42513 42514 42515 42516 42517 42518 42519 42520 42521 42522 42523 42524 42525 42526 42527 42528 42529 42530 42531 42532 42533 42534 42535 42536 42537 42538 42539 42540 42541 42542 42543 42544 42545 42546 42547 42548 42549 42550 42551 42552 42553 42554 42555 42556 42557 42558 42559 42560 42561 42562 42563 42564 42565 42566 42567 42568 42569 42570 42571 42572 42573 42574 42575 42576 42577 42578 42579 42580 42581 42582 42583 42584 42585 42586 42587 42588 42589 42590 42591 42592 42593 42594 42595 42596 42597 42598 42599 42600 42601 42602 42603 42604 42605 42606 42607 42608 42609 42610 42611 42612 42613 42614 42615 42616 42617 42618 42619 42620 42621 42622 42623 42624 42625 42626 42627 42628 42629 42630 42631 42632 42633 42634 42635 42636 42637 42638 42639 42640 42641 42642 42643 42644 42645 42646 42647 42648 42649 42650 42651 42652 42653 42654 42655 42656 42657 42658 42659 42660 42661 42662 42663 42664 42665 42666 42667 42668 42669 42670 42671 42672 42673 42674 42675 42676 42677 42678 42679 42680 42681 42682 42683 42684 42685 42686 42687 42688 42689 42690 42691 42692 42693 42694 42695 42696 42697 42698 42699 42700 42701 42702 42703 42704 42705 42706 42707 42708 42709 42710 42711 42712 42713 42714 42715 42716 42717 42718 42719 42720 42721 42722 42723 42724 42725 42726 42727 42728 42729 42730 42731 42732 42733 42734 42735 42736 42737 42738 42739 42740 42741 42742 42743 42744 42745 42746 42747 42748 42749 42750 42751 42752 42753 42754 42755 42756 42757 42758 42759 42760 42761 42762 42763 42764 42765 42766 42767 42768 42769 42770 42771 42772 42773 42774 42775 42776 42777 42778 42779 42780 42781 42782 42783 42784 42785 42786 42787 42788 42789 42790 42791 42792 42793 42794 42795 42796 42797 42798 42799 42800 42801 42802 42803 42804 42805 42806 42807 42808 42809 42810 42811 42812 42813 42814 42815 42816 42817 42818 42819 42820 42821 42822 42823 42824 42825 42826 42827 42828 42829 42830 42831 42832 42833 42834 42835 42836 42837 42838 42839 42840 42841 42842 42843 42844 42845 42846 42847 42848 42849 42850 42851 42852 42853 42854 42855 42856 42857 42858 42859 42860 42861 42862 42863 42864 42865 42866 42867 42868 42869 42870 42871 42872 42873 42874 42875 42876 42877 42878 42879 42880 42881 42882 42883 42884 42885 42886 42887 42888 42889 42890 42891 42892 42893 42894 42895 42896 42897 42898 42899 42900 42901 42902 42903 42904 42905 42906 42907 42908 42909 42910 42911 42912 42913 42914 42915 42916 42917 42918 42919 42920 42921 42922 42923 42924 42925 42926 42927 42928 42929 42930 42931 42932 42933 42934 42935 42936 42937 42938 42939 42940 42941 42942 42943 42944 42945 42946 42947 42948 42949 42950 42951 42952 42953 42954 42955 42956 42957 42958 42959 42960 42961 42962 42963 42964 42965 42966 42967 42968 42969 42970 42971 42972 42973 42974 42975 42976 42977 42978 42979 42980 42981 42982 42983 42984 42985 42986 42987 42988 42989 42990 42991 42992 42993 42994 42995 42996 42997 42998 42999 43000 43001 43002 43003 43004 43005 43006 43007 43008 43009 43010 43011 43012 43013 43014 43015 43016 43017 43018 43019 43020 43021 43022 43023 43024 43025 43026 43027 43028 43029 43030 43031 43032 43033 43034 43035 43036 43037 43038 43039 43040 43041 43042 43043 43044 43045 43046 43047 43048 43049 43050 43051 43052 43053 43054 43055 43056 43057 43058 43059 43060 43061 43062 43063 43064 43065 43066 43067 43068 43069 43070 43071 43072 43073 43074 43075 43076 43077 43078 43079 43080 43081 43082 43083 43084 43085 43086 43087 43088 43089 43090 43091 43092 43093 43094 43095 43096 43097 43098 43099 43100 43101 43102 43103 43104 43105 43106 43107 43108 43109 43110 43111 43112 43113 43114 43115 43116 43117 43118 43119 43120 43121 43122 43123 43124 43125 43126 43127 43128 43129 43130 43131 43132 43133 43134 43135 43136 43137 43138 43139 43140 43141 43142 43143 43144 43145 43146 43147 43148 43149 43150 43151 43152 43153 43154 43155 43156 43157 43158 43159 43160 43161 43162 43163 43164 43165 43166 43167 43168 43169 43170 43171 43172 43173 43174 43175 43176 43177 43178 43179 43180 43181 43182 43183 43184 43185 43186 43187 43188 43189 43190 43191 43192 43193 43194 43195 43196 43197 43198 43199 43200 43201 43202 43203 43204 43205 43206 43207 43208 43209 43210 43211 43212 43213 43214 43215 43216 43217 43218 43219 43220 43221 43222 43223 43224 43225 43226 43227 43228 43229 43230 43231 43232 43233 43234 43235 43236 43237 43238 43239 43240 43241 43242 43243 43244 43245 43246 43247 43248 43249 43250 43251 43252 43253 43254 43255 43256 43257 43258 43259 43260 43261 43262 43263 43264 43265 43266 43267 43268 43269 43270 43271 43272 43273 43274 43275 43276 43277 43278 43279 43280 43281 43282 43283 43284 43285 43286 43287 43288 43289 43290 43291 43292 43293 43294 43295 43296 43297 43298 43299 43300 43301 43302 43303 43304 43305 43306 43307 43308 43309 43310 43311 43312 43313 43314 43315 43316 43317 43318 43319 43320 43321 43322 43323 43324 43325 43326 43327 43328 43329 43330 43331 43332 43333 43334 43335 43336 43337 43338 43339 43340 43341 43342 43343 43344 43345 43346 43347 43348 43349 43350 43351 43352 43353 43354 43355 43356 43357 43358 43359 43360 43361 43362 43363 43364 43365 43366 43367 43368 43369 43370 43371 43372 43373 43374 43375 43376 43377 43378 43379 43380 43381 43382 43383 43384 43385 43386 43387 43388 43389 43390 43391 43392 43393 43394 43395 43396 43397 43398 43399 43400 43401 43402 43403 43404 43405 43406 43407 43408 43409 43410 43411 43412 43413 43414 43415 43416 43417 43418 43419 43420 43421 43422 43423 43424 43425 43426 43427 43428 43429 43430 43431 43432 43433 43434 43435 43436 43437 43438 43439 43440 43441 43442 43443 43444 43445 43446 43447 43448 43449 43450 43451 43452 43453 43454 43455 43456 43457 43458 43459 43460 43461 43462 43463 43464 43465 43466 43467 43468 43469 43470 43471 43472 43473 43474 43475 43476 43477 43478 43479 43480 43481 43482 43483 43484 43485 43486 43487 43488 43489 43490 43491 43492 43493 43494 43495 43496 43497 43498 43499 43500 43501 43502 43503 43504 43505 43506 43507 43508 43509 43510 43511 43512 43513 43514 43515 43516 43517 43518 43519 43520 43521 43522 43523 43524 43525 43526 43527 43528 43529 43530 43531 43532 43533 43534 43535 43536 43537 43538 43539 43540 43541 43542 43543 43544 43545 43546 43547 43548 43549 43550 43551 43552 43553 43554 43555 43556 43557 43558 43559 43560 43561 43562 43563 43564 43565 43566 43567 43568 43569 43570 43571 43572 43573 43574 43575 43576 43577 43578 43579 43580 43581 43582 43583 43584 43585 43586 43587 43588 43589 43590 43591 43592 43593 43594 43595 43596 43597 43598 43599 43600 43601 43602 43603 43604 43605 43606 43607 43608 43609 43610 43611 43612 43613 43614 43615 43616 43617 43618 43619 43620 43621 43622 43623 43624 43625 43626 43627 43628 43629 43630 43631 43632 43633 43634 43635 43636 43637 43638 43639 43640 43641 43642 43643 43644 43645 43646 43647 43648 43649 43650 43651 43652 43653 43654 43655 43656 43657 43658 43659 43660 43661 43662 43663 43664 43665 43666 43667 43668 43669 43670 43671 43672 43673 43674 43675 43676 43677 43678 43679 43680 43681 43682 43683 43684 43685 43686 43687 43688 43689 43690 43691 43692 43693 43694 43695 43696 43697 43698 43699 43700 43701 43702 43703 43704 43705 43706 43707 43708 43709 43710 43711 43712 43713 43714 43715 43716 43717 43718 43719 43720 43721 43722 43723 43724 43725 43726 43727 43728 43729 43730 43731 43732 43733 43734 43735 43736 43737 43738 43739 43740 43741 43742 43743 43744 43745 43746 43747 43748 43749 43750 43751 43752 43753 43754 43755 43756 43757 43758 43759 43760 43761 43762 43763 43764 43765 43766 43767 43768 43769 43770 43771 43772 43773 43774 43775 43776 43777 43778 43779 43780 43781 43782 43783 43784 43785 43786 43787 43788 43789 43790 43791 43792 43793 43794 43795 43796 43797 43798 43799 43800 43801 43802 43803 43804 43805 43806 43807 43808 43809 43810 43811 43812 43813 43814 43815 43816 43817 43818 43819 43820 43821 43822 43823 43824 43825 43826 43827 43828 43829 43830 43831 43832 43833 43834 43835 43836 43837 43838 43839 43840 43841 43842 43843 43844 43845 43846 43847 43848 43849 43850 43851 43852 43853 43854 43855 43856 43857 43858 43859 43860 43861 43862 43863 43864 43865 43866 43867 43868 43869 43870 43871 43872 43873 43874 43875 43876 43877 43878 43879 43880 43881 43882 43883 43884 43885 43886 43887 43888 43889 43890 43891 43892 43893 43894 43895 43896 43897 43898 43899 43900 43901 43902 43903 43904 43905 43906 43907 43908 43909 43910 43911 43912 43913 43914 43915 43916 43917 43918 43919 43920 43921 43922 43923 43924 43925 43926 43927 43928 43929 43930 43931 43932 43933 43934 43935 43936 43937 43938 43939 43940 43941 43942 43943 43944 43945 43946 43947 43948 43949 43950 43951 43952 43953 43954 43955 43956 43957 43958 43959 43960 43961 43962 43963 43964 43965 43966 43967 43968 43969 43970 43971 43972 43973 43974 43975 43976 43977 43978 43979 43980 43981 43982 43983 43984 43985 43986 43987 43988 43989 43990 43991 43992 43993 43994 43995 43996 43997 43998 43999 44000 44001 44002 44003 44004 44005 44006 44007 44008 44009 44010 44011 44012 44013 44014 44015 44016 44017 44018 44019 44020 44021 44022 44023 44024 44025 44026 44027 44028 44029 44030 44031 44032 44033 44034 44035 44036 44037 44038 44039 44040 44041 44042 44043 44044 44045 44046 44047 44048 44049 44050 44051 44052 44053 44054 44055 44056 44057 44058 44059 44060 44061 44062 44063 44064 44065 44066 44067 44068 44069 44070 44071 44072 44073 44074 44075 44076 44077 44078 44079 44080 44081 44082 44083 44084 44085 44086 44087 44088 44089 44090 44091 44092 44093 44094 44095 44096 44097 44098 44099 44100 44101 44102 44103 44104 44105 44106 44107 44108 44109 44110 44111 44112 44113 44114 44115 44116 44117 44118 44119 44120 44121 44122 44123 44124 44125 44126 44127 44128 44129 44130 44131 44132 44133 44134 44135 44136 44137 44138 44139 44140 44141 44142 44143 44144 44145 44146 44147 44148 44149 44150 44151 44152 44153 44154 44155 44156 44157 44158 44159 44160 44161 44162 44163 44164 44165 44166 44167 44168 44169 44170 44171 44172 44173 44174 44175 44176 44177 44178 44179 44180 44181 44182 44183 44184 44185 44186 44187 44188 44189 44190 44191 44192 44193 44194 44195 44196 44197 44198 44199 44200 44201 44202 44203 44204 44205 44206 44207 44208 44209 44210 44211 44212 44213 44214 44215 44216 44217 44218 44219 44220 44221 44222 44223 44224 44225 44226 44227 44228 44229 44230 44231 44232 44233 44234 44235 44236 44237 44238 44239 44240 44241 44242 44243 44244 44245 44246 44247 44248 44249 44250 44251 44252 44253 44254 44255 44256 44257 44258 44259 44260 44261 44262 44263 44264 44265 44266 44267 44268 44269 44270 44271 44272 44273 44274 44275 44276 44277 44278 44279 44280 44281 44282 44283 44284 44285 44286 44287 44288 44289 44290 44291 44292 44293 44294 44295 44296 44297 44298 44299 44300 44301 44302 44303 44304 44305 44306 44307 44308 44309 44310 44311 44312 44313 44314 44315 44316 44317 44318 44319 44320 44321 44322 44323 44324 44325 44326 44327 44328 44329 44330 44331 44332 44333 44334 44335 44336 44337 44338 44339 44340 44341 44342 44343 44344 44345 44346 44347 44348 44349 44350 44351 44352 44353 44354 44355 44356 44357 44358 44359 44360 44361 44362 44363 44364 44365 44366 44367 44368 44369 44370 44371 44372 44373 44374 44375 44376 44377 44378 44379 44380 44381 44382 44383 44384 44385 44386 44387 44388 44389 44390 44391 44392 44393 44394 44395 44396 44397 44398 44399 44400 44401 44402 44403 44404 44405 44406 44407 44408 44409 44410 44411 44412 44413 44414 44415 44416 44417 44418 44419 44420 44421 44422 44423 44424 44425 44426 44427 44428 44429 44430 44431 44432 44433 44434 44435 44436 44437 44438 44439 44440 44441 44442 44443 44444 44445 44446 44447 44448 44449 44450 44451 44452 44453 44454 44455 44456 44457 44458 44459 44460 44461 44462 44463 44464 44465 44466 44467 44468 44469 44470 44471 44472 44473 44474 44475 44476 44477 44478 44479 44480 44481 44482 44483 44484 44485 44486 44487 44488 44489 44490 44491 44492 44493 44494 44495 44496 44497 44498 44499 44500 44501 44502 44503 44504 44505 44506 44507 44508 44509 44510 44511 44512 44513 44514 44515 44516 44517 44518 44519 44520 44521 44522 44523 44524 44525 44526 44527 44528 44529 44530 44531 44532 44533 44534 44535 44536 44537 44538 44539 44540 44541 44542 44543 44544 44545 44546 44547 44548 44549 44550 44551 44552 44553 44554 44555 44556 44557 44558 44559 44560 44561 44562 44563 44564 44565 44566 44567 44568 44569 44570 44571 44572 44573 44574 44575 44576 44577 44578 44579 44580 44581 44582 44583 44584 44585 44586 44587 44588 44589 44590 44591 44592 44593 44594 44595 44596 44597 44598 44599 44600 44601 44602 44603 44604 44605 44606 44607 44608 44609 44610 44611 44612 44613 44614 44615 44616 44617 44618 44619 44620 44621 44622 44623 44624 44625 44626 44627 44628 44629 44630 44631 44632 44633 44634 44635 44636 44637 44638 44639 44640 44641 44642 44643 44644 44645 44646 44647 44648 44649 44650 44651 44652 44653 44654 44655 44656 44657 44658 44659 44660 44661 44662 44663 44664 44665 44666 44667 44668 44669 44670 44671 44672 44673 44674 44675 44676 44677 44678 44679 44680 44681 44682 44683 44684 44685 44686 44687 44688 44689 44690 44691 44692 44693 44694 44695 44696 44697 44698 44699 44700 44701 44702 44703 44704 44705 44706 44707 44708 44709 44710 44711 44712 44713 44714 44715 44716 44717 44718 44719 44720 44721 44722 44723 44724 44725 44726 44727 44728 44729 44730 44731 44732 44733 44734 44735 44736 44737 44738 44739 44740 44741 44742 44743 44744 44745 44746 44747 44748 44749 44750 44751 44752 44753 44754 44755 44756 44757 44758 44759 44760 44761 44762 44763 44764 44765 44766 44767 44768 44769 44770 44771 44772 44773 44774 44775 44776 44777 44778 44779 44780 44781 44782 44783 44784 44785 44786 44787 44788 44789 44790 44791 44792 44793 44794 44795 44796 44797 44798 44799 44800 44801 44802 44803 44804 44805 44806 44807 44808 44809 44810 44811 44812 44813 44814 44815 44816 44817 44818 44819 44820 44821 44822 44823 44824 44825 44826 44827 44828 44829 44830 44831 44832 44833 44834 44835 44836 44837 44838 44839 44840 44841 44842 44843 44844 44845 44846 44847 44848 44849 44850 44851 44852 44853 44854 44855 44856 44857 44858 44859 44860 44861 44862 44863 44864 44865 44866 44867 44868 44869 44870 44871 44872 44873 44874 44875 44876 44877 44878 44879 44880 44881 44882 44883 44884 44885 44886 44887 44888 44889 44890 44891 44892 44893 44894 44895 44896 44897 44898 44899 44900 44901 44902 44903 44904 44905 44906 44907 44908 44909 44910 44911 44912 44913 44914 44915 44916 44917 44918 44919 44920 44921 44922 44923 44924 44925 44926 44927 44928 44929 44930 44931 44932 44933 44934 44935 44936 44937 44938 44939 44940 44941 44942 44943 44944 44945 44946 44947 44948 44949 44950 44951 44952 44953 44954 44955 44956 44957 44958 44959 44960 44961 44962 44963 44964 44965 44966 44967 44968 44969 44970 44971 44972 44973 44974 44975 44976 44977 44978 44979 44980 44981 44982 44983 44984 44985 44986 44987 44988 44989 44990 44991 44992 44993 44994 44995 44996 44997 44998 44999 45000 45001 45002 45003 45004 45005 45006 45007 45008 45009 45010 45011 45012 45013 45014 45015 45016 45017 45018 45019 45020 45021 45022 45023 45024 45025 45026 45027 45028 45029 45030 45031 45032 45033 45034 45035 45036 45037 45038 45039 45040 45041 45042 45043 45044 45045 45046 45047 45048 45049 45050 45051 45052 45053 45054 45055 45056 45057 45058 45059 45060 45061 45062 45063 45064 45065 45066 45067 45068 45069 45070 45071 45072 45073 45074 45075 45076 45077 45078 45079 45080 45081 45082 45083 45084 45085 45086 45087 45088 45089 45090 45091 45092 45093 45094 45095 45096 45097 45098 45099 45100 45101 45102 45103 45104 45105 45106 45107 45108 45109 45110 45111 45112 45113 45114 45115 45116 45117 45118 45119 45120 45121 45122 45123 45124 45125 45126 45127 45128 45129 45130 45131 45132 45133 45134 45135 45136 45137 45138 45139 45140 45141 45142 45143 45144 45145 45146 45147 45148 45149 45150 45151 45152 45153 45154 45155 45156 45157 45158 45159 45160 45161 45162 45163 45164 45165 45166 45167 45168 45169 45170 45171 45172 45173 45174 45175 45176 45177 45178 45179 45180 45181 45182 45183 45184 45185 45186 45187 45188 45189 45190 45191 45192 45193 45194 45195 45196 45197 45198 45199 45200 45201 45202 45203 45204 45205 45206 45207 45208 45209 45210 45211 45212 45213 45214 45215 45216 45217 45218 45219 45220 45221 45222 45223 45224 45225 45226 45227 45228 45229 45230 45231 45232 45233 45234 45235 45236 45237 45238 45239 45240 45241 45242 45243 45244 45245 45246 45247 45248 45249 45250 45251 45252 45253 45254 45255 45256 45257 45258 45259 45260 45261 45262 45263 45264 45265 45266 45267 45268 45269 45270 45271 45272 45273 45274 45275 45276 45277 45278 45279 45280 45281 45282 45283 45284 45285 45286 45287 45288 45289 45290 45291 45292 45293 45294 45295 45296 45297 45298 45299 45300 45301 45302 45303 45304 45305 45306 45307 45308 45309 45310 45311 45312 45313 45314 45315 45316 45317 45318 45319 45320 45321 45322 45323 45324 45325 45326 45327 45328 45329 45330 45331 45332 45333 45334 45335 45336 45337 45338 45339 45340 45341 45342 45343 45344 45345 45346 45347 45348 45349 45350 45351 45352 45353 45354 45355 45356 45357 45358 45359 45360 45361 45362 45363 45364 45365 45366 45367 45368 45369 45370 45371 45372 45373 45374 45375 45376 45377 45378 45379 45380 45381 45382 45383 45384 45385 45386 45387 45388 45389 45390 45391 45392 45393 45394 45395 45396 45397 45398 45399 45400 45401 45402 45403 45404 45405 45406 45407 45408 45409 45410 45411 45412 45413 45414 45415 45416 45417 45418 45419 45420 45421 45422 45423 45424 45425 45426 45427 45428 45429 45430 45431 45432 45433 45434 45435 45436 45437 45438 45439 45440 45441 45442 45443 45444 45445 45446 45447 45448 45449 45450 45451 45452 45453 45454 45455 45456 45457 45458 45459 45460 45461 45462 45463 45464 45465 45466 45467 45468 45469 45470 45471 45472 45473 45474 45475 45476 45477 45478 45479 45480 45481 45482 45483 45484 45485 45486 45487 45488 45489 45490 45491 45492 45493 45494 45495 45496 45497 45498 45499 45500 45501 45502 45503 45504 45505 45506 45507 45508 45509 45510 45511 45512 45513 45514 45515 45516 45517 45518 45519 45520 45521 45522 45523 45524 45525 45526 45527 45528 45529 45530 45531 45532 45533 45534 45535 45536 45537 45538 45539 45540 45541 45542 45543 45544 45545 45546 45547 45548 45549 45550 45551 45552 45553 45554 45555 45556 45557 45558 45559 45560 45561 45562 45563 45564 45565 45566 45567 45568 45569 45570 45571 45572 45573 45574 45575 45576 45577 45578 45579 45580 45581 45582 45583 45584 45585 45586 45587 45588 45589 45590 45591 45592 45593 45594 45595 45596 45597 45598 45599 45600 45601 45602 45603 45604 45605 45606 45607 45608 45609 45610 45611 45612 45613 45614 45615 45616 45617 45618 45619 45620 45621 45622 45623 45624 45625 45626 45627 45628 45629 45630 45631 45632 45633 45634 45635 45636 45637 45638 45639 45640 45641 45642 45643 45644 45645 45646 45647 45648 45649 45650 45651 45652 45653 45654 45655 45656 45657 45658 45659 45660 45661 45662 45663 45664 45665 45666 45667 45668 45669 45670 45671 45672 45673 45674 45675 45676 45677 45678 45679 45680 45681 45682 45683 45684 45685 45686 45687 45688 45689 45690 45691 45692 45693 45694 45695 45696 45697 45698 45699 45700 45701 45702 45703 45704 45705 45706 45707 45708 45709 45710 45711 45712 45713 45714 45715 45716 45717 45718 45719 45720 45721 45722 45723 45724 45725 45726 45727 45728 45729 45730 45731 45732 45733 45734 45735 45736 45737 45738 45739 45740 45741 45742 45743 45744 45745 45746 45747 45748 45749 45750 45751 45752 45753 45754 45755 45756 45757 45758 45759 45760 45761 45762 45763 45764 45765 45766 45767 45768 45769 45770 45771 45772 45773 45774 45775 45776 45777 45778 45779 45780 45781 45782 45783 45784 45785 45786 45787 45788 45789 45790 45791 45792 45793 45794 45795 45796 45797 45798 45799 45800 45801 45802 45803 45804 45805 45806 45807 45808 45809 45810 45811 45812 45813 45814 45815 45816 45817 45818 45819 45820 45821 45822 45823 45824 45825 45826 45827 45828 45829 45830 45831 45832 45833 45834 45835 45836 45837 45838 45839 45840 45841 45842 45843 45844 45845 45846 45847 45848 45849 45850 45851 45852 45853 45854 45855 45856 45857 45858 45859 45860 45861 45862 45863 45864 45865 45866 45867 45868 45869 45870 45871 45872 45873 45874 45875 45876 45877 45878 45879 45880 45881 45882 45883 45884 45885 45886 45887 45888 45889 45890 45891 45892 45893 45894 45895 45896 45897 45898 45899 45900 45901 45902 45903 45904 45905 45906 45907 45908 45909 45910 45911 45912 45913 45914 45915 45916 45917 45918 45919 45920 45921 45922 45923 45924 45925 45926 45927 45928 45929 45930 45931 45932 45933 45934 45935 45936 45937 45938 45939 45940 45941 45942 45943 45944 45945 45946 45947 45948 45949 45950 45951 45952 45953 45954 45955 45956 45957 45958 45959 45960 45961 45962 45963 45964 45965 45966 45967 45968 45969 45970 45971 45972 45973 45974 45975 45976 45977 45978 45979 45980 45981 45982 45983 45984 45985 45986 45987 45988 45989 45990 45991 45992 45993 45994 45995 45996 45997 45998 45999 46000 46001 46002 46003 46004 46005 46006 46007 46008 46009 46010 46011 46012 46013 46014 46015 46016 46017 46018 46019 46020 46021 46022 46023 46024 46025 46026 46027 46028 46029 46030 46031 46032 46033 46034 46035 46036 46037 46038 46039 46040 46041 46042 46043 46044 46045 46046 46047 46048 46049 46050 46051 46052 46053 46054 46055 46056 46057 46058 46059 46060 46061 46062 46063 46064 46065 46066 46067 46068 46069 46070 46071 46072 46073 46074 46075 46076 46077 46078 46079 46080 46081 46082 46083 46084 46085 46086 46087 46088 46089 46090 46091 46092 46093 46094 46095 46096 46097 46098 46099 46100 46101 46102 46103 46104 46105 46106 46107 46108 46109 46110 46111 46112 46113 46114 46115 46116 46117 46118 46119 46120 46121 46122 46123 46124 46125 46126 46127 46128 46129 46130 46131 46132 46133 46134 46135 46136 46137 46138 46139 46140 46141 46142 46143 46144 46145 46146 46147 46148 46149 46150 46151 46152 46153 46154 46155 46156 46157 46158 46159 46160 46161 46162 46163 46164 46165 46166 46167 46168 46169 46170 46171 46172 46173 46174 46175 46176 46177 46178 46179 46180 46181 46182 46183 46184 46185 46186 46187 46188 46189 46190 46191 46192 46193 46194 46195 46196 46197 46198 46199 46200 46201 46202 46203 46204 46205 46206 46207 46208 46209 46210 46211 46212 46213 46214 46215 46216 46217 46218 46219 46220 46221 46222 46223 46224 46225 46226 46227 46228 46229 46230 46231 46232 46233 46234 46235 46236 46237 46238 46239 46240 46241 46242 46243 46244 46245 46246 46247 46248 46249 46250 46251 46252 46253 46254 46255 46256 46257 46258 46259 46260 46261 46262 46263 46264 46265 46266 46267 46268 46269 46270 46271 46272 46273 46274 46275 46276 46277 46278 46279 46280 46281 46282 46283 46284 46285 46286 46287 46288 46289 46290 46291 46292 46293 46294 46295 46296 46297 46298 46299 46300 46301 46302 46303 46304 46305 46306 46307 46308 46309 46310 46311 46312 46313 46314 46315 46316 46317 46318 46319 46320 46321 46322 46323 46324 46325 46326 46327 46328 46329 46330 46331 46332 46333 46334 46335 46336 46337 46338 46339 46340 46341 46342 46343 46344 46345 46346 46347 46348 46349 46350 46351 46352 46353 46354 46355 46356 46357 46358 46359 46360 46361 46362 46363 46364 46365 46366 46367 46368 46369 46370 46371 46372 46373 46374 46375 46376 46377 46378 46379 46380 46381 46382 46383 46384 46385 46386 46387 46388 46389 46390 46391 46392 46393 46394 46395 46396 46397 46398 46399 46400 46401 46402 46403 46404 46405 46406 46407 46408 46409 46410 46411 46412 46413 46414 46415 46416 46417 46418 46419 46420 46421 46422 46423 46424 46425 46426 46427 46428 46429 46430 46431 46432 46433 46434 46435 46436 46437 46438 46439 46440 46441 46442 46443 46444 46445 46446 46447 46448 46449 46450 46451 46452 46453 46454 46455 46456 46457 46458 46459 46460 46461 46462 46463 46464 46465 46466 46467 46468 46469 46470 46471 46472 46473 46474 46475 46476 46477 46478 46479 46480 46481 46482 46483 46484 46485 46486 46487 46488 46489 46490 46491 46492 46493 46494 46495 46496 46497 46498 46499 46500 46501 46502 46503 46504 46505 46506 46507 46508 46509 46510 46511 46512 46513 46514 46515 46516 46517 46518 46519 46520 46521 46522 46523 46524 46525 46526 46527 46528 46529 46530 46531 46532 46533 46534 46535 46536 46537 46538 46539 46540 46541 46542 46543 46544 46545 46546 46547 46548 46549 46550 46551 46552 46553 46554 46555 46556 46557 46558 46559 46560 46561 46562 46563 46564 46565 46566 46567 46568 46569 46570 46571 46572 46573 46574 46575 46576 46577 46578 46579 46580 46581 46582 46583 46584 46585 46586 46587 46588 46589 46590 46591 46592 46593 46594 46595 46596 46597 46598 46599 46600 46601 46602 46603 46604 46605 46606 46607 46608 46609 46610 46611 46612 46613 46614 46615 46616 46617 46618 46619 46620 46621 46622 46623 46624 46625 46626 46627 46628 46629 46630 46631 46632 46633 46634 46635 46636 46637 46638 46639 46640 46641 46642 46643 46644 46645 46646 46647 46648 46649 46650 46651 46652 46653 46654 46655 46656 46657 46658 46659 46660 46661 46662 46663 46664 46665 46666 46667 46668 46669 46670 46671 46672 46673 46674 46675 46676 46677 46678 46679 46680 46681 46682 46683 46684 46685 46686 46687 46688 46689 46690 46691 46692 46693 46694 46695 46696 46697 46698 46699 46700 46701 46702 46703 46704 46705 46706 46707 46708 46709 46710 46711 46712 46713 46714 46715 46716 46717 46718 46719 46720 46721 46722 46723 46724 46725 46726 46727 46728 46729 46730 46731 46732 46733 46734 46735 46736 46737 46738 46739 46740 46741 46742 46743 46744 46745 46746 46747 46748 46749 46750 46751 46752 46753 46754 46755 46756 46757 46758 46759 46760 46761 46762 46763 46764 46765 46766 46767 46768 46769 46770 46771 46772 46773 46774 46775 46776 46777 46778 46779 46780 46781 46782 46783 46784 46785 46786 46787 46788 46789 46790 46791 46792 46793 46794 46795 46796 46797 46798 46799 46800 46801 46802 46803 46804 46805 46806 46807 46808 46809 46810 46811 46812 46813 46814 46815 46816 46817 46818 46819 46820 46821 46822 46823 46824 46825 46826 46827 46828 46829 46830 46831 46832 46833 46834 46835 46836 46837 46838 46839 46840 46841 46842 46843 46844 46845 46846 46847 46848 46849 46850 46851 46852 46853 46854 46855 46856 46857 46858 46859 46860 46861 46862 46863 46864 46865 46866 46867 46868 46869 46870 46871 46872 46873 46874 46875 46876 46877 46878 46879 46880 46881 46882 46883 46884 46885 46886 46887 46888 46889 46890 46891 46892 46893 46894 46895 46896 46897 46898 46899 46900 46901 46902 46903 46904 46905 46906 46907 46908 46909 46910 46911 46912 46913 46914 46915 46916 46917 46918 46919 46920 46921 46922 46923 46924 46925 46926 46927 46928 46929 46930 46931 46932 46933 46934 46935 46936 46937 46938 46939 46940 46941 46942 46943 46944 46945 46946 46947 46948 46949 46950 46951 46952 46953 46954 46955 46956 46957 46958 46959 46960 46961 46962 46963 46964 46965 46966 46967 46968 46969 46970 46971 46972 46973 46974 46975 46976 46977 46978 46979 46980 46981 46982 46983 46984 46985 46986 46987 46988 46989 46990 46991 46992 46993 46994 46995 46996 46997 46998 46999 47000 47001 47002 47003 47004 47005 47006 47007 47008 47009 47010 47011 47012 47013 47014 47015 47016 47017 47018 47019 47020 47021 47022 47023 47024 47025 47026 47027 47028 47029 47030 47031 47032 47033 47034 47035 47036 47037 47038 47039 47040 47041 47042 47043 47044 47045 47046 47047 47048 47049 47050 47051 47052 47053 47054 47055 47056 47057 47058 47059 47060 47061 47062 47063 47064 47065 47066 47067 47068 47069 47070 47071 47072 47073 47074 47075 47076 47077 47078 47079 47080 47081 47082 47083 47084 47085 47086 47087 47088 47089 47090 47091 47092 47093 47094 47095 47096 47097 47098 47099 47100 47101 47102 47103 47104 47105 47106 47107 47108 47109 47110 47111 47112 47113 47114 47115 47116 47117 47118 47119 47120 47121 47122 47123 47124 47125 47126 47127 47128 47129 47130 47131 47132 47133 47134 47135 47136 47137 47138 47139 47140 47141 47142 47143 47144 47145 47146 47147 47148 47149 47150 47151 47152 47153 47154 47155 47156 47157 47158 47159 47160 47161 47162 47163 47164 47165 47166 47167 47168 47169 47170 47171 47172 47173 47174 47175 47176 47177 47178 47179 47180 47181 47182 47183 47184 47185 47186 47187 47188 47189 47190 47191 47192 47193 47194 47195 47196 47197 47198 47199 47200 47201 47202 47203 47204 47205 47206 47207 47208 47209 47210 47211 47212 47213 47214 47215 47216 47217 47218 47219 47220 47221 47222 47223 47224 47225 47226 47227 47228 47229 47230 47231 47232 47233 47234 47235 47236 47237 47238 47239 47240 47241 47242 47243 47244 47245 47246 47247 47248 47249 47250 47251 47252 47253 47254 47255 47256 47257 47258 47259 47260 47261 47262 47263 47264 47265 47266 47267 47268 47269 47270 47271 47272 47273 47274 47275 47276 47277 47278 47279 47280 47281 47282 47283 47284 47285 47286 47287 47288 47289 47290 47291 47292 47293 47294 47295 47296 47297 47298 47299 47300 47301 47302 47303 47304 47305 47306 47307 47308 47309 47310 47311 47312 47313 47314 47315 47316 47317 47318 47319 47320 47321 47322 47323 47324 47325 47326 47327 47328 47329 47330 47331 47332 47333 47334 47335 47336 47337 47338 47339 47340 47341 47342 47343 47344 47345 47346 47347 47348 47349 47350 47351 47352 47353 47354 47355 47356 47357 47358 47359 47360 47361 47362 47363 47364 47365 47366 47367 47368 47369 47370 47371 47372 47373 47374 47375 47376 47377 47378 47379 47380 47381 47382 47383 47384 47385 47386 47387 47388 47389 47390 47391 47392 47393 47394 47395 47396 47397 47398 47399 47400 47401 47402 47403 47404 47405 47406 47407 47408 47409 47410 47411 47412 47413 47414 47415 47416 47417 47418 47419 47420 47421 47422 47423 47424 47425 47426 47427 47428 47429 47430 47431 47432 47433 47434 47435 47436 47437 47438 47439 47440 47441 47442 47443 47444 47445 47446 47447 47448 47449 47450 47451 47452 47453 47454 47455 47456 47457 47458 47459 47460 47461 47462 47463 47464 47465 47466 47467 47468 47469 47470 47471 47472 47473 47474 47475 47476 47477 47478 47479 47480 47481 47482 47483 47484 47485 47486 47487 47488 47489 47490 47491 47492 47493 47494 47495 47496 47497 47498 47499 47500 47501 47502 47503 47504 47505 47506 47507 47508 47509 47510 47511 47512 47513 47514 47515 47516 47517 47518 47519 47520 47521 47522 47523 47524 47525 47526 47527 47528 47529 47530 47531 47532 47533 47534 47535 47536 47537 47538 47539 47540 47541 47542 47543 47544 47545 47546 47547 47548 47549 47550 47551 47552 47553 47554 47555 47556 47557 47558 47559 47560 47561 47562 47563 47564 47565 47566 47567 47568 47569 47570 47571 47572 47573 47574 47575 47576 47577 47578 47579 47580 47581 47582 47583 47584 47585 47586 47587 47588 47589 47590 47591 47592 47593 47594 47595 47596 47597 47598 47599 47600 47601 47602 47603 47604 47605 47606 47607 47608 47609 47610 47611 47612 47613 47614 47615 47616 47617 47618 47619 47620 47621 47622 47623 47624 47625 47626 47627 47628 47629 47630 47631 47632 47633 47634 47635 47636 47637 47638 47639 47640 47641 47642 47643 47644 47645 47646 47647 47648 47649 47650 47651 47652 47653 47654 47655 47656 47657 47658 47659 47660 47661 47662 47663 47664 47665 47666 47667 47668 47669 47670 47671 47672 47673 47674 47675 47676 47677 47678 47679 47680 47681 47682 47683 47684 47685 47686 47687 47688 47689 47690 47691 47692 47693 47694 47695 47696 47697 47698 47699 47700 47701 47702 47703 47704 47705 47706 47707 47708 47709 47710 47711 47712 47713 47714 47715 47716 47717 47718 47719 47720 47721 47722 47723 47724 47725 47726 47727 47728 47729 47730 47731 47732 47733 47734 47735 47736 47737 47738 47739 47740 47741 47742 47743 47744 47745 47746 47747 47748 47749 47750 47751 47752 47753 47754 47755 47756 47757 47758 47759 47760 47761 47762 47763 47764 47765 47766 47767 47768 47769 47770 47771 47772 47773 47774 47775 47776 47777 47778 47779 47780 47781 47782 47783 47784 47785 47786 47787 47788 47789 47790 47791 47792 47793 47794 47795 47796 47797 47798 47799 47800 47801 47802 47803 47804 47805 47806 47807 47808 47809 47810 47811 47812 47813 47814 47815 47816 47817 47818 47819 47820 47821 47822 47823 47824 47825 47826 47827 47828 47829 47830 47831 47832 47833 47834 47835 47836 47837 47838 47839 47840 47841 47842 47843 47844 47845 47846 47847 47848 47849 47850 47851 47852 47853 47854 47855 47856 47857 47858 47859 47860 47861 47862 47863 47864 47865 47866 47867 47868 47869 47870 47871 47872 47873 47874 47875 47876 47877 47878 47879 47880 47881 47882 47883 47884 47885 47886 47887 47888 47889 47890 47891 47892 47893 47894 47895 47896 47897 47898 47899 47900 47901 47902 47903 47904 47905 47906 47907 47908 47909 47910 47911 47912 47913 47914 47915 47916 47917 47918 47919 47920 47921 47922 47923 47924 47925 47926 47927 47928 47929 47930 47931 47932 47933 47934 47935 47936 47937 47938 47939 47940 47941 47942 47943 47944 47945 47946 47947 47948 47949 47950 47951 47952 47953 47954 47955 47956 47957 47958 47959 47960 47961 47962 47963 47964 47965 47966 47967 47968 47969 47970 47971 47972 47973 47974 47975 47976 47977 47978 47979 47980 47981 47982 47983 47984 47985 47986 47987 47988 47989 47990 47991 47992 47993 47994 47995 47996 47997 47998 47999 48000 48001 48002 48003 48004 48005 48006 48007 48008 48009 48010 48011 48012 48013 48014 48015 48016 48017 48018 48019 48020 48021 48022 48023 48024 48025 48026 48027 48028 48029 48030 48031 48032 48033 48034 48035 48036 48037 48038 48039 48040 48041 48042 48043 48044 48045 48046 48047 48048 48049 48050 48051 48052 48053 48054 48055 48056 48057 48058 48059 48060 48061 48062 48063 48064 48065 48066 48067 48068 48069 48070 48071 48072 48073 48074 48075 48076 48077 48078 48079 48080 48081 48082 48083 48084 48085 48086 48087 48088 48089 48090 48091 48092 48093 48094 48095 48096 48097 48098 48099 48100 48101 48102 48103 48104 48105 48106 48107 48108 48109 48110 48111 48112 48113 48114 48115 48116 48117 48118 48119 48120 48121 48122 48123 48124 48125 48126 48127 48128 48129 48130 48131 48132 48133 48134 48135 48136 48137 48138 48139 48140 48141 48142 48143 48144 48145 48146 48147 48148 48149 48150 48151 48152 48153 48154 48155 48156 48157 48158 48159 48160 48161 48162 48163 48164 48165 48166 48167 48168 48169 48170 48171 48172 48173 48174 48175 48176 48177 48178 48179 48180 48181 48182 48183 48184 48185 48186 48187 48188 48189 48190 48191 48192 48193 48194 48195 48196 48197 48198 48199 48200 48201 48202 48203 48204 48205 48206 48207 48208 48209 48210 48211 48212 48213 48214 48215 48216 48217 48218 48219 48220 48221 48222 48223 48224 48225 48226 48227 48228 48229 48230 48231 48232 48233 48234 48235 48236 48237 48238 48239 48240 48241 48242 48243 48244 48245 48246 48247 48248 48249 48250 48251 48252 48253 48254 48255 48256 48257 48258 48259 48260 48261 48262 48263 48264 48265 48266 48267 48268 48269 48270 48271 48272 48273 48274 48275 48276 48277 48278 48279 48280 48281 48282 48283 48284 48285 48286 48287 48288 48289 48290 48291 48292 48293 48294 48295 48296 48297 48298 48299 48300 48301 48302 48303 48304 48305 48306 48307 48308 48309 48310 48311 48312 48313 48314 48315 48316 48317 48318 48319 48320 48321 48322 48323 48324 48325 48326 48327 48328 48329 48330 48331 48332 48333 48334 48335 48336 48337 48338 48339 48340 48341 48342 48343 48344 48345 48346 48347 48348 48349 48350 48351 48352 48353 48354 48355 48356 48357 48358 48359 48360 48361 48362 48363 48364 48365 48366 48367 48368 48369 48370 48371 48372 48373 48374 48375 48376 48377 48378 48379 48380 48381 48382 48383 48384 48385 48386 48387 48388 48389 48390 48391 48392 48393 48394 48395 48396 48397 48398 48399 48400 48401 48402 48403 48404 48405 48406 48407 48408 48409 48410 48411 48412 48413 48414 48415 48416 48417 48418 48419 48420 48421 48422 48423 48424 48425 48426 48427 48428 48429 48430 48431 48432 48433 48434 48435 48436 48437 48438 48439 48440 48441 48442 48443 48444 48445 48446 48447 48448 48449 48450 48451 48452 48453 48454 48455 48456 48457 48458 48459 48460 48461 48462 48463 48464 48465 48466 48467 48468 48469 48470 48471 48472 48473 48474 48475 48476 48477 48478 48479 48480 48481 48482 48483 48484 48485 48486 48487 48488 48489 48490 48491 48492 48493 48494 48495 48496 48497 48498 48499 48500 48501 48502 48503 48504 48505 48506 48507 48508 48509 48510 48511 48512 48513 48514 48515 48516 48517 48518 48519 48520 48521 48522 48523 48524 48525 48526 48527 48528 48529 48530 48531 48532 48533 48534 48535 48536 48537 48538 48539 48540 48541 48542 48543 48544 48545 48546 48547 48548 48549 48550 48551 48552 48553 48554 48555 48556 48557 48558 48559 48560 48561 48562 48563 48564 48565 48566 48567 48568 48569 48570 48571 48572 48573 48574 48575 48576 48577 48578 48579 48580 48581 48582 48583 48584 48585 48586 48587 48588 48589 48590 48591 48592 48593 48594 48595 48596 48597 48598 48599 48600 48601 48602 48603 48604 48605 48606 48607 48608 48609 48610 48611 48612 48613 48614 48615 48616 48617 48618 48619 48620 48621 48622 48623 48624 48625 48626 48627 48628 48629 48630 48631 48632 48633 48634 48635 48636 48637 48638 48639 48640 48641 48642 48643 48644 48645 48646 48647 48648 48649 48650 48651 48652 48653 48654 48655 48656 48657 48658 48659 48660 48661 48662 48663 48664 48665 48666 48667 48668 48669 48670 48671 48672 48673 48674 48675 48676 48677 48678 48679 48680 48681 48682 48683 48684 48685 48686 48687 48688 48689 48690 48691 48692 48693 48694 48695 48696 48697 48698 48699 48700 48701 48702 48703 48704 48705 48706 48707 48708 48709 48710 48711 48712 48713 48714 48715 48716 48717 48718 48719 48720 48721 48722 48723 48724 48725 48726 48727 48728 48729 48730 48731 48732 48733 48734 48735 48736 48737 48738 48739 48740 48741 48742 48743 48744 48745 48746 48747 48748 48749 48750 48751 48752 48753 48754 48755 48756 48757 48758 48759 48760 48761 48762 48763 48764 48765 48766 48767 48768 48769 48770 48771 48772 48773 48774 48775 48776 48777 48778 48779 48780 48781 48782 48783 48784 48785 48786 48787 48788 48789 48790 48791 48792 48793 48794 48795 48796 48797 48798 48799 48800 48801 48802 48803 48804 48805 48806 48807 48808 48809 48810 48811 48812 48813 48814 48815 48816 48817 48818 48819 48820 48821 48822 48823 48824 48825 48826 48827 48828 48829 48830 48831 48832 48833 48834 48835 48836 48837 48838 48839 48840 48841 48842 48843 48844 48845 48846 48847 48848 48849 48850 48851 48852 48853 48854 48855 48856 48857 48858 48859 48860 48861 48862 48863 48864 48865 48866 48867 48868 48869 48870 48871 48872 48873 48874 48875 48876 48877 48878 48879 48880 48881 48882 48883 48884 48885 48886 48887 48888 48889 48890 48891 48892 48893 48894 48895 48896 48897 48898 48899 48900 48901 48902 48903 48904 48905 48906 48907 48908 48909 48910 48911 48912 48913 48914 48915 48916 48917 48918 48919 48920 48921 48922 48923 48924 48925 48926 48927 48928 48929 48930 48931 48932 48933 48934 48935 48936 48937 48938 48939 48940 48941 48942 48943 48944 48945 48946 48947 48948 48949 48950 48951 48952 48953 48954 48955 48956 48957 48958 48959 48960 48961 48962 48963 48964 48965 48966 48967 48968 48969 48970 48971 48972 48973 48974 48975 48976 48977 48978 48979 48980 48981 48982 48983 48984 48985 48986 48987 48988 48989 48990 48991 48992 48993 48994 48995 48996 48997 48998 48999 49000 49001 49002 49003 49004 49005 49006 49007 49008 49009 49010 49011 49012 49013 49014 49015 49016 49017 49018 49019 49020 49021 49022 49023 49024 49025 49026 49027 49028 49029 49030 49031 49032 49033 49034 49035 49036 49037 49038 49039 49040 49041 49042 49043 49044 49045 49046 49047 49048 49049 49050 49051 49052 49053 49054 49055 49056 49057 49058 49059 49060 49061 49062 49063 49064 49065 49066 49067 49068 49069 49070 49071 49072 49073 49074 49075 49076 49077 49078 49079 49080 49081 49082 49083 49084 49085 49086 49087 49088 49089 49090 49091 49092 49093 49094 49095 49096 49097 49098 49099 49100 49101 49102 49103 49104 49105 49106 49107 49108 49109 49110 49111 49112 49113 49114 49115 49116 49117 49118 49119 49120 49121 49122 49123 49124 49125 49126 49127 49128 49129 49130 49131 49132 49133 49134 49135 49136 49137 49138 49139 49140 49141 49142 49143 49144 49145 49146 49147 49148 49149 49150 49151 49152 49153 49154 49155 49156 49157 49158 49159 49160 49161 49162 49163 49164 49165 49166 49167 49168 49169 49170 49171 49172 49173 49174 49175 49176 49177 49178 49179 49180 49181 49182 49183 49184 49185 49186 49187 49188 49189 49190 49191 49192 49193 49194 49195 49196 49197 49198 49199 49200 49201 49202 49203 49204 49205 49206 49207 49208 49209 49210 49211 49212 49213 49214 49215 49216 49217 49218 49219 49220 49221 49222 49223 49224 49225 49226 49227 49228 49229 49230 49231 49232 49233 49234 49235 49236 49237 49238 49239 49240 49241 49242 49243 49244 49245 49246 49247 49248 49249 49250 49251 49252 49253 49254 49255 49256 49257 49258 49259 49260 49261 49262 49263 49264 49265 49266 49267 49268 49269 49270 49271 49272 49273 49274 49275 49276 49277 49278 49279 49280 49281 49282 49283 49284 49285 49286 49287 49288 49289 49290 49291 49292 49293 49294 49295 49296 49297 49298 49299 49300 49301 49302 49303 49304 49305 49306 49307 49308 49309 49310 49311 49312 49313 49314 49315 49316 49317 49318 49319 49320 49321 49322 49323 49324 49325 49326 49327 49328 49329 49330 49331 49332 49333 49334 49335 49336 49337 49338 49339 49340 49341 49342 49343 49344 49345 49346 49347 49348 49349 49350 49351 49352 49353 49354 49355 49356 49357 49358 49359 49360 49361 49362 49363 49364 49365 49366 49367 49368 49369 49370 49371 49372 49373 49374 49375 49376 49377 49378 49379 49380 49381 49382 49383 49384 49385 49386 49387 49388 49389 49390 49391 49392 49393 49394 49395 49396 49397 49398 49399 49400 49401 49402 49403 49404 49405 49406 49407 49408 49409 49410 49411 49412 49413 49414 49415 49416 49417 49418 49419 49420 49421 49422 49423 49424 49425 49426 49427 49428 49429 49430 49431 49432 49433 49434 49435 49436 49437 49438 49439 49440 49441 49442 49443 49444 49445 49446 49447 49448 49449 49450 49451 49452 49453 49454 49455 49456 49457 49458 49459 49460 49461 49462 49463 49464 49465 49466 49467 49468 49469 49470 49471 49472 49473 49474 49475 49476 49477 49478 49479 49480 49481 49482 49483 49484 49485 49486 49487 49488 49489 49490 49491 49492 49493 49494 49495 49496 49497 49498 49499 49500 49501 49502 49503 49504 49505 49506 49507 49508 49509 49510 49511 49512 49513 49514 49515 49516 49517 49518 49519 49520 49521 49522 49523 49524 49525 49526 49527 49528 49529 49530 49531 49532 49533 49534 49535 49536 49537 49538 49539 49540 49541 49542 49543 49544 49545 49546 49547 49548 49549 49550 49551 49552 49553 49554 49555 49556 49557 49558 49559 49560 49561 49562 49563 49564 49565 49566 49567 49568 49569 49570 49571 49572 49573 49574 49575 49576 49577 49578 49579 49580 49581 49582 49583 49584 49585 49586 49587 49588 49589 49590 49591 49592 49593 49594 49595 49596 49597 49598 49599 49600 49601 49602 49603 49604 49605 49606 49607 49608 49609 49610 49611 49612 49613 49614 49615 49616 49617 49618 49619 49620 49621 49622 49623 49624 49625 49626 49627 49628 49629 49630 49631 49632 49633 49634 49635 49636 49637 49638 49639 49640 49641 49642 49643 49644 49645 49646 49647 49648 49649 49650 49651 49652 49653 49654 49655 49656 49657 49658 49659 49660 49661 49662 49663 49664 49665 49666 49667 49668 49669 49670 49671 49672 49673 49674 49675 49676 49677 49678 49679 49680 49681 49682 49683 49684 49685 49686 49687 49688 49689 49690 49691 49692 49693 49694 49695 49696 49697 49698 49699 49700 49701 49702 49703 49704 49705 49706 49707 49708 49709 49710 49711 49712 49713 49714 49715 49716 49717 49718 49719 49720 49721 49722 49723 49724 49725 49726 49727 49728 49729 49730 49731 49732 49733 49734 49735 49736 49737 49738 49739 49740 49741 49742 49743 49744 49745 49746 49747 49748 49749 49750 49751 49752 49753 49754 49755 49756 49757 49758 49759 49760 49761 49762 49763 49764 49765 49766 49767 49768 49769 49770 49771 49772 49773 49774 49775 49776 49777 49778 49779 49780 49781 49782 49783 49784 49785 49786 49787 49788 49789 49790 49791 49792 49793 49794 49795 49796 49797 49798 49799 49800 49801 49802 49803 49804 49805 49806 49807 49808 49809 49810 49811 49812 49813 49814 49815 49816 49817 49818 49819 49820 49821 49822 49823 49824 49825 49826 49827 49828 49829 49830 49831 49832 49833 49834 49835 49836 49837 49838 49839 49840 49841 49842 49843 49844 49845 49846 49847 49848 49849 49850 49851 49852 49853 49854 49855 49856 49857 49858 49859 49860 49861 49862 49863 49864 49865 49866 49867 49868 49869 49870 49871 49872 49873 49874 49875 49876 49877 49878 49879 49880 49881 49882 49883 49884 49885 49886 49887 49888 49889
|
2025-07-30 Automatically generated <bug-mailutils@gnu.org>
HEAD 8e453b8207d80d9cf0449ef4c330deb052dd643b.
2025-07-30 Sergey Poznyakoff <gray@gnu.org>
Version 3.20.
2025-07-18 Sergey Poznyakoff <gray@gnu.org>
Fix in IMAP SEARCH.
The UID SEARCH command incorrectly treated message range
argument as UIDs instead of as message sequence numbers.
* imap4d/search.c (parse_simple_key): The UID prefix does not
affect the handling of sequence numbers.
* imap4d/tests/search.at: Check if UID SEARCH handles sequence
argument properly.
2025-06-14 Sergey Poznyakoff <gray@gnu.org>
Version 3.19.90.
* configure.ac: Raise version number.
* NEWS: Document the uidnew test.
* doc/texinfo/sieve.texi: Likewise.
2025-06-14 Sergey Poznyakoff <gray@gnu.org>
New sieve test: uidnew.
* libmu_sieve/extensions/uidnew.c: New file.
* libmu_sieve/extensions/Makefile.am: Build uidnew.la
* libmailutils/tests/url.at: Test handling of "~" when
MU_URL_PARSE_LOCAL flag is set.
* libmailutils/url/create.c (_mu_url_ctx_parse_path) If
MU_URL_PARSE_LOCAL flag is set, expand tilde in the pathname.
(_mu_url_ctx_parse_host): Tilde pertains to path, not to the
host.
2025-06-12 Sergey Poznyakoff <gray@gnu.org>
maildir: add compatibility tests.
* libproto/maildir/maildir.c (isync_meta_update): Handle
unexistent .uidvalidity file.
* libproto/maildir/tests/Makefile.am: Add new tests.
* libproto/maildir/tests/testsuite.at: Likewsise.
* libproto/maildir/tests/isynccreat.at: New file.
* libproto/maildir/tests/isyncread.at: New file.
* libproto/maildir/tests/isyncwrite.at: New file.
* libproto/maildir/tests/attfixup.at: Add copyleft header.
* libproto/maildir/tests/uidfixup.at: Likewise.
* libproto/maildir/tests/autodetect.at: Add autotest mode
marker.
* libproto/maildir/tests/notify.at: Likewise.
2025-06-12 Sergey Poznyakoff <gray@gnu.org>
maildir: create old-fashion delivery IDs in comparibility mode.
Use URL parameters to explicitly set compatibility mode:
detect - detect the mode automatically (default);
none, mu - mailutils mode (modern delivery ids);
isync - isync mode (old-fashioned delivery ids).
* libmailutils/url/expand.c (mu_url_expand_path): Silently
ignore unrecognized parameters.
* libproto/maildir/maildir.c (maildir_open): Check URL
parameters for compatibility mode settings.
(maildir_scan_unlocked): Set compatibility mode to none, if not
determined after mailbox scanning (that means an empty
mailbox).
(maildir_uniq_create): Rewrite. Create old-fashion delivery
ids, if in isync compatibility mode. Insert random part id (R)
when in normal mode.
2025-06-11 Sergey Poznyakoff <gray@gnu.org>
Improve maildir compatibility mode.
* libproto/maildir/maildir.c (maildir_scan_unlocked)
(maildir_msg_finish_delivery): Update isync .uidvalidity file.
* include/mailutils/sys/amd.h (amd_get_uidvalidity): New proto.
* libmailutils/base/amd.c (amd_get_uidvalidity): Make external.
2025-06-09 Sergey Poznyakoff <gray@gnu.org>
imap: recognize MU_ATTRIBUTE_SEEN.
* libproto/imap/select.c (_mu_imap_collect_flags): Unless
MU_ATTRIBUTE_RECENT is set, raise MU_ATTRIBUTE_SEEN.
2025-06-09 Sergey Poznyakoff <gray@gnu.org>
imap: avoid needless rescanning of mailboxes.
* libproto/imap/mailbox.c (_imap_mbx_scan): Return immediately
if the mailbox is up to date. All uses updated.
(_imap_mbx_open): Don't scan the mailbox.
2025-06-09 Sergey Poznyakoff <gray@gnu.org>
Minor change.
* libproto/imap/mailbox.c (_imap_mbx_scan): Do notification
loop only if observable is defined.
2025-06-08 Sergey Poznyakoff <gray@gnu.org>
movemail: support uidnext synchronization mode.
* doc/texinfo/programs/movemail.texi: Document changes.
* NEWS: Likewise.
* movemail/movemail.c: Remove the --reverse option. The
--max-messages option counts latest messages. New options:
--sync=mode sets the synchronization mode (all, uidnext,
uidl).
--sync-dir=dir sets the directory for storing synchronization
metadata.
--uidl now a synonim for --sync=uidl
* include/mailutils/mailbox.h (mu_mailbox_get_iterator_at): New
proto.
(mu_mailbox_get_iterator): Rewrite as inline function.
* include/mailutils/sys/imap.h
(_mu_imap_list_nth_element_is_string)
(_mu_imap_list_nth_element_is_string_ci)
(_mu_imap_list_at): Change the type of the position argument to
size_t.
* libmailutils/mailbox/mbxitr.c (struct mailbox_iterator): New
fields: start, stop.
(mbx_first): Start from itr->start.
(mbx_finished_p): If stop is set, stop after returning the
corresponding message.
(mu_mailbox_get_iterator_at): New function. Returns iterator
between two given message numbers or UIDs.
* libproto/imap/mailbox.c (_imap_mbx_get_message): Initialize
the _get_uid method.
* libproto/imap/resplist.c (_mu_imap_list_at): Change the type
of the position argument to size_t. If negative, count position
from the end of the list. (_mu_imap_list_nth_element_is_string)
(_mu_imap_list_nth_element_is_string_ci): Change the type of
the position argument to size_t.
* libproto/imap/resproc.c (parse_response_code): Fix list
parsing.
* libproto/maildir/maildir.c (maildir_create): Reset uidnext.
(maildir_create): Reset uidnext.
(maildir_scan0): Scan mailboxes opened for appends as well.
* libproto/pop/mailbox.c (pop_get_message): Implement the
_get_uidl method.
2025-06-07 Sergey Poznyakoff <gray@gnu.org>
maildir: compatibility mode with old-fashioned delivery
identifiers.
In particular, this provides compatibility with mailboxes
created by isync.
* include/mailutils/sys/amd.h (amd_update_uidvalidity): New
proto.
(MU_AMD_F_SCANNING): New flag.
* libmailutils/base/amd.c (_amd_prop_create): Set the ro field
in accordance with the mailbox open flags.
(_amd_scan0): Avoid recursion. Set MU_AMD_F_INIT_SCAN bit on
return.
(amd_update_uidvalidity): New function.
(amd_update_uidnext): Do nothing if current and proposed values
are equal.
* libproto/maildir/maildir.c (MAILDIR_COMPAT_DETECT)
(MAILDIR_COMPAT_NONE, MAILDIR_COMPAT_ISYNC): New constants.
(_maildir_data): New fields: compat and cur_uid. Replace
needs_uid_fixup with update_uidvalidity.
(struct _maildir_message): New fields: tv, pid, ndlv, flags.
(reset_uid): Initialize cur_uid.
(parse_delivery_id): New function.
(maildir_open): Early attempt to determine MAILDIR_COMPAT_ISYNC
maildir: if the .uidvalidity exists and its first two lines are
unsigned integers (uidvalidity and last used uid).
(maildir_message_alloc): Parse the delivery identifier and
determine compatibility mode (unless already set), based on
whether uppercase "U" is used to store the UID.
(maildir_subdir_scan): Take additional argument indicating
whether it is the initial mailbox scan. If so, check for
duplicates (message names that compare equal).
(maildir_message_fixup): Take the update flag as argument.
Rewrite the UID fixup logic.
(maildir_scan_unlocked): Change message incorporation logic.
Messages in new are assigned explicit UIDs now.
(string_buffer_format_message_name): Depending on compatibility
mode, use lower or uppercase "u" attribute.
(maildir_new_message_name): Store UID in the message name both
in cur and new.
(maildir_msg_finish_delivery): Ditto.
(maildir_message_cmp): Rewrite using parsed out delivery ids.
(maildir_chattr_msg,maildir_msg_init): Parse delivery id.
* mh/sortm.c (sort): Reset uidvalidity after reopening the
mailbox in read-write mode (see the change to _amd_prop_create,
above).
* testsuite/mbop.c: New operation: echo.
2025-06-06 Sergey Poznyakoff <gray@gnu.org>
Fix possible NULL pointer dereference.
* libmailutils/base/assoc.c (mu_assoc_shift): Fix typo in
conditional.
2025-05-28 Sergey Poznyakoff <gray@gnu.org>
Fix coredump in mail.
* mail/alias.c (alias_expand): Handle NULL argument.
2025-03-24 Jordi Mallach <jordi@mallach.net>
Fix missing format arguments for builds with -Wformat-security.
libmailutils/diag/debug.c (mu_debug_format_spec): Add missing
"%s" to printf to avoid triggering -Wformat-security.
2025-03-24 Sergey Poznyakoff <gray@gnu.org>
Minor fix.
2025-03-22 Sergey Poznyakoff <gray@gnu.org>
Version 3.19.
2025-02-26 Sergey Poznyakoff <gray@gnu.org>
filters: revise buffer requirements on returning
mu_filter_more(in|out)put.
2025-02-22 Sergey Poznyakoff <gray@gnu.org>
mail: allow for part spec after any message designator (., ^,
etc).
* mail/msgset.y (DELIM): New token.
(yylex): Generate DELIM token when advancing to the next
argument.
(msgset production): change syntax using delim nonterminal.
(msgexpr): Allow for optional delimiter after ! and { and
before }.
(msgspec): Allow for leading dot: "dec .2.1" meaning the same
as "dec ..2.1", i.e. decode subpart 2.1 of the current message.
(msg): Accept part specifiers after ^ (-), and $ (+).
2025-01-23 orbea <orbea@riseup.net>
libproto tests: link using the libtool archives.
When using slibtool the build fails when it doesn't find
-lmu_tesh. This can be solved by linking internal dependencies
with the generated libtool archive (.la) file.
2025-01-07 Sergey Poznyakoff <gray@gnu.org>
Fix testsuite (mda & mail) to work with arbitrary default
mailbox type.
* mail/testsuite/lib/mail.exp (default_mail_start): Force mbox
mailbox type.
* mda/mda/tests/forward.at: Likewise.
* mda/mda/tests/mda.at: Likewise.
* mda/tests/mda.sh (dumpmail): Handle only mbox.
2025-01-03 Sergey Poznyakoff <gray@gnu.org>
Update doc/texinfo/html.init for use with Texinfo > 6.8.
2025-01-03 Sergey Poznyakoff <gray@gnu.org>
Version 3.18.
2025-01-02 Sergey Poznyakoff <gray@gnu.org>
Update copyleft statements.
2024-12-31 Sergey Poznyakoff <gray@gnu.org>
Require the latest libtool; fix a distcheck failure.
* configure.ac (AM_INIT_AUTOMAKE): Switch strictness from gnits
to gnu. Gnits is equivalent to "gnu readme-alpha check-news
std-options". Among these, std-options causes grief when make
distcheck is run on a system with a previous mailutils version
installed, if one of the shared libraries of that version (most
often, libmuaux.so) are not entirely compatible with those of
the version being checked. Std-options inserts a Makefile goal
that runs each installed binary with --help and --version
option. During make distcheck, that binary will be the one
installed to the _inst subdirectory. It will expect shared
libraries from the version of Mailutils it comes from, but the
runtime loader will link it to the ones installed on the system
(this is somewhat similar to the effects described in
https://gray.gnu.org.ua/public/ltbug, although not directly
related to libtool). Thus, the binary might fail to start, e.g.
if it doesn't encounter a symbol in the library. To avoid this,
the "gnits" strictness is replaced with "gnu readme-alpha
check-news".
(LT_PREREQ): Require version 2.5.4, which fixes bugs described
in the link above.
* bootstrap.conf (bootstrap_epilogue): Remove.
* patches/ltmain.sh-2.4.6.patch: Remove.
* patches/ltmain.sh-2.4.7.patch: Remove.
2024-10-30 Sergey Poznyakoff <gray@gnu.org>
Various bugfixes.
* imap4d/namespace.c (namespace_translate_name): Fix use after
free.
* imap4d/tests/testclient.c: Increase static buffer size.
* libmailutils/base/removefile.c (check_parent_access): Fix use
after free.
* libmailutils/mailbox/mailbox.c (mu_mailbox_destroy):
Likewise.
* libmailutils/mailer/mailer.c (mu_mailer_destroy): Likewise.
* libmailutils/server/acl.c (mu_acl_destroy): Assign NULL to
the argument location.
* mh/mh_format.c (mh_fvm_destroy): Likewise.
* libmailutils/wordsplit: Pull new version.
* libmailutils/tests/Makefile.am: Fix rules for building wsp.
* libmailutils/tests/mailcap.at: Change expected strings.
* libmu_auth/virtual.c: Remove unused variables.
* mh/mh_init.c (mh_find_file): Fix argument to mu_diag_output.
* pop3d/apop.c: Remove unused variables.
2024-10-30 Sergey Poznyakoff <gray@gnu.org>
Bugfix.
* libmu_scm/mu_scm.c (format_table): Fix typo. Patch by Timothy
Sample.
2024-10-10 Don Stokes <don@nz.net>
Bugfix in mu_utc_offset.
This fixes incorrect handling of time zones with the offset of
more than 12 hours out from UTC, e.g. NZ daylight time.
* libmailutils/datetime/utcoff.c: Use the day of the month to
account for day changes.
2024-09-02 Sergey Poznyakoff <gray@gnu.org>
Update FSF address.
2024-09-01 Sergey Poznyakoff <gray@gnu.org>
Bugfix in stream ioctl.
* libmailutils/stream/memory_stream.c (_memory_ioctl): Fix
improperly used parameter.
* libmailutils/stream/tcp.c (_tcp_ioctl): Handle
MU_IOCTL_TRANSPORT_BUFFER.
2024-08-26 Sergey Poznyakoff <gray@gnu.org>
Minor change.
* libmailutils/cidr/fromstr.c (mu_cidr_from_string): Mask out
extra address bits to obtain first IP of the range.
* libmailutils/tests/strtoc.c: Test this.
2024-07-17 Sergey Poznyakoff <gray@gnu.org>
Complement 5380651f84a1e00c5b8ffa27f27851c3cd97981c.
* libmu_sieve/tests.c (retrieve_envelope): Apply same error
translation as in retrieve_address.
2024-06-26 Sergey Poznyakoff <gray@gnu.org>
Bugfix.
* libmu_sieve/load.c (load_module): Produce correct diagnostics
if "init" not found".
2024-06-26 Sergey Poznyakoff <gray@gnu.org>
sieve pipe action: handle error return from mu_stream_close.
2024-06-23 Sergey Poznyakoff <gray@gnu.org>
sieve: don't bail out on malformed email addresses.
* libmu_sieve/tests.c: Handle MU_ERR_EMPTY_ADDRESS as missing
email address (MU_ERR_NOENT).
2024-06-17 Sergey Poznyakoff <gray@gnu.org>
Version 3.17.90.
* NEWS: Update version numger.
* configure.ac: Likewise.
* gnulib.modules: Use gettext-h instead of gettext.
* libmailutils/filter/Makefile.am: Remove unneeded -I option.
2024-06-17 Sergey Poznyakoff <gray@gnu.org>
Makefile.am's: Remove erroneous -I options.
2024-06-13 Sergey Poznyakoff <gray@gnu.org>
manual: discuss configuration files used by the mail utility.
2024-06-13 Sergey Poznyakoff <gray@gnu.org>
mail: several improvements in the variables interface.
* include/mailutils/filter.h (mu_iconv_fallback_name): New
proto.
* libmailutils/filter/decode.c (mu_iconv_fallback_name): New
function.
* mail/mail.c: Use mailvar_init_variables to initialize
variables that depend on mailutils settings and/or current
environment.
* mail/mail.h (mailvar_init_variables): New proto.
* mail/mailvar.c (mailvar_symbol): New field: init. Provide
initialization functions for variables that need it.
(mailvar_init_variables): New function.
(mail_variable): Sort output lexicographically.
2024-06-13 Sergey Poznyakoff <gray@gnu.org>
Bugfix in mu_get_host_name.
* libmailutils/base/hostname.c (mu_get_host_name): Initialize
hints.
2024-06-13 Sergey Poznyakoff <gray@gnu.org>
mail: use the mailer capability.
2024-06-12 Sergey Poznyakoff <gray@gnu.org>
Provide a debugging category shortcut "all".
* doc/texinfo/programs.texi: Document the "all"
pseudo-category.
* include/mailutils/debug.h (mu_debug_category_match): New
proto.
(mu_debug_level_p): Rewrite as inline function.
(MU_DEBUG_FORMAT_DEFAULT,MU_DEBUG_FORMAT_SHOWUNSET)
(MU_DEBUG_FORMAT_COMPRESS,MU_DEBUG_FORMAT_SORT): New macros.
(mu_debug_category_from_string)
(mu_debug_level_from_string): New protos.
* libmailutils/diag/debug.c: Change handling of the isset
field.
(mu_debug_category_match): Don't check isset.
(mu_debug_get_category_level): Likewise.
(mu_debug_enable_category)
(mu_debug_disable_category): Apply to all categories if
catn==0.
(mu_debug_category_from_string): New function.
(mu_debug_level_from_string): Remove static qualifier.
(mu_debug_format_spec): Change semantics of the last argument.
It is a bitmask of:
- MU_DEBUG_FORMAT_SHOWUNSET include unset categories;
- MU_DEBUG_FORMAT_COMPRESS try to compress output by using the
"all"
shortcut;
- MU_DEBUG_FORMAT_SORT sort categories alphabetically;
* libmailutils/tests/debugspec.at: Add new tests.
* libmailutils/tests/debugspec.c: New options: -compress,
-sort, -quiet. Take an optional list of category.level pairs.
Print enable status (true/false) for each of them.
2024-06-11 Sergey Poznyakoff <gray@gnu.org>
Minor fix in mhn and related tests.
* mh/mhn.c (store_handler): When piping the output, make sure
to flush stdout beforhand.
* mh/tests/mhed: Don't create file named "-".
* mh/tests/mhn.at: Fix expected output.
2024-06-11 Sergey Poznyakoff <gray@gnu.org>
Change handling of libtool bugs.
* bootstrap.conf (bootstrap_epilogue): Patch installed version
of ltmain.sh.
* mu-aux/ltmain.sh: Remove.
* patches/README: New file.
* patches/ltmain.sh-2.4.6.patch: New file.
* patches/ltmain.sh-2.4.7.patch: New file.
2024-03-22 Sergey Poznyakoff <gray@gnu.org>
Fix typo in mailutils dbm dump example.
2024-03-22 Sergey Poznyakoff <gray@gnu.org>
Mention nmh scan -file option when discussing MH implementation
differences.
2024-03-22 Sergey Poznyakoff <gray@gnu.org>
Fix ehlo command in the smtp client.
The bug spotted by Christophe Deleuze in
https://savannah.gnu.org/patch/?10439
* libproto/mailer/smtp_capa.c (mu_smtp_capa_test): Issue ehlo
only when in the corresponding state. Return MU_ERR_NOENT if
the requested capability is not found, including the case when
the capability array is null because of one-line ehlo response
or because plain SMTP is in use.
* libproto/mailer/smtp_capa_itr.c (mu_smtp_capa_iterator):
Likewise.
* libproto/mailer/smtp_ehlo.c (mu_smtp_ehlo): Fail if not in
the MU_SMTP_EHLO state. Set MU_SMTP_MAIL on success.
* libproto/mailer/smtp_gsasl.c (_mu_smtp_gsasl_auth): Reset
stat to MU_SMTP_EHLO.
* libproto/mailer/smtp_starttls.c (mu_smtp_starttls): Likewise.
2024-01-06 Sergey Poznyakoff <gray@gnu.org>
Version 3.17.
2024-01-06 Sergey Poznyakoff <gray@gnu.org>
Update copyright years.
2024-01-06 Sergey Poznyakoff <gray@gnu.org>
New dbm function: mu_dbm_break.
This function deallocates resources allocated by
mu_dbm_firstkey function. It should be used when breaking from
a loop iterating over all keys in the database.
* include/mailutils/dbm.h (mu_dbm_impl): New field: _dbm_break
(mu_dbm_break): New function.
* libmu_dbm/break.c: New file.
* libmu_dbm/Makefile.am (libmu_dbm_la_SOURCES): Add break.c
* libmu_dbm/berkeley.c (_bdb_close): Close cursor, if
available.
(_bdb_break): New method.
* libmu_dbm/gdbm.c (_gdbm_break): New method.
2023-06-09 Sergey Poznyakoff <gray@gnu.org>
Add missing includes.
2023-05-24 Sergey Poznyakoff <gray@gnu.org>
Fix definition of -P option in movemail.
2023-05-09 Sergey Poznyakoff <gray@gnu.org>
Fix global timeout and transcript statements in pop3d and
imap4d.
* include/mailutils/server.h (mu_m_server_config_default_fp):
New data type.
(mu_m_server_set_config_default): New prototype.
* libmailutils/server/msrv.c (_mu_m_server): New field:
config_default.
(mu_m_server_set_config_default): New function.
(mu_m_server_listen): If config_default is initialized, call it
to initialize the pconf structure.
* imap4d/imap4d.c (imap4d_connection): Don't reset idle_timeout
and imap4d_transcript.
(imap4d_config_default): New function.
(main): Initialize the server's config_default function.
* pop3d/apop.c (apop_ok): New function.
* pop3d/pop3d.c (pop3d_mainloop): Don't include timestamp in
the banner greeting if APOP database is not available.
(pop3d_config_default): New function.
(main): Initialize the server's config_default function.
* pop3d/pop3d.h (apop_ok): New prototype.
2023-05-07 Sergey Poznyakoff <gray@gnu.org>
Improve file safety checking routine.
* libmailutils/base/filesafety.c (mu_file_safety_check): Accept
symbolic links. Fix memory leak.
2023-05-07 Sergey Poznyakoff <gray@gnu.org>
pop3d, imap4d: global tls-mode is used only when the mode to
use cannot be determined otherwise.
2023-05-04 Sergey Poznyakoff <gray@gnu.org>
pop3d, imap4d: if not set explicitly, derive tls mode from the
port used.
* NEWS: Version 3.16.90
* configure.ac: Likewise.
* imap4d/imap4d.c (main): Use PORT_IMAP4 constant.
* imap4d/imap4d.h (PORT_IMAP4,PORT_IMAP4S): New defines.
* imap4d/starttls.c (starttls_server_check): Derive the tls
mode from the port used or from the global tls mode.
* include/mailutils/sockaddr.h (mu_sockaddr_get_port): New
proto.
* libmailutils/sockaddr/Makefile.am: Add port.c
* libmailutils/sockaddr/port.c: New file.
* mu/libexec/shell.c (readline): Minor change.
* pop3d/cmd.c (stls_server_check): Derive the tls mode from the
port used or from the global tls mode.
* pop3d/pop3d.c (main): Use PORT_POP3 constant.
* pop3d/pop3d.h (PORT_POP3, PORT_POP3S): New defines.
2023-05-03 Sergey Poznyakoff <gray@gnu.org>
Bugfix in mu tool.
* mu/libexec/shell.c [!WITH_READLINE] (readline): Remove static
qualifiers.
2023-05-01 Sergey Poznyakoff <gray@gnu.org>
Version 3.16.
2023-05-01 Sergey Poznyakoff <gray@gnu.org>
Remove leftover uses of gethostby* functions.
* configure.ac: Remove check for gethostbyname
* include/mailutils/util.h: Fix comment.
* imap4d/util.c: Use getaddrinfo.
* libmailutils/base/hostname.c: Likewise.
* libmailutils/sockaddr/fromnode.c: Likewise.
* libmu_auth/virtual.c: Use getnameinfo.
2023-05-01 Sergey Poznyakoff <gray@gnu.org>
Minor fixes.
* NEWS: Update.
* libmu_scm/tests/testsuite.at: Fix improper use of AT_TESTED.
* maint/release.mk (GNUPLOAD): New variable.
* configure.ac: New maintainer option --with-gnupload.
2023-04-30 Sergey Poznyakoff <gray@gnu.org>
Switch to newer autotools.
* configure.ac: Require autoconf 2.71, automake 1.16.2 Don't
use obsolete macros. Drop support for Berkeley DB 2.
* gint: Upgrade.
* gnulib: Upgrade.
* am/db2.m4: Remove. Support for bdb2 withdrawn.
* libmu_dbm/berkeley.c: Drop support for bdb2.
* am/config_paths.m4: Don't use obsolete autoconf macros.
* am/debug.m4: Likewise.
* am/enable.m4: Likewise.
* am/gsasl.m4: Likewise.
* am/gssapi.m4: Likewise.
* am/ipv6.m4: Likewise.
* am/tls.m4: Likewise.
* mail/mail.h (mailvar_value): Rename bool to boolean to avoid
eventual conflicts. All uses changed.
* comsat/comsat.c: Remove the uses of RETSIGTYPE.
* examples/echosrv.c: Likewise.
* imap4d/bye.c: Likewise.
* imap4d/imap4d.c: Likewise.
* imap4d/imap4d.h: Likewise.
* imap4d/signal.c: Likewise.
* lib/muaux.h: Likewise.
* lib/signal.c: Likewise.
* libmailutils/mailer/progmailer.c: Likewise.
* libmailutils/server/msrv.c: Likewise.
* libmu_sieve/extensions/spamd.c: Likewise.
* mh/mhn.c: Likewise.
* mh/prompter-tty.c: Likewise.
* mh/sortm.c: Likewise.
* pop3d/pop3d.h: Likewise.
* pop3d/signal.c: Likewise.
2023-02-21 Sergey Poznyakoff <gray@gnu.org>
Fix coredump in mail.
Patch proposed by Dave Love <Dave.Love@manchester.ac.uk>
* mail/util.c (util_get_charset): Check if charset is not NULL
before strdup'ing it.
2023-01-22 Sergey Poznyakoff <gray@gnu.org>
Update copyright years.
2022-12-27 Sergey Poznyakoff <gray@gnu.org>
Various fixes.
* NEWS: Document changes.
* configure.ac: Version 3.15.90
* libmailutils/stdstream/strerr.c (mu_stdstream_strerr_setup):
Don't destroy mu_strerr unconditionally, use mu_stream_unref.
* frm/common.c (format_field_align): Initialize local variable.
* lib/mailcap.c (mime_context_get_temp_file): Issue diagnostics
on error.
(expand_string): Return -1 if the temp file creation fails.
(create_filter,run_test,run_mailcap): Improve error checking.
* libmailutils/base/fgetpwent.c (mu_fgetpwent_r): Fix use of
uninitialized variables.
* libmailutils/mailbox/msgqlines.c (mu_message_quick_lines):
Likewise.
* libmailutils/mime/mimeitr.c (itrdup): Initialize the
allocated value with zeroes.
* libmailutils/stream/prog_stream.c (start_program_filter):
Improve error checking.
* libmailutils/tests/t-streamshift.c: Use typecasts when
printing mu_off_t values.
* libmailutils/url/set-service.c (mu_url_set_service):
Initialize port.
* libproto/imap/fetch.c (_fill_response): Fix possible use of
uninitialized variable.
* libproto/maildir/maildir.c (maildir_message_name_parse):
Initialize endval.
* libproto/mailer/prog.c (url_to_argv): Translate wordsplit
error code to the mailutils one.
* libproto/mbox/message.c (env_to_stream): Make sure ref->date
is null-terminated.
* libproto/pop/pop3_response.c (mu_pop3_get_response): Don't
check for non-null receiver before calling mu_cpystr: it copes
with the case by itself.
* libproto/pop/pop3_top.c (mu_pop3_top): Always initialize
status.
* mail/escape.c (escape_help): Likewise.
* mail/util.c (util_do_command): Remove unnecessaty
conditional. Upon successful return from mu_vasnprintf cmd is
guaranteed to have a non- null value.
* mda/lib/script.c (mda_filter_message): Bail out if changing
to the user dir fails.
* mh/mhn.c (com_send): Fix allowed user responses.
* mu/libexec/smtp.c (next_name_from_file): Fix the use of
uninitialized variables.
2022-09-16 Sergey Poznyakoff <gray@gnu.org>
Fix handling of overflowing lines in wordwrap streams.
* libmailutils/stream/wordwrap.c (mu_wordwrap_stream): New
field: overflow.
(line_not_empty): New auxiliary function.
(_wordwrap_flush_line,_wordwrap_write)
(_wordwrap_flush): Handle line overflow.
* libmailutils/tests/wordwrap03.at: More tests.
2022-09-14 Sergey Poznyakoff <gray@gnu.org>
tlsfdstr: fix error handling.
* libmu_auth/tlsfdstr.c (_tlsfd_done): Don't close borrowed
descriptors.
(mu_tlsfd_stream_create): Avoid both fds being closed on error.
2022-07-18 Sergey Poznyakoff <gray@gnu.org>
Bugfix.
* libmailutils/base/mutil.c (mutil_parse_field_map): Fix an
attempt to free a memory area that hasn't been allocated. Not
so critical: the bug would be hit only if mu_assoc_install
failed (which means out of memory condition).
2022-07-03 Sergey Poznyakoff <gray@gnu.org>
Fix mh/folder -pack=1 on an empty mailbox.
* mh/folder.c (action_pack): Return immediately if the mailbox
is empty.
2022-05-08 Sergey Poznyakoff <gray@gnu.org>
Modify .gitignore.
2022-05-08 Sergey Poznyakoff <gray@gnu.org>
rdcache_size: return MU_ERR_INFO_UNAVAILABLE if unable to get
transport stream size.
This addresses the problem mentioned in the previous commit.
* libmailutils/stream/rdcache_stream.c (rdcache_size): Return
MU_ERR_INFO_UNAVAILABLE if mu_stream_size returns EAGAIN,
EINTR, ENOSYS, or EINPROGRESS.
* libmailutils/stream/stream.c (mu_stream_seterr): Handle
MU_ERR_INFO_UNAVAILABLE same way as ENOSYS et al.
* libmailutils/stream/streamcpy.c (mu_stream_copy_wcb): Same
handling for: EAGAIN, EINTR, ENOSYS, EINPROGRESS, and
MU_ERR_INFO_UNAVAILABLE.
* mh/msgchk.c (checkmail): Likewise.
2022-05-08 Sergey Poznyakoff <gray@gnu.org>
rdcache: fix stream size computation.
Until now, read cache stream incorrectly updated its size when
it should not. This happened when the stream had cached some
data, then had been rewound and a read operation performed on
it.
* libmailutils/stream/rdcache_stream.c
(mu_rdcache_stream_max_memory_size): Remove unused global.
(rdcache_read): Fix stream size computation.
(rdcache_size): Return cached size only if EOF was hit on
transport stream, otherwise return its size. This means that
depending on whether the stream was already cached or not, the
call to mu_stream_size on rdcache stream may return ENOSYS or
success.
* libmailutils/tests/t-rdcache.c: New test program.
* libmailutils/tests/Makefile.am: Build t-rdcache.
* libmailutils/tests/testsuite.at: Run t-rdcache.
2022-05-02 Sergey Poznyakoff <gray@gnu.org>
Accomodate tests for differences in wc outputs on various
systems.
* libproto/mbox/tests/append.at: Strip leading whitespace from
the wc output.
* libproto/mbox/tests/lastmsg.at: Likewise.
* mda/mda/tests/forward.at: Likewise.
2022-04-17 Sergey Poznyakoff <gray@gnu.org>
Version 3.15.
* NEWS: Raise version number
* configure.ac: Raise version number. Increase shared library
current interface number.
2022-04-13 Sergey Poznyakoff <gray@gnu.org>
Minor fix (imap4d)
* imap4d/imap4d.c (namespace_section_parser): Return error on
invalid or empty namespace name.
2022-04-06 Sergey Poznyakoff <gray@gnu.org>
Document message part syntax for the mail command.
2022-04-06 Sergey Poznyakoff <gray@gnu.org>
mail: error out if a message part is given to the command that
doesn't support parts.
* mail/mail.h (MSG_ALLOWPART): New flag.
* mail/msgset.y: Allow message parts only if MSG_ALLOWPART is
set. Rewrite as a reentrant parser.
* mail/decode.c: Allow message parts in sets.
* mail/write.c: Likewise.
2022-02-18 Sergey Poznyakoff <gray@gnu.org>
Fix GSASL stream initialization in imap4d.
* imap4d/auth_gsasl.c (auth_gsasl): Initialize stream[1],
unless set after return from ioctl.
* libmailutils/stream/fltstream.c (filter_ctl): If both streams
are supplied for MU_IOCTL_OP_SET, combine them into an iostream
prior to setting the transport pointer.
2022-02-18 Sergey Poznyakoff <gray@gnu.org>
imap4d: fix test mode detection.
* imap4d/imap4d.c (test_mode): Three-state. Initialize to
"undef".
(imap4d_mainloop): Don't alter test_mode here.
(main): Detect test_mode value unless already set earlier.
2022-02-18 Sergey Poznyakoff <gray@gnu.org>
Minor change in msrv signal handling.
* libmailutils/server/msrv.c (set_signal): Catch errors.
(_mu_m_server.sigtab): Increase size by one. Slot 0 is not
used.
(mu_m_server_begin,mu_m_server_restore_signals): Enumerate
signals starting from 1.
2022-02-12 Sergey Poznyakoff <gray@gnu.org>
Minor change in MH testcase.
* mh/tests/fmtcomp.at (unclosed control): Reflect changed
wording in parsers produced by bison 3.8.2
2022-02-09 Sergey Poznyakoff <gray@gnu.org>
mbox format: preserve trailing newlines in body.
* libmailutils/stream/streamcpy.c (mu_stream_copy_nl): Append
an extra \n only unless the last character in stream is a
newline. Always append an empty line at the end.
* libproto/mbox/message.c (mboxrd_message_copy_with_uid): use
regular mu_stream_copy, instead of mu_stream_copy_nl.
* mda/tests/input.msg: Remove empty line at the end.
* mda/lmtpd/tests/lmtpd.at: Ensure expout ends with an empty
line.
* mda/mda/tests/forward.at: Likewise.
* mda/mda/tests/mda.at: Likewise.
* mda/putmail/tests/putmail.at: Likewise.
2022-02-08 Sergey Poznyakoff <gray@gnu.org>
Document changes.
2022-02-08 Sergey Poznyakoff <gray@gnu.org>
Bugfix in _fromrd_encoder.
See 451ca485. Patch by Kurt Hackenberg.
2022-02-08 Sergey Poznyakoff <gray@gnu.org>
Normalize test mbox mailboxes.
2022-02-08 Sergey Poznyakoff <gray@gnu.org>
mbox format: don't count terminating empty line as part of
message.
* configure.ac: Version 3.14.90
* NEWS: Version 3.14.90
* libproto/mbox/mboxrd.c (scan_message_finalize): Take
decrement value (n) without additional corrections. All uses
changed.
(mailbox_append_message): Fix padding.
* libproto/mbox/message.c (_msg_stream_setup)
(mboxrd_message_body_scan,_msg_body_setup): Don't count
terminating empty line as part of the message body.
* libproto/mbox/tests/lastmsg.at: New test.
* libproto/mbox/tests/Makefile.am: Add new files.
* libproto/mbox/tests/testsuite.at: Likewise.
* libproto/mbox/tests/append.at: Test appending to partially
terminated mailboxes.
* libproto/mbox/tests/body.at: Fix expected octet and line
counts.
* libproto/mbox/tests/attr.at: Likewise.
* libproto/mbox/tests/autodetect.at: Likewise.
* libproto/mbox/tests/count.at: Likewise.
* libproto/mbox/tests/env.at: Likewise.
* libproto/mbox/tests/notify.at: Likewise.
* libproto/mbox/tests/qget.at: Likewise.
* comsat/tests/testsuite.at: Likewise.
* imap4d/tests/IDEF0956.at: Likewise.
* imap4d/tests/fetch.at: Likewise.
* libmu_scm/tests/mailbox-append-message.at: Likewise.
* libmu_scm/tests/mailbox-expunge.at: Likewise.
* libmu_scm/tests/mailbox-get-message.at: Likewise.
* libmu_scm/tests/mailbox-iterate.at: Likewise.
* libtests/mime.at: Likewise.
* mail/tests/align.at: Likewise.
* mail/tests/hold.at: Likewise.
* mail/tests/nohome.at: Likewise.
* mail/testsuite/mail/Followup.exp
* mail/testsuite/mail/Reply.exp
* mail/testsuite/mail/folder.exp
* mail/testsuite/mail/followup.exp
* mail/testsuite/mail/read.exp
* mail/testsuite/mail/reply.exp
* mail/testsuite/mail/tag.exp
* mail/testsuite/mail/z.exp
* pop3d/testsuite/pop3d/read.exp
* readmsg/tests/all.at: Likewise.
* readmsg/tests/hdr.at: Likewise.
* readmsg/tests/nohdr.at: Likewise.
* readmsg/tests/twomsg.at: Likewise.
* readmsg/tests/weed.at: Likewise.
* sieve/tests/redirect.at: Likewise.
* sieve/tests/reject.at: Likewise.
2022-02-08 Sergey Poznyakoff <gray@gnu.org>
Fix mu_stream_read with NULL as 4th argument.
If called with NULL as its fourth argument (size_t *pread), the
function should return error if unable to read the requested
number of bytes.
* libmailutils/stream/stream.c (mu_stream_read): If pread is
NULL and less than the requested number of bytes has been read,
return MU_ERR_READ.
* libmailutils/tests/t-streamshift.c (stream_verify): Fix size
calculation.
2022-01-28 Sergey Poznyakoff <gray@gnu.org>
Improve performance of the Sieve fileinto action.
* include/mailutils/assoc.h (MU_ASSOC_LRU): New flag.
(mu_assoc_pop, mu_assoc_shift): Change signature: second
argument is char **.
* libmailutils/base/assoc.c (mu_assoc_install_ref2): Maintain
LRU ordering, if so requested. mu_assoc_pop, mu_assoc_shift):
Change type of the second argument to char **. Unless it is
NULL, store there a copy of the key.
* libmu_sieve/sieve-priv.h (mu_sieve_machine): New member:
mailboxes.
* libmu_sieve/actions.c (sieve_action_fileinto): Maintain a
table of output mailboxes. Keep each mailbox open for as long
as possible. If running out of open files, close the least
recently used mailbox and retry.
* libmu_sieve/sieve-gram.y (mu_sieve_machine_destroy): Destroy
the mailbox table.
2022-01-28 Sergey Poznyakoff <gray@gnu.org>
Improve efficiency of operations on flat mailboxes in append
mode.
Until now both mboxrd and dotmail preferred mmap over
unistd-based I/O. This improved performance when reading and
updating mailboxes, but deteriorated it when operating in
append mode. To improve performance in append mode, a new
function (mu_mailbox_stream_create) is introduced, which
selects the underlying stream for the mailbox file based on the
requested open mode and the currentstatus of the file itself.
Both mboxrd and dotmail use this function to initialize mailbox
stream.
* include/mailutils/stream.h (mu_mailbox_stream_create): New
proto.
* libmailutils/stream/Makefile.am (libstream_la_SOURCES): Add
mailbox_stream.c
* libmailutils/stream/mailbox_stream.c: New file.
* libproto/dotmail/dotmail.c (dotmail_mailbox_init_stream): Use
mu_mailbox_stream_create.
* libproto/mbox/mboxrd.c (mboxrd_mailbox_init_stream):
Likewise.
2022-01-24 Sergey Poznyakoff <gray@gnu.org>
Bugfix in mboxrd decoder.
* libmailutils/filter/fromrd.c (_fromrd_decoder): Don't switch
state if '\n' is received while in S_BOL state.
2022-01-21 Sergey Poznyakoff <gray@gnu.org>
Bugfix in quoted-printable decoder.
Bug reported by Kurt Hackenberg, see:
https://lists.gnu.org/archive/html/bug-mailutils/2022-01/msg000
01.html
* libmailutils/filter/qpflt.c (_qp_decoder): Fix calculation of
the number of consumed input characters.
2022-01-21 Sergey Poznyakoff <gray@gnu.org>
Bugfix in mboxrd library.
* libproto/mbox/mboxrd.c (mboxrd_tracker_sync): If mailbox
becomes empty, reset all uid-related fields. It is especially
important to reset x_imapbase_len, otherwise expunging all
messages in the mailbox followed by appending a new message
would cause mboxrd_flush_unlocked in line 1670 to overwrite a
random fragment of the newly created message.
2022-01-21 Sergey Poznyakoff <gray@gnu.org>
Minor fix in dotmail.
* libproto/dotmail/dotmail.c (dotmail_mailbox_init_stream):
Don't retry opening the file if it mu_mapfile_stream_create
returned ENOENT, i.e. file does not exist and MU_STREAM_CREAT
was not specified. Use same flags in both attempts.
(dotmail_open): Check return from dotmail_mailbox_init_stream.
(dotmail_tracker_sync): If mailbox becomes empty, reset all
uid-related fields to 0.
2022-01-17 Sergey Poznyakoff <gray@gnu.org>
Fix EOF check with flex >= 2.6.1.
2022-01-02 Sergey Poznyakoff <gray@gnu.org>
Version 3.14.
2022-01-02 Sergey Poznyakoff <gray@gnu.org>
Update copyright year.
2021-12-07 Sergey Poznyakoff <gray@gnu.org>
amd: Rewrite message scanner.
* include/mailutils/sys/amd.h (_amd_message) <header_size>: New
member.
(MU_AMD_DASHDELIM): New flag.
* libmailutils/base/amd.c (_amd_message_save): Optionally save
dash delimiter line (useful for MH).
(_amd_message_save): Initialize header_size.
(amd_scan_message): Rewrite as a state mashine. Support
MH-style dash-line delimiters between header and body.
(amd_message_stream_open): Close stream on failure.
(amd_header_fill): Use header_size instead of body_start.
* libproto/mh/mh.c (_mailbox_mh_init): Set MU_AMD_DASHDELIM
capability.
2021-12-05 Sergey Poznyakoff <gray@gnu.org>
Update NEWS.
2021-12-05 Sergey Poznyakoff <gray@gnu.org>
amd: use Return-Path and Received headers to save envelope
information.
* libmailutils/base/amd.c (_amd_tempstream): New function.
(_amd_tempfile, _amd_delim): Removed.
(_amd_message_save): Rewrite using mailutils stream functions.
Use mu_stream_stat_buffer to count octets and lines. Use
Return-Path and Received headers to save envelope information.
* libproto/maildir/tests/append.at: Update expected headers.
* libproto/mh/tests/append.at: Likewise.
* mh/tests/pick.at (pick-component, pick-component-or): Use
mbox2dir -e to create the mailstore. Use --Return-Path option
for tests.
* testsuite/mbox2dir.c: New option -e. Rewrite message copying
routines.
2021-12-05 Sergey Poznyakoff <gray@gnu.org>
Improve message append API.
The new API allows for specifying envelope and attributes
(status) for the message being appended.
* include/mailutils/attribute.h (MU_STATUS_BUF_SIZE): Order
flags lexicographically.
* include/mailutils/imap.h (mu_imap_append_stream_size)
(mu_imap_append_stream)
(mu_imap_append_message): Take envelope and attribute as
arguments, instead of struct tm, mu_timezone, and flags.
* include/mailutils/mailbox.h (mu_mailbox_append_message_ext):
New proto.
* include/mailutils/sys/amd.h (_amd_data): Change prototype of
msg_finish_delivery: take additional mu_attribute_t argument.
* include/mailutils/sys/mailbox.h (_mu_mailbox): Change
prototype of _append_message: take mu_envelope_t and
mu_attribute_t as additional arguments.
* libmailutils/base/amd.c (_amd_message_save): Take
mu_envelope_t argument.
(amd_append_message): Take mu_envelope_t and mu_attribute_t
arguments. Use them to alter message envelope and status.
* libmailutils/mailbox/attribute.c (mu_attribute_unset_flags):
Check return from mu_attribute_get_flags.
(flagtrans): Order alphabetically.
* libmailutils/mailbox/mailbox.c
(mu_mailbox_append_message_ext): New function.
(mu_mailbox_append_message): Rewrite as an alternative entry
point to mu_mailbox_append_message_ext.
* libmailutils/mailbox/msgenv.c (message_envelope_date): Give
MU_HEADER_ENV_DATE higher priority than MU_HEADER_RECEIVED.
(message_envelope_sender): Give X-Envelope-Sender higher
priority than Return-Path.
* libmailutils/stream/message_stream.c
(mu_message_from_stream_with_envelope): Initialize attribute
from MU_HEADER_STATUS.
* testsuite/mbop.c (mbop_append): Options -attr, -sender, and
-date can be used to alter message attributes and envelope.
* libproto/dotmail/dotmail.c (mailbox_append_message)
(dotmail_append_message): Take mu_envelope_t and mu_attribute_t
arguments. Use them to alter message envelope and status.
* libproto/dotmail/tests/append.at: Test modifying envelope and
attributes during append.
* libproto/dotmail/tests/testsuite.at: Force TZ=0.
* libproto/imap/appmsg.c (mu_imap_append_message): Take
mu_envelope_t and mu_attribute_t as arguments.
* libproto/imap/appstr.c (mu_imap_append_stream): Likewise.
* libproto/imap/appstrsiz.c (mu_imap_append_stream_size):
Likewise. Use mu_attribute_t to set message flags and
mu_envelope_t to set its delivery date. Note, that sender is
not yet affected.
* libproto/imap/mailbox.c (_imap_mbx_append_message): Take
mu_envelope_t and mu_attribute_t as arguments. Use them to
alter message envelope and status, via mu_imap_append_message.
Altering envelope is done by amd.c
* libproto/maildir/maildir.c (maildir_msg_finish_delivery):
Take additional mu_attribute_t argument. Use it to alter
message flags. Change msg->file_name if needed.
* libproto/maildir/tests/append.at: Test modifying envelope and
attributes during append.
* libproto/mailer/mailbox.c (remote_mbox_append_message): Take
mu_envelope_t and mu_attribute_t as arguments. Use
mu_envelope_t to set sender address. mu_attribute_t is ignored,
as SMTP does not transfer message attributes.
* libproto/mbox/mboxrd.c (mailbox_append_message)
(mboxrd_append_message): Take mu_envelope_t and mu_attribute_t
as arguments. Use them to alter message envelope and status.
* libproto/mbox/tests/append.at: Test modifying envelope and
attributes during append.
* libproto/mh/tests/append.at: Test modifying envelope and
attributes during append.
* mail/copy.c (append_to_mailbox): Preserve message status when
appending.
* mail/quit.c (mail_mbox_commit): Preserve message status when
storing it to MBOX.
* mail/tests/hold.at: Test whether message status is preserved.
* mu/libexec/imap.c (com_append): Rewrite using the new
mu_imap_append_stream call.
2021-11-25 Sergey Poznyakoff <gray@gnu.org>
Version 3.13.91.
2021-11-25 Sergey Poznyakoff <gray@gnu.org>
Bugfixes.
* imap4d/idle.c (imap4d_idle): Catch eof
* libmu_auth/tlsfdstr.c: Add missing include.
2021-11-20 Sergey Poznyakoff <gray@gnu.org>
Fix typos.
2021-11-19 Sergey Poznyakoff <gray@gnu.org>
Fix a corner case in mu_make_file_name_suf.
If dir is '/' (optionally followed by another '/'), copy it
verbatim.
* libmailutils/string/mkfilename.c (mu_make_file_name_suf):
2021-11-19 Sergey Poznyakoff <gray@gnu.org>
Forgotten to add with 22ceaddfb8.
2021-11-19 Sergey Poznyakoff <gray@gnu.org>
Fix memory and fd leak in maildir and amd.
* libmailutils/base/amd.c (amd_expunge): Close and destroy the
associated message stream.
* libproto/maildir/maildir.c (maildir_close): Fix erroneously
reverted condition.
2021-11-13 Sergey Poznyakoff <gray@gnu.org>
mail: implement the unread command.
* mail/unread.c: New file.
* mail/Makefile.am: Add unread.c
* mail/mail.h (mail_unread): New proto.
* mail/table.c: New command "unread" ("U").
* doc/texinfo/programs/mail.texi: Document the unread command.
* NEWS: Likewise.
2021-11-03 Sergey Poznyakoff <gray@gnu.org>
Free allocated memory on exit.
See also 91d35ab2ee.
* include/mailutils/cfg.h (mu_cfg_section): New members:
ident_storage and label_storage.
* libmailutils/cfg/driver.c (mu_config_destroy_container): Free
the storage allocated for ident and label. Do this onlyw if the
decreased refcount hits zero.
(mu_config_container_register_section): Assign allocated
strings to ident_storage and label_storage.
(mu_config_root_register_section): Register an onexit routine
for freeing the allocated memory.
* libmailutils/cli/capa.c (capa_free): Register an onexit
routine for freeing the allocated memory.
* libmailutils/opt/progname.c (mu_set_program_name): Likewise.
2021-11-03 Sergey Poznyakoff <gray@gnu.org>
Minor change.
* libmailutils/stdstream/basestr.c (std_log_bootstrap): Mark
stream as open.
2021-11-03 Sergey Poznyakoff <gray@gnu.org>
Free some allocated memory on exit.
This eliminates certain "memory leaks", that have little (if
any) practical importance, bu make leak detection tools overly
vociferous.
* libmailutils/base/monitor.c (static_monitor_dealloc): New
function.
(mu_monitor_rdlock, mu_monitor_wrlock): Install
static_monitor_dealloc as onexit handler.
* libmailutils/filter/filter.c (filter_dealloc): New function:
deallocate filter_list.
(mu_filter_get_list): Install filter_dealloc as onexit handler.
* libmailutils/locus/ident.c (nametab_dealloc): New function.
(mu_ident_ref): Install nametab_dealloc as onexit handler.
* libmailutils/stdstream/basestr.c (std_log_bootstrap): Unref
transport after setting it up to log stream.
(stdstream_flushall): Call mu_stream_destroy instead of
mu_stream_flush.
2021-11-03 Sergey Poznyakoff <gray@gnu.org>
Move mimetypes support into the library.
* configure.ac: Build libmailutils/mimetypes/Makefile
* include/mailutils/Makefile.am: New header mimetypes.h
* mimeview/mimeview.h: moved from include/mailutils/mimetypes.h
* include/mailutils/sys/Makefile.am: Add mimetypes.h
* include/mailutils/sys/mimetypes.h: New file.
* include/mailutils.h: Include mailutils/mimetypes.h
* libmailutils/Makefile.am: Build mimetypes.
* libmailutils/mimetypes/.gitignore: New file.
* libmailutils/mimetypes/eval.c: New file.
* libmailutils/mimetypes/grammar.y: Moved from
mimeview/grammar.y
* libmailutils/mimetypes/lexer.l: Moved from mimeview/lexer.l.
* libmailutils/diag/debcat: Add mimetypes.
* mimeview/Makefile.am: Update.
* mimeview/tests/testsuite.at: Change debug level.
* include/mailutils/stream.h (mu_fd_stream_create): filename is
const.
* libmailutils/stream/file_stream.c: Likewise.
2021-11-02 Sergey Poznyakoff <gray@gnu.org>
Mimeview: redo the API; rewrite as reentrant scanner/parser.
* include/mailutils/yyloc.h: Formatting change.
* mimeview/grammar.y: Rewrite as a reentrant parser.
* mimeview/lexer.l: Rewrite as a reentrant scanner. Use flex
interface to bison.
* mimeview/mimeview.c: Use new API.
* mimeview/mimeview.h: Remove most prototypes. (mimetypes_open,
mu_mimetypes_close) (mu_mimetypes_stream_type,
mu_mimetypes_file_type)
(mu_mimetypes_fd_type): New API.
* mimeview/tests/testsuite.at (multiple error recovery): Fix
expected location of error recovery.
2021-11-01 Sergey Poznyakoff <gray@gnu.org>
Minor fix in mimeview/grammar.y.
2021-11-01 Sergey Poznyakoff <gray@gnu.org>
Require GNU bison and flex.
* am/bison.m4: Use AC_PATH_PROG.
* am/flex.m4: Likewise.
* configure.ac: Remove MU_YLWRAP.
* include/mailutils/yyloc.h (YYLTYPE): Remove. This needs be
defined in each grammar source individually.
* mu-aux/Makefile.am: Remove gylwrap.
* mu-aux/gylwrap: Remove.
* libmailutils/cfg/Makefile.am: Rewrite rules for building
grammars and lexers.
* libmailutils/datetime/Makefile.am: Likewise.
* libmu_sieve/Makefile.am: Likewise.
* mail/Makefile.am: Likewise.
* mh/Makefile.am: Likewise.
* mimeview/Makefile.am: Likewise.
* libmailutils/cfg/gylwrap.conf: Remove.
* libmailutils/datetime/gylwrap.conf: Remove.
* libmu_sieve/gylwrap.conf: Remove.
* mh/gylwrap.conf: Remove.
* mimeview/gylwrap.conf: Remove.
* libmailutils/cfg/lexer.l: Use %option prefix
* libmu_sieve/sieve-lex.l: Likewise.
* mh/mh_alias_lex.l: Likewise.
* mimeview/lexer.l: Likewise.
* libmailutils/cfg/parser.y: Use api.prefix and %code requires.
* libmailutils/datetime/parsedate.y: Likewise.
* mh/mh_alias_gram.y: Likewise.
* mh/mh_fmtgram.y: Likewise.
* mh/pick-gram.y: Likewise.
* libmu_sieve/sieve-gram.y: Likewise.
* mimeview/grammar.y: Likewise.
* testsuite/lib/mailutils.exp (mu_create_config): Fix source
location.
2021-09-30 Sergey Poznyakoff <gray@gnu.org>
Fix timezone calculation (see
https://savannah.gnu.org/bugs/?61239)
* libmailutils/datetime/utcoff.c (mu_utc_offset): Fix the
timezone correction.
2021-08-27 Sergey Poznyakoff <gray@gnu.org>
Bugfix.
* libmailutils/stream/stream.c (mu_stream_timed_getdelim): If
buffer points to NULL, assume size = 0.
2021-08-27 Sergey Poznyakoff <gray@gnu.org>
Bugfix.
* imap4d/io.c (imap4d_init_tls_server): Fix inverted condition.
* pop3d/extra.c (pop3d_init_tls_server): Likewise.
2021-08-26 Sergey Poznyakoff <gray@gnu.org>
Test TLS streams.
* configure.ac: Configure test directory in libmu_auth
* libmu_auth/Makefile.am: Likewise.
* libmu_auth/tests/.gitignore: New file.
* libmu_auth/tests/Makefile.am: New file.
* libmu_auth/tests/atlocal.in: New file.
* libmu_auth/tests/genfile.c: New file.
* libmu_auth/tests/testsuite.at: New file.
* libmu_auth/tests/tls.at: New file.
* libmu_auth/tests/tlscpy.c: New file.
* pop3d/cmd.c: Fix typo.
2021-08-25 Sergey Poznyakoff <gray@gnu.org>
Version 3.13.90.
2021-08-25 Sergey Poznyakoff <gray@gnu.org>
New function: mu_starttls.
* libmu_auth/tlsfdstr.c (mu_tlsfd_stream_create): Accept
conf==NULL.
(mu_starttls): New function.
* include/mailutils/tls.h (mu_starttls): New proto.
* include/mailutils/imapio.h (mu_imapio_get_transport)
(mu_imapio_set_transport): New functions.
* libmailutils/imapio/transport.c (mu_imapio_get_transport)
(mu_imapio_set_transport): New functions.
* libmailutils/stream/iostream.c (mu_iostream_create): Accept
NULL out stream.
* libmailutils/stream/tcp.c: Support MU_IOCTL_FD
(_tcp_instance): New member fd_borrowed.
(_tcp_close): Don't close fd if fd_borrowed is set.
(_tcp_ioctl): Handle MU_IOCTL_FD.
* libmailutils/stream/xscript-stream.c (_xscript_ctl): Accept
pstr[1] == NULL.
* libmu_auth/notls.c (mu_tlsfd_stream_create)
(mu_tlsfd_stream2_convert)
(mu_starttls): New placeholders.
* libproto/imap/folder.c (_mu_imap_folder_open): Use
mu_tlsfd_stream_convert. Fix stream leak.
* libproto/imap/starttls.c (mu_imap_starttls): Use mu_starttls.
* libproto/mailer/smtp.c (smtp_open): Use
mu_tlsfd_stream_convert.
* libproto/mailer/smtp_starttls.c (mu_smtp_starttls): Use
mu_starttls.
* libproto/pop/pop3_stls.c (mu_pop3_stls): Likewise.
* libproto/pop/mailbox.c (pop_open): Use
mu_tlsfd_stream_convert. Fix stream leak.
* mu/libexec/imap.c (com_connect): Use mu_tlsfd_stream_convert.
Fix stream leak.
* mu/libexec/pop.c: Likewise.
* mu/libexec/smtp.c: Likewise.
* imap4d/io.c (imap4d_init_tls_server): Use mu_starttls.
* pop3d/extra.c: Likewise.
2021-08-25 Sergey Poznyakoff <gray@gnu.org>
New function mu_tlsfd_stream2_convert.
* libmu_auth/tlsfdstr.c (mu_tlsfd_stream_create): Remove last
argument. All uses changed.
(mu_tlsfd_stream2_convert): New function.
* include/mailutils/tls.h (mu_tlsfd_stream_create): Change
signature (flags removed).
(mu_tlsfd_stream2_convert): New proto.
(mu_tlsfd_stream_convert): New inline function.
* libmailutils/diag/errors (MU_ERR_TRANSPORT_GET)
(MU_ERR_TRANSPORT_SET): New error codes.
* imap4d/io.c (imap4d_init_tls_server): Use
mu_tlsfd_stream2_convert.
* pop3d/extra.c (pop3d_init_tls_server): Use
mu_tlsfd_stream2_convert.
2021-08-25 Sergey Poznyakoff <gray@gnu.org>
Use timed I/O and fd-based TLS for pop3d.
2021-08-24 Sergey Poznyakoff <gray@gnu.org>
Intermediate streams: propagate _MU_STR_EVENT_CLRFLAG to the
underlying transport.
* libmailutils/stream/fltstream.c: Propagate mu_stream_clearerr
to the transport stream.
* libmailutils/stream/iostream.c: Likewise.
* libmu_auth/tls.c: Likewise.
* libmu_auth/tlsiostr.c: Likewise.
* libmu_auth/tlsfdstr.c (_tlsfd_read, _tlsfd_write): Translate
GNUTLS_E_TIMEDOUT to MU_ERR_TIMEOUT.
* imap4d/bye.c (imap4d_bye_command): Clear stream error on
ERR_TIMEOUT. ---
2021-08-24 Sergey Poznyakoff <gray@gnu.org>
Attempt to simplify TLS streams.
* libmu_auth/tlsfdstr.c: New TLS stream implementation.
* include/mailutils/tls.h (mu_tls_config): New field:
handshake_timeout.
(mu_tlsfd_stream_create): New proto.
* libmu_auth/Makefile.am: Compile tlsfdstr.c
* libmu_auth/tlsconf.c (tls_canned_param): New configuration
statement: tls.handshake_timeout
* doc/texinfo/programs.texi: Document the tls.handshake-timeout
statement.
* imap4d/io.c (io_setio, imap4d_init_tls_server): Use
mu_tlsfd_stream_create.
* imap4d/starttls.c (global_tls_conf): Initialize
handshake_timeout.
2021-08-23 Sergey Poznyakoff <gray@gnu.org>
Fix handling of MU_IOCTL_SUBSTREAM in iostream.
* libmailutils/stream/iostream.c (_iostream_ctl): Fix handling
of MU_IOCTL_SUBSTREAM (get/set) requests.
* imap4d/io.c (io_setio): Unreference the source stream.
(imap4d_init_tls_server): Fix reference decrement for
tlsstream.
* pop3d/extra.c (pop3d_setio): Unreference the source stream.
(pop3d_init_tls_server): Fix reference decrement for tlsstream.
2021-08-21 Sergey Poznyakoff <gray@gnu.org>
imap4d: Set timeouts for I/O operations during handshake.
* imap4d/io.c (io_setio): Set I/O timeout for pull functions
during the handshake.
* libmu_auth/tls.c: Fix debugging output.
* libmu_auth/tlsiostr.c (_tls_io_read): Improve error
diagnostics.
2021-08-21 Sergey Poznyakoff <gray@gnu.org>
imap4d: switch to timed stream I/O.
* imap4d/idle.c (imap4d_idle): Use mu_stream_timed_getline.
* imap4d/imap4d.c (imap4d_mainloop): Remove use of
io_wait_input.
* imap4d/imap4d.h (io_wait_input): Remove.
* imap4d/io.c (io_wait_input): Remove.
(io_getline): Rewrite using mu_stream_timed_getline.
(imap4d_tokbuf_getline): Likewise.
(check_input_err): Handle MU_ERR_TIMEOUT.
2021-08-21 Sergey Poznyakoff <gray@gnu.org>
Implement "timed" versions of the stream read-up-to-delimiter
operations.
* include/mailutils/stream.h (MU_IOCTL_TIMEOUT): New ioctl
code.
(mu_stream_timed_readdelim,mu_stream_timed_readline): New
protos.
(mu_stream_readdelim,mu_stream_readline,mu_stream_getdelim)
(mu_stream_getline): Rewrite as inline functions.
* include/mailutils/datetime.h (mu_timeval_cmp, mu_timeval_add)
(mu_timeval_sub): New inline functions for operations over
struct timeval.
* include/mailutils/sys/file_stream.h (_mu_file_stream): New
member: io_timeout.
* libmailutils/diag/errors (MU_ERR_TIMEOUT, MU_ERR_SET_TIMEOUT)
(MU_ERR_WRITE, MU_ERR_TLS): New error codes.
* libmailutils/stream/file_stream.c (fd_read,fd_write): Take
into account I/O timeout.
(fd_ioctl): Handle MU_IOCTL_TIMEOUT.
* libmailutils/stream/stream.c (mu_stream_timed_readdelim)
(mu_stream_timed_readline): New functions.
* libmu_auth/tls.c (_tls_open): Special handling for time-out
errors.
* libmailutils/stream/iostream.c (_iostream_ctl): Pass
MU_IOCTL_TIMEOUT to the transport stream.
2021-08-19 Sergey Poznyakoff <gray@gnu.org>
Provide program name for mu shell utilities.
* mu/libexec/imap.c (main): Set program name.
* mu/libexec/pop.c: Likewise.
* mu/libexec/smtp.c: Likewise.
2021-08-05 Sergey Poznyakoff <gray@gnu.org>
Version 3.13.
2021-07-27 Sergey Poznyakoff <gray@gnu.org>
Prefer User-Agent header over X-Mailer.
* NEWS: Update.
* doc/texinfo/programs/mail.texi: Update.
* include/mailutils/header.h (MU_HEADER_USER_AGENT): New
define.
* mail/mail.c (default_setup): Set useragent
* mail/mail.h (mailvar_name_useragent): New define.
* mail/mailline.c (header_generator): Add MU_HEADER_USER_AGENT.
* mail/mailvar.c: Mew variable: "useragent". Retain "xmailer"
as an alias.
* mail/send.c (mail_compose_send): Add the User-Agent header if
the "useragent" variable is set.
* libmailutils/tests/hdrcpy.at: Use User-Agent instead of
X-Mailer.
* mail/tests/send.at: Likewise.
* mail/tests/sendbyname.at: Likewise.
* mail/tests/sendrec.at: Likewise.
* mail/testsuite/mail/Followup.exp: Likewise.
* mail/testsuite/mail/Reply.exp: Likewise.
* mail/testsuite/mail/reply.exp: Likewise.
* mail/testsuite/mail/send.exp: Likewise.
* mh/repl.c: Likewise.
* mh/send.c: New .mtstailor vareiable "user-agent".
2021-07-27 Sergey Poznyakoff <gray@gnu.org>
Rewrite tests for interactive mail features in expect.
After 4befcfd015 interpolation escapes can't be tested using
autotest. Move them to DejaGNU testsuite.
* mail/tests/Followup.at: Remove.
* mail/tests/Reply.at: Remove.
* mail/tests/followup.at: Remove.
* mail/tests/reply.at: Remove.
* mail/tests/Makefile.am: Remove these tests.
* mail/tests/testsuite.at: Likewise.
* mail/.gitignore: Fix the entry for mail.
* mail/testsuite/mail/Followup.exp: New test.
* mail/testsuite/mail/Reply.exp: New test.
* mail/testsuite/mail/followup.exp: New test.
* mail/testsuite/mail/reply.exp: New test.
* mail/testsuite/mail/DISTFILES: Add these files.
* mail/testsuite/lib/mail.exp (mail_version): Don't print the
version number.
* mail/testsuite/mail/write.exp: Preserve current working
directory.
2021-07-19 Sergey Poznyakoff <gray@gnu.org>
Fix in quoted-printable decoder.
* libmailutils/filter/qpflt.c (_qp_decoder): Accept soft line
breaks (RFC 2045, 6.7, page 19)
2021-07-19 Sergey Poznyakoff <gray@gnu.org>
mail: disable compose escapes in non-interctive mode.
* NEWS: Document changes.
* doc/texinfo/programs/mail.texi: Document changes.
* mail/send.c (mail_compose_send): Recognize escapes only in
interactive mode.
2021-07-16 Sergey Poznyakoff <gray@gnu.org>
Rename the FROMRB filter to FROMRD.
Old name is retained as an alias.
2021-07-15 Sergey Poznyakoff <gray@gnu.org>
Fix stream reference bug in mu_filter_stream_create.
If the mu_filter_xcode_t function failed in mu_filter_init
request, mu_filter_stream_create would leave the transport
reference counter incremented by one.
* libmailutils/stream/fltstream.c (mu_filter_stream_create): On
failure, decrement reference counter of transport stream.
* libmailutils/tests/fltcnt.c: Test for the above bug as well.
2021-07-15 Sergey Poznyakoff <gray@gnu.org>
Fix stream reference bug in mu_filter_chain_create family
functions.
This change affects the following two functions:
mu_filter_chain_create, mu_filter_chain_create_pred. In
previous versions, if these functions failed to create the
requested filter chain, they decremented reference counter of
their transport (input stream) argument.
This change restores the proper behavior:
- On success, reference counter is incremented by 1.
- On error, reference counter doesn't change.
* libmailutils/filter/fltchain.c (_add_next_link): Make sure
the transport reference counter does not change.
* libmailutils/tests/Makefile.am: Add new auxiliary program and
test case.
* libmailutils/tests/fltcnt.at: New file.
* libmailutils/tests/fltcnt.c: New file.
* libmailutils/tests/testsuite.at: Include new test.
2021-07-14 Sergey Poznyakoff <gray@gnu.org>
Minor change.
* libmailutils/stream/streamref.c
(mu_streamref_create_abridged):Don't reposition the underlying
stream to beginning.
2021-07-13 Sergey Poznyakoff <gray@gnu.org>
Bugfixes.
* libproto/imap/fetch.c (_fill_response): Tolerate NIL date
field.
* libproto/imap/mailbox.c (__imap_msg_get_stream): Seek to the
end, instead of computing stream size.
* libproto/mbox/mboxrd.c (mailbox_append_message): If all
methods of determining envelope size fail, assume epoch instead
of bailing out.
2021-06-11 Sergey Poznyakoff <gray@gnu.org>
mail: fix descriptions of command arguments in help output.
2021-06-11 Sergey Poznyakoff <gray@gnu.org>
fix mail '| cat >/tmp/save'
* mail/send.c (msg_to_pipe): Run command via shell.
2021-06-11 Sergey Poznyakoff <gray@gnu.org>
Fix handling of MIME messages that have only one part.
* libmailutils/mime/mime.c (_mime_part_size): Fix handling of
one part MIME messages. Don't touch psize memory in case of
error.
(_mime_body_stream_read): Fix handling of one part MIME
messages. Previous implementation used to add an extra newline
at the end.
* mh/tests/mhn.at: Reflect the above changes.
* sieve/tests/vacation.at: Reflect the above changes.
2021-06-11 Sergey Poznyakoff <gray@gnu.org>
Fix typo.
* mail/util.c (util_outfilename): Remove extra closing
parenthesis.
2021-06-10 Sergey Poznyakoff <gray@gnu.org>
Update docs; improve mailx compatibility mode.
* doc/texinfo/programs/mail.texi (Saving and Recording): New
section.
* mail/mailvar.c: Make sure escape is a single character.
* mail/util.c (util_outfilename): In mailx compatibility mode,
assume outfilename_local.
2021-06-10 Sergey Poznyakoff <gray@gnu.org>
Fix memory leaks (mboxrd and mail)
* libproto/mbox/mboxrd.c (mboxrd_rescan_unlocked): Free buf.
(mboxrd_detect): Destroy str when no longer needed.
* mail/copy.c (mail_copy0): Free allocated memory. Create file
in cwd if util_outfolder_name return NULL.
* mail/exit.c (mail_exit): Destroy mbox.
* mail/util.c (util_range_msg): Use msgset_free instead of
plain free.
2021-06-10 Sergey Poznyakoff <gray@gnu.org>
Provide several ways of creating the outgoing file name.
Several mail commands store message in a file named by its
recipient (or sender) in the "folder" directory (these commands
are: Copy, Save, Mail, followup, Followup). As per POSIX, the
local part of the email address serves as the file name. There
may be cases, however, when using the entire email would be
preferable.
This commit introduces new mail variable "outfilename" that
controls how the file name is generated. Its default value is
"local", which means use the email local part. Other possible
values are: "email", to save messages in a file named by entire
email, and "domain", to save them in a file named by domain
part of the email.
* NEWS: Document changes.
* doc/texinfo/programs/mail.texi: Document changes.
* mail/mail.c (default_setup): Set outfilename=local.
* mail/mail.h (mailvar_name_outfilename): New define.
(outfilename_mode): New extern.
(util_outfilename): New proto.
* mail/mailvar.c: New variable: "outfilename".
* mail/send.c (mail_compose_send): Use util_outfilename to form
outgoing file name.
* mail/util.c (outfilename_mode): New global.
(util_outfilename): New function.
(util_message_sender): Use util_outfilename.
2021-06-09 Sergey Poznyakoff <gray@gnu.org>
mail: implement the fullnames variable.
* NEWS: Document changes.
* doc/texinfo/programs/mail.texi: Likewise.
* mail/mail.c (default_setup): Set fullnames.
* mail/mail.h (mailvar_name_fullnames): New define.
* mail/mailvar.c (fullnames): New variable.
* mail/reply.c (compose_remove_personal): New function.
(respond_msg,respond_all): Call compose_remove_personal if
fullnames is not set.
2021-06-09 Sergey Poznyakoff <gray@gnu.org>
Add tests for mail send/reply/followup commands.
* mail/mail.c (main): Fix exit status in send mode.
* mail/tests/Makefile.am: Add new tests.
* mail/tests/testsuite.at: Likewise.
* mail/tests/atlocal.in (MAILER): New variable.
* mail/tests/Followup.at: New file.
* mail/tests/Reply.at: New file.
* mail/tests/followup.at: New file.
* mail/tests/reply.at: New file.
* mail/tests/send.at: New file.
* mail/tests/sendbyname.at: New file.
* mail/tests/sendrec.at: New file.
2021-06-09 Sergey Poznyakoff <gray@gnu.org>
mail: fix semantics of mail sending and saving commands.
* NEWS: Document changes.
* doc/texinfo/programs/mail.texi: Document changes.
* mail/Makefile.am (mail_SOURCES): Remove followup.c
* mail/followup.c: Remove.
* mail/mail.c: Fix the -F option. Rewrite send mode by calling
mail_send directly.
* mail/mail.h (mailvar_name_byname): Remove.
(mail_send0): Rename to mail_compose_send. All uses changed.
(util_message_sender): New function.
* mail/mailvar.c (mailvar_tab): Remove the "byname" variable.
"outfolder": Accept string and boolean values.
(print_descr): Handle hard newlines.
(mailvar_get): Use mailvar_type_whatever to test whether a
variable is set, regardless of its type.
* mail/reply.c: Rewrite to match POSIX standard. This affects
the following commands: "reply", "Reply", "followup",
"Followup".
* mail/send.c (compose_header_set): Use util_merge_addresses
when operating on address headers.
(send_message): In mailx compatibility mode, assume the
sendmail:// scheme.
(mail_send0): Rename to mail_compose_send. Add Date header
before saving the message, to make sure
mu_mailbox_append_message won't bail out.
* mail/table.c: New command: "Mail".
* mail/testsuite/mail/send.exp: Fix expected output.
* mail/testsuite/mail/write.exp: Likewise.
* mail/util.c (util_message_sender): New function.
(util_get_sender): Rewrite using util_message_sender.
(util_outfolder_name,util_save_outgoing): Rewrite from scratch,
Ensure mailx compatibility,
* mail/write.c (mail_write): Don't use outfolder.
* testsuite/mockmail.c: Support -i and -v options.
* testsuite/mockmail.at: Unset MAIL_DUMP when testing.
2021-06-08 Sergey Poznyakoff <gray@gnu.org>
Bugfix.
* libproto/mbox/mboxrd.c (mailbox_append_message): Don't
overwrite the error code.
2021-06-07 Sergey Poznyakoff <gray@gnu.org>
mail: Add a Date: header before sending the message.
* mail/send.c (message_add_date): New function.
(mail_send0): Call message_add_date before sending the message.
2021-06-06 Sergey Poznyakoff <gray@gnu.org>
mail: revamp parsing of adresses in send mode.
In particular, this fixes parsing of addresses with comma in
the local part.
* include/mailutils/address.h (MU_ADDRESS_HINT_INITIALIZER):
New define.
* libmailutils/address/addrstream.c (mu_stream_format_address):
Format local user names without surrounding angle quotes.
* mail/mail.h (util_header_expand): Rename to
util_header_expand_aliases. All uses changed.
(util_address_expand_aliases): New function.
* mail/send.c (compose_header_set): Expand aliases if
inplacealiases is set. Avoid useless recursion.
* mail/util.c (send_message): Create addresses via
mu_address_create_hint to avoid appending local domain to the
unqualified user names.
(mail_send0): Likewise.
(util_address_expand_aliases): New function.
(util_header_expand): Rename to util_header_expand_aliases. Use
util_address_expand_aliases and regular address parsing
functions instead of wordsplit. Unwrap header values.
2021-05-25 Sergey Poznyakoff <gray@gnu.org>
Test IMAP folder scanning.
* imap4d/imap4d.c (prefix_section_parser): Use
namespace_encode_delim.
* imap4d/imap4d.h (namespace_decode_delim)
(namespace_encode_delim): New protos.
* imap4d/list.c (list_ref): Convert delimiters in the wcard to
/.
* imap4d/namespace.c (namespace_decode_delim)
(namespace_encode_delim): New functions.
* imap4d/tests/testclient.c: New auxiliary program.
* imap4d/tests/.gitignore: Add testclient.
* imap4d/tests/Makefile.am: Add new tests
* imap4d/tests/atlocal.in: Include libproto/imap/tests in the
PATH.
* imap4d/tests/clt_list.at: New file.
* imap4d/tests/list.at: Test delimiter translation.
* imap4d/tests/testsuite.at: Add new tests.
* libproto/imap/tests/imapfolder.c: Sort the resulting lists.
Use quoting on output.
2021-05-25 Sergey Poznyakoff <gray@gnu.org>
imap4d LIST: discern between implementation-defined and
required behavior.
* imap4d/list.c (match_pfx): Return true if ref is "pfx/",
where / stands for a namespace delimiter.
* imap4d/namespace.c (prefix_translate_name): namespace prefix
is required to end with a delimiter.
* imap4d/tests/list.at: Make sure all reference arguments that
refer to directories end in a hierarchy delimiter.
2021-05-23 Sergey Poznyakoff <gray@gnu.org>
fix memory leak in folder scanner.
* libmailutils/mailbox/folder.c (mu_folder_enumerate): Set the
destroy_item function on the created list.
* libmailutils/mailbox/fsfolder.c (list_helper): Free the resp
structure when it is no longer needed.
2021-05-23 Sergey Poznyakoff <gray@gnu.org>
Fix the previous commit: take into account "" mailbox names.
* libproto/imap/folder.c (_mu_imap_folder_separator): Use empty
mailbox name to get the hierarchy delimiter.
* libproto/imap/genlist.c: Take into account eventual hierarchy
delimiter queries.
2021-05-22 Sergey Poznyakoff <gray@gnu.org>
folder scan returns mailbox names without the leading directory
prefix.
For example, suppose folder /foo/bar contains mailboxes a, b,
and c. Then scanning the mu_folder_t object for '/foo' will
return 'bar/a', 'bar/b', and 'bar/c'. Scanning the mu_folder_t
for '/foo/bar'
will return 'a', 'b', and 'c', and so on.
* libmailutils/string/mkfilename.c (mu_make_file_name_suf):
Reasonable handling of corner cases. Document its behavior.
* libmailutils/mailbox/fsfolder.c (struct folder_scan_data):
New member: prefix_len
(list_helper): Return the portion of the file name after the
base directory prefix.
(_fsfolder_list): Initialize sdata.prefix_len.
* libmailutils/tests/fsfolder.c: Remove prefix handling code.
* libmailutils/tests/fsfolder00.at: Change expectations.
* libmailutils/tests/fsfolder02.at: Likewise.
* libmailutils/tests/fsfolder03.at: Likewise.
* libmailutils/tests/fsfolder04.at: Likewise.
* include/mailutils/sys/imap.h (struct _mu_imap): New members:
separator and prefix_len.
* libproto/imap/folder.c (_mu_imap_folder_separator): New
function.
(_mu_imap_folder_pathname): New function.
(_mu_imap_folder_list): Prefix the original refname with the
base directory of the folder.
(_mu_imap_folder_lsub,_mu_imap_folder_subscribe)
(_mu_imap_folder_unsubscribe,_mu_imap_folder_delete)
(_mu_imap_folder_rename): Adjust input mailbox names.
* libproto/imap/genlist.c (list_untagged_handler): Return the
portion of the file name after the base directory prefix.
* libproto/imap/tests/imapfolder.c: Minor change.
Update for changed folder behavior
* imap4d/list.c (struct refinfo): Replace dirlen with delim - a
character to be inserted between the original reference and
mailbox name.
(list_fun): Insert delimiter, if required.
(list_ref): Set refinfo.delim, unless the reference prefix
already ends with a delimiter or is the same as the namespace
prefix.
Mail 'folders' command: add support for remote folders.
* mail/folders.c: Handle remote folders correctly.
* mail/mail.h (util_get_folder): New proto.
* mail/mailline.c (struct filegen): Remove path_len.
(new_folder): Rename to util_get_folder and move to util.c
(filegen_init): Initialize prefix_len from the argument.
* mail/util.c (util_get_folder): New function.
2021-05-21 Sergey Poznyakoff <gray@gnu.org>
Bugfix in mu_list_clear.
The bug affected imap client code, in particular.
* libmailutils/list/clear.c (mu_list_clear): Reset list item
count.
2021-05-01 Sergey Poznyakoff <gray@gnu.org>
Revise the mailbox locking functions.
The locker is created by the following call:
mu_locker_create_ext(&locker, filename, &hints);
The last arguments points to a structure mu_locker_hints_t,
which defines the settings for the locker. NULL value implies
default. Settings of an existing locker can be modified using
the following call:
mu_locker_modify(locker, &hints);
Current settings can be examined using mu_locker_get_hints.
The functions mu_locker_destroy, mu_locker_lock_mode,
mu_locker_lock, mu_locker_touchlock, mu_locker_unlock, and
mu_locker_remove_lock remained unchanged. Rest of functions is
deprecated, but retained for a couple of releases for the sake
of backward compatibility.
Constants (locker types, flags, etc) are also revisited.
This commit also fixes a bug in mu_spawnvp function, which was
discovered when testing external lockers.
* include/mailutils/locker.h: Major rewrite.
(MU_LOCKER_DEFAULT_EXPIRE_TIME) (MU_LOCKER_DEFAULT_RETRY_COUNT)
(MU_LOCKER_DEFAULT_RETRY_SLEEP)
(MU_LOCKER_DEFAULT_EXT_LOCKER): New defines.
(mu_locker_hints_t): New data type. (MU_LOCKER_FLAG_RETRY)
(MU_LOCKER_FLAG_EXPIRE_TIME) (MU_LOCKER_FLAG_CHECK_PID)
(MU_LOCKER_FLAG_TYPE,MU_LOCKER_FLAGS_ALL): New defines.
(mu_locker_create_ext, mu_locker_modify)
(mu_locker_get_hints): New functions.
(mu_locker_create,mu_locker_set_default_flags)
(mu_locker_set_default_retry_timeout)
(mu_locker_set_default_retry_count)
(mu_locker_set_default_expire_timeout)
(mu_locker_set_default_external_program)
(mu_locker_set_flags,mu_locker_mod_flags)
(mu_locker_set_expire_time,mu_locker_set_retries)
(mu_locker_set_retry_sleep,mu_locker_set_external)
(mu_locker_get_flags,mu_locker_get_expire_time)
(mu_locker_get_retries,mu_locker_get_retry_sleep): Mark as
deprecated.
* libmailutils/base/locker.c: Rewrite.
* libmailutils/cli/stdcapa.c: New locking statements: type and
retry-sleep. retry-timeout is deprecated.
* libmailutils/tests/lck.c: Use new locker functions.
* libmailutils/tests/lock.at: Test the external locker.
* libmailutils/base/spawnvp.c (mu_spawnvp): Restore the default
SIGCHLD handler while waiting for the process to terminate.
* dotlock/dotlock.c: Use new locker functions.
* lib/manlock.c: Likewise.
* libmailutils/base/amd.c: Likewise.
* libmu_dbm/berkeley.c: Likewise.
* libmu_sieve/extensions/vacation.c: Likewise.
* libproto/dotmail/dotmail.c: Likewise.
* libproto/mbox/mboxrd.c: Likewise.
* mail/copy.c: Likewise.
* mda/lmtpd/lmtpd.c: Modify mu_locker_defaults instead of using
deprecated functions.
* mda/mda/mda.c: Likewise.
* mda/putmail/putmail.c: Likewise.
* NEWS: Document changes.
* configure.ac: Version 3.12.90.
* doc/texinfo/Makefile.am: Add programs/dotlock.texi
* doc/texinfo/programs.texi: Rewrite the locking section. New
section: dotlock.
* doc/texinfo/programs/dotlock.texi: New file.
2021-04-29 Sergey Poznyakoff <gray@gnu.org>
mail: accept attachments from FIFOs.
* mail/send.c: Use mu_file_stream_create for FIFOs.
2021-04-29 Sergey Poznyakoff <gray@gnu.org>
mh: fix extra doc formatting.
* mh/mh_getopt.c (mh_extra_help_hook): Use number of leading
whitespace as left margin for output.
2021-04-29 Sergey Poznyakoff <gray@gnu.org>
libopt: don't show hidden options in the --usage output.
* libmailutils/opt/help.c (option_summary): Skip options with
MU_OPTION_HIDDEN bit set.
(mu_option_describe_options): Reset margin to 0 so that
eventual extra_doc is formatted correctly.
2021-04-29 Sergey Poznyakoff <gray@gnu.org>
Further improvements of the locker interface.
This fixes a bug that prevented previous versions of mailutils
to retry aquiring the lock.
Locking configuration (the "locking" section) is improved.
* dotlock/dotlock.c: New options: --retry (-r), --delay (-t),
--pid-check (-p). Use the "locking" capability.
* libmailutils/base/locker.c: Remove the uses of assert().
(mu_locker_lock_mode): Fix the retry loop.
(lock_dotlock): Use mu_asprintf to create temporary lock name.
Return EAGAIN on temporary error conditions.
(lock_kernel): Fix typo (EACCES).
* libmailutils/cli/stdcapa.c (cb_locker_flags): Locker flags
are deprecated.
(cb_locker_retry_timeout,cb_locker_retry_count): Clear the
MU_LOCKER_RETRY flag, if supplied a zero value.
(cb_locker_external): Clear the MU_LOCKER_EXTERNAL flag (revert
to the dotlock locker type) if the value is a false boolean
value.
* libmailutils/tests/Makefile.am: Add new test.
* libmailutils/tests/testsuite.at: Include new test,
* libmailutils/tests/lck.c: New test program.
* libmailutils/tests/lock.at: New test.
2021-04-27 Sergey Poznyakoff <gray@gnu.org>
Fix misattributed locker flags.
* libmailutils/cli/stdcapa.c (cb_locker_expire_timeout)
(cb_locker_external): Pass proper first argument to
mu_locker_set_default_flags.
2021-04-18 Sergey Poznyakoff <gray@gnu.org>
Bugfix in the configuration file lexer.
String values like the following caused failure:
"foo \
bar \
baz \
qux"
The second and third physical lines would not be recognized by
the scanner. The bug was due to a long-standing copy-paste
error.
2021-04-18 Sergey Poznyakoff <gray@gnu.org>
SQL auth: supply backend-specific parameters via the "param"
statement.
For MySQL, backend-specific parameter is a list of
keuword=value pairs delimited by semicolons. Valid keywords
are:
defaults_file - read configuration from the supplied file;
group - if default_file is supplied, read configuration from
this named group (default - "client"); ca - name of the
certificate authority file;
* include/mailutils/sql.h (mu_sql_module_config)<param>: New
member.
(mu_sql_connection)<param>: New member.
(mu_sql_connection_init): Take additional argument (param). All
uses changed.
* libmu_auth/sql.c: New keyword: "param".
* sql/mysql.c (mu_mysql_connect): Parse backend-specific
parameters: defaults_file, group, and ca.
* sql/sql.c (mu_sql_connection_init): Take additional argument.
Initialize the connection param member.
2021-04-18 Sergey Poznyakoff <gray@gnu.org>
mbox,dotmail: fix the _message_unseen method.
* libproto/dotmail/dotmail.c (dotmail_message_unseen): Set
return value to 0 and return success if there are no unseen
messages.
* libproto/mbox/mboxrd.c (mboxrd_message_unseen): Likewise.
2021-04-15 Sergey Poznyakoff <gray@gnu.org>
Bugfix in mimeview testsuite.
* mimeview/tests/bf.c (write_byte): Fix type of the character
buffer.
2021-04-15 Sergey Poznyakoff <gray@gnu.org>
Minor fix.
* include/mailutils/sys/streamtrans.h: Add missing #endif
2021-02-13 Sergey Poznyakoff <gray@gnu.org>
Version 3.12.
2021-02-13 Sergey Poznyakoff <gray@gnu.org>
Skip imap4d tests if home directory does not exist.
* imap4d/tests/testsuite.at (IMAP4D_RUN): Skip test if home
directory does not exist.
2021-02-10 Sergey Poznyakoff <gray@gnu.org>
inc: when updating the unseen sequence, translate message
numbers to uids.
* mh/inc.c (main): Ensure translation from ordinal to sequence
numbers (uid).
2021-02-09 Sergey Poznyakoff <gray@gnu.org>
dotmail: synchronize with the recent changes to mbox.
* libproto/dotmail/dotmail.c: Synchronize with the recent
changes to mbox.
* libproto/dotmail/tests/rospool.at: New test.
* libproto/dotmail/tests/Makefile.am: Add new test.
* libproto/dotmail/tests/testsuite.at: Add new test.
2021-02-09 Sergey Poznyakoff <gray@gnu.org>
mbox: use fstat etc. instead of stat etc.
* libproto/mbox/mboxrd.c (mboxrd_stat,mboxrd_set_priv): New
functions.
(mboxrd_get_atime): Use mboxrd_stat instead of stat(2). Fix the
return value.
(mboxrd_flush_unlocked): Use mboxrd_stat to stat the mailbox
and mboxrd_set_priv to set mode and ownership.
* libproto/mbox/tests/rospool.at: Remove extra newline (typo).
2021-02-09 Sergey Poznyakoff <gray@gnu.org>
mbox: fix expunging in a read-only directory.
This fixes debian bug 980042. Re:
https://bugs.debian.org/cgi-bin/bugreport.cgi?bug=980042#16
* libproto/mbox/mboxrd.c (mboxrd_flush_unlocked): If temporary
file cannot be created in the directory of the mailbox because
of EACCES, create it elsewhere and copy back to the mailbox
when ready. Also, make sure that the mode and ownership of the
mailbox are preserved, no matter what temporary file was used.
* libproto/mbox/tests/rospool.at: New test.
* libproto/mbox/tests/Makefile.am: Add new test.
* libproto/mbox/tests/testsuite.at: Add new test.
2021-01-12 Sergey Poznyakoff <gray@gnu.org>
Fix libmu_scm testsuite.
This is a follow-up to a3bd653315.
* libmu_scm/tests/testsuite.at (MU_GUILE_OUTPUT_FILTER): New
macro.
(MU_GUILE_CHECK): If MU_GUILE_OUTPUT_FILTER is not empty,
filter the stdout through it.
* libmu_scm/tests/mailbox-append-message.at: Filter out line
and byte counts.
* libmu_scm/tests/mailbox-expunge.at: Fix line and byte counts.
* libmu_scm/tests/mailbox-get-message.at: Likewise.
* libmu_scm/tests/mailbox-iterate.at: Likewise.
2021-01-12 Sergey Poznyakoff <gray@gnu.org>
Remove left-over mailutils.rc support.
* libmailutils/cli/cli.c (MU_LEGACY_CONFIG_FILE): Remove.
(mu_cli_ext): No handling for the pre-3.0 configuration file.
2021-01-11 Sergey Poznyakoff <gray@gnu.org>
Fix building mda utilities with mailbox quotas off.
2021-01-11 Sergey Poznyakoff <gray@gnu.org>
Fix architecture-dependent test failures.
* configure.ac (MU_COND_MAILBOX_QUOTA): Fix test condition.
* libproto/dotmail/tests/atlocal.in (x_imapbase_normalize): New
function.
* libproto/mbox/tests/atlocal.in: Likewise.
* libproto/dotmail/tests/delete.at: Filter output through
x_imapbase_normalize to avoid triggering false negative due to
padding differences.
* libproto/mbox/tests/delete.at: Likewise.
2021-01-11 Sergey Poznyakoff <gray@gnu.org>
Force character signedness in strout test.
2021-01-11 Sergey Poznyakoff <gray@gnu.org>
SMTP mailer: fix selection of the default port.
* libproto/mailer/smtp.c (smtp_open): Use MU_SMTPS_PORT only if
MAILER_TLS_ALWAYS is required.
2021-01-11 Sergey Poznyakoff <gray@gnu.org>
strout test: don't wait for the input forever.
* libmailutils/tests/strout.c: Run no longer than 30 seconds.
Standardize exit codes.
2021-01-05 Sergey Poznyakoff <gray@gnu.org>
Minor changes.
2021-01-05 Sergey Poznyakoff <gray@gnu.org>
Version 3.11.1.
2021-01-05 Sergey Poznyakoff <gray@gnu.org>
Fix version output.
* include/mailutils/cli.h (mu_copyright_year): New extern.
(mu_version_print): New proto.
* libmailutils/cli/cli.c (mu_copyright_year): New variable.
Should be updated once a year.
(mu_version_print): New function.
(mu_version_hook): Use mu_version_print.
* mail/mail.c (mail_warranty): Use mu_version_print.
2021-01-05 Sergey Poznyakoff <gray@gnu.org>
Update copyright years.
2020-12-30 Sergey Poznyakoff <gray@gnu.org>
Fix coredump on NULL input to mu_url_create_hint.
In particular, this caused inc to coredump when called without
explicit -file option.
* libmailutils/url/create.c (mu_url_create_hint): Return EINVAL
if str is NULL.
* mh/tests/inc.at: Add new test.
2020-12-30 Sergey Poznyakoff <gray@gnu.org>
Use well-known mboxrd format name everywhere.
2020-12-23 Sergey Poznyakoff <gray@gnu.org>
Version 3.11.
2020-12-21 Sergey Poznyakoff <gray@gnu.org>
MH: provide a mh_profile setting to control assignment of
sequence numbers.
The "Volatile-uidnext" setting controls how sequence numbers
are allocated. By default they increase monotonically. If
Volatile-uidnext is set to "true", each new incorporated
message is assigned the sequence number equal to that of the
last message increased by one. When the last message in the
mailbox is deleted, the value of UIDNEXT is recalculated and
UIDVALIDITY is increased. This follows the behavior of
traditional MH implementations.
* doc/texinfo/mu-mh.texi: Document chnges.
* include/mailutils/sys/amd.h (MU_AMD_VOLATILE_UIDNEXT): New
constant.
* libmailutils/base/amd.c (amd_expunge): Reset uidvalidity and
uidnext if MU_AMD_VOLATILE_UIDNEXT capability is set and the
last message was removed.
* libproto/mh/mh.c (_mailbox_mh_init): New mh_profile setting
"Volatile-uidnext". If set to true, it instructs mailutils to
mimic the traditional MH behavior when assigning sequence
number to the new message.
* testsuite/mbop.c (main): Use MBOP_PRE_OPEN_HOOK (if defined)
as the name of the function to call before opening the mailbox.
* libproto/mh/tests/mbop.c (mbop_pre_open_hook): New function.
If the MH environment variable is set, take its value as the
name of the mh_profile and read settings from it.
* libproto/mh/tests/Makefile.am: Add uidvol.at
* libproto/mh/tests/atlocal.in: Unset MH.
* libproto/mh/tests/testsuite.at: Include uidvol.at
* libproto/mh/tests/uidvol.at: New file.
2020-12-04 Sergey Poznyakoff <gray@gnu.org>
amd: reset the UIDNEXT after resetting the uidvalidity.
This happens automatically for plaintext mailboxes, but needs
to be done explicitly for directory-based ones.
* libmailutils/base/amd.c (amd_set_uidvalidity): Reset the
UIDNEXT
* testsuite/mbop.c: New command: uidvalidity_reset
2020-12-04 Sergey Poznyakoff <gray@gnu.org>
Explicitly reset uidvalidity after folder -pick.
(See also 6e0fb32ec8)
2020-11-30 Sergey Poznyakoff <gray@gnu.org>
Version 3.10.91.
2020-11-30 Sergey Poznyakoff <gray@gnu.org>
New functions for closing all fds and daemonizing.
* configure.ac: Select a suitable interface for closing all
file descriptors greater than or equal to a chosen one.
* include/mailutils/daemon.h (mu_daemon): New proto.
* include/mailutils/util.h (mu_close_fds): New proto.
* lib/daemon.c: Removed.
* lib/Makefile.am: Remove daemon.c
* libmailutils/base/Makefile.am: Add closefds.c
* libmailutils/base/closefds.c: New file.
* libmailutils/base/daemon.c: Rename to
libmailutils/base/pidfile.c
* libmailutils/base/daemon.c: New file.
* libmailutils/diag/bt.c: Use mu_close_fds.
* libmailutils/server/acl.c: Likewise.
* mh/mh_whatnow.c: Likewise.
* libmailutils/stream/prog_stream.c: Likewise.
* libmailutils/server/msrv.c: Use mu_daemon.
* mh/send.c: Likewise.
* mda/lib/util.c (mda_close_fds): Remove.
2020-11-29 Sergey Poznyakoff <gray@gnu.org>
Optimize the observable interface.
A bitmask of all requested event types is stored in the
observable structure. When an event is reported,
mu_observable_notify first check if the event type bit is set
in that bitmap. If so, it starts iterating over observers. That
should allow us to avoid the loop in most cases.
* include/mailutils/observer.h (mu_observable_wants): New
proto.
* include/mailutils/sys/observer.h (_mu_observable): New
member: types.
* libmailutils/base/observer.c (mu_observable_attach): Compute
bitmask of all types requested by attached observers.
(mu_observable_detach): Likewise.
(mu_observable_notify): Check if the event type is marked in
the bitmap, skip iteration if it is not.
(mu_observable_wants): New function.
2020-11-29 Sergey Poznyakoff <gray@gnu.org>
Avoid using VPATH in libproto testsuites.
* libproto/dotmail/tests/Makefile.am: Build mbop from local
source.
* libproto/maildir/tests/Makefile.am: Likewise.
* libproto/mbox/tests/Makefile.am: Likewise.
* libproto/mh/tests/Makefile.am: Likewise.
* libproto/dotmail/tests/mbop.c: New file.
* libproto/maildir/tests/mbop.c: New file.
* libproto/mbox/tests/mbop.c: New file.
* libproto/mh/tests/mbop.c: New file.
Rename mbox.c files in libproto libraries to avoid confusion
with the eponymous format.
* libproto/imap/mbox.c: Rename to mailbox.c.
* libproto/imap/Makefile.am: Update.
* libproto/maildir/mbox.c: Rename to maildir.c
* libproto/maildir/Makefile.am: Update.
* libproto/mailer/mbox.c: Rename to mailbox.c
* libproto/mailer/Makefile.am: Update.
* libproto/mh/mbox.c: Rename to mh.c.
* libproto/mh/Makefile.am: Update.
* libproto/pop/mbox.c: Rename to mailbox.c
* libproto/pop/Makefile.am: Update.
2020-11-27 Sergey Poznyakoff <gray@gnu.org>
Improve mbox data/time handling.
* libproto/mbox/mboxrb.c (scan_message_begin): Use a single
scan format for parsing all possible variants of the date/time.
2020-11-27 Sergey Poznyakoff <gray@gnu.org>
Don't use __FILE__ and __LINE__ in mu_debug.
This is spurious as it can be enabled by the debug.line-info
configuration directive.
2020-11-27 Sergey Poznyakoff <gray@gnu.org>
mu_scan_datetime: Fix error recovery. %Z handles both
time-zone forms.
The value stored in the memory location pointed to by the endp
argument has changed. On the MU_ERR_PARSE error, it is (as
earlier) the position in input where conversion stopped. On the
MU_ERR_FORMAT, however, it is the character in fmt where the
format error was detected.
* libmailutils/datetime/scantime.c (peek_state): Return
MU_ERR_FORMAT if mu_list_tail fails (the list is empty). This
reflects unbalanced closing parenthesis or bracket.
(scan_recovery): fix algorithm.
(mu_scan_datetime): %Z handles both abbreviated time-zones and
time-zones as hour offset from GMT. Improve error handling. On
MU_ERR_PARSE error, point *endp to the character in input where
conversion stopped. On MU_ERR_FORMAT error, point it to the
character in fmt, where the format error was detected.
* libmailutils/tests/scantime.c: Improve error handling.
* libmailutils/tests/scantime.at: More testcases.
2020-11-26 Sergey Poznyakoff <gray@gnu.org>
dotmail: re-implement tracker along the lines of mboxrb.
* include/mailutils/sys/dotmail.h (mu_dotmail_message): New
member: mark.
(mu_dotmail_message_reconstruct): Change signature.
* libproto/dotmail/dotmail.c (mu_dotmail_flush_tracker): Change
type of the ref member.
(tracker_next_ref): Rewrite.
(dotmail_tracker_sync): Rewrite.
(dotmail_mailbox_copy_unchanged): Rewrite.
* libproto/dotmail/message.c (dotmail_message_copy_with_uid)
(mu_dotmail_message_reconstruct): Rewrite.
* libproto/dotmail/tests/delete.at: Rewrite.
2020-11-26 Sergey Poznyakoff <gray@gnu.org>
mboxrb: Keep timestamps in normalized form.
* include/mailutils/datetime.h (mu_timezone_offset): New proto.
* libmailutils/datetime/scantime.c: New conversion: %Z
(timezone abbreviation).
* libmailutils/datetime/parsedate.y (mu_timezone_offset): New
function. Returns time offset in seconds corresponding to the
given timezone abbreviation.
* include/mailutils/sys/mboxrb.h (mu_mboxrb_hdr): Remove
unneeded enum.
(mu_mboxrb_message): Remove env_date_start, New member "date"
holds the string representation of the envelope timestamp in
normalized form - ctime(3), UTC.
* libproto/mbox/mboxrb.c (scan_message_finalize): New function.
(scan_message_begin): New function. When initializing the
message, timestamps in obsolete forms are converted to
normalized representation.
(mboxrb_rescan_unlocked): Use scan_message_finalize and
scan_message_begin.
* libproto/mbox/message.c (mboxrb_envelope_date): Get
normalized timestamp from the date member,
* libproto/mbox/tests/env.at: Reflect the above changes.
2020-11-25 Sergey Poznyakoff <gray@gnu.org>
Improve mboxrb scanner.
* libproto/mbox/mboxrb.c: Request that the From_line be
preceded by an empty line.
2020-11-25 Sergey Poznyakoff <gray@gnu.org>
Replace mbox format driver with mboxrb.
* NEWS: update
* configure.ac: Revert 9763fd4a.
* include/mailutils/registrar.h: Likewise.
* libproto/Makefile.am: Likewise.
* libmailutils/stream/stream.c (mu_stream_size): Fix size
calculation in case of line and full buffering scheme.
* libmailutils/stream/streamcpy.c (mu_stream_copy_nl): Change
semantics. Ensure that the copied data ends with two newline
characters. Append them if necessary.
* testsuite/mbop.c: New commands: message_lines and
message_size.
* libproto/mbox/mboxrb.c (mboxrb_mailbox_init_stream): Always
add MU_STREAM_READ permission. Use the same flags for
mu_mapfile_stream_create and mu_file_stream_create.
(mboxrb_rescan_unlocked): Count terminating newline as part of
the message.
(mailbox_append_message): Make sure each message ends with an
empty line.
(mboxrb_tracker_sync): Update mailbox mesg_count.
(mboxrb_flush_temp): Truncate the temporary stream to the new
size.
(mboxrb_flush_unlocked): Clear all modifications only in
FLUSH_UIDVALIDITY mode.
(mboxrb_message_copy_with_uid): Fix message_end computation.
Use mu_stream_copy_nl to copy message body.
(mu_mboxrb_message_reconstruct): Update ref on return.
* po/POTFILES.in: Update.
* mail/copy.c (append_to_file): Use mu_stream_stat_buffer to
compute statistics.
* mail/mail.c: Allow for opening read-only mailboxes.
* libproto/mbox/tests/body.at: Fix the expected byte count.
* libproto/mbox/tests/qget.at: Likewise.
* libproto/mbox/tests/delete.at: Add more tests.
* mail/tests/align.at: Fix the expected byte and line count.
* mail/tests/hold.at: Likewise.
* mail/testsuite/mail/read.exp: Likewise.
* mail/testsuite/mail/tag.exp: Likewise.
* mail/testsuite/mail/z.exp: Likewise.
* mail/tests/copy04.at: Don't use line count and size in
comparison.
* mail/testsuite/mail/write.exp: Use regexps instead of exact
strings for the same reason.
* pop3d/testsuite/pop3d/read.exp: Fix the expected byte count.
* readmsg/tests/all.at: Expect extra newline in output.
* readmsg/tests/hdr.at: Likewise.
* readmsg/tests/nohdr.at: Likewise.
* readmsg/tests/twomsg.at: Likewise.
* readmsg/tests/weed.at: Likewise.
* sieve/tests/redirect.at: Fix the expected byte count.
* sieve/tests/reject.at: Expect extra newline in output.
* mh/inc.c (incmbx): Parse truncate and nomoveto URL parameters
prior to opening the mailbox. If notruncate is requested, open
the mailbox read-only.
* mh/mh_format.c (str_compress_ws): Fix copying between
overlapping memory regions.
* libtests/Makefile.am: Remove lstuid tests.
* libtests/testsuite.at: Likewise.
* libtests/lstuid.c: Remove.
* libtests/lstuid00.at: Remove.
* libtests/lstuid01.at: Remove.
* libtests/lstuid02.at: Remove.
* libtests/mime.at: Fix the expected byte count.
* imap4d/tests/IDEF0956.at: Fix the expected byte count.
* map4d/tests/fetch.at: Likewise.
* imap4d/tests/append00.at: Remove X-* headers and Status from
the mbox prior to comparison.
* imap4d/tests/append01.at: Likewise.
* libproto/mbox: Remove old code. Replace it with mboxrb.
* mail/tests/nohome.at: Update lines/sizes.
* mail/testsuite/mail/folder.exp: Likewise.
* mail/testsuite/mail/tag.exp: Likewise.
* mail/testsuite/mail/z.exp: Likewise.
* mda/mda/tests/mda.at: Fix shell quoting.
* mda/putmail/tests/putmail.at: Remove extra newline from the
expectation. Eliminate X-IMAPbase and X-UID from the resulting
mailbox.
* mda/tests/mda.sh: Eliminate X-IMAPbase and X-UID from the
output.
* pop3d/testsuite/pop3d/read.exp: Fix expected lines/sizes
* readmsg/tests/hdr.at: Fix extra whitespace.
* sieve/tests/action.at: Eliminate X-IMAPbase and X-UID. Fix
extra whitespace in the expected From_ line.
* sieve/tests/addheader.at: Likewise.
* sieve/tests/pipeact.at: Likewise.
2020-11-23 Sergey Poznyakoff <gray@gnu.org>
Two bugfixes.
* libproto/mboxrb/mboxrb.c (mboxrb_open): Propagate failure to
open the stream to the return code.
* libproto/mboxrb/tests/notify.at: Use cat to create test inbox
2020-11-23 Sergey Poznyakoff <gray@gnu.org>
Add two more mboxrb tests.
2020-11-23 Sergey Poznyakoff <gray@gnu.org>
mboxrb: rewrite tracker.
* include/mailutils/sys/mboxrb.h (mu_mboxrb_message_ref):
Remove.
(mu_mboxrb_message_reconstruct): Change prototype.
* libproto/mboxrb/mboxrb.c (mu_mboxrb_flush_tracker) <ref>:
Change type to size_t *.
(tracker_next_ref): Return the refereced message.
(mboxrb_tracker_sync): Rewrite.
(mboxrb_mailbox_copy_unchanged): Update.
(mailbox_append_message): Place exactly one empty line between
two messages.
* libproto/mboxrb/message.c (mboxrb_message_copy_with_uid): Ref
argument is struct mu_mboxrb_message *.
(mu_mboxrb_message_reconstruct): Likewise.
* libproto/mboxrb/tests/delete.at: Check number of messages
after deletion.
* libproto/mboxrb/tests/append.at: Expect extra newline.
2020-11-23 Sergey Poznyakoff <gray@gnu.org>
Fix deletes. Add new tests.
* include/mailutils/sys/mboxrb.h (mu_mboxrb_message): New
member: mark
* libproto/mboxrb/mboxrb.c (mu_mboxrb_message_ref): New
members: from_length, env_sender_len, env_date_start.
* libproto/mboxrb/message.c (mboxrb_rescan_unlocked): Update
dmp->scan. Fix NULL dereference.
(mboxrb_rescan): Don't update dmp->scan, see above.
(mailbox_append_message): Write out envelope; use FROMRB
filter.
(mboxrb_tracker_sync): Rewrite using mark/sweep technique.
* libproto/mboxrb/tests/Makefile.am: Add new tests.
* libproto/mboxrb/tests/testsuite.at: Include new tests.
* libproto/mboxrb/tests/append.at: New test.
* libproto/mboxrb/tests/delete.at: New test.
* libproto/mboxrb/tests/qget.at: New test.
* libproto/mboxrb/tests/uidnext.at: New test.
* libproto/mboxrb/tests/uidvalidity.at: New test.
2020-11-23 Sergey Poznyakoff <gray@gnu.org>
Implement mboxrb format (a replacement for the mbox used
currently)
* configure.ac: New format: mboxrb
* include/mailutils/filter.h (mu_fromrb_filter): New extern.
* include/mailutils/registrar.h (mu_mboxrb_record): New extern.
(mu_register_all_mbox_formats)
(mu_register_local_mbox_formats): Add mu_mboxrb_record.
* libmailutils/filter/filter.c (mu_filter_get_list): Add
mu_fromrb_filter
* libproto/Makefile.am [MU_COND_SUPPORT_MBOXRB]: Add mboxrb
* bootstrap.conf: Remove special handling for testsuite/maildir
(fixes 1d846d2d92).
* testsuite/mbop.c: Implement the -r (--read-only) option.
* include/mailutils/sys/Makefile.am: Add mboxrb.h
* include/mailutils/sys/mboxrb.h: New file.
* libmailutils/filter/Makefile.am (libfilter_la_SOURCES): Add
fromrb.c
* libmailutils/filter/fromrb.c: New file.
* libmailutils/tests/Makefile.am: New file.
* libmailutils/tests/fromrb.at: New file.
* libmailutils/tests/testsuite.at: New file.
* libproto/mboxrb/Makefile.am: New file.
* libproto/mboxrb/mboxrb.c: New file.
* libproto/mboxrb/message.c: New file.
* libproto/mboxrb/tests/.gitignore: New file.
* libproto/mboxrb/tests/Makefile.am: New file.
* libproto/mboxrb/tests/atlocal.in: New file.
* libproto/mboxrb/tests/attr.at: New file.
* libproto/mboxrb/tests/autodetect.at: New file.
* libproto/mboxrb/tests/body.at: New file.
* libproto/mboxrb/tests/count.at: New file.
* libproto/mboxrb/tests/env.at: New file.
* libproto/mboxrb/tests/header.at: New file.
* libproto/mboxrb/tests/testsuite.at: New file.
2020-11-20 Sergey Poznyakoff <gray@gnu.org>
dotmail: update uids in append mode as well.
* include/mailutils/sys/dotmail.h (mu_dotmail_mailbox): New
member stream_flags.
* libproto/dotmail/dotmail.c (dotmail_mailbox_init_stream):
Translate MU_STREAM_APPEND to MU_STREAM_RDWR.
(dotmail_rescan_unlocked,dotmail_rescan): Check actual stream
flags, not the mailbox ones.
(dotmail_flush_unlocked): Remove check for MU_STREAM_APPEND.
* libproto/dotmail/tests/append.at: Test appends in append
mode.
* testsuite/mbop.c: New option -a (--append).
2020-11-20 Sergey Poznyakoff <gray@gnu.org>
dotmail: optimize appends.
* include/mailutils/sys/dotmail.h (mu_dotmail_mailbox): New
members: x_imapbase_off and x_imapbase_len.
* libproto/dotmail/dotmail.c: Format X-IMAPbase header with
fixed width to avoid rewriting entire mailbox only to make the
new header fit to its place in the first message.
2020-11-19 Sergey Poznyakoff <gray@gnu.org>
Make sure UIDs are monotonically increased in dotmail, mh, and
maildir.
* include/mailutils/sys/amd.h (_MU_AMD_PROP_UIDNEXT): New
define.
(MU_AMD_PROP): Remove.
(MU_AMD_F_PROP): New flag.
(_amd_data): New member: flags. Remove next_uid
(amd_reset_uidvalidity): Change return type.
(amd_update_uidnext,amd_alloc_uid): New protos.
* include/mailutils/sys/dotmail.h (mu_dotmail_mailbox): New
member uidvalidity_changed.
* libmailutils/base/amd.c (_amd_prop_create): Set MU_AMD_F_PROP
flag if the prop file exists.
(amd_initial_scan): New function. (amd_get_uidvalidity,
amd_set_uidvalidity)
(amd_uidnext): Rewrite using amd_initial_scan.
(amd_reset_uidvalidity): Return int.
(amd_update_uidnext,amd_alloc_uid): New functions.
* libproto/dotmail/dotmail.c (dotmail_close): Flush UID
parameters if uidvalidity_changed is set.
(dotmail_flush): Take three-state mode as its third argument.
(dotmail_flush_unlocked): Likewise. If operating in
FLUSH_UIDVALIDITY mode, clear all other modifications to the
messages in the mailbox. Clear uidvalidity_changed on success.
(dotmail_expunge, dotmail_sync): Update call to dotmail_flush.
(dotmail_alloc_next_uid): Set uidvalidity_changed.
(dotmail_rescan_unlocked): Check if the assigned UID is greater
than the previously assigned one and less than the UIDNEXT
value. Raise uidvalidity_changed if UIDs were re-allocated.
(mu_dotmail_mailbox_uid_setup): Set uidvalidity_scanned.
* libproto/dotmail/tests/Makefile.am: Add new test.
* libproto/dotmail/tests/testsuite.at: Likewise.
* libproto/dotmail/tests/uidnext.at: New test.
* libproto/maildir/mbox.c: Use amd_update_uidnext to
synchronize the computed and predicted uidnext value.
(maildir_next_uid): Remove.
* libproto/maildir/tests/Makefile.am: Add new test.
* libproto/maildir/tests/testsuite.at: Likewise.
* libproto/maildir/tests/uidnext.at: New test.
* libproto/mh/mbox.c (_mh_next_seq): Remove function.
(mh_scan0): Use amd_update_uidnext to synchronize the computed
and predicted uidnext value.
* libproto/mh/tests/Makefile.am: Add new test.
* libproto/mh/tests/testsuite.at: Likewise.
* libproto/mh/tests/uidnext.at: New test.
2020-11-18 Sergey Poznyakoff <gray@gnu.org>
imap4d: SEARCH: don't bail out if unexistent UID is given as
criterion.
* imap4d/search.c (node_false): New constant.
(parse_simple_key): Report error only if mu_msgset_parse_imap
returns MU_ERR_PARSE. Otherwise, add node_false to the tree.
(evaluate_node): Handle node_false.
2020-11-18 Sergey Poznyakoff <gray@gnu.org>
maildir: assign UID to the message file before moving it from
new to cur.
* libproto/maildir/mbox.c (maildir_scan_unlocked): Assign next
UID to the message before moving it from new to cur.
* libproto/maildir/tests/new.at: New test.
* libproto/maildir/tests/Makefile.am: Add nre test.
* libproto/maildir/tests/testsuite.at: Likewise.
2020-11-17 Sergey Poznyakoff <gray@gnu.org>
maildir_fixup: don't bail out if unable to open the mailbox.
2020-11-17 Sergey Poznyakoff <gray@gnu.org>
Fix mda (lmtpd) testsuite: don't assume mbox as the default
format.
2020-11-17 Sergey Poznyakoff <gray@gnu.org>
Minor changes.
* libproto/mh/mbox.c: Include limits.h
* testsuite/mbox2dir.c (next_name_from_file): *scanf %m
modifier isn't common enough yet. Rewrite using fgets +
realloc.
2020-11-17 Sergey Poznyakoff <gray@gnu.org>
New mailutils subcommand: maildir_fixup.
The subcommand converts names in maildirs created by earlier
versions of mailutils to the new format.
* NEWS: Update.
* doc/texinfo/programs/mailutils.texi: Document maildir_fixup
* mu/libexec/Makefile.am: Build maildir_fixup subcommand.
* mu/libexec/maildir_fixup.c: New file.
* mu/libexec/mu.h (common_options): New extern.
* include/mailutils/cli.h (MU_CLI_OPTION_CONF_PROGNAME): New
constant.
* libmailutils/cli/simple.c (MU_CLI_OPTION_PROG_NAME)
(MU_CLI_OPTION_PROG_NAME) (MU_CLI_OPTION_PROG_DOC)
(MU_CLI_OPTION_BUG_ADDRESS) (MU_CLI_OPTION_PACKAGE_URL)
(MU_CLI_OPTION_EXTRA_INFO) (MU_CLI_OPTION_HELP_HOOK)
(MU_CLI_OPTION_VERSION_HOOK) (MU_CLI_OPTION_PROG_DOC_HOOK)
(MU_CLI_OPTION_NEGATION)
(MU_CLI_OPTION_SPECIAL_ARGS): Allow for NULL argument.
(MU_CLI_OPTION_CONF_PROGNAME): New code
2020-11-17 Sergey Poznyakoff <gray@gnu.org>
sortm: reset the uidvalidity of the modified mailbox.
* include/mailutils/mailbox.h (mu_mailbox_uidvalidity_reset):
New proto.
* include/mailutils/sys/mailbox.h (_mu_mailbox): Replace the
_uidvalidity member with two function pointers:
_get_uidvalidity and _set_uidvalidity.
* libmailutils/mailbox/mailbox.c
(mu_mailbox_uidvalidity_reset): New function.
* libmailutils/base/amd.c: Initialize the two methods.
* libproto/dotmail/dotmail.c: Likewise.
* libproto/mbox/mbox.c: Likewise.
* libproto/imap/mbox.c: Initialize the _get_uidvalidity field.
* mh/sortm.c: Reset the uidvalidity on success.
* mh/tests/sortm.at: Check that the uidvalidity changed after
sorting
2020-11-16 Sergey Poznyakoff <gray@gnu.org>
Remove mh and maildir sample mailboxes from the distribution.
Testsuites use mbox2dir to create the requested directory-based
mailbox from the mbox source.
2020-11-16 Sergey Poznyakoff <gray@gnu.org>
Fix message append notifications for maildir, mh, and dotmail.
* testsuite/mbop.c: Implement notification mode.
* comsat/tests/testsuite.at: Fix mh qid.
* libproto/dotmail/dotmail.c (dotmail_append_message): Lock the
monitor before and unlock it after the operation.
* libproto/dotmail/tests/notify.at: New file.
* libproto/dotmail/tests/Makefile.am: Add notify.at
* libproto/dotmail/tests/testsuite.at: Include notify.at.
* include/mailutils/sys/amd.h (cur_msg_file_name): Change
signature.
* libmailutils/base/amd.c: Use amd->cur_msg_file_name with 0 as
its second argument to get qid.
* libproto/maildir/mbox.c (maildir_cur_message_name): Take
three argument, second one specifying whether an absolute or
relative filename is requested. All uses changed.
* libproto/maildir/tests/notify.at: New file.
* libproto/maildir/tests/Makefile.am: Add notify.at
* libproto/maildir/tests/testsuite.at: Include notify.at
* libproto/mh/mbox.c (_mh_cur_message_name): Take three
argument, second one specifying whether an absolute or relative
filename is requested. All uses changed.
* libproto/mh/tests/notify.at: New file.
* libproto/mh/tests/Makefile.am: Add notify.at
* libproto/mh/tests/testsuite.at: Include notify.at
2020-11-16 Sergey Poznyakoff <gray@gnu.org>
Write testsuite for mh mailbox library.
* libmailutils/base/amd.c (amd_get_attr_flags): Scan the
message if AMD does not report MU_AMD_STATUS capability.
* libproto/mh/mbox.c (mh_qfetch): Fix,
* libproto/mh/Makefile.am (SUBDIRS): Add tests.
* libproto/mh/tests/.gitignore: New file.
* libproto/mh/tests/Makefile.am: New file.
* libproto/mh/tests/append.at: New file.
* libproto/mh/tests/atlocal.in: New file.
* libproto/mh/tests/attr.at: New file.
* libproto/mh/tests/autodetect.at: New file.
* libproto/mh/tests/body.at: New file.
* libproto/mh/tests/count.at: New file.
* libproto/mh/tests/delete.at: New file.
* libproto/mh/tests/envelope.at: New file.
* libproto/mh/tests/header.at: New file.
* libproto/mh/tests/qget.at: New file.
* libproto/mh/tests/testsuite.at: New file.
* libproto/mh/tests/uid.at: New file.
* libproto/mh/tests/uidvalidity.at: New file.
2020-11-15 Sergey Poznyakoff <gray@gnu.org>
Encode all Mailutils attributes in maildir file names.
The attributes that have no corresponding info letters are
encoded in the 'a' name attribute as a string of mailutils
status flags, e.g.:
1284628225.M17468P3883Q0.localhost,a=FO,u=1:2,S
Meaning: MU_ATTRIBUTE_READ (from the info letter 'S'),
MU_ATTRIBUTE_FLAGGED (attr. 'F') and MU_ATTRIBUTE_SEEN (attr.
'O').
* libproto/maildir/mbox.c (maildir_message_alloc): Parse the
'a' attribute.
(maildir_subdir_scan): Don't force MU_ATTRIBUTE_SEEN on
existing messages.
(maildir_message_fixup): Fixup the (original) MU_ATTRIBUTE_SEEN
attribute.
* libproto/maildir/tests/attfixup.at: Update.
* libproto/maildir/tests/attr.at: Update.
2020-11-15 Sergey Poznyakoff <gray@gnu.org>
Rename mu_string_to_flags to mu_attribute_string_to_flags.
* include/mailutils/attribute.h (mu_attribute_string_to_flags):
New proto.
(mu_string_to_flags): Mark as deprecated.
(mu_attribute_flags_to_string): New proto.
* libmailutils/mailbox/attribute.c (mu_string_to_flags): Rename
to mu_attribute_string_to_flags.
(mu_attribute_flags_to_string): New function.
* libmailutils/base/amd.c: Use mu_attribute_string_to_flags
instead of mu_string_to_flags.
* libmailutils/mailbox/msgscan.c: Likewise. *
libproto/dotmail/message.c: Likewise.
* libproto/pop/mbox.c: Likewise.
2020-11-15 Sergey Poznyakoff <gray@gnu.org>
Add maildir format detection test.
* libproto/maildir/tests/Makefile.am: Add autodetect.at.
* libproto/maildir/tests/testsuite.at: Include autodetect.at.
* libproto/maildir/tests/autodetect.at: New file.
* testsuite/mbop.c: Fix exit code for --detect.
2020-11-15 Sergey Poznyakoff <gray@gnu.org>
Convert dotmail testsuite to mbop.
* libproto/dotmail/tests/.gitignore: Update.
* libproto/dotmail/tests/Makefile.am: Remove dm_detect, dm_mesg
and dm_qget, build mbop instead.
* testsuite/mbop.c: Implement the detect mode.
* libproto/dotmail/tests/dm_detect.c: Remove.
* libproto/dotmail/tests/dm_mesg.c: Remove.
* libproto/dotmail/tests/dm_qget.c: Remove.
* libproto/dotmail/tests/append.at: Use mbop.
* libproto/dotmail/tests/autodetect.at: Use mbop.
* libproto/dotmail/tests/count.at: Use mbop.
* libproto/dotmail/tests/delete.at: Use mbop.
* libproto/dotmail/tests/qget.at: Use mbop.
* libproto/dotmail/tests/recent.at: Use mbop.
* libproto/dotmail/tests/testsuite.at: Use mbop.
* libproto/dotmail/tests/uidvalidity.at: Use mbop.
* libproto/dotmail/tests/unseen.at: Use mbop.
2020-11-15 Sergey Poznyakoff <gray@gnu.org>
Implement the MU_ATTRIBUTE_FORWARDED attribute flag.
* include/mailutils/attribute.h (MU_ATTRIBUTE_FORWARDED): New
constant. (mu_attribute_is_forwarded,
mu_attribute_set_forwarded)
(mu_attribute_unset_forwarded): New prototypes.
(MU_STATUS_BUF_SIZE): Update definition.
* libmailutils/mailbox/attribute.c (mu_attribute_is_forwarded)
(mu_attribute_set_forwarded)
(mu_attribute_unset_forwarded): New functions.
* libproto/maildir/mbox.c (info_map): Implement the 'P' flag.
2020-11-15 Sergey Poznyakoff <gray@gnu.org>
AMD API: provide function for resetting the uidvalidity value.
* include/mailutils/sys/amd.h (amd_reset_uidvalidity): New
proto.
* libmailutils/base/amd.c (amd_reset_uidvalidity): New
function.
* libproto/maildir/mbox.c (maildir_scan_unlocked): Use
amd_reset_uidvalidity.
2020-11-15 Sergey Poznyakoff <gray@gnu.org>
Improve mbop interface.
* testsuite/mbop.c: Use mu_cli_simple for option handling. Use
the -m option to pass the mailbox file name (or URL). Mark qget
as not requiring message selection.
2020-11-15 Sergey Poznyakoff <gray@gnu.org>
More maildir tests.
* .gitignore: Update.
* include/mailutils/sys/amd.h (MU_AMD_IMAPBASE): Remove.
* libmailutils/base/amd.c (amd_scan_message): Remove obsolete
code.
* libproto/maildir/mbox.c (maildir_message_cmp): Bugfixes.
* testsuite/Makefile.am: Add mbop.c to distribution.
* testsuite/mbop.c: Implement qget.
* testsuite/mbox2dir.c (maildir_generate_name): Fix typo.
(main): Skip From_ line before copying.
* libmailutils/tests/Makefile.am (wsp_SOURCES): Remove.
* libproto/maildir/tests/Makefile.am: Add new tests.
* libproto/maildir/tests/append.at: New file.
* libproto/maildir/tests/attr.at: New file.
* libproto/maildir/tests/body.at: New file.
* libproto/maildir/tests/count.at: Update.
* libproto/maildir/tests/delete.at: New file.
* libproto/maildir/tests/envelope.at: New file.
* libproto/maildir/tests/header.at: New file.
* libproto/maildir/tests/qget.at: New file.
* libproto/maildir/tests/testsuite.at: Include new tests.
* libproto/maildir/tests/uid.at: New file.
* libproto/maildir/tests/uidvalidity.at: New file.
2020-11-14 Sergey Poznyakoff <gray@gnu.org>
Maildir testsuite core.
* libmailutils/tests/tesh.c (mu_tesh_read_and_eval): Print
fixed prompt if attached to a terminal.
* libproto/maildir/Makefile.am (SUBDIRS): Add tests.
* libproto/maildir/mbox.c (flags_to_info): Be sure to format
each flag only once.
(maildir_scan_unlocked): Save updated properties.
* testsuite/.gitignore: Add mbox2dir.
* testsuite/Makefile.am: Build mbox2dir.
* testsuite/mbop.c: New file.
* testsuite/mbox2dir.c: New file.
* libproto/maildir/tests/.gitignore: New file.
* libproto/maildir/tests/Makefile.am: New file.
* libproto/maildir/tests/atlocal.in: New file.
* libproto/maildir/tests/attfixup.at: New file.
* libproto/maildir/tests/count.at: New file.
* libproto/maildir/tests/testsuite.at: New file.
* libproto/maildir/tests/uidfixup.at: New file.
2020-11-12 Sergey Poznyakoff <gray@gnu.org>
Full rewrite of maildir support.
This rewrite aims to speed up maildir manipulations and to fix
the problem with storing the uids and uidvalidity attributes.
Uidvalidity value is stored in the .mu-prop file, as it was
done previously. UID of each message is encoded in its file
name between the unique prefix and the info part. Overall
structure of the message file name is:
uniq [ ',' attrs ] ':2,' info
where uniq is the unique prefix, info is the attribute flags,
and attrs is a comma-delimited list of attribute=value pairs.
The 'u' attribute holds the UID. Unrecognized attributes are
ignored.
To speed up the access and avoid unnecessary memory
allocations, maildir access is reimplemented using the *at()
function calls (openat instead of open, etc).
* libproto/maildir/folder.c: Rewrite.
* libproto/maildir/maildir.h: Rewrite.
* libproto/maildir/mbox.c: Rewrite.
2020-11-12 Sergey Poznyakoff <gray@gnu.org>
dotmail: reset uidvalidity if UIDs are reinitialized.
* libproto/dotmail/dotmail.c (dotmail_rescan_unlocked): Reset
uidvalidity if the UIDs are to be reinitialized.
2020-11-12 Sergey Poznyakoff <gray@gnu.org>
Don't assume any special meaning of the X-Imapbase header in
the library.
This starts a series of commits whose purpose is to clean up
the mess with the uid and uidvalidity attributes.
The way these attributes are stored depends on the mailbox
type. The libmailutils library contained some historical
left-overs that assumed that the X-Imapbase header of the first
message in the mailbox contained the value of the uidvalidity
and next uid. These left-overs are removed.
* include/mailutils/message.h (mu_message_scan): Remove
uidvalidity.
* libmailutils/mailbox/msgscan.c: Remove special handling for
the X-Imapbase header.
* libmailutils/base/amd.c (_amd_message_save)
(amd_scan_message): Remove special handling for X-Imapbase.
2020-11-10 Sergey Poznyakoff <gray@gnu.org>
Fix Savane bug #56428.
* NEWS: Update.
* configure.ac: Version 3.10.90
* include/mailutils/cstr.h (mu_version_string_parse)
(mu_version_string_cmp): New protos.
* libmailutils/string/Makefile.am (libstring_la_SOURCES): Add
version.c.
* libmailutils/string/version.c: New file.
* include/mailutils/sys/amd.h (_amd_message): Remove the
orig_flags member. All uses changed.
(MU_AMD_PROP): New capability.
* include/mailutils/url.h (MU_AUTODETECT_ACCURACY_MAX): New
constant.
* libmailutils/base/amd.c (_amd_prop_create): Raise MU_AMD_PROP
if the prop file exists.
* libmailutils/base/schemeauto.c: New values for the
MU_AUTODETECT_ACCURACY environment variable: default, fast, and
max.
* libmailutils/property/mhprop.c (_mh_prop_fill): Fix
diagnostic message.
* libproto/maildir/mbox.c: Fix incorrect letter to attribute
mapping.
* libproto/mh/mbox.c: Remove uses of orig_flags.
* libmailutils/base/registrar.c (mu_registrar_lookup_url): Fall
back to the default registrar if the url doesn't contain
explicit scheme, the file it references does not exist, and the
default record is a local one.
2020-11-09 Sergey Poznyakoff <gray@gnu.org>
Fix mapping of the \Seen IMAP attribute.
* include/mailutils/attribute.h: Document message attributes.
* libmailutils/imapio/flags.c (_imap4_attrlist): \Seen
corresponds to MU_ATTRIBUTE_READ.
2020-10-01 Sergey Poznyakoff <gray@gnu.org>
Improve message comparison routine for maildir.
* libproto/maildir/mbox.c (maildir_message_cmp): Compare
seconds, microseconds and number of deliveries, in that order.
If all match (shouldn't happen), resort to lexicographical
comparison.
2020-10-01 Sergey Poznyakoff <gray@gnu.org>
Rewrite amd_msg_bsearch without recursion.
2020-10-01 Sergey Poznyakoff <gray@gnu.org>
Bugfix.
* libmailutils/base/amd.c (amd_msg_lookup): Always store the
index of the memory slot, as described in the comment. This was
broken in 1274d937 in a fit of overcorrectness.
2020-09-28 Sergey Poznyakoff <gray@gnu.org>
Fix last resort return for message_envelope_sender.
* libmailutils/mailbox/msgenv.c (message_envelope_sender): Fix
conditional. Use mu_get_user_email instead of tinkering with
mu_auth_data.
* sieve/tests/moderator.at: Fix expected output.
2020-09-13 Sergey Poznyakoff <gray@gnu.org>
Fix uninitialized variable in readmsg.
* readmsg/readmsg.c (main): Initialize weedc.
2020-09-07 Sergey Poznyakoff <gray@gnu.org>
Include libtests/mbdel.at to the dist.
2020-09-06 Sergey Poznyakoff <gray@gnu.org>
Honor idle timeout settings in inetd mode.
* imap4d/imap4d.c (main): For inetd mode, initialize
idle_timeout from the server settings.
* pop3d/pop3d.c: Likewise.
2020-09-05 Sergey Poznyakoff <gray@gnu.org>
Fix parsing of IMAP ranges with the lower value less than the
actual message set minimum.
* libmailutils/msgset/parse.c (get_msgnum): Make sure the
returned is in the [minval,maxval] interval.
2020-08-19 Sergey Poznyakoff <gray@gnu.org>
libmailutils/tests: Use MU_CHECK for simple tests.
* testsuite/testsuite.inc (MU_CHECK): Remove superfluous
quoting.
* libmailutils/tests/modmesg.at: New file.
* libmailutils/tests/streams.at: New file.
* libmailutils/tests/strin.at: Minor change.
* libmailutils/tests/modmesg02.at: Remove.
* libmailutils/tests/streamshift.at: Remove.
* libmailutils/tests/strtoc.at: Remove.
* libmailutils/tests/t0-stream.at: Remove.
* libmailutils/tests/t1-stream.at: Remove.
* libmailutils/tests/getdelim.at: Remove.
* libmailutils/tests/modmesg00.at: Remove.
* libmailutils/tests/modmesg01.at: Remove.
* libmailutils/tests/modmesg03.at: Remove.
* libmailutils/tests/testsuite.at: Update.
* libmailutils/tests/Makefile.am: Update.
2020-08-18 Sergey Poznyakoff <gray@gnu.org>
libmailutils/tests tools: use mu_cli_simple for option
handling.
2020-08-17 Sergey Poznyakoff <gray@gnu.org>
Bugfix (complements fd9a86d37b)
* mda/lib/mailquota.c (sql_retrieve_quota): Fix a leftover use
of get_size.
2020-08-14 Sergey Poznyakoff <gray@gnu.org>
Version 3.10.
* NEWS: Update.
* configure.ac: Raise version number and VI_CURRENT.
2020-08-14 Sergey Poznyakoff <gray@gnu.org>
Reorganize testsuite.
The testsuite directory contains only data and programs that
are used by other tests in the mailutils hierarchy. As such, it
is moved to the top of the SUBDIRS list, so that the utilities
on which another tests depend are tested first.
The tests that depend on both libmailutils and libraries from
libproto are moved to a separate directory libtests. These
tests are run after tests in testsuite, libmailutils and
libproto.
* Makefile.am (SUBDIR): Move the testsuite directory before
libmailutils.
* configure.ac (libtests): New test directory.
* libtests/.gitignore: New file.
* libtests/Makefile.am: New file.
* libtests/atlocal.in: New file.
* testsuite/fldel.at: Move to libtests/
* testsuite/fldel.c: Likewise.
* testsuite/lstuid.c: Likewise.
* testsuite/lstuid00.at: Likewise.
* testsuite/lstuid01.at: Likewise.
* testsuite/lstuid02.at: Likewise.
* testsuite/mbdel.at: Likewise.
* testsuite/mbdel.c: Likewise.
* testsuite/mime.at: Likewise.
* testsuite/mime01.at: Likewise.
* testsuite/mimetest.c: Likewise.
* libtests/testsuite.at: New file.
* testsuite/Makefile.am: Remove all files that depend on
mailutils components.
* testsuite/testsuite.at: Likewise.
* testsuite/bs.c: Remove.
* testsuite/msgset.c: Remove.
2020-08-14 Sergey Poznyakoff <gray@gnu.org>
Fix race condition in mockmta.
* testsuite/mockmta.c (mta_open): Call to listen before
printing the port number. This ensures that the client will
find port listening to its requests.
2020-08-14 Sergey Poznyakoff <gray@gnu.org>
Bugfixes.
* libmailutils/stream/mapfile_stream.c (_mapfile_open): For
MU_STREAM_WRITE set open flags to O_RDWR. This is required for
the remapping code to work. Without it mmap with MAP_SHARED
falls with EACCESS.
* libmailutils/stream/stream.c (mu_stream_close): Improve error
checking.
2020-08-11 Sergey Poznyakoff <gray@gnu.org>
decodemail: use append mode to reduce memory requirements.
* decodemail/decodemail.c (main): Open output mailbox in append
mode. If truncate is requested, open it rw for truncating, then
close and reopen for appending. This speeds up operation
considerably.
* libproto/mbox/mbox.c (mbox_open): Change rules for selecting
mmap vs file open.
(mbox_close): Destroy the stream.
(append_message_to_stream): Minor fix.
(mbox_append_message): Unlock the stream on failure as well as
on success.
2020-08-11 Sergey Poznyakoff <gray@gnu.org>
Allow the caller to unref messages obtained from the mailbox.
* include/mailutils/sys/message.h (struct _mu_message): New
member: _detach.
* libmailutils/mailbox/msgref.c (_mu_message_free): Detach
message from the owning object.
* libmailutils/base/amd.c (_amd_attach_message): Provide the
_detach method.
* libproto/dotmail/message.c (mu_dotmail_message_get):
Initialize the _detach member.
* libproto/imap/mbox.c (_imap_mbx_get_message): Likewise.
* libproto/mbox/mbox.c (new_message): Likewise.
* libproto/pop/mbox.c (pop_create_message): Likewise.
* libmailutils/stream/temp_stream.c (temp_stream_write):
Tempfile stream is created fully buffered. Free the buffer
before reinitializing.
* lib/mdecode.c (message_body_stream): Change error message for
MU_ERR_NOENT.
* decodemail/decodemail.c (main): Unref the original message to
decrease memory usage.
2020-08-10 Sergey Poznyakoff <gray@gnu.org>
Use mu_temp_stream_create instead of mu_temp_file_stream_create
everywhere.
2020-08-10 Sergey Poznyakoff <gray@gnu.org>
Fix compilation without TLS.
* testsuite/mockmta.c: Fix preprocessor conditionals regarding
TLS.
2020-08-09 Sergey Poznyakoff <gray@gnu.org>
Implement temporary streams.
A temporary stream functions as a memory stream until its size
reaches a preconfigured threshold value. Once it is reached,
the stream storage is automatically converted to a temporary
file, and all data written so far are transferred to the new
storage. If the temporary file cannot be created, the stream
continues to operate in memory-based mode.
This stream type is intended to decrease the number of used
file descriptors.
* include/mailutils/sys/Makefile.am: Add temp_stream.h
* include/mailutils/sys/temp_stream.h: New file.
* include/mailutils/stream.h (mu_temp_file_threshold_size): New
extern.
(mu_temp_stream_create): New proto.
* libmailutils/stream/Makefile.am: Add temp_stream.c.
* libmailutils/stream/temp_stream.c: New file.
* libmailutils/string/Makefile.am: Add strtosize.c
* libmailutils/tests/.gitignore: Update.
* libmailutils/tests/Makefile.am
* libmailutils/tests/strtoc.c: Add tests for mu_c_hsize.
* libmailutils/tests/temp_stream.c: New test program.
* libmailutils/tests/testsuite.at: Test the temp_stream
functionality.
* testsuite/testsuite.inc (MU_CHECK): New macro.
* libmailutils/mailbox/body.c (body_get_transport): Use
mu_temp_stream_create.
2020-08-08 Sergey Poznyakoff <gray@gnu.org>
New function: mu_strtosize.
* include/mailutils/cstr.h (mu_strtosize): New proto.
* libmailutils/string/strtosize.c: New file.
* libmailutils/string/Makefile.am: Add strtosize.c
* libmailutils/string/str_to_c.c: Implement conversions for
mu_c_hsize.
* include/mailutils/util.h (mu_c_hsize): New mu_c_type,
* libmailutils/tests/strtoc.c: Add tests for mu_c_hsize.
* libmu_auth/ldap.c: Use mu_strtosize to parse quota.
* mda/lib/mailquota.c: Likewise.
2020-08-08 Sergey Poznyakoff <gray@gnu.org>
Bugfix in MIME parser.
* libmailutils/mime/mime.c: Rewrite boundary matcher as a
separate function.
2020-08-08 Sergey Poznyakoff <gray@gnu.org>
Fix referencing uninitialized value.
* decodemail/decodemail.c (message_decode_mime): Don't
dereference newmsg prior to creating it.
2020-08-07 Sergey Poznyakoff <gray@gnu.org>
stream API: remove the readdelim method.
The method is superfluous as the API itself provides the
necessary functionality. Besides, it interacted poorly with
positioning in buffered streams.
* include/mailutils/sys/stream.h (struct _mu_stream): Remove
the readdelim method.
* libmailutils/stream/stream.c (mu_stream_readdelim)
(mu_stream_getdelim): Remove uses of the readdelim method.
* libmailutils/tests/.gitignore: Update.
* libmailutils/tests/Makefile.am: Add new test.
* libmailutils/tests/testsuite.at: Likewise.
* libmailutils/tests/getdelim.at: New test.
* libmailutils/tests/stream-getdelim.c: New test program.
* libmailutils/base/amd.c: Remove readdelim implementation.
* libmailutils/mailbox/msgstream.c: Likewise.
* libmailutils/stream/iostream.c: Likewise.
* libmailutils/stream/streamref.c: Likewise.
* libmailutils/stream/xscript-stream.c: Likewise.
* libproto/pop/pop3_stream.c: Likewise.
* mail/decode.c (mime_descend): Handle errors from
mu_message_unencapsulate graciously. On failure, treat
message/rfc822 as text/plain.
2020-08-07 Sergey Poznyakoff <gray@gnu.org>
decodemail: if run out of fds report the number of fds needed.
* decodemail/decodemail.c: Special handling for EMFILE.
2020-08-07 Sergey Poznyakoff <gray@gnu.org>
Bugfixes.
* libmailutils/stream/temp_file_stream.c
(mu_temp_file_stream_create): Fix return value.
* decodemail/decodemail.c (message_decode): Split to two
subfunctions to improve error recovery.
* include/mailutils/sys/body.h: Fix typo.
2020-08-06 Sergey Poznyakoff <gray@gnu.org>
decodemail: make sure each message has the final newline on its
own.
* include/mailutils/stream.h (mu_stream_copy_wcb)
(mu_stream_copy_nl): New protos.
* libmailutils/stream/streamcpy.c (mu_stream_copy_wcb)
(mu_stream_copy_nl): New functions.
* libproto/mbox/mbox.c (append_message_to_stream): Use
mu_stream_copy_nl.
* decodemail/decodemail.c (hdr_print, body_print): Remove.
(message_store_stdout): Use message stream instead of piping
header and body separately. Use mu_stream_copy_nl to ensure the
message has a final newline.
2020-08-06 Sergey Poznyakoff <gray@gnu.org>
Fix in scm testsuite.
* libmu_scm/tests/message-get-envelope-date.at: Expected time
zone is UTC (compensates for the change introduced in
50d7ea1d1b).
2020-08-05 Sergey Poznyakoff <gray@gnu.org>
logstream: introduce optional prefix.
The prefix, if set, is output at the beginning of each line,
after the location and before the severity. It can be used to
provide additional information about the diagnostics, such as,
e.g. the number or UID of the message.
The decodemail utility makes use of the new feature.
* include/mailutils/log.h (MU_LOGMODE_PREFIX): New define.
* include/mailutils/stream.h
(MU_IOCTL_LOGSTREAM_SET_LOCUS_RANGE)
(MU_IOCTL_LOGSTREAM_SET_PREFIX): New defines.
* include/mailutils/sys/logstream.h (_mu_log_stream): New
member: prefix.
* libmailutils/stream/logstream.c (_log_write): Output the
prefix.
(_log_done): Dereference the prefix.
(_log_ctl): Handle MU_IOCTL_LOGSTREAM_SET_LOCUS_RANGE and
MU_IOCTL_LOGSTREAM_SET_PREFIX.
* libmailutils/tests/logstr.c: New test: prefix.
* libmailutils/tests/logstr.at: Test log prefix functionality.
* decodemail/decodemail.c: Remove crd_error. Use logstream
prefix to display message part locations.
2020-08-05 Sergey Poznyakoff <gray@gnu.org>
Add two manpages.
2020-08-05 Sergey Poznyakoff <gray@gnu.org>
Assorted fixes.
* libmailutils/mailbox/body.c (mu_body_size): Don't unref the
transport stream. This fixes a bug introduced in 45d54031f4.
* decodemail/decodemail.c (message_decode): Additional
error-checking.
* libmailutils/cfg/parser.y (split_cfg_path): Free the
mu_wordsplit object on error.
* libmu_sieve/extensions/spamd.c (spamd_read_line): Fix the
argument to free.
* doc/texinfo/programs/decodemail.texi: Remove a techically
incorrect passage.
* examples/sa.c: Initialize the urlstr variable.
* libmailutils/base/amd.c (amd_msg_lookup): Store the value in
*pret only if returning success.
(amd_body_stream_seek): Check the return value from
amd_body_size.
* libmailutils/base/permstr.c (mu_readlink): Fix the
uninitialized variable.
* libmailutils/base/symlink.c (mu_readlink) Store the value in
*plen only on success.
2020-08-03 Sergey Poznyakoff <gray@gnu.org>
Housekeeping.
2020-08-02 Sergey Poznyakoff <gray@gnu.org>
Provide fallback methods for restoring the envelope date.
* libmailutils/mailbox/msgenv.c (message_envelope_date): Try
Received, X-Envelope-Date, and Date headers, in that order.
* libmailutils/datetime/scantime.c (mu_scan_datetime): Timezone
defaults to UTC.
2020-08-01 Sergey Poznyakoff <gray@gnu.org>
New function to reconstruct message envelope from the headers.
* include/mailutils/sys/message_stream.h (_mu_message_stream):
Reorganize structure.
* libmailutils/base/amd.c: Use mu_message_reconstruct_envelope
instead of the amd-specific envelope functions.
* libmailutils/stream/message_stream.c: Likewise.
* libmailutils/tests/readmesg.at: New test case.
* libmailutils/tests/readmesg.c: New test program.
* libmailutils/tests/Makefile.am: Add new tests.
* libmailutils/tests/testsuite.at: Likewise.
* mh/tests/mhl.at: Update expected output.
* mh/tests/mhn.at: Likewise.
* testsuite/mh/mbox1/: Fix timestamps in X-Envelope-Date
* testsuite/mh/teaparty/: Likewise.
2020-08-01 Sergey Poznyakoff <gray@gnu.org>
New function for reconstructing the message envelope from its
headers.
* libmailutils/address/parse822.c (mu_parse822_route_addr):
Accept <local-part-only> if the default domain is set.
* include/mailutils/message.h
(mu_message_reconstruct_envelope): New prototype.
* libmailutils/mailbox/msgenv.c (message_envelope_sender): Try
each candidate header in turn until a valid email is extracted
or run out of headers. In the latter case, use the current user
login name as the email.
(mu_message_reconstruct_envelope): New function.
* libmailutils/tests/Makefile.am: Add new test.
* libmailutils/tests/testsuite.at: Likewise.
* libmailutils/tests/recenv.c: Test program for the
mu_message_reconstruct_envelope function
* libmailutils/tests/recenv.at: New test.
2020-08-01 Sergey Poznyakoff <gray@gnu.org>
MIME-related fices in decodemail.
* decodemail/decodemail.c (message_decode): Initialize ismime
to 0.
* libmailutils/mime/mimehdr.c (parse_param): Silently ignore
duplicated parameters.
2020-07-31 Sergey Poznyakoff <gray@gnu.org>
decodemail: Fix storing the envelope.
Copying the envelope was broken in f111a7ad. This fixes it and
improves the diagnostics in message_store_mbox.
* decodemail/decodemail.c (message_store_mbox)
(message_store_stdout): Take mu_coord_t as 3rd argument.
Improve diagnostics.
(message_store_mbox): Don't exit on address family errors.
(message_decode): Decrement dim.
2020-07-30 Sergey Poznyakoff <gray@gnu.org>
Bugfixes.
* libmailutils/base/ctparse.c (content_type_parse): Initialize
rc.
* decodemail/decodemail.c (message_decode): Use the
MU_CONTENT_TYPE_PARAM flag.
* lib/mdecode.c: Likewise.
2020-07-29 Sergey Poznyakoff <gray@gnu.org>
Bugfix.
* mda/lib/script.c: Restore the message-id-header configuration
statement.
2020-07-29 Sergey Poznyakoff <gray@gnu.org>
Relax syntax rules for parsing Content-Type headers.
* decodemail/decodemail.c (qstring_format): Account for s==NULL
(message_decode): Use MU_CONTENT_TYPE_RELAXED when parsing
content types.
* doc/texinfo/programs/decodemail.texi: Document handling of
partial content types.
* include/mailutils/util.h (MU_CONTENT_TYPE_STRICT)
(MU_CONTENT_TYPE_RELAXED)
(MU_CONTENT_TYPE_PARAM): New constants.
(mu_content_type_parse_ext): New function.
* lib/mdecode.c (text_mime_cmp): Implement comparison of
partial content types (missing subtype).
(message_body_stream): Use MU_CONTENT_TYPE_RELAXED.
* libmailutils/base/ctparse.c (content_type_parse): Take
additional argument (flags). Modify parsing algorithm depending
on its value.
(mu_content_type_parse_ext): New function.
(mu_content_type_parse): Rewrite as a wrapper over
mu_content_type_parse_ext.
(mu_content_type_destroy): Account for subtype==NULL.
2020-07-27 Sergey Poznyakoff <gray@gnu.org>
decodemail: quote personal part of an address header only if
necessary.
* decodemail/decodemail.c (is_address_header): Add "From:".
(qstring_format): Format as a quoted string only if really
necessary.
(message_decode): Fix improper use of address_decode.
2020-07-27 Sergey Poznyakoff <gray@gnu.org>
Bugfix.
* imap4d/namespace.c (prefix_translate_name): The name "INBOX"
is special only without prefix.
2020-07-25 Sergey Poznyakoff <gray@gnu.org>
decodemail: double-quote decoded personal parts of email
addresses.
* decodemail/decodemail.c: Take care to double-quote decoded
personal parts of email addresses.
* libmailutils/address/parse822.c (mu_parse822_quoted_string):
Don't skip 8-bit characters.
2020-07-25 Sergey Poznyakoff <gray@gnu.org>
Improve error tolerance when parsing MIME structured headers.
* include/mailutils/assoc.h (mu_assoc_set_mark)
(mu_assoc_head_set_mark, mu_assoc_tail_set_mark) (mu_assoc_pop,
mu_assoc_shift)
(mu_assoc_sweep_unset, mu_assoc_pull): New protos.
* libmailutils/base/assoc.c: New functions (see above).
* libmailutils/mime/mimehdr.c (parse_param): Mark last
installed element for sweeping. When seeing a semicolon, unmark
it. Return MU_ERR_PARSE on errors. On success, install the
created parameter in the assoc array.
(_mime_header_parse): Change type of the subset parameter.
Attempt error recovery on parse errors. If it succeeds, sweep
out the last installed parameter. If subset is specified, use
mu_assoc_pull to populate it from the created assoc.
(mu_mime_header_parse_subset)
(mu_mime_param_assoc_create): Update invocations of
_mime_header_parse.
* libmailutils/tests/mimehdr.at: Test error tolerance.
* libmailutils/tests/mimehdr.c: Use mu_cli_simple to parse
command line. Treat positional arguments as names of the
parameters to retain on output.
2020-07-24 Sergey Poznyakoff <gray@gnu.org>
decodemail: print error location (message.part) with
diagnostics.
* decodemail/decodemail.c (message_decode): Take three
arguments: the message(part), its location as a pointer to
mu_coord_t object and dimension, meaning number of slots used
in the latter. Use crd_error for diagnostics.
(crd_error): New function. Display error message prefixed with
the location of the message part it belongs to.
* libmailutils/base/coord.c (mu_coord_realloc): Update the
stored dimension.
2020-07-23 Sergey Poznyakoff <gray@gnu.org>
* decodemail/decodemail.c (message_decode): Don't stop on copy
errors. Instead, issue an error message and mark the part in
the output message where copying failed with an explicit error
statement.
2020-07-23 Sergey Poznyakoff <gray@gnu.org>
Minor fixes in base64 and inline-comment filters.
* libmailutils/diag/errors (MU_ERR_BASE64): New error code.
* libmailutils/filter/base64.c (_base64_decoder): Stop decoding
and return failure if padding length gets greater than 3
* libmailutils/filter/inline-comment.c (_ilcmt_decoder): Make
sure proper error code is set.
2020-07-23 Sergey Poznyakoff <gray@gnu.org>
decodemail: better error tolerance.
* decodemail/decodemail.c (message_decode): Don't bail out if
unable to get the Content-Type header or copy the message
envelope.
2020-07-23 Sergey Poznyakoff <gray@gnu.org>
Relax sytnax requirements for MIME structured headers.
* libmailutils/base/ctparse.c (content_type_parse): Rewrite the
value splitting on type and subtype. Allow for optional
whitespace at both sides of "/". Both type and subtype can
contain arbitrary characters (except for "/"). This is not
right according to RFC 2045, but reportedly such cases exist in
old mails.
* libmailutils/mailbox/bodystruct.c (bodystructure_fill): Fix
parsing of the Content-Type header. Fix storing the pointer to
an automatic variable in assoc object. Unfold the
Content-Disposition value.
* libmailutils/mime/mimehdr.c (_mime_header_parse): Return in
pvalue entire prefix part up to the first semicolon, with
leading and trailing whitespace removed. Allow for both output
parameters to be NULL.
* libmailutils/tests/content-type.at: Add new test case.
* libmailutils/tests/conttype.c: ignore empty lines in input.
* libmailutils/tests/mimehdr.at: Change mimehdr16 and mimehdr17
tests: this syntax is accepted by the relaxed rules of the
modified parser.
2020-07-23 Sergey Poznyakoff <gray@gnu.org>
Fixes in MIME structured header parser.
* libmailutils/mime/mimehdr.c (parse_param): Allow for
whitespace surrounding =.
* libmailutils/tests/mimehdr.at: More tests
2020-07-23 Sergey Poznyakoff <gray@gnu.org>
Add missing file.
* libmailutils/tests/listsort.c: New file.
2020-07-22 Sergey Poznyakoff <gray@gnu.org>
Fix list sort.
* include/mailutils/sys/list.h (_mu_list_null)
(_mu_list_init): New functions.
* libmailutils/list/sort.c (_list_qsort): Fix pivot selection
and list merging.
* libmailutils/tests/.gitignore: Add listsort.
* libmailutils/tests/Makefile.am: Likewise.
* libmailutils/tests/list.at: Check sorting large lists.
2020-07-22 Sergey Poznyakoff <gray@gnu.org>
Stricter parsing of structured MIME headers.
The mu_content_type_parse function allowed for missing
/subtype, which caused grief in case of blatantly invalid
inputs.
* decodemail/decodemail.c (message_decode): Handle
mu_content_type_parse failures racefully: return a reference to
the input message. Improve diagnostics.
* lib/mdecode.c (message_body_stream): Improve diagnostics.
* libmailutils/base/assoc.c (merge_sort): Bugfix: accept empty
input list.
* libmailutils/base/ctparse.c (content_type_parse): Require
that both type and subtype be present.
* libmailutils/mime/mimehdr.c (_mime_header_parse): Move
parameter parsing to a separate function. Do better syntax
checking.
* libmailutils/tests/Makefile.am: Add new tests.
* libmailutils/tests/testsuite.at: Likewise.
* libmailutils/tests/content-type.at: New tests.
* libmailutils/tests/conttype.c: Return 1 if at least one parse
fails.
* libmailutils/tests/mimehdr.at: Add tests for invalid inputs.
* libmailutils/tests/mimehdr.c: Better diagnostics.
2020-07-21 Sergey Poznyakoff <gray@gnu.org>
decodemail: always copy the envelope.
* decodemail/decodemail.c (message_decode): When processing the
top-level message, always copy the original envelope to it.
2020-07-20 Sergey Poznyakoff <gray@gnu.org>
New simplified interface to command line option parser.
* include/mailutils/cli.h (MU_CLI_OPTION_): New constants.
(mu_cli_simple): New proto.
* libmailutils/cli/simple.c: New file.
* libmailutils/cli/Makefile.am: Add new source.
* libmailutils/cli/cli.c (mu_cli_ext): Take into account
po_special_flags in hints. Honor MU_PARSEOPT_HELP_HOOK and
MU_PARSEOPT_EXIT_ERROR set in hints.
* libmailutils/opt/opt.c (parseopt_init): Fix improper use of
MU_PARSEOPT_PACKAGE_URL instead of MU_PARSEOPT_DATA.
2020-07-20 Sergey Poznyakoff <gray@gnu.org>
Fix memory leak in property code.
The property API contains a serious flaw that leads to memory
leaks. The property initialization function (set by
mu_property_set_init or similiar functions) is supposed to
initialize the supported methods in mu_property_t, in
particular _prop_done, which is responsible for releasing the
resources allocated for the initdata object upon invocation of
mu_property_destroy.
However, the initialization function gets called only upon a
read/write manipulation on the property. This means that unless
at least one such operation is performed the _prop_done method
will not be initialized and the resources (if any) allocated
for the initial data object will never be released. This is
true, in particular for the MH properties and assoc properties
with I/O stream.
Until the API is revamped, the following solution is
implemented. The function mu_property_create_init calls the
mu_property_init function if called with a non-NULL third
argument (initdata). This ensures that it will be properly
freed upon destroying the object.
The use of low-level functions mu_property_set_init and
mu_property_set_init_data requires the caller to call
mu_property_init explicitly, if needed.
* include/mailutils/property.h (mu_property_init): New proto.
* libmailutils/property/create.c (_mu_property_init): Rename to
mu_property_init.
(mu_property_create_init): Call mu_property_init if initdata is
not NULL.
* libmailutils/property/propinv.c: Update call to
mu_property_init.
2020-07-20 Sergey Poznyakoff <gray@gnu.org>
Provide tests for auxiliary test utilities.
* configure.ac: Initialize testsuite in libproto/mbox
* libproto/mbox/Makefile.am (SUBDIRS): Declare.
* libproto/mbox/tests/Makefile.am: New file.
* libproto/mbox/tests/atlocal.in: New file.
* libproto/mbox/tests/testsuite.at: New file.
* testsuite/ufms.at: Rename to libproto/mbox/tests/ufms.at
* testsuite/ufms.c: Rename to libproto/mbox/tests/ufms.c
* testsuite/.gitignore: Update.
* testsuite/mockmail.at: New file.
* testsuite/mockmail.c (main): Fix the state machine.
* testsuite/mockmta.at: New file.
* testsuite/mockmta.c: Fix typo in the comment.
* testsuite/testsuite.at: Add new tests
* testsuite/Makefile.am: Add new tests
2020-07-19 Sergey Poznyakoff <gray@gnu.org>
Minor changes.
* testsuite/Makefile.am (cwdrepl_LDADD): Remove mailutils
dependencies
* testsuite/cwdrepl.c: Replace with a mu-independent version
from wydawca. (http://git.gnu.org.ua/cgit/wydawca.git)
* testsuite/mockmail.c: Fix indentation
* mh/tests/comp.at: Remove trailing whitespace from the output.
* mh/tests/forw.at: Likewise.
* mh/tests/repl.at: Likewise.
2020-07-17 Sergey Poznyakoff <gray@gnu.org>
New test tool: mockmail.
* testsuite/mockmail.c: New auxiliary tool.
* testsuite/.gitignore: Add mockmail.
* testsuite/Makefile.am: Build mockmail.
* testsuite/mockmta.c: Change docs.
* mail/testsuite/mail/send.exp: Use testsuite/mockmail to
emulate Sendmail.
* mda/mda/tests/forward.at: Likewise.
* mh/tests/send.at: Likewise.
* mh/tests/testsuite.at: Likewise.
* sieve/tests/moderator.at: Likewise.
* sieve/tests/redirect.at: Likewise.
* sieve/tests/reject.at: Likewise.
* sieve/tests/testsuite.at: Likewise.
* sieve/tests/vacation.at: Likewise.
2020-07-17 Sergey Poznyakoff <gray@gnu.org>
Rewrite test suite for smtp mailer.
* libproto/mailer/smtp.c: Fix mailer initialization (bug
introduced in a0f754eb81). Initialization based on mailer URL
cannot be run from _mailer_smtp_init, since at that stage URL
is not yet known. Move it to smtp_open and make sure it is run
only once.
* am/tls.m4: Make TLS_LIBS a subst variable.
* testsuite/mockmta.c: New test tool.
* testsuite/.gitignore: Update.
* testsuite/Makefile.am: Update.
* libproto/mailer/tests/.gitignore: Update.
* libproto/mailer/tests/Makefile.am: Add new tests.
* libproto/mailer/tests/testsuite.at: Include new tests.
* libproto/mailer/tests/seqsend.at: New test case.
* libproto/mailer/tests/smtp-msg.at: New test case. Moved from
testsuite/smtp-msg.at. Uses mockmta.
* libproto/mailer/tests/smtp-str.at: New test case. Moved from
testsuite/smtp-str.at. Uses mockmta.
* libproto/mailer/tests/smtpsend.c: New program. Moved from
testsuite/smtpsend.c.
2020-07-15 Sergey Poznyakoff <gray@gnu.org>
Test multiple transmissions over a single SMTP mailer.
* configure.ac: Configure testsuite in libproto/mailer/tests.
* examples/mta.c: New option -c (continuous reception).
(mta_smtp): Continue accepting connections if -c is given.
* libproto/mailer/Makefile.am: Add tests.
* libproto/mailer/tests/.gitignore: New file.
* libproto/mailer/tests/Makefile.am: New file.
* libproto/mailer/tests/atlocal.in: New file.
* libproto/mailer/tests/sendm.c: New file.
* libproto/mailer/tests/sends.c: New file.
* libproto/mailer/tests/seqsend.at: New file.
* libproto/mailer/tests/testsuite.at: New file.
2020-07-15 Sergey Poznyakoff <gray@gnu.org>
smtp mailer: fix multiple open/close on the same mailer.
This fixes the operation of the smtp(s) mailer in the following
context
while (cond)
{
mu_mailer_open (mailer, ...);
mu_mailer_send_message (mailer, msg, ...);
mu_mailer_close (mailer);
}
* include/mailutils/mailer.h (mu_mailer_get_streamref)
(mu_mailer_set_stream): Remove.
* include/mailutils/sys/mailer.h (struct _mu_mailer): Remove
stream.
* libmailutils/mailer/mailer.c (mu_mailer_create): Don't
reference stream.
(mu_mailer_set_stream,mu_mailer_get_streamref): Remove.
* libproto/mailer/smtp.c (struct _smtp_mailer): New members:
tls and auth.
(smtp_open): Open the stream and assign it.
(_mailer_smtp_init): Create the struct _smtp_mailer object and
save it in the mailer.
(smtp_close): Close and destroy the carrier.
* libproto/mailer/smtp_carrier.c (mu_smtp_set_carrier): Accept
NULL as the carrier argument.
2020-07-15 Sergey Poznyakoff <gray@gnu.org>
Fix memory leaks.
* libmailutils/sockaddr/free.c (mu_sockaddr_free): Free the
address itself.
* libmailutils/stream/message_stream.c
(mu_message_from_stream_with_envelope): Envelope must be owned
by the message. Change mu_envelope_create accordingly.
(_env_msg_date, _env_msg_sender): Likewise.
* libmailutils/url/destroy.c: Free url->portstr.
2020-07-15 Sergey Poznyakoff <gray@gnu.org>
Update decodemail.texi.
Improved version from Karl Berry.
2020-07-14 Sergey Poznyakoff <gray@gnu.org>
Document the decodemail tool.
* THANKS: Add Karl Berry
* doc/texinfo/programs/decodemail.texi: New file.
* doc/texinfo/Makefile.am (programs_TEXINFOS): Add new file.
* doc/texinfo/mailutils.texi: Document the decodemail tool.
* doc/texinfo/programs.texi: Document the mime configuration
statement.
* doc/texinfo/programs/readmsg.texi: Document new options.
2020-07-09 Sergey Poznyakoff <gray@gnu.org>
Fix https://savannah.gnu.org/bugs/index.php?57787.
2020-07-09 Sergey Poznyakoff <gray@gnu.org>
Fix memory leaks.
* libmailutils/diag/debug.c (mu_debug_log): Free buf.
* libmailutils/mailer/progmailer.c (mu_progmailer_send): Call
mu_stream_destroy (fix copy-paste error).
* libmailutils/string/expvar.c (mu_str_expand): Save word[0],
free the rest.
* mail/mail.c (main): Free the result of mu_argcv_string.
* mail/mail.h (compose_header_get): Return const ptr.
* mail/mailline.c (ml_readline_internal): Free the buffer on
EOF.
* mail/reply.c (reply0): compose_header_get returns const
char*.
* mail/send.c (add_body): Don't increase stream reference count
(follow-up to 45d54031).
(compose_header_get): Return const char* (use
mu_header_sget_value).
(mail_send0): Always free buf.
* mail/source.c (source_readline): Free buf on EOF.
* mail/util.c (util_header_expand): Free mu_wordsplit.
2020-07-07 Sergey Poznyakoff <gray@gnu.org>
Bugfixes.
* libmailutils/stream/stream.c (_stream_read_unbuffered):
Update pnread only on success.
* libmailutils/string/muctype.c: Mark underscore as
MU_CTYPE_HEADR
2020-07-06 Sergey Poznyakoff <gray@gnu.org>
Fix assoc operation in case-insensitive mode.
* libmailutils/base/assoc.c (_mu_assoc): New member: hash.
(mu_assoc_create): Set proper hashing function for
case-insensitive operation.
2020-07-06 Sergey Poznyakoff <gray@gnu.org>
Implement mu_stream_shift function.
* include/mailutils/stream.h (mu_stream_shift): New proto.
* libmailutils/stream/Makefile.am: Add new source.
* libmailutils/stream/streamshift.c: New file.
* libmailutils/tests/.gitignore: Update.
* libmailutils/tests/Makefile.am: Add new tests.
* libmailutils/tests/streamshift.at: New file.
* libmailutils/tests/t-streamshift.c: New file.
* libmailutils/tests/testsuite.at: Include new test.
2020-07-05 Sergey Poznyakoff <gray@gnu.org>
Bugfix.
* libmailutils/imapio/getline.c (mu_imapio_getline): Don't
unquote literals.
2020-06-30 Sergey Poznyakoff <gray@gnu.org>
Fix static builds with libldap.
2020-06-29 Sergey Poznyakoff <gray@gnu.org>
Improve default content types for message_body_stream.
2020-06-27 Sergey Poznyakoff <gray@gnu.org>
sieve: quoted strings may span several lines.
As per RFC 5228, quoted strings may span several lines and are
allowed to contain special characters. Backslash and
double-quotes appearing within a quoted string must be escaped
by a backslash. A backslash followed by any other character is
silently removed.
* libmu_sieve/sieve-lex.l (line_addz, str_unescape): Remove.
Allow for \n in quoted strings. Escape only " and \ with
backslash. Replace unrecognized escapes with the character
after \.
* sieve/examples/exn-5.4.sv: envelope should not be required.
* sieve/tests/compile.at: Add more tests.
2020-06-27 Sergey Poznyakoff <gray@gnu.org>
Replace AM_LEXFLAGS in Makefile.ams with AM_LFLAGS.
2020-06-26 Sergey Poznyakoff <gray@gnu.org>
Minor fix in configure.
* configure.ac (check_bdb): Add library to DBMLIBS when it is
confirmed that the header and library versions match.
2020-06-26 Sergey Poznyakoff <gray@gnu.org>
Use mailutils instead of mailutils-config in AM_GNU_MAILUTILS.
* mu-aux/mailutils.m4: Rewrite using the mailutils tool.
2020-06-26 Sergey Poznyakoff <gray@gnu.org>
Restore mailutils-config (partial revert of e1e7e02cf932)
It was premature to remove that script, since some existing
packages still rely on it.
* mu/mailutils-config: Restore. Put installation directory
before other PATH components, not after them.
2020-06-25 Sergey Poznyakoff <gray@gnu.org>
configure: make sure python-config version matches that of
python.
2020-06-23 Sergey Poznyakoff <gray@gnu.org>
Specify additional content-type parameters when creating
multipart MIME objects.
Preserve original parameters (excepting boundary) when
processing multipart messages by decodemail.
* decodemail/decodemail.c (message_decode): copy parameters
from the original Content-Type.
* include/mailutils/mime.h (mu_mime_create_multipart): Add
third parameter: an assoc table of additional content-type
parameters.
(mu_mime_content_type_param): Rename to
mu_mime_content_type_get_param.
(mu_mime_content_type_set_param): New proto.
* libmailutils/mime/mime.c: See above.
(_mime_set_content_type): Preserve all parameters.
2020-06-22 Sergey Poznyakoff <gray@gnu.org>
decodemain: set 7bit or 8bit transfer encoding on decoded
parts.
* decodemail/decodemail.c (message_decode): Set 8bit or 7bit
transfer encoding, depending on the character of the decoded
stream.
* include/mailutils/cstr.h (mu_mem_8bit_count): New proto.
* include/mailutils/stream.h (MU_STREAM_STAT_IN8BIT)
(MU_STREAM_STAT_OUT8BIT): New constants.
* libmailutils/stream/stream.c (_stream_read,_stream_write):
Set MU_STREAM_STAT_IN8BIT (MU_STREAM_STAT_OUT8BIT) if requested
* libmailutils/string/strcount.c (mu_mem_8bit_count): New
function.
2020-06-22 Sergey Poznyakoff <gray@gnu.org>
Fix default text mime types.
2020-06-21 Sergey Poznyakoff <gray@gnu.org>
Make the list of textual mime types configurable.
* decodemail/decodemail.c: Request the "mime" configuration
capability.
* lib/mdecode.c: Make the list of textual mime types
configurable via the mime.text-type configuration statement.
* lib/muaux.h (mu_cli_capa_mime): New extern.
2020-06-17 Sergey Poznyakoff <gray@gnu.org>
Improve MIME parser and mime object creation. Preserve
original content-type in decodemail.
* decodemail/decodemail.c: Preserve the content subtype of each
message.
* include/mailutils/mime.h (MU_MIME_CONTENT_TYPE_MULTIPART)
(MU_MIME_CONTENT_SUBTYPE_MIXED)
(MU_MIME_CONTENT_SUBTYPE_ALTERNATIVE)
(MU_MIME_CONTENT_SUBTYPE_DIGEST): New defines.
(mu_mime_create_multipart): New proto.
(mu_mime_sget_content_type,mu_mime_aget_content_type)
(mu_mime_sget_content_subtype,mu_mime_aget_content_subtype)
(mu_mime_content_type_param): New protos.
* include/mailutils/sys/mime.h (content_type): Change type.
(boundary): Const now. Points to a string in
content_type->param.
* libmailutils/base/ctparse.c (format_param): Fix quoting.
Insert additonal whitespace after each semicolon.
* libmailutils/mime/mime.c: Use mu_content_type_t to represent
the Content-Type header.
(mu_mime_create_multipart): New function.
(mu_mime_create): Use mu_mime_create_multipart to create new
mime object.
(mu_mime_sget_content_type,mu_mime_aget_content_type)
(mu_mime_sget_content_subtype,mu_mime_aget_content_subtype)
(mu_mime_content_type_param): New functions.
2020-06-16 Sergey Poznyakoff <gray@gnu.org>
Update NEWS.
2020-06-16 Sergey Poznyakoff <gray@gnu.org>
Drop support for Python 2.x.
2020-06-16 Sergey Poznyakoff <gray@gnu.org>
decodemail: don't recode charsets unless explicitly requested.
* decodemail/decodemail.c: New options --charset and --recode
(main): Recode messages only if requested from the command
line. Don't add the Content-Disposition header.
* include/mailutils/util.h (mu_content_type_format): New proto.
* lib/mdecode.c (charset_setup): Return immediately if charset
is NULL.
* libmailutils/base/ctparse.c (mu_content_type_format): New
function.
2020-06-15 Sergey Poznyakoff <gray@gnu.org>
Fix long-standing memory leak in body.c.
* include/mailutils/body.h (mu_body_ref, mu_body_unref): New
functions.
* include/mailutils/sys/body.h (_mu_body): New member
ref_count.
* libmailutils/mailbox/body.c: Keep body and body stream
objects alive for as long as their reference counters are not
zero. Rewrite transport stream code.
* libmailutils/tests/modmesg.c: Use MU_ASSERT.
2020-06-15 Sergey Poznyakoff <gray@gnu.org>
decodemail: copy original message envelope.
2020-06-14 Sergey Poznyakoff <gray@gnu.org>
Add missing files.
2020-06-14 Sergey Poznyakoff <gray@gnu.org>
Move decodemail to a separate directory and make it
installable.
2020-06-14 Sergey Poznyakoff <gray@gnu.org>
Upgrade wordsplit.
2020-06-14 Sergey Poznyakoff <gray@gnu.org>
New utility: decodemail.
* examples/decodemail.c: New source.
* examples/.gitignore: Add decodemail.
* examples/Makefile.am: Build decodemail.
* lib/mdecode.c: New file.
* lib/Makefile.am: Add mdecode.c
* lib/muaux.h (message_body_stream): New proto.
* readmsg/msglist.c (message_body_stream): Move to a separate
source in lib.
2020-06-14 Sergey Poznyakoff <gray@gnu.org>
Rewrite mime message parser.
* include/mailutils/sys/mime.h (MIME_STATE_BEGIN_LINE)
(MIME_PARSER_HAVE_CR): Remove constants.
(struct _mu_mime): Remove cur_buf and buf_size.
* libmailutils/mime/mime.c (_mime_parse_mpart_message): Use
mu_stream_getline instead of the handcrafted dual buffering
scheme.
2020-06-14 Sergey Poznyakoff <gray@gnu.org>
mail: fix message list parser.
* mail/msgset.y: Throw range error only if message number is
greater than the number of available messages.
2020-06-14 Sergey Poznyakoff <gray@gnu.org>
Fix memory leaks.
* libmailutils/base/amd.c (amd_message_stream_close): Use
mu_stream_destroy instead of mu_stream_close.
* libmailutils/base/ctparse.c (content_type_parse): Free value.
* libmailutils/base/tilde.c (mu_tilde_expansion): Free proto.
* libmailutils/cfg/driver.c (mu_config_destroy_container): Free
refcount.
* libmailutils/cfg/parser.y (mu_cfg_tree_postprocess): Destroy
iterator.
(mu_cfg_destroy_tree): Free the tree itself.
* libmailutils/datetime/scantime.c (pop_input): Free the popped
element.
* libmailutils/mailer/mailer.c (send_fragments): Destroy mime
after converting it to message.
* libmailutils/mime/mimehdr.c (_mime_header_parse): Free ws
after errors.
2020-06-06 Sergey Poznyakoff <gray@gnu.org>
Use mu_coord_t in mail.
* include/mailutils/message.h (mu_coord_part_string): New
proto.
* libmailutils/base/coord.c (mu_coord_part_string): New
function.
* mail/mail.h (message_set): Remove npart and msg_part.
Introduce mu_coord_t crd instead. All uses updated.
2020-06-05 Sergey Poznyakoff <gray@gnu.org>
Bugfix.
* libmailutils/base/coord.c (mu_coord_alloc): Return the
allocated memory.
2020-06-04 Sergey Poznyakoff <gray@gnu.org>
Remove placeholder (mapi) and dead (nntp) code.
2020-06-04 Sergey Poznyakoff <gray@gnu.org>
Fix compilation without libunistring.
* lib/unistr_c.c (unistr_is_substring_dn): Add missing function
2020-06-02 Sergey Poznyakoff <gray@gnu.org>
Minor fixes.
2020-06-02 Sergey Poznyakoff <gray@gnu.org.ua>
Bugfix.
* libmailutils/base/coord.c (mu_coord_string): Reverse the
partially built coordinate string.
* mail/msgset.y (msgset_part_str): Likewise.
2020-06-02 Sergey Poznyakoff <gray@gnu.org>
Improve message part iterator and readmsg output.
* include/mailutils/message.h (mu_coord_t): New data type.
(mu_coord_alloc, mu_coord_realloc)
(mu_coord_dup, mu_coord_string): New protos.
(mu_coord_length): New function.
* libmailutils/base/Makefile.am: Add coord.c
* libmailutils/base/coord.c: New file.
* libmailutils/mime/mimeitr.c: Key returned by
mu_iterator_current_kv is allocated in the struct mimeitr.
Caller may not free it.
(struct mimeitr): New member: coord.
(getitem): Reallocate coord.
(mimeitr_free): New function.
(destroy): Use mimeitr_free.
(itrdup): Duplicate coord
(mu_message_get_iterator): Initialize coord.
* libmailutils/tests/mimeitr.c: Use mu_coord_string to print
the part coordinates.
* readmsg/msglist.c (message_body_stream): New argument:
unix_header. Install additional "FROM" encoding filter if it is
set.
(print_header): Special handling for "*" in the weedlist.
(msgpart_str): Remove. Use mu_coord_string instead.
(main): In mime decode mode, if -h (display all headers) is
requested, ignore MIME headers, since after decoding they are
no longer relevant.
2020-06-01 Sergey Poznyakoff <gray@gnu.org>
readmsg: Implement searches in MIME messages. Decode MIME on
output.
* configure.ac: Add UNISTRING_LIBS to MU_APP_LIBRARIES.
* examples/Makefile.am: Link with $MU_APP_LIBRARIES instead of
plain libmuaux.la.
* mh/Makefile.am: Likewise.
* imap4d/Makefile.am: Likewise.
* imap4d/imap4d.h (unistr_downcase)
(unistr_is_substring): Move prototypes to lib/muaux.h
* imap4d/search.c (_scan_header): Use unistr_is_substring_dn
instead of unistr_is_substring.
* include/mailutils/message.h (mu_message_get_iterator): New
prototype.
* lib/Makefile.am: Add unistr_u8.c or unistr_c.c, depending on
MU_COND_UNISTRING.
* lib/muaux.h (unistr_downcase)
(unistr_is_substring,unistr_is_substring_dn): New functions.
* lib/unistr_c.c: New file (moved from /imap4d).
* lib/unistr_u8.c: Likewise.
* libmailutils/mime/Makefile.am: Add mimeitr.c
* libmailutils/mime/mimeitr.c: New file.
* libmailutils/tests/Makefile.am: Add mimeitr.c
* libmailutils/tests/mimeitr.c: New file.
* readmsg/msglist.c: Rewrite search in messages.
* readmsg/readmsg.c: New options --glob, --regex, --ignorecase
control message matching.
* readmsg/readmsg.h (pattern_init,pattern_match)
(pattern_free): New protos.
2020-05-29 Sergey Poznyakoff <gray@gnu.org>
Fix stream buffer parameters on truncate.
* configure.ac: Version 3.9.90
* libmailutils/stream/stream.c (mu_stream_truncate): Update
stream->offset, stream->level, and stream->pos, if needed.
2020-05-29 Sergey Poznyakoff <gray@gnu.org>
mail: write command operates on message parts as well as on
messages.
Messages or message parts are decoded before being written to a
disk file.
* include/mailutils/cstr.h (mu_mem_c_count): New proto.
* include/mailutils/stream.h (MU_STREAM_STAT_INLN)
(MU_STREAM_STAT_OUTLN): New constants.
* libmailutils/stream/stream.c (_stream_stat_incr)
(_stream_seek): Rewrite as inline functions.
(_stream_read, _stream_write): Rewrite as inline functions.
Optionally count number of lines read/written.
* libmailutils/string/strcount.c (mu_mem_c_count): New
function.
* libmailutils/tests/fltst.c: Update.
* mail/decode.c (format_msgset): Remove. Use msgset_str
instead.
(print_message_body): New function.
* mail/mail.h (msgset_part_str)
(util_get_message_part): New protos.
(msgset_str): New function.
* mail/msgset.y: Change the message part syntax. Components are
separated by dots, instead of being enclosed in brackets. Old
syntax is still supported for compatibility.
* mail/struct.c (show_part): Use msgset_str.
* mail/testsuite/mail/read.exp: Fix expected strings.
* mail/util.c (util_get_message_part): New function.
* mail/write.c (mail_write): Write message part if requested.
Decode the body if the Content-Transfer-Encoding header is set.
2020-05-29 Sergey Poznyakoff <gray@gnu.org>
libmailutils: fix error in full and line buffer mode.
* libmailutils/stream/stream.c (_stream_buffer_full_p): Fix
conditions for buffered streams. The buffer is full if current
pointer (not level) equals the size. For line buffering, any
newline appearing in the written portion of the buffer causes
flushing.
(mu_stream_write): Fix the free space calculation.
* libmailutils/tests/t0-stream.at: New file.
* libmailutils/tests/t0-stream.c: New file.
* libmailutils/tests/t1-stream.at: New file.
* libmailutils/tests/t1-stream.c: New file.
* libmailutils/tests/Makefile.am: Add new testcase.
* libmailutils/tests/testsuite.at: Likewise.
2020-05-28 Sergey Poznyakoff <gray@gnu.org>
Amend b8664765e1.
The body_end member holds the offset of the first character
that follows the message body. In a well-formed mailbox, it is
the newline character of a blank line that delimits the
message. However, there are mailboxes that lack this blank
line. In such cases body_end points to the ^F of the next
envelope line.
When saving the mailbox, delimiting blank lines are always
emitted.
* libproto/mbox/mbox.c (mbox_expunge_unlocked): Revert size
calculation. Always emit a blank line after the message.
2020-05-27 Sergey Poznyakoff <gray@gnu.org>
mail: fix INTR handling.
The mail's signal handler is not called when using readline 6.0
or newer. As a result pressing INTR no longer works as
expected. To fix this, this change prevents libreadline from
setting its own signal handlers.
* mail/mailline.c (sig_handler): Call readline-specific signal
handler.
(ml_readline_init): Disable readline signal handling.
2020-04-28 Sergey Poznyakoff <gray@gnu.org>
Bugfix.
* libmailutils/datetime/utcoff.c (mu_utc_offset): Fix a typo.
2020-04-20 Sergey Poznyakoff <gray@gnu.org>
Fix uid->seqno translation.
* libmailutils/msgset/trans.c (_mu_msgset_translate_pair):
Don't exclude end point of the range.
2020-03-31 Sergey Poznyakoff <gray@gnu.org>
mbox: fix a bug in expunge routine.
The bug will manifest itself by removal of the trailing newline
in the last message in a block of unchanged messages when
expunging the mailbox after removal of one or more messages
before that block.
Bug reported by Ken Olum.
* libproto/mbox/mbox.c (mbox_expunge_unlocked): Fix an
off-by-one error in computation of the file chunk size.
2020-03-30 Sergey Poznyakoff <gray@gnu.org>
Fix improper handling of [TRYCREATE] and similar imap
responses.
* libproto/imap/resproc.c (parse_response_code): Fix an
off-by-one index.
2020-03-27 Sergey Poznyakoff <gray@gnu.org>
Minor changes.
* imap4d/io.c (io_setio): Unref subordinate streams.
* pop3d/extra.c: Likewise.
2020-03-22 Jordi Mallach <jordi@debian.org>
Call $PYTHON_CONFIG instead of pyhon-config.
2020-03-22 Sergey Poznyakoff <gray@gnu.org>
imap4d: implement TLS in inetd mode.
This is a follow-up to commit ddfa689bff. It also fixes
possible bug in daemon mode: calls to auth_gssapi_init and
auth_gsasl_init should appear after eventual demonization
(mu_m_server_begin), since the latter may close file
descriptors opened by them.
2020-03-18 Sergey Poznyakoff <gray@gnu.org>
Remove deprecated mailutils-config. Other minor changes.
* libmu_sieve/extensions/Makefile.am: Remove superfluous
variables.
* libmu_sieve/extensions/vacation.c: Remove unneeded include.
* mu/mailutils-config: Remove.
* mu/Makefile.am: Likewise.
2020-03-16 Sergey Poznyakoff <gray@gnu.org>
Fix a typo.
2020-03-13 Sergey Poznyakoff <gray@gnu.org>
Version 3.9.
2020-03-13 Sergey Poznyakoff <gray@gnu.org>
Distribute testsuite/package.m4.
2020-02-08 Sergey Poznyakoff <gray@gnu.org>
Update copyright years.
2020-02-08 Sergey Poznyakoff <gray@gnu.org>
Remove include/mailutils/sys/wordsplit.h.
The file is a symlink created by configure. It was
inadvertently added by 2ad00905.
2019-12-21 Sergey Poznyakoff <gray@gnu.org>
Fix build with Python 3.8
(https://savannah.gnu.org/bugs/index.php?57318)
* configure.ac: When setting PYTHON_LIBS, use the approach
suggested in
https://docs.python.org/dev/whatsnew/3.8.html#debug-build-uses-
the-same-abi-as-release-build.
2019-12-21 Sergey Poznyakoff <gray@gnu.org>
Fix https://savannah.gnu.org/bugs/index.php?57431.
* libmailutils/mime/attachment.c (at_hdr): Always use base file
name without directory components for both filename and name.
(mu_message_create_attachment): Update accordingly.
* NEWS: Update.
2019-12-15 Sergey Poznyakoff <gray@gnu.org>
Update NEWS.
2019-12-15 Sergey Poznyakoff <gray@gnu.org>
mail: enforce inline disposition for message body.
* mail/send.c (atchinfo) <disp_inline>: New member.
(attlist_add): New argument: disp_inline.
(saveatt): Split into two functions: saveatt and
save_attachment. Make sure memory allocated for the MIME part
is always freed. If disp_inline is set, enforce
Content-Disposition: inline.
(add_body): Set prominent identifier and request inline
disposition.
2019-12-14 Sergey Poznyakoff <gray@gnu.org>
Fix several linking issues.
* configure.ac: Require libtool version 2.4.6
(MU_LINK_POSTFLAGS): Remove. Not needed with the patched
version of ltmain.sh. Detect the presencecof GSSAPI. Fix
displaying the status of GSSAPI support. Remove the hack
introduced on 2010-02-19 (commit 35ac66f056).
(MU_AUTHLIBS,SQLLIB)
(SQL_LOADABLE_MODULES,SQL_LIBOBJS): Insert spaces only when
needed.
* mu-aux/ltmain.sh: ltmain.sh from libtool 2.4.6 with fixes
from http://gray.gnu.org.ua/public/ltbug installed.
* bootstrap.conf (bootstrap_epilogue): Install the fixed
ltmain.sh version.
* am/gssapi.m4: Allow for "yes" and "probe" argument values.
Improve makefile style consistency
. Uniformly use parentheses instead of curly braces in
variable
referencing;
. Prefer to use Make variables over substitution variables,
for
variables prefixed with MU_;
* comsat/Makefile.am
* dotlock/Makefile.am
* examples/Makefile.am
* examples/cpp/Makefile.am
* frm/Makefile.am
* imap4d/Makefile.am
* imap4d/tests/Makefile.am
* lib/Makefile.am
* libmailutils/Makefile.am
* libmailutils/address/Makefile.am
* libmailutils/auth/Makefile.am
* libmailutils/base/Makefile.am
* libmailutils/cfg/Makefile.am
* libmailutils/cidr/Makefile.am
* libmailutils/cli/Makefile.am
* libmailutils/datetime/Makefile.am
* libmailutils/diag/Makefile.am
* libmailutils/filter/Makefile.am
* libmailutils/imapio/Makefile.am
* libmailutils/list/Makefile.am
* libmailutils/locus/Makefile.am
* libmailutils/mailbox/Makefile.am
* libmailutils/mailcap/Makefile.am
* libmailutils/mailer/Makefile.am
* libmailutils/mime/Makefile.am
* libmailutils/msgset/Makefile.am
* libmailutils/opt/Makefile.am
* libmailutils/property/Makefile.am
* libmailutils/server/Makefile.am
* libmailutils/sockaddr/Makefile.am
* libmailutils/stdstream/Makefile.am
* libmailutils/stream/Makefile.am
* libmailutils/string/Makefile.am
* libmailutils/tests/Makefile.am
* libmailutils/url/Makefile.am
* libmailutils/wicket/Makefile.am
* libmu_auth/Makefile.am
* libmu_cpp/Makefile.am
* libmu_dbm/Makefile.am
* libmu_scm/Makefile.am
* libmu_scm/mailutils/Makefile.am
* libmu_sieve/Makefile.am
* libmu_sieve/extensions/Makefile.am
* libproto/dotmail/Makefile.am
* libproto/dotmail/tests/Makefile.am
* libproto/imap/Makefile.am
* libproto/imap/tests/Makefile.am
* libproto/maildir/Makefile.am
* libproto/mailer/Makefile.am
* libproto/mbox/Makefile.am
* libproto/mh/Makefile.am
* libproto/nntp/Makefile.am
* libproto/pop/Makefile.am
* mail/Makefile.am
* mapi/Makefile.am
* mda/lib/Makefile.am
* mda/lmtpd/Makefile.am
* mda/mda/Makefile.am
* mda/mda/tests/Makefile.am
* mda/putmail/Makefile.am
* messages/Makefile.am
* mh/Makefile.am
* mh/tests/Makefile.am
* mimeview/Makefile.am
* movemail/Makefile.am
* mu/Makefile.am
* mu/libexec/Makefile.am
* pop3d/Makefile.am
* python/2/libmu_py/Makefile.am
* python/2/mailutils/Makefile.am
* python/3/libmu_py/Makefile.am
* python/3/mailutils/Makefile.am
* readmsg/Makefile.am
* sieve/Makefile.am
* sql/Makefile.am
* testsuite/Makefile.am
2019-12-14 Sergey Poznyakoff <gray@gnu.org.ua>
Make sure LD_LIBRARY_PATH overrides the DT_RPATH tag on
FreeBSD.
* testsuite/testsuite.inc: Set LD_LIBRARY_PATH_RPATH variable
to "y" before running tests.
2019-12-14 Sergey Poznyakoff <gray@gnu.org>
Build package.m4 in Makefile.
The decision to build package.m4 in config.status makes proper
maintenance of the file problematic. It is reverted.
This patch also uses colon-separated VPATH for compatibility
with other make implementations.
* configure.ac: Don't build package.m4
* testsuite/Makefile.am: Do it here.
* libmailutils/tests/Makefile.am: Use colon-separated VPATH for
compatibility with BSD make.
* testsuite/package.m4.in: Remove.
2019-11-30 Sergey Poznyakoff <gray@gnu.org>
Fix the cwdrepl auxiliary tool.
Make sure the longest possible match is replaced.
* testsuite/cwdrepl.c: Sort the translist by directory length,
in descending order.
* mail/tests/atlocal.in: Add $testsuitedir to $PATH
* mail/tests/hold.at (MAIL_TEST): Use cwdrepl instead of sed
rules. Correct expected outputs accordingly.
2019-11-29 Sergey Poznyakoff <gray@gnu.org>
Fix missing Makefile variables.
* readmsg/tests/Makefile.am: Augment TESTSUITE_AT.
Inadvertently broken in b666b297.
2019-11-26 Sergey Poznyakoff <gray@gnu.org>
Bugfix.
* comsat/action.c (run_user_action): Fill env.locus.end with
0s.
2019-11-23 Sergey Poznyakoff <gray@gnu.org>
Bugfix in libmailutils testsuite.
* libmailutils/tests/decode2047.at: Deduce charset from the
input.
2019-11-23 Sergey Poznyakoff <gray@gnu.org>
Restore two accidentally deleted lines.
2019-11-23 Sergey Poznyakoff <gray@gnu.org>
Fix uses of uninitialized variables.
* libproto/mailer/smtp.c (_smtp_set_rcpt): Initialize header
count to zero if no such header is provided.
* mail/decode.c: Fix the util_get_hdr_value usage.
* mail/mail.h (util_get_content_type)
(util_get_hdr_value): Change return type.
* mail/util.c (util_get_content_type): Change return to void.
(util_get_hdr_value): Report error if necessary. Always
initialize
*value before return. Change return to void.
2019-11-17 Sergey Poznyakoff <gray@gnu.org>
Bugfix.
* libmailutils/mailbox/msgenv.c (get_received_date): Fix
possible NULL dereference.
2019-11-11 Sergey Poznyakoff <gray@gnu.org.ua>
Follow-up to the previous commit.
2019-11-11 Sergey Poznyakoff <gray@gnu.org.ua>
Get rid of the deprecated functions.
Below I list the removed functions along with the recipes on
how to replace them.
. mu_body_get_stream . mu_message_get_stream .
mu_mailer_get_stream . mu_header_get_stream
These functions should not be used at all.
They will reappear within a couple of releases as synonyms
for the corresponding _get_streamref functions, after which
the latter will be gradually removed. Thus, at the end of
the transition perion _get_streamref's will be replaced by
_get_stream.
. mu_sieve_compile_buffer
Replaced by mu_sieve_compile_text.
Old code:
rc = mu_sieve_compile_buffer (mach, buf, bufsize, fname,
line);
New code:
struct mu_locus_point loc = MU_LOCUS_POINT_INITIALIZER;
mu_locus_point_set_file (&loc, fname);
loc.mu_line = line;
rc = mu_sieve_compile_text (mach, buf, bufsize, &loc);
mu_locus_point_deinit (&loc);
. mu_address_to_string
Use mu_address_get_printable instead.
. mu_address_format_string
Use mu_stream_format_address instead. E.g. to print to a
string:
char buf[100];
stream_t str;
mu_fixed_memory_stream_create (&str, buf, sizeof(buf),
MU_STREAM_WRITE);
rc = mu_stream_format_address (str, addr);
. mu_registrar_get_list
Should not be used. Use mu_registrar_get_iterator if you need
to
iterate over the list.
. mu_mailbox_save_attributes
Replaced by mu_mailbox_sync.
. mu_msgset_print
Use mu_stream_msgset_format.
Old code:
rc = mu_msgset_print (mu_stream_t str, mu_msgset_t mset);
New code:
rc = mu_stream_msgset_format (str, mu_msgset_fmt_imap, mset);
2019-11-10 Sergey Poznyakoff <gray@gnu.org>
Create types.h when configuring.
2019-11-10 Sergey Poznyakoff <gray@gnu.org>
Remove deprecated MU_IOCTL_LOGSTREAM_GET_LOCUS and
MU_IOCTL_LOGSTREAM_SET_LOCUS.
2019-11-10 Sergey Poznyakoff <gray@gnu.org>
Bugfixes.
* include/mailutils/Makefile.am: Don't distribute types.h
* mda/tests/mda.sh: New file.
* mda/Makefile.am: Distribute mda.sh
* mda/lmtpd/tests/atlocal.in: Set MU_DEFAULT_SCHEME and source
mda.sh
* mda/mda/tests/atlocal.in: Likewise.
* mda/putmail/tests/atlocal.in: Likewise.
* mda/lmtpd/tests/lmtpd.at: Use dumpmail
* mda/tests/mda.inc (MDA_OPTIONS): Remove MUT_DEFAULT_OPTIONS.
(dumpmail): Remove macro.
* testsuite/package.m4.in (MU_DEFAULT_SCHEME): Remove macro.
* maint/fullcheck.mk (fullcheck_tmpl): Make the source dir
read-only.
2019-11-09 Sergey Poznyakoff <gray@gnu.org>
Reorganize testsuite.
Simplify Makefile.am's in tests subdirectories by moving the
common part in a separate file and including it where
necessary. Build only one copy of package.m4. Both package.m4
and include file testsuite.am reside in the testsuite
directory.
Also provide configure options for selecting mda components to
build:
--disable-build-mda do not build mda
--disable-build-lmtpd do not build lmtpd
--disable-build-putmail do not build putmail
* .gitignore: Update.
* Makefile.am [MU_COND_MDA]: Change to MU_COND_MDA_TOOLS
* configure.ac: Provide a way to enable/disable building of
mda, lmtpd and putmail separately. Build testsuite/package.m4
* testsuite/testsuite.am
* testsuite/Makefile.am: Distribute both package.m4.in and
package.m4. Include main part from testsuite.am
* testsuite/package.m4.in: New file.
* comsat/tests/Makefile.am: Include main part from testsuite.am
* frm/tests/Makefile.am: Likewise.
* imap4d/tests/Makefile.am: Likewise.
* libmailutils/tests/Makefile.am: Likewise.
* libmu_scm/tests/Makefile.am: Likewise.
* libproto/dotmail/tests/Makefile.am: Likewise.
* mail/tests/Makefile.am: Likewise.
* messages/tests/Makefile.am: Likewise.
* mh/tests/Makefile.am: Likewise.
* mimeview/tests/Makefile.am: Likewise.
* readmsg/tests/Makefile.am: Likewise.
* sieve/tests/Makefile.am: Likewise.
* mda/.gitignore: Remove.
* mda/tests/Makefile.am: Remove.
* mda/tests/testsuite.at: Remove.
* mda/tests/.gitignore: Remove.
* mda/tests/atlocal.in: Remove.
* mda/tests/mda.inc: New file.
* mda/Makefile.am: Add extra directory level. Add subdirs
depending on whether the corresponding component is selected
for building.
* mda/lmtpd/.gitignore: New file.
* mda/lmtpd/Makefile.am: New file.
* mda/lmtpd.c: Move to mda/lmtpd/lmtpd.c
* mda/lmtpd/tests/.gitignore: New file.
* mda/lmtpd/tests/Makefile.am: New file.
* mda/lmtpd/tests/atlocal.in: New file.
* mda/tests/lmtpd.at: Move to mda/lmtpd/tests/lmtpd.at
* mda/lmtpd/tests/testsuite.at: New file.
* mda/mda/.gitignore: New file.
* mda/mda/Makefile.am: New file.
* mda/mda.c: Move to mda/mda/mda.c
* mda/mda/tests/.gitignore: New file.
* mda/mda/tests/Makefile.am: New file.
* mda/mda/tests/atlocal.in: New file.
* mda/tests/forward.at: Move to mda/mda/tests/forward.at
* mda/tests/mda.at: Move to mda/mda/tests/mda.at
* mda/mda/tests/testsuite.at: New file.
* mda/putmail/.gitignore: New file.
* mda/putmail/Makefile.am: New file.
* mda/putmail.c: Move to mda/putmail/putmail.c
* mda/putmail/tests/.gitignore: New file.
* mda/putmail/tests/Makefile.am: New file.
* mda/putmail/tests/atlocal.in: New file.
* mda/tests/putmail.at: Move to mda/putmail/tests/putmail.at
* mda/putmail/tests/testsuite.at: New file
* po/POTFILES.in: Update pathnames
* maint/fullcheck.mk: Minor fixes.
2019-11-09 Sergey Poznyakoff <gray@gnu.org>
New maintainer makefile for running tests for all default
mailbox formats.
* maint/fullcheck.mk: New file. Runs make check for all
possible default mailbox formats.
* GNUmakefile: Include new file.
* NEWS: Update.
* configure.ac: Version 3.8.90
2019-11-09 Sergey Poznyakoff <gray@gnu.org>
Fix mda testsuite.
The testsuite should work no matter what the selected default
mailbox format.
* mda/tests/atlocal.in (dumpmail): New function.
* mda/tests/forward.at: Use dumpmail to read the mailbox.
* mda/tests/mda.at: Likewise.
2019-11-09 Sergey Poznyakoff <gray@gnu.org>
Fix SUBDIRS ordering in Makefile.am's.
* imap4d/Makefile.am: Build in source dir before tests.
* mimeview/Makefile.am: Likewise.
* pop3d/Makefile.am: Likewise.
* mail/Makefile.am: Likewise.
2019-11-09 Sergey Poznyakoff <gray@gnu.org>
dotmail: fix opening in append-only mode.
* libproto/dotmail/dotmail.c (dotmail_rescan_unlocked)
(dotmail_rescan): Skip if mailbox is not opened for reading.
2019-11-07 Sergey Poznyakoff <gray@gnu.org>
Fix typos in help strings.
* imap4d/imap4d.c: Fix typo in help string for tls-mode.
* pop3d/pop3d.c: Likewise.
2019-11-06 Sergey Poznyakoff <gray@gnu.org>
Version 3.8.
* configure.ac: Version 3.8
* NEWS: Document changes.
* THANKS: Update.
2019-10-16 Sergey Poznyakoff <gray@gnu.org>
Restore MDA debug flags.
2019-10-14 Sergey Poznyakoff <gray@gnu.org>
Restore mda tests.
* mda/mda.c: Instrument for compilation for the testsuite.
* mda/tests/.gitignore: Add testmda
* mda/tests/Makefile.am: Build testmda. Add new tests.
* mda/tests/forward.at: New test.
* mda/tests/mda.at: New test.
* mda/tests/testsuite.at: Include new tests.
2019-10-13 Sergey Poznyakoff <gray@gnu.org>
Minor fixes.
2019-10-13 Sergey Poznyakoff <gray@gnu.org>
Fix distcheck.
2019-10-12 Sergey Poznyakoff <gray@gnu.org.ua>
Split maidag into three single-purpose tools.
Maidag operated in three modes: mda, url and lmtp. In mda mode
it is normally started by sendmail with non-root privileges. In
order to be able to write to other users' mailboxes, the binary
must be setuid, which creates certain security threats. As
these appear to be impossible to avoid in a single
multi-purpose program, it has been decided to replace maidag
with three single-purpose tools: mda, putmail, and lmtpd. The
mda tool is a local mail delivery agent. It is the only one for
which the setuid bit is required, so special measures have been
taken to secure it. In particular, to avoid unverified user
inputs it disallows to override any configuration settings from
the command line.
The two other tools provide the functionality of the url and
lmtp mode.
* Makefile.am (MAIDAG_DIR): Replace with MDA_DIR
* configure.ac (MU_COND_MAILBOX_QUOTA): New conditional. Use
names relative to ${top_builddir} instead of ".".
* maidag: Remove.
* mda/.gitignore: New file.
* mda/Makefile.am: New file.
* mda/lib/Makefile.am: New file.
* mda/lib/deliver.c: New file.
* mda/lib/forward.c: New file.
* mda/lib/libmda.h: New file.
* mda/lib/mailquota.c: New file.
* mda/lib/script.c: New file.
* mda/lib/util.c: New file.
* mda/lmtpd.c: New file.
* mda/mda.c: New file.
* mda/putmail.c: New file.
* mda/tests/.gitignore: New file.
* mda/tests/Makefile.am: New file.
* mda/tests/atlocal.in: New file.
* mda/tests/input.msg: New file.
* mda/tests/lmtpd.at: New file.
* mda/tests/putmail.at: New file.
* mda/tests/testsuite.at: New file.
* doc/texinfo/programs/maidag.texi: Remove.
* doc/texinfo/programs/mda.texi: New file.
* doc/texinfo/programs/lmtpd.texi: New file.
2019-10-12 Sergey Poznyakoff <gray@gnu.org.ua>
cli: implement a hint that disallows overriding configuration
from the command line * include/mailutils/cfg.h
(MU_CFHINT_NO_CONFIG_OVERRIDE): New hint. *
libmailutils/cli/cli.c (init_options): Omit configuration
override options if MU_CFHINT_NO_CONFIG_OVERRIDE is set.
2019-09-11 Sergey Poznyakoff <gray@gnu.org.ua>
Fix typo.
2019-09-11 Sergey Poznyakoff <gray@gnu.org.ua>
mail: revamp message type specification handling.
* mail/mail.h (msgtype_generator): New proto.
* mail/mailline.c (msgtype_generator): Remove.
* mail/msgset.y (TYPE rule): Use find_type_selector to find the
right selector.
(select_type): Remove. Replaced with separate functions for
each message type (select_type_n, select_type_d, etc.)
(find_type_selector): New static function.
(msgtype_generator): New function.
2019-09-11 Sergey Poznyakoff <gray@gnu.org.ua>
mail: new message specification :s.
* NEWS: Update.
* doc/texinfo/programs/mail.texi: Update.
* mail/mailline.c (msgtype_generator): Recogize 's'
* mail/msgset.y (select_type): Recognize 's'
2019-09-11 Sergey Poznyakoff <gray@gnu.org.ua>
Document how to set body content-type and encoding in multipart
messages.
This closes https://savannah.gnu.org/support/?109866
2019-09-11 Sergey Poznyakoff <gray@gnu.org.ua>
Document yesterday's changes.
2019-09-10 Sergey Poznyakoff <gray@gnu.org.ua>
Fix the semantics of the hold and keepsave variables in mail.
* mail/delete.c (mail_delete_msg): Set
MAIL_ATTRIBUTE_PRESERVED. This is not necessary, stricto sensu,
because mail_mbox_close skips messages marked for deletion
anyway. But it's good for clarity.
* mail/quit.c (mailbox_classify): New function.
(mail_mbox_commit): Rewrite
* mail/tests/Makefile.am: Add new test
* mail/tests/testsuite.at: Include new tests.
* mail/tests/atlocal.in (catmbox): New function.
* mail/tests/hold.at: New test.
2019-09-05 Sergey Poznyakoff <gray@gnu.org.ua>
Fix guimb help message.
* scheme/guimb.scmi: Format the usage and description lines
consistently with other mailutils programs.
2019-09-03 Sergey Poznyakoff <gray@gnu.org>
comsatd: optional argument to the --test option supplies the
name of the tty to use.
* NEWS: Document changes.
* comsat/action.c (open_default_tty): Remove.
(open_tty): Examine the tty device (or file) and construct a
suitable filter chain. Use append mode when opening it.
* comsat/comsat.c: The --test option takes optional argument.
* comsat/tests/testsuite.at: Use local file instead of the tty.
* doc/texinfo/programs/comsatd.texi: Document changes.
2019-08-29 Sergey Poznyakoff <gray@gnu.org.ua>
pop3d: implement TLS in inetd mode.
New global configuration statement "tls-mode" configures the
TLS for use in inetd mode.
The certificate and key files are configured by the global
"tls" compound statement.
Example configuration (pop3s server):
mode inetd;
tls-mode connection;
tls {
ssl-key-file /etc/ssl/key.pem;
ssl-certificate-file /etc/ssl/cert.pem;
}
In daemon mode, global "tls-mode" sets the type of TLS
encryption to use in all server blocks that lack the "tls-mode"
statement.
* pop3d/cmd.c (global_tls_mode)
(global_conf_status): New globals.
(stls_server_check): New function.
(stls_preflight): Use stls_server_check.
* pop3d/pop3d.c (pop3d_cfg_param): New global statement:
tls-mode
(main): Set up TLS connection in inetd mode, if requested.
* pop3d/pop3d.h (global_tls_mode): New global.
(stls_server_check): New proto.
* NEWS: Document changes.
* doc/texinfo/programs/pop3d.texi: Likewise.
2019-07-23 Sergey Poznyakoff <gray@gnu.org>
Fix mandatory locking.
* lib/manlock.c (mailbox_open_and_lock): Force proper locker if
a null locker is associated with the mailbox.
2019-07-23 Sergey Poznyakoff <gray@gnu.org>
Minor fix.
Check return from mu_message_get_num_parts
2019-07-13 Sergey Poznyakoff <gray@gnu.org>
Fixes in the mail testsute.
* mail/tests/copy00.at: Fix description. Skip test if
/dev/stdout cannot be locked.
* mail/tests/copy03.at: Rename MBOX to avoid name clashes on
case-insensitive file systems.
2019-07-11 Sergey Poznyakoff <gray@gnu.org>
Bugfix.
* include/mailutils/sys/dotmail.h: Remove stray variable
declaration.
2019-07-11 Sergey Poznyakoff <gray@gnu.org>
Pull wordsplit from submodule.
* .gitmodules: Add wordsplit.
* configure.ac: Version 3.7.90
* NEWS: Raise version number.
* include/mailutils/sys/Makefile.am: Include wordsplit.h from
the submodule.
* include/mailutils/sys/wordsplit.h: New file.
* include/mailutils/wordsplit.h: Rewrite as a wrapper over
mailutils/sys/wordsplit.h
* libmailutils/Makefile.am: Distribute files from wordsplit.
* libmailutils/string/Makefile.am: Add libmailutils/wordsplit
to the include path.
* libmailutils/string/wordsplit.c: Replace with a wrapper over
wordsplit/wordsplit.c
* libmailutils/tests/.gitignore: Update.
* libmailutils/tests/Makefile.am: Pull wordsplit testsuite from
the submodule.
* libmailutils/tests/wordsplit.at: Remove.
* libmailutils/tests/wsp.c: Remove.
2019-06-22 Sergey Poznyakoff <gray@gnu.org>
Use defines for internal mail variable names.
2019-06-22 Sergey Poznyakoff <gray@gnu.org>
Fix typos and wording in some diagnostic messages.
2019-06-21 Sergey Poznyakoff <gray@gnu.org>
Version 3.7.
2019-06-21 Sergey Poznyakoff <gray@gnu.org>
Update NEWS.
2019-05-30 Sergey Poznyakoff <gray@gnu.org>
Fix conditional compilation; add dotmail support to libmu_scm.
* configure.ac: Accept dotmail as a value for
MU_DEFAULT_SCHEME. Display dotmail support status at the end of
the run.
* libmailutils/base/nullrec.c: Provide placeholder for disabled
dotmail.
* libmu_scm/mu_scm.c (format_table): Add dotmail.
* libmu_scm/tests/testsuite.at: Don't assume mbox as the
default. Load it explicitly.
2019-05-30 Sergey Poznyakoff <gray@gnu.org>
Minor change.
* maint/flowgraph.mk: Pass --all to cflow.
2019-05-29 Sergey Poznyakoff <gray@gnu.org>
mh: fix folder +/absolute/name.
* mh/folder.c (name_prefix_len): Remove global.
(install_folder_info,_scan): Take additional argument: length
of the name prefix to skip.
(folder_scan): New function.
(action_print): Don't impose name prefix unconditionally. Call
folder_scan to set it up as necessary.
2019-05-22 Sergey Poznyakoff <gray@gnu.org>
Fix a bug in TLS read.
This complements afda9ba4. Thanks to Rafael Fontenelle for
helping locate the bug.
* libmu_auth/tlsiostr.c (_tls_io_read): Handle GNUTLS_E_AGAIN
and GNUTLS_E_INTERRUPTED.
* libmailutils/stream/stream.c (mu_stream_seterr): EINTR is a
transient error condition.
* THANKS: Update.
2019-05-22 Sergey Poznyakoff <gray@gnu.org>
URL parser: use case-insensitive comparison for auth and host
parts.
* libmailutils/url/accessor.h: (URL_PART_CMP_ICASE)
(URL_PART_CMP_ICASE): New defines.
* libmailutils/url/get-auth.c: Request case-insensitive
comparison.
* libmailutils/url/get-host.c: Likewise.
2019-05-21 Sergey Poznyakoff <gray@gnu.org>
Describe maidag delivery-mode configuration variable.
2019-05-09 Sergey Poznyakoff <gray@gnu.org>
Maidag: fix coredump in daemon mode.
* maidag/maidag.c (main): Pass pointer to the server as data
parameter to mu_cli.
2019-05-03 Sergey Poznyakoff <gray@gnu.org>
movemail: make sure UIDLs are properly stored.
* movemail/movemail.c (main): When using POP3 UIDLs for message
identification, be sure to store them in the X-UIDL header.
2019-04-24 Sergey Poznyakoff <gray@gnu.org>
Bugfixes.
* libmailutils/diag/diag.c (mu_diag_vprintf): Fix debug level
formatting. It missed 's' after the escape character.
* mu/libexec/ldflags.c (lib_descr): Add dotmail.
2019-03-29 Sergey Poznyakoff <gray@gnu.org>
Remove explicit _DEPENDENCIES variables from Makefiles.
These might be needed only in rare cases during the development
cycle. There is no use keeping them around.
* configure.ac (MU_AUTHLIBS_DEPENDENCY)
(DBMLIB_DEPENDENCY,SQLLIB_DEPENDENCY): Remove.
* imap4d/Makefile.am: Remove explicit _DEPENDENCIES.
* pop3d/Makefile.am: Likewise.
* libmu_auth/Makefile.am: Likewise.
* libmu_dbm/Makefile.am: Likewise.
2019-03-27 Sergey Poznyakoff <gray@gnu.org>
Use <prog>_LDADD to link in libmu_test.
This helps automake discover dependency on this library.
2019-03-27 Sergey Poznyakoff <gray@gnu.org>
Minor fix (follow-up to 60c5545ba)
2019-03-27 Sergey Poznyakoff <gray@gnu.org>
Minor fixes in dot filters.
The DOT decoder accepts input consisting of two characters
".\n" and decodes it to empty output. When encoding empty
input, ".\n" is produced
Similarly, CRLFDOT handles ".\r\n" the same way.
* libmailutils/filter/crlfdot.c (_crlfdot_encoder): Accept
".\r\n" as input.
* libmailutils/filter/dot.c: Accept ".\n" as input.
* libmailutils/tests/crlfdot.at: Add new test.
* libmailutils/tests/dot.at: Likewise.
2019-03-26 Sergey Poznyakoff <gray@gnu.org>
Use mu_folder_scan in imap4d.
* imap4d/list.c (list_fun): Don't check if the returned record
matches refinfo->pfx->record. This is done by mu_folder_scan.
(list_ref): Use mu_folder_scan.
2019-03-26 Sergey Poznyakoff <gray@gnu.org>
Consistently use the term 'depth' when referring to directory
nesting depth.
* include/mailutils/folder.h (mu_list_response): Rename 'level'
to 'depth'. All uses updated.
2019-03-26 Sergey Poznyakoff <gray@gnu.org>
Implement selection of requested mailbox formats in scanning
the local file system folders.
* include/mailutils/registrar.h (mu_record_match): New struct.
(mu_registrar_match_records): New proto.
* libmailutils/base/registrar.c (mu_registrar_match_records):
New function.
* libmailutils/mailbox/fsfolder.c (list_helper): Actually
select the matching record from scn->records (if supplied).
* libmailutils/tests/Makefile.am: Add new tests.
* libmailutils/tests/fsfolder.c: Minor changes.
* libmailutils/tests/testsuite.at: Add new tests.
* libmailutils/tests/fsfolder03.at: New file.
* libmailutils/tests/fsfolder04.at: New file.
2019-03-25 Sergey Poznyakoff <gray@gnu.org>
Bugfixes in fsfolder.
* libmailutils/mailbox/fsfolder.c (list_helper): Fix depth cut
off. Fix the lookup in scn->records.
* libmailutils/tests/fsfolder.c: Implement two test records.
New command: "scan".
2019-03-25 Sergey Poznyakoff <gray@gnu.org>
Implement test shell framework.
* libmailutils/tests/tesh.c: New file.
* libmailutils/tests/tesh.h: New file.
* libmailutils/tests/Makefile.am: Add new files.
* libmailutils/tests/fsfolder.c: Rewrite using test shell
framework.
* libmailutils/tests/fsfolder00.at: Use semicolons to delimit
commands.
* libmailutils/tests/fsfolder01.at: Likewise.
* libmailutils/tests/linetrack.c: Rewrite using test shell
framework.
* libmailutils/tests/linetrack.at: Change command initial
character to dot.
* libmailutils/tests/listop.c: Rewrite using test shell
framework.
* libmailutils/tests/list.at: Minor changes.
* libproto/dotmail/tests/dm_mesg.c: Rewrite using test shell
framework.
* libproto/dotmail/tests/Makefile.am: Link dm_mesg with
libmu_tesh
* libproto/dotmail/dotmail.c: Fix typo.
2019-03-23 Sergey Poznyakoff <gray@gnu.org>
Two new string functions.
mu_string_prefix(A, B) returns true if B is the prefix of A.
mu_string_suffix(A, B) returns true if B is the suffix of A.
* include/mailutils/cstr.h (mu_string_prefix)
(mu_string_suffix): protos.
* libmailutils/string/Makefile.am: Add new files.
* libmailutils/string/strpref.c: New file.
* libmailutils/string/strsuf.c: New file.
2019-03-23 Sergey Poznyakoff <gray@gnu.org>
Rewrite folder listing interface.
New function mu_folder_scan provides an improved scanning
interface. In particular, it allows the user to abridge the
scan to mailboxes of certain type (or types).
Existing listing API functions are rewritten as alternative
entry points to mu_folder_scan.
* include/mailutils/folder.h (mu_folder_scanner): New struct.
(mu_folder_scan): New function.
* include/mailutils/registrar.h (mu_registrar_list_p): New
function.
* include/mailutils/sys/folder.h (_mu_folder._list): Change
signature.
* libmailutils/base/registrar.c (mu_registrar_list_p): New
function.
* libmailutils/mailbox/folder.c (mu_folder_scan): New function.
(mu_folder_enumerate): Rewrite as entry point to
mu_folder_scan.
* libmailutils/mailbox/fsfolder.c: Use new API,
* libmailutils/tests/fsfolder.c: Rewrite scheme matcher.
* libmailutils/tests/fsfolder00.at: Fix test output.
* libmailutils/tests/fsfolder02.at: Likewise.
* libproto/imap/folder.c: Use new API.
2019-03-22 Sergey Poznyakoff <gray@gnu.org>
Fix MH format detection.
* libproto/mh/folder.c (mh_dir_p): Check only regular files.
(_mh_list_p): Ditto. All directories are eligible for listing.
* libmailutils/base/registrar.c (mu_record_list_p): Remove
useless check.
2019-03-13 Sergey Poznyakoff <gray@gnu.org>
mail: force mime mode if at least one attachment was given.
This fixes
https://bugs.debian.org/cgi-bin/bugreport.cgi?bug=918806
* mail/mail.c (cli_attach): Set mime_option.
2019-03-10 Sergey Poznyakoff <gray@gnu.org>
Fix encoding of empty input by DOT filter.
* libmailutils/filter/dot.c (_dot_encoder): Don't emit
additional empty line on empty input (i.e. if mu_filter_lastbuf
arrives when dfa is in dot_encode_init state).
* libmailutils/tests/dot.at: Test empty input.
2019-03-06 Sergey Poznyakoff <gray@gnu.org>
Simplify dotmail test environment.
The dm_mbox tool is not needed after ff847bb1. Remove it.
Modify dm_mesg to optionally take commands from the command
line. Use it instead of dm_mbox in testcases.
2019-03-06 Sergey Poznyakoff <gray@gnu.org>
Minor change.
* NEWS: Document the recent changes.
* THANKS: Add Kurt Hackenberg.
2019-03-06 Sergey Poznyakoff <gray@gnu.org>
Bugfix.
* libproto/mbox/mbox.c (restore_date): Fix possible
uninitialized memory access.
2019-03-06 Sergey Poznyakoff <gray@gnu.org>
Revamp UID support in dotmail.
* include/mailutils/stream.h (mu_stream_header_copy): New
proto.
* libmailutils/stream/hdrcpy.c: New file.
* libmailutils/stream/Makefile.am: Add hdrcpy.c
* libmailutils/tests/hdrcpy.c: New test program.
* libmailutils/tests/hdrcpy.at: New testcase.
* libmailutils/tests/Makefile.am: Add new test program and
testcase.
* libmailutils/tests/testsuite.at: Add new testcase.
* libproto/dotmail/tests/append.at: Add new tests.
* libmailutils/tests/.gitignore: Update.
* include/mailutils/sys/dotmail.h (mu_dotmail_message): Remove
headers_scanned. New field: uid_modified.
(mu_dotmail_mailbox): Change type for uidnext to unsigned long.
Remove scanned_uids_count. (mu_dotmail_message_headers_prescan)
(mu_dotmail_mailbox_scan_uids): Remove.
(mu_dotmail_mailbox_uid_setup): New proto.
* libproto/dotmail/dotmail.c: Revamp UID support. See "Notes"
on line 251 for description.
* libproto/dotmail/message.c (mu_dotmail_message_reconstruct):
Optimize for the case where the message remains unchanged
except for the UID information.
* libproto/dotmail/tests/dm_mesg.c: Add mailbox inspection
commands from dm_mbox. Perhaps the latter can be removed.
2019-03-03 Sergey Poznyakoff <gray@gnu.org>
Implement automatic dot-unstuffing in dotmail mailboxes.
* include/mailutils/sys/dotmail.h (mu_dotmail_message): New
members: body_size and body_dot_stuffed.
* libproto/dotmail/dotmail.c (dotmail_rescan_unlocked): Count
dot-unstuffed octets in the body. Set dmsg->body_dot_stuffed to
1 if at least one byte was dot-stuffed.
* libproto/dotmail/message.c (dotmail_body_size): Return
unstuffed size.
(_msg_body_setup): If the body was dot-stuffed, return rdcache
stream built over the "DOT" decoder.
* libproto/dotmail/tests/body.at: Check dot-unstuffing.
2019-03-02 Sergey Poznyakoff <gray@gnu.org>
Fix the dot filter decoding.
* libmailutils/filter/dot.c (_dot_decoder): Don't emit extra
newline at the "\n.\n" marker.
* libmailutils/stream/stream.c (mu_stream_seterr): Don't treat
ENOSYS as fatal error.
* libmailutils/tests/dot.at: New file.
* libmailutils/tests/testsuite.at: Include dot.at.
* libmailutils/tests/Makefile.am: Add dot.at
* testsuite/smtp-msg.at: Remove extra newline from the expected
output.
* testsuite/smtp-str.at: Likewise.
2019-03-02 Sergey Poznyakoff <gray@gnu.org>
Improve the dotmail testsuite.
* libproto/dotmail/tests/dm_mesg.c: Rewrite to take commands
from stdin.
* libproto/dotmail/tests/Makefile.am: Add setattr.at
* libproto/dotmail/tests/testsuite.at (DM_MESG): New macro.
* libproto/dotmail/tests/setattr.at: New file.
* libproto/dotmail/tests/append.at: Use DM_MESG.
* libproto/dotmail/tests/attr.at: Likewise.
* libproto/dotmail/tests/body.at: Likewise.
* libproto/dotmail/tests/delete.at: Likewise.
* libproto/dotmail/tests/env.at: Likewise.
* libproto/dotmail/tests/header.at: Likewise.
* libproto/dotmail/tests/uid.at: Likewise.
2019-03-02 Sergey Poznyakoff <gray@gnu.org>
Implement different accuracy levels for the mailbox format
detection.
Selecting the accuracy level allows the user to achieve the
desired balance between the speed of the folder scan and
accuracy of mailbox format detection.
The accuracy level can be set either from the configuration
file, using the mailbox.accuracy-level statement, or from the
environment, using the MU_AUTODETECT_ACCURACY variable.
The default accuracy level 1 discerns valid mbox and dotmail
mailboxes providing reasonable scan speed. Level 0 (previous
default) does not discern them, but provides maximal speed.
Level 2 and higher provide better accuracy at the price of
speed.
* include/mailutils/url.h (MU_AUTODETECT_ACCURACY_AUTO)
(MU_AUTODETECT_ACCURACY_FAST)
(MU_AUTODETECT_ACCURACY_DEFAULT): New constants.
(mu_scheme_autodetect_p): New proto, moved here from util.h
(mu_set_autodetect_accuracy)
(mu_autodetect_accuracy): New protos.
* libmailutils/base/schemeauto.c (mu_set_autodetect_accuracy)
mu_autodetect_accuracy): New functions.
* libmailutils/cli/stdcapa.c: New configuration statement:
mailbox.autodetect-accuracy.
* libmailutils/url/create.c (_mu_url_create_internal): Assume
the "file" scheme if the MU_URL_PARSE_LOCAL flag is set.
* libproto/dotmail/folder.c: Implement format detection. Three
accuracy levels: 0, 1, and >1
* libproto/mbox/folder.c (_mbox_is_scheme): Implement default
format detection.
* libproto/dotmail/tests/Makefile.am: Add new test.
* libproto/dotmail/tests/autodetect.at: New test.
* libproto/dotmail/tests/dm_detect.c: New file.
* libproto/dotmail/tests/testsuite.at: Add new test.
2019-03-01 Sergey Poznyakoff <gray@gnu.org>
Initial implementation of the dotfile format.
* configure.ac: Enable new local format.
* include/mailutils/registrar.h (mu_dotmail_record): New
extern. (mu_register_all_mbox_formats)
(mu_register_local_mbox_formats): Add mu_dotmail_record
* include/mailutils/sys/dotmail.h: New file.
* libproto/dotmail/Makefile.am: New file.
* libproto/dotmail/dotmail.c: New file.
* libproto/dotmail/message.c: New file.
* libproto/dotmail/folder.c: New file.
* libproto/dotmail/tests/.gitignore: New file.
* libproto/dotmail/tests/Makefile.am: New file.
* libproto/dotmail/tests/atlocal.in: New file.
* libproto/dotmail/tests/count.at: New file.
* libproto/dotmail/tests/dm_mbox.c: New file.
* libproto/dotmail/tests/dm_mesg.c: New file.
* libproto/dotmail/tests/env.at: New file.
* libproto/dotmail/tests/header.at: New file.
* libproto/dotmail/tests/recent.at: New file.
* libproto/dotmail/tests/testsuite.at: New file.
* libproto/dotmail/tests/attr.at: New file.
* libproto/dotmail/tests/body.at: New file.
* libproto/dotmail/tests/uid.at: New file.
* libproto/dotmail/tests/dm_qget.c: New file.
* libproto/dotmail/tests/qget.at: New file.
* libproto/dotmail/tests/append.at: New file.
* libproto/dotmail/tests/delete.at: New file.
* libmu_scm/mailutils/ancilla.scm: Fix regular expression to
take into account changes introduced by 4bdc41ff90.
2019-02-26 Sergey Poznyakoff <gray@gnu.org>
Provide fallback mechanism for mu_mailbox_messages_recent and
mu_mailbox_message_unseen.
* libmailutils/mailbox/mailbox.c (mu_mailbox_messages_recent)
(mu_mailbox_message_unseen): Fall back to iteration if no
backend-specific method is provided.
2019-02-26 Sergey Poznyakoff <gray@gnu.org>
envelope: attempt to recover from trace information if not
available otherwise.
* libmailutils/mailbox/msgenv.c (message_envelope_date): Use
timestamp from Received header.
(message_envelope_sender): Give preference to Return-Path
header
2019-02-26 Sergey Poznyakoff <gray@gnu.org>
New autoconf macro for activating mailbox format support.
* am/enable.m4 (MU_ENABLE_SUPPORT)
(MU_ENABLE_BUILD): Use m4_-prefixed directives.
(MU_ENABLE_MAILBOX_FORMAT) (MU_ENABLE_LOCAL_MAILBOX_FORMAT_
(MU_ENABLE_REMOTE_MAILBOX_FORMAT): New macros. (MU_LIB_MAILBOX)
(MU_LIB_LOCAL_MAILBOX)
(MU_LIB_REMOTE_MAILBOX): New substitution variables.
* configure.ac: Use new macros to enable mailbox formats
* libproto/Makefile.am: Augment SUBDIRS instead of using
Makefile variables.
* comsat/Makefile.am: Use MU_LIB_.*MAILBOX macros to link in
the necessary libraries.
* examples/Makefile.am: Likewise.
* examples/cpp/Makefile.am: Likewise.
* frm/Makefile.am: Likewise.
* imap4d/Makefile.am: Likewise.
* include/mailutils/sys/Makefile.am: Likewise.
* libmu_scm/Makefile.am: Likewise.
* libproto/Makefile.am: Likewise.
* maidag/Makefile.am: Likewise.
* mail/Makefile.am: Likewise.
* messages/Makefile.am: Likewise.
* mh/Makefile.am: Likewise.
* movemail/Makefile.am: Likewise.
* mu/libexec/Makefile.am: Likewise.
* pop3d/Makefile.am: Likewise.
* python/2/libmu_py/Makefile.am: Likewise.
* python/3/libmu_py/Makefile.am: Likewise.
* readmsg/Makefile.am: Likewise.
* sieve/Makefile.am: Likewise.
* testsuite/Makefile.am: Likewise.
2019-02-24 Sergey Poznyakoff <gray@gnu.org>
Bugfix.
* python/3/libmu_py/mailcap.c: Fix leftover uses of
PyString_FromString and PyInt_FromLong.
2019-02-23 Sergey Poznyakoff <gray@gnu.org>
Version 3.6.
* NEWS: Update.
* configure.ac: Raise version number Raise VI_CURRENT and clear
VI_REVISION (due to 18e23d6e).
* libproto/imap/close.c: Add missing include.
2019-02-03 Sergey Poznyakoff <gray@gnu.org>
Update NEWS.
2019-02-03 Sergey Poznyakoff <gray@gnu.org>
Rewrite the mailcap support.
* configure.ac: Build libmailutils/mailcap/Makefile
* include/mailutils/mailcap.h: Rewrite
* include/mailutils/sys/Makefile.am: Add mailcap.h
* include/mailutils/sys/mailcap.h: New file.
* include/mailutils/util.h: Add missing include.
* lib/mailcap.c: Rewrite using new API.
* libmailutils/Makefile.am: Build in mailcap
* libmailutils/base/Makefile.am: Remove mailcap.c
* libmailutils/base/mailcap.c: Remove.
* libmailutils/mailcap/Makefile.am: New file.
* libmailutils/mailcap/ctmatch.c: New file.
* libmailutils/mailcap/deferrclos.c: New file.
* libmailutils/mailcap/mcp_creat.c: New file.
* libmailutils/mailcap/mcp_destr.c: New file.
* libmailutils/mailcap/mcp_err.c: New file.
* libmailutils/mailcap/mcp_flags.c: New file.
* libmailutils/mailcap/mcp_get.c: New file.
* libmailutils/mailcap/mcp_sel.c: New file.
* libmailutils/mailcap/mcp_count.c: New file.
* libmailutils/mailcap/mcp_find.c: New file.
* libmailutils/mailcap/ent_cmd.c: New file.
* libmailutils/mailcap/ent_creat.c: New file.
* libmailutils/mailcap/ent_destr.c: New file.
* libmailutils/mailcap/ent_locus.c: New file.
* libmailutils/mailcap/ent_type.c: New file.
* libmailutils/mailcap/fieldacc.c: New file.
* libmailutils/mailcap/fields.c: New file.
* libmailutils/mailcap/finder.c: New file.
* libmailutils/mailcap/parse.c: New file.
* libmailutils/mailcap/parsefile.c: New file.
* libmailutils/tests/mailcap.c: Rewrite using new API. Improve
cli
* libmailutils/tests/mcf.c: New file.
* libmailutils/tests/ctm.c: New file.
* libmailutils/tests/ctm.at: New file.
* libmu_cpp/mailcap.cc: Rewrite using new API.
* python/2/libmu_py/mailcap.c: Rewrite using new API.
* python/3/libmu_py/mailcap.c: Rewrite using new API.
* examples/python/2/mailcap.py: Minor change. This example is
broken with the new API. Should be fixed.
* include/mailutils/cpp/mailcap.h: Update
* include/mailutils/cpp/pop3.h: Update
2019-02-02 Sergey Poznyakoff <gray@gnu.org>
New iterator functions: mu_iterator_skip_while and
mu_iterator_skip_until.
The mu_iterator_skip_while function continues iteration while
the supplied predicate function returns true. The
mu_iterator_skip_until function continues iteration until the
supplied predicate function returns true.
* include/mailutils/iterator.h: Add new prototypes.
* libmailutils/base/iterator.c: Implement new functions.
2019-01-31 Sergey Poznyakoff <gray@gnu.org>
Rewrite the transcript stream.
The new implementation consists of two independent state
machines for each transcript channel (input and output). The
MU_XSCRIPT_PAYLOAD state can be turned on for a predefined
number of bytes on each channel. After that many bytes pass
through, the state will return back to MU_XSCRIPT_NUMBER. This
allows, in particular, to improve logging of client commands
containing literals in imap4d.
* include/mailutils/stream.h (MU_IOCTL_XSCRIPTSTREAM_CHANNEL):
New ioctl subcode.
(mu_xscript_channel): New struct. (MU_XSCRIPT_LEVEL_IS_PACKED)
(MU_XSCRIPT_LEVEL_MASK,MU_XSCRIPT_LEVEL_UNMASK)
(MU_XSCRIPT_LEVEL_PACK): New macros.
* include/mailutils/sys/xscript-stream.h (_mu_xscript_channel):
New struct.
(_mu_xscript_stream): Keep independent state for each channel.
* libmailutils/stream/xscript-stream.c: Rewrite as a state
machine with independent states for input and output channels.
* libmailutils/tests/xscript.at: Test packed channel levels and
MU_IOCTL_XSCRIPTSTREAM_CHANNEL ioctl.
* libmailutils/tests/xscript.c: Rewrite command parser.
* imap4d/imap4d.h (xscript_declare_client_payload): New proto.
* imap4d/util.c (xscript_declare_client_payload): New function.
* imap4d/io.c (imap4d_readline): Use
xscript_declare_client_payload after literals.
2019-01-29 Sergey Poznyakoff <gray@gnu.org>
imap4d: Proper case-insensitive searches over multibyte
strings.
This requires libunistring.
* NEWS: Update.
* README: Update.
* configure.ac: Check for libunistring.
* libmailutils/base/version.c: Reflect libunistring usage.
* imap4d/Makefile.am: Link with libunistring, if available.
* imap4d/imap4d.h (unistr_downcase)
(unistr_is_substring): New protos.
* imap4d/search.c (_scan_header)
(_scan_header_all,_match_text): Use unistr_is_substring for
searches.
* imap4d/unistr_c.c: New file.
* imap4d/unistr_u8.c: New file.
* imap4d/tests/search.at: Add new test.
2019-01-28 Sergey Poznyakoff <gray@gnu.org>
Revert 3aeec0dcc151b836cb09d756ad41598c95201446.
Adding 1 to the buffer size is necessary, because
_stream_scandelim requires buffer to provide enough space to
accomodate the trailing 0. Consequently, the minimal acceptable
buffer size is 2.
2019-01-27 Sergey Poznyakoff <gray@gnu.org>
Minor fix.
* search.c (_match_multipart): Initialize result.
2019-01-26 Sergey Poznyakoff <gray@gnu.org>
Minor fix.
* imap4d/search.c (parse_search_key): Fix eventual NULL pointer
dereference.
2019-01-26 Sergey Poznyakoff <gray@gnu.org>
Add tests for imap4d SEARCH BODY, TEXT, and CHARSET.
* imap4d/tests/.gitignore: New file.
* imap4d/tests/ckiconv.c: New file.
* imap4d/tests/Makefile.am: Build ckiconv.c
* imap4d/tests/search.at: Add tests for BODY, TEXT and CHARSET
* imap4d/tests/testsuite.at (IMAP4D_WITH_PREREQ): New macro
(IMAP4D_CHECK): Skip test if the supplied prerequisite is not
satisfied.
* testsuite/spool/search2.mbox: New file.
* testsuite/spool/DISTFILES: Add search2.mbox.
* mail/decode.c (mime_descend): Fix handling of message/rfc822.
2019-01-26 Sergey Poznyakoff <gray@gnu.org>
Remove misguiding comment.
2019-01-26 Sergey Poznyakoff <gray@gnu.org>
imap4d: implement SEARCH CHARSET; fix BODY and TEXT searches.
* imap4d/search.c: Implement proper BODY searches. Implement
CHARSET.
* imap4d/util.c (util_strcasestr): Remove. Use mu_c_strcasestr
instead.
* imap4d/imap4d.h: Likewise.
* NEWS: Document changes.
2019-01-25 Sergey Poznyakoff <gray@gnu.org>
Improve error checking in stream writing functions.
* libmailutils/stream/stream.c (mu_stream_write): Return EIO on
short writes if pnwritten is NULL.
* libmailutils/stream/streamcpy.c (mu_stream_copy): Likewise
(if source stream size is known.
2019-01-24 Sergey Poznyakoff <gray@gnu.org>
Fix stream reference implementation.
Do not propagate streamref's error and eof state upstream.
* libmailutils/stream/streamref.c (streamref_return): Remove
function. All uses updated.
2019-01-23 Sergey Poznyakoff <gray@gnu.org>
mail: fix completion of set, unset, and variable.
2019-01-23 Sergey Poznyakoff <gray@gnu.org>
mail: implement variable and command expansion in echo command.
* mail/echo.c: Implement variable and command expansion.
* mail/mail.c (main): Set PID mailvar.
* mail/mailvar.c (mailvar_tab): New variable PID (to help in
debugging).
(set_folder): Expand initial ~
* mail/set.c: Remove misguiding comment.
2019-01-23 Sergey Poznyakoff <gray@gnu.org>
Fix in IMAP wildcard matcher.
* libmailutils/imapio/wildmatch.c (_wild_match): Handle % at
the end of input same way as *.
2019-01-23 Sergey Poznyakoff <gray@gnu.org>
mail: fixes in completion routines.
2019-01-23 Sergey Poznyakoff <gray@gnu.org>
mail: improve message set parser.
* mail/from.c (sender_string): New function.
* mail/mail.h: Likewise.
* mail/msgset.y: Fix memory management and error reporting.
Implement sender address matching.
* mail/util.c (util_outfolder_name): Always return allocated
value.
* mail/copy.c (mail_copy0): Add typecast.
2019-01-23 Sergey Poznyakoff <gray@gnu.org>
mail: new notation @, for the mailbox given with the -f option.
* doc/texinfo/programs/mail.texi: Document the @ notation.
* NEWS: Likewise.
* mail/copy.c (mail_copy0): Rewrite. Use mailbox URLs instead
of filenames.
* mail/file.c (mail_expand_name): Return integer code. On
success, convert the expanded name to URL and return it in the
memory location supplied by the second argument. Use new
shorthand notation @, for the name of the file given with the
-f option. All uses changed.
* mail/mail.c (secondary_url): New global.
(main): Save the URL of the file given with the -f option in
secondary_url. Use it, instead of the file variable, to decide
what kind of summary message to display for empty mailbox (see
commit 99b6b6f02c3cf94ebe1daf7233a702c743d6a2b5).
* mail/mail.h (secondary_url): New global.
(mail_expand_name): Change prototype.
* mail/mailline.c: Minor changes.
* libmailutils/wicket/noauth.c (noauth_ticket_get_cred): Return
MU_ERR_AUTH_NO_CRED.
2019-01-22 Sergey Poznyakoff <gray@gnu.org>
Summarize recent changes in NEWS.
2019-01-22 Sergey Poznyakoff <gray@gnu.org>
Improve mail folder completion.
* mail/mailline.c (filegen_init): Check if the mail folder is
the same as the one used by the current mailbox, and reuse it
if so.
2019-01-22 Sergey Poznyakoff <gray@gnu.org>
Add missing prototype.
* include/mailutils/url.h (mu_url_is_same_portstr): New proto.
2019-01-22 Sergey Poznyakoff <gray@gnu.org>
Remove central registry of created folders.
The way it is implemented now, it creates more problems than
offers solutions. In particular, it makes it impossible to open
two mailboxes in the same IMAP account.
* libmailutils/mailbox/folder.c (known_folder_list)
(folder_lock): Remove variable.
(is_known_folder): Remove function.
(mu_folder_create_from_record): Don't use static folder list.
2019-01-22 Sergey Poznyakoff <gray@gnu.org>
fix in mail completion.
* mail/mailline.c (filegen_init): Append tailing delimiter to
folders only on exact match.
2019-01-22 Sergey Poznyakoff <gray@gnu.org>
Minor fix in imap client.
* libproto/imap/close.c (_mu_close_handler): Free mbox_name.
2019-01-21 Sergey Poznyakoff <gray@gnu.org>
Fixes in imap client: handle EXPUNGE response, fix
incorporation of new messages.
Certain servers do not issue EXISTS unsolicited response after
expunging. Use EXPUNGE responses to keep track of the deleted
messages.
Internal structure of imap mailbox object did not interact well
with incorporating new messages. It is fixed.
* include/mailutils/imap.h (MU_IMAP_CB_EXPUNGE): New callback
code.
* include/mailutils/sys/imap.h (_mu_imap_message): New member:
msgno.
(_mu_imap_mailbox): Change type of msgs to struct
_mu_imap_message **. Each _mu_imap_message * is registered as
owner for various MU objects, so it is important it does not
change during reallocations.
* libproto/imap/mbox.c (_imap_msg_free): Free the message
itself.
(_imap_attr_clr_flags): Fix bitwise op.
(_imap_mbx_get_message,_imap_realloc_messages)
(aggregate_attributes,_imap_mbx_gensync)
(_imap_fetch_callback): Reflect change in the type of msgs
array.
(_imap_expunge_callback): New callback.
(_imap_mbx_open): Register _imap_expunge_callback.
* libproto/imap/resproc.c (_process_unsolicited_response):
handle the EXPUNGE response.
2019-01-21 Sergey Poznyakoff <gray@gnu.org>
Fix page invalidation in mail.
2019-01-21 Sergey Poznyakoff <gray@gnu.org>
Improve folder handling and expansion in mail. Add convenience
functions to the library.
* configure.ac: Build libmailutils/wicket
* libmailutils/Makefile.am: Likewise.
* libmailutils/base/wicket.c: Move file wicket stuff to ...
* libmailutils/wicket/file.c: ... here
* libmailutils/wicket/noauth.c: New file.
* libmailutils/wicket/Makefile.am: New file.
* include/mailutils/auth.h (mu_noauth_ticket_create)
(mu_noauth_wicket_create): New protos.
* include/mailutils/folder.h (mu_folder_attach_ticket)
(mu_folder_is_local): New protos.
* include/mailutils/mailbox.h (mu_mailbox_attach_ticket): New
proto.
* include/mailutils/sys/folder.h (_mu_folder): Remove flags.
Add new member: is_local.
* libmailutils/mailbox/folder.c (mu_folder_create_from_record):
Set is_local.
(mu_folder_attach_ticket): New function.
(mu_folder_is_local): New function.
* libmailutils/mailbox/mbx_default.c
(mu_mailbox_attach_ticket): New function.
* libmailutils/url/create.c: Allow for trailing / in url.
* libproto/imap/mbox.c (_imap_mbx_open): Do initial scan.
(__imap_msg_get_stream): Initialize clos.size.
* libproto/imap/tests/imapfolder.c: Attach ticket to the
folder.
* mail/cd.c (mail_cd): Expand directory name (~, %, +
notations) prior to use.
* mail/file.c (mail_file): Attach ticket to the mailbox.
* mail/copy.c (append_to_mailbox): Likewise.
* mail/mailline.c: Rewrite directory expansion. Implement fully
functional folder expansion.
* mail/util.c (util_folder_path)
(util_outfolder_name): Rewrite using mu_mailbox_expand_name.
2019-01-18 Sergey Poznyakoff <gray@gnu.org>
Read message headers during initial scan of an imap mailbox.
This considerably speeds up the operation of such tools as mail
(initial loading), frm or from.
* include/mailutils/sys/imap.h (_mu_imap_message): New member:
header_stream.
* libproto/imap/mbox.c (_imap_msg_free): Destroy header_stream.
(_imap_hdr_fill): Rewrite.
(fetch_response_parser): Handle MU_IMAP_FETCH_BODY.
(_imap_mbx_scan): Fetch BODY.PEEK[HEADER].
2019-01-18 Sergey Poznyakoff <gray@gnu.org>
Don't reveal file name with the '0 messages' summary message.
Rationale: file name can contain password.
* mail/mail.c (main): Make sure file is always allocated. Fill
it with 0's and free when no longer needed. Use mail_summary to
display the summary for empty mailbox.
2019-01-18 Sergey Poznyakoff <gray@gnu.org>
Minor change.
* mail/testsuite/lib/mail.exp (default_mail_start): Join
arguments into a string.
2019-01-18 Sergey Poznyakoff <gray@gnu.org>
mail: implement msglist completion.
* mail/mailline.c (msglist_closure_compl): Make the matches
argument optional.
(msglist_compl): Implement using msglist_closure_compl.
2019-01-17 Sergey Poznyakoff <gray@gnu.org>
Improve completion in mail.
This affects the following commands: pipe, file, write, store.
* mail/mail.h (shell_compl): New function.
* mail/mailline.c (ml_command_completion): Change the meaning
of the last argument to command_completion function. All
functions updated.
(msgtype_generator): Take into account '/' that can follow ':'.
Prefix returned values with :.
(header_generator): Append ':/' to the returned strings.
(compl_concat): New function.
(file_compl): Rewrite.
(msglist_closure_compl): New function.
(file_compl_matches,msglist_file_compl,exec_compl): Rewrite.
(shell_compl): New function.
* mail/table.c: Implement completion for pipe and shell
commands.
2019-01-16 Sergey Poznyakoff <gray@gnu.org>
Edit docs.
* doc/texinfo/programs/mail.texi: Reorder material. Document
message states. Rewrite description of message lists. Describe
mailbox argument in file, save, write, etc.
* doc/texinfo/mailutils.texi: Regenerate detailed menu
2019-01-16 Sergey Poznyakoff <gray@gnu.org>
Bugfix.
* libmailutils/base/amd.c (amd_body_stream_readdelim): Fix line
length calculation.
2019-01-16 Sergey Poznyakoff <gray@gnu.org>
mail: fix / and :/ searches in message sets.
* mail/mail.h (msgset_remove): New proto.
* mail/msgset.y (yylex): Make sure to never move cur_p past the
terminating 0 character.
(msgset_append): Eliminated duplicates.
(select_body): Read entire lines. Fix the conditional: return
true if the matching line was found.
2019-01-16 Sergey Poznyakoff <gray@gnu.org>
Split programs.texi into manageable parts.
* NEWS: Update.
* configure.ac: Version 3.5.90
* doc/texinfo/Makefile.am (mailutils_TEXINFOS): Add new files.
* doc/texinfo/programs.texi: Include sections from
programs/*.texi
* doc/texinfo/programs/comsatd.texi: New file.
* doc/texinfo/programs/frm.texi: New file.
* doc/texinfo/programs/guimb.texi: New file.
* doc/texinfo/programs/imap4d.texi: New file.
* doc/texinfo/programs/maidag.texi: New file.
* doc/texinfo/programs/mail.texi: New file.
* doc/texinfo/programs/mailutils.texi: New file.
* doc/texinfo/programs/messages.texi: New file.
* doc/texinfo/programs/mimeview.texi: New file.
* doc/texinfo/programs/movemail.texi: New file.
* doc/texinfo/programs/pop3d.texi: New file.
* doc/texinfo/programs/readmsg.texi: New file.
* doc/texinfo/programs/sieve.texi: New file.
2019-01-15 Sergey Poznyakoff <gray@gnu.org>
Fix the pipe command (mail)
* mail/pipe.c: Always treat last argument as the name of the
command to use.
2019-01-15 Sergey Poznyakoff <gray@gnu.org>
Improve mail documentation.
2019-01-15 Sergey Poznyakoff <gray@gnu.org>
Minor change.
* libmailutils/cli/cli.c: Update copyright year.
2019-01-03 Sergey Poznyakoff <gray@gnu.org>
Update copyright years.
2018-12-25 Sergey Poznyakoff <gray@gnu.org>
Fix typos and improve wording in the docs.
Reported by Dan Jacobson.
2018-12-25 Sergey Poznyakoff <gray@gnu.org>
Fix showenvelope.
* mail/envelope.c (print_stream_envelope): New function. End
output with a newline.
* mail/mail.h: Likewise.
* mail/print.c (mail_print_msg): Print envelope to the created
output stream, instead of mu_strout.
2018-11-09 Sergey Poznyakoff <gray@gnu.org>
Fix obsolete docstring.
* libmailutils/cli/stdcapa.c: Fix description of the argument
syntax for the "debug" statement.
2018-10-27 Sergey Poznyakoff <gray@gnu.org>
Version 3.5.
2018-10-24 Sergey Poznyakoff <gray@gnu.org>
Add missing prototype.
2018-10-24 Sergey Poznyakoff <gray@gnu.org>
sieve: set variables from command line.
The new command line option --variable initializes the RFC 5229
variable.
* NEWS: Update.
* doc/texinfo/programs.texi: Fix description of sieve command
line options.
* include/mailutils/sieve.h (mu_sieve_variable_initialize): New
proto.
* libmu_sieve/runtime.c (sieve_run): Call
mu_i_sv_init_variables to clear and initialize the table of
variables.
* libmu_sieve/sieve-gram.y (mu_sieve_machine_dup): Copy
variables.
(mu_sieve_machine_destroy): Destroy table of variables and
initializer list.
* libmu_sieve/sieve-priv.h (mu_sieve_machine) <init_var>: New
member.
(mu_sieve_variable_initializer): New type.
(mu_i_sv_init_variables): New proto.
* libmu_sieve/variables.c (mu_sieve_variable_initialize): New
function.
(mu_i_sv_copy_variables): Copy initializers as well.
(mu_i_sv_init_variables): New function.
* sieve/sieve.c: New command line option --variable.
* sieve/tests/variables.at: Test the --variable option.
2018-10-23 Sergey Poznyakoff <gray@gnu.org>
Fix static linkage.
* libmailutils/datetime/scantime.c (get_num): static
* mu/libexec/ldflags.c: Make sure libmailutils is linked after
all libmu_ libraries that rely on it.
2018-10-22 Sergey Poznyakoff <gray@gnu.org>
Fix wordsplit command expansion and related tests.
* include/mailutils/wordsplit.h (MU_WRDSO_ARGV): Remove.
* libmailutils/string/wordsplit.c (expcmd): Always split
command line into arguments. This fixes
https://savannah.gnu.org/bugs/?54830
* libmailutils/tests/wordsplit.at: Rewrite command expansion
tests.
* libmailutils/tests/wsp.c: Implement internal commands,
instead of calling shell ones. This fixes
https://savannah.gnu.org/bugs/?54829.
* libmailutils/string/expvar.c: Remove the use of
MU_WRDSO_ARGV.
2018-10-04 Sergey Poznyakoff <gray@gnu.org>
Fix imap client behavior when opening empty mailboxes.
According to RFC 3501 (page 89):
The server should respond with a tagged BAD
response to a command that uses a message
sequence number greater than the number of
messages in the selected mailbox. This
includes "*" if the selected mailbox is empty.
* include/mailutils/sys/imap.h (_mu_imap_mailbox)<total_size>:
Remove unnecessary field.
* libproto/imap/mbox.c (_imap_fetch_callback): Fix array size
calculation.
(_imap_mbx_scan): Don't issue FETCH command if the mailbox is
empty.
2018-08-26 Sergey Poznyakoff <gray@gnu.org>
Implement SCM interface to mailutils filters.
* include/mailutils/guile.h (mu_port_make_from_stream): Remove
unused msg argument. All uses updated.
* libmu_scm/mu_filter.c: New file.
* libmu_scm/Makefile.am: Add mu_filter.c
* libmu_scm/mu_message.c (mu-message-get-port): Add missing
anchor to the docstring.
* libmu_scm/mu_port.c (mu_port): Remove msg.
* libmu_scm/mu_scm.c (mu_scm_init): Call mu_scm_filter_init.
* NEWS: Updated.
2018-08-25 Sergey Poznyakoff <gray@gnu.org>
Bugfix in base64 encoder.
* libmailutils/filter/base64.c (_base64_encoder): Don't return
immediately on eof. The encoder can have some more characters
for output, left over from the previous call.
2018-08-16 Ivan A. Melnikov <iv@altlinux.org>
Force terminating \0 in mh_format result.
Apparently, mu_stream_read is not required to put the
terminating zero into the buffer, so we need to do it in its
caller.
Signed-off-by: Ivan A. Melnikov <iv@altlinux.org>
2018-08-13 Sergey Poznyakoff <gray@gnu.org>
Bugfix in python configuration code.
* configure.ac: Use $PYTHON_CONFIG instead of the hardcoded
python-config name.
2018-07-30 Sergey Poznyakoff <gray@gnu.org>
Version 3.4.91.
* NEWS: Update version number.
* configure.ac: Likewise.
2018-07-30 Sergey Poznyakoff <gray@gnu.org>
Support for Python 3.
Support for v2 is retained for a while. Both the API and the
syntax of the two versions differ considerably enough to keep
both versions apart in parallel directory subtrees, instead of
fiddling with CPP directives and Automake conditionals. So,
instead of prior 'python/' and 'examples/python' we now have
'python/2', 'python/3', and 'examples/python/2' with
'examples/python/3'. The customized loader is modified to
insert the appropriate path to the sys.path.
When Python 2 is definitely gone, the directory structures will
be flattened again, by removing additional version number
subdirectory.
* Makefile.am (SUBDIRS): Add python unconditionally
* configure.ac (PYTHON_MAJOR): New substvar.
(MU_LIB_PY): Change path
(MU_COND_PYTHON2,MU_COND_PYTHON3): New conditionals.
* examples/python/*: Rename to examples/python/2/*
* examples/python/3/Makefile.am: New file.
* examples/python/3/addr.py: New file.
* examples/python/3/auth.py: New file.
* examples/python/3/iconv.py: New file.
* examples/python/3/lsf.py: New file.
* examples/python/3/mailcap.py: New file.
* examples/python/3/mimetest.py: New file.
* examples/python/3/msg-send.py: New file.
* examples/python/3/sfrom.py: New file.
* examples/python/3/url-parse.py: New file.
* include/mailutils/python.h: Remove inclusion of Python.h. It
must included before all other files.
* lib/python.c: Include Python.h
* python/*: Rename to python/2/*
* python/usercustomize.py: Insert path to the appropriate
Python version implementation to the sys.path
* python/3/Makefile.am: New file.
* python/3/libmu_py/Makefile.am: New file.
* python/3/libmu_py/address.c: New file.
* python/3/libmu_py/attribute.c: New file.
* python/3/libmu_py/auth.c: New file.
* python/3/libmu_py/body.c: New file.
* python/3/libmu_py/envelope.c: New file.
* python/3/libmu_py/errno.c: New file.
* python/3/libmu_py/error.c: New file.
* python/3/libmu_py/filter.c: New file.
* python/3/libmu_py/folder.c: New file.
* python/3/libmu_py/header.c: New file.
* python/3/libmu_py/libmu_py.c: New file.
* python/3/libmu_py/libmu_py.h: New file.
* python/3/libmu_py/list.c: New file.
* python/3/libmu_py/mailbox.c: New file.
* python/3/libmu_py/mailcap.c: New file.
* python/3/libmu_py/mailer.c: New file.
* python/3/libmu_py/message.c: New file.
* python/3/libmu_py/mime.c: New file.
* python/3/libmu_py/nls.c: New file.
* python/3/libmu_py/registrar.c: New file.
* python/3/libmu_py/script.c: New file.
* python/3/libmu_py/secret.c: New file.
* python/3/libmu_py/sieve.c: New file.
* python/3/libmu_py/stream.c: New file.
* python/3/libmu_py/url.c: New file.
* python/3/libmu_py/util.c: New file.
* python/3/mailutils/Makefile.am: New file.
* python/3/mailutils/__init__.py: New file.
* python/3/mailutils/address.py: New file.
* python/3/mailutils/attribute.py: New file.
* python/3/mailutils/auth.py: New file.
* python/3/mailutils/body.py: New file.
* python/3/mailutils/c_api.c: New file.
* python/3/mailutils/envelope.py: New file.
* python/3/mailutils/error.py: New file.
* python/3/mailutils/filter.py: New file.
* python/3/mailutils/folder.py: New file.
* python/3/mailutils/header.py: New file.
* python/3/mailutils/mailbox.py: New file.
* python/3/mailutils/mailcap.py: New file.
* python/3/mailutils/mailer.py: New file.
* python/3/mailutils/message.py: New file.
* python/3/mailutils/mime.py: New file.
* python/3/mailutils/nls.py: New file.
* python/3/mailutils/registrar.py: New file.
* python/3/mailutils/secret.py: New file.
* python/3/mailutils/sieve.py: New file.
* python/3/mailutils/stream.py: New file.
* python/3/mailutils/url.py: New file.
* python/3/mailutils/util.py: New file.
2018-07-27 Sergey Poznyakoff <gray@gnu.org>
Bugfix.
* libmailutils/mime/mimehdr.c (_mime_header_parse): Initialize
ws.ws_options prior to modifying it.
2018-07-25 Sergey Poznyakoff <gray@gnu.org>
Add maintainer's makefiles.
2018-07-23 Sergey Poznyakoff <gray@gnu.org>
Support for Berkeley DB versions 5 and 6.
Drop the legacy configure option --with-db2
2018-07-20 Sergey Poznyakoff <gray@gnu.org>
Add test cases missing from the distribution.
* readmsg/tests/Makefile.am (TESTSUITE_AT): Add missing
testcases
2018-06-22 Sergey Poznyakoff <gray@gnu.org>
Minor documentation fix.
2018-06-22 Sergey Poznyakoff <gray@gnu.org>
Fix endianness bug in string to IP conversion.
* libmailutils/cidr/fromsa.c (_mu_inaddr_to_bytes)
(_mu_sockaddr_to_bytes): Fix improper endianness conversion.
* libmailutils/cidr/tosa.c (mu_cidr_to_sockaddr): Simplify
conversion.
2018-06-13 Sergey Poznyakoff <gray@gnu.org>
Fix eventual segmentation violation in imap4d.
The coredump occurred if a recently started child received a
termination signal before initializing iostream.
* imap4d/bye.c (imap4d_bye0): Rename to imap4d_bye_command. All
uses changed.
* imap4d/io.c (io_untagged_response): Check if iostream is
initialized.
2018-06-13 Sergey Poznyakoff <gray@gnu.org>
libmu_scm: fix docs.
2018-06-12 Sergey Poznyakoff <gray@gnu.org>
libmu_scm: add testcases for mu-mime functions (with bugfixes)
* libmu_scm/mu_message.c (mu_scm_message_add_owner): Fix owner
list construction.
* libmu_scm/mu_mime.c (mu-mime-create): Fix a bug: both
arguments are optional now.
* libmu_scm/tests/Makefile.am: Add new tests.
* libmu_scm/tests/testsuite.at: Likewise,
New testcases:
* libmu_scm/tests/mime-add-part.at
* libmu_scm/tests/mime-create.at
* libmu_scm/tests/mime-get-num-parts.at
* libmu_scm/tests/mime-get-part.at
* libmu_scm/tests/mime-multipart-p.at
* libmu_scm/tests/mime-p.at
2018-06-12 Sergey Poznyakoff <gray@gnu.org>
libmu_scm: more tests.
* testsuite/spool/mbox2: New file. Same messages as in mbox1,
but with Mailutils auxiliary headers added. Ideally,
libmailutils should not add any headers to the messages, unless
explicitly requested to do so. Hopefully, I'll fix this in
future.
* testsuite/spool/DISTFILES: Add mbox2 and mime.msg
* libmu_scm/tests/mailbox-append-message.at: New testcase.
* libmu_scm/tests/mailbox-expunge.at: New testcase.
* libmu_scm/tests/message-delete.at: New testcase.
* libmu_scm/tests/message-get-flag.at: New testcase.
* libmu_scm/mu_message.c (mu_scm_message_print): Display flags.
* libmu_scm/tests/Makefile.am: Add new files.
* libmu_scm/tests/mailbox-print.at: Remove the now superfluous
quoting.
* libmu_scm/tests/message-get-part.at: Likewise.
* libmu_scm/tests/testsuite.at (MU_GUILE_CHECK): Quote the
argument to AT_DATA Include new tests.
Changes missing from the previous commit:
* libmu_scm/mailutils/ancilla.scm
* libmu_scm/mu_body.c
* libmu_scm/mu_port.c
2018-06-10 Sergey Poznyakoff <gray@gnu.org>
libmu_scm: minor fixes; add more tests.
* libmu_scm/mailutils/ancilla.scm (string->message)
(file->message): Ise open- call instead of call-with-input to
avoid premature closing of the input port. This has a drawbak
that the port will be actually closed only after the returned
message is destroyed (possibly by the gc).
* libmu_scm/mu_body.c: Use scm_intprint when printing objects.
* libmu_scm/mu_mailbox.c: Likewise.
* libmu_scm/mu_port.c: Likewise.
* libmu_scm/mu_message.c (mu_scm_message_free): Fix destroying
of the underlying mu_message_t object.
* libmu_scm/tests/message-get-num-parts.at: New file.
* libmu_scm/tests/message-get-part.at: New file.
* libmu_scm/tests/message-multipart.at: New file.
* testsuite/spool/mime.msg: New file.
2018-06-09 Sergey Poznyakoff <gray@gnu.org>
Upgrade gint.
This suppresses spurious warnings when generating
guile-procedures.txt
2018-06-09 Sergey Poznyakoff <gray@gnu.org>
Add more libmu_scm tests.
* libmu_scm/Makefile.am (C_SRCS): Add portstream.c
* libmu_scm/mailutils/Makefile.am (EXTRA_DIST): Add ancilla.scm
* libmu_scm/mailutils/ancilla.scm: New file
* libmu_scm/mu_message.c (mu-message-get-header-fields): Fix
operation when called with three arguments.
(mu-message-from-port): New function.
* libmu_scm/portstream.c: New file.
2018-06-08 Sergey Poznyakoff <gray@gnu.org>
Further fixes in the scheme library. Add guile testsuite.
* .gitignore: Ignore .gdbinit
* README: Update.
* configure.ac: Add guile testsuite
* libmu_scm/Makefile.am (SUBDIRS): Add tests.
* libmu_scm/mu_body.c: Update smob support.
* libmu_scm/mu_dbgport.c (mu_scm_make_debug_port): Delegate
buffering to mailutils streams layer.
* libmu_scm/mu_mailbox.c: Update smob support.
(mu-mailbox-more-messages?): Fix reversed return value.
* libmu_scm/mu_message.c: Update smob support.
* libmu_scm/mu_mime.c: Likewise.
* libmu_scm/mu_port.c (mu_port_make_from_stream): Delegate
buffering to mailutils streams layer.
* libmu_scm/tests/.gitignore: New file.
* libmu_scm/tests/Makefile.am: New file.
* libmu_scm/tests/atlocal.in: New file.
* libmu_scm/tests/const.at: New file.
* libmu_scm/tests/mailbox-get-message.at: New file.
* libmu_scm/tests/mailbox-get-size.at: New file.
* libmu_scm/tests/mailbox-get-url.at: New file.
* libmu_scm/tests/mailbox-iterate.at: New file.
* libmu_scm/tests/mailbox-messages-count.at: New file.
* libmu_scm/tests/mailbox-open-exc.at: New file.
* libmu_scm/tests/mailbox-open.at: New file.
* libmu_scm/tests/mailbox-print.at: New file.
* libmu_scm/tests/message-create.at: New file.
* libmu_scm/tests/message-print.at: New file.
* libmu_scm/tests/testsuite.at: New file.
2018-06-02 Sergey Poznyakoff <gray@gnu.org.ua>
Switch to Guile 2.2.0.
* configure.ac" Set minimum supported Guile version to 2.2.0
* libmu_scm/mu_body.c: Rewrite.
* libmu_scm/mu_dbgport.c: Rewrite.
* libmu_scm/mu_mailbox.c: Update types.
* libmu_scm/mu_message.c: Likewise.
* libmu_scm/mu_mime.c: Likewise.
* libmu_scm/mu_port.c: Likewise.
2018-06-02 Sergey Poznyakoff <gray@gnu.org>
Fix absolute name of the "missing" utility.
* am/bison.m4: Use $am_aux_dir. Take care to not expand $SHELL
prematurely.
* am/flex.m4: Likewise.
2018-05-16 Sergey Poznyakoff <gray@gnu.org>
Fix the use of uninitialized variable.
2018-04-18 Sergey Poznyakoff <gray@gnu.org>
Minor fixes in the mailutils-dbm utility.
* mu/libexec/dbm.c (write_quoted_string): Fix expected return
from mu_wordsplit_c_quote_char.
(add_records): Don't break on empty lines.
2018-02-20 Sergey Poznyakoff <gray@gnu.org.ua>
Port wordsplit from grecs
dae43f323db9578e656e3a6c53440e2365421af7.
* libmailutils/string/wordsplit.c (expvar): Gracefully handle
NULL values in an ENV_KV environment.
* include/mailutils/wordsplit.h: Fix typos
2018-01-19 Sergey Poznyakoff <gray@gnu.org.ua>
Version 3.4.90; update copyright years.
2018-01-19 Sergey Poznyakoff <gray@gnu.org.ua>
Add new date/time specifier for headline variable in mail.
The new %D specifier allows the user to supply arbitrary
strftime(3) format string for outputting message date/time.
E.g.:
set headline="%4m %20D{%Y-%m-%dT%H:%M:%S} %18f %s"
* mail/from.c (hdr_date): Take format from data, if supplied.
(compile_headline): Handle the %D specifier
* mail/util.c (util_do_command): Return immediately if command
parsing failed.
* mail/tests/D.at: New testcase.
* mail/tests/Makefile.am: Add new testcase.
* mail/tests/testsuite.at: Likewise.
* NEWS: Document changes.
* doc/texinfo/strftime.texi: New file.
* doc/texinfo/Makefile.am: Add strftime.texi
* doc/texinfo/mailutils.texi: Include strftime.texi
* doc/texinfo/programs.texi: Document the %D format specifier.
2018-01-18 Sergey Poznyakoff <gray@gnu.org>
Fix header field alignment in header output of the mail
command.
* mail/from.c (compile_headline): Honor the alingment setting.
* mail/tests/align.at: New testcase.
* mail/tests/Makefile.am: Add new testcase.
* mail/tests/testsuite.at: Include new testcase.
2018-01-18 Sergey Poznyakoff <gray@gnu.org>
Minor fixes.
* doc/texinfo/mailutils.texi: Fix typos in the imap URL
example.
* libmailutils/locus/linetrack.c: Re-word the comment.
* mimeview/grammar.y: Remove unnecessary assignment.
2017-12-29 Sergey Poznyakoff <gray@gnu.org>
Fix memory management in imap4d.
* imap4d/io.c (imap4d_tokbuf_getline): Add missing index check.
* imap4d/search.c (parse_simple_key): Don't free msgset (it
will be freed later).
2017-12-17 Sergey Poznyakoff <gray@gnu.org>
Update ChangeLog.amend.
2017-12-16 Sergey Poznyakoff <gray@gnu.org>
Fix the operation of CRLF and CRLFDOT filters.
When encoding, these filters used to retain any existing CRLF
sequences untouched on output. As a result, it was not possible
to predict the number of characters output having the number of
characters and number of lines on input. Due to this imap4d
fetch would produce invalid literal output on FETCH command if
the requested stream (usually body), contained a mixture of LF
and CRLF terminated lines. Moreover, encode + decode operations
would not be idempotent in this case.
To fix this, the default behavior of CRLF and CRLFDOT filter in
encode mode is changed to translate each LF to CRLF, no matter
what the prior character was. To invoke the former
"normalizing" behavior, the "-n" option argument is provided
for mu_filter_create_args.
* imap4d/fetch.c (fetch_io): Use raw stream when possible. Use
a temporary CRLF translator to ensure proper positioning if
start offset is specified. This is suboptimal (to say the very
least) and will be fixed as soon as possible.
* imap4d/io.c (io_enable_crlf): New function (hopefully
temporary).
* libmailutils/filter/crlfdot.c: When encoding, retain input
CRLF only if the -n option was used when creating the filter.
Otherwise, translate it to CRCRLF.
* libmailutils/filter/crlfflt.c: Likewise.
* libmailutils/stream/fltstream.c (filter_read): Make sure
mu_filter_lastbuf is always emitted prior to closing the
filter.
(filter_seek): Clear flag_eof.
* libmailutils/tests/Makefile.am (noinst_PROGRAMS): Add dump
and tocrlf.
* libmailutils/tests/crlf.at: New test case.
* libmailutils/tests/crlfdot.at: New test case.
* libmailutils/tests/dump.c: New auxiliary program.
* libmailutils/tests/tocrlf.c: Likewise.
* libmailutils/tests/testsuite.at (MU_FILTER_TEST_NIBBLE)
(MU_FILTER_TEST): New defines.
2017-11-27 Sergey Poznyakoff <gray@gnu.org.ua>
Fix typos.
2017-11-27 Sergey Poznyakoff <gray@gnu.org.ua>
Follow up to 78132d34.
* libmailutils/mime/mime.c (_mime_parse_mpart_message): Avoid
segmentation violation on nbytes==0.
2017-11-23 Sergey Poznyakoff <gray@gnu.org.ua>
MIME: part boundary in not required to be followed by a
newline.
* libmailutils/mime/mime.c: Part boundary can be either
followed by a newline, or appear at the very end of input.
* testsuite/Makefile.am: Add mime01.at
* testsuite/testsuite.at: Include mime01.at.
* testsuite/mime01.at: New file.
* testsuite/mime.at: Update expected output. Don't filter
output through tr & sed.
* testsuite/mimetest.c: Change output to make sure no trailing
whitespace could be produced.
2017-11-18 Sergey Poznyakoff <gray@gnu.org.ua>
Bugfix.
* libmailutils/base/rfc2047.c (mu_rfc2047_encode): Fix
compliance with RFC 2047, 4.3 (page 7). See FIXME, though.
* libmailutils/tests/encode2047.at: Change expected output
2017-11-18 Sergey Poznyakoff <gray@gnu.org>
Fix AM_GNU_MAILUTILS.
* mu-aux/mailutils.m4: Remove support for v. 1.2 and earlier.
2017-11-18 Sergey Poznyakoff <gray@gnu.org>
Fix the use of uninitialized memory.
* mh/mh_alias_lex.l (push_source): Initialize locus range prior
to copying to it.
* libmailutils/cfg/parser.y (mu_cfg_tree_create_node):
Likewise.
* libmu_sieve/util.c: (mu_sieve_value_create): Likewise.
2017-11-10 Sergey Poznyakoff <gray@gnu.org>
Minor fix in MH testsuite.
Running fmtcheck without .mh_profile triggers mh_install, which
surprises the testsuite with unexpected output "I'm going to
create the standard MH path for you." Defining the MH envar to
an existing file name suppresses it.
* mh/tests/fmtcnd00.at: Always define MH prior to starting
fmtcheck.
* mh/tests/fmtcomp.at: Likewise.
* mh/tests/fmtfunc.at: Likewise.
2017-11-10 Sergey Poznyakoff <gray@gnu.org.ua>
Pull wordsplit tests from grecs.
* libmailutils/string/wordsplit.c (_wsplt_alloc_die): use %s
format spec.
(mu_wordsplit_init): Use MU_WRDSX_ constants instead of
numerics.
(expvar): Remove useless gettext.
* libmailutils/tests/wordsplit.at: Update.
2017-11-09 Sergey Poznyakoff <gray@gnu.org.ua>
Minor fix.
* mimeview/lexer.l (yyerror): Use explicit format spec.
2017-11-08 Sergey Poznyakoff <gray@gnu.org.ua>
Improve support of MU_IOCTL_TCPSTREAM.
* libmailutils/stream/iostream.c (_iostream_ctl): Handle
MU_IOCTL_TCPSTREAM
* libmailutils/stream/logstream.c (_log_ctl): Propagate unknown
codes to the transport stream.
* libmailutils/stream/rdcache_stream.c (rdcache_ioctl):
Likewise.
* libmu_auth/tls.c (_tls_ioctl): Likewise.
* libmu_auth/tlsiostr.c (_tls_io_ioctl): Likewise.
2017-11-02 Sergey Poznyakoff <gray@gnu.org.ua>
Version 3.4.
2017-11-01 Sergey Poznyakoff <gray@gnu.org>
Minor fix.
2017-11-01 Sergey Poznyakoff <gray@gnu.org.ua>
Improve socket and SMTP client API.
Split formatting functions into two distinct families.
Functions prefixed with mu_sys_sockadrr deal with struct
sockaddr, whereas those starting with mu_sockaddr deal with
struct mu_sockaddr. Introduce special format for SMTP EHLO.
When sending EHLO to the remote party, use IP address in square
brackets if hostname is empty.
* libmailutils/sockaddr/Makefile.am (libsockaddr_la_SOURCES):
Add fromsock.c
* libmailutils/sockaddr/fromsock.c: New function.
* libmailutils/sockaddr/str.c (mu_sockaddr_format): Rewrite.
(mu_sys_sockaddr_format,mu_sys_sockaddr_to_astr): New
functions.
* include/mailutils/debug.h (mu_sockaddr_to_astr): Remove
prototype.
* include/mailutils/sockaddr.h (mu_sockaddr_format): New enum.
(mu_sockaddr_format): change signature.
(mu_sys_sockaddr_format,mu_sys_sockaddr_to_astr): New
prototypes.
(mu_sockaddr_from_socket): New prototype.
* include/mailutils/stream.h (MU_IOCTL_TCPSTREAM): New ioctl
family;
(MU_IOCTL_TCP_GETSOCKNAME): New ioctl opcode.
* comsat/comsat.c: Use mu_sys_sockaddr_ interface to handle
struct sockaddr.
* lib/tcpwrap.c: Likewise.
* libmailutils/server/ipsrv.c: Likewise.
* libmailutils/server/msrv.c: Likewise.
* libmailutils/stream/tcp.c (_tcp_ioctl): Handle
MU_IOCTL_TCPSTREAM.
* libproto/mailer/smtp_ehlo.c (mu_smtp_ehlo): If hostname is
empty, use IP address in square brackets.
2017-11-01 Sergey Poznyakoff <gray@gnu.org.ua>
Bugfix.
* libmailutils/sockaddr/fromnode.c
[!MAILUTILS_IPV6] (mu_sockaddr_from_node): Convert port to
network order.
2017-10-25 Sergey Poznyakoff <gray@gnu.org.ua>
Bugfix in AM_MAILUTILS macro.
* mu-aux/mailutils.m4 (am_mu_vercmp): Ignore missing version
parts.
2017-10-18 Sergey Poznyakoff <gray@gnu.org.ua>
Version 3.3.
* NEWS: Update.
* configure.ac: Update.
* Makefile.am (dist-hook): Fix conditional.
2017-10-18 Sergey Poznyakoff <gray@gnu.org.ua>
Minor change.
* libmailutils/mailbox/msgsave.c (mu_message_save_to_mailbox):
Open destination in append mode.
2017-10-16 Sergey Poznyakoff <gray@gnu.org>
Reimplement control escapes in mh_format.
This patch makes sure that (1) the value of the "num" register
is not altered by evaluating the condition expressions and
remains visible in the conditional branches, and (2) the value
of the control escape is 1 or 0 depending on whether the last
control condition succeeded or not.
* mh/mh_format.h: Implement numeric stack in the vm.
(mhop_pushn,mhop_popn,mhop_xchgn): New opcodes.
(mh_fvm) <numstack,maxstack,tos>: New members.
* mh/mh_fmtgram.y (ctx_stack): Reallocate as necessary.
(yylex_cond): Handle backslash continuations.
(format_parse): Initialize and free ctx_stack
(codegen_node): Reimplement control escapes. See the comment
for explanation
* mh/mh_format.c (mh_fvm_run): Use mh_string_init to initialize
registers. Initialize stack. Implement push, popn, and xchgn
(extract_labels,mh_format_dump_disass): Handle new opcodes.
* mh/tests/fmtcnd00.at: New testcase.
* mh/tests/Makefile.am: Add new testcase
* mh/tests/testsuite.at: Likewise.
* mh/tests/fmtcomp.at: Fix expected code dumps
2017-10-15 Sergey Poznyakoff <gray@gnu.org>
Fix memory leaks in amd and assoc.
2017-10-10 Sergey Poznyakoff <gray@gnu.org.ua>
Version 3.2.94.
2017-10-10 Sergey Poznyakoff <gray@gnu.org.ua>
Use mu_prtstr to safely print string values.
2017-10-10 Sergey Poznyakoff <gray@gnu.org.ua>
Check for NULL return from mu_address_aget_ and
mu_address_sget_ family functions.
It is possible that these functions return success and place
NULL in the result variable. Make sure this possibility is
checked throughout the code.
* libmailutils/base/usremail.c (mu_set_user_email): Check for
NULL return value from mu_address_[as]get.
* libmailutils/mailbox/msgenv.c (message_envelope_sender)
* libmailutils/tests/addr.c (parse)
* libmu_scm/mu_message.c (mu_scm_message_print):
* libproto/mailer/prog.c (_expand_rcpt)
* libproto/mailer/smtp.c (_rcpt_to_addr)
(mu_address_sget_email)
* maidag/lmtp.c (check_address):
* mail/from.c (hdr_from):
* mail/util.c (util_get_sender):
* mh/mh_format.c (addr_cmp, builtin_proper) (builtin_addr,
builtin_pers, builtin_note) (builtin_mbox, builtin_path,
builtin_formataddr)
* mh/mh_whom.c (scan_addrs):
* libmu_sieve/util.c (mu_sieve_vlist_compare): Skip NULL
returns from retr.
* libmu_sieve/actions.c (check_redirect_loop): Error checking.
* include/mailutils/types.hin (mu_prstr): New function.
* libmu_cpp/address.cc: Use mu_prstr to ensure the printable
representation of string.
* python/libmu_py/address.c: Likewise.
* libmu_scm/mu_address.c (_get_address_part): Likewise.
* libmailutils/string/wordsplit.c (expvar): Treat NULL value as
"".
2017-10-10 Sergey Poznyakoff <gray@gnu.org.ua>
Bugfix in mh.
* mh/mh_fmtgram.y (yylex_func): Accept negative numbers.
2017-10-04 Sergey Poznyakoff <gray@gnu.org.ua>
Minor fix.
* libmailutils/mime/mimehdr.c (_mime_header_parse): Preserve
charset no matter what lang setting is.
2017-10-04 Sergey Poznyakoff <gray@gnu.org.ua>
bugfix in imap4d: INBOX name is case-insensitive.
2017-09-27 Sergey Poznyakoff <gray@gnu.org.ua>
Assume UTC for IMAP internaldate.
* include/mailutils/datetime.h (mu_datetime_tz_utc): New proto.
* libmailutils/datetime/tzutc.c: New file.
* libmailutils/datetime/Makefile.am: Add tzutc.c
* imap4d/fetch.c (_frt_internaldate): Assume UTC for
internaldate.
* libproto/imap/fetch.c (_date_mapper): Likewise.
* mh/send.c: Improve diagnostics.
2017-09-27 Sergey Poznyakoff <gray@gnu.org>
Fix build without libtool.
* libmu_sieve/load.c [!HAVE_LIBLTDL] (mu_sieve_unload_ext):
Dummy function.
[!HAVE_LIBLTDL] (mu_sieve_load_ext, mu_i_sv_load_add_dir): Set
errno. Fix return value.
* mu-aux/gylwrap (yysym): Add more symbols
(dumpme): Skip old contents of the BOOTSTRAP section up to the
next POD keyword.
* mu/libexec/Makefile.am (MUTOOL_LIBRARIES_TAIL): Fix ordering
of libraries.
2017-09-27 Sergey Poznyakoff <gray@gnu.org>
Minor fix.
2017-07-29 Sergey Poznyakoff <gray@gnu.org.ua>
Implement new MH format primitives (for compatibility with
nmh).
* mh/etc/replcomps: Use localmbox instead of me.
* mh/etc/replgroupcomps: Likewise.
* mh/mh.h (mh_get_my_real_name)
(mh_get_my_user_name,mh_my_host): New protos.
(mh_my_email): Change prototype.
* mh/mh_format.c (builtin_me): Use mh_get_my_user_name.
(builtin_myhost,builtin_myname,builtin_localmbox): New
functions.
(builtin_formataddr): Preserve collected data if the address is
not parseable.
(builtin_tab): New functions: myhost, myname, localmbox.
* mh/mh_init.c (mh_local_mailbox): New function.
(mh_get_my_real_name)
(mh_get_my_user_name,mh_my_host): New functions.
* mh/repl.c (set_group): Don't overwrite any prior -form or
-format options.
2017-07-14 Sergey Poznyakoff <gray@gnu.org>
Bugfix.
* mail/send.c (add_body): Increase reference counter of the
copied stream.
2017-07-07 Sergey Poznyakoff <gray@gnu.org>
Bugfixes in MH format code generator.
* mh/mh_fmtgram.y (mh_read_formfile): Remove only the last
trailing newline.
(codegen_node): Don't emit spurious clear register statements
at the end of the "else" branch. Optimize if no "else" branch
is present.
* mh/mh_format.c (mh_fvm_run) <mhop_brzn, mhop_brzs>: Leave the
result of condition evaluation in num.
(builtin_tab): rcpt takes literal argument.
* mh/scan.c (action): Remove unused argument.
* mh/tests/fmtcomp.at: Update the "if-else" test.
2017-07-07 Sergey Poznyakoff <gray@gnu.org>
Simplify mh_fvm_run calling sequence.
The commit 6b16ba19 (in its changes to mh/mh_format.c)
inadvertently broke the operation of inc on folders with gaps
in sequence (UID) numbering. It turns out that the msgno
argument to mh_fvm_run (and msgno member in struct mh_fvm) can
be disposed of. If the caller wants to supply an explicit UID
number of the message, it should use mu_message_set_uid.
* mh/mh.h (mh_fvm_run): Take only two arguments: fvm and
message.
* mh/mh_format.h (mh_fvm) <msgno>: Remove.
* mh/fmtcheck.c (run): Set the uid accessor on the created
message.
* mh/mh_format.c (mh_format_str): Likewise.
(builtin_msg, builtin_cur): Always call mh_message_number.
* mh/inc.c: Update calls to mh_fvm_run
* mh/repl.c: Likewise.
* mh/scan.c: Likewise.
* mh/sortm.c: Likewise.
* mh/tests/inc.at: Check whether inc on folders with gaps in
message UIDs produces the correct output.
2017-07-06 Sergey Poznyakoff <gray@gnu.org>
Bugfix.
* mu-aux/gylwrap (filter): $yyrx is always defined after
ce4b84ab. Use $yyrepl instead.
2017-07-06 Sergey Poznyakoff <gray@gnu.org>
Implement new opool function.
* include/mailutils/opool.h (mu_opool_less): New function.
* libmailutils/base/opool.c: Likewise.
2017-07-06 Sergey Poznyakoff <gray@gnu.org>
Rewrite rfc822 date parser.
* include/mailutils/parse822.h (mu_parse822_day)
(mu_parse822_date,mu_parse822_time): Remove protos.
* libmailutils/address/parse822.c (mu_parse822_date_time):
Rewrite via mu_scan_datetime.
2017-07-06 Sergey Poznyakoff <gray@gnu.org>
Start rewriting parse822.
* include/mailutils/cctype.h (MU_CTYPE_IMSPC)
(MU_CTYPE_NWCTL,MU_CTYPE_IMATM): New classes.
(mu_isimspc,mu_isnwctl,mu_isimatm): New macros
* libmailutils/string/muctype.c: Mark characters from the above
classes.
* include/mailutils/parse822.h (mu_parse822_is_char)
(mu_parse822_is_digit,mu_parse822_is_ctl)
(mu_parse822_is_space,mu_parse822_is_htab)
(mu_parse822_is_lwsp_char,mu_parse822_is_special)
(mu_parse822_is_atom_char,mu_parse822_is_q_text)
(mu_parse822_is_d_text,mu_parse822_is_smtp_q): Rewrite as
inline static functions, using macros from cctype.h
* libmailutils/address/parse822.c: See above.
(parse822_is_atom_char_ex): Remove.
2017-07-06 Sergey Poznyakoff <gray@gnu.org>
Bootstrap gylwrap.
This removes the need for List::Regexp during development
2017-07-06 Sergey Poznyakoff <gray@gnu.org>
Improve gylwrap.
This change allows the user to pre-compile the yyrx expression
in gylwrap so that it no longer requires the List::Regexp
module. Only supplying the --yysym module will require the
module.
* mu-aux/gylwrap: New options --reset and --dump
2017-07-06 Sergey Poznyakoff <gray@gnu.org>
Bugfix.
* am/flex.m4: Add missing 'fi'
2017-07-05 Sergey Poznyakoff <gray@gnu.org>
Fix VI_REVISION and VI_AGE in configure.ac.
2017-07-05 Sergey Poznyakoff <gray@gnu.org>
Fix the nohost MH format function.
2017-07-05 Sergey Poznyakoff <gray@gnu.org>
MH: Rewrite the mymbox function.
* mh/mh_init.c (emailcmp): Rewrite.
(email_match): New function.
(mh_is_my_name): Cache Alternate-Mailboxes and mh_my_email in a
static mu_address_t; use email_match to compare.
* mh/tests/fmtfunc.at: Test mymbox function.
2017-07-04 Sergey Poznyakoff <gray@gnu.org>
Add more fmtfunc tests.
2017-07-04 Sergey Poznyakoff <gray@gnu.org>
Minor fixes.
* mh/mh_fmtgram.y (yyerror): Cast * arguments to int
* mh/mh_format.h (mh_instr_t)<size>: New member.
* mh/tests/fmtfunc.at (FMTFUNC): Enforce Charset:auto.
2017-07-04 Sergey Poznyakoff <gray@gnu.org.ua>
mu_parse_date_dtl: Minor fix.
* libmailutils/datetime/parsedate.y (mu_parse_date_dtl): Set
tm.tm_gmtoff and tm.tm_zone upon return (if present).
2017-07-04 Sergey Poznyakoff <gray@gnu.org.ua>
Improve parsedate & related MH formats.
* libmailutils/datetime/parsedate.y (spec production): If a
non-signed number is given, treat it as a (positive) timezone,
unless tz is already set, or as a year number, unless a year is
already set, or throw an error otherwise.
(mu_parse_date_dtl): Revert sign of the returned utc_offset
* mh/mh_format.c (builtin_tzone): Compatibility fix
* mh/tests/fmtfunc.at: Test more functions.
2017-07-04 Sergey Poznyakoff <gray@gnu.org.ua>
Revamp MH datetime format functions.
* mh/mh_format.c (_parse_date): Use mu_parse_date_dtl instead
of much stricter mu_parse822_date_time. Return more info. All
callers changed
(builtin_sday,builtin_szone): Implemented
* mh/tests/fmtfunc.at: Comment out (temporarily) the tzone test
2017-07-04 Sergey Poznyakoff <gray@gnu.org.ua>
Move parsedate.y from base to datetime library.
2017-07-04 Sergey Poznyakoff <gray@gnu.org.ua>
Improve parsedate parser.
* include/mailutils/datetime.h (MU_PD_MASK_*): New defines,
taken from parsedate.y
(mu_parse_date_dtl): New proto.
* libmailutils/base/parsedate.y: Remove obsolete defines. Move
PD_MASK_ defines to datetime.h; use functions from cctype.h and
cstr.h
(pd_date) <tzname>: New member
(%union): New member tz
(T_ZONE,T_DAYZONE): Change type to <tz>
(zone productions): Set tzname.
(mu_parse_date_dtl): New function. Returns detailed time
information.
(mu_parse_date): Rewrite as an entry point to mu_parse_date_dtl
2017-07-03 Sergey Poznyakoff <gray@gnu.org.ua>
Test mh format date functions.
* mh/mh_format.c (builtin_sday, builtin_szone): Mark as not
implemented
(builtin_zone): Fix output
(builtin_tzone): Fix output
* mh/tests/fmtfunc.at: Test most date functions.
2017-07-03 Sergey Poznyakoff <gray@gnu.org.ua>
Bugfix.
* libmailutils/address/parse822.c (mu_parse822_date_time): Set
tm_yday
2017-07-03 Sergey Poznyakoff <gray@gnu.org.ua>
fmtcheck: use symbolic label names by default.
Actual program counters may differ between different
architecture, so avoid using them in the testsuite.
* mh/fmtcheck.c: New option -pc requires printing program
counters. Unless this option is used, -disass prints only
labels where needed.
* mh/mh.h (mh_format_dump_disass): Change signature.
* mh/mh_format.c (mh_format_dump_disass): Take additional flag
indicating whether to print program counters. Compute and print
program labels, unless this flag is non-zero.
* mh/tests/fmtcomp.at: Don't expect program counters in
disassembled code.
2017-07-02 Sergey Poznyakoff <gray@gnu.org.ua>
MH: fix formataddr.
* mh/mh_fmtgram.y (emit_funcall): Emit mhop_movs acc, reg if
MHA_ACC flag is set.
* mh/mh_format.c (mh_fvm_run): Clear all registers.
(builtin_formataddr): Get previously accumulated addresses from
R_ACC
(builtin_tab): Mark formataddr with MHA_ACC, remove MHA_OPTARG
(mh_format_dump_disass): Account for the new register.
(mh_fvm_destroy): Free all registers.
* mh/mh_format.h: New register R_ACC. It is needed to implement
proper formataddr and concataddr functionality.
* mh/tests/fmtcomp.at: Update.
* mh/tests/fmtfunc.at: Update.
2017-07-02 Sergey Poznyakoff <gray@gnu.org.ua>
MH: fix the nodate format function.
* mh/mh_format.c (builtin_nodate): Call mu_parse822_date_time
directly.
(mh_format_dump_disass): Escape literal strings on output.
* mh/tests/fmtfunc.at: Test nodate.
2017-07-01 Sergey Poznyakoff <gray@gnu.org.ua>
Minor fixes.
2017-07-01 Sergey Poznyakoff <gray@gnu.org.ua>
MH format: fix processing of special functions: putstrf,
putnumf, lit, and num.
* mh/mh_fmtgram.y (node): Replace noprint with printflag.
(escape production): Consult printflag to decide whether to amd
how to print
(funcall production): Rewrite logic
(yylex_func): Make a clear distinction between literals and
inlined ctls, which require leading whitespace, and funcalls
and components, that don't tolerate it.
(emit_funcall): Process special functions separately
* mh/mh_format.c (builtin_tab): Mark lit, num, putstrf, and
putnumf as specials.
* mh/mh_format.h: Revamp MHA_ flags
* mh/tests/fmtcomp.at: Update.
* mh/tests/fmtfunc.at: Add tests for putstrf and putnumf
2017-07-01 Sergey Poznyakoff <gray@gnu.org.ua>
MH: Fix mh_builtin field misnomer.
2017-07-01 Sergey Poznyakoff <gray@gnu.org.ua>
More fixes in MH format parser.
* mh/mh_fmtgram.y (codegen_node): Generate mhop_printlit
instruction for fmtnode_print node with a literal or number
argument.
* mh/mh_format.c (mh_fvm_run): Handle mhop_printlit
* mh/mh_format.h (mhop_printlit): New opcode.
* mh/tests/fmtcomp.at: Update.
* mh/tests/fmtfunc.at: Add more tests.
2017-06-30 Sergey Poznyakoff <gray@gnu.org.ua>
Improve MH format parser.
* mh/fmtcheck.c (main): Assume -dump if no input message and no
-disass is given.
* mh/mh_fmtgram.y: Enable error-verbose mode
(funcall production): Use MHA_OPTARG_NIL flag to provide 0 (or
"") default argument.
(yyerror): Improve location printer
(yylex_initial): Correctly handle %%
* mh/mh_format.c (mh_string_move): Rename to mh_string_copy
(builtin_msg, builtin_cur): Try to obtain message number only
if msgno is 0.
(builtin_tab): Fix definitions of comp, lit, and num
(mh_format_dump_disass): Print width.
* mh/mh_format.h (MHA_OPTARG_NIL): New flag.
* mh/tests/fmtcomp.at: New file.
* mh/tests/fmtfunc.at: New file.
* mh/tests/Makefile.am: Add new files.
* mh/tests/testsuite.at: Likewise.
* mh/tests/atlocal.in (MHETCDIR): New variable.
* mh/tests/scan.at: Test external formats.
2017-06-30 Sergey Poznyakoff <gray@gnu.org.ua>
Introduce explicit data type for MH format virtual machine.
* mh/mh.h (mh_fvm_t): New typedef.
(mh_format): Remove. (mh_fvm_create,mh_fvm_destroy)
(mh_fvm_set_output,mh_fvm_set_width)
(mh_fvm_set_format,mh_fvm_run): New protos.
* mh/mh_format.c: Likewise.
* mh/mh_format.h (mh_machine): Rename to mh_fvm
* mh/fmtcheck.c: Rewrite using mh_fvm_ functions.
* mh/inc.c: Likewise.
* mh/mh_list.c (print_header_value): Likewise.
* mh/repl.c: Likewise.
* mh/scan.c: Likewise.
* mh/sortm.c: Likewise.
2017-06-30 Sergey Poznyakoff <gray@gnu.org.ua>
Restore version output expected by mh-e.
* mh/mh_getopt.c (mh_version_hook): Print version in format
expected by mh-e
(process_std_options): Produce usual version output when
responding to --version
2017-06-29 Sergey Poznyakoff <gray@gnu.org.ua>
Add special flag for debugging MH format parser.
* mh/mh.h (MH_FMT_PARSE_DEBUG): New flag.
* mh/fmtcheck.c: Pass the MH_FMT_PARSE_DEBUG flag, if required.
* mh/mh_fmtgram.y (mh_format_debug): Remove.
(format_parse): Enable debugging if MH_FMT_PARSE_DEBUG flag is
set
2017-06-29 Sergey Poznyakoff <gray@gnu.org.ua>
MH: minor fix in format lexer.
* mh/mh_fmtgram.y (yylex): Don't return empty strings
2017-06-29 Sergey Poznyakoff <gray@gnu.org.ua>
Improve mhl format parser.
* mh/mh_list.c: Keep track of input locations
2017-06-29 Sergey Poznyakoff <gray@gnu.org.ua>
Fix wordsplit MU_WRDSF_INCREMENTAL | MU_WRDSF_NOSPLIT.
* libmailutils/string/wordsplit.c (mu_wordsplit_process_list):
Update wsp->ws_endp in nosplit mode
* libmailutils/tests/wordsplit.at: Test incremental nosplit
2017-06-29 Sergey Poznyakoff <gray@gnu.org.ua>
Bugfix in libdatetime.
* libmailutils/datetime/utcoff.c (mu_utc_offset): Correct the
difference if computed at the break of a day.
2017-06-29 Sergey Poznyakoff <gray@gnu.org.ua>
Improve format parser API.
* mh/scanfmt.c: New file.
* mh/Makefile.am: Add scanfmt.c
* mh/mh.h (mh_list_format): Remove extern
(mh_format_parse): Remove proto.
(mh_format_string_parse,mh_format_file_parse)
(mh_scan_format): New functions.
(mh_audit_open, mh_audit_close): Operate on mu_stream_t,
instead of FILE*.
* mh/mh_fmtgram.y (mh_format_string_parse)
(mh_format_file_parse): New functions.
* mh/mh_format.c (print_fmt_string): Make sure trailing newline
is output, even if it is the Nth character on the line
(N=width).
* mh/mh_getopt.c (mh_opt_parse_formfile)
(mh_opt_parse_format): New functions.
* mh/mh_getopt.h (mh_opt_parse_formfile)
(mh_opt_parse_format): New protos.
* mh/mh_init.c (mh_list_format): Remove.
(mh_audit_open, mh_audit_close): Operate on mu_stream_t,
instead of FILE*.
* mh/fmtcheck.c: Use new format parsing API.
* mh/inc.c: Likewise.
* mh/mh_list.c: Likewise.
* mh/repl.c: Likewise.
* mh/scan.c: Likewise.
* mh/sortm.c: Likewise.
2017-06-27 Sergey Poznyakoff <gray@gnu.org.ua>
MH: Fix repl formats.
* mh/etc/replcomps: Replace calls to %(concat)
* mh/etc/replgroupcomps: Likewise.
* mh/repl.c: Fix embedded format.
2017-06-27 Sergey Poznyakoff <gray@gnu.org.ua>
MH format: fix location tracking and error diagnostics.
* mh/mh_fmtgram.y: Use mu_linetrack_t to keep track of input
location. Handle %; comments.
* mh/mh_format.c (mh_format): Change semantics of mhop_atoi and
mhop_itoa.
(builtin_tab): Fix returns types of trim, date2local, and
date2gmt.
* mh/mh_format.h: Document changes.
* mh/mh_init.c (mh_read_formfile): Read entire file.
2017-06-27 Sergey Poznyakoff <gray@gnu.org.ua>
Fix mu_diag_at_locus_range and mu_vdiag_at_locus_range.
* libmailutils/diag/diag.c (mu_vdiag_at_locus_range): Reset
stream mode.
2017-06-27 Sergey Poznyakoff <gray@gnu.org.ua>
Further work on format vm.
* mh/mh.h (mh_format): Change signature.
(MH_FMT_FORCENL): New define.
* mh/mh_format.h (MHA_OPT_CLEAR): Remove.
(MHA_LITERAL,MHA_VOID): New flags.
(mh_machine) <flags>: New member.
* mh/mh_fmtgram.y (funcall production): Fix argument
interpretation
(else_part production): Allow for empty expression.
(token_function): Use MU_CTYPE_IDENT instead of the more
restrictive MU_CTYPE_ALPHA.
* mh/mh_format.c (node_free): Accept NULL as argument
(emit_funcall): Assign literal arguments to R_ARG registers
(codegen_node): Fix coding the mhop_setn instruction. Clear
both str and reg if the ELSE part of a conditional is empty.
(mh_string_load): Fix size computation.
(mh_string_move): Don't clear the source register.
(mh_format): Reorder parameters, pass flags as 6th parameter.
Emit final newline if MH_FMT_FORCENL is set, unless the last
character output is newline.
(mh_format_str): Rewrite function.
(builtin_lit): Implement
(builtin_friendly): Fix register assignment
(builtin_addr): Pass R_ARG to R_REG verbatim, if it cannot be
parsed as a RFC822 address.
(builtin_decode): Don't clear str reg.
(builtin_concat): Remove. The implementation contradicts the
principles of the format VM; besides, the same functionality
could be easily achieved by using ctls
(builtin_tab): Put additional flags
* mh/fmtcheck.c (run): Update call to mh_format
* mh/inc.c (list_message): Likewise. Emit warning about
not-implemented audit feature.
* mh/mh_list.c (_destroy_value): Remove spurious call to
free().
* mh/repl.c: Fix calls to mh_format and mh_format_parse.
* mh/scan.c: Likewise.
* mh/sortm.c: Likewise.
2017-06-27 Sergey Poznyakoff <gray@gnu.org.ua>
Improve cctype API.
* include/mailutils/cctype.h (MU_CTYPE_IDENT)
(MU_CTYPE_HEADR): New character classes.
(mu_isident,mu_isheadr): New macros.
* libmailutils/string/muctype.c: Mark valid identifier and
header constituents as such.
2017-06-26 Sergey Poznyakoff <gray@gnu.org.ua>
Fix premature push.
2017-06-26 Sergey Poznyakoff <gray@gnu.org.ua>
Start rewriting MH format functions.
* mh/fmtcheck.c: New option -disassemble
* mh/mh.h: Move format-related declarations to mh_format.h
(mh_format_parse): Change signature.
(mh_format): Change signature. (mh_format_dump_code)
(mh_format_dump_disass): New protos.
(mh_decode_2047): Change signature.
* mh/mh_fmtgram.y: Rewrite from scratch. First, build a parse
tree, then use it to generate code.
* mh/mh_format.c: Rewrite from scratch.
* mh/mh_format.h: Move format-related declarations from mh.h
* mh/mh_init.c (mh_decode_2047): Text is const.
* mh/mh_list.c: Fix calls to mh_format_parse and related
objects.
2017-06-26 Sergey Poznyakoff <gray@gnu.org.ua>
Start rewriting MH format functions.
* mh/fmtcheck.c: New option -disassemble
* mh/mh.h: Move format-related declarations to mh_format.h
(mh_format_parse): Change signature.
(mh_format): Change signature. (mh_format_dump_code)
(mh_format_dump_disass): New protos.
(mh_decode_2047): Change signature.
* mh/mh_fmtgram.y: Rewrite from scratch. First, build a parse
tree, then use it to generate code.
* mh/mh_format.c: Rewrite from scratch.
* mh/mh_format.h: Move format-related declarations from mh.h
* mh/mh_init.c (mh_decode_2047): Text is const.
* mh/mh_list.c: Fix calls to mh_format_parse and related
objects.
2017-06-21 Sergey Poznyakoff <gray@gnu.org.ua>
mh: determine output width automatically.
* mh/fmtcheck.c: Take file name as optional argument. Run
format on it, if supplied
* mh/mh.h (mh_width): New proto.
* mh/inc.c: Don't initialize width.
* mh/mh_format.c (mh_format): Use mh_width, if width is 0.
* mh/mh_list.c (mhl_format_run): Use mh_width, if width is 0.
* mh/mh_init.c (mh_width): New function.
* mh/repl.c: Likewise.
* mh/scan.c: Likewise.
* mh/sortm.c: Likewise. New option -width
2017-06-20 Sergey Poznyakoff <gray@gnu.org.ua>
Revert previous commit. Require gettext 0.19.
2017-06-20 Sergey Poznyakoff <gray@gnu.org.ua>
Remove gettext version requirement.
2017-06-20 Sergey Poznyakoff <gray@gnu.org>
Version 3.2.93.
2017-06-20 Sergey Poznyakoff <gray@gnu.org.ua>
Rework emitting source locations in sieve code.
* include/mailutils/locus.h (mu_locus_point_eq): New function.
* libmu_sieve/prog.c (mu_i_sv_code): Emit the
_mu_i_sv_instr_locus if locus changed.
(mu_i_sv_locus): Raise the changeloc flag and set the locus,
instead of immediately emitting location change code.
* libmu_sieve/runtime.c (_mu_i_sv_instr_locus): New function.
(_mu_i_sv_instr_source,_mu_i_sv_instr_line)
(_mu_i_sv_instr_col): Remove.
* libmu_sieve/sieve-priv.h (mu_sieve_machine) <changeloc>: New
member.
2017-06-20 Sergey Poznyakoff <gray@gnu.org.ua>
Bugfix in sieve library.
* libmu_sieve/sieve-gram.y: Add missing assignment to $$ in
testlist production. This fixes improper handling of anyof and
allof
2017-06-20 Sergey Poznyakoff <gray@gnu.org.ua>
Commit missing file.
2017-06-20 Sergey Poznyakoff <gray@gnu.org.ua>
API for formatting message sets on output.
* libmailutils/msgset/print.c (mu_msgset_formats): New global.
(mu_stream_msgset_format): New function.
* include/mailutils/msgset.h (mu_msgset_format): New struct.
(mu_msgset_fmt_imap, mu_msgset_fmt_mh): New defines.
(MU_MSGSET_IGNORE_TRANSERR): New flag
(mu_msgset_copy, mu_msgset_translate): New protos.
(mu_stream_msgset_format, mu_msgset_imap_print): New protos.
(mu_msgset_print): Deprecate.
* libmailutils/imapio/sendmsgset.c: Use mu_msgset_imap_print
instead of mu_msgset_print.
* mu/libexec/imap.c: Likewise.
* libmailutils/msgset/Makefile.am: Add copy.c
* libmailutils/msgset/add.c (mu_msgset_add_range): Translate if
message set mode doesn't match the requested one.
* libmailutils/msgset/sub.c (mu_msgset_sub_range): Likewise.
* libmailutils/msgset/trans.c (_mu_msgset_translate_pair): Act
according to the mode argument.
(mu_msgset_translate): New function.
* libmailutils/tests/msgset.c: New option -mh
* mh/mh_sequence.c (write_sequence): Rewrite.
* testsuite/msgset.c: Optionally translate uids to msgnums and
vice-versa.
2017-06-18 Sergey Poznyakoff <gray@gnu.org>
refile: eliminate refiled messages from all sequences.
* mh/Makefile.am: Add seqelim.c
* mh/mh.h (mh_sequences_elim): New proto.
* mh/seqelim.c: New file.
* mh/refile.c (main): Fixup sequences after refiling.
* mh/rmm.c: Fixup sequences using mh_sequences_elim
2017-06-18 Sergey Poznyakoff <gray@gnu.org>
linetrack: handle #line directives without file name.
* include/mailutils/diag.h (mu_vdiag_at_locus_range): New
proto.
* libmailutils/locus/linetrack.c (mu_linetrack_origin): accept
locus point with mu_file==NULL. Reuse current file name in this
case. This is to simplify handling of #line directives without
file name.
* libmailutils/tests/linetrack.c: Implement #line directive.
* libmailutils/tests/linetrack.at: Add new test.
2017-06-18 Sergey Poznyakoff <gray@gnu.org>
Improve line tracker.
The new version is able to hold input history from several
source lines, which makes it easier to implement #line
directives in lexers.
* include/mailutils/locus.h (mu_linetrack_stat): Remove
start_line
(mu_linetrack_origin): New proto.
* libmailutils/locus/linetrack.c: Improve indexing. Keep track
of several input files.
* libmailutils/tests/linetrack.at: Add new tests.
* libmailutils/tests/linetrack.c: Improve command set.
* mimeview/grammar.y (make_node): Initialize locus
2017-06-17 Sergey Poznyakoff <gray@gnu.org>
Minor change in the testsuite.
* mh/tests/send.at: Make expected text version-independent
2017-06-16 Sergey Poznyakoff <gray@gnu.org.ua>
Version 3.2.92.
2017-06-15 Sergey Poznyakoff <gray@gnu.org>
Make sure all loci are properly initialized before first use.
Clean up semantics of initializers. Each locus type can be
initialized either statically (by assigning the
MU_LOCUS_*_INITIALIZER macro), or dynamically (by calling
mu_locus_*_init function). Whatever method is used, it is
important that it be initialized prior to using any other
mu_locus_* function.
* include/mailutils/locus.h (mu_locus_point_init): Takes single
argument. Returns nothing.
(mu_locus_range_init): New proto.
* libmailutils/locus/locus.c (mu_locus_point_init): Rewrite.
(mu_locus_range_init): New function.
* libmailutils/cfg/parser.y (mu_cfg_alloc_node): Initialize
locus.
* libmailutils/tests/logstr.c: Fix printf argument types.
* libmu_sieve/extensions/moderator.c
(moderator_filter_message): Initialize locus.
* libmu_sieve/sieve-gram.y (node_alloc): Likewise.
* mu/libexec/logger.c (parse_locus_point, set_locus): Likewise.
2017-06-15 Sergey Poznyakoff <gray@gnu.org.ua>
Fix id reference counting.
* include/mailutils/locus.h: Add copyleft.
(mu_ident_stat): New proto.
* include/mailutils/types.hin (mu_locus_DEPRECATED): Update
commit. Include link to the wiki article.
* include/mailutils/yyloc.h: Add copyleft.
* libmailutils/locus/ident.c (mu_ident_stat): New function.
* libmailutils/locus/locus.c (mu_locus_point_init)
(mu_locus_point_copy): Don't touch destination unless setting
mu_file member succeeds.
(mu_locus_range_copy): deinitialize dest before assignment.
* libmailutils/stream/logstream.c (_log_write): Use
mu_locus_range_copy to save locus.
(mu_ioctl_logstream_get_locus_deprecated)
(mu_ioctl_logstream_set_locus_deprecated): Include link to the
wiki article.
* libmailutils/tests/linetrack.c (main): Destroy tracker before
exiting.
* libmailutils/tests/logstr.c: Make it possible to run selected
tests.
2017-06-14 Sergey Poznyakoff <gray@gnu.org.ua>
Require bison and flex.
These are needed only during development cycle, as the created
sources are included in the tarball.
* am/bison.m4: New file.
* am/flex.m4: New file.
* configure.ac: Use MU_PROG_BISON and MU_PROG_FLEX
* mu-aux/gylwrap: Drop support for alternative command line
syntax and the --stdout option.
2017-06-14 Sergey Poznyakoff <gray@gnu.org.ua>
Provide backward compatibility layer for deprecated functions.
* include/mailutils/sieve.h (mu_sieve_compile_text): New proto.
(mu_sieve_compile_buffer): Backward-compatible proto.
* include/mailutils/stream.h
((MU_IOCTL_LOGSTREAM_GET_LOCUS_DEPRECATED)
(MU_IOCTL_LOGSTREAM_SET_LOCUS_DEPRECATED): New defines.
(MU_IOCTL_LOGSTREAM_GET_LOCUS)
(MU_IOCTL_LOGSTREAM_SET_LOCUS): Use external functions to make
sure any references to these are marked as deprecated.
* include/mailutils/types.hin (mu_locus_DEPRECATED): New
struct.
(mu_locus): Define to mu_locus_DEPRECATED
* libmailutils/stream/logstream.c (_log_ctl): Handle the
deprecated ctls.
* libmu_sieve/extensions/moderator.c
(moderator_filter_message): Use mu_sieve_compile_text.
* libmu_sieve/sieve-gram.y (mu_sieve_compile_buffer): Rename to
mu_sieve_compile_text. Re-introduce it as a
backward-compatibility API.
* sieve/sieve.c: Call mu_sieve_compile_text instead of
mu_sieve_compile_buffer.
2017-06-14 Sergey Poznyakoff <gray@gnu.org.ua>
Lex-related fixes.
* mu-aux/gylwrap (@yysym): Add more symbols from lex.
* mh/mh_alias_lex.l (mh_alias_read): Return meaningful value.
2017-06-14 Sergey Poznyakoff <gray@gnu.org.ua>
Bugfixes.
* libmu_sieve/sieve-lex.l: Allocate new ctx structure (restore
accidentally deleted file.
* libmailutils/locus/debug.c: Add missing copyleft.
* libmailutils/locus/genprloc.c: Likewise.
* libmailutils/locus/ident.c: Likewise.
* libmailutils/locus/linetrack.c: Likewise.
* libmailutils/locus/locus.c: Likewise.
* mu-aux/gencl: Likewise.
* mu-aux/gitinfo: Likewise.
* mu-aux/gylwrap: Likewise.
2017-06-13 Sergey Poznyakoff <gray@gnu.org.ua>
Switch mh_aliases to line tracker.
* mh/mh.h (ali_parse_error): Remove.
* mh/mh_alias_gram.y: Simplify parser. Use location tracking.
* mh/mh_alias_lex.l: Switch to mu_linetrack facility
* mh/tests/ali.at: Update expected location.
2017-06-13 Sergey Poznyakoff <gray@gnu.org.ua>
Try to display exact error locations in Sieve diagnostics.
* include/mailutils/sieve.h (mu_sieve_value_t)<locus>: New
field.
* libmu_sieve/util.c (mu_sieve_value_create): Take a pointer to
mu_locus_range. Use it to initialize the locus field.
* libmu_sieve/sieve-gram.y: Pass loci in calls to
mu_sieve_value_create.
* libmu_sieve/actions.c: Use the most specific locus when
displaying the message.
* libmu_sieve/comparator.c: Likewise.
* libmu_sieve/prog.c: Likewise.
* libmu_sieve/variables.c: Likewise.
* sieve/tests/i-numeric.at: Update the expected error location.
2017-06-13 Sergey Poznyakoff <gray@gnu.org.ua>
Rewrite Makefile rules for lex and bison.
The aim is to get rid of the explicit rules and use the
Automake framework as much as possible, without hurting the
flexibility. To this effect, the gylwrap tool is rewritten from
scratch (in Perl). In compatibility mode it takes the same
arguments as the standard ylwrap. Additional configuration is
supplied in the configuration file gylwrap.conf, located in the
directory where the input file resides.
* mu-aux/gylwrap: Rewrite from scratch.
* configure.ac (MU_YLWRAP): New subst variable.
* libmailutils/base/.gitignore: Update.
* libmailutils/base/Makefile.am: Update.
* libmailutils/base/gylwrap.conf: New file.
* libmailutils/cfg/.gitignore: Update.
* libmailutils/cfg/Makefile.am: Use new YLWRAP
* libmailutils/cfg/cfg.h: Remove.
* libmailutils/cfg/gylwrap.conf: New file.
* libmailutils/cfg/lexer.l: Include mailutils/yyloc.h directly.
* libmailutils/cfg/parser.y: Likewise.
* libmu_sieve/Makefile.am: Use new YLWRAP
* libmu_sieve/gylwrap.conf: New file.
* libmu_sieve/sieve.y: Rename to libmu_sieve/sieve-gram.y
* libmu_sieve/sieve.l: Rename to libmu_sieve/sieve-lex.l
* mail/Makefile.am: Use new YLWRAP
* mh/.gitignore: Update.
* mh/Makefile.am: Use new YLWRAP
* mh/gylwrap.conf: New file.
* mh/mh_alias.y: Rename to mh/mh_alias_gram.y
* mh/mh_alias.l: Rename to mh/mh_alias_lex.l
* mh/pick.y: Rename to mh/pick-gram.y
* mimeview/.gitignore: Update.
* mimeview/Makefile.am: Use new YLWRAP
* mimeview/mimetypes.y: Rename to mimeview/grammar.y
* mimeview/gylwrap.conf: New file.
* mimeview/mimetypes.l: Rename to mimeview/lexer.l
* po/POTFILES.in: Update
2017-06-13 Sergey Poznyakoff <gray@gnu.org.ua>
Switch to new locus types.
* include/mailutils/types.hin (mu_locus): Remove.
* include/mailutils/diag.h (mu_diag_at_locus): Remove.
(mu_diag_at_locus_point,mu_diag_at_locus_range): New protos.
* include/mailutils/mailutils.h: Include locus.h
* include/mailutils/stream.h (MU_IOCTL_LOGSTREAM_GET_LOCUS)
(MU_IOCTL_LOGSTREAM_SET_LOCUS): Remove.
* libmailutils/stream/logstream.c (_log_ctl): Reflect this.
* libmailutils/tests/logstr.at: Remove the related test.
* libmailutils/tests/logstr.c: Ditto.
* libmailutils/cfg/Makefile.am: Add new header.
* libmailutils/cfg/cfg.h: New file.
* libmailutils/cfg/format.c: Use mu_locus_range
* libmailutils/cfg/lexer.l: Use the mu_linetrack facility
* libmailutils/cfg/parser.y: Likewise.
* libmailutils/diag/diag.c (mu_diag_at_locus): Remove.
(mu_diag_at_locus_point,mu_diag_at_locus_range): New protos.
* comsat/action.c: Use mu_locus_point and mu_locus_range
instead of the removed mu_locus.
* include/mailutils/auth.h: Likewise.
* include/mailutils/cfg.h: Likewise.
* include/mailutils/sieve.h: Likewise.
* libmailutils/base/wicket.c: Likewise.
* libmailutils/tests/wicket.c: Likewise.
* libmu_auth/radius.c: Likewise.
* libmu_sieve/actions.c: Likewise.
* libmu_sieve/comparator.c: Likewise.
* libmu_sieve/extensions/moderator.c: Likewise.
* libmu_sieve/mem.c: Likewise.
* libmu_sieve/prog.c: Likewise.
* libmu_sieve/require.c: Likewise.
* libmu_sieve/runtime.c: Likewise.
* libmu_sieve/sieve-priv.h: Likewise.
* libmu_sieve/sieve.l: Use the mu_linetrack facility.
* libmu_sieve/sieve.y: Likewise.
* libmu_sieve/util.c: Use mu_locus_point and mu_locus_range
instead of the removed mu_locus
* libmu_sieve/variables.c: Likewise.
* mail/source.c: Likewise.
* mu/libexec/dbm.c: Likewise.
* mu/libexec/logger.c: Likewise.
* mu/libexec/wicket.c: Likewise.
* sieve/sieve.c: Likewise.
* sieve/tests/i-numeric.at: Update expected locations
2017-06-12 Sergey Poznyakoff <gray@gnu.org.ua>
Improve linetrack interface.
* include/mailutils/locus.h (mu_linetrack_rebase): New proto.
* libmailutils/locus/linetrack.c (mu_linetrack_rebase): New
function.
* libmailutils/diag/diag.c (mu_diag_at_locus_range): New
function.
2017-06-12 Sergey Poznyakoff <gray@gnu.org.ua>
Switch mimeview to new locus and linetracker.
* include/mailutils/locus.h (mu_stream_print_locus_point): New
proto.
(mu_locus_range_copy): New proto.
* include/mailutils/yyloc.h (mu_file_print_locus_point)
(mu_file_print_locus_range): New protos.
(YY_LOCATION_PRINT): Redo using mu_file_print_locus_range.
* libmailutils/locus/filprloc.c: New file.
* libmailutils/locus/genprloc.c: New file.
* libmailutils/locus/strprloc.c: New file.
* libmailutils/locus/Makefile.am: Add new files.
* libmailutils/locus/debug.c (mu_stream_print_locus_range):
Remove. Declared elsewhere.
* libmailutils/locus/linetrack.c: use mu_locus_point_set_file,
instead of mu_locus_point_init.
* libmailutils/locus/locus.c: Likewise. (mu_locus_range_copy)P:
New function.
* mimeview/mimetypes.l: Provide rule for \n in ARGSTRING Always
print diagnostics before returning BOGUS
(lex_next_rule): Rewrite. Print verbose diagnostics if
app.trace6 is set.
(mimetypes_close): Deinitialize yylloc.
* mimeview/mimetypes.y: Catch the BOGUS token. Adjust conflict
expectation. Properly reference assigned loci.
(mimetypes_parse): Return 1 if any errors detected.
* mimeview/mimeview.c: Use debug category app instead of mime.
* mimeview/tests/testsuite.at: Add new tests.
* libmailutils/stream/logstream.c (_log_done): Deinitialize
locus range.
2017-06-12 Sergey Poznyakoff <gray@gnu.org>
Start switching lexers to the new line tracker facility.
* include/mailutils/locus.h (MU_LOCUS_POINT_INITIALIZER): New
define
(MU_LOCUS_RANGE_INITIALIZER): New define
(mu_locus_point_set_file, mu_locus_point_init)
(mu_locus_point_deinit, mu_locus_point_copy)
(mu_locus_range_deinit): New protos
* libmailutils/locus/locus.c: New file.
* libmailutils/locus/Makefile.am: Add new file.
* libmailutils/locus/linetrack.c (mu_linetrack_at_bol): New
function.
(mu_linetrack_locus): New function.
(mu_linetrack_advance): Use mu_locus_point_set_file to set the
mu_file field.
* libmailutils/tests/linetrack.c: Initialize and deinitialize
locus range.
* mimeview/mimetypes.l: switch to line tracker
* mimeview/mimeview.h: Use defines from yyloc.h
2017-06-11 Sergey Poznyakoff <gray@gnu.org>
Fix the -nodraftfolder and -nowhatnowproc options.
The commit 744c4a9c didn't take into account the -nodraftfolder
and -nowhatnowproc options, which can be used to cancel the
effect of the corresponding facilities. This commit fixes it.
* mh/mh_getopt.c (mh_getopt_ext): New function.
* mh/mh_getopt.h (mh_getopt_ext): New prototype.
(mh_optinit): New struct.
* mh/tests/comp.at: Test the use of Draft-Folder
* mh/tests/forw.at: Likewise.
* mh/tests/repl.at: Likewise.
* mh/comp.c (main): use mh_getopt_ext to properly process
draftfolder and whatnowproc.
* mh/forw.c: Likewise.
* mh/repl.c: Likewise.
* mh/mh.h (mh_whom): Remove.
(mh_whom_header, mh_whom_file, mh_whom_message): New protos.
* mh/mh_alias.y (mh_read_aliases): Don't read aliases twice.
* mh/mh_whatnow.c (whom): Use mh_whom_file.
* mh/mh_whom.c (mh_whom): Rewrite and rename to mh_whom_file.
(mh_whom_header, mh_whom_message): New functions.
* mh/whom.c: Use mh_getopt_ext. Interpret command line
arguments, depending on whether the draftfile facility is in
use.
2017-06-09 Sergey Poznyakoff <gray@gnu.org.ua>
Fix processing of abbreviated negated boolean options.
It was noted that "mhn -nohead" did not suppress the output of
headers as "mhn -noheaders" did. It turned out that the
negation marker was overwritten while scanning options for
possible matching alternatives. This patch fixes it.
* libmailutils/opt/opt.c (find_long_option): Don't overwrite
the negation attribute of the last found option.
* libmailutils/tests/parseopt.c: New option --headers, to test
the fix.
* libmailutils/tests/parseopt28.at: New testcase.
* libmailutils/tests/Makefile.am: Add new testcase.
* libmailutils/tests/testsuite.at: Include new testcase.
* libmailutils/tests/parseopt*.at: Trivial changes
2017-06-08 Sergey Poznyakoff <gray@gnu.org>
Re-use last invoked editor in MH whatnow.
This fixes a bug introduced in d30e5a07
* mh/mh.h (mh_whatnow_env) <last_ed>: New member
* mh/mh_whatnow.c (_whatnow): Initialize reedit and last_ed
members Free last_ed before returning
(edit): Prefer wh->last_ed over wh->editor
2017-06-08 Sergey Poznyakoff <gray@gnu.org>
Bugfix in mh_whatnow.
* mh/mh_whatnow.c (edit): Disable command expansion in
wordsplit. See also 491bec23.
2017-06-08 Sergey Poznyakoff <gray@gnu.org.ua>
Rename mu_locus_tracker to mu_linetrack.
2017-06-08 Sergey Poznyakoff <gray@gnu.org.ua>
Silence remaining *.[yl] rules in Makefiles.
2017-06-08 Sergey Poznyakoff <gray@gnu.org.ua>
Include new headers to the distribution.
2017-06-08 Sergey Poznyakoff <gray@gnu.org.ua>
Improve locus tracker; provide a testsuite.
* include/mailutils/locus.h (mu_locus_track_stat): New struct.
(mu_locus_tracker_stat): New proto.
(mu_locus_tracker_retreat): Change return type.
* libmailutils/locus/debug.c (mu_stream_vlprintf): Don't print
spurious \n.
(mu_lrange_debug): Fix incorrect call.
* libmailutils/locus/tracker.c (mu_locus_track_create):
Allocate storage for at least two lines of text.
(mu_locus_tracker_stat): New function.
(mu_locus_tracker_advance): Handle empty lines
(mu_locus_tracker_retreat): Add error handling.
* libmailutils/tests/Makefile.am (noinst_PROGRAMS): Add
locktrack.
* libmailutils/tests/tracker.c: Rename to loctrack.c
* libmailutils/tests/testsuite.at: Add new testcase.
* libmailutils/tests/loctrack.at: New test case.
2017-06-08 Sergey Poznyakoff <gray@gnu.org>
Bugfix in mh_whatnow.
2017-06-07 Sergey Poznyakoff <gray@gnu.org.ua>
Fix logstream to support mu_locus_range.
* include/mailutils/locus.h (mu_stream_print_locus_range)
(mu_stream_vlprintf, mu_stream_lprintf, mu_lrange_debug): New
protos.
* include/mailutils/stream.h
(MU_IOCTL_LOGSTREAM_GET_LOCUS_RANGE)
(MU_IOCTL_LOGSTREAM_SET_LOCUS_RANGE): New ioctls.
* include/mailutils/sys/logstream.h (_mu_log_stream): Replace
locus with struct mu_locus_range locrange.
* libmailutils/locus/debug.c: Rewrite.
* libmailutils/locus/ident.c (mu_ident_ref): Accept NULL
argument. Fix initialization.
(mu_ident_deref): Accept NULL argument.
* libmailutils/stream/logstream.c: Rewrite.
* libmailutils/tests/.gitignore: Update.
* libmailutils/tests/Makefile.am: Add new tests.
* libmailutils/tests/testsuite.at: Likewise.
* libmailutils/tests/logstr.at: New testcase.
* libmailutils/tests/logstr.c: New file.
* libmailutils/tests/xscript.at: Minor change.
* sieve/tests/i-numeric.at: Minor change.
2017-06-07 Sergey Poznyakoff <gray@gnu.org.ua>
Fix tests when logical and physical CWD differ.
MH testsuite produced false negatives when run in a directory
accessed by its logical name (symlink). To fix this, avoiding
at the same time the use of non-portable "pwd -P" & "pwd -L",
this commit adds a filter utility that replaces both logical
and physical cwd with a dot on output. The MH testsuite is
updated to use this utility.
* testsuite/cwdrepl.c: New utility
* testsuite/Makefile.am: Build cwdrepl
* testsuite/.gitignore: Update.
* testsuite/cwdrepl.at: New test.
* testsuite/testsuite.at: Include new test.
* mh/tests/atlocal.in (PATH): Add testsuite
(remove_curdir): Remove function.
* mh/tests/comp.at: Use cwdrepl, fix expected output.
* mh/tests/forw.at: Likewise.
* mh/tests/mhn.at: Likewise.
* mh/tests/mhpath.at: Likewise.
* mh/tests/repl.at: Likewise.
2017-06-07 Sergey Poznyakoff <gray@gnu.org>
Begin implementing liblocus.
Liblocus is a part of libmailutils that will provide functions
for manipulating source file locations, for use in lexers,
grammars, etc. This will expand the functionality of the
mu_locus type and logstreams.
* configure.ac: add libmailutils/locus/
* include/mailutils/assoc.h (mu_assoc_install_ref2): New proto.
* libmailutils/base/assoc.c (mu_assoc_install_ref2): New entry
point.
* libmailutils/base/copyfile.c (copy_regular_file): Add
typecasts.
* libmailutils/Makefile.am: Build liblocus
* libmailutils/locus/Makefile.am: New file.
* libmailutils/locus/debug.c: New file.
* libmailutils/locus/ident.c: New file.
* libmailutils/locus/tracker.c: New file.
* libmailutils/tests/Makefile.am: New file.
* libmailutils/tests/tracker.c: New file.
2017-06-06 Sergey Poznyakoff <gray@gnu.org.ua>
Bugfix.
* mh/mh_whatnow.c (edit): Initialize ws.ws_env
2017-06-03 Sergey Poznyakoff <gray@gnu.org>
mimeview: improve parser error recovery.
* mimeview/Makefile.am: Silent rules
* mimeview/mimetypes.l (lex_reset): Remove.
(lex_next_rule): New function.
* mimeview/mimetypes.y: Expect 12 shift/reduce conflicts.
Rewrite the error rule
(yyprint): Print TYPE token correctly
* mimeview/mimeview.h (lex_next_rule): New proto.
2017-06-02 Sergey Poznyakoff <gray@gnu.org.ua>
mh whatnow: allow for arguments in the editor profile value.
* mh/mh_whatnow.c (edit): Make sure ed is always initialized.
Accept command line arguments in the "editor" and "*-next"
values.
2017-06-02 Sergey Poznyakoff <gray@gnu.org.ua>
New wordsplit call: mu_worsplit_append.
* include/mailutils/wordsplit.h (mu_wordsplit_append): New
proto.
* libmailutils/string/wordsplit.c (mu_wordsplit_append): New
function.
* libmailutils/tests/wordsplit.at: Two more tests cases for
mu_wordsplit_append.
* libmailutils/tests/wsp.c: Accept extra arguments to append
using the new function.
2017-06-01 Sergey Poznyakoff <gray@gnu.org.ua>
Revise the mime.types lexer; provide the testsuite.
* am/testsuite.m4: New file.
* configure.ac: Use the MU_CONFIG_TESTSUITE macro.
* mimeview/Makefile.am (SUBDIRS): Add tests
* mimeview/mimetypes.l: Rewrite in three exclusive states.
* mimeview/mimetypes.y: Simplify grammar.
* mimeview/mimeview.c: New option --identify (-i).
* mimeview/mimeview.h: Update.
* mimeview/tests/Makefile.am: New file.
* mimeview/tests/atlocal.in: New file.
* mimeview/tests/bf.c: New file.
* mimeview/tests/testsuite.at: New file.
* README: Update.
* doc/texinfo/programs.texi
2017-06-01 Sergey Poznyakoff <gray@gnu.org.ua>
Bugfix.
* mimeview/mimetypes.y (compare_bytes): Fix improper read size
2017-05-31 Sergey Poznyakoff <gray@gnu.org>
Fix whatnow edit command.
In whatnow shell, edit [program [parameters]] now calls program
with supplied parameters plus the name of the file to edit.
* mh/mh.h (mh_whatnow_env) <reedit>: New member.
* mh/mh_whatnow.c (edit): Rewrite.
* mh/whatnow.c (main): Properly handle argv[1]
* NEWS: Update.
2017-05-31 Sergey Poznyakoff <gray@gnu.org>
mh: check Local-Mailbox setting.
* mh/mh_init.c (mh_my_email): If Local-Mailbox is set, use its
value.
* mh/tests/scan.at: Add test for Local-Mailbox.
2017-05-31 Sergey Poznyakoff <gray@gnu.org>
Fix MH initialization order.
Calls to mh_global_profile_get and similar functions must
appear only after a call to mh_getopt (more properly, after
mh_init and mh_init2 are callead). This sequence was
inadvertently changed by commit e267ac86, due to which comp,
forw, repl and burst stopped reading important information from
.mh_profile. Bug spotted by Pierre-Jean.
* mh/burst.c: Make sure profile variables are accessed after
the profile is read.
* mh/comp.c: Likewise.
* mh/forw.c: Likewise.
* mh/repl.c: Likewise.
* mh/mh.h (mh_whatnow_env_from_environ): Split into two
functions: mh_whatnow_env_from_environ_early, to be called
before mh_getopt, and mh_whatnow_env_from_environ_late, to be
called after it.
* mh/whatnowenv.c: Ditto.
* mh/whatnow.c: Call these two in the right order.
* THANKS: Update.
2017-05-31 Sergey Poznyakoff <gray@gnu.org.ua>
Improve mimeview.
Old short option '-t' renamed to '-f' for consistency (-f
stands for --file in most other utilities). Thus, 'mimeview -f
my.types' reads the file 'my.types'.
The '-t' option is reused as a short equivalent of the new
'--lint' option, which instructs the tool to check the syntax
of the mime.types file and exit, ignoring any surplus command
line arguments.
Added support for priority and regex functions.
Improved debugging output.
* mimeview/mimetypes.l: Rewrite lexer in a cleaner way.
* mimeview/mimetypes.y: Rewrite parser. Track locations. Add
line information to nodes and rules. Improve debugging
* mimeview/mimeview.c: Remove the debug configuration
statement. Using debug { level } provides the same
functionality. Use mu_debug for debugging. New option -t
(--lint). Rename the -t short option to -f.
* mimeview/mimeview.h: Define lexer and parser macros for
location tracking.
* NEWS: Document changes to mimeview utility.
* doc/texinfo/programs.texi: Document changes to mimeview
utility.
* lib/mailcap.c: Use standart mu_debug calls for debugging.
* lib/mailcap.h (display_stream_mailcap): Change last argument:
take a mu_debug_handle_t
* libmailutils/diag/debcat (app): New category.
Application-specific debug
* mail/decode.c (display_submessage): Change invocation of
display_stream_mailcap.
* mail/mailvar.c: Setting "verbose" enables app.trace7,
unsetting it clears app.*
2017-05-26 Sergey Poznyakoff <gray@gnu.org>
Bugfixes in MH show.
* mh/show.c: Set cur before returning. Allow for arguments in
showproc settings. Move to next or prev if invoked with the
corresponding argv[0]
* mh/mh.h (mh_msgset_parse): def argument is const.
(mh_msgset_first_current, mh_msgset_first_uid): Remove proto.
(mh_msgset_first): Change signature.
(mh_msgset_last): New function.
* mh/mh_msgset.c (mh_msgset_first): Return UID or message
number depending on the value of the second parameter.
(mh_msgset_first_current, mh_msgset_first_uid): Remove.
(mh_msgset_last): New function.
* mh/anno.c: Update.
* mh/comp.c: Update.
* mh/folder.c: Update.
* mh/mh_init.c: Update.
* mh/repl.c: Update.
* mh/Makefile.am (install-exec-hook): Link show to prev and
next
2017-05-26 Sergey Poznyakoff <gray@gnu.org>
Implement mu_msgset_first and mu_msgset_last.
* include/mailutils/msgset.h (mu_msgset_first, mu_msgset_last):
New prototypes.
* libmailutils/msgset/Makefile.am: Add new files.
* libmailutils/msgset/first.c: New file.
* libmailutils/msgset/last.c: New file.
* libmailutils/tests/msgset.c: New options for testing the new
functions.
* libmailutils/tests/msgset.at: Test new functions.
2017-04-22 Sergey Poznyakoff <gray@gnu.org>
Bugfix.
* mh/etc/Makefile.am (bindir): Override. Reported by Ken Brown
<kbrown@cornell.edu>
2017-04-22 Sergey Poznyakoff <gray@gnu.org.ua>
Functions for formatting RFC-2231-compliant mail headers
fields.
* include/mailutils/cctype.h (MU_CTYPE_TSPEC): New class.
Represents tspecials as per RFC 2045, section 5.1.
(mu_istspec): New define.
* libmailutils/string/muctype.c (mu_c_tab): Mark tspecials
* include/mailutils/assoc.h (mu_assoc_mark)
(mu_assoc_sweep): New protos.
* libmailutils/base/assoc.c (_mu_assoc_elem): New field: mark
(mu_assoc_mark,mu_assoc_sweep): New functions.
* libmailutils/filter/Makefile.am (libfilter_la_SOURCES): Add
dq.c and percent.c.
* libmailutils/filter/dq.c: New file.
* libmailutils/filter/percent.c: New file.
* include/mailutils/filter.h (mu_percent_filter)
(mu_dq_filter): New externs.
* libmailutils/filter/filter.c (mu_filter_get_list): Register
mu_percent_filter and mu_dq_filter.
* include/mailutils/mime.h (mu_mime_header_set)
(mu_mime_header_set_w): New protos.
* libmailutils/mime/Makefile.am (libmime_la_SOURCES): Add
mimehdrset.c
* libmailutils/mime/mimehdrset.c: New file.
* libmailutils/mime/mime.c (_mime_set_content_type): For
multipart/alternative, remove also all parameters except
charset from the Content-Type header.
* mail/send.c (saveatt): Remove the now unneeded conditionals.
* libmailutils/tests/mimehdr.at: Test formatting functions.
* include/mailutils/stream.h (MU_IOCTL_FILTER_SET_OUTBUF_SIZE):
New ioctl.
* include/mailutils/sys/filter.h (_MU_FILTER_DISABLED)
(_MU_FILTER_EOF): Remove. Use bitfields instead.
(_mu_filter_stream): Remove fltflag. New fields: flag_disabled,
flag_eof, outbuf_size.
* libmailutils/stream/fltstream.c (MFB_BASE) (MFB_CURPTR,
MFB_ENDPTR, MFB_SIZE, MFB_LEVEL) (MFB_POS, MFB_RDBYTES,
MFB_FREESIZE)
(MBF_CLEAR, MBF_FREE): Replace with inline functions.
(init_iobuf): Use the outbuf_size field (unless 0) to set the
output buffer size.
(filter_read): Stop if on success if outbuf_size is set,
without trying to fill the entire buffer.
(filter_ctl): Handle MU_IOCTL_FILTER_SET_OUTBUF_SIZE.
* libmailutils/tests/mimehdr.c: New option -width: format and
print the value assuming given line width.
2017-04-19 Sergey Poznyakoff <gray@gnu.org.ua>
Minor change.
* mail/mail.h: Remove unneeded extern qualifiers.
2017-04-19 Sergey Poznyakoff <gray@gnu.org.ua>
Automatically handle native character sets on input to the mail
utility.
If the mime header is set, then mail will provide the missing
'charset' parameter for each Content-Type header that begins
with 'text/'. Its value will be determined by examining the
'charset' mail variable. If it is set to 'auto' (the default),
the character set will be extracted from the value of the
LC_ALL environment variable. If it is unset, it will be deduced
from the LANG environment variable.
Thus, provided that LC_ALL is set correctly, the following
setting in .mailrc is recommended to ensure that mails in
native character sets will be processed correctly:
set charset=auto mime
In most cases, it can be simplified to just 'set mime'.
* NEWS: Update.
* doc/texinfo/programs.texi: Update the description of the
charset variable.
* mail/mail.h (util_get_charset): New proto.
* mail/send.c (attach_set_content_type): New function.
(attlist_add, add_body): Use attach_set_content_type to set the
content_type field.
* mail/util.c (util_get_charset): New function.
(util_rfc2047_decode): Use util_get_charset.
2017-04-19 Sergey Poznyakoff <gray@gnu.org.ua>
mail: use mailvar_is_true to test boolean values.
2017-04-19 Sergey Poznyakoff <gray@gnu.org.ua>
New option --mime.
* mail/mail.c (mime_option): New variable.
(main): assume --mime if either or both of --content-type and
--content-encoding are set. Set the mime variable if so.
* mail/mail.h (mailvar_is_true): New prototype.
* mail/send.c (add_attachments): Continue if the mime variable
is set.
(add_body): Rewrite, treating the text read from the stdin as
MIME part in itself.
* mailvar.c (mailvar_tab): New variable "mime"
(mailvar_is_true): New function.
* NEWS: Document --mime
* doc/texinfo/programs.texi: Rewrite the Attachments
subsection.
2017-04-19 Sergey Poznyakoff <gray@gnu.org.ua>
Minor changes.
* mail/mail.c (cli_attach): Exit if unable to attach file.
* mail/mail.h (send_attach_file): Change prototype.
* mail/send.c (send_attach_file): Return int.
(add_body): Honor default_content_type
2017-04-18 Sergey Poznyakoff <gray@gnu.org>
fix a typo.
2017-04-18 Sergey Poznyakoff <gray@gnu.org.ua>
Fix semantics of mu_header_set_value and creation of
multipart/alternative MIME.
Until now, mu_header_set_value called with replace=0 prepended
the header to the header list, if a header with such name was
already present. This has been changed. Now, if the header with
the requested name is already present, its action is as
follows:
1. If repl is 0, return MU_ERR_EXISTS
2. Otherwise, replace the header with the new value.
If the header is not present, it is appended to the end of the
header list, instead of putting it at the beginning.
This change is incompatible and breaks the tests, that relied
on a particular field ordering. These are fixed as well.
The use of mu_header_set_value throughout the sources has been
revised to ensure that single-instance headers are never added
twice.
This change also facilitates the second part of this commit,
which fixes creation of the multipart/alternative message by
the mail utility.
* libmailutils/mailbox/header.c (mu_header_set_value): Fix
semantics. If the replace parameter is not set and the header
field with the given name already exists, return MU_ERR_EXISTS
without changing anything. If adding new header, append it to
the end of the header list, instead of pushing it to the top.
* configure.ac: Raise shared library revision number.
* libmu_scm/mu_message.c (mu-message-set-header)
(mu-message-set-header-fields): call mu_header_set_value
explicitly if repl is not set.
* libmu_sieve/extensions/moderator.c: Force replace header mode
when needed.
* libmu_sieve/extensions/vacation.c: Likewise.
* mh/mh_init.c (mh_annotate): Prepend the annotation header.
* mh/mhn.c: Force replace header mode when needed.
* mh/repl.c: Likewise.
* mh/send.c: Likewise.
* libmailutils/tests/modmesg01.at: Change expected header
order.
* libmailutils/tests/modmesg03.at: Likewise.
* mh/tests/mhn.at: Likewise.
* mh/tests/send.at: Likewise.
* sieve/tests/moderator.at: Likewise.
* sieve/tests/redirect.at: Likewise.
* sieve/tests/reject.at: Likewise.
* sieve/tests/vacation.at: Likewise.
* examples/mta.c (message_finalize): Append
X-Authentication-Warning, instead of setting it.
Make sure Content-Disposition is not set for parts of a
multipart/ alternative MIME message. Some mail readers
(notably, yahoo), misinterpret it.
* libmailutils/mime/attachment.c (at_hdr): Use
mu_header_set_value to set Content-Type and
Content-Disposition.
* libmailutils/mime/mime.c (_mime_set_content_type): If the
content type is set to multipart/alternative, remove the
Content-Disposition headers from the message parts.
* mail/send.c (saveatt): Don't set content-disposition for
multipart/alternative, it is now done by the library.
(add_attachments): Warn about ignored headers. Append only
Received and X-* headers, replace others.
(parse_headers): Append headers.
(compose_header_set): Use mu_header_append if COMPOSE_APPEND is
requested.
* mail/util.c (util_header_expand): Use mu_header_append.
2017-04-14 Sergey Poznyakoff <gray@gnu.org.ua>
Bugfix.
* libmailutils/base/assoc.c (merge_sort): Fix last argument in
call to cmp.
2017-04-13 Sergey Poznyakoff <gray@gnu.org.ua>
Send multipart/alternative messages using mail.
The new option --alternative is provided to change the content
type of the composed message to multipart/alternative. The ~/
escape toggles the type between multipart/mixed and
multipart/alternative. In messages of multipart/alternative
type, the Content-Disposition header of all attachments is
reset to "inline".
* libmailutils/mime/mime.c (mu_mime_create): Bugfix: honour the
MU_MIME_MULTIPART_ALT flag.
* mail/mail.c: New option --alternative.
* mail/mail.h (compose_env) <attlist,mime>: New members.
(multipart_alternative): New global.
(send_attach_file): Change return value.
(escape_toggle_multipart_type): New proto.
* mail/send.c (multipart_alternative): New global. Keep the
list of attachments in compose_env_t. Make sure it is freed
when no longer used. Implement the ~/ escape.
* mail/table.c: New escape ~/
* mail/util.c: Use mu_strerror instead of strerror.
* NEWS: Document changes to the mail utility
* doc/texinfo/programs.texi: Likewise.
2017-04-11 Sergey Poznyakoff <gray@gnu.org.ua>
Rewrite the mailutils tool.
The subcommands are re-implemented as standalone binaries
installed to pkglibexecdir. The main binary acts as a
dispatcher.
* configure.ac: Build mu/libexec/Makefile
* include/mailutils/.gitignore: Ignore gitinfo.h
* include/mailutils/opt.h (mu_parseopt_help_stream_create): New
proto.
* libmailutils/cli/cli.c (mu_cli_ext): Honor
MU_PARSEOPT_PROG_NAME setting.
* libmailutils/opt/help.c (mu_parseopt_create_help_stream): New
function. (mu_program_help,mu_program_usage)
(mu_program_version): Use it.
* mu/Makefile.am: Move commands to separate executables under
libexec.
* mu/mu.c: Rewrite.
* mu/dispatch.c: Remove.
* mu/help.c: Remove.
* mu/libexec/.gitignore: New file.
* mu/libexec/Makefile.am: New file.
* mu/libexec/getopt.c: New file.
* mu/getans.c: Move to mu/libexec.
* mu/getarg.c: Likewise.
* mu/getyn.c: Likewise.
* mu/util.c: Likewise.
* mu/verbose.c: Likewise.
* mu/shell.c: Likewise.
* mu/mu.h: Remove.
* mu/libexec/mu.h: New file.
* mu/acl.c: Move to mu/libexec; Rewrite as a standalone
program.
* mu/cflags.c: Likewise.
* mu/dbm.c: Likewise.
* mu/filter.c: Likewise.
* mu/flt2047.c: Likewise.
* mu/imap.c: Likewise.
* mu/info.c: Likewise.
* mu/ldflags.c: Likewise.
* mu/logger.c: Likewise.
* mu/pop.c: Likewise.
* mu/query.c: Likewise.
* mu/send.c: Likewise.
* mu/smtp.c: Likewise.
* mu/stat.c: Likewise.
* mu/wicket.c: Likewise.
* mu/mu-setup.awk: Remove.
* po/POTFILES.in: Update.
2017-04-10 Sergey Poznyakoff <gray@gnu.org.ua>
Bugfix.
* libmailutils/cfg/parser.y (mu_cfg_find_node): Fix spurious
error diagnostics when the node is not found.
2017-04-09 Sergey Poznyakoff <gray@gnu.org>
Version 3.2.91.
2017-04-09 Sergey Poznyakoff <gray@gnu.org>
Remove the Scheme implementation of the Sieve language.
* NEWS: Describe the change.
* doc/texinfo/mailutils.texi: Remove description of sieve2scm
* doc/texinfo/programs.texi: Likewise.
* scheme/Makefile.am: Remove sieve2scm.
* scheme/mimeheader.scm: Remove.
* scheme/numaddr.scm: Remove.
* scheme/redirect.scm: Remove.
* scheme/reject.scm: Remove.
* scheme/sieve-core.scm: Remove.
* scheme/sieve2scm.scmi: Remove.
* scheme/vacation.scm: Remove.
2017-04-08 Sergey Poznyakoff <gray@gnu.org.ua>
movemail: implement --progress-meter option.
2017-04-08 Sergey Poznyakoff <gray@gnu.org.ua>
Improve generation of session identifiers for server programs.
* include/mailutils/acl.h (mu_acl_set_session_id): Remove
proto.
* include/mailutils/server.h (mu_session_id): Remove extern.
(mu_sid): New proto.
* libmailutils/server/sid.c: New file.
* libmailutils/server/Makefile.am: Add sid.c
* libmailutils/server/ipsrv.c (mu_ip_tcp_accept)
(mu_ip_udp_accept): Remove calls to mu_acl_set_session_id.
(mu_ip_server_accept): Make sure output to mu_strerr is
filtered so that session ID is prepended to each line.
(mu_ip_server_loop): Remove.
* libmailutils/server/msrv.c (mu_m_server_check_acl): Remove
call to mu_acl_set_session_id.
* libmailutils/server/server.c (mu_session_id): Remove
variable.
* imap4d/imap4d.c (get_client_address, set_strerr_flt)
(clr_strerr_flt): Remove unused functions.
(imap4d_connection): Simplify.
* pop3d/pop3d.c: Likewise.
2017-04-07 Sergey Poznyakoff <gray@gnu.org>
Fix links in HTML doc generator.
* doc/texinfo/gendocs_template: Fix links.
* doc/texinfo/html.init: Fix the Documentation link.
2017-04-06 Sergey Poznyakoff <gray@gnu.org>
Improve AM_GNU_MAILUTILS autoconf macro.
* mu-aux/mailutils.m4: Don't use packed version representation,
because of eventual numerical overflows. Compare versions
number by number. Define the following additional constants:
MAILUTILS_VERSION_MAJOR, MAILUTILS_VERSION_MINOR, and
MAILUTILS_VERSION_PATCH.
* NEWS: Document changes.
2017-04-06 Sergey Poznyakoff <gray@gnu.org>
Minor improvement in gitinfo.h production.
* Makefile.am: Minor change.
* include/mailutils/Makefile.am (gitinfo.h): Build only if
$(srcdir) and $(builddir) are the same.
* mu-aux/gitinfo.pl: Rename to mu-aux/gitinfo
* configure.ac (GITINFO): Reflect this change
* mu-aux/Makefile.am: Likewise.
2017-04-05 Sergey Poznyakoff <gray@gnu.org.ua>
Ensure stability of merge sort in assoc.
* libmailutils/base/assoc.c (merge): Fix comparison
2017-04-04 Sergey Poznyakoff <gray@gnu.org.ua>
Another improvement in gencl.
* mu-aux/gencl: New option --email.
* Makefile.am: Simplify the ChangeLog command. Use the --email
option.
2017-04-03 Sergey Poznyakoff <gray@gnu.org>
Minor improvements in gencl.
* mu-aux/gencl: Don't use Time::ParseDate. Work over bug in
Text::Wrap 2012.0818. New option --ignore-errors (-i). Ensure
consistent error code.
* Makefile.am (dist-hook): Relax checking for intermediate
releases.
2017-04-03 Sergey Poznyakoff <gray@gnu.org.ua>
Rewrite gencl as an enhanced replacement of
gitlog-to-changelog.
* mu-aux/gencl: Rewritten as a replacement for
gitlog-to-changelog.
* ChangeLog.amend: More spell fixes.
* Makefile.am: Use gencl instead of gitlog-to-changelog.
* doc/ChangeLog.CVS: Spell checking
* gnulib.modules: Remove gitlog-to-changelog.
2017-03-24 Sergey Poznyakoff <gray@gnu.org.ua>
Test transcript streams.
* libmailutils/tests/.gitignore: Update.
* libmailutils/tests/xscript.at: New file.
* libmailutils/tests/xscript.c: New file.
* libmailutils/tests/Makefile.am: Add new files.
* libmailutils/tests/testsuite.at: Include new testcase.
2017-03-23 Sergey Poznyakoff <gray@gnu.org.ua>
Tiny fix.
* include/mailutils/debug.h (MU_ASSERT): Prefix local variable
name with two underscores to diminish the probability of
shadowing.
2017-03-23 Sergey Poznyakoff <gray@gnu.org.ua>
Make sure ChangeLog is built by make.
* Makefile.am: Mark ChangeLog as noinst_DATA to trigger its
rule. Rewrite the ChangeLog rule using a wrapper over
gitlog-to-changelog, which rewrites the file only when needed.
(dist-hook): Fail if there are uncommitted changes.
* mu-aux/gencl: New file.
* maint.mk: Remove.
2017-03-22 Sergey Poznyakoff <gray@gnu.org.ua>
Bugfix.
* libmailutils/stream/xscript-stream.c (print_transcript):
Print closing double-quote after user name in LOGIN statement.
2017-03-21 Sergey Poznyakoff <gray@gnu.org.ua>
Improve maintainer scripts.
* Makefile.am (alpha,alphacheck): Update rules.
* mu-aux/gitinfo.pl: Obtain more data.
2017-03-21 Sergey Poznyakoff <gray@gnu.org.ua>
Minor fix.
2017-03-21 Sergey Poznyakoff <gray@gnu.org.ua>
Bugfixes in NLS code.
* libmailutils/base/lcall.c (mu_lc_all_free): Use str->flags to
determine what fields need to be freed.
(mu_parse_lc_all): Force retrieving language and territory if
charset is requested. Use this to provide a default value, in
case charset cannot be determined. Deallocate the surplus data
afterward
* libmailutils/base/locale.c (mu_charset_lookup): Bugfix.
* mail/util.c (util_rfc2047_decode): Avoid memory leak.
2017-03-21 Sergey Poznyakoff <gray@gnu.org.ua>
Fix imap4d testsuite.
The tests failed if MU_DEFAULT_SCHEME were set to anything, but
mbox.
* imap4d/tests/atlocal.in (make_config): set
.mailbox.mailbox-type=mbox.
* imap4d/list.c (imap4d_list): Use %s as the format.
2017-03-21 Sergey Poznyakoff <gray@gnu.org.ua>
More fixes to mu_cfg_field_map (see afbb33cf).
* libmailutils/cfg/driver.c (mu_cfg_field_map): Use correct
enumeration function depending on the element type. Return
meaningful error.
2017-03-20 Sergey Poznyakoff <gray@gnu.org.ua>
Housekeeping: implement a tool for producing intermediate alpha
tarballs.
Intermediate tarballs have the same version number as initial
alpha version, to which is appended a suffix "-N", where N is
the number of commits between the current git HEAD and the
original alpha release.
Additionally, the --version (or -version, for MH) output has
been changed to include the N and the git description (for all
releases, but stable).
* .gitignore: Update.
* Makefile.am: Remove git-describe and git-describe.h goals.
(alpha, alphacheck): Rewrite.
* configure.ac (GITINFO): New subst variable.
* include/mailutils/Makefile.am (gitinfo.h): New built source.
* libmailutils/cli/cli.c: Include gitinfo.h
(mu_version_hook): Rewrite.
* mh/mh_getopt.c: Include gitinfo.h
(mh_version_hook): Rewrite.
* mu-aux/gitinfo.pl: New file.
* mu-aux/Makefile.am (EXTRA_DIST): Add gitinfo.pl
* mu/Makefile.am (mu-setup.c): Add dependency
* testsuite/testsuite.inc (MUT_VERSION): Account for changes in
version output.
2017-03-20 Sergey Poznyakoff <gray@gnu.org.ua>
Fix pop3d command parser (complement afda9ba4)
* pop3d/cmd.c (command_table_head): Remove. Use command_table
instead. All uses changed.
* pop3d/stls.c (pop3d_stls): Fail if TLS is not requested.
2017-03-20 Sergey Poznyakoff <gray@gnu.org.ua>
New itrctl request: mu_itrctl_count.
* include/mailutils/iterator.h (mu_itrctl_req)
<mu_itrctl_count>: New request type.
* libmailutils/base/assoc.c (itrctl): Support mu_itrctl_count.
* libmailutils/list/iterator.c (list_itrctl): Likewise.
* libmailutils/mailbox/hdritr.c (hdr_itrctl): Likewise.
* libmailutils/mailbox/mbxitr.c (mbx_itrctl): Likewise.
* libmailutils/base/opool.c (opitr_itrctl): New function -
support mu_itrctl_count.
(mu_opool_get_iterator): Register opitr_itrctl.
* libmailutils/diag/debug.c (list_itrctl): Return 1-based
position indices on mu_itrctl_tell. Support mu_itrctl_count.
2017-03-19 Sergey Poznyakoff <gray@gnu.org>
Fix a bug in field-map handling.
* libmailutils/cfg/driver.c (parse_mapping): Fix expected value
type.
* libmu_auth/sql.c (get_field): Remove left-over mu_assoc_ref
call (see 622bc770).
2017-03-18 Sergey Poznyakoff <gray@gnu.org>
Rewrite TLS support.
The new implementation allows for per-server certificates.
* libmu_auth/Makefile.am: Build tls support depending on the
value of MU_COND_GNUTLS.
* libmu_auth/notls.c: New file.
* libmu_auth/tls.c: Rewrite.
* libmu_auth/tlsiostr.c: New file.
* libmu_auth/tlsvar.c: New file.
* libmu_auth/tlsconf.c: New file.
* include/mailutils/sys/tls-stream.h (_mu_tls_stream): New
members: session_type, conf, cred.
(mu_tls_io_stream_create): New proto.
* include/mailutils/tls.h (mu_tls_module_config): Remove
definition.
(mu_tls_config): New structure.
(mu_tls_server_stream_create): Remove proto.
(mu_tls_cert_file_checks) (mu_tls_key_file_checksr)
(mu_tls_ca_file_checks): New globals (MU_TLS_CERT_FILE_CHECKS)
(MU_TLS_KEY_FILE_CHECKS)
(MU_TLS_CA_FILE_CHECKS): New defines.
(mu_tls_stream_create): New proto.
(mu_tls_config_status): New constants.
(mu_tls_check_config): Remove.
(mu_tls_config_check): New function.
* include/mailutils/server.h (mu_m_server_preflight_fp): New
typedef.
(mu_m_server_set_preflight): New proto.
* libmailutils/diag/debcat (tls): New category.
* libmailutils/server/ipsrv.c (mu_ip_server_get_data): New
function.
* libmailutils/server/msrv.c (_mu_m_server) <preflight>: New
method.
(mu_m_server_set_preflight): New function.
(mu_m_server_destroy): Destroy the srvlist.
(open_connection): New function.
(mu_m_server_run): Remove from srvlist only those servers that
failed to open. Run preflight check, if registered.
* include/mailutils/cfg.h (mu_cfg_section): New member: data.
* libmailutils/cfg/driver.c (dup_container): Copy the "data"
pointer.
(mu_cfg_section_add_params): Preserve original pointer and
offset when necessary.
* libmailutils/cfg/parser.y (_scan_tree_helper): Use the
section data pointer (if set) as data target.
* configure.ac (MU_COND_GNUTLS): New conditional.
* imap4d/commands.c: Remove #ifdef WITH_TLS preprocessor
conditional.
* imap4d/imap4d.c (tls_mode): Remove variable.
(imap4d_srv_config): Move definition to the header file. Remove
#ifdef WITH_TLS preprocessor conditionals. Rename the tls
configuration statement to tls-mode. Add new subsection
.server.tls; Remove the legacy tls-required configuration
statement.
(imap4d_mainloop): Change signature: take a pointer to the
struct imap4d_srv_config as the 3rd argument, Use the
cfg->tls_mode member to decide on TLS state.
(main): Call mu_tls_cfg_init. Install server preflight checker.
* imap4d/imap4d.h: Remove #ifdef WITH_TLS preprocessor
conditionals.
(imap4d_srv_config): Moved from imap4d.c New member: tls_conf
(imap4d_session): New member: tls_conf
(global_tls_conf): New global.
(io_setio, imap4d_init_tls_server): Change prototypes.
* imap4d/io.c (io_setio): Change signature: take a pointer to
the struct mu_tls_config as the 3rd argument. Rewrite TLS
support.
(imap4d_init_tls_server): Take a pointer to the struct
mu_tls_config.
* imap4d/starttls.c (tls_available, tls_done): Remove globals.
(global_tls_conf): New global.
(imap4d_starttls): Keep TLS state in the session.
(tls_encryption_on): Likewise.
(starttls_init): Rewrite as a mserver preflight check function.
* pop3d/capa.c: Remove #ifdef WITH_TLS preprocessor
conditional.
(capa_stls): Rewrite.
* pop3d/cmd.c (global_tls_conf): New global.
(stls_preflight): New function.
(pop3d_error_string): Rewrite using char ** array.
* pop3d/extra.c (pop3d_setio): Take a pointer to struct
mu_tls_config as the 3rd argument. Decide on TLS using it.
(pop3d_init_tls_server): Take a pointer to struct
mu_tls_config.
* pop3d/pop3d.c: Rename the tls configuration statement to
tls-mode. Add new subsection .server.tls; Remove the legacy
tls-required configuration statement. (pop3d_mainloop) Take a
pointer to struct mu_tls_config as the 3rd argument. Decide on
TLS using it.
(main): Call mu_tls_cfg_init. Install server preflight check.
* pop3d/pop3d.h (pop3d_session): New member tls_conf.
(pop3d_srv_config): New definition.
(global_tls_conf): New extern.
* pop3d/stls.c: Rewrite TLS support.
* NEWS: Document new features.
* configure.ac: Version 3.2.90.
* doc/texinfo/programs.texi: Update.
2017-03-11 Sergey Poznyakoff <gray@gnu.org>
Minor changes.
2017-03-11 Sergey Poznyakoff <gray@gnu.org>
Version 3.2.
2017-03-06 Sergey Poznyakoff <gray@gnu.org>
Fix NULL dereference.
* libmailutils/mime/mimehdr.c (mu_mime_param_free): Check if
argument is NULL.
2017-02-18 Sergey Poznyakoff <gray@gnu.org>
'Q' encoding: encode question mark properly; limit length of
encoded words.
* libmailutils/base/rfc2047.c (mu_rfc2047_encode): Limit length
of encoded word to 75 bytes.
* libmailutils/filter/qpflt.c: Treat '?' as special character
in Q encoder.
* libmailutils/tests/encode2047.at: Add more tests.
* libmailutils/tests/encode2047.c: Use mailutils string I/O
2017-02-17 Sergey Poznyakoff <gray@gnu.org>
Fix memory leak in mu_stream_destroy.
* libmailutils/stream/stream.c (mu_stream_destroy): Free buffer
space.
(mu_stream_set_buffer,mu_stream_getdelim): Use stdlib
allocation functions instead of mu wrappers.
2017-02-17 Sergey Poznyakoff <gray@gnu.org>
Fix handling of ambiguous command line options.
The approach used so far failed to recognize ambiguous
abbreviations located in different groups. It also didn't work
when MU_PARSEOPT_NO_SORT was requested. This commit fixes it by
keeping an additional array of indices to long options. The
array is sorted so that its elements produce a
lexicographically ascending list of long options.
* include/mailutils/opt.h (mu_parseopt): New members
po_longcnt, po_longidx keep a sorted array of indices to
po_optv with long options.
* libmailutils/opt/opt.c (find_long_option): Iterate over
po_longidx.
(parseopt_init): Initialize and sort po_longidx.
(mu_parseopt_free): Free po_longidx.
* libmailutils/tests/parseopt.c: Add three more potentially
ambiguous options
* libmailutils/tests/parseopt26.at: New testcase.
* libmailutils/tests/parseopt27.at: New testcase.
* libmailutils/tests/Makefile.am: Add new testcases.
* libmailutils/tests/testsuite.at: Likewise.
2017-02-05 Sergey Poznyakoff <gray@gnu.org>
Remove unneeded file.
* sieve/examples/.gitignore: Remove.
2017-01-30 Sergey Poznyakoff <gray@gnu.org.ua>
sieve: add a locus indicating end of input.
The new node type mu_sieve_node_end is introduced to explicitly
mark end of the parse tree. When generating code, this node
triggers insertion of _mu_i_sv_instr_source/_mu_i_sv_instr_line
before the end of code marker. This, in turn, ensures that a
correct location is reported for implicit keep, if logging is
enabled.
* libmu_sieve/sieve-priv.h (mu_sieve_node_end): New node type.
(mu_sieve_node_list): New type (from struct node_list in
sieve.y)
* libmu_sieve/sieve.y (node_list_add): New function.
(input production): Add mu_sieve_node_end at the end of the
tree.
2017-01-30 Sergey Poznyakoff <gray@gnu.org.ua>
Log sieve source location in maidag.
* lib/sieve.c (_sieve_action_log): Log source location
2017-01-30 Sergey Poznyakoff <gray@gnu.org.ua>
Fix sieve logging in maidag.
* maidag/maidag.c (sieve_debug_flags)
(sieve_enable_log): Remove.
* maidag/script.c (apply_script): Check for
mu_script_sieve_log.
2017-01-26 Sergey Poznyakoff <gray@gnu.org.ua>
Allow for "INBOX." namespace.
* imap4d/imap4d.h (io_send_astring): New proto.
* imap4d/io.c (io_send_astring): New function.
* imap4d/list.c (list_fun): Use io_send_astring.
(list_ref): Special handling for empty wcard
(imap4d_list): Remove special handling for empty wcard and
INBOX. Leave that to list_ref. This makes it possible to
declare namespaces like "INBOX." ("." being the delimiter).
* imap4d/lsub.c (imap4d_lsub): Use io_send_astring.
* imap4d/namespace.c (namespace_translate_name): Check for
declared namespace first.
2017-01-26 Sergey Poznyakoff <gray@gnu.org.ua>
Minor fix.
2017-01-26 Sergey Poznyakoff <gray@gnu.org.ua>
Improve description of variables useful in namespace directory
statements.
2017-01-26 Sergey Poznyakoff <gray@gnu.org.ua>
Minor fix.
* imap4d/list.c (list_ref): Use mu_imap_wildmatch_ci to check
for a request matching INBOX.
* include/mailutils/imaputil.h (mu_imap_wildmatch_ci): New
prototype.
* libmailutils/imapio/wildmatch.c (mu_imap_wildmatch_ci): New
function.
2017-01-24 Sergey Poznyakoff <gray@gnu.org.ua>
Further improvements of IMAP LIST functionality.
* imap4d/list.c (list_fun): Ignore names that contain delimiter
as part of their name (untranslatable names); Don't insert
spurious separators.
(list_ref): Make sure a pathnames are properly separated from
namespace prefixes.
(imap4d_list): Fix eventual use of uninitialized pfx.
* imap4d/namespace.c (prefix_translate_name): Allow for
NS_OTHER prefixes ending with a delimiter.
(extract_username): Return NULL if prefix without trailing
delimiter was used.
* imap4d/tests/atlocal.in (make_config): Add more namespace
prefixes.
* imap4d/tests/list.at: Add more tests.
* libmailutils/string/expvar.c (exp_getvar): Return
MU_WRDSE_UNDEF if the variable is defined, but has NULL value.
2017-01-24 Sergey Poznyakoff <gray@gnu.org.ua>
imap4d: forbid to treat namespace root as a mailbox.
* imap4d/namespace.c (namespace_get_name): Return NULL if name
is the same as the returned prefix
2017-01-24 Sergey Poznyakoff <gray@gnu.org>
Simplify the namespace interface.
* imap4d/namespace.c (prefix_translate_name): Remove the url
parameter. All uses changed.
(namespace_translate_name): Likewise.
(i_translate_name): Rename to translate_name. Remove the url
and ns parameters. All uses changed.
* imap4d/imap4d.h (namespace_translate_name): Change signature.
2017-01-24 Sergey Poznyakoff <gray@gnu.org>
imap4d: uniformly use mailbox name and record for opening
mailboxes.
This avoids problems with escaping pathnames that contain
characters specific for URLs
* imap4d/select.c (imap4d_select0): Don't use mailbox URL.
* lib/manlock.c (manlock_open_mailbox_from_record): New
function.
* lib/muaux.h (manlock_open_mailbox_from_record): New proto.
2017-01-23 Sergey Poznyakoff <gray@gnu.org.ua>
Fix memory allocation.
2017-01-23 Sergey Poznyakoff <gray@gnu.org.ua>
imap4d: fix list.
* imap4d/list.c (refinfo) <refptr>: const pointer.
(list_fun): Don't insert spurious delimiter between the prefix
and the value.
(list_ref): New static function. Actually list a normalized
ref/wcard pair.
(imap4d_list): Correctly handle wildcard part starting with
namespace prefixes
* imap4d/namespace.c (prefix_translate_name): If a prefix ends
with a delimiter, allow its use without trailing delimiter in
ref. E.g.
LIST "~" "%"
for prefix "~/" is quite OK.
* imap4d/tests/atlocal.in: Fix prefix declaration.
2017-01-23 Sergey Poznyakoff <gray@gnu.org>
Fix listing names with escapable characters.
* imap4d/io.c (io_send_qstring): Fix condition
* imap4d/list.c (list_fun): Use io_send_qstring to print names.
* imap4d/lsub.c (imap4d_lsub): Likewise.
2017-01-22 Sergey Poznyakoff <gray@gnu.org>
Bugfix.
* imap4d/namespace.c (namespace_init): Provide record for
default "" prefix.
2017-01-22 Sergey Poznyakoff <gray@gnu.org>
imap4d: revamp namespace translation.
Instead of translating names to full mailbox URLs, translate
them to the filesystem pathname and record (mu_record_t) that
should be used when creating the mailbox. Never use
mu_mailbox_create_default.
This patch also fixes memory leaks in some functions (the
return value from namespace_get_url was never freed).
* imap4d/imap4d.h (namespace_get_url): Remove.
(namespace_get_name): New proto.
* imap4d/namespace.c (namespace_init): Always initialize the
pfx->record member. This requires that the default record be
initialized.
(namespace_get_url): Remove.
(namespace_get_name): New function.
* imap4d/create.c: Use namespace_get_name and
mu_mailbox_create_from_record to create mailboxes. Fix folder
creation.
* imap4d/append.c: Use namespace_get_name and
mu_mailbox_create_from_record to create mailboxes.
* imap4d/copy.c: Likewise.
* imap4d/delete.c: Likewise.
* imap4d/quota.c: Likewise.
* imap4d/rename.c: Likewise.
* imap4d/status.c: Likewise.
2017-01-22 Sergey Poznyakoff <gray@gnu.org>
Bugfix in IMAP LIST.
* imap4d/list.c (list_fun): List matching directories.
2017-01-21 Sergey Poznyakoff <gray@gnu.org.ua>
Bugfix.
* libmu_auth/ldap.c (_construct_attr_array)
(_mu_entry_to_auth_data): Fix types of iterator return values.
2017-01-20 Sergey Poznyakoff <gray@gnu.org.ua>
Update README-alpha.
2017-01-20 Sergey Poznyakoff <gray@gnu.org.ua>
Update documentation. Use the namespace name "personal",
instead of "private".
2017-01-19 Sergey Poznyakoff <gray@gnu.org>
Add tests for mu_str_expand and mu_str_vexpand functions.
* libmailutils/string/expvar.c (exp_shell): Fix out-of-buffer
read when used without arguments.
(mu_str_expand): Improve error handling.
* libmailutils/tests/testsuite.at (MU_GENERIC_TEST_CMD): New
macro. Include exp.at
* libmailutils/tests/vexp.c: New file.
* libmailutils/tests/Makefile.am: Build vexp. Add exp.at
* libmailutils/tests/exp.at: New file.
2017-01-19 Sergey Poznyakoff <gray@gnu.org.ua>
Provide functions for expanding string using mu_assoc_t table.
The functions are used wherever variables can be expected, most
notably in configuration statements, such as ldap, namespace
(imap4d), etc. Apart from expanding variables it also provides
command expansion $(command args...)
The commands currently available are:
domainpart ARG splits its argument on the first occurrence of
@
and returns the part after it.
localpart ARG splits its argument on the first occurrence of @
and returns the part before it.
shell CMD ARG... runs shell command CMD and returns its output
* include/mailutils/cstr.h (mu_str_expand, mu_str_vexpand): New
protos.
* libmailutils/string/expvar.c: New file.
* libmailutils/string/Makefile.am: Add expvar.c
* libmailutils/tests/exp.c: New file.
* libmailutils/tests/Makefile.am: Add exp.c
* imap4d/imap4d.c (namespace_cfg_init): Fix docstring.
* imap4d/namespace.c (namespace_translate_name): Use
mu_str_expand.
* libmailutils/mailbox/mbx_default.c
(mu_construct_user_mailbox_url): Use mu_str_vexpand.
* libmu_auth/ldap.c (_mu_ldap_search): Likewise.
* libmu_auth/radius.c (_expand_query): Likewise.
* libmu_auth/sql.c (mu_sql_expand_query): Likewise.
* mu/shell.c (mutool_prompt_env): Remove.
(shell_prompt): Rewrite
(input_line_interactive): Use mu_str_expand.
(mutool_shell_prompt_assoc): New function.
* mu/mu.h (mutool_shell_prompt_assoc): New proto.
* mu/imap.c (imap_prompt_env): Use mutool_shell_prompt_assoc.
* mu/pop.c (pop_prompt_env): Likewise.
* mu/smtp.c (smtp_prompt_env): Likewise.
2017-01-18 Sergey Poznyakoff <gray@gnu.org.ua>
Minor change.
* libmailutils/mime/mime.c: Fix formatting
2017-01-17 Sergey Poznyakoff <gray@gnu.org.ua>
Remove unnecessary mu_message_t flag (MESSAGE_MIME_OWNER)
2017-01-17 Sergey Poznyakoff <gray@gnu.org.ua>
Minor changes.
* configure.ac: Set version 3.1.91
* NEWS: Update.
* doc/texinfo/programs.texi: Minor change.
* libmailutils/mime/mime.c (_mime_part_size)
(_mime_body_lines): Fix counting. Return 0 if MIME is empty.
2017-01-16 Sergey Poznyakoff <gray@gnu.org>
Improve mu_attachment_copy_ interface.
* libmailutils/mime/attachment.c
(mu_attachment_copy_from_stream)
(mu_attachment_copy_from_file): Remove the encoding parameter.
Take the encoding to use from the value of the
Content-Transfer-Encoding header. Return EINVAL if it is not
present.
* include/mailutils/message.h (mu_attachment_copy_from_stream)
(mu_attachment_copy_from_file): Change signature. All uses
changed.
2017-01-16 Sergey Poznyakoff <gray@gnu.org>
Improve the --skip-empty-attachment functionality.
This also includes small bugfixes in the MIME library code.
The --skip-empty-attachment option now affects the original
body as well. If the option is in effect, and the body is
empty, it will not be included to the composed message.
* libmailutils/mime/mime.c (_mime_body_stream_read): Return EOF
if there are no parts in the message.
(mu_mime_get_num_parts): If message is not multipart, report 1
part without setting mime->nmtp_parts. Setting it caused
coredump in other MIME functions (namely, in mu_mime_add_part.
* mail/send.c (add_body): New function. Adds original body to
the MIME, honoring the --skip-empty-attachment option.
* doc/texinfo/programs.texi: Update.
2017-01-16 Sergey Poznyakoff <gray@gnu.org>
imap4d: log client identity.
* imap4d/id.c (eat_args): Log the client identity using the
info channel.
* imap4d/list.c: tiny change
2017-01-16 Sergey Poznyakoff <gray@gnu.org>
mail: new option --skip-empty-attachments.
* libmailutils/cli/cli.c (mu_cli): Use "no-" prefix to indicate
negation
* mail/mail.c (skip_empty_attachments): New global.
(mail_options): New option --skip-empty-attachments
* mail/mail.h (skip_empty_attachments): New extern.
* mail/send.c (atchinfo) <skip_empty>: New field.
(send_attach_file): Initialize skip_empty
(saveatt): Optionally skip empty attachments
* NEWS: Mention the new option.
* doc/texinfo/programs.texi: Document the new option.
2017-01-14 Sergey Poznyakoff <gray@gnu.org>
Bugfix.
* libmu_sieve/load.c [!HAVE_LIBLTDL] (mu_sieve_load_ext): Fix
declaration.
2017-01-14 Sergey Poznyakoff <gray@gnu.org>
Fix typos.
2017-01-14 Sergey Poznyakoff <gray@gnu.org.ua>
docs: improve the attachment section.
* doc/texinfo/programs.texi: provide an example script
illustrating how to use mail from another programs.
2017-01-14 Sergey Poznyakoff <gray@gnu.org.ua>
Re-introduce the --HANG hidden option.
* libmailutils/cli/cli.c (mu_common_options): Declare the
--HANG option.
(hangproc): New function.
2017-01-14 Sergey Poznyakoff <gray@gnu.org.ua>
mail: new options to read attachments from file descriptors.
* mail/mail.c (default_encoding,default_content_type)
(content_name,content_filename): New statics.
(cli_attach): Use the value of --content-name option as the
content-type name parameter. The "-" argument instructs the
program to read attachment from stdin (eqv --attach-fd=0)
(cli_attach_fd): New function.
(mail_options): New options: --content-name,
--content-filename, --attach-fd
* mail/mail.h (send_attach_file_default): Remove.
(send_attach_file): New proto.
* mail/send.c (atchinfo): New fields: id, name, source.
(atchinfo_free): Update.
(default_encoding,default_content_type): Remove globals.
(send_attach_file): Rewrite.
(send_attach_file_default): Remove.
(escape_list_attachments): Print attachment identifier instead
of the file name, which can be NULL.
(saveatt): Use mu_attachment_create and
mu_attachment_copy_from_stream.
* NEWS: Update.
* doc/texinfo/programs.texi: Document the new options.
2017-01-13 Sergey Poznyakoff <gray@gnu.org.ua>
Fix default nullstream read mode.
* libmailutils/stream/nullstream.c (_nullstream_free_pattern):
Always reset pattern and patsize.
(mu_nullstream_create): Fix patsize.
2017-01-04 Sergey Poznyakoff <gray@gnu.org>
Improve handling of namespace references.
* imap4d/list.c (refinfo) <pfxlen>: Remove.
(list_fun): Change the algorithm for restoring the printable
reference name.
(imap4d_list): Use actual reference, not the prefix value.
* imap4d/namespace.c: Fix handling of NS_OTHER prefixes.
* imap4d/tests/list.at: Change the testcase.
2017-01-04 Sergey Poznyakoff <gray@gnu.org.ua>
Tiny fix in c++ code.
2017-01-04 Sergey Poznyakoff <gray@gnu.org.ua>
Rewrite namespace support.
* imap4d/imap4d.c (imap4d_homedir)
(modify_homedir, mailbox_mode): Remove.
(imap4d_srv_param): New configuration statement "namespace"
Remove statements: homedir, personal-namespace,
shared-namespace, other-mailbox-mode, shared-mailbox-mode.
* imap4d/imap4d.h (imap4d_homedir, modify_homedir)
(mailbox_mode): Remove. (namespace, namespace_init_session,
util_getfullpath)
(namespace_getfullpath, namespace_checkfullpath): Remove.
(namespace_prefix, namespace): New structs. (namespace_lookup,
namespace_translate_name)
(namespace_get_url, translate_delim): New protos.
* imap4d/list.c (refinfo): Revamp.
(list_fun): Rewrite.
* imap4d/namespace.c: Rewrite from scratch.
* imap4d/append.c: Use new namespace functions.
* imap4d/util.c (util_getfullpath): Remove.
* imap4d/copy.c: Likewise.
* imap4d/create.c: Likewise.
* imap4d/delete.c: Likewise.
* imap4d/quota.c: Likewise.
* imap4d/rename.c: Likewise.
* imap4d/select.c: Likewise.
* imap4d/status.c: Likewise.
* imap4d/tests/atlocal.in (make_config): New function.
* imap4d/tests/testsuite.at (IMAP4D_CONFIG)
(IMAP4D_RUN): New functions.
* imap4d/tests/list.at: Update tests 16, 17, 18, 19
* imap4d/tests/IDEF0955.at: Use IMAP4D_RUN.
* imap4d/tests/IDEF0956.at: Likewise.
* imap4d/tests/append00.at: Likewise.
* imap4d/tests/append01.at: Likewise.
* imap4d/tests/create01.at: Likewise.
* imap4d/tests/create02.at: Likewise.
2017-01-02 Sergey Poznyakoff <gray@gnu.org>
Tiny fix.
* libmailutils/sockaddr/str.c: Add missing include. Reported by
Felix Janda
2017-01-01 Sergey Poznyakoff <gray@gnu.org>
Happy GNU Year.
2016-12-31 Sergey Poznyakoff <gray@gnu.org.ua>
Provide a way to discern between erroneous return and
user-induced break condition in foreach iterator functions.
* libmailutils/diag/errors (MU_ERR_USER0-MU_ERR_USER7): New
error constants. Reserved for user's purposes, such as breaking
from foreach iterators.
* libmaildutils/list/foreach.c (mu_list_foreach): Treat NULL
list as a list of 0 elements.
* libmailutils/list/foreachdir.c (mu_list_foreach_dir):
Likewise.
* imap4d/imap4d.h (imap4d_auth_result): Remap constants to
MU_ERR_USER[0-2]
* libmu_sieve/prog.c (mu_i_sv_lint_command): Use mu_list_locate
with the default comparator.
* mh/mh_list.c (_comp_name): Rewrite to match the definition of
mu_list_comparator_t
(mhl_format_run): Set _comp_name as comparator for the
env.printed_fields list.
(header_is_printed): Use mu_list_locate.
* imap4d/authenticate.c: Use MU_ERR_USER0-MU_ERR_USER7 to
indicate normal break condition in foreach iterators.
* imap4d/imap4d.c: Likewise.
* imap4d/namespace.c: Likewise.
* libmailutils/auth/auth.c: Likewise.
* libmailutils/cfg/driver.c: Likewise.
* libmailutils/cfg/parser.y: Likewise.
* libmailutils/server/acl.c: Likewise.
* libmailutils/server/msrv.c: Likewise.
* libmu_sieve/conf.c: Likewise.
* libmu_sieve/load.c: Likewise.
* libmu_sieve/sieve.l: Likewise.
* libmu_sieve/strexp.c: Likewise.
* libproto/imap/mbox.c: Likewise.
* libproto/imap/search.c: Likewise.
* mh/mh_format.c: Likewise.
* mh/send.c: Likewise.
* mh/sortm.c: Likewise.
* mimeview/mimetypes.y: Likewise.
* movemail/movemail.c: Likewise.
2016-12-28 Sergey Poznyakoff <gray@gnu.org.ua>
Provide sort function for associative arrays.
The mu_assoc_sort_r call sorts the elements of mu_assoc_t for
subsequent iterative access. Random access facilities remain
undisturbed.
* include/mailutils/assoc.h (mu_assoc_comparator_t): New
typedef.
(mu_assoc_sort_r): New proto.
* libmailutils/base/assoc.c (mu_assoc_sort_r): New function.
* libmailutils/tests/mimehdr.c: Sort assoc elements prior to
iteration.
2016-12-28 Sergey Poznyakoff <gray@gnu.org.ua>
Fix parsing of Content-Type and Content-Disposition headers.
Correctly handle character set and language info embedded in
parameter values, and eventual parameter value continuations as
per RFC 2231, Section 3.
* include/mailutils/assoc.h (mu_assoc_is_empty): New proto.
* libmailutils/base/assoc.c (mu_assoc_is_empty): New function.
* include/mailutils/mime.h (mu_mime_header_parse): Output
charset is char const *.
* libmailutils/mime/mimehdr.c (mu_mime_header_parse): Likewise.
* include/mailutils/util.h (mu_content_type) <param>: Change
type to mu_assoc_t
(mu_param): Remove structure declaration.
(mu_content_type_parse): Take an optional output charset.
* libmailutils/base/ctparse.c (mu_content_type_parse): Rewrite
using mu_mime_header_parse.
* imap4d/fetch.c (send_parameter_list): Rewrite using
mu_mime_header_parse.
(format_param): Use base64 for parameter values with explicit
charsets.
* libmailutils/tests/conttype.c: Reflect the changes to struct
mu_content_type
2016-12-28 Sergey Poznyakoff <gray@gnu.org.ua>
Implement mu_assoc_foreach function.
* include/mailutils/assoc.h (mu_assoc_action_t): New typedef.
(mu_assoc_foreach): New function.
* libmailutils/base/assoc.c (mu_assoc_foreach): New function.
2016-12-27 Sergey Poznyakoff <gray@gnu.org.ua>
Revise associative array API.
* configure.ac (VI_REVISION): Increase.
* include/mailutils/assoc.h (mu_assoc_create): Change
prototype. (mu_assoc_ref,mu_assoc_ref_install)
(mu_assoc_remove_ref): Remove.
(mu_assoc_get): New proto.
(mu_assoc_lookup,mu_assoc_lookup_ref): New proto.
(mu_assoc_install_ref): New proto.
(mu_assoc_set_free): Remove.
(mu_assoc_set_destroy_item): Set proto.
* include/mailutils/types.hin (mu_deallocator_t): New typedef.
* include/mailutils/list.h (mu_list_destroy_item_t): Change
definition.
* libmailutils/base/assoc.c: Rewrite. Link all entries in a
doubly-linked list to preserve natural ordering during
iterations.
* libmailutils/base/mutil.c (mutil_parse_field_map): Update
calls to assoc API.
* libmailutils/cfg/driver.c (alloc_section_tab)
(mu_create_canned_section,mu_create_canned_param)
(mu_get_canned_container,parse_mapping)
(mu_cfg_field_map): Likewise.
* libmailutils/mime/mimehdr.c (_mu_mime_param_free): Free the
pointer itself. (flush_param,mu_mime_param_assoc_create)
(mu_mime_param_assoc_add) (_mime_header_parse)
(mu_mimehdr_aget_decoded_param): Update calls to assoc API.
(mu_mime_param_free): New function.
* libmailutils/property/assocprop.c: Likewise.
* libmu_sieve/environment.c: Likewise.
* libmu_sieve/variables.c: Likewise.
* libproto/imap/id.c: Likewise.
* mail/alias.c: Likewise.
* mail/testsuite/mail/alias.exp: Update ordering of expected
output.
* mu/imap.c (com_id): Update.
* include/mailutils/mime.h (mu_rfc2047_decode_param): Change
prototype.
* libmailutils/base/rfc2047.c (mu_rfc2047_decode_param):
Allocate returned value, instead of filling an already
allocated structure.
* libproto/imap/fetch.c: Reflect changes.
2016-12-26 Sergey Poznyakoff <gray@gnu.org.ua>
Fix typecasts in sieve.
* libmu_sieve/sieve.y (sieve_parse): Make sure 0 is properly
promoted to sieve_instr_t.
2016-12-25 Sergey Poznyakoff <gray@gnu.org.ua>
Improve attachment creation API.
* include/mailutils/message.h (mu_attachment_create)
(mu_attachment_copy_from_stream)
(mu_attachment_copy_from_file): New functions.
* libmailutils/mime/attachment.c: Likewise.
(mu_message_create_attachment): Rewrite using the three
functions above.
2016-12-25 Sergey Poznyakoff <gray@gnu.org.ua>
New string functions.
* libmailutils/string/strcount.c (mu_str_count): Take an array
of (ASCII) characters to count occurrences of. Optionally store
individual counts in an array passed as the 3rd argument.
* include/mailutils/cstr.h (mu_str_count): Change proto.
(mu_c_str_escape, mu_c_str_escape_trans)
(mu_c_str_unescape_inplace, mu_c_str_unescape)
(mu_c_str_unescape_trans): New protos.
* libmailutils/string/cstrescape.c: New file.
* libmailutils/string/cstrunescape.c: New file.
* libmailutils/string/Makefile.am: Add new files.
2016-12-22 Sergey Poznyakoff <gray@gnu.org.ua>
New command: mailutils stat.
* include/mailutils/util.h (mu_c_storage_t): New data type.
* mu/stat.c: New file.
* mu/Makefile.am: Add stat
* doc/texinfo/programs.texi: Document mailutils stat
2016-12-21 Sergey Poznyakoff <gray@gnu.org.ua>
Bugfixes in imap client code.
* libproto/imap/mbox.c (_imap_message_unseen): Fix type of
pointer returned by mu_list_head
* libproto/imap/resproc.c (parse_response_code): Fix parser
2016-12-21 Sergey Poznyakoff <gray@gnu.org.ua>
imap: fix LIST "" "mbox"
* imap4d/list.c (imap4d_list): Move the longest directory
prefix to the reference.
* imap4d/tests/list.at: New testcase.
* libmu_sieve/tests.c: Fix bug introduced by previous commit
2016-12-20 Sergey Poznyakoff <gray@gnu.org.ua>
sieve: improve address tests.
* libmu_sieve/tests.c (retrieve_address): Treat
MU_ERR_EMPTY_ADDRESS as MU_ERR_NOENT. This complements
678d93678
2016-12-20 Sergey Poznyakoff <gray@gnu.org.ua>
Bugfixes.
* libmu_sieve/sieve.y (mu_sieve_machine_clone): Fix memory
allocation.
* mh/pick.c: Remove unused functions.
2016-12-19 Sergey Poznyakoff <gray@gnu.org.ua>
Fix fb84d1e3.
The commit didn't take into account all possible
option/argument combinations.
* mh/pick.c (main): Preprocess command line prior to parsing
it, expanding --COMP NAME in -component COMP -pattern NAME.
* mh/mh_getopt.c: Revert fb84d1e3
* mh/mh_getopt.h: Likewise.
2016-12-19 Sergey Poznyakoff <gray@gnu.org.ua>
Minor changes to configure.
* configure.ac: Assume tokyo|kyoto cabinet will pull the
necessary dependencies. Add GINT_LDADD if necessary
* gint: Upgrade
2016-12-19 Sergey Poznyakoff <gray@gnu.org.ua>
New example.
* configure.ac (MU_PRI_OFF_T): Define to the printf format spec
suitable for printing mu_off_t. Don't use [ ] instead of test.
* include/mailutils/types.hin (MU_PRI_OFF_T): New define.
* include/mailutils/Makefile.am (type.h): Pass MU_PRI_OFF_T
* examples/mboxsize.c: New file.
* examples/Makefile.am: Build mboxsize
2016-12-19 Sergey Poznyakoff <gray@gnu.org.ua>
Fix size calculation for MH and Maildir mailboxes.
Exclude from calculation any eventual nested mailboxes.
* libproto/maildir/mbox.c: Provide the mailbox_size method.
* libproto/mh/mbox.c: Likewise.
2016-12-19 Sergey Poznyakoff <gray@gnu.org.ua>
Bugfixes.
* configure.ac: Fallback to guile installation prefix, if
'guile-config info bindir' returns empty string.
* doc/texinfo/programs.texi: Minor fix.
* mail/mailline.c (ml_readline_init): Don't use obsolete
CPPFunction type.
* mu/shell.c (mutool_initialize_readline): Likewise.
* scheme/sieve2scm.scmi: Fix typo.
* sieve/sieve.c (main): Fix initialization of Sieve environment
variables "location" and "post".
2016-12-17 Sergey Poznyakoff <gray@gnu.org.ua>
Version 3.1.90.
2016-12-17 Sergey Poznyakoff <gray@gnu.org.ua>
Improve rename/copy/reomove API.
* examples/rename.c: Remove.
* examples/fcopy.c: New file.
* examples/fremove.c: New file.
* examples/frename.c: New file.
* examples/Makefile.am: Update.
* include/mailutils/util.h (mu_rename_file): Add flags.
(mu_remove_file): New function.
(MU_COPY_OVERWRITE): New flag.
* libmailutils/base/renamefile.c: New file.
* libmailutils/base/Makefile.am: Add new file.
* libmailutils/base/copyfile.c: Fix error handling.
* libmailutils/base/renamefile.c (mu_rename_file): Refuse to
proceed if the destination file exists and MU_COPY_OVERWRITE
flag is not set
* libmailutils/diag/errors (MU_ERR_REMOVE_SOURCE)
(MU_ERR_RESTORE_META): New errors
* imap4d/rename.c (imap4d_rename): Use mu_rename_file
* mh/forw.c: Likewise.
* mh/mh_whatnow.c: Likewise.
* mh/mhn.c: Likewise.
* mh/send.c: Likewise.
* include/mailutils/cstr.h (mu_str_count): New proto.
* include/mailutils/util.h (mu_file_name_is_safe): New proto.
* libmailutils/string/safefilename.c: New file.
* libmailutils/string/strcount.c: New file.
* libmailutils/string/Makefile.am: Update.
2016-12-17 Sergey Poznyakoff <gray@gnu.org.ua>
Add functions for safe renaming and copying of files.
* libmailutils/base/copyfile.c: New file.
* libmailutils/base/renamefile.c: New file.
* include/mailutils/util.h (mu_copy_file)
(mu_rename_file): New protos.
* libmailutils/base/Makefile.am: Add new files.
* examples/rename.c: New file.
* examples/Makefile.am: Add new files.
* NEWS: Update.
2016-12-16 Sergey Poznyakoff <gray@gnu.org>
Version 3.1.1 released.
2016-12-15 Sergey Poznyakoff <gray@gnu.org.ua>
Export mu-mailer guile variable.
* libmu_scm/mu_scm.c: Export mu-mailer.
* libmu_scm/mu_message.c (scm_mu_message_send): Fix a typo.
2016-12-15 Sergey Poznyakoff <gray@gnu.org.ua>
Swap precedences of MH and Maildir to help in format
autodetection.
* include/mailutils/registrar.h: Swap MU_MAILDIR_PRIO and
MU_MH_PRIO (mu_record_is_local)
(mu_registrar_apply_filter): New protos.
* libmailutils/base/registrar.c
(mu_registrar_set_default_scheme): Use
mu_registrar_set_default_record.
(mu_record_is_local): New function.
(mu_record_get_url): Use it.
(mu_registrar_apply_filter): New function.
2016-12-15 Sergey Poznyakoff <gray@gnu.org>
Version 3.1.1.
2016-12-14 Sergey Poznyakoff <gray@gnu.org>
Fix pick --component NAME.
* mh/mh_getopt.c (mh_getopt0): New function.
(mh_getopt): Rewrite as alternative entry point to .
* mh/mh_getopt.h (mh_getopt0): New proto.
* mh/pick.c: Use mh_getopt0
* mh/tests/pick.at: Add new testcase.
2016-12-14 Sergey Poznyakoff <gray@gnu.org.ua>
Bugfixes.
* libproto/imap/tag.c: Initialize allocated slot to 0
* mu/imap.c: Fix number of elements to allocate
2016-12-14 Sergey Poznyakoff <gray@gnu.org.ua>
Restore prematurely deleted header.
* include/mailutils/argcv.h: Restore
* include/mailutils/Makefile.am: Add back argcv.h
2016-12-13 Sergey Poznyakoff <gray@gnu.org>
Minor changes in sieve.
* libmu_sieve/runtime.c (mu_sieve_abort): Jump with code
MU_ERR_FAILURE.
* libmu_sieve/tests.c (retrieve_address): Tolerate empty
addresses.
(retrieve_header): Return reasonable error code.
* maidag/script.c (script_apply): If the script failed, return
0.
2016-12-13 Sergey Poznyakoff <gray@gnu.org>
Minor fix.
2016-12-13 Sergey Poznyakoff <gray@gnu.org>
Version 3.1.
* configure.ac: version 3.1
* NEWS: Likewise.
* libmu_sieve/comparator.c: Attend to FIXMEs.
* libmu_sieve/conf.c: Likewise.
* libmu_sieve/prog.c: Likewise.
* libmu_sieve/runtime.c: Likewise.
* libmu_sieve/sieve.y: Likewise.
* libmu_sieve/util.c: Likewise.
* libmu_sieve/variables.c: Likewise.
* po/POTFILES.in: Add new files.
2016-12-13 Sergey Poznyakoff <gray@gnu.org>
libmu_sieve: minor fix.
* libmu_sieve/util.c (mu_sieve_value_get): Treat actual string
and expected string list as equivalent types.
2016-12-13 Sergey Poznyakoff <gray@gnu.org.ua>
Pacify a paranoid compiler warning.
* libmailutils/string/wordsplit.c (mu_wordsplit_perror): Use %s
format specifier
2016-12-13 Jordi Mallach <jordi@debian.org>
Fix spelling errors.
2016-12-13 Sergey Poznyakoff <gray@gnu.org.ua>
Bugfixes.
* libmu_sieve/sieve.y: Fix compilation of chained elsif
conditions.
* sieve/sieve.c: Define the location environment item.
2016-12-13 Sergey Poznyakoff <gray@gnu.org.ua>
Document changes to Sieve.
* NEWS: Update.
* doc/texinfo/libmu_sieve.texi: Update.
* doc/texinfo/sieve.texi: Document extensions
* libmu_sieve/comparator.c (mu_sieve_match_part_checker): Check
the type of the 2nd argument.
* sieve/sieve.c: Define "location" and "phase" environment
items.
* sieve/tests/pipetest.at: Use "pipe" as the capability string.
2016-12-13 Sergey Poznyakoff <gray@gnu.org.ua>
New sieve machine accessor functions.
* include/mailutils/sieve.h (mu_sieve_get_mailbox)
(mu_sieve_get_argc): New protos.
* libmu_sieve/runtime.c: New functions.
2016-12-13 Sergey Poznyakoff <gray@gnu.org.ua>
Fix command expansion in wordsplit.
* libmailutils/string/wordsplit.c: Change ordering of
expansions so that command expansion occurs first. This fixes
nested expansions and command expansions occurring after
variable expansions.
* libmailutils/tests/wordsplit.at: Add more tests.
2016-12-12 Sergey Poznyakoff <gray@gnu.org.ua>
mhn: allow for whitespace in edit commands.
2016-12-12 Sergey Poznyakoff <gray@gnu.org.ua>
Fix -nowhatnow proc in mh.
* mh/mh.h (mh_whatnow_env) <nowhatnowproc>: New member.
* mh/compcommon.c (check_draft_disposition): Return
DISP_REPLACE if nowhatnowproc is set.
* mh/mh_whatnow.c (mh_whatnowproc): Return 0 if nowhatnowproc
is set.
* mh/comp.c: Fix -nowhatnowproc
* mh/forw.c: Likewise.
* mh/repl.c: Likewise.
2016-12-12 Sergey Poznyakoff <gray@gnu.org.ua>
Bugfix.
* libmailutils/base/ctparse.c (parse_type)
(parse_subtype): Fix memory allocation
2016-12-12 Sergey Poznyakoff <gray@gnu.org>
Minor fix.
2016-12-12 Sergey Poznyakoff <gray@gnu.org>
Add tests for sieve environment. Initialize environment in
maidag and inc.
* sieve/tests/environment.at: New testcase.
* sieve/tests/Makefile.am: Add new file.
* sieve/tests/testsuite.at: Include new file.
* lib/muscript.h (mu_script_init): Change signature.
* lib/muscript_priv.h (mu_script_fun) <script_init>: Likewise.
* lib/guile.c (scheme_init): Update.
* lib/python.c (python_init): Update.
* lib/script.c (mu_script_init): Pass environment to the
script_init method.
* lib/sieve.c (sieve_init): Set sieve environment.
* maidag/script.c (apply_script): Set environment.
* mh/inc.c: Likewise.
2016-12-11 Sergey Poznyakoff <gray@gnu.org.ua>
Support for environment extension (RFC 5183).
* include/mailutils/sieve.h (mu_sieve_require_environment): New
proto.
* libmu_sieve/Makefile.am: Add environment.c
* libmu_sieve/environment.c: New file.
* libmu_sieve/require.c: Handle "environment" keyword.
* libmu_sieve/sieve-priv.h (mu_sieve_machine) <exenv>: New
member.
* libmu_sieve/sieve.l: Bugfixes
* libmu_sieve/variables.c: Add missing static qualifiers
* sieve/sieve.c: New option --environment
2016-12-10 Sergey Poznyakoff <gray@gnu.org>
Remove libmu_compat.
2016-12-10 Sergey Poznyakoff <gray@gnu.org>
Rewrite stream flushing code.
* libmailutils/stream/stream.c (_stream_flush_buffer): Rewrite.
2016-12-09 Sergey Poznyakoff <gray@gnu.org>
Fix minor inconsistencies.
2016-12-09 Sergey Poznyakoff <gray@gnu.org>
Provide function for parsing the Content-Type header (RFC
2045).
* include/mailutils/util.h (mu_content_type, mu_param): New
structs.
(mu_content_type_t): New typedef.
(mu_content_type_parse, mu_content_type_destroy): New protos.
* libmailutils/base/ctparse.c: New file.
* libmailutils/base/Makefile.am: Add new file.
* imap4d/fetch.c: Use mu_content_type_parse to parse the
header.
* libmailutils/tests/conttype.c: New file.
* libmailutils/tests/Makefile.am: Add new file.
2016-12-08 Sergey Poznyakoff <gray@gnu.org>
Fix eventual dangling pointers.
Don't set mu_log_tag, leave that to the caller.
* libmailutils/cli/cli.c (mu_cli_ext): Don't set mu_log_tag.
* libmailutils/stdstream/strerr.c: Use MU_LOG_TAG macro from
syslog.h
* sieve/sieve.c: Redo --no-program-name support
2016-12-08 Sergey Poznyakoff <gray@gnu.org>
sieve: fix the mu_sieve_vlist_compare API.
* libmu_sieve/util.c (mu_sieve_vlist_compare): Rewrite.
* include/mailutils/sieve.h (mu_sieve_retrieve_t): Change
signature. All uses changed.
(mu_sieve_relational_count): Remove.
(mu_sieve_vlist_compare): Change signature.
* libmu_sieve/extensions/list.c (list_retrieve_header): Always
return meaningful status.
* libmu_sieve/tests.c (mu_sieve_relational_count): Remove.
(retrieve_address,retrieve_envelope): Return meaningful status.
(retrieve_header): Iterate over all mime parts, if required.
(sieve_test_address,sieve_test_header): Rewrite.
* libmu_sieve/variables.c (sieve_test_string): Rewrite using
mu_sieve_vlist_compare.
2016-12-07 Sergey Poznyakoff <gray@gnu.org.ua>
Version 3.0.90.
2016-12-07 Sergey Poznyakoff <gray@gnu.org.ua>
Add missing file.
* include/mailutils/glob.h: File was missing in df608ed0
* include/mailutils/Makefile.am: Add glob.h
2016-12-07 Sergey Poznyakoff <gray@gnu.org.ua>
Implement the "variables" Sieve extension (RFC 5229)
* include/mailutils/sieve.h (mu_sieve_string): New fields
"constant" and "changed".
(mu_sieve_match_part_tags): New extern.
(mu_sieve_relational_count) (mu_sieve_require_variables)
(mu_sieve_has_variables)
(mu_sieve_string_get): New functions.
* libmu_sieve/variables.c: New file.
* libmu_sieve/Makefile.am: Add variables.c
* libmu_sieve/comparator.c: Use mu_sieve_string_get to obtain
the actual value of the string.
* libmu_sieve/require.c: Support the "variables" extension.
* libmu_sieve/sieve-priv.h (mu_sieve_machine): New fields
vartab, match_string, match_buf, match_count, match_max.
(mu_i_sv_copy_variables)
(mu_i_sv_expand_variables): New protos.
* libmu_sieve/sieve.l (line_add): zero length means add entire
asciiz string.
* libmu_sieve/sieve.y (mu_sieve_machine_reset): Reset the new
fields.
(mu_sieve_machine_clone): Copy variables and initialize new
fields.
(string_rescan): New function.
(sieve_parse): Rescan string to determine their properties.
* libmu_sieve/strexp.c (update_len): Allow for NULL replacement
values.
* libmu_sieve/string.c (mu_sieve_string_get): New function.
(mu_sieve_string): Use it.
* libmu_sieve/tests.c (do_count): Rename to
mu_sieve_relational_count, make global. All uses changed.
(match_part_tags): Rename to mu_sieve_match_part_tags, make
global. All uses changed.
* sieve/tests/variables.at: New file.
* sieve/tests/Makefile.am: Add new testcases.
* sieve/tests/testsuite.at: Likewise.
2016-12-06 Sergey Poznyakoff <gray@gnu.org.ua>
Use glob API in sieve.
* libmu_sieve/comparator.c: Use mu_glob_compile instead of
fnmatch.
2016-12-06 Sergey Poznyakoff <gray@gnu.org.ua>
New API for converting globbing patterns to extended POSIX
regex.
* include/mailutils/opool.h (mu_nonlocal_jmp_t): New type.
(mu_opool_setjmp,mu_opool_clrjmp): New functions.
(mu_opool_setup_nonlocal_jump): New macro.
* libmailutils/base/opool.c (_mu_opool)<jmp>: New field.
(alloc_bucket): Do a non-local jump on out of memory condition,
if jmp is not NULL.
(mu_opool_setjmp,mu_opool_clrjmp): New functions.
* libmailutils/base/glob.c: New file.
* libmailutils/base/Makefile.am: Add glob.c
* include/mailutils/glob.h: New file.
* include/mailutils/mailutils.h: Include glob.h
* libmailutils/tests/globtest.c: New file.
* libmailutils/tests/globtest.at: New test.
* libmailutils/tests/Makefile.am: Add new files.
* libmailutils/tests/testsuite.at: Include new test.
2016-12-06 Sergey Poznyakoff <gray@gnu.org.ua>
Bugfix.
* libmailutils/stream/stream.c (mu_stream_ioctl): Don't flush
read buffer.
2016-12-05 Sergey Poznyakoff <gray@gnu.org>
Improve opool.
* include/mailutils/opool.h (mu_opool_detach): New proto.
* libmailutils/base/opool.c (mu_opool_bucket): Redo as union to
ensure proper alignment. All uses changed.
(mu_opool_detach): New function.
2016-12-04 Sergey Poznyakoff <gray@gnu.org>
sieve: redo symbol registry support.
The purpose is to simplify the machine structure and to ensure
its clones are completely independent of the master instance.
* include/mailutils/sieve.h (mu_sieve_command): New struct.
(mu_sieve_record): New enum
(mu_sieve_registry_t): Generalize for storing various types of
objects. (mu_sieve_test_lookup,mu_sieve_action_lookup)
(mu_sieve_require_action,mu_sieve_require_test)
(mu_sieve_require_comparator): Remove.
(mu_sieve_register_test_ext,mu_sieve_register_test)
(mu_sieve_register_action_ext,mu_sieve_register_action)
(mu_sieve_register_comparator)
(mu_sieve_load_ext): Change return type.
(mu_sieve_registry_require,mu_sieve_unload_ext): New functions.
(mu_sieve_machine_inherit): Rename to mu_sieve_machine_clone.
* libmu_sieve/sieve-priv.h (mu_sieve_machine): Remove
source_list, test_list, action_list, and comp_list. Add a
single registry list instead. Add space for file and command
(action and test) names: idspace, idcount, idmax. Remove unused
field "stack";
(mu_i_sv_lex_finish): Change prototype.
(_mu_i_sv_instr_push,_mu_i_sv_instr_pop): Remove protos.
(mu_i_sv_id_canon,mu_i_sv_id_num)
(mu_i_sv_id_str,mu_i_sv_free_idspace): New protos.
* libmu_sieve/register.c: Rename to registry.c
* libmu_sieve/registry.c (mu_sieve_test_lookup)
(mu_sieve_action_lookup): Remove.
(mu_sieve_require_test,mu_sieve_require_action): Remove.
(mu_sieve_registry_require): New function.
(mu_sieve_registry_add,mu_sieve_registry_lookup): New
functions.
* libmu_sieve/Makefile.am: Update.
* libmu_sieve/comparator.c: Rewrite using new registry
functions.
* libmu_sieve/load.c (mu_sieve_load_ext): Return module handle.
(mu_sieve_unload_ext): New function.
* libmu_sieve/mem.c (mu_sieve_free): Gracefully handle NULL
argument.
(mu_i_sv_id_canon,mu_i_sv_id_num,mu_i_sv_id_str): New
functions.
* libmu_sieve/prog.c (mu_i_sv_locus): Store index of the file
name in the id space, instead of pointer to the name itself.
* libmu_sieve/require.c (mu_sieve_require): Rewrite.
* libmu_sieve/runtime.c (_mu_i_sv_instr_source): Expect ID
index as argument. (_mu_i_sv_instr_push)
(_mu_i_sv_instr_pop): Remove unused instructions.
* libmu_sieve/sieve.l (file_names): Remove. Use
mu_sieve_machine idspace instead.
* libmu_sieve/sieve.y (mu_sieve_machine_clone)
(mu_sieve_machine_dup): Rewrite.
(mu_sieve_machine_destroy): Free idspace and registry
* examples/numaddr.c: Reflect changes.
* libmu_sieve/extensions/editheader.c: Likewise.
* libmu_sieve/extensions/list.c: Likewise.
* libmu_sieve/extensions/moderator.c: Likewise.
* libmu_sieve/extensions/pipe.c: Likewise.
* libmu_sieve/extensions/spamd.c: Likewise.
* libmu_sieve/extensions/timestamp.c: Likewise.
* libmu_sieve/extensions/vacation.c: Likewise.
2016-12-03 Sergey Poznyakoff <gray@gnu.org>
Rename mu_sieve_machine_init to mu_sieve_machine_create.
2016-12-03 Sergey Poznyakoff <gray@gnu.org>
Cleanup.
* include/mailutils/sieve.h (SVT_IDENT): Remove.
* libmu_sieve/comparator.c (mu_sieve_match_part_checker):
Remove unused variable.
* libmu_sieve/mem.c (mu_sieve_reclaim_list): Remove function.
* libmu_sieve/sieve.y: Remove leftover uses of SVT_IDENT.
* libmu_sieve/util.c: Likewise.
* libmu_sieve/sieve-priv.h: Remove useless prototypes.
2016-12-02 Sergey Poznyakoff <gray@gnu.org.ua>
sieve: change string allocation and argument passing
convention.
Strings are allocated in a per-machine string space. String and
argument lists form contiguous arrays of structures. Regular
expressions are compiled when they are needed. Compiled
expressions are cached for eventual reuse.
2016-12-01 Sergey Poznyakoff <gray@gnu.org.ua>
Fix delivery to MH and Maildir mailboxes.
After successful delivery, maidag would switch back to root
privileges too early, due to which the mailbox would be closed
when running with root UID. I the property file (.mu-prop) did
not exist, it would therefore be created by root. Subsequent
attempts to open it by user would fail. One of consequences is
that the UIDVALIDITY value would be recalculated each time the
mailbox is opened. This would force imap4 clients to rescan
mailboxes infinitely, as each scan would change the UIDVALIDITY
again.
This patch fixes the initialization of UIDVALIDITY and fixes
maidag to switch back to root privileges only after closing the
mailbox. It also makes sure MH and Maildir mailboxes write
.mu-prop upon closing, not upon destroying the mailbox.
* libmailutils/base/amd.c (amd_close): Save property.
(_amd_scan0): Use mailbox modification time as initial
uidvalidity value.
* maidag/deliver.c (deliver_to_mailbox): Remove useless UID/GID
transitions.
2016-11-29 Sergey Poznyakoff <gray@gnu.org.ua>
sieve: improve memory allocation.
* include/mailutils/sieve.h (mu_sieve_alloc)
(mu_sieve_palloc,mu_sieve_prealloc)
(mu_sieve_pfree,mu_sieve_pstrdup): Remove.
(mu_sieve_mstrdup,mu_sieve_mrealloc)
(mu_sieve_mfree): Remove.
(mu_sieve_reclaim_t): New typedef.
(mu_sieve_calloc,mu_sieve_strdup) (mu_sieve_realloc)
(mu_sieve_reclaim_default,mu_sieve_reclaim_list)
(mu_sieve_reclaim_value,mu_sieve_reclaim_tag): New functions
(mu_sieve_value_create): Change prototype (take
mu_sieve_machine_t as first argument)
* libmu_sieve/mem.c: New file.
* libmu_sieve/Makefile.am: Add new file.
* libmu_sieve/comparator.c: Use new allocation functions.
* libmu_sieve/prog.c: Likewise.
* libmu_sieve/register.c: Likewise.
* libmu_sieve/sieve.l: Likewise.
* libmu_sieve/sieve.y: Likewise.
* libmu_sieve/util.c: Likewise.
* doc/texinfo/libmu_sieve.texi: Update (needs revision).
2016-11-29 Sergey Poznyakoff <gray@gnu.org.ua>
Minor change.
* include/mailutils/list.h (mu_list_remove)
(mu_list_remove_nd): Second arg is const.
* libmailutils/list/remove.c: Likewise.
2016-11-29 Sergey Poznyakoff <gray@gnu.org.ua>
Remove compatibility support for obsolete .mu-size.
2016-11-28 Sergey Poznyakoff <gray@gnu.org.ua>
sieve: more improvements to the argument/tag runtime access
API.
* include/mailutils/sieve.h (mu_sieve_handler_t): Change
signature: remove args and tags arguments, they are contained
in struct mu_sieve_machine now. (mu_sieve_get_comparator)
(mu_sieve_relcmpn_t): Change signature.
(mu_sieve_tag_lookup,mu_sieve_tag_lookup_untyped): Remove
(mu_sieve_get_tag,mu_sieve_get_tag_untyped): New protos.
(mu_sieve_value_get_optional): Replace by
mu_sieve_get_arg_optional.
(mu_sieve_value_get_untyped): Replace by
mu_sieve_get_arg_untyped.
(mu_sieve_value_get): Replace by mu_sieve_get_arg. All uses
changed.
* libmu_sieve/sieve-priv.h (mu_sieve_machine): New members:
arg_list and tag_list
* libmu_sieve/runtime.c (instr_run): Set up identifier,
arg_list, and tag_list in mu_sieve_machine_t before calling the
handler. Reset them afterward.
* libmu_sieve/util.c (mu_sieve_value_get_optional): Replace by
mu_sieve_get_arg_optional.
(mu_sieve_value_get_untyped): Replace by
mu_sieve_get_arg_untyped.
(mu_sieve_value_get): Replace by mu_sieve_get_arg.
(mu_sieve_tag_lookup): Replace by mu_sieve_get_tag
(mu_sieve_tag_lookup_untyped): Replace by
mu_sieve_get_tag_untyped
2016-11-26 Sergey Poznyakoff <gray@gnu.org>
sieve: improve argument/tag runtime access API.
* include/mailutils/sieve.h (mu_sieve_data_type): Remove
SVT_VALUE_LIST.
(mu_sieve_value_storage): Named union for use in
mu_sieve_value_t; remove the tag field.
(mu_sieve_tag_lookup): Change prototype.
(mu_sieve_value_get): Change prototype.
(mu_sieve_value_get_optional)
(mu_sieve_value_get_untyped): New functions.
(mu_sieve_arg_error): Removed proto.
* libmu_sieve/sieve.y: Remove SVT_VALUE_LIST support.
* libmu_sieve/util.c (mu_sieve_value_create)
(mu_sieve_type_str,mu_sieve_vlist_do): Remove SVT_VALUE_LIST
support.
(mu_sieve_value_get): Rewrite. (mu_sieve_value_get_untyped)
(mu_sieve_value_get_optional): New functions.
(mu_sieve_arg_error): Remove.
(mu_sieve_tag_lookup): Rewrite.
(mu_sieve_tag_lookup_untyped): New function.
* doc/texinfo/libmu_sieve.texi: Update.
libmu_sieve/tests.c libmu_sieve/actions.c
libmu_sieve/extensions/editheader.c
libmu_sieve/extensions/list.c
libmu_sieve/extensions/moderator.c
libmu_sieve/extensions/pipe.c libmu_sieve/extensions/spamd.c
libmu_sieve/extensions/timestamp.c
libmu_sieve/extensions/vacation.c libmu_sieve/relational.c
examples/numaddr.c
2016-11-26 Sergey Poznyakoff <gray@gnu.org>
Minor fixes.
* libmu_sieve/sieve-priv.h (sieve_op_t) <unum>: New field.
* libmu_sieve/sieve.l: Leave one string interpreter slot.
2016-11-26 Sergey Poznyakoff <gray@gnu.org.ua>
Improve list sorting API.
* libmailutils/list/sort.c (mu_list_sort_r): New function.
* include/mailutils/list.h: Provide prototype.
2016-11-25 Sergey Poznyakoff <gray@gnu.org.ua>
Implement RFC 5228, 2.4.2.4 (Encoding Characters Using
"encoded-character")
* libmu_sieve/encoded.c: New file.
* libmu_sieve/strexp.c: New file.
* libmu_sieve/Makefile.am: Add new files.
* libmu_sieve/require.c (mu_sieve_require): Understand
"encoded-character".
* libmu_sieve/sieve-priv.h (mu_i_sv_interp_t): New typedef.
(mu_i_sv_expand_encoded_char): New proto.
(mu_sieve_require_encoded_character): New proto.
* libmu_sieve/sieve.l (string): Rewrite via line_.* functions.
This fixes memory leaks on mu_sieve_machine_destroy.
(line_finish): Expand ${} sequences before returning.
(mu_sieve_require_encoded_character): New function.
* sieve/tests/enc-char.at: New file.
* sieve/tests/Makefile.am: Add enc-char.at
* sieve/tests/testsuite.at: Likewise.
2016-11-24 Sergey Poznyakoff <gray@gnu.org.ua>
sieve: simplify action logging API.
* include/mailutils/sieve.h (mu_sieve_action_log_t): Change
proto.
* lib/sieve.c (_sieve_action_log): Rewrite.
* libmu_sieve/util.c (mu_sieve_log_action): Rewrite.
* python/libmu_py/sieve.c (_sieve_action_printer): Rewrite.
* sieve/sieve.c (_sieve_action_log): Rewrite.
2016-11-24 Sergey Poznyakoff <gray@gnu.org.ua>
sieve: provide a separate stream for debugging output.
* include/mailutils/sieve.h (MU_SIEVE_DEBUG_TRACE)
(MU_SIEVE_DEBUG_INSTR,MU_SIEVE_DEBUG_DISAS)
(MU_SIEVE_DRY_RUN): Remove.
(mu_sieve_machine_init_ex): Remove proto.
(mu_sieve_set_dbg_stream,mu_sieve_get_dbg_stream)
(mu_sieve_stream_save)
(mu_sieve_stream_restore): New protos.
* libmu_sieve/runtime.c (INSTR_DISASS,INSTR_DEBUG):
Reimplement.
* libmu_sieve/sieve-priv.h (MU_SV_SAVED_ERR_STATE)
(MU_SV_SAVED_DBG_STATE,MU_SV_SAVED_STATE): New bitflags.
(mu_sieve_state_disass): New constant.
(mu_sieve_machine)<state_flags, err_mode>
<err_locus,dbg_mode,dbg_locus>: New members.
<dbgstream>: New member.
* libmu_sieve/sieve.y (mu_sieve_machine_init_ex): Remove.
(mu_sieve_machine_dup, mu_sieve_machine_inherit): Fix.
(mu_sieve_set_dbg_stream)
(mu_sieve_get_dbg_stream): New functions.
(mu_sieve_machine_destroy): Destroy dbgstream.
(with_machine): Preserve stream state (mode & locus).
* libmu_sieve/util.c (mu_i_sv_debug,mu_i_sv_debug_command): Use
ioctl instead of format strings.
(mu_sieve_stream_save, mu_sieve_stream_restore): New functions.
* python/libmu_py/sieve.c (api_sieve_machine_init): Use
mu_sieve_machine_init.
* sieve/sieve.c: Improve help output.
(main): Dump disassembled code to standard output.
2016-11-24 Sergey Poznyakoff <gray@gnu.org.ua>
Sieve: remove unused opcode.
* libmu_sieve/runtime.c (_mu_i_sv_instr_nop): Remove.
* libmu_sieve/sieve-priv.h: Likewise.
2016-11-24 Sergey Poznyakoff <gray@gnu.org.ua>
Revamp debugging/tracing support.
* bootstrap.conf (mu_sieve_debug, mu_sieve_trace): Remove.
* include/mailutils/sieve.h (mu_sieve_debug): Remove.
* examples/numaddr.c: Remove calls to mu_sieve_trace.
* libmu_sieve/extensions/list.c: Likewise.
* libmu_sieve/extensions/moderator.c: Likewise.
* libmu_sieve/extensions/pipe.c: Likewise.
* libmu_sieve/extensions/spamd.c: Likewise.
* libmu_sieve/extensions/timestamp.c: Likewise.
* libmu_sieve/extensions/vacation.c: Likewise.
* libmu_sieve/tests.c: Likewise.
* libmu_sieve/runtime.c: Use new debugging/tracing functions.
* libmu_sieve/sieve-priv.h (mu_i_sv_debug, mu_i_sv_trace)
(mu_i_sv_debug_command)
(mu_i_sv_argf, mu_i_sv_valf): New prototypes.
* libmu_sieve/sieve.y (mu_i_sv_valf, mu_i_sv_argf): New
functions.
* libmu_sieve/util.c (mu_sieve_debug): Remove.
(mu_i_sv_print_value_list): Remove.
(mu_i_sv_print_tag_list): Remove.
(mu_sieve_trace): Remove.
(mu_i_sv_tagf): New function.
(mu_i_sv_debug): New function.
(mu_i_sv_trace): New function.
(mu_i_sv_debug_command): New function.
2016-11-23 Sergey Poznyakoff <gray@gnu.org.ua>
Fix typo.
2016-11-23 Sergey Poznyakoff <gray@gnu.org.ua>
Redo sieve debugging support.
Instead of keeping individual debug flags for each Sieve
machine, use global debugging mechanism, category "sieve". The
following levels are defined:
trace1 - print parse tree before optimization
trace2 - print parse tree after optimization
trace3 - print parser traces
trace4 - print tests and actions being executed
trace8 - print disassembled code, don't run
trace9 - print each Sieve instruction being executed
* include/mailutils/sieve.h (mu_sieve_get_debug_level)
(mu_sieve_set_debug_level): Remove.
(mu_sieve_is_dry_run,mu_sieve_set_dry_run
* lib/script.c (mu_script_debug_flags): Redo.
* lib/sieve.c (sieve_init): Remove call to obsoleted
mu_sieve_set_debug_level.
* examples/numaddr.c: Use mu_sieve_trace
* libmu_sieve/extensions/list.c: Likewise.
* libmu_sieve/extensions/moderator.c: Likewise.
* libmu_sieve/extensions/pipe.c: Likewise.
* libmu_sieve/extensions/spamd.c: Likewise.
* libmu_sieve/extensions/timestamp.c: Likewise.
* libmu_sieve/extensions/vacation.c: Likewise.
* libmu_sieve/tests.c: Likewise.
* libmu_sieve/runtime.c (INSTR_DEBUG,INSTR_DISASS): Rewrite.
(mu_sieve_get_debug_level): Remove. (mu_sieve_is_dry_run_:
Rewrite.
(mu_sieve_set_dry_run): New function.
(mu_sieve_disass): Rewrite.
* libmu_sieve/sieve-priv.h (mu_sieve_machine) <debug_level>:
Remove.
<dry_run>: New field.
* libmu_sieve/sieve.y (mu_sieve_set_debug_level): Remove.
* libmu_sieve/util.c (mu_sieve_trace): New function.
* sieve/sieve.c: Rewrite support for --dry-run and --debug.
* sieve/tests/ext.at: Use --libdir-prefix instead of -L
2016-11-23 Sergey Poznyakoff <gray@gnu.org.ua>
Further cleanup of sieve namespace.
Prefix internal function names with mu_i_
2016-11-23 Sergey Poznyakoff <gray@gnu.org.ua>
Rewrite sieve parser.
Three objectives:
1. Simplify code. 2. Produce optimized sieve code. 3. Improve
error reporting. 4. Prepare for further extensions
* include/mailutils/sieve.h (mu_sieve_tag_checker_t): Change
signature (take mu_sieve_machine_t as the first arg). All uses
changed.
(mu_sieve_require): Likewise.
(mu_sieve_yydebug): Remove global.
* libmu_sieve/sieve-priv.h (mu_locus_range): New struct.
(YYLTYPE): New define
(mu_sieve_state): New enum.
(mu_sieve_machine): New members: string_pool, state.
(mu_sieve_node_type): New enum.
(mu_sieve_node): New struct. Remove unused prototypes.
* libmu_sieve/sieve.l: Keep track of code locations. Use opool
for constructing string values.
* libmu_sieve/sieve.y: Rewrite. First build the parse tree.
Then optimize it. Finally, generate code.
* libmu_sieve/tests.c (sieve_test_true,sieve_test_false):
Remove. True and false tests are always optimized away.
* libmu_sieve/util.c (mu_sv_compile_error): Remove.
* libmu_sieve/actions.c: Use mu_diag_at_locus to report errors
and mu_i_sv_error to mark sieve machine as being in error
state.
* libmu_sieve/comparator.c: Likewise.
* libmu_sieve/prog.c (mu_sv_code): Replace with mu_i_sv_code.
(mu_sv_code_instr,mu_sv_code_handler)
(mu_sv_code_list,mu_sv_code_number)
(mu_sv_code_string,mu_sv_code_source)
(mu_sv_code_line,mu_sv_change_source)
(mu_sv_code_action,mu_sv_code_test)
(mu_sv_code_anyof,mu_sv_code_allof): Remove.
(mu_i_sv_locus,mu_i_sv_code_action)
(mu_i_sv_code_test): New function.
(mu_sv_code_command): Replace with a static function.
* libmu_sieve/require.c (mu_sieve_require): Take ptr to machine
as the first arg.
* libmu_sieve/runtime.c (mu_sieve_mailbox)
(mu_sieve_message): Refuse to run if the machine is in error
state.
* sieve/sieve.c: Update.
* sieve/tests/i-numeric.at: Update expected error message.
* libmailutils/diag/diag.c (mu_diag_at_locus): Don't pass locus
if mu_file is NULL.
* libmu_auth/ldap.c (_mu_entry_to_auth_data): Remove leftover
mu_error.
2016-11-14 Sergey Poznyakoff <gray@gnu.org>
Fix expansion of #, &, %, etc. in mail copy and file commands.
This was accidentally broken by commit eea2c4aa.
* include/mailutils/mailbox.h (mu_mailbox_expand_name): New
proto.
* libmailutils/mailbox/mbx_default.c (mu_mailbox_expand_name):
New function.
(mu_mailbox_create_default): Use it.
(mu_set_folder_directory): Accept NULL as argument.
(mu_folder_directory): Reset default value after assigning it.
This way the folder directory still defaults to the same value
as earlier, but can be reset to NULL, if so desired.
(plus_expand): Return a copy of the input string if folder is
NULL.
* mail/copy.c (append_to_mailbox): Use mu_mailbox_create, as
the mailbox name has already been expanded.
* mail/file.c (mail_expand_name): Use mu_mailbox_expand_name.
(mail_file): Use mu_mailbox_create, as the mailbox name has
already been expanded.
* mail/mailvar.c (mailvar_cmd): New enum.
(mailvar_symbol) <handler>: Change signature and return type.
(mailvar_set): Rewrite. Take care not to modify the variable if
the handler (if any) returns non-null or if the memory can't be
allocated.
(set_folder): Handler for the "folder" variable.
* mail/tests/copy01.at: New testcase.
* mail/tests/copy02.at: New testcase.
* mail/tests/copy03.at: New testcase.
* mail/tests/copy04.at: New testcase.
* mail/tests/Makefile.am: Add new tests.
* mail/tests/testsuite.at (MUT_MAIL_CMD): Set MAILRC to
/dev/null. Add new tests.
2016-11-11 Sergey Poznyakoff <gray@gnu.org.ua>
mhn: restore -compose mode as default.
2016-11-10 Sergey Poznyakoff <gray@gnu.org>
Fix program name duplicate in the output of "mailutils help
COMMAND"
2016-11-07 Sergey Poznyakoff <gray@gnu.org>
Version 3.0.
2016-11-05 Sergey Poznyakoff <gray@gnu.org>
Fix option sorting.
* libmailutils/opt/opt.c (sort_group): Don't assume stability
of the sort. Use auxiliary data structure to sort array of
options that contain aliases.
* libmailutils/tests/parseopt.c (set_prog_args): Fix delimiter.
* libmailutils/tests/strtoc.c (v_cidr_format): Error checking.
* maidag/Makefile.am (maidag_LDADD): Reorder libraries to make
sure maidag uses freshly built libraries (not the ones already
installed in the system).
* mh/pick.c (options): Bugfix.
2016-11-05 Sergey Poznyakoff <gray@gnu.org>
Add missing documentation.
2016-11-05 Sergey Poznyakoff <gray@gnu.org>
Minor changes.
2016-11-04 Sergey Poznyakoff <gray@gnu.org.ua>
Fix operation of mail -t; some other minor fixes.
* mail/escape.c (parse_headers): Moved to send.c
(check_headers): New function.
(escape_continue): Use check_headers.
* mail/mail.c (read_recipients): New variable. The -t option
sets read_recipients and editheaders
* mail/mail.h (parse_headers): New proto.
* mail/send.c: Special handling for -t option.
(parse_headers): New function.
* movemail/movemail.c (onerror statement): Accept a list as
argument.
* doc/texinfo/mailutils.texi: Update.
* doc/texinfo/programs.texi: Update.
2016-11-03 Sergey Poznyakoff <gray@gnu.org.ua>
Fix docs. Change argument of the field-map configuration
statement.
The field-map statement (.ldap.field-map & .sql.field-map)
takes a list of mappings as argument. For compatibility and for
internal purposes, a string is still allowed.
* doc/texinfo/programs.texi: Update.
* include/mailutils/cfg.h (mu_cfg_field_map): New proto.
* include/mailutils/sql.h (mu_password_type): Rename.
(mu_sql_module_config) <positional>: Remove.
(mu_sql_decode_password_type): Remove prototype.
* libmailutils/base/mutil.c (mu_sql_decode_password_type):
Remove function.
* libmailutils/cfg/driver.c (mu_cfg_field_map): New function.
* libmu_auth/ldap.c (cb_field_map): Use mu_cfg_field_map.
(module_init): Fix default filter.
* libmu_auth/sql.c (cb_field_map): Use mu_cfg_field_map.
(mu_sql_param): Rename "password-type" statement to
"password-encryption". Remove the "positional" statement.
2016-11-02 Sergey Poznyakoff <gray@gnu.org.ua>
Bugfix.
* libmailutils/cfg/parser.y (mu_cfg_parse_config): Silently
ignore ENOENT
2016-11-02 Sergey Poznyakoff <gray@gnu.org.ua>
Rename default configuration file.
The default configuration file name is "mailutils.conf". Legacy
configuration file "mailutils.rc" is processed if necessary.
* libmailutils/cli/cli.c: Rename main configuration file to
mailutils.conf Remove 'rcfile' option aliases.
(mu_cli_ext): Special handling for legacy configuration file.
* NEWS: Update.
* doc/texinfo/mailutils.texi: Update.
* doc/texinfo/programs.texi: Update.
2016-11-02 Sergey Poznyakoff <gray@gnu.org.ua>
Improve configuration file handling.
* include/mailutils/cfg.h (mu_cfg_parse_hints): Rename
site_rcfile to site_file, custom_rcfile to custom_file. Remove
append_tree and data fields.
(MU_PARSE_CONFIG_GLOBAL,MU_CFG_PARSE_PROGRAM): Remove.
(MU_PARSE_CONFIG_VERBOSE): Rename to MU_CF_VERBOSE.
(MU_PARSE_CONFIG_DUMP): Rename to MU_CF_DUMP.
(MU_CFG_FMT_LOCUS): Rename to MU_CF_FMT_LOCUS.
(MU_CFG_FMT_VALUE_ONLY): Rename to MU_CF_FMT_VALUE_ONLY.
(MU_CFG_FMT_PARAM_PATH): Rename to MU_CF_FMT_PARAM_PATH.
(MU_CFG_COMPATIBILITY,MU_CFG_DEPRECATED): Remove.
(mu_parse_config, mu_get_config): Remove deprecated functions.
* libmailutils/cli/cli.c (mu_general_help_text): New global.
(app_data): New struct.
(init_options): Construct configuration option group depending
on which configuration files are in use.
(mu_cli_ext): Don't use per-user configuration files for
servers. Pass pointer to app_data structure as po.po_data
(mu_cli): Set MU_CFHINT_PER_USER_FILE flag by default.
* mail/testsuite/lib/mail.exp: Rewrite invocation of the
mu_init command.
* include/mailutils/cli.h (mu_cli_setup) <server>: New field.
* comsat/comsat.c (cli): Mark as server.
(main): Bugfix: pass pointer to server to mu_cli.
* imap4d/imap4d.c (cli): Mark as server.
* pop3d/pop3d.c: Likewise.
* comsat/tests/testsuite.at: Use the --no-site-config option.
* imap4d/tests/testsuite.at: Likewise.
* libmailutils/cfg/driver.c: Update.
* libmailutils/cfg/format.c: Update.
* libmailutils/cfg/lexer.l: Update.
* libmailutils/cfg/parser.y: Update.
* mu/acl.c: Update.
* pop3d/testsuite/lib/pop3d.exp: Likewise.
* mu/mu.c: Don't read configuration files.
* mu/query.c: Fix args_doc
* testsuite/lib/mailutils.exp (mu_init): Change option
handling. Set --no-config option by default.
2016-11-01 Sergey Poznyakoff <gray@gnu.org.ua>
Fix in logstream.
* libmailutils/stream/logstream.c (_log_write): Force
MU_LOG_LOCUS mode if the locus is given explicitly.
2016-11-01 Sergey Poznyakoff <gray@gnu.org.ua>
Bugfixes in MH.
* mh/mh_getopt.c (mh_opt_notimpl_warning): For boolean options,
don't emit warning if the value would be set to false.
* mh/anno.c: Fix the type of boolean unimplemented options.
* mh/refile.c: Likewise.
* mh/repl.c: Likewise.
* mh/send.c: Likewise.
2016-10-31 Sergey Poznyakoff <gray@gnu.org.ua>
Minor fix.
2016-10-30 Sergey Poznyakoff <gray@gnu.org>
Improve opool API.
* configure.ac: Version 2.99.993
* NEWS: Update.
* include/mailutils/opool.h (MU_OPOOL_DEFAULT)
(MU_OPOOL_ENOMEMABRT): New defines.
(mu_opool_create): Change meaning of the 2nd argument. All uses
updated.
(mu_opool_free, mu_opool_dup): New proto.
* libmailutils/base/opool.c (_mu_opool) <memerr>: Replace with
flags.
<head,tail,free>: Rename.
(mu_opool_free, mu_opool_dup): New functions.
(mu_opool_head): Bugfix.
2016-10-29 Sergey Poznyakoff <gray@gnu.org>
Remove old compatibility quirks.
2016-10-29 Sergey Poznyakoff <gray@gnu.org>
Minor changes.
2016-10-29 Sergey Poznyakoff <gray@gnu.org>
Remove left over references to argp; other bugfixes.
2016-10-28 Sergey Poznyakoff <gray@gnu.org>
Bugfix.
* configure.ac: Version 2.99.992
* NEWS: Update.
* libmailutils/opt/opt.c (add_option_cache): Use opt_default if
no argument is given.
2016-10-24 Sergey Poznyakoff <gray@gnu.org>
Bugfix.
2016-10-24 Sergey Poznyakoff <gray@gnu.org>
Improve program usage output.
* include/mailutils/opt.h (MU_PARSEOPT_SPECIAL_ARGS): New flag.
(mu_parseopt)<po_special_args>: New field.
* libmailutils/opt/help.c (option_summary)
(print_program_usage): Print po_special_args, if defined.
* libmailutils/opt/opt.c (parseopt_init): Initialize
po_special_args unless MU_PARSEOPT_SPECIAL_ARGS is set.
MH: Advertise [+FOLDER] special argument if the -folder option
is declared.
* mh/mh_getopt.c (folder_option): Bugfix: -folder takes
argument.
(mh_getopt): Set po_special_args if the -folder option is
declared.
* mh/inc.c: Fix arg_doc.
* mh/mhpath.c: Likewise.
* mh/repl.c: Likewise.
* mh/rmf.c: Likewise.
* mh/rmm.c: Likewise.
* mh/scan.c: Likewise.
* mh/show.c: Likewise.
2016-10-23 Sergey Poznyakoff <gray@gnu.org.ua>
Bugfix.
2016-10-22 Sergey Poznyakoff <gray@gnu.org>
Bugfixes.
* libmailutils/cli/cli.c (mu_cli_ext): Initialize hints.data
(accidentally deleted).
* libmailutils/opt/help.c (mu_option_describe_options): Don't
display dup_args_note in single-dash mode.
* libmailutils/opt/progname.c (mu_set_program_name): Free the
old value after allocating new copy. This allows to pass
mu_full_program_name as argument. Set mu_program_name to point
to a segment of mu_full_program_name, not the original arg.
* mh/mh_getopt.c: Remove duplicate version option.
* po/POTFILES.in: Add missing files.
2016-10-22 Sergey Poznyakoff <gray@gnu.org>
Provide extended interface to mu_cli.
* include/mailutils/cfg.h (MU_CFG_APPEND_TREE): New flag.
* include/mailutils/cli.h (mu_version_copyright): New extern.
(mu_cli_ext): New proto.
* libmailutils/cfg/parser.y (mu_cfg_parse_config): Check for
MU_CFG_APPEND_TREE bit set before accessing hints->append_tree.
* libmailutils/cli/cli.c (param_set): Likewise.
(mu_cli_ext): New function.
(mu_cli): Rewrite as an entry point to mu_cli_ext.
* comsat/comsat.c: Remove inclusion of obsolete headers.
* mu/help.c: Likewise.
* pop3d/extra.c: Likewise.
2016-10-22 Sergey Poznyakoff <gray@gnu.org>
Bugfixes.
* libmu_auth/ldap.c: Fix compilation without ldap
* mh/mh_getopt.c: Fix version output to match what MH-E expects
2016-10-22 Sergey Poznyakoff <gray@gnu.org>
MH: Fix MH-E compatibility.
* include/mailutils/cli.h (mu_version_func): Rename to
mu_version_hook.
* libmailutils/cli/cli.c: Likewise.
* pop3d/popauth.c: Likewise.
* mh/mh_getopt.c: (mh_getopt): Initialize NLS support. Install
standard version hook (needed for mh-e autodetect feature).
* mh/ali.c: Update prog_doc. Remove NLS initialization.
* mh/anno.c: Likewise
* mh/burst.c: Likewise
* mh/comp.c: Likewise
* mh/fmtcheck.c: Likewise
* mh/folder.c: Likewise
* mh/forw.c: Likewise
* mh/inc.c: Likewise
* mh/install-mh.c: Likewise
* mh/mark.c: Likewise
* mh/mhl.c: Likewise
* mh/mhn.c: Likewise
* mh/mhparam.c: Likewise
* mh/mhpath.c: Likewise
* mh/mhseq.c: Likewise
* mh/msgchk.c: Likewise
* mh/pick.c: Likewise
* mh/prompter.c: Likewise
* mh/refile.c: Likewise
* mh/repl.c: Likewise
* mh/rmf.c: Likewise
* mh/rmm.c: Likewise
* mh/scan.c: Likewise
* mh/send.c: Likewise
* mh/show.c: Likewise
* mh/sortm.c: Likewise
* mh/whatnow.c: Likewise
* mh/whom.c: Likewise
2016-10-22 Sergey Poznyakoff <gray@gnu.org>
Finish conversion of MH utilities to mh_parseopt.
This finishes work started at commit bc73fc65.
* include/mailutils/opt.h (mu_option_cache) <cache_arg>: Made
const.
* libmailutils/opt/opt.c (mu_option_cache_destroy): Don't free
cache_arg.
* doc/texinfo/mu-mh.texi: Update.
* po/POTFILES.in: Remove obsolete files.
* mh/tests/refile.at: Don't use double-dash options.
* mh/mh_getopt.c (mh_opt_set_folder): New function.
* mh/mh_getopt.h: Likewise.
* mh/mhn.c: Convert to mh_getopt.
* mh/mhparam.c: Likewise.
* mh/mhpath.c: Likewise.
* mh/mhseq.c: Likewise.
* mh/msgchk.c: Likewise.
* mh/pick.c: Likewise.
* mh/pick.h: Likewise.
* mh/pick.y: Likewise.
* mh/prompter.c: Likewise.
* mh/refile.c: Likewise.
* mh/repl.c: Likewise.
* mh/rmf.c: Likewise.
* mh/rmm.c: Likewise.
* mh/scan.c: Likewise.
* mh/send.c: Likewise.
* mh/show.c: Likewise.
* mh/sortm.c: Likewise.
* mh/whatnow.c: Likewise.
* mh/whom.c: Likewise.
2016-10-21 Sergey Poznyakoff <gray@gnu.org.ua>
Begin rewriting MH to get rid of argp stuff.
MH utilities will use only single-dash long options.
* include/mailutils/opt.h (mu_option) <opt_default>: New
member.
* libmailutils/opt/opt.c (find_long_option): Improve detection
of ambiguous options.
(mu_option_set_value): Use default value (opt_default), if
supplied.
* mh/mh_argp.c: Delete.
* mh/Makefile.am (libmh_a_SOURCES): Remove mh_argp.c
* mh/mh_getopt.c: Rewrite from scratch using mailutils/opt
* mh/mh_getopt.h: Likewise.
* mh/mh.h: Add missing includes
(mh_read_formfile, mh_alias_read): Change signatures.
* mh/mh_alias.l (mh_alias_read): Name is const
* mh/mh_init.c (mh_read_formfile): Name is const.
* mh/ali.c: Convert to mh_getopt.
* mh/anno.c: Likewise.
* mh/burst.c: Likewise.
* mh/comp.c: Likewise.
* mh/fmtcheck.c: Likewise.
* mh/folder.c: Likewise.
* mh/forw.c: Likewise.
* mh/inc.c: Likewise.
* mh/install-mh.c: Likewise.
* mh/mark.c: Likewise.
* mh/mhl.c: Likewise.
* mh/scan.c: Likewise.
* mh/tests/burst.at: Don't use double-dash options
* mh/tests/folder.at: Likewise.
2016-10-20 Sergey Poznyakoff <gray@gnu.org.ua>
Support for single-dash long options (as in MH) and negation
for boolean options.
* include/mailutils/opt.h (MU_PARSEOPT_SINGLE_DASH)
(MU_PARSEOPT_NEGATION): New flags.
(mu_parseopt) <po_negation, po_long_opt_start>: New fields.
(mu_option_describe_options): Change signature.
* libmailutils/opt/help.c (init_usage_vars): Initialize
long_opt_col depending on the value of MU_PARSEOPT_SINGLE_DASH
bit.
(print_option): Handle single-dash long options and boolean
options with negations.
(option_summary): Likewise.
(mu_option_describe_options): Take struct mu_parseopt * as its
second parameter.
* libmailutils/opt/opt.c (find_long_option): Handle boolean
options with negations. Return also a pointer to the mu_option
describing the originally used option (as opposed to the
canonical one returned by the function).
(parse): Handle single-dash long options.
(parseopt_init): Initialize po_negation and po_long_opt_start.
* libmailutils/tests/parseopt.c (parseopt_param): Handle
MU_PARSEOPT_SINGLE_DASH and MU_PARSEOPT_NEGATION.
2016-10-20 Sergey Poznyakoff <gray@gnu.org>
Minor fix in wordwrapper stream.
* libmailutils/stream/wordwrap.c (set_margin): Flush the stream
if the new margin equals the current offset.
(_wordwrap_write): Fix conditional
2016-10-20 Sergey Poznyakoff <gray@gnu.org>
Minor fix.
* mu/ldflags.c: Ignore "cfg" and "argp" keywords.
2016-10-19 Sergey Poznyakoff <gray@gnu.org>
Minor fix.
2016-10-19 Sergey Poznyakoff <gray@gnu.org.ua>
Rename MU_APP_NEW_LIBRARIES back to MU_APP_LIBRARIES. Version
2.99.991.
2016-10-19 Sergey Poznyakoff <gray@gnu.org.ua>
Convert remaining utilities (except mh) to mu_cli.
* Makefile.am: Remove libmu_argp and libmu_cfg
* configure.ac: Likewise.
* libmu_argp/: Remove.
* libmu_cfg/: Remove.
* include/mailutils/Makefile.am (pkginclude_HEADERS): Remove
gocs.h, libargp.h, libcfg.h
* frm/frm.c: Register tls auth module
* frm/from.c: Likewise.
* maidag/maidag.c: Likewise.
* mail/mail.c: Likewise.
* messages/messages.c: Likewise.
* movemail/movemail.c: Likewise.
* readmsg/readmsg.c: Likewise.
* sieve/sieve.c: Likewise.
* frm/frm.h: Remove obsolete includes
* imap4d/Makefile.am: Update.
* imap4d/imap4d.c: Use mu_cli for command line and
configuration parsing.
* imap4d/imap4d.h: Update.
* include/mailutils/gocs.h: Remove.
* libmailutils/cfg/gocs.c: Remove.
* libmailutils/cfg/Makefile.am: Remove gocs.c
* include/mailutils/cli.h (mu_cli_capa_apply): Rename to
mu_cli_capa_extend_settings
(mu_cli_setup) <inorder, prog_doc_hook>: New fields.
* include/mailutils/daemon.h: Remove obsolete includes.
* include/mailutils/gsasl.h: Likewise.
* include/mailutils/mailutils.h: Update.
* include/mailutils/mu_auth.h (mu_auth_mode): New enum
(mu_auth_module): Redo structure.
* include/mailutils/opt.h (mu_parseopt) <po_prog_doc_hook>: New
field.
* include/mailutils/sql.h (mu_sql_module_config): New extern.
(mu_sql_interface_index): Change proto.
* libmailutils/auth/mu_auth.c: Rewrite.
* libmailutils/auth/system.c (mu_auth_system_module): Update
structure
* libmailutils/cli/capa.c (mu_cli_capa_apply): Rename to
mu_cli_capa_extend_settings
* libmailutils/cli/cli.c: Extend settings from auth modules as
well.
* libmailutils/opt/help.c (mu_program_help): Invoke
po_prog_doc_hook if defined.
* libmailutils/opt/opt.c (parseopt_init): Check the
MU_PARSEOPT_PROG_DOC_HOOK flag.
(find_long_option): Fix recognition of ambiguous options in
case of exact match.
* libmu_auth/gsasl.c: Add configuration.
* libmu_auth/ldap.c: Likewise.
* libmu_auth/pam.c: Likewise.
* libmu_auth/radius.c: Likewise.
* libmu_auth/sql.c: Likewise.
* libmu_auth/tls.c: Likewise.
* libmu_auth/virtual.c: Likewise.
* mu/Makefile.am: Update.
* mu/mu.c: Rewrite using mu_cli
* mu/mu.h: Likewise.
* mu/acl.c: Likewise.
* mu/cflags.c: Likewise.
* mu/dbm.c: Likewise.
* mu/dispatch.c: Likewise.
* mu/filter.c: Likewise.
* mu/flt2047.c: Likewise.
* mu/getans.c: Likewise.
* mu/getarg.c: Likewise.
* mu/getyn.c: Likewise.
* mu/help.c: Likewise.
* mu/imap.c: Likewise.
* mu/info.c: Likewise.
* mu/ldflags.c: Likewise.
* mu/logger.c: Likewise.
* mu/pop.c: Likewise.
* mu/query.c: Likewise.
* mu/send.c: Likewise.
* mu/shell.c: Likewise.
* mu/smtp.c: Likewise.
* mu/util.c: Likewise.
* mu/verbose.c: Likewise.
* mu/wicket.c: Likewise.
* pop3d/Makefile.am: Update.
* pop3d/pop3d.c: Convert to mu_cli interface.
* pop3d/pop3d.h: Likewise.
* sql/sql.c (mu_sql_interface_index): Change argument
qualifiers.
2016-10-17 Sergey Poznyakoff <gray@gnu.org>
Convert pop3d to mu_cli.
2016-10-16 Sergey Poznyakoff <gray@gnu.org>
Convert popauth to mu_cli.
2016-10-16 Sergey Poznyakoff <gray@gnu.org>
Convert maidag to mu_cli.
2016-10-16 Sergey Poznyakoff <gray@gnu.org>
Convert comsat to mu_cli.
2016-10-16 Sergey Poznyakoff <gray@gnu.org>
Convert examples to mu_cli.
2016-10-16 Sergey Poznyakoff <gray@gnu.org>
Minor fix in help output.
Print "[OPTION...]", instead of "[OPTION]..."
2016-10-16 Sergey Poznyakoff <gray@gnu.org.ua>
Convert mail to mu_cli.
2016-10-16 Sergey Poznyakoff <gray@gnu.org>
Allow for multiple argument sets in help output.
Alternative invocations follow the main one, each on a separate
line, preceded by " or: ".
* include/mailutils/cli.h (mu_cli_setup) <prog_alt_args>: New
member.
* include/mailutils/opt.h (mu_parseopt) <po_prog_args>: Change
type.
(mu_program_usage): Change signature.
* include/mailutils/stream.h (MU_IOCTL_WORDWRAP_GET_OFFSET):
Rename to MU_IOCTL_WORDWRAP_GET_COLUMN. All uses changed.
* libmailutils/cli/cli.c (mu_cli): Construct po.po_prog_args
from prog_args and prog_alt_args.
* libmailutils/opt/help.c (move_margin): Remove.
(print_program_usage): New static function.
(mu_program_usage): Second argument instructs how to display
options. Main work is done by print_program_usage.
(mu_program_help): Call print_program_usage.
* libmailutils/opt/opt.c: Update.
* libmailutils/stream/wordwrap.c (set_margin): Avoid
unnecessary flushes.
* libmailutils/tests/parseopt.c (MU_PARSEOPT_PROG_ARGS):
Alternative argument sets are separated by the pipe sign.
* libmailutils/tests/Makefile.am: Add new testcase.
* libmailutils/tests/testsuite.at: Likewise.
* libmailutils/tests/parseopt_help04.at: Add
MU_PARSEOPT_PROG_ARGS to keywords.
* libmailutils/tests/parseopt_help12.at: New file.
* libmailutils/tests/tcli.c (cli): Add alternative arguments.
* dotlock/dotlock.c: Update.
* mimeview/mimeview.c: Likewise.
* sieve/sieve.c: Likewise.
2016-10-15 Sergey Poznyakoff <gray@gnu.org>
Rewrite parseopt help routines using wordwrap streams.
* include/mailutils/stream.h
(MU_IOCTL_WORDWRAP_SET_NEXT_MARGIN)
(MU_IOCTL_WORDWRAP_GET_OFFSET): New opcodes.
* libmailutils/stream/wordwrap.c (_wordwrap_flush_line):
Replace whitespace-only lines with single newline on output.
(_wordwrap_flush): Fix condition.
(set_margin): Bugfix.
(_wordwrap_ctl): Handle new opcodes.
* include/mailutils/cli.h (mu_version_func): Change signature.
* include/mailutils/opt.h (mu_parseopt) <po_help_hook>
<po_version_hook>: Change signature.
(mu_parseopt_fmt_text): Remove. (mu_option_describe_options,
mu_program_help)
(mu_program_usage): Change signature.
(mu_program_version): New prototype.
* libmailutils/cli/cli.c (mu_version_func): Take mu_stream_t as
2nd argument. Use mu_stream_printf for output.
(extra_help_hook): Likewise.
* libmailutils/opt/help.c: Rewrite using wordwrap streams.
* libmailutils/opt/opt.c (fn_help, fn_usage, fn_version):
Update.
* libmailutils/tests/parseopt.c (version_hook): Write to
mu_stream_t.
* libmailutils/tests/parseopt_help00.at: Fix expected output.
* libmailutils/tests/parseopt_help01.at: Likewise.
* libmailutils/tests/parseopt_help02.at: Likewise.
* libmailutils/tests/parseopt_help03.at: Likewise.
* libmailutils/tests/parseopt_help04.at: Likewise.
* libmailutils/tests/parseopt_help05.at: Likewise.
* libmailutils/tests/parseopt_help06.at: Likewise.
* libmailutils/tests/parseopt_help07.at: Likewise.
* libmailutils/tests/parseopt_help08.at: Likewise.
* libmailutils/tests/parseopt_help09.at: Likewise.
* libmailutils/tests/parseopt_help10.at: Likewise.
* libmailutils/tests/parseopt_help11.at: Likewise.
2016-10-14 Sergey Poznyakoff <gray@gnu.org>
Implement simple word-wrapping stream.
* include/mailutils/stream.h (MU_IOCTL_WORDWRAPSTREAM): New
ioctl.
(mu_wordwrap_stream_create): New proto.
* libmailutils/stream/Makefile.am: add wordwrap.c
* libmailutils/stream/wordwrap.c: New file.
* libmailutils/tests/Makefile.am: Add new testcases.
* libmailutils/tests/testsuite.at: Include new testcases.
* libmailutils/tests/wordwrap.c: New file.
* libmailutils/tests/wordwrap00.at: New file.
* libmailutils/tests/wordwrap01.at: New file.
* libmailutils/tests/wordwrap02.at: New file.
* libmailutils/tests/wordwrap03.at: New file.
2016-10-13 Sergey Poznyakoff <gray@gnu.org.ua>
Bugfixes in libmailutils/opt/opt.c.
2016-10-12 Sergey Poznyakoff <gray@gnu.org.ua>
Fix some incompatibilities in the previous commit.
* dotlock/dotlock.c (force): Change type to unsigned. Provide
default value for --force.
(cli): Set exit codes and extra docstring.
* include/mailutils/cli.h (mu_cli_setup): New members:
prog_extra_doc, ex_usage, ex_config.
* include/mailutils/opt.h (mu_parseopt_getcolumn)
(mu_parseopt_fmt_text): New prototypes.
* libmailutils/cli/cli.c (extra_help_hook): New hook.
(mu_cli): Set up customized exit codes. Pass pointer to struct
mu_cli_setup in hints.data. All uses changed. Set up help hook
if setup->prog_extra_doc is defined.
* libmailutils/opt/help.c (mu_parseopt_getcolumn): New
function.
(print_option_descr): Honor explicit newlines.
(mu_parseopt_fmt_text): New function.
* mimeview/mimeview.c (cli): Provide extra docs.
* sieve/sieve.c: Likewise.
2016-10-12 Sergey Poznyakoff <gray@gnu.org>
Convert to mu_cli: frm, from, messages, mimeview, movemail,
readmsg, sieve.
* configure.ac (MU_APP_NEW_LIBRARIES): New temp variable.
* include/mailutils/sieve.h (mu_cli_capa_sieve): New extern.
* include/mailutils/tls.h (mu_cli_capa_tls): New extern.
* libmailutils/cli/cli.c: Minor change.
* libmailutils/cli/stdcapa.c: Add "auth" capability.
* libmu_auth/tls.c: provide mu_cli_capa_tls
* dotlock/Makefile.am: Link with MU_APP_NEW_LIBRARIES
* dotlock/dotlock.c
* frm/Makefile.am: Link with MU_APP_NEW_LIBRARIES
* frm/frm.h: Fix includes.
* frm/frm.c: Use mu_cli for option & config parsing.
* frm/from.c: Likewise.
* messages/Makefile.am: Link with MU_APP_NEW_LIBRARIES
* messages/messages.c: Use mu_cli for option & config parsing.
* mimeview/Makefile.am: Link with MU_APP_NEW_LIBRARIES
* mimeview/mimeview.c: Use mu_cli for option & config parsing.
* movemail/Makefile.am: Link with MU_APP_NEW_LIBRARIES
* movemail/movemail.c: Use mu_cli for option & config parsing.
* readmsg/Makefile.am: Link with MU_APP_NEW_LIBRARIES
* readmsg/readmsg.c: Use mu_cli for option & config parsing.
* sieve/Makefile.am: Link with MU_APP_NEW_LIBRARIES
* sieve/sieve.c: Use mu_cli for option & config parsing.
2016-10-11 Sergey Poznyakoff <gray@gnu.org>
Bugfix.
* libmailutils/opt/opt.c (find_long_option): Don't mark
ambiguity if the matching option unaliases to the same option
as the found one.
2016-10-11 Sergey Poznyakoff <gray@gnu.org>
Introduce new CLI/configuration code for mailutils
applications.
The new API is to replace libmu_cfg and libmu_argp. A smooth
transition is scheduled, during which the two APIs will
coexist,
* configure.ac: Build libmailutils/cli/Makefile
* include/mailutils/cli.h: New file.
* include/mailutils/Makefile.am: Add cli.h
* libmailutils/cli/Makefile.am: New file.
* libmailutils/cli/capa.c: New file.
* libmailutils/cli/cli.c: New file.
* libmailutils/cli/stdcapa.c: New file.
* libmailutils/Makefile.am (SUBDIRS): Add cli.
* include/mailutils/cfg.h (mu_cfg_parse_hints): New members:
append_tree and data.
(MU_PARSE_CONFIG_LINT): New flag.
* include/mailutils/diag.h (mu_program_name)
(mu_full_program_name): Remove const qualifier.
* include/mailutils/locker.h
(mu_locker_set_default_external_program): Argument is const.
* libmailutils/base/locker.c: Likewise.
* include/mailutils/opt.h (mu_progname, mu_absprogname):
Replace with mu_program_name and mu_full_program_name.
(mu_set_progname): Rename to mu_set_program_name.
(mu_parseopt) <po_data>: Change type to void *.
(po_help_hook, po_version_hook): Change signatures.
(mu_parseopt_error): New function.
* libmailutils/opt/progname.c (mu_progname, mu_absprogname):
Replace with mu_program_name and mu_full_program_name.
(mu_set_progname): Rename to mu_set_program_name.
* libmailutils/opt/help.c: Minor changes
* libmailutils/opt/opt.c (parse_error): Rename to
mu_parse_error (extern).
(next_opt): Fix permutations.
* libmailutils/tests/parseopt.c: Reflect changes.
* libmailutils/tests/parseopt17.at: Improve test case
* libmailutils/tests/parseopt_help05.at: Reflect changes.
* libmailutils/tests/parseopt_help07.at: Reflect changes.
* include/mailutils/stdstream.h (mu_program_name): Remove
qualifier.
* libmailutils/cfg/driver.c (mu_cfg_tree_reduce): Remove
useless condition
* libmailutils/cfg/lexer.l (mu_cfg_parse_file): Additional info
messages.
* libmailutils/cfg/parser.y (mu_cfg_parse_config): Join in the
append_tree.
* libmailutils/diag/diag.c (mu_program_name,
mu_full_program_name)
(mu_set_program_name): Remove. Declared elsewhere.
* libmu_sieve/conf.c: Add new configuration code. Mark old text
for removal.
* libmailutils/tests/tcli.c: New program.
* libmailutils/tests/Makefile.am: Add tcli.c
2016-10-10 Sergey Poznyakoff <gray@gnu.org>
Raise shared library version number.
* configure.ac (VI_CURRENT): Set to 5 Don't link intprops.h
* gnulib: Upgrade.
* gnulib.modules (intprops) Remove.
* libmailutils/cfg/parser.y: Don't include intprops.h
* po/POTFILES.in: Add new files.
2016-10-10 Sergey Poznyakoff <gray@gnu.org.ua>
Add missing test.
2016-10-10 Sergey Poznyakoff <gray@gnu.org.ua>
Fix help output. Test it.
* include/mailutils/opt.h (MU_PARSEOPT_EXTRA_INFO)
(MU_PARSEOPT_EXIT_ERROR): New flags.
(struct mu_parseopt) <po_extra_info>: New member.
<po_exit_error>: New member.
* libmailutils/opt/help.c: Fix help output formatting.
Implement support for ARGP_HELP_FMT envvar.
* libmailutils/opt/opt.c (add_option_cache): Honor
MU_PARSEOPT_IMMEDIATE.
(parseopt_init): Initialize each member separately.
* libmailutils/tests/parseopt.c: Rewrite envvar handling.
* libmailutils/tests/Makefile.am: Add new tests.
* libmailutils/tests/testsuite.at (PARSEOPT_DEFAULT): New
define.
* libmailutils/tests/parseopt00.at: Use PARSEOPT_DEFAULT.
* libmailutils/tests/parseopt01.at: Likewise.
* libmailutils/tests/parseopt02.at: Likewise.
* libmailutils/tests/parseopt03.at: Likewise.
* libmailutils/tests/parseopt04.at: Likewise.
* libmailutils/tests/parseopt05.at: Likewise.
* libmailutils/tests/parseopt06.at: Likewise.
* libmailutils/tests/parseopt07.at: Likewise.
* libmailutils/tests/parseopt08.at: Likewise.
* libmailutils/tests/parseopt09.at: Likewise.
* libmailutils/tests/parseopt10.at: Likewise.
* libmailutils/tests/parseopt11.at: Likewise.
* libmailutils/tests/parseopt12.at: Likewise.
* libmailutils/tests/parseopt13.at: Likewise.
* libmailutils/tests/parseopt14.at: Likewise.
* libmailutils/tests/parseopt15.at: Likewise.
* libmailutils/tests/parseopt16.at: Likewise.
* libmailutils/tests/parseopt17.at: Likewise.
* libmailutils/tests/parseopt18.at: Likewise.
* libmailutils/tests/parseopt19.at: Likewise.
* libmailutils/tests/parseopt20.at: Likewise.
* libmailutils/tests/parseopt21.at: Likewise.
* libmailutils/tests/parseopt22.at: Likewise.
* libmailutils/tests/parseopt23.at: New test.
* libmailutils/tests/parseopt24.at: New test.
* libmailutils/tests/parseopt25.at: New test.
* libmailutils/tests/parseopt_help00.at: New test.
* libmailutils/tests/parseopt_help01.at: New test.
* libmailutils/tests/parseopt_help02.at: New test.
* libmailutils/tests/parseopt_help03.at: New test.
* libmailutils/tests/parseopt_help04.at: New test.
* libmailutils/tests/parseopt_help05.at: New test.
* libmailutils/tests/parseopt_help06.at: New test.
* libmailutils/tests/parseopt_help07.at: New test.
* libmailutils/tests/parseopt_help08.at: New test.
* libmailutils/tests/parseopt_help09.at: New test.
* libmailutils/tests/parseopt_help10.at: New test.
* libmailutils/tests/parseopt_help11.at: New test.
2016-10-09 Sergey Poznyakoff <gray@gnu.org.ua>
Fix mu_parseopt. Add testsuite for it.
* include/mailutils/opt.h (mu_parseopt) <po_permuted>: New
member.
* libmailutils/opt/help.c (print_option): Fix display of
optional arguments.
* libmailutils/opt/opt.c (next_opt,parse): Fix
start-of-arguments index. Move permutation into a separate
function.
* libmailutils/opt/progname.c (mu_set_progname): Remove
eventual lt- prefix.
* libmailutils/tests/Makefile.am: Add new tests.
* libmailutils/tests/parseopt.c: Use environment to control
mu_parseopt flags.
* libmailutils/tests/testsuite.at: Add new tests.
* libmailutils/tests/strtoc.at: Update.
* libmailutils/tests/parseopt00.at: New file.
* libmailutils/tests/parseopt01.at: New file.
* libmailutils/tests/parseopt02.at: New file.
* libmailutils/tests/parseopt03.at: New file.
* libmailutils/tests/parseopt04.at: New file.
* libmailutils/tests/parseopt05.at: New file.
* libmailutils/tests/parseopt06.at: New file.
* libmailutils/tests/parseopt07.at: New file.
* libmailutils/tests/parseopt08.at: New file.
* libmailutils/tests/parseopt09.at: New file.
* libmailutils/tests/parseopt10.at: New file.
* libmailutils/tests/parseopt11.at: New file.
* libmailutils/tests/parseopt12.at: New file.
* libmailutils/tests/parseopt13.at: New file.
* libmailutils/tests/parseopt14.at: New file.
* libmailutils/tests/parseopt15.at: New file.
* libmailutils/tests/parseopt16.at: New file.
* libmailutils/tests/parseopt17.at: New file.
* libmailutils/tests/parseopt18.at: New file.
* libmailutils/tests/parseopt19.at: New file.
* libmailutils/tests/parseopt20.at: New file.
* libmailutils/tests/parseopt21.at: New file.
* libmailutils/tests/parseopt22.at: New file.
2016-10-08 Sergey Poznyakoff <gray@gnu.org.ua>
Use mu_c_type_t throughout the code. Get rid of
mu_cfg_param_data_type.
* include/mailutils/cfg.h (mu_cfg_param_data_type): Remove.
(mu_cfg_param_type): New enum.
(mu_cfg_param) <type>: Change type to int.
(mu_cfg_cidr): Remove.
(mu_cfg_parse_boolean): Remove. All uses updated.
* include/mailutils/util.h (mu_c_void): New constant.
(mu_c_type_str): New extern/
* libmailutils/string/str_to_c.c (mu_c_type_str): New global.
* libmailutils/cfg/format.c (mu_cfg_data_type_string): Rename
to mu_c_type_string; change argument type. All uses updated.
* libmailutils/cfg/parser.y: Use mu_str_to_c for value
conversion.
* libmailutils/tests/.gitignore: Update.
* libmailutils/tests/Makefile.am: Add strtoc.at; build strtoc
* libmailutils/tests/strtoc.at: New file.
* libmailutils/tests/strtoc.c: New file.
* libmailutils/tests/testsuite.at: Include strtoc.at
* comsat/comsat.c: Use mu_c_type_t types.
* dotlock/dotlock.c: Likewise.
* imap4d/imap4d.c: Likewise.
* lib/manlock.c: Likewise.
* lib/tcpwrap.c: Likewise.
* libmailutils/server/msrv.c: Likewise.
* libmu_argp/muinit.c: Likewise.
* libmu_cfg/common.c: Likewise.
* libmu_cfg/gsasl.c: Likewise.
* libmu_cfg/ldap.c: Likewise.
* libmu_cfg/pam.c: Likewise.
* libmu_cfg/radius.c: Likewise.
* libmu_cfg/sieve.c: Likewise.
* libmu_cfg/sql.c: Likewise.
* libmu_cfg/tls.c: Likewise.
* libmu_cfg/virtdomain.c: Likewise.
* maidag/maidag.c: Likewise.
* mimeview/mimeview.c: Likewise.
* movemail/movemail.c: Likewise.
* pop3d/pop3d.c: Likewise.
* readmsg/readmsg.c: Likewise.
* sieve/sieve.c: Likewise.
2016-10-07 Sergey Poznyakoff <gray@gnu.org.ua>
Add generic library for option parsing.
* configure.ac: Build libmailutils/opt
* include/mailutils/Makefile.am: Add opt.h
* include/mailutils/opt.h: New file.
* include/mailutils/util.h (mu_c_type_t): New datatype.
(mu_str_to_c): New proto.
* libmailutils/Makefile.am: Add opt to subdirs.
* libmailutils/opt/Makefile.am: New file.
* libmailutils/opt/help.c: New file.
* libmailutils/opt/opt.c: New file.
* libmailutils/opt/progname.c: New file.
* libmailutils/string/Makefile.am: Add new files.
* libmailutils/string/str_to_c.c: New file.
* libmailutils/string/to_sn.c: New file.
* libmailutils/string/to_un.c: New file.
* libmailutils/tests/.gitignore: Update.
* libmailutils/tests/Makefile.am: Update.
* libmailutils/tests/parseopt.c: New file.
2016-10-06 Sergey Poznyakoff <gray@gnu.org.ua>
Bugfixes.
* mh/rmf.c (current_folder_path): Treat name as folder while
expanding.
* mail/unset.c (mail_unset): Fix the behavior when no arguments
were given.
2016-08-22 Sergey Poznyakoff <gray@gnu.org.ua>
Allow to configure the length of the backlog queue for TCP
servers.
New statement backlog is provided in the server block.
* include/mailutils/server.h (mu_m_server_cfg_init): Pass
mu_m_server_t as first argument.
* libmailutils/server/msrv.c (mu_m_server_cfg_init): Pass
mu_m_server_t as first argument. Customize available statements
depending on the type of server (tcp vs udp). New statement
"backlog" available for tcp servers.
* comsat/comsat.c: Update call to mu_m_server_cfg_init
* imap4d/imap4d.c: Likewise.
* pop3d/pop3d.c: Likewise.
* maidag/maidag.c: Likewise.
2016-08-22 Sergey Poznyakoff <gray@gnu.org.ua>
Minor fixes.
* libmailutils/tests/modtofsaf.c (main): Trivial fix.
* mail/mail.c: Support "address" capability.
* mu/shell.c: Trivial fixes
2016-08-22 Sergey Poznyakoff <gray@gnu.org.ua>
Force using gnu-mh in Emacs after loading mailutils-mh.
* mh/etc/mailutils-mh.eli: Force using gnu-mh
2016-08-22 Sergey Poznyakoff <gray@gnu.org.ua>
Fix docstrings for -nowhatnowproc.
2016-08-21 Sergey Poznyakoff <gray@gnu.org.ua>
mh: fix the -nowhatnowproc option.
The -nowhatnowproc option inhibits the invocation of whatnow,
and consequently, prevents the editing of the draft from
occurring.
2016-07-04 Sergey Poznyakoff <gray@gnu.org.ua>
Fix memory allocation in libmu_imap.
* libproto/imap/tag.c (_mu_imap_tag_incr): Fix size calculation
when reallocating tag_buf
(_mu_imap_tag_clr): Re-initialize members on error.
2016-06-15 Sergey Poznyakoff <gray@gnu.org.ua>
Revert changes to msgset test utility.
The changes would be nice, if it weren't for the fact that
libproto is not yet built by the time libmailutils/tests are
compiled.
2016-06-15 Sergey Poznyakoff <gray@gnu.org>
Gracefully handle empty mailboxes in mu_msgset_parse_imap.
* libmailutils/msgset/parse.c (MU_MSGSET_EMPTY): New constant.
(parse_msgrange): Don't add any ranges if mode is set to
MU_MSGSET_EMPTY.
(mu_msgset_parse_imap): Force MU_MSGSET_EMPTY mode if the
mailbox is empty.
* libmailutils/msgset/print.c (mu_msgset_print): Handle empty
message sets.
* libmailutils/msgset/trans.c (_mu_msgset_translate_pair):
Initialize variable.
* libmailutils/tests/Makefile.am (msgset_LDADD): New variable.
* libmailutils/tests/msgset.c (parse_msgset): Take mailbox as
first argument.
(main): New option -mailbox
2016-02-08 Sergey Poznyakoff <gray@gnu.org.ua>
Minor fix.
* mu/smtp.c(com_list_param): Report if the connection has not
been established yet.
2016-01-22 Sergey Poznyakoff <gray@gnu.org>
Fix build without tcpwrappers.
* configure.ac (MU_TCPWRAP_LIBRARIES): New subst variable.
Always includes lib/libmutcpwrap.a. If libwrap is present on
the system and required, it is included as well
* imap4d/Makefile.am (TCPWRAP_LIBRARIES): Replace with
MU_TCPWRAP_LIBRARIES.
* maidag/Makefile.am: Likewise.
* pop3d/Makefile.am: Likewise.
2016-01-22 Sergey Poznyakoff <gray@gnu.org.ua>
Update copyright years.
2015-12-19 Sergey Poznyakoff <gray@gnu.org>
Bugfix in wordsplit test program.
* libmailutils/tests/wsp.c (make_env_kv): Fix array size.
2015-11-11 Sergey Poznyakoff <gray@gnu.org>
Minor fix.
* bootstrap.conf: Don't try to download anything if --help is
given
2015-11-10 Sergey Poznyakoff <gray@gnu.org>
Minor changes.
* libmu_argp/mailutils.c: Include argp-namefrob.h
* libproto/mailer/smtp_auth.c (get_ticket)
(_mu_smtp_fixup_params): Protect with WITH_GSASL
2015-11-10 Sergey Poznyakoff <gray@gnu.org>
Fix linking.
* configure.ac (MU_APP_LIBRARIES): Add libmuaux.la. This
complements a41e62b9 and fixes linking on systems that are
unable to track dynamic library dependencies.
2015-10-28 Sergey Poznyakoff <gray@gnu.org.ua>
Document Sieve extensions.
2015-10-27 Sergey Poznyakoff <gray@gnu.org.ua>
vacation: read message body from the file.
* doc/texinfo/sieve.texi: Document recent changes to vacation.
* libmu_sieve/extensions/vacation.c (vacation_reply): Handle
the "rfc2822" tag: if set together with :file, treat the file
as the RFC2822 message. Otherwise, read message body from it.
* sieve/tests/vacation.at: Add test for :rfc2822
2015-10-27 Sergey Poznyakoff <gray@gnu.org.ua>
User-defined headers in vacation extension.
New tag :header allows to set headers in the reply message
generated by the vacation extension.
2015-10-27 Sergey Poznyakoff <gray@gnu.org.ua>
Minor fixes.
* libproto/mailer/sendmail.c: Fix typo in debugging message.
* po/.gitignore: Update.
2015-10-27 Sergey Poznyakoff <gray@gnu.org.ua>
Maidag: avoid using auth_by_uid when delivering message.
When delivering message, the library may need to know the email
address of the user on behalf of whom maidag is called. In
particular, that happens when using the vacation extension. In
that case the library would construct the email by
concatenating user name, obtained as a result of
mu_get_auth_by_uid, and current domain name. Avoid this by
remembering email address the message is being delivered to.
* libmailutils/base/usremail.c (mu_set_user_email): NULL
argument clears email.
(mu_get_user_email): Use EUID instead of UID.
* maidag/deliver.c (do_delivery): Set user email prior to
delivery.
* maidag/maidag.c (default_domain): New variable.
(maidag_cfg_param): New setting "domain".
* maidag/maidag.h (default_domain): New extern.
2015-10-27 Sergey Poznyakoff <gray@gnu.org.ua>
Improve debugging.
* libmailutils/diag/debug.c (mu_debug_log): Account for
eventual newlines in the generated message string.
* imap4d/io.c (imap4d_init_tls_server): Use mu_stream_strerror.
2015-10-27 Sergey Poznyakoff <gray@gnu.org.ua>
Bugfix.
* libproto/mailer/prog.c (url_to_argv): Free ws only if it was
initialized.
2015-10-27 Sergey Poznyakoff <gray@gnu.org.ua>
Minor fixes in Makefiles.
* include/mailutils/Makefile.am (errno.h): Use explicit file
names instead of implicit variables.
* include/mailutils/sys/Makefile.am (debcat.h): Likewise.
* libmailutils/diag/Makefile.am (muerrno.c): Likewise.
* libmu_argp/Makefile.am (libmu_argp_la_LIBADD): Use relative
path to .la,
2015-10-26 Sergey Poznyakoff <gray@gnu.org>
Vacation: improve compatibility with the Sendmail utility.
* libmu_sieve/extensions/vacation.c (match_addresses): Change
arguments: take primary email address as well as a list of
aliases.
(vacation_reply): Reply if the primary email or one of alias
emails are listed in recipient list of the original message.
New tag "always_reply" reverts to the old behavior: reply
regardless of whether the message is destined for us. Use the
current user email as the sender address of the vacation
message. New tag "return_address" sets the sender address
explicitly.
* sieve/tests/vacation.at: Add new tests.
2015-10-25 Sergey Poznyakoff <gray@gnu.org>
Fixes in sieve vacation extension.
* libmu_sieve/extensions/vacation.c (build_mime): Fix memory
leak. This also flushes the message body stream, so its content
becomes visible for the mailer.
(noreply_address_p): Rename "addresses" tag to "noreply".
(check_db): The "database" tag provides vacation database name.
(vacation_reply): Always set message headers.
(vacation_tags): Rename "addresses" tag to "noreply". New tag:
"database"
* sieve/tests/vacation.at: New file.
* sieve/tests/Makefile.am (TESTSUITE_AT): Add vacation.at.
* sieve/tests/testsuite.at: Include vacation.at.
* doc/texinfo/programs.texi: Minor change.
2015-09-20 Sergey Poznyakoff <gray@gnu.org>
Document mailbox types, variable extension, etc.
2015-09-19 Sergey Poznyakoff <gray@gnu.org>
Complement f160ca75.
* include/mailutils/wordsplit.h (MU_WRDSX_WORD)
(MU_WRDSX_QUOTE): New constants.
(mu_wordsplit_getwords): Rename to mu_wordsplit_get_words.
* libmailutils/string/wordsplit.c (mu_wordsplit_getwords):
Rename to mu_wordsplit_get_words.
* libmailutils/base/userprivs.c (mu_switch_to_privs): Fix
memory overrun when retrieving the current pointer.
* examples/header.c (main): Use mu_wordsplit_get_words
* imap4d/preauth.c (preauth_getvar): Rewrite according to the
new API.
* libmailutils/imapio/create.c (mu_imapio_create): Use
MU_WRDSX_ constants to address ws_escape.
* libmailutils/imapio/qstring.c: Likewise.
* libmailutils/mailbox/mbx_default.c: Minor fix.
* libmailutils/server/acl.c (acl_getvar): Rewrite according to
the new API.
* libmailutils/tests/wsp.c: Minor fix.
* libmailutils/url/create.c (_mu_url_create_internal): Bugfix:
alloc url->path.
* libmu_sieve/extensions/list.c (retrieve_next_header): Use
mu_wordsplit_get_words
* libproto/mailer/prog.c (prog_getvar): Rewrite according to
the new API.
* libproto/mailer/smtp_gsasl.c (get_implemented_mechs): Remove
unneeded assignment to ws.ws_wordv.
* mh/folder.c: Use mu_wordsplit_get_words.
* mh/mhn.c: Likewise.
* movemail/movemail.c (movemail_getvar): Rewrite according to
the new API.
2015-09-16 Sergey Poznyakoff <gray@gnu.org>
Port wordsplit from grecs 20616b88.
The updated version supports tilde and pathname expansion,
command substitution and standard shell-like replacement
constructs in variable substitution, such as ${X:-V} etc.
* include/mailutils/wordsplit.h: Update.
* libmailutils/string/wordsplit.c: Update.
* libmailutils/tests/wsp.c: Update.
* libmailutils/tests/wordsplit.at: Update unescape test.
* libmailutils/imapio/create.c (mu_imapio_create): Initialize
ws_escape array.
* libmailutils/mime/mimehdr.c (_mime_header_parse): Likewise.
* libmailutils/tests/modmesg.c: Use mu_wordsplit with
MU_WRDSF_NOSPLIT to run expansions on the string.
* mu/shell.c (shell_prompt): Likewise.
2015-08-24 Sergey Poznyakoff <gray@gnu.org>
Fix typos.
2015-08-04 Sergey Poznyakoff <gray@gnu.org>
Spelling fixes in ChangeLog.
2015-08-04 Sergey Poznyakoff <gray@gnu.org>
Bugfix.
* pop3d/bulletin.c (read_bulletin_db): Fix memory/descriptor
leak.
2015-07-11 Sergey Poznyakoff <gray@gnu.org>
Update NEWS.
2015-07-11 Sergey Poznyakoff <gray@gnu.org.ua>
Log ciphersuite info after successful initiation of TLS
connection.
* include/mailutils/stream.h (MU_IOCTL_TLSSTREAM): New ioctl
code.
(MU_IOCTL_TLS_GET_CIPHER_INFO): New ioctl opcode.
* libmailutils/property/assocprop.c (_assoc_prop_fill)
(_assoc_prop_save): allow for NULL stream pointer.
* libmu_auth/tls.c (_tls_io_ioctl,_tls_ioctl): Handle
MU_IOCTL_TLSSTREAM/MU_IOCTL_TLS_GET_CIPHER_INFO ioctl.
* imap4d/io.c (log_cipher): New function.
(io_setio, imap4d_init_tls_server): Call log_cipher after
successfully establishing the TLS connection.
* imap4d/starttls.c (tls_encryption_on): Remove diagnostic
output.
* pop3d/extra.c (log_cipher): New function.
(pop3d_setio,pop3d_init_tls_server): Call log_cipher after
successfully establishing the TLS connection.
2015-07-11 Sergey Poznyakoff <gray@gnu.org.ua>
Minor fixes.
* libmailutils/mailbox/mbx_default.c
(mu_normalize_mailbox_url): don't place / in front of the
username.
(plus_expand): Use mu_make_file_name and mu_asprintf. Check for
errors.
(mu_mailbox_create_default): Check for errors.
2015-07-10 Sergey Poznyakoff <gray@gnu.org.ua>
Fix TLS streams.
Avoid calling gnutls_global_init (via mu_tls_module_init) prior
to forking. gnutls_global_init opens at least one file
descriptor (/dev/urandom), and closing it will disrupt its
operation. Current stable libgnutls (3.3.15) is able to cope
with it, but there are plenty of systems running much older
versions.
* libmailutils/server/msrv.c (mu_m_server_begin): Reset onexit
list after forking.
* libmu_auth/tls.c (mu_tls_module_init): Don't call
mu_init_tls_libs.
(_tls_server_open, _tls_client_open): Check return value from
mu_init_tls_libs.
* imap4d/auth_gsasl.c (auth_gsasl): Use mu_onexit to register
onexit functions.
* imap4d/imap4d.h (util_atexit): Remove prototype.
* imap4d/starttls.c (imap4d_starttls): Don't register
mu_deinit_tls_libs: now done by tls library.
(starttls_init): Don't call mu_init_tls_libs.
* imap4d/util.c (util_atexit): Remove.
(util_bye): Update accordingly.
* pop3d/extra.c (pop3d_setio): Print informational message
after establishing TLS.
(pop3d_bye): Don't call mu_deinit_tls_libs: that's done by the
library.
* pop3d/pop3d.c (main): Don't call mu_init_tls_libs.
2015-07-09 Sergey Poznyakoff <gray@gnu.org.ua>
Fix make check if MU_DEFAULT_SCHEME value is other than mbox.
* testsuite/testsuite.inc (MUT_DEFAULT_OPTIONS): New define.
* maidag/tests/testsuite.at: Add MUT_DEFAULT_OPTIONS to the
options passed to maidag
* mail/tests/cols00.at: Use MUT_MAIL_CMD
* mail/tests/cols01.at: Likewise.
* mail/tests/copy00.at: Likewise.
* mail/tests/nohome.at: Likewise.
* mail/tests/testsuite.at (MUT_MAIL_CMD): New define. Pass
MUT_DEFAULT_OPTIONS to mail.
* sieve/tests/testsuite.at: Pass MUT_DEFAULT_OPTIONS to sieve.
2015-07-09 Sergey Poznyakoff <gray@gnu.org.ua>
Compatibility fix.
* libmailutils/mailbox/mbx_default.c
(mu_normalize_mailbox_url): Append ${user} if URL ends with
"user=". Fixes 131ddb25a.
2015-07-07 Sergey Poznyakoff <gray@gnu.org.ua>
Minor changes.
* lib/Makefile.am: Add -version-info to LDFLAGS
* libmu_cfg/Makefile.am: Likewise.
* libmu_argp/Makefile.am: Use LIBADD to add library dependency
Pass -version-info to LDFLAGS
2015-07-02 Sergey Poznyakoff <gray@gnu.org.ua>
Bugfix.
* libmailutils/cfg/gocs.c (mu_gocs_register): Avoid registering
same capability twice.
2015-07-02 Sergey Poznyakoff <gray@gnu.org>
Version 2.99.99.
* configure.ac: Version 2.99.99
* NEWS: Update.
* libmu_argp/mailutils.c: New file.
* libmu_argp/Makefile.am: Add mailutils.c
* libmu_argp/cmdline.c (all_cmdline_capa): Add
mu_mailutils_cmdline.
(mu_libargp_init): Register modflags function.
* libmu_argp/mu_argp.c (mu_build_argp): Retain negative group
numbers.
(argp_capa): New member: modflags.
(mu_register_argp_capa): Take pointer to modflags function as
3rd parameter.
(mu_build_argp): Use modflags member to alter argp flags.
(mu_argp_build): Take pointer to flags as its third argument.
* libmu_argp/muinit.c (mu_app_init): Pass pointer to flags to
mu_argp_build.
* libmu_cfg/init.c (mu_libcfg_init): Silently ignore unknown
groups
* include/mailutils/libargp.h (mu_mailutils_cmdline): New
extern.
(mu_cmdline_capa): New member: modflags.
(mu_argp_build): Change signature.
(mu_register_argp_capa): Change signature.
* libmailutils/cfg/gocs.c (std_gocs_table): Add dummy entry for
"mailutils"
* mu/Makefile.am (bin_PROGRAMS): Rename to "mailutils".
* mu/dispatch.c (dispatch_docstring): Use mu_program_name
instead of the hardcoded name.
* mu/mu.c: Use "mailutils" capability.
* mu/mailutils-config.in: Rename to mu/mailutils-config
* comsat/comsat.c: Use "mailutils" capability.
* dotlock/dotlock.c: Likewise.
* examples/muauth.c: Likewise.
* examples/muemail.c: Likewise.
* frm/frm.c: Likewise.
* frm/from.c: Likewise.
* imap4d/imap4d.c: Likewise.
* maidag/maidag.c: Likewise.
* mail/mail.c: Likewise.
* messages/messages.c: Likewise.
* mimeview/mimeview.c: Likewise.
* movemail/movemail.c: Likewise.
* pop3d/pop3d.c: Likewise.
* pop3d/popauth.c: Likewise.
* readmsg/readmsg.c: Likewise.
* sieve/sieve.c: Likewise.
2015-07-02 Sergey Poznyakoff <gray@gnu.org.ua>
Minor fix.
* mh/prompter.c (main): Use mu_stream_printf instead of printf
2015-06-29 Sergey Poznyakoff <gray@gnu.org>
Bugfix.
* libproto/maildir/mbox.c (maildir_msg_finish_delivery): Don't
complain if trying to unlink a nonexistent file.
2015-06-28 Sergey Poznyakoff <gray@gnu.org>
Fix compilation warnings.
* configure.ac: Check for intptr_t
* comsat/action.c (need_crlf): Use intermediate cast to
intptr_t.
* imap4d/imap4d.c (cb2_group, mu_get_user_groups): Likewise.
* libmailutils/stream/file_stream.c (fd_ioctl): Likewise.
* libmailutils/stream/mapfile_stream.c (_mapfile_ioctl):
Likewise.
* libmailutils/stream/tcp.c (_tcp_ioctl): Likewise.
* maidag/maidag.c (cb2_group): Likewise.
* frm/common.c (puts_bidi): Fix the type of 3rd parameter to
fribidi_log2vis
* include/mailutils/body.h: Use MU_DEPRECATED instead of
__attribute__ ((deprecated)).
* include/mailutils/cfg.h: Likewise.
* include/mailutils/header.h: Likewise.
* include/mailutils/libargp.h: Likewise.
* include/mailutils/mailbox.h: Likewise.
* include/mailutils/mailer.h: Likewise.
* include/mailutils/registrar.h: Likewise.
* include/mailutils/message.h: Likewise.
(mu_message_set_stream): Remove deprecation marker.
2015-06-27 Sergey Poznyakoff <gray@gnu.org.ua>
python: cleanup.
* python/libmu_py/libmu_py.c (_ro): Remove inline qualifier.
* python/libmu_py/libmu_py.h: Likewise.
2015-06-27 Sergey Poznyakoff <gray@gnu.org.ua>
python: fix returning size_t values.
* python/libmu_py/address.c: Use PyInt_FromSize_t to return
size_t and similar values.
* python/libmu_py/auth.c: Likewise.
* python/libmu_py/body.c: Likewise.
* python/libmu_py/header.c: Likewise.
* python/libmu_py/mailbox.c: Likewise.
* python/libmu_py/mailcap.c: Likewise.
* python/libmu_py/message.c: Likewise.
* python/libmu_py/mime.c: Likewise.
* python/libmu_py/sieve.c: Likewise.
* python/libmu_py/stream.c: Likewise.
2015-06-27 Sergey Poznyakoff <gray@gnu.org.ua>
python: fix passing size_t values on 64-bit architectures.
* lib/python.c (python_proc): Pass a copy of mu_program_name as
argv[0].
* python/libmu_py/libmu_py.h (ASSERT_INDEX_RANGE): New macro.
* python/libmu_py/address.c: Use Py_ssize_t and check returned
value range when getting size_t arguments.
* python/libmu_py/auth.c: Likewise.
* python/libmu_py/folder.c: Likewise.
* python/libmu_py/header.c: Likewise.
* python/libmu_py/mailbox.c: Likewise.
* python/libmu_py/mailcap.c: Likewise.
* python/libmu_py/message.c: Likewise.
* python/libmu_py/mime.c: Likewise.
* python/libmu_py/secret.c: Likewise.
* python/libmu_py/stream.c: Likewise.
2015-06-27 Sergey Poznyakoff <gray@gnu.org.ua>
Fix double-inclusion of config.h in some sources.
* lib/muscript.h: Don't include config.h: the caller is
responsible for that.
* lib/guile.c: Include config.h
* lib/python.c: Likewise.
* lib/script.c: Likewise.
* lib/sieve.c: Likewise.
2015-06-26 Sergey Poznyakoff <gray@gnu.org.ua>
Minor fix.
* mh/prompter-tty.c: include signal.h
2015-06-26 Sergey Poznyakoff <gray@gnu.org.ua>
Fix segfault when destroying mu_body_t under certain
conditions.
That's a temporary solution until reference counters are
implemented for mu_body_t
* libmailutils/mailbox/body.c (bstr_close, bstr_done): Don't
close streams.
2015-06-26 Sergey Poznyakoff <gray@gnu.org.ua>
Bugfixes.
* configure.ac: Fix checks for readline. If it is not present -
bail out if it was explicitly requested and silently disable it
otherwise. Check for dbm_dirfno and dbm_pagfno (see
libmu_dbm/ndbm.c, below).
* examples/mboxidx.c (set_charset_filter): Fix array
dimensions.
* lib/python.c (python_done): add missing return statement.
* libmailutils/address/address.c (mu_address_union): Fix size
argument to memset.
* libmailutils/server/msrv.c (mu_m_server_get_hints): Likewise.
* libmu_compat/vartab.c (vardefn_free): Likewise.
* libmailutils/cfg/parser.y (_set_fun): cast enum to size_t
before comparison
* libmailutils/diag/wd.c (mu_wd): fix while loop.
* libmailutils/tests/url-parse.c (main): Fix printf format.
* libmu_dbm/ndbm.c (_ndbm_get_fd): One of dbm_dirfno or
dbm_pagfno may be missing (on FreeBSD, dbm_pagfno expands to a
non-defined macro, which produces compilation error.
* mail/mailvar.c (mailvar_varptr_comp): Remove.
(mailvar_list_copy): Use mailvar_variable_comp instead of the
removed mailvar_varptr_comp.
2015-06-24 Sergey Poznyakoff <gray@gnu.org.ua>
Add gnulib as a module.
2015-06-24 Sergey Poznyakoff <gray@gnu.org.ua>
Make libmuaux installable shared library.
This commit converts libmuaux into installable shared library
that includes selected modules from gnulib. Correspondingly,
libmu_argp is also converted into installable shared library,
which is the main purpose of these changes. This should allow
other packages which depend on Mailutils to link against
libmu_argp even on systems that for some reason choose not to
include static libraries in their distribution (vide Debian).
Another side effect is that such packages won't need to bother
about argp being present on the system, as it is now included
in libmuaux.so.
* bootstrap.conf: Don't create Makefile.am Build gnulib using
libtool and use mu_am_flags custom module
* lib/local/modules/mu_am_flags: New file.
* configure.ac (MU_APP_LIBRARIES): Use libmu_argp.la
(TCPWRAP_LIBRARIES): Add libmutcpwrap.a
* lib/Makefile.am: Make libmuaux installable shared library New
static library libmutcpwrap.a
* libmu_argp/Makefile.am: Make libmu_argp installable shared
library
* examples/Makefile.am: Use libmu_argp.la
* examples/cpp/Makefile.am: Likewise.
* imap4d/Makefile.am: Likewise.
* mapi/Makefile.am: Likewise.
* mh/Makefile.am: Likewise,
* pop3d/Makefile.am: Likewise.
2015-06-23 Sergey Poznyakoff <gray@gnu.org>
Minor fixes in Scheme scripts.
* scheme/Makefile.am: set executable bit on guimb (fix a typo)
Override the installcheck-binSCRIPTS rule to avoid spurious
output from guile 2.0 when running the program.
* scheme/guimb.scmi: Remove flags specific to guile 1.8
2015-06-23 Sergey Poznyakoff <gray@gnu.org>
Fix improper padding in B encoding.
* libmailutils/stream/fltstream.c: stop encoding when no more
input is available.
* libmailutils/tests/encode2047.at: add new tests.
* libmailutils/filter/base64.c (_base64_encoder): detect eof
2015-05-05 Sergey Poznyakoff <gray@gnu.org>
Minor fix.
2015-05-05 Sergey Poznyakoff <gray@gnu.org>
mail: add tests in a non-interactive mode.
* configure.ac: Configure mail/tests subdirectory.
* mail/Makefile.am (SUBDIRS): Add tests.
* mail/tests/testsuite.at: New file.
* mail/tests/Makefile.am: New file.
* mail/tests/.gitignore: New file.
* mail/tests/atlocal.in: New file.
* mail/tests/cols00.at: New file.
* mail/tests/cols01.at: New file.
* mail/tests/copy00.at: New file.
* mail/tests/nohome.at: New file.
* mail/tests/version.at: New file.
2015-05-04 Sergey Poznyakoff <gray@gnu.org>
mail: the "copy" command operates on files by default.
Last argument is treated as a mailbox only if it begins with a
mailbox scheme (mbox://, maildir://, etc).
* mail/copy.c (append_to_mailbox)
(append_to_file): New functions.
(mail_copy0): Depending on whether mailbox scheme is specified,
call one of the above functions.
* doc/texinfo/programs.texi (mail): Fix documentation of the
copy command.
* mail/testsuite/mail/write.exp: Update line/character counts
for [Ss]ave commands.
2015-05-03 Sergey Poznyakoff <gray@gnu.org>
Minor change.
* doc/texinfo/programs.texi: Fix description of mail --print
2015-05-03 Sergey Poznyakoff <gray@gnu.org>
readmsg: minor fix.
* readmsg/readmsg.c: Bail out unless arguments are present.
* doc/texinfo/programs.texi: Update.
2015-05-03 Sergey Poznyakoff <gray@gnu.org>
Fix doc generation.
The Config file applies to all output formats, which is wrong.
Use a dedicated configuration file for html output formats, and
default settings for the rest.
* doc/texinfo/Makefile.am (GENDOCS): Add html-specific
configuration file.
* doc/texinfo/Config: Rename to doc/texinfo/html.init (with
changes).
* doc/texinfo/programs.texi: Fix sectioning.
2015-05-03 Sergey Poznyakoff <gray@gnu.org>
mail: honor columns/screen variables.
* mail/util.c (util_command_list): Use util_screen_columns
instead of util_getcols.
(util_getcols): Don't use COLUMNS.
(util_getlines): Don't use LINES.
* mail/mail.c: Don't force COLUMNS and LINES (they are normally
not exported, so setting them will cause util_getcols and
util_getlines to return wrong results). Set variable "columns"
from envvar COLUMNS, if set to a numeric value. Set variable
"screen" from envvar LINES, if set to a numeric value.
* mail/from.c (format_headline): Use util_screen_columns
instead of util_getcols.
* mail/mailvar.c (mailvar_print,mail_variable): Likewise.
* mail/print.c (mail_print_msg): Likewise.
2015-05-03 Sergey Poznyakoff <gray@gnu.org>
Honor MAIL and FOLDER envars if _mu_mailbox_pattern is not set.
The _mu_mailbox_pattern variable is supposed to be set only
from configuration file. However, the mu_mailbox_url function
would also set it as a side effect. This produced strange
results; in particular unsetting HOME variable caused mail
utilities to ignore MAIL variable as well (as reported by Dan
Jacobson on 2015-04-30, <87vbgemcc7.fsf@jidanni.org>).
* configure.ac (MU_PATH_MAILDIR): Don't end with a slash.
* libmailutils/mailbox/mbx_default.c
(mu_normalize_mailbox_url): Use mu_make_file_name.
(mu_mailbox_url): Don't set _mu_mailbox_pattern.
2015-04-27 Sergey Poznyakoff <gray@gnu.org.ua>
Bugfixes.
Setting non-existing variable in bin/mail at the start of the
session caused further calls to set (without arguments) to
malfunction. This revealed bugs in list mapping functions.
On the other hand, invoking completion after "set var=" caused
bin/mail to coredump.
* libmailutils/list/gmap.c (mu_list_gmap): Initialize rc.
* libmailutils/list/map.c: Always initialize *res.
* mail/mailvar.c (mailvar_list_copy): The call to mu_list_map
does not necessarily create the list. Create it, if it doesn't.
(mailvar_iterate_next): Redo the loop: check if there are items
to iterate over.
2015-03-02 Sergey Poznyakoff <gray@gnu.org.ua>
Switch to Texinfo 5.0.
* doc/texinfo/Config: Rewrite.
* doc/texinfo/Makefile.am: Use Makeinfo 5 instead of texi2htm
* doc/texinfo/gendocs_template: Remove ps
* doc/imprimatur: Upgrade.
* doc/texinfo/gendocs.sh: New file.
* doc/texinfo/rendition.texi: Remove.
* doc/texinfo/programs.texi: Bugfixes
2015-03-02 Sergey Poznyakoff <gray@gnu.org.ua>
Update copyright years.
2014-12-08 Sergey Poznyakoff <gray@gnu.org.ua>
Fix alignment issues in mu_fgetpwent_r.
* libmailutils/base/fgetpwent.c: Place struct passwd at the
beginning of the buffer. Account for eventual missing newline
at the end of file.
2014-12-07 Sergey Poznyakoff <gray@gnu.org>
New function mu_fgetpwent_r.
* libmailutils/base/fgetpwent.c: Rewrite from scratch.
* ChangeLog.amend: Update.
2014-12-06 Sergey Poznyakoff <gray@gnu.org>
Improve diagnostics in maildir.
* libmailutils/mailbox/fsfolder.c: Fix debugging categories
* libproto/maildir/mbox.c (maildir_opendir)
(maildir_msg_finish_delivery)
(maildir_scan0): Log errors.
(maildir_flush,maildir_deliver_new): Return EACCES if the
mailbox is read-only.
2014-12-06 Sergey Poznyakoff <gray@gnu.org.ua>
Fix the use of read-only maildir folders. Imap4d improvements.
New imap4d statement "retain-groups" instructs it to retain the
named supplementary user groups when switching to the user
privileges (previously, imap4d just switched to <user>:mail).
Read-only mailboxes are handled graciously: SELECT succeeds on
such mailboxes, bug marks them explicitly as read-only.
* imap4d/imap4d.c (user_retain_groups): New global. New config
statement "retain-groups".
(mu_get_user_groups): New function.
(imap4d_session_setup0): Use mu_switch_to_privs instead of just
setuid.
* imap4d/list.c (imap4d_list): Fix handling of
LIST "" "/path/to/mbox"
* imap4d/select.c (imap4d_select0): Retry opening in read-only
mode if failed to open for read-write.
* libproto/maildir/mbox.c (maildir_mkfilename)
(mk_info_filename): Change return value and signature. All uses
changed.
(maildir_scan0): Don't shuffle messages if mailbox is opened
read-only.
* libproto/maildir/folder.c: Update call to maildir_mkfilename.
* libproto/maildir/maildir.h (maildir_mkfilename): Change
prototype.
2014-12-03 Sergey Poznyakoff <gray@gnu.org.ua>
Fix eventual memory overrun.
* mail/mail.c (mail_mainloop): Check command length before
trying to access its last byte.
2014-08-14 Sergey Poznyakoff <gray@gnu.org>
Fix possible coredump in stream library.
* libmailutils/stream/stream.c (mu_stream_strerror): stream can
be NULL.
2014-08-10 Sergey Poznyakoff <gray@gnu.org>
imap-related bugfixes.
* imap4d/search.c (imap4d_search0): Use parsebuf.err_mesg if
defined, otherwise fall back to the general "parse error"
message.
* include/mailutils/datetime.h (MU_DATETIME_INTERNALDATE): Use
%e for day. Day can be one-digit decimal.
* libmailutils/datetime/scantime.c (mu_scan_datetime): Skip
initial ws for %e.
* mu/imap.c (com_search): Print newline after the "no matches"
message.
2014-07-28 Sergey Poznyakoff <gray@gnu.org>
Add scripting capability to mh/inc.
This patch adds a convenience library libmuscript that provides
scripting capability easy to use in MU applications. Currently
used by maidag and inc.
* include/mailutils/util.h (mu_stpcpy): 2nd arg is const.
* libmailutils/string/stpcpy.c: Likewise.
* lib/.gitignore: Update.
* lib/Makefile.am: New library libmuscript.a
* lib/muscript.h: New file.
* lib/muscript_priv.h: New file.
* lib/script.c: New file.
* maidag/guile.c: Rename to ...
* lib/guile.c: ... this
* maidag/python.c: Rename to ...
* lib/python.c: ... this
* maidag/sieve.c: Rename to ...
* lib/sieve.c: ... this
* maidag/Makefile.am (maidag_LDADD): Add libmuscript.a
(maidag_SOURCES): Update.
* maidag/maidag.c (script_handler): Change type to mu_script_t.
* maidag/maidag.h: Include muscript.h
* maidag/script.c: Rewrite via libmuscript
* mh/Makefile.am (inc_LDADD): New variable.
* mh/inc.c (options): New options --language and --script.
(mh_option): New options -language and -script.
(incdat) <handler,descr>: New members.
(incmbx): Optionally process each message through a script. If
it is marked as deleted upon return, don't incorporate it.
(main): Set mh as the default mailbox scheme. Initialize
scripting subsystem and deallocate it when finished.
* mh/mh_getopt.h (ARG_LANG, ARG_SCRIPT): New constants.
2014-07-26 Sergey Poznyakoff <gray@gnu.org>
Move gnulib into a subdir.
* bootstrap.conf: Create and populate lib/gnu, if necessary.
* configure.ac (MU_APP_COMMON_INCLUDES): Update.
(AC_CONFIG_FILES): Build lib/gnu/Makefile
* lib/Makefile.am (libmuaux_a_SOURCES): Add all objects from
gnu/
* po/POTFILES.in: Update.
* examples/.gitignore: Update.
2014-07-17 Sergey Poznyakoff <gray@gnu.org.ua>
Bugfixes.
* examples/echosrv.c: Fix typo.
* libmailutils/sockaddr/url.c: Likewise.
* mh/mhn.c: Likewise.
* mh/folder.c (roll_back): Fix conditional.
* THANKS: Update.
2014-07-17 Sergey Poznyakoff <gray@gnu.org.ua>
Bugfix.
* libmailutils/filter/iconvflt.c: Fix silly errors.
2014-07-07 Sergey Poznyakoff <gray@gnu.org.ua>
Push missing files.
2014-07-07 Sergey Poznyakoff <gray@gnu.org.ua>
New example: mboxidx.
* examples/mboxidx.c: New file
* examples/Makefile.am: Add mboxidx
2014-07-07 Sergey Poznyakoff <gray@gnu.org.ua>
Fix memory overrun in iconv filter.
* libmailutils/filter/iconvflt.c (format_octal): New function.
(_icvt_decoder): Fix size calculations before returning
mu_filter_moreoutput. Use format_octal instead of sprintf to
avoid memory overwrite with the terminating nul character.
2014-07-05 Sergey Poznyakoff <gray@gnu.org.ua>
Implement the xml filter.
* libmailutils/filter/xml.c: New file.
* include/mailutils/filter.h (mu_xml_filter): New extern.
* libmailutils/filter/Makefile.am (libfilter_la_SOURCES): Add
xml.c
* libmailutils/filter/filter.c (mu_filter_get_list): Register
mu_xml_filter.
* libmailutils/tests/xml.at: New file.
* libmailutils/tests/Makefile.am: Add xml.at
* libmailutils/tests/testsuite.at: Likewise.
2014-07-02 Sergey Poznyakoff <gray@gnu.org.ua>
New filter: htmlent.
* include/mailutils/filter.h (mu_htmlent_filter): New extern.
* libmailutils/filter/Makefile.am: Add htmlent.c
* libmailutils/filter/filter.c (mu_filter_get_list): Register
mu_htmlent_filter.
* libmailutils/filter/htmlent.c: New file.
* libmailutils/tests/htmlent.at: New testcase.
* libmailutils/tests/Makefile.am: Add new testcase.
* libmailutils/tests/testsuite.at: Likewise.
2014-06-17 Damien Diederen <dd@crosstwine.com>
maildir: Keep trailing comma even when no flags are set.
Without this, `mk_info_filename' generates filenames of the
following form when the flag set is empty:
1402217787.M664911P5957Q143.hostname:2
The original Maildir spec (http://cr.yp.to/proto/maildir.html),
however, mandates that filenames must be of the form
`uniq:info', with `info' starting with "2,"--including a comma.
This patch removes the "cleanup" performed by
`mk_info_filename' as that there is no rationale for it in
mailutils' source code history, and as it breaks Gnus'
"nnmaildir" backend (Cf. `nnmaildir--add-flag').
* libproto/maildir/mbox.c (mk_info_filename): Keep comma at the
end of filename when the flags suffix is empty.
2014-05-21 Sergey Poznyakoff <gray@gnu.org.ua>
Bugfixes.
* libmailutils/mailbox/attribute.c (mu_attribute_is_equal): Fix
comparison.
* libmailutils/mailbox/biffnotify.c: Add missing includes.
2014-04-15 Sergey Poznyakoff <gray@gnu.org.ua>
frm: fix counters when given multiple mailboxes.
* frm/frm.c (frm): Initialize counters.
* frm/tests/testsuite.at: Test multiple mailboxes.
2014-02-26 Sergey Poznyakoff <gray@gnu.org>
Fix compilation without gnutls.
* imap4d/imap4d.c [WITH_TLS] (cb_tls_required): Conditional
compilation.
* imap4d/imap4d.h [!WITH_TLS] (tls_encryption_on): Empty
define.
* pop3d/pop3d.c [!WITH_TLS] (tls_available): Empty define.
* libmu_scm/mu_mailbox.c (mu_scm_mailbox_print): Fix format
string.
2014-02-26 Sergey Poznyakoff <gray@gnu.org.ua>
imap client: fix handling of ID response without untagged part.
* libproto/imap/id.c: Make sure returned mu_assoc_t is valid
even if no untagged response was received (equivalent to NIL).
2014-02-26 Sergey Poznyakoff <gray@gnu.org.ua>
Improve tls support.
Remove deprecated types and function calls. Make cipher, mac,
and other priorities configurable.
* include/mailutils/sys/tls-stream.h (_mu_tls_stream): Use
gnutls_session_t.
* include/mailutils/tls.h (mu_tls_module_config): New member:
priorities.
* libmu_auth/tls.c: Remove deprecated types.
(initialize_tls_session): Make priorities configurable.
(prepare_client_session): Set default priorities.
* libmu_cfg/tls.c: New configuration statement: ssl-priorities.
2014-02-26 Sergey Poznyakoff <gray@gnu.org.ua>
Clean up unused variables.
2014-02-26 Sergey Poznyakoff <gray@gnu.org.ua>
Use AM_CPPFLAGS instead of INCLUDES; upgrade gint.
2014-02-06 Sergey Poznyakoff <gray@gnu.org.ua>
Accept single-dash notify option to inc.
* mh/mh_getopt.c (mh_getopt): Correctly handle traditional
options that begin with "no" (e.g. "notify").
* mh/inc.c (mh_option): Accept -notify (single-dash).
2014-02-06 Sergey Poznyakoff <gray@gnu.org.ua>
Move biff notification to the library. Implement it in inc and
movemail.
* include/mailutils/mailbox.h (mu_mailbox_set_notify)
(mu_mailbox_unset_notify): New protos.
* include/mailutils/sys/mailbox.h (_mu_mailbox) <notify_user>
<notify_fd,notify_sa>: New members.
* libmailutils/mailbox/Makefile.am (libmailbox_la_SOURCES): Add
biffnotify.c
* libmailutils/mailbox/biffnotify.c: New file.
* libmailutils/mailbox/mailbox.c (_mailbox_create_from_record):
Initialize notify_fd.
(mu_mailbox_destroy): Free notify_sa.
(mu_mailbox_close): Close notify_fd.
(mu_mailbox_flush): Rewrite to handle append-only mailboxes
effectively.
* libmailutils/server/msrv.c (server_cfg_param): Fix docstring.
* libmailutils/stream/file_stream.c (fd_open): Open fd
read-write if both MU_STREAM_APPEND and MU_STREAM_READ are
requested.
* libproto/mbox/mbox.c (mbox_expunge0): Rescan the mailbox if
messages_count == 0. Special handling for append-only
mailboxes.
* maidag/deliver.c: Use library notification mechanism.
* mh/inc.c: New option --notify.
* movemail/movemail.c: Likewise.
2014-02-05 Sergey Poznyakoff <gray@gnu.org.ua>
Update copyright years.
2014-02-04 Sergey Poznyakoff <gray@gnu.org.ua>
Use global TLS setting in inetd mode (bug #40891)
* imap4d/imap4d.c (imap4d_connection): Use global TLS setting
if no local one was supplied.
(main): Use global TLS setting in inetd mode.
* pop3d/pop3d.c (main): Use global TLS setting in inetd mode.
2014-02-04 Sergey Poznyakoff <gray@gnu.org.ua>
Fix coredump if crypt returns NULL.
* libmailutils/auth/system.c: Check return from crypt before
passing it to strcmp.
* libmu_auth/sql.c: Likewise.
2014-02-04 Sergey Poznyakoff <gray@gnu.org.ua>
Issue a deprecation warning if tls-required is used in pop3d or
imap4d config.
2013-12-24 Sergey Poznyakoff <gray@gnu.org.ua>
Fix bug in handling AUTHENTICATE command (imap4d). Add
user/group ACLs.
The bug was introduced in commit 6e2a3758.
The ACLs allow administrators to limit access to IMAP services
to particular users or users belonging to particular groups.
* imap4d/authenticate.c (imap4d_auth_capability): Take session
pointer as argument. Don't report authentication capabilities
if tls is required.
(imap4d_authenticate): Fix conditional.
* imap4d/capability.c (imap4d_capability): Update call to
imap4d_auth_capability.
* imap4d/imap4d.c (cb_tls_required): Set tls_mode.
(auth_deny_user_list,auth_allow_user_list)
(auth_deny_group_list,auth_allow_group_list): New statics.
(check_user_groups,imap_check_group_list): New static
functions. (imap4d_cfg_param) <allow-users,deny-users>
<allow-groups,deny-groups>: New configuration statements.
(imap4d_session_setup0): Check allow/deny lists.
* imap4d/imap4d.h (imap4d_auth_capability): Change signature.
* pop3d/pop3d.c (cb_tls_required): Set tls_mode.
* bootstrap (gnulib_extra_files): Update.
2013-12-17 Sergey Poznyakoff <gray@gnu.org.ua>
Minor fix in mh/inc.
* mh/inc.c (main): Update the unseen sequence only if some new
messages were incorporated.
2013-11-30 Sergey Poznyakoff <gray@gnu.org.ua>
Fix appending to IMAP[S] mailboxes.
* libproto/imap/appmsg.c (mu_imap_append_message): Fix
conditional.
* libproto/imap/mbox.c (_imap_mbx_append_message): Fix error
checking.
* libproto/imap/url.c (_mu_imap_url_init)
(_mu_imaps_url_init): Set _get_path member. This allows the
user to specify an URL without explicit path, implying INBOX.
2013-10-20 Sergey Poznyakoff <gray@gnu.org.ua>
Bugfixes.
* imap4d/io.c (io_copy_out): Switch to full buffering before
sending data.
* libmailutils/stream/stream.c (_stream_skip_input_bytes):
Bugfix.
2013-08-22 Sergey Poznyakoff <gray@gnu.org.ua>
Fix tls_required functionality in imap4d.
* imap4d/imap4d.c (imap4d_mainloop): Add missing break.
2013-08-13 Sergey Poznyakoff <gray@gnu.org.ua>
Bugfix in LDAP code.
* libmu_auth/ldap.c (_mu_conn_setup): Set protocol version
number before trying to initialize TLS. Provide a detailed
diagnostics.
2013-07-17 Sergey Poznyakoff <gray@gnu.org.ua>
Support for RFC 3206.
* pop3d/pop3d.h (ERR_SYS_LOGIN): New error code.
* pop3d/capa.c (pop3d_session_init): Advertise the
AUTH-RESP-CODE capability.
* pop3d/cmd.c (error_table) <ERR_BAD_LOGIN>: Mark with the AUTH
response code.
<ERR_SYS_LOGIN>: New entry.
* pop3d/user.c (pop3d_user): Use mu_get_auth to obtain the
user's identity. On error, the error code is ERR_BAD_LOGIN or
ERR_SYS_LOGIN, depending on its return and return from
mu_authenticate.
2013-06-19 Sergey Poznyakoff <gray@gnu.org.ua>
One more fix.
* libmailutils/server/ipsrv.c (mu_ip_tcp_accept): Handle
connection aborted error as well.
2013-05-25 Sergey Poznyakoff <gray@gnu.org.ua>
Bugfixes.
* imap4d/io.c (imap4d_tokbuf_decrlf): Rewrite to run in O(n).
* libmailutils/server/ipsrv.c (mu_ip_tcp_accept): Return 0 on
EINTR (unless srv->f_intr tells otherwise) and EAGAIN. The
caller will retry.
(mu_ip_server_accept): output a diagnostic message before
returning error.
2013-05-25 Sergey Poznyakoff <gray@gnu.org.ua>
Minor fixes.
* mu/Makefile.am (mailutils-config): Fix sed expression
* mu/mailutils-config.in: Replace MUNAME once and assign it to
the variable.
2013-04-12 Sergey Poznyakoff <gray@gnu.org.ua>
Implement MH show utility.
* mh/show.c: New file.
* NEWS: Document changes.
* libmailutils/stream/message_stream.c (copy_trimmed_value):
Fix string length calculation to allow for empty lines.
* mh/.gitignore: Update.
* mh/Makefile.am: Build show.
* mh/TODO: Document show.
* mh/mh_getopt.h: Add new option codes.
* mh/mh_init.c (mh_expand_name): Change handling of the last
argument. All callers updated.
(mh_draft_name): Remove.
2013-04-07 Sergey Poznyakoff <gray@gnu.org.ua>
Fix MH sequence parser.
* mh/mh_msgset.c (parse_range): Fix resolving non-existing
UIDs.
* mh/tests/mhseq.at: Add more test cases.
2013-04-03 Sergey Poznyakoff <gray@gnu.org.ua>
Add support for Unseen-Sequence in inc.
* mh/inc.c (main): Append the numbers of incorporated messages
to Unseen-Sequence, if defined in .mh_profile.
2013-04-02 Sergey Poznyakoff <gray@gnu.org.ua>
MH send: improve compatibility with MH/nmh.
2013-04-02 Sergey Poznyakoff <gray@gnu.org.ua>
Rewrite mu_utc_offset in a more portable (hopefully) way.
2013-04-02 Sergey Poznyakoff <gray@gnu.org.ua>
Minor fix in docs.
2013-04-01 Sergey Poznyakoff <gray@gnu.org.ua>
MH: Synchronize sequences after removal of messages.
* include/mailutils/msgset.h (mu_msgset_sget_mailbox): New
proto.
* include/mailutils/sys/msgset.h (_MU_MSGSET_MODE): New macro.
* libmailutils/msgset/Makefile.am: Add getmbox.c
* libmailutils/msgset/getmbox.c: New file.
* libmailutils/msgset/addset.c: Use _MU_MSGSET_MODE.
* libmailutils/msgset/create.c: Likewise.
* libmailutils/msgset/foreachmsg.c: Likewise.
* libmailutils/msgset/foreachnum.c: Likewise.
* libmailutils/msgset/negate.c: Likewise.
* libmailutils/msgset/subset.c: Likewise.
* libmailutils/msgset/trans.c: Likewise.
* mh/mh.h (mh_private_sequences_iterate): New proto.
* mh/mh_sequence.c (format_closure) <delim>: New member.
(format_sequence): Use delim to avoid outputting leading space.
(save_sequence): Initialize delim.
(mh_private_sequences_iterate): New function.
* mh/rmm.c (main): Remove message numbers from sequences.
* mh/tests/rmm.at: Update.
2013-04-01 Sergey Poznyakoff <gray@gnu.org.ua>
Bugfix.
* libmailutils/base/amd.c (_amd_update_message): Return
immediately if the message is not modified. Always use
initialized value of flg.
2013-03-30 Sergey Poznyakoff <gray@gnu.org.ua>
msgchk: assume -date by default.
2013-03-30 Sergey Poznyakoff <gray@gnu.org.ua>
Minor fixes.
* mh/msgchk.c (checkmail): take into account various possible
return codes.
2013-03-30 Sergey Poznyakoff <gray@gnu.org.ua>
Implement IMAP SEARCH. New function mu_mailbox_access_time.
* include/mailutils/imap.h (mu_imap_search): New proto.
* libproto/imap/search.c: New file.
* include/mailutils/sys/imap.h (MU_IMAP_CLIENT_SEARCH_RX): New
state.
* libproto/imap/fetch.c: Fix debugging categories
* libproto/imap/mbox.c (_imap_messages_recent)
(_imap_message_unseen): Use search if information is not
readily available.
* libproto/imap/status.c (_mu_imap_status_name_table): Comment
out UNSEEN: its semantics is entirely different from what we
need.
* libproto/imap/Makefile.am: Add new file.
* mu/imap.c: Implement search.
* include/mailutils/sys/mailbox.h (_mu_mailbox) <_get_atime>:
New method.
* include/mailutils/mailbox.h (mu_mailbox_access_time): New
proto.
* libproto/mbox/mbox.c (_mailbox_mbox_init): Initialize
>_get_atime.
* libmailutils/mailbox/mailbox.c (mu_mailbox_access_time): New
function.
* libmailutils/datetime/utcoff.c (mu_utc_offset): Rewrite using
tzset.
* mh/msgchk.c: Implement --date. Check for new mail using both
recent and unseen messages.
2013-03-30 Sergey Poznyakoff <gray@gnu.org.ua>
Implement msgchk.
* mh/msgchk.c: New file.
* mh/Makefile.am: Build msgchk.
* mh/mh_getopt.h: Update.
* mh/.gitignore: Update.
* mh/TODO: Update.
2013-03-27 Sergey Poznyakoff <gray@gnu.org.ua>
Fix the use of localname and localdomain in ~/.mtstailor.
* mh/send.c (read_mts_profile): Fix the handling of localname
vs. localdomain. The localname setting used alone overrides the
hostname as returned by mu_hostname. The value of localdomain,
if set, is appended to the hostname (eventually modified by
localname), with a "." as a separator.
2013-03-25 Sergey Poznyakoff <gray@gnu.org.ua>
Do not ask for ESMTP credentials if unable to handle them.
* libproto/mailer/smtp.c (smtp_open): Disable ESTMP AUTH if
GSASL support is not compiled.
* libproto/mailer/smtp_auth.c (mu_smtp_auth): If compiled
without GSASL, don't attempt to obtain user credentials.
2013-03-25 Sergey Poznyakoff <gray@gnu.org.ua>
Fix interaction with POP3 servers that do not support the CAPA
command.
* libproto/pop/mbox.c (pop_open): Do not bail out if the CAPA
command returns -ERR. Assume a pre-RFC2449 server.
* include/mailutils/pop3.h (mu_pop3_strresp)
(mu_pop3_sget_response,mu_pop3_aget_response)
(mu_pop3_get_response): New protos.
* libproto/pop/pop3_response.c (mu_pop3_response): Don't make
out a fake response in case of a I/O error. (mu_pop3_strresp)
(mu_pop3_sget_response,mu_pop3_aget_response)
(mu_pop3_get_response): New functions.
2013-03-25 Sergey Poznyakoff <gray@gnu.org.ua>
Bugfix.
* libmu_auth/ldap.c (_mu_ldap_search): Fix improper addressing
of env.
2013-03-21 Sergey Poznyakoff <gray@gnu.org.ua>
Raise version number.
2013-02-16 Sergey Poznyakoff <gray@gnu.org.ua>
ali: executable file inclusion.
The "< file" construct tests if file is executable and begins
with the shell interpreter magic (#!/ or #! /). If so, this
file is executed and its output is collected. This provides a
way for building aliases on the fly.
* mh/mh_alias.l (buffer_ctx) <exec_p>: New member.
(exec_p): New static variable.
(push_source): If the file is executable and begins with the
"#!/" magic, run it and collect its output.
(pop_source): Use exec_p to decide how to close the file.
* mh/tests/ali.at: Test executable file inclusion.
* NEWS: Update.
2013-01-03 Sergey Poznyakoff <gray@gnu.org.ua>
Make sure modifications to a message or its parts become
visible in the message stream.
* include/mailutils/sys/body.h (_mu_body)<rawstream>: New
member.
* include/mailutils/sys/message.h (_mu_message)<rawstream>: New
member.
* libmailutils/mailbox/body.c: Rewrite. Return the specially
crafted "body-stream" for user I/O operations. Writes to that
stream trigger creation of a temporary stream (write-through
mode) which will be used for subsequent I/O.
* libmailutils/mailbox/msgbody.c (mu_message_get_body): Use
msg->rawstream.
* libmailutils/mailbox/msgheader.c (message_header_fill): Do
not call mu_message_get_streamref, as that can result in
endless recursion. Use msg->rawstream instead.
* libmailutils/mailbox/msgref.c (_mu_message_free): Destroy
both rawstream and outstream.
* libmailutils/mailbox/msgstream.c (mu_message_set_stream): Set
rawstream.
(mu_message_get_stream): Create outstream as needed.
(mu_message_get_streamref): If the message has been modified,
create the outstream and return it to the caller. This way, the
modifications become visible via the stream interface.
* libmailutils/tests/Makefile.am: Add new testcases.
* libmailutils/tests/testsuite.at: Likewise.
* libmailutils/tests/modmesg.c: New file.
* libmailutils/tests/modmesg00.at: New file.
* libmailutils/tests/modmesg01.at: New file.
* libmailutils/tests/modmesg02.at: New file.
* libmailutils/tests/modmesg03.at: New file.
* mh/mhn.c: Fix message reference counting.
2012-12-13 Sergey Poznyakoff <gray@gnu.org.ua>
Bugfix.
* mh/folder.c (_fixup): Pass a pointer to mailbox to
mu_msgset_create.
2012-11-19 Sergey Poznyakoff <gray@gnu.org.ua>
Minor fixes.
* imap4d/imap4d.c: Avoid gcc warnings.
* libmailutils/tests/imapio.c (main): Fix format specifier.
* maidag/mailquota.c (dbm_retrieve_quota): Likewise.
* mail/quit.c (mail_mbox_close): Likewise.
* mail/mail.c (options): Fix improper initialization.
* mu/mu.h (mu_getans): Add proto.
* mu/util.c: Include netinet/in.h
2012-11-12 Sergey Poznyakoff <gray@gnu.org.ua>
Implement editheader sieve extension (RFC 5293).
Also fix iterator synchronization after removing an element and
improve Sieve API.
* include/mailutils/header.h (mu_header_get_itemptr): New
proto.
* include/mailutils/iterator.h (mu_iterator_advance): Remove.
(mu_iterator_delitem): New proto.
(mu_iterator_set_delitem): New proto.
* include/mailutils/sieve.h (mu_sieve_register_t) <opt_args>:
New member. (mu_sieve_register_test_ext)
(mu_sieve_register_action_ext): New protos.
* include/mailutils/sys/iterator.h (_mu_iterator) <curitem_p>:
Remove.
<delitem>: New member. All uses updated.
* libmailutils/base/iterator.c (mu_iterator_set_delitem): New
function.
* libmailutils/mailbox/hdritr.c: Implement bidirectional
iteration. Implement itrctl method.
* libmailutils/mailbox/header.c: Likewise.
* libmailutils/base/assoc.c: Use delitem method instead of
curitem_p.
(mu_iterator_delitem): New function.
* libmailutils/base/opool.c
* libmailutils/diag/debug.c
* libmailutils/list/iterator.c
* libmailutils/list/pop.c
* libmailutils/list/remove.c
* libmailutils/list/removenth.c
* libmailutils/mailbox/imapenv.c
* libmailutils/mailbox/mbxitr.c
* libproto/pop/pop3_iterator.c
* libmu_sieve/extensions/Makefile.am: Add editheader.c
* libmu_sieve/extensions/editheader.c: New file.
* libmu_sieve/prog.c (mu_sv_code_command): Allow for optional
positional arguments.
* libmu_sieve/register.c (mu_sieve_test_lookup)
(mu_sieve_action_lookup): Return NULL if a record with empty
(NULL) handler is found. (mu_sieve_register_test_ext)
(mu_sieve_register_action_ext): New functions.
(mu_sieve_register_test)
(mu_sieve_register_action): Rewrite as wrappers to the above.
* libmu_sieve/util.c (mu_sieve_vlist_do): Allow for SVT_STRING
argument.
* sieve/tests/Makefile.am: Add new testcases.
* sieve/tests/testsuite.at: Include new testcases.
* sieve/tests/addheader.at: New testcase.
* sieve/tests/delheader.at: New testcase.
* NEWS: Update.
* doc/rfc/README: Update.
2012-08-08 Sergey Poznyakoff <gray@gnu.org.ua>
Improve header stream write method.
* libmailutils/mailbox/header.c (HEADER_STREAMMOD): New flag.
(mu_header_fill): Read data back from mstream if it was
modified.
(mu_header_destroy): Destroy mstream.
(header_write): Rewrite from scratch. Allow for writing at
arbitrary offsets.
* examples/header.c: New commands: "overwrite" and "append",
for testing the new functionality.
2012-08-07 Sergey Poznyakoff <gray@gnu.org.ua>
mail: provide a way to set return address.
* mail/mail.c: New option -r (--return-address).
* mail/mailvar.c: New variable "return-address".
* mail/send.c (send_message): Obtain the return mail address
from the "return-address" variable (if set).
* NEWS: Update.
* doc/texinfo/programs.texi: Update.
2012-08-06 Sergey Poznyakoff <gray@gnu.org.ua>
Fix a typo.
2012-08-06 Sergey Poznyakoff <gray@gnu.org.ua>
mailutils-config: reflect eventual rename of mu, so that
AM_GNU_MAILUTILS works.
* mu/.gitignore: Update.
* mu/Makefile.am: Build mailutils-config
* mu/mailutils-config.in: New file.
* mu/mailutils-config: Remove.
2012-08-04 Sergey Poznyakoff <gray@gnu.org.ua>
Ensure consistent stream state before calling its ctl method.
Prior to calling ctl method, mu_stream_ioctl flushes stream
buffer.
* libmailutils/stream/fltstream.c (filter_ctl)
<MU_IOCTL_FILTER_SET_DISABLED>: Flush internal buffer prior to
setting the flag.
* libmailutils/stream/stream.c (mu_stream_ioctl): Flush stream
buffer.
2012-07-29 Sergey Poznyakoff <gray@gnu.org.ua>
Port 0b1e16bea to imap4d.
* imap4d/imap4d.c (tls_required): Remove.
(tls_mode): New variable.
(imap4d_srv_config) <tls>: Remove.
(imap4d_srv_config) <tls_mode>: New member.
(imap4d_srv_param): Change the definition of the "tls"
statement. Mark "tls-required" as deprecated.
(imap4d_mainloop): Change type of the tls argument. Initialize
session and pass it to each handler.
* imap4d/imap4d.h (imap4d_session): New struct.
(imap4d_command) <func>: Change signature. All uses changed.
(tls_mode): New enum.
(tls_required): Remove.
(tls_available): New global.
* imap4d/io.c (io_setio): Don't call tls_encryption_on, leave
it to the caller.
* imap4d/login.c (imap4d_login): Use session.
* imap4d/starttls.c (tls_available): Global. Present even if
!WITH_TLS
(tls_encryption_on): Change signature. All callers updated.
2012-07-28 Sergey Poznyakoff <gray@gnu.org.ua>
Implement SMTP shell in mu.
* include/mailutils/smtp.h (mu_smtp_get_reply_iterator)
(mu_smtp_cmd,mu_smtp_test_param): New protos.
* libproto/mailer/Makefile.am (libmu_mailer_la_SOURCES): Add
smtp_cmd.c
* libproto/mailer/smtp_cmd.c: New file.
* libproto/mailer/smtp_io.c (mu_smtp_get_reply_iterator): New
function.
* libproto/mailer/smtp_param.c (mu_smtp_set_param): Accept NULL
parameter value.
(mu_smtp_test_param): New function.
* mu/Makefile.am [MU_COND_SUPPORT_SMTP]: Add smtp.c to MODULES.
(mu_SOURCES): Add getans.c, getyn.c and util.c
* mu/getans.c: New file.
* mu/getyn.c: New file.
* mu/smtp.c: New file.
* mu/util.c: New file.
* mu/mu.h (port_from_sa): New proto.
* mu/pop.c (port_from_sa): Move to util.c
2012-07-28 Sergey Poznyakoff <gray@gnu.org.ua>
Drop a superfluous dependency on libgcrypt.
* am/tls.m4 (MU_CHECK_GNUTLS): Newer GNU TLS does not require
libgcrypt. It is required only for v. 2.11 and prior versions.
2012-07-23 Sergey Poznyakoff <gray@gnu.org.ua>
Minor changes in SMTP and URL code.
* include/mailutils/smtp.h (mu_smtp_replcode)
(mu_smtp_sget_reply)
(mu_smtp_capa_iterator): New protos.
* libmailutils/url/dup.c (mu_url_dup): Bugfix. Obtain the name
using mu_url_sget_name, which will create it if necessary.
* libproto/mailer/Makefile.am (libmu_mailer_la_SOURCES): Add
smtp_capa_itr.c
* libproto/mailer/smtp_capa_itr.c: New file.
* libproto/mailer/smtp_io.c (mu_smtp_response): Fix filling of
smtp->flbuf.
(mu_smtp_replcode,mu_smtp_sget_reply): New functions.
2012-07-22 Sergey Poznyakoff <gray@gnu.org.ua>
pop3d: make tls more configurable.
The "tls" statement can be used both within a server
declaration and in the global scope, the former overriding the
latter. Its argument can be one of the following:
no TLS is not used. The STLS command won't be available even
if the tls configuration is otherwise complete.
ondemand TLS is initiated when the user issues the STLS
command.
This is the default when TLS is configured.
required Same as above, but the use of STLS is mandatory. The
authentication state is entered only after TLS negotiation
has succeeded.
connection TLS is always forced when the connection is
established (pops).
For compatibility with prior versions the tls-required
statement is retained, but is considered deprecated. It is
synonymous with "tls required". The "tls" statement allows for
the following alias values:
false, off, 0 same as no
stls same as ondemand
yes, true, on, 1 same as connection
Internally, all handler functions receive a pointer to the POP
session structure, which configures the current session. In
particular, it contains the TLS mode and capability list.
* pop3d/capa.c (pop3d_capa): Traverse the capability list,
outputting each of its elements. (pop3d_session_init)
(pop3d_session_free): New functions.
* pop3d/logindelay.c (login_delay_capa): Change signature.
* pop3d/pop3d.c (tls_required): Remove.
(tls_mode): New variable.
(pop3d_srv_config) <tls>: Remove.
(pop3d_srv_config) <tls_mode>: New member.
(pop3d_srv_param): Change definition of the "tls" statement.
(pop3d_cfg_param): New statement "tls". Mark "tls-required" as
deprecated.
(pop3d_mainloop): Change type of the tls argument. Initialize
session and pass it to each handler.
(pop3d_connection): Decide whether and how to use TLS using
global and per-session settings, the latter overriding the
former.
* pop3d/pop3d.h (login_delay_capa): Change signature.
(tls_mode): New enum.
(pop3d_capa_type): New enum.
(pop3d_capa, pop3d_session): New structs. (pop3d_session_init)
(pop3d_session_free): New protos.
(pop3d_command_handler_t): Change signature. All handlers and
their uses are changed accordingly.
* pop3d/stls.c (pop3d_stls): Return error if session does not
allow tls.
2012-07-21 Sergey Poznyakoff <gray@gnu.org.ua>
Minor fix.
2012-07-19 Sergey Poznyakoff <gray@gnu.org.ua>
mail: provide mechanism for listing and editing attachments
from the shell.
* NEWS: Update.
* mail/escape.c (escape_check_args): Take two additional
arguments specifying minimum and maximum number of parameters
to expect. All uses updated. Remove static qualifier.
* mail/mail.h (send_attach_file): Rename to
send_attach_file_default
(escape_check_args,escape_list_attachments)
(escape_attach,escape_remove_attachment): New protos.
* mail/send.c (send_attach_file): Take encoding and content
type as arguments.
(send_attach_file_default): New function.
(escape_list_attachments)
(escape_attach,escape_remove_attachment): New functions.
* mail/table.c: New escapes: l, +, ^
* include/mailutils/list.h (mu_list_remove_nth)
(mu_list_remove_nth_nd): New protos.
* libmailutils/list/Makefile.am (liblist_la_SOURCES): Add
removenth.c
* libmailutils/list/removenth.c: New file.
2012-07-18 Sergey Poznyakoff <gray@gnu.org.ua>
Implement --attach option in mail; fix dead.letter
functionality.
* NEWS: Update.
* doc/imprimatur: Upgrade.
* libmailutils/mime/attachment.c
(mu_message_create_attachment): Bugfixes.
* mail/mail.c: New options --attach, --content-type and
--encoding.
* mail/mail.h (default_encoding, default_content_type): New
externs.
(send_attach_file): New proto.
* mail/send.c (send_attach_file): New function.
(save_dead_message_env): New function.
(save_dead_message): Rewrite.
(mail_send0): Attach files, if requested.
2012-07-17 Wojciech Polak <polak@gnu.org>
Update C++ and Python interfaces.
* include/mailutils/prog.h: Add extern "C".
* include/mailutils/wordsplit.h: Likewise.
* libmu_cpp/address.cc (Address::to_string): Use
mu_address_sget_printable.
* libmu_cpp/filter.cc (FilterIconvStream): Use
mu_filter_create_args.
* python/mailutils/folder.py (get_stream, set_stream): Remove.
2012-07-17 Sergey Poznyakoff <gray@gnu.org.ua>
Spelling fixes.
2012-07-17 Sergey Poznyakoff <gray@gnu.org.ua>
Upgrade imprimatur module.
* doc/imprimatur: Upgrade.
2012-07-17 Sergey Poznyakoff <gray@gnu.org.ua>
Improve configuration options.
* am/enable.m4 (MU_ENABLE_BUILD): Change handling of
additional-cond
($4): the --{enable|disable}-build-* argument value overrides
it. This allows to use such configuration shortcuts as:
--disable-build-clients --enable-build-mail
which will build only mail, but no other client.
* configure.ac: New option --with-dbm can be used to
enable/disable building of all available DBM interfaces. It can
be used in conjunction with implementation-specific options in
the same way as described above, e.g.:
--without-dbm --with-gdbm
New option --with-mailbindir allows for overriding the
installation directory for mail[x] only.
* mail/Makefile.am (mailbindir): New variable.
(bin_PROGRAMS): Rename to mailbin_PROGRAMS.
2012-07-16 Sergey Poznyakoff <gray@gnu.org.ua>
Remove dependency on obstack. Use mu_opool_t instead.
* include/mailutils/opool.h (mu_opool_alloc): New proto.
* libmailutils/base/opool.c (mu_opool_alloc): New function.
(mu_opool_appendz): Do not append trailing null character.
* libmailutils/cfg/parser.y (mu_cfg_tree_create_node): Reflect
the change in mu_opool_appendz.
* comsat/action.c: Use mu_opool_t instead of struct obstack.
* lib/mailcap.c: Likewise.
* libmailutils/url/urlstr.c: Likewise.
* mh/burst.c: Likewise.
* mh/mh_fmtgram.y: Likewise.
* mh/mh_format.c: Likewise.
* mh/mh_format.h: Likewise.
* mh/mhn.c: Likewise.
* mh/repl.c: Likewise.
* mh/whatnowenv.c: Likewise.
* mimeview/mimetypes.l: Likewise.
* mimeview/mimeview.h: Likewise.
* gnulib.modules: Remove obstack.
2012-07-16 Sergey Poznyakoff <gray@gnu.org.ua>
Remove dependency on getline.
* gnulib.modules: Remove getline.
* pop3d/apop.c [!ENABLE_DBM] Use mu_stream API instead of FILE.
2012-07-16 Sergey Poznyakoff <gray@gnu.org.ua>
Bugfix.
Imap4d would fail to select a nonexistent maildir INBOX,
because the mu_mailbox_uidvalidity would return MU_ERR_NOENT.
* libmailutils/base/amd.c (_amd_scan0): Recompute uidvalidity
if the mailbox is empty.
2012-06-15 Sergey Poznyakoff <gray@gnu.org.ua>
inc: bugfix.
* mh/inc.c (incmbx): Fix typos.
2012-06-11 Sergey Poznyakoff <gray@gnu.org.ua>
Fix a typo.
* imap4d/copy.c (imap4d_copy0): Invert condition.
2012-06-10 Sergey Poznyakoff <gray@gnu.org.ua>
Fix in configuration reduction routines.
* libmailutils/cfg/parser.y (mu_cfg_preorder): Accept null node
lists.
2012-06-08 Sergey Poznyakoff <gray@gnu.org.ua>
Fix bug in mh testsuite.
We cannot assume that $HOME points to existing directory.
* mh/tests/testsuite.at (MH_SETUP): Override HOME environment
variable. Use it instead of curdir.
* mh/tests/atlocal.in (remove_curdir): Likewise.
* mh/tests/mhn.at: Likewise.
2012-06-07 Sergey Poznyakoff <gray@gnu.org.ua>
Minor fix.
* imap4d/imap4d.c Include mailutils/gsasl.h unconditionally.
2012-06-07 Sergey Poznyakoff <gray@gnu.org.ua>
Fixes: port cfg statement, listen cfg statement in maidag,
final dot recognition in maidag.
* include/mailutils/server.h (mu_m_server_listen)
(mu_m_server_parse_url): New protos.
* libmailutils/server/msrv.c (add_server): Rename to
mu_m_server_listen (now extern). All uses updated.
(get_port): Bugfix: return port in server byte order. This
fixes the use of the "port" configuration statement.
* maidag/lmtp.c (cfun_data): Don't switch to full buffering.
This makes it impossible to note the final dot in time.
* maidag/maidag.c (cb_listen): New callback.
(maidag_cfg_param): Attach cb_listen to the "listen" statement.
2012-06-07 Sergey Poznyakoff <gray@gnu.org.ua>
Implement two new Scheme functions.
* NEWS: Update.
* configure.ac: Version 2.99.97
* libmu_scm/mu_mailbox.c (mu-mailbox-sync)
(mu-mailbox-flush): New functions.
2012-06-06 Sergey Poznyakoff <gray@gnu.org.ua>
Fix comsat testsuite.
* comsat/tests/atlocal.in (MH_SUPPORT)
(MAILDIR_SUPPORT): New variables.
* comsat/tests/testsuite.at: Disable test cases if their
prerequisite features are not compiled in.
2012-06-04 Sergey Poznyakoff <gray@gnu.org.ua>
Don't use disabled features in mailutils.scm.
* libmu_scm/mailutils/Makefile.am (DISTCLEANFILES): Rename to
CLEANFILES: mailutils.scm should be cleaned as a usual object
file.
(MU_FEATURES): New variable, constructed depending on MU_COND_
variables.
(mailutils.scm goal): Use the value of MU_FEATURES as m4
command line.
* libmu_scm/mailutils/mailutils.scm.in: Include only supported
libraries.
2012-06-04 Sergey Poznyakoff <gray@gnu.org.ua>
Bugfix.
* libmailutils/base/symlink.c (mu_readlink): Fix initialization
of size.
2012-06-01 Sergey Poznyakoff <gray@gnu.org.ua>
Update root ignore list.
2012-06-01 Sergey Poznyakoff <gray@gnu.org.ua>
Fix typos in the generated ChangeLog.
* ChangeLog.amend: New file.
* Makefile.am: Apply corrections from ChangeLog.amend when
generating ChangeLog file.
2012-06-01 Sergey Poznyakoff <gray@gnu.org.ua>
Update ignore lists.
2012-06-01 Sergey Poznyakoff <gray@gnu.org.ua>
inc: accept mail from multiple source mailboxes.
* doc/texinfo/mu-mh.texi: Document changes to inc.
* NEWS: Likewise.
* mh/inc.c: Accept multiple source mailboxes.
(input_file): Remove.
(input_file_list): New variable.
(opt_handler): Multiple -file options augment input_file_list.
(incmbox): New function.
(main): Iterate over input_file_list, incorporating mail from
each mailbox in it.
Bugfix:
* libproto/imap/mbox.c (_imap_env_date): Return a 0-terminated
string.
Fix MH test suite.
The ali-everybody tests fails on machines with user database
kept in a non-standard storage (e.g. LDAP or NIS). This patch
attempts to fix it.
* mh/tests/lu.c: New file.
* mh/tests/.gitignore: Add lu.
* mh/tests/Makefile.am (noinst_PROGRAMS): New variable.
* mh/tests/ali.at: Use lu instead of scanning /etc/passwd
directly.
2012-05-13 Sergey Poznyakoff <gray@gnu.org.ua>
Bugfix in imap4d testsuite.
Reportedly, the test command on 64-bit boxes is unable to
handle unsigned long integers. Install a work over.
* imap4d/tests/IDEF0955.at: Use string comparison in the
invocation of test.
* imap4d/tests/IDEF0956.at: Likewise.
2012-05-09 Sergey Poznyakoff <gray@gnu.org.ua>
Minor change in bootstrap.
* bootstrap.conf: Avoid downloading radius.m4 if it is already
here.
2012-05-09 Sergey Poznyakoff <gray@gnu.org.ua>
Fix SMTP STARTTLS and SMTPS.
* libproto/mailer/smtp.c (smtp_open): Do not use mu_tls_enable,
rely on TLS stream functions to do the right thing. This
complements 325c864eb1b88ac73c39ca3681a02f5194021806.
2012-05-09 Sergey Poznyakoff <gray@gnu.org.ua>
Fix handling of URL authentication credentials in SMTP AUTH.
Provide special functions for storing and retrieving URL from
mu_smtp_t object, instead of using MU_SMTP_PARAM_URL. The major
drawback of the latter is that URLs in textual form can contain
obfuscated access credentials, which makes them unusable for
authentication.
* include/mailutils/smtp.h (mu_smtp_set_url) (mu_smtp_get_url)
(mu_smtp_set_secret,mu_smtp_get_secret): New protos.
* include/mailutils/sys/smtp.h (_mu_smtp) <url>: New member.
* libproto/mailer/smtp_secret.c: New file.
* libproto/mailer/smtp_url.c: New file.
* libproto/mailer/Makefile.am (libmu_mailer_la_SOURCES): Add
new files.
* libproto/mailer/smtp.c (smtp_open): Use mu_smtp_set_url to
preserve URL credentials.
* libproto/mailer/smtp_auth.c (_mu_smtp_fixup_params): Use
smtp->url.
* libproto/mailer/smtp_create.c (mu_smtp_destroy): Destroy
smtp->url.
* libproto/mailer/smtp_param.c (mu_smtp_set_param): Special
handling for MU_SMTP_PARAM_URL.
(mu_smtp_get_param): Likewise.
2012-05-09 Sergey Poznyakoff <gray@gnu.org.ua>
Fix quoted-printable and Q encodings.
The Q encoding in RFC 2047 is not exactly the same as
Quoted-Printable encoding: it differs in its handling of space
characters (ASCII 32), which are encoded as underscores.
* libmailutils/filter/qpflt.c (_qp_decoder): Use xd parameter
to determine whether to treat underscores specially.
(_qp_encoder): Likewise.
(_qp_filter,_Q_filter): Allocate and initialize filter data
accordingly to the kind of encoding.
2012-05-09 Sergey Poznyakoff <gray@gnu.org.ua>
Remove get_stream methods from folder and mailbox.
* doc/texinfo/folder.texi: Update
* include/mailutils/cpp/folder.h (Folder) <set_stream>
<get_stream>: Remove.
* include/mailutils/folder.h (mu_folder_get_stream)
(mu_folder_get_streamref)
(mu_folder_set_stream): Remove.
* include/mailutils/mailbox.h (mu_folder_get_stream)
(mu_folder_get_streamref)
(mu_folder_set_stream): Remove protos.
* include/mailutils/sys/folder.h (_mu_folder)<stream>: Remove.
All uses updated.
* libmailutils/mailbox/folder.c (mu_folder_set_stream)
(mu_folder_get_stream,mu_folder_get_streamref): Remove.
* libmailutils/mailbox/mailbox.c (mu_mailbox_get_stream)
(mu_mailbox_get_streamref): Remove.
* libmu_cpp/folder.cc (get_stream, set_stream): Remove.
* libmu_scm/mu_mailbox.c (mu-mailbox-get-port): Remove.
* python/libmu_py/folder.c (get_stream): Remove.
2012-05-09 Sergey Poznyakoff <gray@gnu.org.ua>
Minor fix.
* configure.ac: Fix quoting in FriBidi test.
2012-04-29 Sergey Poznyakoff <gray@gnu.org.ua>
Implement a copy method in mailbox.
This method copies given messages (indicated by their sequence
or UID numbers) to the given mailbox. So far this is
implemented only in IMAP[S] folders.
The mh/inc utility uses this method to optionally move
incorporated messages to other folder (mailbox) instead of
simply deleting them.
* include/mailutils/imap.h (mu_imap_response)
(mu_imap_response_code): New protos.
(MU_IMAP_CB_TAGGED_OK,MU_IMAP_CB_TAGGED_NO)
(MU_IMAP_CB_TAGGED_BAD): New callback codes.
* include/mailutils/mailbox.h (MU_MAILBOX_COPY_UID)
(MU_MAILBOX_COPY_CREAT): New constants.
(mu_mailbox_msgset_copy)
(mu_mailbox_message_copy): New protos.
* include/mailutils/sys/imap.h (resp_code): Rename to response
to avoid confusion. All uses updated.
(response_code): New member.
(_mu_imap_process_tagged_response): New proto.
* include/mailutils/sys/mailbox.h (_mu_mailbox) <_copy>: New
member.
* libmailutils/mailbox/Makefile.am (libmailbox_la_SOURCES): Add
copy.c
* libmailutils/mailbox/copy.c: New file.
* libproto/imap/err.c (mu_imap_response): New function.
(mu_imap_response_code): New function.
* libproto/imap/mbox.c (_imap_copy_to_mailbox)
(_mu_imap_mailbox_init): Implement _copy method.
* libproto/imap/resplist.c (IS_LBRACE,IS_RBRACE): Fix macros.
* libproto/imap/response.c (_mu_imap_response): Call
_mu_imap_process_tagged_response to process tagged responses.
* libproto/imap/resproc.c (parse_response_code): Bugfix:
expected ']' was set off by one.
(resptab)<code>: New member.
(_mu_imap_process_tagged_response): New function.
* mh/inc.c (options, mh_option, opt_handler): New option
--moveto.
(move_to_mailbox): New variable.
(main): If move_to_mailbox is set, move messages to that
mailbox instead of deleting them.
* mh/mh_getopt.h (mh_arg)<ARG_MOVETO>: New constant.
* NEWS: Update.
* include/mailutils/folder.h: Add a comment.
* libmailutils/mailbox/folder.c: Minor formatting change.
2012-04-27 Sergey Poznyakoff <gray@gnu.org.ua>
Minor fix.
* po/POTFILES.in: Remove xmalloc.c
2012-04-27 Sergey Poznyakoff <gray@gnu.org.ua>
Avoid using expr in tests with ulong as its argument.
* configure.ac (MU_ULONG_MAX): Rename to MU_ULONG_MAX_1,
decrease by one accordingly.
* imap4d/tests/IDEF0955.at: Use MU_ULONG_MAX_1 instead of
calling expr.
* imap4d/tests/IDEF0956.at: Likewise.
* imap4d/tests/atlocal.in: Define MU_ULONG_MAX_1.
2012-04-23 Sergey Poznyakoff <gray@gnu.org.ua>
Bugfixes.
* libproto/mailer/smtp.c (_smtp_set_rcpt): Assign rcpt_to a
copy of the recipient address.
* mail/util.c (util_header_expand): Make sure exp is always
initialized.
* mh/send.c (main): Process mtstailor before checking input
files, so its settings affect creation of additional headers
and addresses. In particular, this allows for setting the
sender address in mtstailor.
2012-04-13 Sergey Poznyakoff <gray@gnu.org.ua>
Fix SMTP test on machines with IPv6 enabled.
* testsuite/smtpsend.c: New assignment option `family=' to
force using a specified interface family.
* testsuite/smtp-msg.at: Force IPv4.
* testsuite/smtp-str.at: Likewise.
2012-03-25 Sergey Poznyakoff <gray@gnu.org.ua>
Revise some memory allocation routines.
* examples/aclck.c: Check return values from strdup.
* libmailutils/base/usremail.c: Likewise.
* libmailutils/mailbox/bodystruct.c: Likewise.
* lib/mailcap.c: Likewise.
* libmailutils/mailbox/mbx_default.c: Likewise.
* libmailutils/server/acl.c: Likewise.
* libmailutils/stream/logstream.c: Likewise.
* libmailutils/stream/message_stream.c: Likewise.
* libmu_argp/mu_argp.c: Likewise.
* libmu_auth/ldap.c: Likewise.
* libmu_auth/pam.c: Likewise.
* libmu_auth/sql.c: Likewise.
* libmu_sieve/comparator.c: Likewise.
* libmu_sieve/conf.c: Likewise.
* libmu_sieve/extensions/list.c: Likewise.
* libmu_sieve/extensions/vacation.c: Likewise.
* libproto/mailer/prog.c: Likewise.
* libproto/mailer/smtp_io.c: Likewise.
* maidag/lmtp.c: Likewise.
* python/libmu_py/address.c: Likewise.
* sql/odbc.c
* examples/sfrom.c (main): Avoid unnecessary memory allocation.
* libmailutils/mailbox/mailbox.c: Likewise.
* frm/frm.h: Include mailutils/alloc.h, remove xalloc.h
* mh/mh.h: Likewise.
* imap4d/imap4d.h: Remove xalloc.h
* mail/mail.h: Likewise.
* mimeview/mimeview.h: Likewise.
* mu/acl.c: Likewise.
* readmsg/readmsg.c: Likewise.
* include/mailutils/locker.h
(mu_locker_set_default_external_program): Change returned type.
* include/mailutils/mailbox.h (mu_set_folder_directory): Change
returned type.
* libmailutils/base/locker.c
(mu_locker_set_default_external_program): Return int (error
code).
* libmailutils/base/tilde.c: Add extra checks
* libmailutils/mime/mimehdr.c (_mime_header_parse): Bugfix.
* mail/folders.c: Don't use alloca, use mu_alloc instead. It
was the only use of that function in Mailutils, so this change
allows to withdraw the alloca module.
* gnulib.modules (alloca, malloc)
(realloc, xalloc): Remove.
* frm/common.c: Use mu_alloc and friends instead of xmalloc.
* frm/from.c: Likewise.
* imap4d/append.c: Likewise.
* imap4d/auth_gsasl.c: Likewise.
* imap4d/authenticate.c: Likewise.
* imap4d/fetch.c: Likewise.
* imap4d/imap4d.c: Likewise.
* imap4d/io.c: Likewise.
* imap4d/list.c: Likewise.
* imap4d/namespace.c: Likewise.
* imap4d/parsebuf.c: Likewise.
* imap4d/preauth.c: Likewise.
* imap4d/rename.c: Likewise.
* imap4d/search.c: Likewise.
* imap4d/util.c: Likewise.
* libmu_argp/muinit.c: Likewise.
* mail/alias.c: Likewise.
* mail/alt.c: Likewise.
* mail/copy.c: Likewise.
* mail/decode.c: Likewise.
* mail/escape.c: Likewise.
* mail/file.c: Likewise.
* mail/from.c: Likewise.
* mail/mail.c: Likewise.
* mail/mailline.c: Likewise
* mail/mailvar.c: Likewise
* mail/msgset.y: Likewise
* mail/page.c: Likewise
* mail/send.c: Likewise
* mail/shell.c: Likewise
* mail/unset.c: Likewise
* mail/util.c: Likewise
* mh/folder.c: Likewise
* mh/mh_alias.l: Likewise
* mh/mh_alias.y: Likewise
* mh/mh_fmtgram.y: Likewise
* mh/mh_format.c: Likewise
* mh/mh_global.c: Likewise
* mh/mh_init.c: Likewise
* mh/mh_list.c: Likewise
* mh/mh_whatnow.c: Likewise
* mh/mh_whom.c: Likewise
* mh/mhn.c: Likewise
* mh/pick.y: Likewise
* mh/prompter-rl.c: Likewise
* mh/refile.c: Likewise
* mh/repl.c: Likewise
* mh/send.c: Likewise
* mh/sortm.c: Likewise
* mimeview/mimetypes.y: Likewise
* mu/dbm.c: Likewise
* mu/dispatch.c: Likewise
* mu/imap.c: Likewise
* mu/pop.c: Likewise
* mu/shell.c: Likewise
* pop3d/apop.c: Likewise
* pop3d/bulletin.c: Likewise
* pop3d/popauth.c: Likewise
* pop3d/user.c: Likewise
2012-03-24 Sergey Poznyakoff <gray@gnu.org.ua>
Minor changes.
2012-03-23 Sergey Poznyakoff <gray@gnu.org.ua>
Fix semantics of MU_IOCTL_SUBSTREAM.
This also fixes e75e9123, which broke TLS support in daemons.
* include/mailutils/stream.h (MU_IOCTL_TOPSTREAM): New ioctl.
* imap4d/imap4d.c (set_strerr_flt)
(clr_strerr_flt): Use MU_IOCTL_TOPSTREAM.
* pop3d/pop3d.c: Likewise.
* libmailutils/stream/fltstream.c (filter_ctl): Handle both
MU_IOCTL_SUBSTREAM and MU_IOCTL_TOPSTREAM.
* libmailutils/stream/iostream.c (_iostream_ctl): Likewise.
* libmailutils/stream/logstream.c (_log_ctl): Likewise.
* libmailutils/stream/xscript-stream.c (_xscript_ctl):
Likewise.
2012-03-23 Sergey Poznyakoff <gray@gnu.org.ua>
Minor fixes.
* libmailutils/mime/mimehdr.c (free_param_continuation): Change
return type to void.
* mu/shell.c: Include muaux.h
* libproto/imap/logout.c (mu_imap_logout): Logout is valid in
any state, except MU_IMAP_SESSION_INIT.
2012-03-20 Sergey Poznyakoff <gray@gnu.org.ua>
Improve conversion between file mode and safety criteria and
vice versa.
* include/mailutils/util.h (mu_file_safety_code_to_name): New
proto.
* libmailutils/base/filesafety.c: Remove static functions which
checked file mode bits. Use safety_checker.mode for that
directly.
(mu_file_safety_code_to_name): New function.
(mu_file_mode_to_safety_criteria): Bugfix.
(mu_safety_criteria_to_file_mode): Change algorithm.
* libmailutils/tests/.gitignore: Update
* libmailutils/tests/fsaftomod.at: New file.
* libmailutils/tests/fsaftomod.c: New file.
* libmailutils/tests/modtofsaf.at: New file.
* libmailutils/tests/modtofsaf.c: New file.
* libmailutils/tests/Makefile.am (noinst_PROGRAMS): Add
fsaftomod and modtofsaf.
(TESTSUITE_AT): Add fsaftomod.at and modtofsaf.at
* libmailutils/tests/testsuite.at: Include fsaftomod.at and
modtofsaf.at
2012-03-17 Sergey Poznyakoff <gray@gnu.org.ua>
Bugfix.
* libmu_dbm/berkeley.c (do_bdb_open): Fix typo.
2012-03-17 Sergey Poznyakoff <gray@gnu.org.ua>
Add missing includes.
2012-03-17 Sergey Poznyakoff <gray@gnu.org.ua>
mh: minor fix in reply formats.
* mh/etc/replcomps: Format Fcc only if coming from myself.
* mh/etc/replgroupcomps: Likewise.
2012-03-17 Sergey Poznyakoff <gray@gnu.org.ua>
Implement session ID for TCP/UDP servers.
* imap4d/imap4d.c (set_strerr_flt,clr_strerr_flt): New
functions.
(imap4d_connection): Setup session prefix in strerr if
mu_log_session_id is set.
* imap4d/io.c (io_setio): Bugfix: unref debug stream.
* pop3d/extra.c (pop3d_setio): Likewise.
* pop3d/pop3d.c (set_strerr_flt,clr_strerr_flt): New functions.
(pop3d_connection): Setup session prefix in strerr if
mu_log_session_id is set.
* include/mailutils/acl.h (mu_acl_setenv)
(mu_acl_getenv,mu_acl_set_session_id): New functions.
* include/mailutils/server.h (mu_session_id): New extern.
(mu_m_server_configured_count): Fix signature.
* include/mailutils/syslog.h (mu_log_session_id): New extern.
* libmailutils/diag/syslog.c (mu_log_session_id): New global.
* libmailutils/server/acl.c (_mu_acl) <envv,envc,envn>: New
members.
(run_closure) <env>: New member.
(mu_acl_destroy): Free environment.
(_acl_match): Handle "family" variable.
(expand_arg): Propagate ACL environment to wordsplit.
(mu_acl_check_sockaddr): Propagate ACL environment.
(mu_acl_setenv)
(mu_acl_getenv,mu_acl_set_session_id): New functions.
* libmailutils/server/ipsrv.c (mu_ip_tcp_accept): Store session
ID in the ACL.
(mu_ip_udp_accept): Likewise.
* libmailutils/server/msrv.c (mu_m_server_configured_count):
Fix signature.
(mu_m_server_check_acl): Store session ID in the ACL.
* libmailutils/server/server.c (mu_session_id): New global
variable.
(connection_loop): Increment session ID
(mu_acl_set_session_id): New function.
* libmailutils/stream/fltstream.c (filter_ctl): Handle
MU_IOCTL_SUBSTREAM.
* libmailutils/stream/logstream.c (_log_ctl): Likewise.
* libmu_cfg/common.c (mu_logging_param) <session-id>: New
statement.
2012-03-14 Sergey Poznyakoff <gray@gnu.org.ua>
Minor fix in smtp transport.
* libproto/mailer/smtp.c (smtp_send_message): Filter out Fcc
and Bcc headers.
2012-03-14 Sergey Poznyakoff <gray@gnu.org.ua>
Fix creation of Berkeley db files.
* include/mailutils/util.h (mu_file_mode_to_safety_criteria)
(mu_safety_criteria_to_file_mode): New protos.
* libmailutils/base/filesafety.c (safety_checker) <mode>: New
member.
(file_safety_check_tab): Update.
(mu_file_mode_to_safety_criteria)
(mu_safety_criteria_to_file_mode): New functions.
* libmu_dbm/berkeley.c (do_bdb_open): Create file prior to
locking it.
2012-03-13 Sergey Poznyakoff <gray@gnu.org.ua>
mail: Implement folder completion in "save"
* mail/mailline.c (file_compl_internal): New function (from
file_compl);
(file_compl): Call file_compl_internal.
(msglist_file_compl): Call file_compl_internal.
2012-03-11 Sergey Poznyakoff <gray@gnu.org.ua>
Fix the use of struct utmp/utmpx in comsatd.
* am/utmp.m4: Check if struct utmp has ut_user or ut_name
members.
* comsat/comsat.c [HAVE_UTMPX_H]: Define UTMP as a typedef of
struct utmpx. Define ut_user, if necessary.
(find_user): Use ut_user instead of (backward-compatible)
ut_name.
2012-03-09 Sergey Poznyakoff <gray@gnu.org.ua>
Fix compilation of pop3d and maidag without DBM.
* maidag/Makefile.am: Load libmu_dbm.la if MU_COND_DBM is true.
* pop3d/apop.c (pop3d_apopuser): Set owner, if specified in the
config.
* pop3d/pop3d.c (apop_database_owner)
(apop_database_owner_set): New globals.
(pop3d_cfg_param) <apop-database-owner>: New keyword.
* pop3d/pop3d.h (apop_database_owner)
(apop_database_owner_set): New declarations.
2012-03-08 Sergey Poznyakoff <gray@gnu.org.ua>
Bugfix.
* mu/dbm.c: Include conditionally, depending on ENABLE_DBM.
2012-02-27 Sergey Poznyakoff <gray@gnu.org.ua>
Fix locking of Berkeley databases.
* include/mailutils/locker.h (mu_locker_lock_mode): New proto.
* libmailutils/base/locker.c (_mu_locker_lock): Rename to
mu_locker_lock_mode. All callers updated.
* libmu_dbm/berkeley.c (bdb_file) <locker>: New member.
(do_bdb_open): New function. Lock the database file before
opening it. Drop support for version 2.
(_bdb_open): Rewrite as a wrapper over do_bdb_open.
* mu/dbm.c (dbm_doc): Document the "dump" subcommand.
* NEWS: Version 2.99.96
* configure.ac: Likewise.
2012-02-26 Sergey Poznyakoff <gray@gnu.org.ua>
Fix parsing local URLs.
* include/mailutils/url.h (MU_URL_PARSE_LOCAL): New flag.
* libmailutils/tests/url-parse.c (parse_kwtab): New flag
"local".
* libmailutils/tests/url.at: Add new tests
* libmailutils/url/create.c (_mu_url_ctx_parse_host): Skip
parsing host part if MU_URL_PARSE_LOCAL is set.
(_mu_url_create_internal): Initialize rc. If MU_URL_PARSE_SLASH
is set and URL begins with "./" assume it is file. If either
MU_URL_PARSE_SLASH or MU_URL_PARSE_PIPE are given and the URL
is diagnosed as file or pipe, prefer the scheme from hints.
2012-02-21 Sergey Poznyakoff <gray@gnu.org.ua>
Bugfixes.
* include/mailutils/Makefile.am: Add types to
pkginclude_HEADERS.
* libmailutils/tests/url-comp.at: Add missing dnl.
2012-02-20 Sergey Poznyakoff <gray@gnu.org.ua>
Bugfix.
* mh/mhn.c (mhn_edit): Destroy output prior to unreferencing
msg, because it may have been taken from it.
2012-01-22 Sergey Poznyakoff <gray@gnu.org.ua>
Minor fix.
* libproto/mailer/smtp.c (smtp_send_message): Fix typo.
2012-01-13 Sergey Poznyakoff <gray@gnu.org.ua>
Bugfix in the testsuite.
* testsuite/smtp-msg.at: Ignore output from kill.
* testsuite/smtp-str.at: Likewise.
2012-01-11 Sergey Poznyakoff <gray@gnu.org.ua>
Assorted fixes.
* libmailutils/mailer/mailer.c (mu_mailer_send_fragments): Fix
3rd argument to _set_to.
* libproto/mailer/smtp.c (smtp_send_message): SIZE capability
can appear alone, without specifying maximum size.
* mh/mh_whom.c (mh_alias_expand): Recreate domain part for
addresses missing it.
2012-01-08 Sergey Poznyakoff <gray@gnu.org.ua>
Restore extra quoting in test mhn-store-pipe of
mh/tests/mhn.at.
Extra quoting is necessary because the argument includes
unbalanced parentheses. It was first implemented in commit
1b5098c9 on 2011-05-05, but was accidentally removed in commit
1e33c774 on 2011-10-16.
2012-01-05 Sergey Poznyakoff <gray@gnu.org.ua>
Bugfix in the testsuite.
* libmailutils/tests/url-comp.c (main): Initialize URL.
2012-01-05 Sergey Poznyakoff <gray@gnu.org.ua>
Happy GNU Year.
2011-12-31 Sergey Poznyakoff <gray@gnu.org.ua>
Implement SMTPS.
* NEWS: Update.
* include/mailutils/registrar.h (mu_smtps_record): New extern.
(mu_register_all_mailer_formats): Register mu_smtps_record.
* include/mailutils/sys/registrar.h (MU_SMTPS_SCHEME)
(MU_SMTPS_SCHEME_LEN,MU_SMTPS_PORT): New defines.
* libmailutils/address/address.c (mu_address_get_count): Don't
count parts with NULL emails.
(mu_address_contains_email): Validate email before comparison.
(mu_list_copy): New static.
(mu_address_union): Reuse last subaddress if its email is NULL.
* libmailutils/base/nullrec.c (mu_smtps_record): New
placeholder.
* libproto/mailer/smtp.c (mu_smtps_record): New global.
(smtp_open): Implement SMTPS
* mu/send.c: New file.
* mu/Makefile.am (MODULES): Add send.c
2011-12-31 Sergey Poznyakoff <gray@gnu.org.ua>
Add SMTP test.
* examples/mta.c: Handle -bD option. Detach from the
controlling terminal if -bd is given. Print pid and port number
in this case.
* testsuite/smtpsend.c: Fix handling of the trace= option.
* testsuite/Makefile.am: Add new tests.
* testsuite/smtp-msg.at: New test case.
* testsuite/smtp-str.at: New test case.
* testsuite/testsuite.at: Include new test cases.
2011-12-30 Sergey Poznyakoff <gray@gnu.org.ua>
Fix a bug in DOT decoder.
2011-12-30 Sergey Poznyakoff <gray@gnu.org.ua>
Improve msgset interface. Use it in MH.
* libmailutils/msgset/Makefile.am (libmsgset_la_SOURCES): Add
new files.
* libmailutils/msgset/addset.c: New file.
* libmailutils/msgset/count.c: New file.
* libmailutils/msgset/foreachmsgno.c: New file.
* libmailutils/msgset/foreachuid.c: New file.
* libmailutils/msgset/isempty.c: New file.
* libmailutils/msgset/subset.c: New file.
* libmailutils/msgset/trans.c: New file.
* libmailutils/msgset/add.c (mu_msgset_add_range): Take fourth
argument specifying the conversion mode. Translate numbers as
necessary.
* libmailutils/msgset/foreachmsg.c: Translate numbers as
necessary.
* libmailutils/msgset/foreachnum.c: Rewrite.
* libmailutils/msgset/negate.c (_invert_range)
(mu_msgset_add_range): Update calls to mu_msgset_add_range.
* libmailutils/msgset/parse.c (parse_msgnum_env)<mode>: New
member.
(parse_msgrange): Update calls to mu_msgset_add_range.
(mu_msgset_parse_imap): Change signature. All callers updated.
* libmailutils/msgset/sub.c (mu_msgset_sub_range): Take fourth
argument specifying the conversion mode. Translate numbers as
necessary.
* imap4d/copy.c (imap4d_copy0): Update calls to
mu_msgset_create and mu_msgset_parse_imap.
* imap4d/fetch.c (fetch_thunk): Likewise.
* imap4d/search.c (parse_simple_key): Likewise.
* imap4d/store.c (store_thunk): Likewise.
* include/mailutils/msgset.h (MU_MSGSET_NUM,MU_MSGSET_UID): New
defines.
(mu_msgset_add,mu_msgset_sub): New protos.
(mu_msgset_add_range,mu_msgset_sub_range): Take 4 arguments.
All callers changed.
* include/mailutils/sys/msgset.h (_mu_msgset_translate_pair)
(_mu_msgset_translate_range): New protos.
* libmailutils/tests/msgset.c: Reflect the above changes.
* testsuite/msgset.c: Likewise.
* libproto/imap/mbox.c: Update calls to mu_msgset functions.
* mh/mh.h (mh_msgset_t): Remove.
(mh_iterator_fp): Remove typedef.
(mh_msgset_parse): Change signature.
(mh_msgset_member,mh_msgset_reverse,mh_msgset_negate)
(mh_msgset_current,mh_msgset_free,mh_msgset_uids): Remove
protos.
(mh_msgset_parse_string): New proto.
(mh_msgset_first_current,mh_msgset_first): New proto.
(mh_iterate: Remove proto. Use mu_msgset_foreach* functions
instead.
(mh_seq_add,mh_seq_delete): Change signatures.
* mh/mh_init.c (mh_iterate): Remove.
* mh/mh_msgset.c: Rewrite using mu_msgset_t.
* mh/mh_sequence.c: Likewise.
* mh/anno.c: Use new msgset functions.
* mh/burst.c: Likewise.
* mh/comp.c: Likewise.
* mh/folder.c: Likewise.
* mh/forw.c: Likewise.
* mh/mark.c: Likewise.
* mh/mhn.c: Likewise.
* mh/mhpath.c: Likewise.
* mh/mhseq.c: Likewise.
* mh/pick.c: Likewise.
* mh/refile.c: Likewise.
* mh/repl.c: Likewise.
* mh/rmm.c: Likewise.
* mh/scan.c: Likewise.
* mh/send.c: Likewise.
* mh/sortm.c: Likewise.
* mh/whatnowenv.c: Likewise.
* mh/tests/mark.at: Reflect changes in the format of the saved
sequences, which may contain ranges now.
* mu/imap.c: Update calls to mu_msgset functions.
2011-12-28 Sergey Poznyakoff <gray@gnu.org.ua>
msgset: implement "foreach" calls.
* imap4d/copy.c (copy_env) <src>: Remove. Not needed now.
(size_sum,do_copy): Change to a mu_msgset_message_action_t.
(try_copy,safe_copy): Change signature; use
mu_msgset_foreach_message.
* imap4d/fetch.c (_fetch_from_message): Change to a
mu_msgset_message_action_t.
(imap4d_fetch0): Use mu_msgset_foreach_message.
* imap4d/imap4d.h (imap4d_message_action_t): Remove typedef.
(util_foreach_message): Remove. Use mu_msgset_foreach_message.
* imap4d/store.c (_do_store): Change to a
mu_msgset_message_action_t.
(imap4d_store0): Use mu_msgset_foreach_message.
* imap4d/util.c (util_foreach_message): Remove.
* include/mailutils/list.h (mu_list_foreach_dir): New proto.
* include/mailutils/msgset.h (mu_msgset_msgno_action_t)
(mu_msgset_message_action_t): New typedefs.
(mu_msgset_negate,mu_msgset_foreach_dir_msgno)
(mu_msgset_foreach_msgno,mu_msgset_foreach_dir_message)
(mu_msgset_foreach_message): New protos.
* libmailutils/list/foreachdir.c: New file.
* libmailutils/list/Makefile.am (liblist_la_SOURCES): Add
foreachdir.c.
* libmailutils/list/head.c (mu_list_head): Fix conditional.
* libmailutils/list/tail.c (mu_list_tail): Likewise.
* libmailutils/msgset/foreachmsg.c: New file.
* libmailutils/msgset/foreachnum.c: New file.
* libmailutils/msgset/negate.c: New file.
* libmailutils/msgset/Makefile.am (libmsgset_la_SOURCES): Add
new files.
* libmailutils/msgset/getitr.c (mu_msgset_get_iterator): Call
mu_msgset_aggregate before doing anything.
* libmailutils/msgset/getlist.c (mu_msgset_get_list): Likewise.
* libmailutils/msgset/locate.c (mu_msgset_locate): Likewise.
* libmailutils/msgset/parse.c (parse_msgrange): Remove
duplicated code.
* testsuite/msgset.c: Implement -neg option.
2011-12-27 Sergey Poznyakoff <gray@gnu.org.ua>
Update TODO.
2011-12-26 Sergey Poznyakoff <gray@gnu.org.ua>
Use mu_msgset_t in imap4d.
* imap4d/util.c (util_parse_msgset): Remove. Use
mu_msgset_parse_imap. All uses changed.
(util_foreach_message): Change first argument to mu_msgset_t.
All uses changed.
* imap4d/imap4d.h: Likewise.
* imap4d/copy.c: Use mu_msgset_t
* imap4d/fetch.c: Likewise.
* imap4d/search.c: Likewise.
* imap4d/store.c: Likewise.
2011-12-26 Sergey Poznyakoff <gray@gnu.org.ua>
Use mu_msgset_t in imap client for FETCH, STORE and COPY.
* include/mailutils/imap.h (mu_imap_fetch,mu_imap_store)
(mu_imap_store_flags,mu_imap_copy): Take mu_msgset_t as the
message set parameter.
* include/mailutils/imapio.h (mu_imapio_send_msgset): New
proto. (mu_imapio_send_command_v,mu_imapio_send_command)
(mu_imapio_send_command_e): Take additional mu_msgset_t
parameter. All uses changed.
* include/mailutils/msgset.h (mu_msgset_parse_imap): Input
string is const.
* include/mailutils/sys/imap.h (imap_command) <msgset>: New
member.
* libmailutils/imapio/sendmsgset.c: New file.
* libmailutils/imapio/Makefile.am (libimapio_la_SOURCES): Add
sendmsgset.c.
* libmailutils/imapio/sendcmd.c (mu_imapio_send_command): Take
additional mu_msgset_t parameter.
* libmailutils/imapio/sendcmde.c (mu_imapio_send_command_e):
Likewise.
* libmailutils/imapio/sendcmdv.c (mu_imapio_send_command_v):
Likewise.
* libmailutils/msgset/parse.c (mu_msgset_parse_imap): Input
string is const.
* libproto/imap/copy.c (mu_imap_copy): Take mu_msgset_t as the
message set parameter.
* libproto/imap/fetch.c (mu_imap_fetch): Likewise.
* libproto/imap/store.c (mu_imap_store): Likewise.
* libproto/imap/storeflg.c (mu_imap_store_flags): Likewise.
* libproto/imap/gencom.c (mu_imap_gencom): Send cmd->msgset.
2011-12-26 Sergey Poznyakoff <gray@gnu.org.ua>
Bugfix.
* libmailutils/mailbox/mailbox.c (_MBOX_CHECK_FLAGS): Fix
return code.
2011-12-26 Sergey Poznyakoff <gray@gnu.org.ua>
Add functions for operations on message sets.
* configure.ac: Build libmailutils/msgset/Makefile
* include/mailutils/msgset.h: New file.
* include/mailutils/Makefile.am (pkginclude_HEADERS): Add
msgset.h
* include/mailutils/mailutils.h: Include mailutils/msgset.h
* include/mailutils/sys/msgset.h: New file.
* include/mailutils/sys/Makefile.am (sysinclude_HEADERS): Add
msgset.h
* include/mailutils/types.hin (mu_msgset_t): New type.
* libmailutils/Makefile.am (SUBDIRS): Add msgset.
(libmailutils_la_LIBADD): Add libmsgset.la
* libmailutils/msgset/Makefile.am: New file.
* libmailutils/msgset/add.c: New file.
* libmailutils/msgset/aggr.c: New file.
* libmailutils/msgset/clear.c: New file.
* libmailutils/msgset/create.c: New file.
* libmailutils/msgset/free.c: New file.
* libmailutils/msgset/getitr.c: New file.
* libmailutils/msgset/getlist.c: New file.
* libmailutils/msgset/locate.c: New file.
* libmailutils/msgset/parse.c: New file.
* libmailutils/msgset/print.c: New file.
* libmailutils/msgset/sub.c: New file.
* libmailutils/tests/msgset.at: New file.
* libmailutils/tests/msgset.c: New file.
* libmailutils/tests/Makefile.am (noinst_PROGRAMS): Add msgset.
(TESTSUITE_AT): Add msgset.at.
* libmailutils/tests/testsuite.at: Include msgset.at.
* testsuite/msgset.c: New file.
* testsuite/Makefile.am (noinst_PROGRAMS): Add msgset.
2011-12-25 Sergey Poznyakoff <gray@gnu.org.ua>
imap mbox: minor improvements.
* libproto/imap/mbox.c: Add some debugging messages.
(_imap_mbx_gensync): New function shared among _imap_mbx_sync
and _imap_mbx_expunge. It aggregates message numbers with same
flags to separate message sets, thereby reducing the number of
STORE commands sent to the server.
2011-12-23 Sergey Poznyakoff <gray@gnu.org.ua>
Minor fixes in imap.
* include/mailutils/imap.h (MU_IMAP_RESPONSE_UNKNOWN)
(MU_IMAP_RESPONSE_TAGGED): New defines.
* libproto/imap/mbox.c (_imap_mbx_open): Fix callback ID.
* libproto/imap/response.c (_mu_imap_response): Call
MU_IMAP_CB_BAD callback on tagged BAD responses as well.
* libproto/imap/storeflg.c (mu_imap_store_flags): Insert space
after item name.
2011-12-23 Wojciech Polak <polak@gnu.org>
Update the NEWS file.
2011-12-23 Sergey Poznyakoff <gray@gnu.org.ua>
Finish imap mailbox implementation.
Some features are missing (notably, quick access), but overall
the implementation offers all necessary features and performs a
lot better than 2.x.
Additionally, this commit fixes a minor bug in the imap4d
implementation: the STORE command did not accept empty flag
list.
* NEWS: Update.
* imap4d/store.c (store_thunk): Accept empty list as "items"
argument.
* include/mailutils/imap.h (mu_imap_store_flags): New proto.
* include/mailutils/imaputil.h (mu_imap_format_flags): Add new
argument.
* include/mailutils/sys/imap.h (_MU_IMAP_MSG_ATTRCHG): New
flag.
* libmailutils/imapio/flags.c: Accept three arguments, last one
being a boolean flag specifying whether we want \Recent in the
output.
* libproto/imap/storeflg.c: New flag.
* libproto/imap/Makefile.am (libmu_imap_la_SOURCES): Add
storeflg.c.
* libproto/imap/mbox.c: Finish the basic implementation.
* imap4d/sync.c: Update calls to mu_imap_format_flags.
* imap4d/util.c: Likewise.
* mu/imap.c: Likewise.
* libmailutils/imapio/sendflg.c (mu_imapio_send_flags):
Likewise.
2011-12-23 Sergey Poznyakoff <gray@gnu.org.ua>
Implement imap mailbox (read-only, so far).
* include/mailutils/sys/imap.h (_mu_imap_mailbox_init): New
proto.
(_mu_imap_message,_mu_imap_mailbox): New structures.
* libproto/imap/mbox.c: New file.
* libproto/imap/Makefile.am (libmu_imap_la_SOURCES): Put back
mbox.c
* libproto/imap/fetch.c: Fix body/bodystructure parsing.
* libproto/imap/folder.c (_mu_imap_folder_destroy): Close
folder.
(_mu_imap_folder_open): Implement STARTTLS.
(_imap_record): Accept parameters in URL, use
_mu_imap_mailbox_init to initialize mailbox.
2011-12-23 Sergey Poznyakoff <gray@gnu.org.ua>
Bugfixes in imap client.
* libproto/imap/fetch.c (_fetch_fold): Fix parsing of BODY[].
(_mu_imap_parse_fetch_response): Fix return value.
2011-12-22 Sergey Poznyakoff <gray@gnu.org.ua>
mu imap: implement copy command.
* mu/imap.c (com_copy): New function.
(print_list_item): Treat 0 separator as '/' to avoid
preliminary truncating the output.
2011-12-22 Sergey Poznyakoff <gray@gnu.org.ua>
Implement imap (client) bodystructure and envelope.
* libmailutils/string/wordsplit.c (alloc_space): Fix
reallocation calculations.
* imap4d/fetch.c (bodystructure): Output number of lines for
any TEXT part, not only TEXT/PLAIN.
* include/mailutils/header.h (MU_HEADER_CONTENT_LOCATION): New
define.
* include/mailutils/imap.h (mu_imap_fetch_bodystructure):
Implement.
(mu_imap_fetch_envelope): Replace data fields with a single
pointer to struct mu_imapenvelope.
* include/mailutils/message.h: Include datetime.h
(mu_imapenvelope, mu_bodystructure): New structs.
(mu_message_type): New type.
(mu_message_get_imapenvelope,mu_message_imapenvelope_free)
(mu_message_set_imapenvelope)
(mu_bodystructure_free,mu_list_free_bodystructure)
(mu_message_get_bodystructure)
(mu_message_set_bodystructure): New protos.
* include/mailutils/mime.h (mu_mime_param_assoc_create)
(mu_mime_param_assoc_add): New protos.
* include/mailutils/sys/message.h (_mu_message)<_imapenvelope>
<_bodystructure>: New methods.
* libmailutils/mailbox/bodystruct.c: New file.
* libmailutils/mailbox/imapenv.c: New file.
* libmailutils/mailbox/Makefile.am (libmailbox_la_SOURCES): Add
new sources.
* libproto/imap/fetch.c: Implement bodystructure.
* mu/imap.c: Likewise.
* testsuite/bs.c: New file.
* testsuite/Makefile.am (noinst_PROGRAMS): Add bs.
2011-12-21 Sergey Poznyakoff <gray@gnu.org.ua>
Fix API for obtaining full email address.
Old API relied on passing a pointer to the buffer string and
its size, which is defective. The new API, in addition to that,
provides functions for obtaining a pointer to the statically
allocated original value, a pointer to dynamically allocated
copy, and a function for formatting the address directly to a
MU stream.
Two functions are marked as deprecated: mu_address_to_string
and mu_address_format_string. Both assume a pointer to an
allocated string of a fixed size, which is far from being
convenient nor reliable enough.
* include/mailutils/address.h (MU_ADDR_HINT_ADDR): Rename to
MU_ADDR_HINT_PRINTABLE
(mu_address)<addr>: Rename to printable.
(mu_address_sget_printable,mu_address_aget_printable)
(mu_address_get_printable): New protos.
(mu_stream_format_address): New proto. (mu_address_to_string)
(mu_address_format_string): Mark as deprecated.
(mu_validate_email): New proto.
* examples/mta.c: Use mu_address_sget_printable instead of
(mu_address_to_string)
* libmailutils/address/addrstream.c: New file.
* libmailutils/address/Makefile.am (libaddress_la_SOURCES): Add
addrstream.c
* libmailutils/address/address.c (mu_address_format_string):
Rewrite using streams.
(mu_address_to_string): Rewrite as a wrapper over
mu_address_get_printable.
(mu_address_sget_printable,mu_address_aget_printable)
(mu_address_get_printable): New functions.
* libmailutils/mime/mimehdr.c (_mime_header_parse): Initialize
rc.
* mail/util.c (util_merge_addresses): Use
mu_address_aget_printable.
* mh/mh.h (mh_annotate): Both string args are const.
* mh/mh_init.c (mh_annotate): Likewise.
* mh/mh_format.c (builtin_formataddr): Use
mu_address_sget_printable.
* mh/mh_whatnow.c (anno_data)<field,value>: Both are consts.
(annotate): Use mu_address_sget_printable.
* mh/send.c (set_address_header): Use
mu_address_sget_printable.
* mu/imap.c (format_email): Use mu_stream_format_address.
* python/libmu_py/address.c (api_address_to_string): Likewise.
2011-12-21 Sergey Poznyakoff <gray@gnu.org.ua>
imap4d: Fix fetch in case of message/rfc822.
This case requires full recursion.
* imap4d/fetch.c (bodystructure): Call fetch_bodystructure0.
2011-12-21 Sergey Poznyakoff <gray@gnu.org.ua>
Bugfix.
2011-12-21 Sergey Poznyakoff <gray@gnu.org.ua>
Re-implement parser for RFC-2231 header fields.
The new implementation is able to return all parameters at
once, in an associative array. A subset of parameters can be
requested. The data are automatically converted to the output
charset.
In addition, RFC-2047 parser is extended to support language
specifications (RFC-2231, chapter 5).
* include/mailutils/message.h (MU_MIMEHDR_CSINFO)
(MU_MIMEHDR_MULTILINE): Remove, not public anymore.
(mu_mimehdr_get_param,mu_mimehdr_aget_param)
(mu_message_aget_attachment_name)
(mu_message_get_attachment_name): Remove pflags argument.
* include/mailutils/mime.h (mu_mime_param): New struct.
(mu_rfc2047_decode_param)
(mu_mime_header_parse,mu_mime_header_parse_subset): New proto.
* libmailutils/base/rfc2047.c (_rfc2047_decode_param): New
auxiliary function. Use memory stream to collect data.
(mu_rfc2047_decode): Rewrite as a wrapper around the above.
(mu_rfc2047_decode_param): New function.
* libmailutils/filter/decode.c (mu_decode_filter_args): Pass
actual (instead of maximal) number of arguments to
mu_filter_chain_create.
* libmailutils/mime/mimehdr.c: Rewrite from scratch.
* libmailutils/tests/.gitignore: Add mimehdr.
* libmailutils/tests/Makefile.am (noinst_PROGRAMS): Add
mimehdr.
(TESTSUITE_AT): Add mimehdr.at.
* libmailutils/tests/mimehdr.at: New test.
* libmailutils/tests/mimehdr.c: New test program.
* libmailutils/tests/testsuite.at: Include.
2011-12-17 Sergey Poznyakoff <gray@gnu.org.ua>
Move Python support from experimental to stable features.
2011-12-17 Sergey Poznyakoff <gray@gnu.org.ua>
Fix the use of the hierarchy delimiter.
* include/mailutils/util.h (MU_HIERARCHY_DELIMITER): New
define.
(mu_tilde_expansion): Change signature. Delimiter is an int.
* libmailutils/base/tilde.c: Likewise. All uses update.
* imap4d/namespace.c (namespace_checkfullpath)
(namespace_getfullpath): Remove delim argument. All uses
updated.
* imap4d/util.c (util_getfullpath): Remove delim argument. All
uses updated.
2011-12-17 Sergey Poznyakoff <gray@gnu.org.ua>
Use IMAP-stile wildcards in folder matchers by default.
* imap4d/imap4d.h: Include mailutils/imaputil.h
* imap4d/list.c: Use mu_folder_imap_match/mu_imap_wildmatch.
* imap4d/lsub.c: Likewise.
* imap4d/util.c (util_wcard_match): Move as to libmailutils as
mu_imap_wildmatch.
* include/mailutils/imaputil.h: New file.
* include/mailutils/Makefile.am (pkginclude_HEADERS): Add
imaputil.h
* include/mailutils/folder.h (mu_folder_imap_match)
(mu_folder_glob_match): New protos.
* include/mailutils/imapio.h (mu_imap_flag_to_attribute)
(mu_imap_format_flags): Move to imaputil.h
* libmailutils/imapio/wildmatch.c: New file.
* libmailutils/imapio/sendflg.c: New file.
* libmailutils/imapio/Makefile.am (libimapio_la_SOURCES): Add
sendflg.c and wildmatch.c.
* libmailutils/imapio/flags.c (mu_imapio_send_flags): Move to
sendflg.c
* libmailutils/mailbox/folder.c (mu_folder_match): Rename to
mu_folder_glob_match.
(mu_folder_imap_match): New function.
(mu_folder_create_from_record): Use mu_folder_imap_match as the
default matcher.
* libmailutils/tests/fsfolder.c: Start command line options
with a dash. New option "-glob". All uses changed.
* libproto/imap/select.c: Include imaputil.h
* mu/imap.c: Likewise.
2011-12-16 Sergey Poznyakoff <gray@gnu.org.ua>
Provisions for loading python modules from the source tree.
* python/Makefile.am (EXTRA_DIST): Add usercustomize.py
* python/usercustomize.py: New file.
* python/libmu_py/Makefile.am (pythonexec_LTLIBRARIES): Remove.
* python/mailutils/Makefile.am (pythonexec_LTLIBRARIES): New
variable (moved from ../libmu_py/Makefile.am)
* python/libmu_py/c_api.c: Move ...
* python/mailutils/c_api.c: ... there
2011-12-16 Sergey Poznyakoff <gray@gnu.org.ua>
Add a test suite for folder delete method.
* testsuite/Makefile.am: Add new test cases.
* testsuite/testsuite.at: Include fldel.at, add banners.
* testsuite/atlocal.in: Define MH_SUPPORT and MAILDIR_SUPPORT
variables depending on whether the corresponding mailbox format
is enabled.
* testsuite/fldel.at: New test case.
* testsuite/mbdel.at: Skip tests which rely on disabled mailbox
formats.
2011-12-16 Sergey Poznyakoff <gray@gnu.org.ua>
Share folder implementation between mbox, mh and maildir. Fix
mu_folder_delete.
* include/mailutils/folder.h (_mu_fsfolder_init): New proto.
* include/mailutils/mailbox.h (mu_mailbox_create_at): New
proto.
* libmailutils/mailbox/mailbox.c (mu_mailbox_create_at): New
function.
* libmailutils/mailbox/Makefile.am (libmailbox_la_SOURCES): Add
fsfolder.c
* libmailutils/mailbox/folder.c (mu_folder_delete): If folder
does not provide its own method for deletion, use
mu_mailbox_remove. (mu_folder_open, mu_folder_close,
mu_folder_enumerate) (mu_folder_lsub, mu_folder_subscribe,
mu_folder_unsubscribe)
(mu_folder_rename): Return EINVAL if folder is NULL.
(mu_folder_match): Bugfix: don't pass folder flags to fnmatch.
* libmailutils/mailbox/fsfolder.c: New file. Implementation of
file-system based folders.
* libmailutils/mailbox/mailbox (_create_mailbox0): Propagate
error return from mu_registrar_lookup_url.
* libmailutils/tests/fsfolder00.at: New test case.
* libmailutils/tests/fsfolder01.at: New test case.
* libmailutils/tests/fsfolder02.at: New test case.
* libmailutils/tests/Makefile.am (noinst_PROGRAMS): Add
fsfolder.
(TESTSUITE_AT): Add fsfolder tests.
* libmailutils/tests/testsuite.at: Include fsfolder tests.
* libproto/mbox/folder.c: Use fsfolder.
(_mh_is_scheme): Check file even if scheme matches.
* libproto/maildir/folder.c: Likewise.
(_maildir_is_scheme): Check file even if scheme matches.
* libproto/mh/folder.c: Likewise.
* testsuite/fldel.c: New file.
* testsuite/Makefile.am (noinst_PROGRAMS): Build fldel.
2011-12-16 Sergey Poznyakoff <gray@gnu.org.ua>
Minor cleanup in imap client.
* include/mailutils/imap.h (mu_imap_session_state): Remove.
(mu_imap_state): Rename to mu_imap_session_state.
(mu_imap_state_str): Rename to mu_imap_session_state_str.
* libproto/imap/create.c (mu_imap_session_state)
(mu_imap_iserror,mu_imap_clearerr): Move to state.c
* mu/imap.c: Update accordingly.
2011-12-15 Sergey Poznyakoff <gray@gnu.org.ua>
imap client: implement folder API.
* libmailutils/list/listlist.c (mu_list_append_list): Do
nothing if the source list is empty.
* include/mailutils/sys/imap.h (_mu_imap_url_init)
(_mu_imaps_url_init): New protos.
* libproto/imap/Makefile.am (libmu_imap_la_SOURCES): Restore
url.c
* libproto/imap/mbox.c: Deleted
* libproto/imap/url.c: Rewrite.
* libproto/imap/folder.c: Rewrite from scratch.
* configure.ac: Build libproto/imap/tests/Makefile
* include/mailutils/imap.h (mu_imap_session_state)
(mu_imap_iserror, mu_imap_clearerr)
(mu_imap_login_secret): New protos.
* include/mailutils/sys/imap.h (_mu_imap_list_element_is_nil):
New proto.
* libmailutils/mailbox/folder.c (mu_folder_list): Pass
MU_FOLDER_ATTRIBUTE_ALL.
* libproto/imap/fake-folder.c: Remove.
* libproto/imap/Makefile.am (libmu_imap_la_SOURCES): Remove
fake-folder.c Add url.c and folder.c
* libproto/imap/create.c (mu_imap_session_state)
(mu_imap_iserror, mu_imap_clearerr): New functions.
* libproto/imap/delete.c: Check input parameters.
* libproto/imap/fetch.c: Use _mu_imap_list_element_is_nil to
check for empty lists.
* libproto/imap/genlist.c: Likewise.
* libproto/imap/rename.c: Likewise.
* libproto/imap/subscribe.c: Likewise.
* libproto/imap/unsubscribe.c: Likewise.
* libproto/imap/resplist.c: Treat NIL and () equally.
* libproto/imap/login.c (mu_imap_login_secret): New function.
* mu/imap.c: Fix a typo.
2011-12-14 Sergey Poznyakoff <gray@gnu.org.ua>
Implement UID command in mu imap.
2011-12-14 Sergey Poznyakoff <gray@gnu.org.ua>
Imap client: implement starttls.
* include/mailutils/imap.h (mu_imap_starttls): New proto.
* include/mailutils/imapio.h: Use mu_imapio_t instead of struct
_mu_imapio *.
* include/mailutils/sys/imap.h (MU_IMAP_CLIENT_STARTTLS_RX):
New state.
* libmailutils/imapio/transport.c: New file.
* libmailutils/imapio/Makefile.am (libimapio_la_SOURCES): Add
transport.c
* libproto/imap/starttls.c: New file.
* libproto/imap/Makefile.am (libmu_imap_la_SOURCES): Add
starttls.c.
* libproto/imap/capability.c (mu_imap_capability): Bugfix: set
up comparator and reclaim function after successful return from
mu_list_map.
* libproto/imap/capatst.c (mu_imap_capability_test): Clear
MU_IMAP_RESP bit.
* libproto/imap/err.c (mu_imap_strerror): Return errstr only if
MU_IMAP_RESP is set.
* mu/imap.c: Implement starttls.
2011-12-14 Sergey Poznyakoff <gray@gnu.org.ua>
Imap client: implement LSUB.
LSUB is pretty similar to LIST, therefore it is implemented as
a wrapper over the latter.
* include/mailutils/imap.h
(mu_imap_genlist,mu_imap_genlist_new)
(mu_imap_lsub,mu_imap_lsub_new): New protos.
* include/mailutils/sys/imap.h (MU_IMAP_CLIENT_LSUB_RX): New
state.
* libproto/imap/Makefile.am (libmu_imap_la_SOURCES): Add new
files.
* libproto/imap/genlist.c: New file.
* libproto/imap/list.c: Rewrite using generalized list
functions.
* libproto/imap/lsub.c: New file.
* mu/imap.c: Implement lsub.
2011-12-14 Sergey Poznyakoff <gray@gnu.org.ua>
Imap client: Implement SUBSCRIBE and UNSUBSCRIBE.
* include/mailutils/imap.h (mu_imap_subscribe)
(mu_imap_unsubscribe): New protos.
* include/mailutils/sys/imap.h (MU_IMAP_CLIENT_SUBSCRIBE_RX)
(MU_IMAP_CLIENT_UNSUBSCRIBE_RX): New states.
* libproto/imap/Makefile.am (libmu_imap_la_SOURCES): Add
subscribe.c and unsubscribe.c
* libproto/imap/subscribe.c: New file.
* libproto/imap/unsubscribe.c: New file.
* mu/imap.c: Implement subscribe/unsubscribe.
2011-12-14 Sergey Poznyakoff <gray@gnu.org.ua>
Imap client: quote command arguments as necessary.
* include/mailutils/imapio.h (mu_imapio_send_command)
(mu_imapio_send_command_e,mu_imapio_send_command_v)
(mu_imapio_last_error,mu_imapio_clearerr): New protos.
* include/mailutils/sys/imap.h (imap_command)<uid>: Remove.
<extra>: New member.
* libmailutils/imapio/Makefile.am (libimapio_la_SOURCES): Add
new files.
* libmailutils/imapio/qstring.c
(mu_imapio_send_qstring_unfold): Improve functionality.
* libmailutils/imapio/sendcmd.c: New file.
* libmailutils/imapio/sendcmde.c: New file.
* libmailutils/imapio/sendcmdv.c: New file.
* libmailutils/imapio/errstate.c: New file.
* libproto/imap/gencom.c (mu_imap_gencom): Use
mu_imapio_send_command_v
* libproto/imap/appstrsiz.c: Quote command arguments as
necessary.
* libproto/imap/capability.c: Likewise.
* libproto/imap/check.c: Likewise.
* libproto/imap/close.c: Likewise.
* libproto/imap/copy.c: Likewise.
* libproto/imap/delete.c: Likewise.
* libproto/imap/expunge.c: Likewise.
* libproto/imap/fetch.c: Likewise.
* libproto/imap/list.c: Likewise.
* libproto/imap/login.c: Likewise.
* libproto/imap/mbcreate.c: Likewise.
* libproto/imap/noop.c: Likewise.
* libproto/imap/rename.c: Likewise.
* libproto/imap/select.c: Likewise.
* libproto/imap/store.c: Likewise.
* libproto/imap/unselect.c: Likewise.
2011-12-13 Sergey Poznyakoff <gray@gnu.org.ua>
Imap client: implement list.
* libmailutils/stdstream/basestr.c (mu_strout): Bugfix:
initialize destroy function.
* include/mailutils/imap.h (imap_command)
(mu_imap_gencom): Move to sys/imap.h
(mu_imap_list,mu_imap_list_new): New protos.
* include/mailutils/sys/imap.h (imap_command): New struct (from
../imap.h).
<handler>: Rename to tagged_handler.
(untagged_handler,untagged_handler_data): New members. All uses
changed.
(mu_imap_gencom): New proto.
* libproto/imap/list.c: New file.
* libproto/imap/Makefile.am: Add list.c
* libproto/imap/gencom.c: Use supplied untagged_handler to
analyze untagged response.
* mu/imap.c: Implement list command.
2011-12-13 Sergey Poznyakoff <gray@gnu.org.ua>
Bugfixes.
* libmu_sieve/sieve.y (mu_sieve_compile): Initialize rc.
* python/libmu_py/sieve.c (api_sieve_machine_error_text): Fix
type of length.
2011-12-13 Wojciech Polak <polak@gnu.org>
Improve Python API. Add MemoryStream class.
* python/libmu_py/sieve.c (api_sieve_machine_init): Improve.
(api_sieve_machine_error_text): Add new function.
* python/libmu_py/stream.c (api_memory_stream_create):
Likewise.
(api_stream_to_message): Likewise.
* python/mailutils/error.py (Error): Add optional str_error
argument.
* python/mailutils/sieve.py: Update.
* python/mailutils/stream.py (to_message): Add new method.
(MemoryStream): Add new class.
2011-12-13 Sergey Poznyakoff <gray@gnu.org.ua>
Minor changes.
* libmailutils/datetime/streamftime.c (mu_c_streamftime):
Handle %Z separately.
* libmu_sieve/sieve.y (mu_sieve_compile): Return MU_ERR_PARSE
on errors.
2011-12-12 Sergey Poznyakoff <gray@gnu.org.ua>
Fix possible output buffer overflow in base64 encoder.
* libmailutils/filter/base64.c (_base64_encoder): Continue
after incrementing nbytes.
* mh/mhn.c: Additional error checking.
2011-12-12 Sergey Poznyakoff <gray@gnu.org.ua>
Fix declaration of mu_sieve_vlist_do in libmu_sieve.
2011-12-12 Sergey Poznyakoff <gray@gnu.org.ua>
Initialize standard I/O streams statically.
This allows programmers to use them right away, much like their
stdio counterparts. The mu_stdstream_setup and friends can be
used to re-initialize them, should the need be.
* include/mailutils/sys/file_stream.h
(_MU_FILE_STREAM_STATIC_FILENAME): New flag.
(_mu_file_stream_setup): New proto.
* include/mailutils/sys/logstream.h (_mu_log_stream_setup): New
proto.
* include/mailutils/sys/stream.h (_MU_STR_EVENT_BOOTSTRAP): New
event code.
(_mu_stream) <destroy>: New method.
* libmailutils/stdstream/basestr.c: Define the three standard
streams statically, use bootstrap event to initialize them.
* libmailutils/stdstream/strerr.c (mu_stdstream_strerr_create):
Accept tag==NULL.
* libmailutils/stream/file_stream.c (fd_done): Do not free
filename if _MU_FILE_STREAM_STATIC_FILENAME is set.
(_mu_file_stream_setup): New function.
* libmailutils/stream/logstream.c (NEXT): Check size before
advancing buffer pointer.
(_mu_log_stream_setup): New function.
* libmailutils/stream/stream.c (_bootstrap_event): New macro.
(mu_stream_destroy): If .destroy is defined, use it instead of
free(2). (mu_stream_open,mu_stream_seek,mu_stream_set_buffer)
(mu_stream_read,mu_stream_readdelim,mu_stream_getdelim)
(mu_stream_write,mu_stream_size,mu_stream_wait)
(mu_stream_truncate,mu_stream_shutdown): Call _bootstrap_event
at the beginning.
* libmailutils/tests/.gitignore: Add strin, strout.
* libmailutils/tests/Makefile.am (noinst_PROGRAMS): Add strin,
strout.
(TESTSUITE_AT): Add stdstream tests.
* libmailutils/tests/testsuite.at: Include stdstream tests.
* libmailutils/tests/strerr.at: New test case.
* libmailutils/tests/strin.at: Likewise.
* libmailutils/tests/strout.at: Likewise.
* libmailutils/tests/strin.c: New test program.
* libmailutils/tests/strout.c: Likewise.
2011-12-12 Sergey Poznyakoff <gray@gnu.org.ua>
Bugfix in imap4d.
* imap4d/util.c (util_getfullpath): Use mu_stpcpy.
2011-12-12 Sergey Poznyakoff <gray@gnu.org.ua>
Fix UID generation in mboxes (complements f9a034c7)
* libproto/mbox/mboxscan.c (mbox_scan_internal): Fix UID
generation.
* testsuite/lstuid.c: New test program.
* testsuite/lstuid00.at: New test case.
* testsuite/lstuid01.at: Likewise.
* testsuite/lstuid02.at: Likewise.
* testsuite/Makefile.am: Add new test cases.
* testsuite/testsuite.at: Likewise.
2011-12-11 Sergey Poznyakoff <gray@gnu.org.ua>
Bugfix in libmu_sieve.
* libmu_sieve/sieve.y (mu_sieve_machine_init_ex): Fix typo.
Reference errstream, not mu_strerr.
2011-12-10 Sergey Poznyakoff <gray@gnu.org.ua>
imap4d: remove functions duplicated in the library.
* imap4d/imap4d.h (util_format_attribute_flags)
(util_attribute_to_type): Remove. All uses changed to
mu_imap_format_flags and mu_imap_flag_to_attribute,
respectively.
(util_type_to_attribute): Remove.
2011-12-10 Sergey Poznyakoff <gray@gnu.org.ua>
Redo message set parser in imap4d.
The new parser complies to RFC3501. Its output message sets are
formatted as MU lists of non-overlapping contiguous message
ranges, which reduces memory consumption and imposes less
strain on CPU. The parser automatically translates message UIDs
to sequence numbers and provides better error handling.
* imap4d/imap4d.h (util_msgset): Remove.
(util_parse_msgset): New proto.
(imap4d_message_action_t): New typedef.
(util_foreach_message): New proto.
* imap4d/util.c (util_msgset): Remove.
(util_parse_msgset): New function.
* imap4d/copy.c: Use util_parse_msgset to parse message set
specs and util_foreach_message to iterate over the returned
list.
* imap4d/fetch.c: Likewise.
* imap4d/search.c: Likewise.
* imap4d/store.c: Likewise.
* imap4d/tests/IDEF0955.at: Update the test.
* include/mailutils/list.h (mu_list_action_t): Fix typedef.
* libmailutils/list/foreach.c (mu_list_foreach)
(mu_list_do): Update signatures.
2011-12-09 Sergey Poznyakoff <gray@gnu.org.ua>
Make sure mu_mailbox_get_message returns MU_ERR_NOENT if the
requested message number is not found in the mailbox.
* libmailutils/base/amd.c (amd_get_message): Return
MU_ERR_NOENT if msgno is not found in the mailbox, but not if
it is 0, in which case return EINVAL.
* libproto/mbox/mbox.c (mbox_get_message): Likewise.
* libproto/pop/mbox.c (pop_create_pop3_message): Likewise.
* libproto/mbox/mboxscan.c (mbox_scan_internal): Fix
calculation of UIDs.
2011-12-09 Sergey Poznyakoff <gray@gnu.org.ua>
Bugfix in mu_list_sort.
* libmailutils/list/sort.c (_list_qsort): Fix end-of-list
condition.
2011-12-08 Sergey Poznyakoff <gray@gnu.org.ua>
Use UTC in From_ separators in accordance with RFC 4155.
* examples/mta.c (make_tmp): Use gmtime + mu_c_streamftime to
create From_ line.
* libmailutils/mailbox/msgenv.c (message_envelope_date): Use
gmtime.
* maidag/deliver.c (make_tmp): Likewise.
* maidag/lmtp.c (cfun_data): Likewise.
* readmsg/readmsg.c (print_unix_header): Use gmtime.
2011-12-08 Sergey Poznyakoff <gray@gnu.org.ua>
New function mu_datetime_tz_local.
The function initializes mu_timezone structure to the local
timezone.
* include/mailutils/datetime.h (mu_utc_offset): Change return
type.
(mu_datetime_tz_local): New proto.
* libmailutils/datetime/tzlocal.c: New file.
* libmailutils/datetime/Makefile.am: Add new file.
* libmailutils/datetime/scantime.c (mu_scan_datetime): Use
mu_datetime_tz_local to initialize local TZ.
* mh/mh_format.c (_parse_date): Likewise.
* libmailutils/datetime/utcoff.c (mu_utc_offset): Returns int.
* libmu_sieve/actions.c (mime_create_ds): Use mu_c_streamftime
to format time directly to stream.
2011-12-08 Sergey Poznyakoff <gray@gnu.org.ua>
Rename mu_tm2time to mu_datetime_to_utc.
2011-12-08 Sergey Poznyakoff <gray@gnu.org.ua>
Bugfixes.
* imap4d/append.c: Don't reuse msg variable.
* po/POTFILES.in: Remove unneeded file.
2011-12-08 Sergey Poznyakoff <gray@gnu.org.ua>
Revamp date/time calculations.
* configure.ac: Build libmailutils/datetime/Makefile.am
* include/mailutils/datetime.h (mu_datetime_julianday)
(mu_datetime_dayofweek,mu_datetime_dayofyear)
(mu_datetime_year_days): New protos.
* libmailutils/Makefile.am (SUBDIRS): Add datetime
(libmailutils_la_LIBADD): Add libdatetime.la
* libmailutils/base/Makefile.am (libbase_la_SOURCES): Remove
date.c and strftime.c.
* libmailutils/base/date.c: Remove.
* libmailutils/base/strftime.c: Move to libmailutils/datetime
* libmailutils/datetime/Makefile.am: New file.
* libmailutils/datetime/dow.c: New file.
* libmailutils/datetime/doy.c: New file.
* libmailutils/datetime/jd.c: New file.
* libmailutils/datetime/scantime.c: New file.
* libmailutils/datetime/streamftime.c: New file.
* libmailutils/datetime/tab.c: New file.
* libmailutils/datetime/unixtime.c: New file.
* libmailutils/datetime/utcoff.c: New file.
* libmailutils/datetime/yd.c: New file.
* libmailutils/tests/scantime.at: Fix yday numbers.
2011-12-08 Sergey Poznyakoff <gray@gnu.org.ua>
Move date/time declarations into a separate header:
mailutils/datetime.h.
Additionally, do not typedef mu_timezone, leave it in struct
namespace.
2011-12-08 Sergey Poznyakoff <gray@gnu.org.ua>
imap client: implement CREATE and APPEND. Fix APPEND in imap4d.
* imap4d/append.c (imap4d_append0): Use
mu_message_from_stream_with_envelope with crafted envelope. The
effect is that the envelope of the message always reflects the
actual sender, as deduced from the header (X-Envelope-Sender,
Sender, From, in that order) and the date given with the APPEND
command (or current date/time, if not given).
* imap4d/tests/append00.at: Reflect changes in the envelope.
* imap4d/tests/append01.at: Likewise.
* imap4d/io.c (io_format_completion_response): Call imap4d_sync
to emit eventual non-tagged responses before the tagged one.
* include/mailutils/envelope.h (mu_envelope_set_destroy): New
proto.
* include/mailutils/header.h (MU_HEADER_SENDER): Remove
duplicate define.
* include/mailutils/imap.h (mu_imap_mailbox_create)
(mu_imap_append_stream_size,mu_imap_append_stream)
(mu_imap_append_message,mu_imapio_send_flags)
(mu_imapio_send_time): New protos.
* include/mailutils/imapio.h (mu_imapio_send_literal): Remove
proto. (mu_imapio_send_literal_string)
(mu_imapio_send_literal_stream): New protos.
* include/mailutils/message.h
(mu_message_from_stream_with_envelope): New proto.
* include/mailutils/sys/imap.h (MU_IMAP_CLIENT_APPEND_RX): New
state.
* include/mailutils/sys/message_stream.h (_mu_message_stream)
<envelope>: Rename to envelope_string.
<construct_envelope>: New member.
* libmailutils/imapio/literal.c: Remove.
* libmailutils/imapio/litstream.c: New file.
* libmailutils/imapio/litstring.c: New file.
* libmailutils/imapio/time.c: New file.
* libmailutils/imapio/Makefile.am: Add new files.
* libmailutils/imapio/flags.c (mu_imapio_send_flags): New
function.
* libmailutils/imapio/qstring.c
(mu_imapio_send_qstring_unfold): Use
mu_imapio_send_literal_string.
* libmailutils/mailbox/envelope.c (mu_envelope_set_destroy):
New function.
* libmailutils/stream/message_stream.c
(mu_message_from_stream_with_envelope): New function.
(mu_stream_to_message): Rewrite as an alternative entry point
to the above.
* libproto/imap/Makefile.am: Add new files.
* libproto/imap/appmsg.c: New file.
* libproto/imap/appstr.c: New file.
* libproto/imap/appstrsiz.c: New file.
* libproto/imap/mbcreate.c: New file.
* mu/imap.c: Implement create and append.
2011-12-07 Sergey Poznyakoff <gray@gnu.org.ua>
imap client: implement STORE, DELETE, RENAME, CHECK, EXPUNGE,
COPY, CLOSE and UNSELECT.
* include/mailutils/imap.h (imap_command): New struct.
(mu_imap_gencom): New function. (mu_imap_store,mu_imap_delete)
(mu_imap_rename,mu_imap_mailbox_close,mu_imap_close)
(mu_imap_check): New functions.
(_mu_close_handler): New function.
* include/mailutils/sys/imap.h (mu_imap_client_state): Add new
states.
* libproto/imap/gencom.c: New file.
* libproto/imap/close.c: New file.
* libproto/imap/delete.c: New file.
* libproto/imap/rename.c: New file.
* libproto/imap/store.c: New file.
* libproto/imap/unselect.c: New file.
* libproto/imap/check.c: New file.
* libproto/imap/expunge.c: New file.
* libproto/imap/copy.c: New file.
* libproto/imap/Makefile.am (libmu_imap_la_SOURCES): Add new
files.
* mu/imap.c: Implement new commands.
* mu/shell.c (execute_line): Treat backslash as escape only
before another backslash or double-quote.
2011-12-07 Sergey Poznyakoff <gray@gnu.org.ua>
imap4d: CLOSE should not send EXPUNGE responses. Fix error
checking in STORE.
* imap4d/imap4d.h (silent_expunge): New global.
* imap4d/sync.c (silent_expunge): New variable.
(action): Suppress EXPUNGE responses if silent_expunge is set.
* imap4d/close.c (imap4d_close0): Set silent_expunge before
calling mu_mailbox_flush.
* imap4d/tests/close-expunge.at: New test.
* imap4d/tests/testsuite.at: Include close-expunge.at.
* imap4d/tests/Makefile.am (TESTSUITE_AT): Add
close-expunge.at.
* imap4d/fetch.c (fetch_thunk): Emit BAD response if failed to
parse message set.
* imap4d/store.c (store_thunk): Emit BAD response if failed to
parse flags.
2011-12-06 Sergey Poznyakoff <gray@gnu.org.ua>
Minor change.
2011-12-06 Sergey Poznyakoff <gray@gnu.org.ua>
Improve mu_scan_datetime.
* libmailutils/base/date.c (mu_scan_datetime): Handle optional
blocks (%[ %| %], alternatives %( %| %), "any character"
wildcards (%?) and strict character matches (%\C). Return
MU_ERR_FORMAT on errors in format string. Compute tm->tm_yday.
* libmailutils/diag/errors (MU_ERR_FORMAT): New error code.
* libmailutils/tests/scantime.c: Print yday. Print input line
with diagnostic messages.
* libmailutils/tests/scantime.at: Add more tests.
* include/mailutils/util.h (MU_DATETIME_RFC822): Split into two
formats: MU_DATETIME_FORM_RFC822, for output formatting, and
MU_DATETIME_SCAN_RFC822 for input scanning. All uses changed.
2011-12-06 Sergey Poznyakoff <gray@gnu.org.ua>
Use list LIFO access where appropriate.
* libmu_sieve/runtime.c (_mu_sv_instr_push)
(_mu_sv_instr_pop): Use mu_list_push and mu_list_pop.
* mail/alias.c (recursive_alias_expand): Likewise.
2011-12-06 Sergey Poznyakoff <gray@gnu.org.ua>
Implement LIFO access functions for lists.
* include/mailutils/list.h (mu_list_push)
(mu_list_pop): New functions.
* libmailutils/list/pop.c: New file.
* libmailutils/list/push.c: New file.
* libmailutils/list/Makefile.am (liblist_la_SOURCES): Add new
files.
* libmailutils/tests/list.at: Test LIFO access.
* libmailutils/tests/listop.c: Implement push & pop.
2011-12-05 Sergey Poznyakoff <gray@gnu.org.ua>
Bugfixes.
* imap4d/util.c (util_parse_internal_date): Use
MU_DATETIME_INTERNALDATE format.
* include/mailutils/util.h (MU_DATETIME_IMAP_SEARCH): Rename to
MU_DATETIME_INTERNALDATE (previous incorrect definition
removed).
(MU_DATETIME_RFC822): New format.
* libmailutils/address/address.c: Accessors for local_part and
domain invalidate email field.
(validate_email): New static function.
(mu_address_sget_email): Reconstruct email, if necessary.
(mu_address_format_string): Likewise.
* libmailutils/base/date.c (mu_c_streamftime): Allow for %$
specifier for compatibility with mu_scan_datetime.
(mu_scan_datetime): Use %$ to indicate optional end of string.
* libmailutils/tests/scantime.at: Update.
* libproto/imap/fetch.c (_fill_response): Use
MU_DATETIME_RFC822 format.
* mu/imap.c (fetch_response_printer): Print subject.
2011-12-05 Sergey Poznyakoff <gray@gnu.org.ua>
Implement mu_scan_datetime.
* include/mailutils/stream.h (mu_fixed_memory_stream_create):
New proto.
* libmailutils/stream/memory_stream.c
(mu_fixed_memory_stream_create): New function.
* include/mailutils/util.h (mu_parse_imap_date_time)
(mu_parse_ctime_date_time): Remove.
(mu_scan_datetime): New proto.
(mu_strftime): Remove const from the last arg.
(MU_DATETIME_FROM,MU_DATETIME_IMAP)
(MU_DATETIME_IMAP_SEARCH,MU_DATETIME_INTERNALDATE): New
defines.
* libmailutils/base/strftime.c: New file.
* libmailutils/base/Makefile.am (libbase_la_SOURCES): Add
strftime.c.
* libmailutils/base/date.c (mu_scan_datetime): New function.
* libmailutils/base/mutil.c (mu_strftime): Remove.
* libmailutils/tests/scantime.at: New file.
* libmailutils/tests/scantime.c: New file.
* libmailutils/tests/Makefile.am (noinst_PROGRAMS): Add
scantime.
(TESTSUITE_AT): Add scantime.at.
* libmailutils/tests/strftime.c (main): Call
mu_set_program_name.
* libmailutils/tests/testsuite.at: Include scantime.at
* libmu_sieve/actions.c (mime_create_reason): Use
mu_c_streamftime.
* imap4d/fetch.c (_frt_internaldate): Use mu_scan_datetime.
* imap4d/util.c (util_parse_internal_date): Likewise.
* libmu_scm/mu_message.c (mu-message-get-envelope-date):
Likewise.
* libproto/imap/fetch.c (_date_mapper): Likewise.
* mail/from.c (hdr_date): Use mu_scan_datetime.
2011-12-05 Sergey Poznyakoff <gray@gnu.org.ua>
Implement locale-independent strftime function.
* include/mailutils/util.h (mu_c_streamftime): New prototype.
* libmailutils/base/date.c (mu_c_streamftime): New function.
* libmailutils/tests/.gitignore: Update.
* libmailutils/tests/strftime.at: New test script.
* libmailutils/tests/strftime.c: New test program.
* libmailutils/tests/Makefile.am (noinst_PROGRAMS): Add
strftime.
(TESTSUITE_AT): Add strftime.at.
* libmailutils/tests/testsuite.at: Include strftime.at.
2011-12-02 Sergey Poznyakoff <gray@gnu.org.ua>
Split ibmailutils/mailbox/message.c into logically separated
and easily manageable parts.
2011-12-01 Sergey Poznyakoff <gray@gnu.org.ua>
mail: Use new list functions to simplify vartab-related
operations.
* mail/mailvar.c (_mailvar_symbol_to_array): Remove.
(_mailvar_symbol_to_list): New function.
(mailvar_make_array): Remove.
(mailvar_list_copy): New function.
(mailvar_iterator)<varptr,varcnt,pos>: Remove.
<varlist,varitr>: New members.
(mailvar_iterate_next): Use subordinate iterator.
(mailvar_iterate_first): Likewise.
(mailvar_print): Use mailvar_make_array.
2011-12-01 Sergey Poznyakoff <gray@gnu.org.ua>
MH: minor change in folder.
* mh/folder.c: Use mu_list_t instead of obstack to keep folder
list.
2011-12-01 Sergey Poznyakoff <gray@gnu.org.ua>
Implement list sorting.
* include/mailutils/list.h (mu_list_sort): New proto.
* libmailutils/list/sort.c: New file.
* libmailutils/list/Makefile.am (liblist_la_SOURCES): Add
sort.c
* libmailutils/tests/listop.c: Implement the sort command.
* libmailutils/tests/list.at: Test list sorting.
2011-12-01 Sergey Poznyakoff <gray@gnu.org.ua>
imap client: improve parsing of BODY[] items.
* include/mailutils/imap.h (mu_imap_fetch_body) <key>: Rename
to section.
<fields>: New member.
* libproto/imap/fetch.c: Rewrite response item parser.
* mu/imap.c: Improve fetch_response_printer
2011-11-30 Sergey Poznyakoff <gray@gnu.org.ua>
Implement list folding functions.
* include/mailutils/list.h (mu_list_folder_t): New typedef.
(mu_list_fold, mu_list_rfold): New functions.
* libmailutils/list/fold.c: New file.
* libmailutils/list/rfold.c: New file.
* libmailutils/list/Makefile.am (liblist_la_SOURCES): Add
fold.c and rfold.c
* libmailutils/list/gmap.c (mu_list_gmap): Access list elements
directly, instead of using iterators.
* libmailutils/tests/list.at: Add test cases for list folding.
* libmailutils/tests/listop.c: Add fold and rfold commands.
2011-11-30 Sergey Poznyakoff <gray@gnu.org.ua>
Clean-up state changes in imap client. Fix error handling in
it and in pop3.
* include/mailutils/imap.h (mu_imap_state): Rename to struct
mu_imap_session_state, prefix all values with MU_IMAP_STATE_.
All uses updated.
* include/mailutils/sys/imap.h (mu_imap_client_state): Prefix
all values with MU_IMAP_CLIENT. Rename MU_IMAP_NO_STATE to
MU_IMAP_READY. All uses updated.
(_mu_imap)<state>: Rename to client_state, fix data type.
(imap_state): Rename to imap_state. All uses updated.
(MU_IMAP_CHECK_EAGAIN): Reset state to MU_IMAP_CLIENT_READY if
MU_ERR_REPLY or MU_ERR_BADREPLY is reported.
* include/mailutils/sys/pop3.h (MU_POP3_CHECK_EAGAIN): Reset
state to MU_POP3_NO_STATE, if MU_ERR_REPLY or MU_ERR_BADREPLY
is reported.
* libproto/imap/fetch.c (_date_mapper): Avoid overwriting
resp->type.
* libproto/imap/select.c (_mu_imap_collect_flags): Initialize
*res prior to collecting flags into it.
* mu/imap.c: Install a FETCH callback.
2011-11-30 Sergey Poznyakoff <gray@gnu.org.ua>
imap client: initial implementation of fetch.
* include/mailutils/imap.h (mu_imap_fetch): New proto.
(MU_IMAP_CB_FETCH): New callback code.
(MU_IMAP_FETCH_BODY,MU_IMAP_FETCH_BODYSTRUCTURE)
(MU_IMAP_FETCH_ENVELOPE,MU_IMAP_FETCH_FLAGS)
(MU_IMAP_FETCH_INTERNALDATE,MU_IMAP_FETCH_RFC822_SIZE)
(MU_IMAP_FETCH_UID): New constants.
(mu_imap_fetch_body,mu_imap_fetch_bodystructure)
(mu_imap_fetch_envelope,mu_imap_fetch_flags)
(mu_imap_fetch_internaldate,mu_imap_fetch_rfc822_size)
(mu_imap_fetch_uid,mu_imap_fetch_response): New structures.
* include/mailutils/sys/imap.h (MU_IMAP_SET_XSCRIPT_MASK)
(MU_IMAP_CLR_XSCRIPT_MASK): New macros.
(mu_imap_client_state)<MU_IMAP_FETCH_RX>: New state.
(_mu_imap_list_nth_element_is_string): New proto.
* libproto/imap/fetch.c: New file.
* libproto/imap/Makefile.am (libmu_imap_la_SOURCES): Add
fetch.c
* libproto/imap/carrier.c (mu_imap_set_carrier): Update call to
mu_imapio_create.
* libproto/imap/resplist.c
(_mu_imap_list_nth_element_is_string): New function.
* libproto/imap/resproc.c (_process_unsolicited_response):
Handle FETCH response.
* libproto/imap/trace.c (mu_imap_trace_mask): Call
mu_imapio_trace_payload if needed.
* mu/imap.c (imap_bad_callback): New function.
(com_disconnect): Register imap_bad_callback.
(com_fetch): New function.
(imap_comtab): Add the "fetch" command.
* mu/mu.h (mutool_command) <flags>: New member.
* mu/pop.c (pop_comtab): Update initializers.
* mu/shell.c (default_comtab): Update initializers.
(execute_line): Rewrite using incremental wordsplit. This
allows for optionally coalescing arguments with indices >=
argmax into one argument. This is useful for such commands as
"prompt" and "fetch".
2011-11-30 Sergey Poznyakoff <gray@gnu.org.ua>
Add a function for creating an empty email address object.
* include/mailutils/address.h (mu_address_create_null): New
proto.
* libmailutils/address/address.c (mu_address_create_null): New
function.
2011-11-30 Sergey Poznyakoff <gray@gnu.org.ua>
imapio: fix payload tracing and handling of continuation
responses.
* include/mailutils/imapio.h (mu_imapio_create): Change
signature. All uses updated.
(mu_imapio_trace_payload,mu_imapio_get_trace_payload): New
protos.
* include/mailutils/sys/imapio.h (_mu_imapio) <_imap_server>
<_imap_trace_payload>: New bits.
* libmailutils/imapio/create.c (mu_imapio_create): Take three
arguments, the third one specifying whether the imapio object
is intended for server or client.
* libmailutils/imapio/getline.c (initial_parse): In server
mode, parse everything at once. Handle continuation responses
in client mode.
(mu_imapio_getline): Toggle MU_XSCRIPT_PAYLOAD only if
requested.
* libmailutils/imapio/literal.c: Wait for continuation response
(in client mode).
* libmailutils/imapio/trace.c (mu_imapio_trace_payload)
(mu_imapio_get_trace_payload): New functions.
* libmailutils/tests/imapio.c: New option -server.
* libmailutils/tests/imapio.at: Update literal tests.
2011-11-30 Sergey Poznyakoff <gray@gnu.org.ua>
Bugfix.
* libmailutils/imapio/getline.c (mu_imapio_getline): Fix the
call to realloc.
2011-11-29 Sergey Poznyakoff <gray@gnu.org.ua>
Imap4d: fix handling of nested message/rfc822 parts.
* imap4d/fetch.c (fetch_runtime_closure) <msglist>: New member.
(frt_register_message,frt_unregister_messages): New functions.
(fetch_get_part_rfc822): Look into encapsulated rfc822
messages. (_frt_body_text,_frt_header)
(_frt_header_fields): Use frt_unregister_messages.
(imap4d_fetch0): Initialize all fields in struct
fetch_runtime_closure. Destroy msglist when finished using it.
* imap4d/tests/fetch.at: Add test cases for nested
message/rfc822.
* testsuite/spool/msg.mbox: Add a message with nested
message/rfc822 part.
2011-11-28 Sergey Poznyakoff <gray@gnu.org.ua>
Update ignored file list.
* scheme/.gitignore: Update
2011-11-28 Sergey Poznyakoff <gray@gnu.org.ua>
Fix a bug in imap4d parser, add more tests.
* imap4d/io.c (gettok): Fix memory overwrite.
* imap4d/tests/fetch.at: Add checks for HEADER, HEADER.FIELDS,
HEADER.FIELDS.NOT, and TEXT applied to message/rfc822 parts.
* testsuite/spool/msg.mbox: New file.
* testsuite/spool/DISTFILES: Add msg.mbox.
2011-11-28 Sergey Poznyakoff <gray@gnu.org.ua>
imap4d: reimplement fetch tests in Autotest. Remove
DejaGNU-based testsuite.
* configure.ac: Update.
* imap4d/Makefile.am (SUBDIRS): Remove testsuite.
* imap4d/fetch.c (fetch_thunk): Add a FIXME reference.
* imap4d/tests/fetch.at: New file.
* imap4d/tests/Makefile.am (TESTSUITE_AT): Add fetch.at
* imap4d/tests/testsuite.at: Include fetch.at
* imap4d/tests/atlocal.in (fixup_tz): New filter.
* imap4d/tests/Makefile.am (EXTRA_DIST): Remove unexisting
file.
* imap4d/testsuite: Remove
2011-11-28 Sergey Poznyakoff <gray@gnu.org.ua>
Minor fix.
2011-11-28 Sergey Poznyakoff <gray@gnu.org.ua>
imap4d: reimplement append tests.
* imap4d/tests/Makefile.am (TESTSUITE_AT): Add append00.at and
append01.at
* imap4d/tests/testsuite.at: Include append tests.
* imap4d/tests/append00.at: New file.
* imap4d/tests/append01.at: New file.
2011-11-28 Sergey Poznyakoff <gray@gnu.org.ua>
imap4d: rewrite testsuite in Autotest.
* configure.ac (IMAP_AUTHOBJS): Remove subst variable. Use
conditional instead. Configure imap4d/tests for testing. Build
imap4d/tests/Makefile and imap4d/tests/atlocal.
* imap4d/Makefile.am (SUBDIRS): Add tests.
[MU_COND_GSASL]: Define AUTH_GSASL
[MU_COND_GSSAPI]: Define AUTH_GSSAPI
(imap4d_SOURCES): Include AUTH_GSASL and AUTH_GSSAPI
(imap4d_LDADD,imap4d_DEPENDENCIES): Remove reference to
IMAP_AUTHOBJS.
(EXTRA_DIST): Remove.
* imap4d/tests/.gitignore: New file.
* imap4d/tests/IDEF0955.at: New file
* imap4d/tests/IDEF0956.at: New file
* imap4d/tests/Makefile.am
* imap4d/tests/anystate.at: New file
* imap4d/tests/atlocal.in
* imap4d/tests/create01.at: New file
* imap4d/tests/create02.at: New file
* imap4d/tests/examine.at: New file
* imap4d/tests/expunge.at: New file
* imap4d/tests/id.at: New file
* imap4d/tests/list.at: New file
* imap4d/tests/search.at: New file
* imap4d/tests/select.at: New file
* imap4d/tests/status.at: New file
* imap4d/tests/testsuite.at: New file
* imap4d/fetch.c (fetch_io): Improve range checking. If the
requested number of bytes is greater than maximum, truncate it.
* imap4d/imap4d.c: New option --test.
(test_mode): New global variable.
(imap4d_session_setup0): Fix improperly allocated automatic
variable.
(main): Call GSASL and GSSAPI initializations only if
mu_gsasl_enabled() returns true.
* imap4d/imap4d.h (test_mode): New extern.
* imap4d/preauth.c: Do not complain about failed getpeername in
test mode.
* imap4d/select.c: Fix human-readable response texts.
* include/mailutils/gsasl.h (mu_gsasl_module_data)<enable>: New
member.
(mu_gsasl_enabled): New proto.
* libmailutils/mailbox/mailbox.c (mu_mailbox_flush):
(mu_mailbox_append_message,mu_mailbox_sync)
(mu_mailbox_expunge): Use MU_STREAM_WRITE instead of
MU_STREAM_RDWR.
* libmu_auth/gsasl.c (mu_gsasl_module_data): Fix
initialization.
(mu_gsasl_enabled): New function.
* libmu_cfg/gsasl.c (mu_gsasl_param): New parameter "enable".
2011-11-27 Sergey Poznyakoff <gray@gnu.org.ua>
imap4d: fix FETCH (BODYSTRUCTURE)
* imap4d/fetch.c (bodystructure): Do not emit CHARSET pair if
there is none in the Content-Type header.
(fetch_get_part_rfc822): Use mu_message_unencapsulate
* libmailutils/mime/attachment.c (mu_message_unencapsulate):
Use mu_stream_to_message to create destination message. This
ensures that the latter can be handled by other MU functions
(e.g. mu_header_* family).
2011-11-27 Sergey Poznyakoff <gray@gnu.org.ua>
imap4d: Fix the functionality of FETCH BODY sections HEADER,
TEXT and MIME.
According to RFC 3501 HEADER, HEADER.FIELDS, and
HEADER.FIELDS.NOT part specifiers refer to the RFC-2822 header
of the message or of an encapsulated MESSAGE/RFC822 message.
They return NILs if applied to a MIME part other than
MESSAGE/RFC822.
* imap4d/fetch.c (fetch_get_part_rfc822): New function.
(_frt_body): Used only for BODY[]. Consequently, do not try to
resolve message part, use the message itself instead.
(_frt_body_n): New function.
(_frt_mime): New function.
(_frt_body_text,_frt_header,_frt_header_fields): Use
fetch_get_part_rfc822. Unref the retrieved message when
through.
(parse_section_text): Use _frt_mime for BODY[<n>.MIME]
(parse_section): Use _frt_body_n for BODY[<n>].
* imap4d/testsuite/imap4d/fetch.exp: Remove incorrect tests.
2011-11-26 Sergey Poznyakoff <gray@gnu.org.ua>
Change callback signature in imap client.
The purpose is to avoid using variadic calls in order to let
the compiler do the necessary argument checking.
* include/mailutils/imap.h (mu_imap_callback_t): Take a pair of
size_t and void * arguments instead of the single va_list.
(mu_imap_callback): Likewise.
* libproto/imap/callback.c: Likewise.
* libproto/imap/resproc.c: Update callback calls.
* mu/imap.c: Update callback declarations.
2011-11-25 Sergey Poznyakoff <gray@gnu.org.ua>
Add a test for non-synchronized imap literals.
2011-11-25 Sergey Poznyakoff <gray@gnu.org.ua>
Improve IMAP I/O module. Add testcase.
* libmailutils/imapio/getline.c (initial_parse): New function.
(mu_imapio_getline): Use initial_parse.
* libmailutils/tests/imapio.c (main): Do not set progname.
* libmailutils/tests/imapio.at: New file.
* libmailutils/tests/Makefile.am: Add imapio.at.
* libmailutils/tests/testsuite.at: Include imapio.at
2011-11-25 Sergey Poznyakoff <gray@gnu.org.ua>
Minor change.
* mu/shell.c: Output newline when EOF is received.
2011-11-25 Sergey Poznyakoff <gray@gnu.org.ua>
imap client: implement noop.
* include/mailutils/imap.h (mu_imap_noop): New proto.
* include/mailutils/sys/imap.h (mu_imap_client_state)
<MU_IMAP_NOOP_RX>: New state.
* libproto/imap/noop.c: New file.
* libproto/imap/Makefile.am (libmu_imap_la_SOURCES): Add noop.c
* mu/imap.c (report_failure): New function.
(com_login,select_mbox,com_status): Use report_failure for
error reporting.
(com_noop): New function.
(imap_comtab)<noop>: New command.
2011-11-25 Sergey Poznyakoff <gray@gnu.org.ua>
Minor change.
* mu/imap.c: Add missing gettext markers.
2011-11-25 Sergey Poznyakoff <gray@gnu.org.ua>
Process untagged responses synchronously.
* include/mailutils/imap.h (mu_imap_response_action_t): Move to
sys/imap.h
(mu_imap_foreach_response): Remove.
* include/mailutils/sys/imap.h (_mu_imap)<untagged_resp>:
Remove. All sources updated.
(_mu_imap_response): Change signature.
(_mu_imap_untagged_response_clear)
(_mu_imap_untagged_response_add): Remove.
(_mu_imap_untagged_response_to_list)
(_mu_imap_process_untagged_response): New protos.
* libproto/imap/connect.c: Use
_mu_imap_untagged_response_to_list and
_mu_imap_process_untagged_response.
* libproto/imap/create.c: Update.
* libproto/imap/destroy.c: Update.
* libproto/imap/disconnect.c: Update.
* libproto/imap/capability.c: Update calls to _mu_imap_response
* libproto/imap/id.c: Likewise.
* libproto/imap/login.c: Likewise.
* libproto/imap/logout.c: Likewise.
* libproto/imap/select.c: Likewise.
* libproto/imap/status.c: Likewise.
* libproto/imap/resplist.c (_mu_imap_untagged_response_clear):
Remove.
(_mu_imap_untagged_response_add): Remove.
(_mu_imap_untagged_response_to_list): New function.
* libproto/imap/response.c (_mu_imap_response): Take
response-processing function and its closure as arguments.
* libproto/imap/resproc.c (_mu_imap_process_untagged_response):
New function.
(mu_imap_foreach_response): Remove.
* mu/imap.c: Install a BYE callback.
2011-11-24 Sergey Poznyakoff <gray@gnu.org.ua>
Change callback handling in imap client.
* include/mailutils/imap.h (MU_IMAP_CB_NO)
(MU_IMAP_CB_BAD,MU_IMAP_CB_BYE)
(MU_IMAP_CB_PREAUTH): New callbacks.
(mu_imap_callback_t): Change signature.
(mu_imap_callback): Change signature.
* include/mailutils/sys/imap.h (mu_imap_client_state)
<MU_IMAP_CLOSING>: New state.
* libproto/imap/callback.c (mu_imap_callback): Change
signature. Fix boundary check.
(mu_imap_register_callback_function): Fix boundary check.
* libproto/imap/connect.c (mu_imap_connect): Use
mu_imap_foreach_response to parse response.
* libproto/imap/response.c (_mu_imap_response): Check number of
words before dereferencing them.
* libproto/imap/resproc.c: Handle all server responses.
* mu/imap.c (com_connect): Set POPAUTH callback. Set verbosity
flags after I/O structure has been created.
2011-11-24 Sergey Poznyakoff <gray@gnu.org.ua>
list: new operations: head and tail.
* include/mailutils/list.h (mu_list_head, mu_list_tail): New
prototypes.
* libmailutils/list/head.c: New file.
* libmailutils/list/tail.c: New file.
* libmailutils/list/Makefile.am (liblist_la_SOURCES): Add new
files.
* libmailutils/tests/listop.c (head,tail): New commands.
* libmailutils/tests/list.at: Test head and tail.
2011-11-24 Sergey Poznyakoff <gray@gnu.org.ua>
imap client: reflect changes to imapio parser.
* include/mailutils/sys/imap.h (_mu_imap_seterrstrz): New
proto.
* libmailutils/imapio/replstr.c: Update.
* libproto/imap/err.c (_mu_imap_seterrstrz): New function.
* libproto/imap/id.c: Remove superfluous calls to
_mu_imap_seterrstr.
* libproto/imap/login.c: Likewise.
* libproto/imap/select.c: Likewise.
* libproto/imap/status.c: Likewise.
* libproto/imap/response.c: Set human-readable text as errstr.
* libproto/imap/resproc.c (ok_response): Reflect changes to
mu_imapio_getline.
2011-11-24 Sergey Poznyakoff <gray@gnu.org.ua>
imapio: improve getline parser.
* libmailutils/imapio/create.c (mu_imapio_create): Treat [ and
] as delimiters. Use MU_WRDSF_DQUOTE flag instead of
MU_WRDSF_QUOTE. Use MU_WRDSF_APPEND
* libmailutils/imapio/getline.c (mu_imapio_getline): Use
incremental wordsplit mode. Return human-readable part of
status responses as a single token.
2011-11-24 Sergey Poznyakoff <gray@gnu.org.ua>
wordsplit: minor fix in return_delims mode.
* libmailutils/string/wordsplit.c (scan_word): Return only one
delimiter if MU_WRDSF_RETURN_DELIMS is on
* libmailutils/tests/wordsplit.at: Reflect that.
2011-11-24 Sergey Poznyakoff <gray@gnu.org.ua>
wordsplit: add incremental mode.
* include/mailutils/wordsplit.h (MU_WRDSF_INCREMENTAL): New
flag.
(MU_WRDSE_NOINPUT): New error code.
* libmailutils/string/wordsplit.c (mu_wordsplit_init0): New
function.
(mu_wordsplit_init): Call mu_wordsplit_init0.
(expvar): Use MU_WRDSF_WS instead of MU_WRDSF_SQUEEZE_DELIMS in
call to subordinate mu_wordsplit.
(skip_delim): If both MU_WRDSF_RETURN_DELIMS and
MU_WRDSF_SQUEEZE_DELIMS are given, squeeze only the same
delimiter characters.
* libmailutils/tests/wordsplit.at: Add tests for incremental
mode.
* libmailutils/tests/wsp.c: Support incremental mode.
2011-11-24 Sergey Poznyakoff <gray@gnu.org.ua>
tls: do not generate DH params.
* libmu_auth/tls.c: Don't generate DH params at all.
2011-11-23 Sergey Poznyakoff <gray@gnu.org.ua>
Enable GSASL by default.
* am/gsasl.m4 (MU_CHECK_GSASL): Enable GSASL by default. Other
minor fixes.
* am/tls.m4 (MU_CHECK_TLS): Rename to MU_CHECK_GNUTLS. Check
option arguments. Check for gnutls library version.
* configure.ac: Update.
* README: Document the change.
* NEWS: Document the change.
2011-11-22 Sergey Poznyakoff <gray@gnu.org.ua>
Bugfixes.
* libmu_dbm/dbm.c (mu_dbm_create_from_url): Parameter list
beginning with a negative parameter implies default safety
criteria. Fix semantics of the "default" keyword: it is
different from "all".
* libmu_dbm/mudbm.h (DEFAULT_DBM_SAFETY_FLAGS): Remove. Not
needed now.
* pop3d/bulletin.c (read_bulletin_db): Remove a leftover call
to mu_dbm_safety_set_flags.
2011-11-22 Sergey Poznyakoff <gray@gnu.org.ua>
Implement new DBM dump format.
The new format, called "C", allows programmers to create input
data for use by mu load using conventional means. It represents
both key and content as C strings (hence its name), with usual
C (literal and octal) escapes to represent non-printable
characters.
* mu/dbm.c (IOBUF_REREAD,IOBUF_EOF): New constants.
(iobuf) <state>: New member.
(input_eof): New macro.
(input_getline): Use iobuf.state to detect EOF.
(input_ungetline): Reset state only if it is 0.
(format_tab): New format "C".
(write_quoted_string,C_writer,C_read_datum)
(C_reader): New functions to implement the C dump format.
* libmailutils/tests/testsuite.at: Minor change.
2011-11-21 Sergey Poznyakoff <gray@gnu.org.ua>
Version 2.99.95.
2011-11-21 Sergey Poznyakoff <gray@gnu.org.ua>
libmu_dbm: Functions for DB creation take default safety flags
in their last argument.
* configure.ac (check_dbm_impl): Fix improper usage of expr in
BDB=* case.
* include/mailutils/dbm.h (mu_dbm_create_from_url)
(mu_dbm_create): Take default safety flags as the last
argument.
* libmailutils/base/filesafety.c (_check_linkwrdir): Check for
both hard and symbolic links. Fix the latter check.
* libmailutils/tests/fsaf.at: Add check for softlink in a
writable dir.
* libmu_dbm/create.c (mu_dbm_create): Take default file safety
as the last argument.
* libmu_dbm/dbm.c (mu_dbm_create_from_url): Likewise.
* maidag/mailquota.c (dbm_retrieve_quota): Update call to
mu_dbm_create. Impose MU_FILE_SAFETY_ALL by default.
* mu/dbm.c (open_db_file): Update call to mu_dbm_create. No
checks by default.
* pop3d/apop.c (pop3d_apopuser): Update call to mu_dbm_create.
Use apop_database_safety as the default checks.
* pop3d/bulletin.c (read_bulletin_db,write_bulletin_db): Update
calls to mu_dbm_create. Use DEFAULT_GROUP_DB_SAFETY as default.
* pop3d/logindelay.c (open_stat_db): Update call to
mu_dbm_create. Use DEFAULT_GROUP_DB_SAFETY as default.
* pop3d/pop3d.c (apop_database_safety): Initialize to
MU_FILE_SAFETY_ALL.
(apop_database_safety_set): Remove.
* pop3d/pop3d.h (apop_database_safety_set): Remove.
* pop3d/popauth.c (open_db_file): Update call to mu_dbm_create.
Use safety_flags by default.
2011-11-20 Sergey Poznyakoff <gray@gnu.org.ua>
wordsplit: implement separate single- and double-quote parsing.
* include/mailutils/wordsplit.h
(MU_WRDSF_SQUOTE,MU_WRDSF_DQUOTE): New flags.
(MU_WRDSF_QUOTE): Redefine as an OR of the above two.
* libmailutils/string/wordsplit.c (scan_word): Treat '\'' and
'"' separately, depending on the flags.
* libmailutils/tests/wsp.c: Add squote and dquote options.
* libmailutils/tests/wordsplit.at: Test separate quoting
support.
2011-11-19 Sergey Poznyakoff <gray@gnu.org.ua>
Implement list slicing functions.
* include/mailutils/list.h (mu_list_slice_dup,mu_list_slice)
(mu_list_slice2_dup,mu_list_slice2): New protos.
* libmailutils/list/slice.c: New file.
* libmailutils/list/slice2.c: New file.
* libmailutils/list/Makefile.am: Add slice.c and slice2.c
* libmailutils/tests/list.at: Add slicing tests.
* libmailutils/tests/listop.c: New command: "slice"
2011-11-19 Sergey Poznyakoff <gray@gnu.org.ua>
Imap client: fix status implementation.
2011-11-19 Sergey Poznyakoff <gray@gnu.org.ua>
Implement general-purpose processing of unsolicited responses
in imap client.
* include/mailutils/imap.h (mu_imap_response_action_t): New
typedef.
(mu_imap_foreach_response): New proto.
(MU_IMAP_CB_PERMANENT_FLAGS,MU_IMAP_CB_MESSAGE_COUNT)
(MU_IMAP_CB_RECENT_COUNT,MU_IMAP_CB_FIRST_UNSEEN)
(MU_IMAP_CB_UIDNEXT,MU_IMAP_CB_UIDVALIDITY)
(MU_IMAP_CB_OK,_MU_IMAP_CB_MAX): New constants.
(mu_imap_callback_t): New typedef.
(mu_imap_callback,mu_imap_register_callback_function): New
protos. (MU_IMAP_RESPONSE_ALERT,MU_IMAP_RESPONSE_BADCHARSET)
(MU_IMAP_RESPONSE_CAPABILITY,MU_IMAP_RESPONSE_PARSE)
(MU_IMAP_RESPONSE_PERMANENTFLAGS,MU_IMAP_RESPONSE_READ_ONLY)
(MU_IMAP_RESPONSE_READ_WRITE,MU_IMAP_RESPONSE_TRYCREATE)
(MU_IMAP_RESPONSE_UIDNEXT,MU_IMAP_RESPONSE_UIDVALIDITY)
(MU_IMAP_RESPONSE_UNSEEN): New constants.
(mu_imap_response_codes): New extern.
* include/mailutils/sys/imap.h (_mu_imap) <callback>: New
member.
(_mu_imap_collect_flags, _mu_imap_list_at): New protos.
* libproto/imap/resplist.c (_mu_imap_list_at): New function.
* libproto/imap/callback.c: New file.
* libproto/imap/resproc.c: New file.
* libproto/imap/Makefile.am: Add new files.
* libproto/imap/capability.c: Rewrite using
mu_imap_foreach_response.
* libproto/imap/id.c: Likewise.
* libproto/imap/select.c: Likewise.
2011-11-19 Sergey Poznyakoff <gray@gnu.org.ua>
Rename mu_list_do to mu_list_foreach. Add comments to
mailutils/list.h.
2011-11-19 Sergey Poznyakoff <gray@gnu.org.ua>
imap client: implement status command.
* include/mailutils/imap.h (mu_imap_status): New proto.
(_mu_imap_status_name_table): New declaration.
* include/mailutils/sys/imap.h (mu_imap_client_state)
<MU_IMAP_STATUS_RX>: New state.
* libproto/imap/status.c: New file.
* libproto/imap/Makefile.am (libmu_imap_la_SOURCES): Add
status.c
* mu/imap.c: Implement "status"
2011-11-18 Sergey Poznyakoff <gray@gnu.org.ua>
imap client: implement select/examine.
* include/mailutils/imap.h (mu_imap_stat): New structs.
(MU_IMAP_STAT_DEFINED_FLAGS,MU_IMAP_STAT_PERMANENT_FLAGS)
(MU_IMAP_STAT_MESSAGE_COUNT,MU_IMAP_STAT_RECENT_COUNT)
(MU_IMAP_STAT_FIRST_UNSEEN,MU_IMAP_STAT_UIDNEXT)
(MU_IMAP_STAT_UIDVALIDITY): New flags.
(mu_imap_select): New proto.
* include/mailutils/imapio.h (mu_imap_flag_to_attribute)
(mu_imap_format_flags): New protos.
* include/mailutils/sys/imap.h (mu_imap_client_state)
<MU_IMAP_SELECT_RX>: New state.
(_mu_imap) <mbox_name,mbox_writable,mbox_stat>: New members.
* libmailutils/imapio/flags.c: New file.
* libmailutils/imapio/Makefile.am: Add flags.c
* libproto/imap/select.c: New file.
* libproto/imap/Makefile.am: Add select.c
* libproto/imap/err.c (_mu_imap_seterrstr)
(_mu_imap_clrerrstr, mu_imap_strerror): Allow for imap==NULL.
* libproto/imap/id.c (mu_imap_id): Set errstr on
MU_ERR_BADREPLY
* libproto/imap/login.c (mu_imap_login): Likewise.
* libproto/imap/resplist.c (_mu_imap_list_element_is_string):
New function.
* mu/imap.c: Implement examine and select.
2011-11-18 Sergey Poznyakoff <gray@gnu.org.ua>
imap client: redo capability and id support via list mappers.
* libproto/imap/capability.c (mu_imap_capability): Use
mu_list_map to create the capability list.
* libproto/imap/id.c (_id_convert): Likewise for ID pairs.
2011-11-18 Sergey Poznyakoff <gray@gnu.org.ua>
Implement list mapping.
* include/mailutils/list.h (MU_LIST_MAP_OK)
(MU_LIST_MAP_SKIP,MU_LIST_MAP_STOP): New constants.
(mu_list_mapper_t): New typedef.
(mu_list_map): New proto.
* libmailutils/list/gmap.c: New file.
* libmailutils/list/map.c: New file.
* libmailutils/list/Makefile.am: Add gmap.c and map.c
* libmailutils/tests/listop.c: New command "map".
* libmailutils/tests/list.at: Test the list mapping.
2011-11-18 Sergey Poznyakoff <gray@gnu.org.ua>
Move list support into a separate convenience library.
* configure.ac: Build libmailutils/list/Makefile
* include/mailutils/sys/list.h (DESTROY_ITEM): New define.
(_mu_list_insert_item): New proto.
* libmailutils/Makefile.am (SUBDIRS): Add list.
(libmailutils_la_LIBADD): Add list/liblist.la
* libmailutils/base/Makefile.am (libbase_la_SOURCES): Remove
list sources.
* libmailutils/base/list.c: Split into smaller files (see
below).
* libmailutils/base/listlist.c: Move to
libmailutils/list/listlist.c
* libmailutils/list/Makefile.am: New file.
* libmailutils/list/append.c: New file.
* libmailutils/list/array.c: New file.
* libmailutils/list/clear.c: New file.
* libmailutils/list/count.c: New file.
* libmailutils/list/create.c: New file.
* libmailutils/list/destroy.c: New file.
* libmailutils/list/do.c: New file.
* libmailutils/list/empty.c: New file.
* libmailutils/list/get.c: New file.
* libmailutils/list/getcomp.c: New file.
* libmailutils/list/insert.c: New file.
* libmailutils/list/intersect.c: New file.
* libmailutils/list/iterator.c: New file.
* libmailutils/list/locate.c: New file.
* libmailutils/list/prepend.c: New file.
* libmailutils/list/remove.c: New file.
* libmailutils/list/replace.c: New file.
* libmailutils/list/setcomp.c: New file.
* libmailutils/list/setdestr.c: New file.
2011-11-18 Sergey Poznyakoff <gray@gnu.org.ua>
Rewrite existing imap client support using imapio.
2011-11-18 Sergey Poznyakoff <gray@gnu.org.ua>
Implement mu_imapio_reply_string function.
* include/mailutils/imapio.h (mu_imapio_reply_string): New
proto.
* libmailutils/imapio/replstr.c: New file.
* libmailutils/imapio/Makefile.am: Add replstr.c
2011-11-17 Sergey Poznyakoff <gray@gnu.org.ua>
Implement IMAP I/O functions for client and server.
* include/mailutils/imapio.h: New file.
* include/mailutils/sys/imapio.h: New file.
* libmailutils/imapio/create.c: New file.
* libmailutils/imapio/getline.c: New file.
* libmailutils/imapio/literal.c: New file.
* libmailutils/imapio/printf.c: New file.
* libmailutils/imapio/qstring.c: New file.
* libmailutils/imapio/send.c: New file.
* libmailutils/imapio/trace.c: New file.
* libmailutils/imapio/words.c: New file.
* libmailutils/imapio/xscript.c: New file.
* configure.ac: Build libmailutils/imapio/Makefile
* include/mailutils/Makefile.am (pkginclude_HEADERS): Add
imapio.h.
* include/mailutils/imapio.h: New file.
* include/mailutils/sys/Makefile.am (sysinclude_HEADERS): Add
imapio.h.
* include/mailutils/sys/imapio.h: New file.
* include/mailutils/types.hin (mu_imapio_t): New data type.
* libmailutils/Makefile.am (SUBDIRS): Add imapio.
* libmailutils/tests/Makefile.am: Build imapio
* libmailutils/tests/imapio.c: New source.
* libmailutils/tests/wsp.c: Handle escape argument
2011-11-17 Sergey Poznyakoff <gray@gnu.org.ua>
Improve wordsplit.
* include/mailutils/wordsplit.h (mu_wordsplit) <ws_escape>: New
member.
(MU_WRDSF_ESCAPE): New flag.
(mu_wordsplit_general_unquote_copy): New function.
* libmailutils/string/wordsplit.c: Remove empty nodes after
whitespace trimming. If MU_WRDSF_ESCAPE is set, remove only
backslashes appearing in front of a character in ws_escape.
* libmailutils/tests/wordsplit.at: Test new features.
2011-11-16 Sergey Poznyakoff <gray@gnu.org.ua>
Import error codes directly from libmailutils to Python.
* python/libmu_py/Makefile.am (libmu_py_la_SOURCES): Add
errno.c
* python/libmu_py/errno.c: New file.
* python/libmu_py/libmu_py.c (_mu_py_module_name): New
function.
(_mu_py_attach_module): Use _mu_py_module_name to allocate FQ
module name instead of taking the risk of using fixed size
buffer. Don't call Py_InitModule if methods is NULL.
(mu_py_attach_modules): Call _mu_py_attach_errno.
* python/libmu_py/libmu_py.h (_mu_py_attach_errno): New proto.
* python/mailutils/error.py: Re-export everything from
c_api.errno. Remove hardcoded definitions of error codes.
2011-11-15 Sergey Poznyakoff <gray@gnu.org.ua>
Minor changes.
* libmu_cfg/tls.c (SSL_KEY_FILE_CHECKS): Mask out
MU_FILE_SAFETY_OWNER_MISMATCH bit.
* mu/shell.c: Handle SIGPIPE and SIGINTR.
2011-11-12 Sergey Poznyakoff <gray@gnu.org.ua>
Minor change.
* mu/dbm.c (add_records): Set DBM meta-data after populating it
with data.
2011-11-10 Sergey Poznyakoff <gray@gnu.org.ua>
Minor fix.
* libmu_dbm/dbm.c (mu_dbm_create_from_url): Fix owner=
parameter.
2011-11-10 Wojciech Polak <polak@gnu.org>
Update Python interface.
* python/libmu_py/filter.c: Bugfix.
* python/libmu_py/url.c (api_url_parse): Remove.
* python/mailutils/error.py: Update MU_ERR_* values.
* python/mailutils/url.py (Url): Remove parse() method.
* examples/python/iconv.py: Remove open/close method calls.
* examples/python/mailcap.py: Likewise.
* examples/python/url-parse.py: Remove parse() call.
2011-11-09 Sergey Poznyakoff <gray@gnu.org.ua>
Implement _dbm_get_fd in Kyoto cabinet.
* libmu_dbm/kyoto.c: Implement _dbm_get_fd.
2011-11-09 Sergey Poznyakoff <gray@gnu.org.ua>
Minor change.
* libmailutils/base/version.c (mu_conf_option): Reflect BDB
support.
2011-11-09 Wojciech Polak <polak@gnu.org>
Add Kyoto Cabinet DBM support.
* libmu_dbm/kyoto.c: New file.
* libmu_dbm/dbm.c: Update.
* libmu_dbm/mudbm.h: Update.
* libmu_dbm/Makefile.am: (libmu_dbm_la_SOURCES): Add kyoto.c
* configure.ac: Add --with-kyotocabinet.
* README: Update.
* doc/texinfo/programs.texi: Likewise.
* libmailutils/base/version.c: Likewise.
2011-11-09 Sergey Poznyakoff <gray@gnu.org.ua>
spamd sieve test: bugfix.
* libmu_sieve/extensions/spamd.c (get_real_message_size): New
function.
(spamd_test): Use get_real_message_size instead of
mu_message_size.
2011-11-08 Wojciech Polak <polak@gnu.org>
Fix typos.
2011-11-08 Wojciech Polak <polak@gnu.org>
Re-add Tokyo Cabinet DBM support.
* libmu_dbm/tokyo.c: New file.
* libmu_dbm/Makefile.am (libmu_dbm_la_SOURCES): Add tokyo.c.
* doc/texinfo/programs.texi: Update.
* README: Update.
2011-11-08 Sergey Poznyakoff <gray@gnu.org.ua>
Minor changes in diagnostic messages.
* maidag/maidag.c (cb_delivery_mode): Fix typo.
* mail/mail.c (mail_warranty): Update copyright years.
2011-11-08 Sergey Poznyakoff <gray@gnu.org.ua>
Bugfix.
* mu/dbm.c (add_records): Reference mu_strin before using it
for input.
2011-11-06 Sergey Poznyakoff <gray@gnu.org.ua>
Version 2.99.94.
2011-11-06 Sergey Poznyakoff <gray@gnu.org.ua>
Minor fix.
* pop3d/pop3d.c (pop3d_mainloop): start in AUTHORIZATION if tls
is established.
2011-11-06 Sergey Poznyakoff <gray@gnu.org.ua>
Update docs + minor changes.
* .gitmodules: Add imprimatur.
* Makefile.am: Likewise.
* configure.ac: Likewise.
* doc/Makefile.am: Likewise.
* bootstrap.conf: Comment out make in doc/texinfo
* doc/texinfo/Makefile.am: Rewrite.
* doc/texinfo/fdl.texi: Minor change.
* doc/texinfo/getdate.texi: Minor change.
* doc/texinfo/mailutils.texi: begin rewrite.
* doc/texinfo/mu-mh.texi: Minor change.
* doc/texinfo/programs.texi: begin rewrite.
* doc/texinfo/sieve.texi: Minor change.
* doc/texinfo/usage.texi: Minor change.
* libmailutils/cfg/lexer.l: Allow for @ in unquoted strings
* pop3d/bulletin.c: Relax safety checks for bulletin.db
* pop3d/logindelay.c: Relax safety checks for stat.sb
* pop3d/pop3d.h (DEFAULT_GROUP_DB_SAFETY): New define.
2011-11-05 Sergey Poznyakoff <gray@gnu.org.ua>
Write NEWS article describing the recent changes.
2011-11-04 Sergey Poznyakoff <gray@gnu.org.ua>
Fix MU_EVT_MESSAGE_ADD in pop://
* libproto/pop/mbox.c (pop_scan): Make sure MU_EVT_MESSAGE_ADD
is delivered when it is already possible to retrieve the
message.
* mail/mail.c (default_setup) <headline>: Use %L instead of %l.
* mu/logger.c (logger_options)<priority>: Minor fix.
2011-11-04 Sergey Poznyakoff <gray@gnu.org.ua>
Implement pop3s and imap4s in respective servers.
* comsat/comsat.c (comsat_prefork,comsat_connection): Change
signatures.
* imap4d/imap4d.c: Implement imaps.
* imap4d/imap4d.h (io_setio): Change signature.
(tls_encryption_on): New proto.
* imap4d/io.c (io_setio): Change signature. Initialize TLS
stream if requested.
* imap4d/starttls.c (tls_encryption_on): New function.
* include/mailutils/server.h (mu_srv_config): New struct.
(mu_m_server_conn_fp, mu_m_server_prefork_fp): Remove typedefs.
(mu_m_server_handler_fp): New typedef.
(mu_m_server_set_conn): Change signature.
(mu_m_server_set_prefork): Change signature.
(mu_m_server_set_app_data_size)
(mu_m_server_set_config_size): New prototype.
(mu_m_server_cfg_init): Change signature.
* include/mailutils/tls.h (mu_init_tls_libs): Change signature.
* lib/tcpwrap.c: Include tcpwrap.h
(mu_tcp_wrapper_daemon): Fix declaration.
(mu_tcp_wrapper_prefork): Change signature.
* lib/tcpwrap.h (mu_tcp_wrapper_prefork): Change signature
* libmailutils/server/msrv.c (_mu_m_server) <conn,prefork>:
Change data type. All uses updated.
<app_data_size>: New member.
(m_srv_config): Remove struct. Replaced with mu_srv_config from
tls.h
(mu_m_server_set_conn): Change signature.
(mu_m_server_set_prefork): Change signature.
(mu_m_server_set_app_data_size)
(mu_m_server_set_config_size): New functions.
(add_server): Allocate app_data_size additional bytes of data.
(mu_m_server_cfg_init): Take one argument.
* libmu_auth/tls.c (mu_tls_module_init): Update call to
mu_init_tls_libs. Don't call mu_file_safety_check with NULL
argument.
(mu_init_tls_libs): Rewrite. Prepare x509 here, instead of
doing it each time a TLS stream is created.
(mu_deinit_tls_libs): Free x509, if exists.
(_tls_server_open): Update call to mu_init_tls_libs. Remove
x509 initialization.
* libmu_cfg/tls.c (cb2_safety_checks): Fix typos.
* maidag/lmtp.c (lmtp_connection): Change signature.
* maidag/maidag.c (main): Update call to mu_m_server_cfg_init.
* maidag/maidag.h (lmtp_connection): Change signature.
* pop3d/extra.c (pop3d_setio): Initialize TLS stream, if
requested.
* pop3d/pop3d.c: Implement pops.
* pop3d/pop3d.h (pop3d_setio): Change prototype.
2011-11-04 Sergey Poznyakoff <gray@gnu.org.ua>
Implement error_string method in TLS streams.
* include/mailutils/sys/tls-stream.h (_mu_tls_stream_s):
Remove.
* libmailutils/diag/errors (MU_ERR_BAD_RESUMPTION): Remove. Use
EAGAIN instead.
(MU_ERR_DISABLED): New error code.
* libmu_auth/tls.c (_tls_server_open): Return MU_ERR_DISABLED
when needed.
(_mu_tls_stream_create): Implement error_string method.
* libproto/maildir/mbox.c (maildir_msg_init): Fix return value.
2011-11-04 Sergey Poznyakoff <gray@gnu.org.ua>
Fix TLS usage.
Remove --tls option. Make TLS stream open methods call
mu_init_tls_libs. It is now not necessary to call this function
explicitly, unless the application wishes to ensure TLS is
initialized (e.g. pop3d or imap4d).
* include/mailutils/libargp.h (mu_tls_cmdline): Remove.
* libmu_argp/tls.c
* libmu_argp/Makefile.am (libmu_argp_a_SOURCES): Remove tls.c
* libmu_argp/cmdline.c (all_cmdline_capa): Remove tls.c
* libmu_auth/tls.c [WITH_TLS] (mu_tls_module_config): Enable by
default.
(mu_check_tls_environment): Return 0 if TLS is disabled.
(mu_init_tls_libs): Always call gnutls_global_init, otherwise
any call to TLS library (especially, handshake) can produce a
coredump.
* libmu_cfg/tls.c: Fix description string for tls.enable.
* mh/mh_init.c (mh_init): Remove call to mu_init_tls_libs, now
unnecessary.
* python/libmu_py/registrar.c: Likewise.
* testsuite/smtpsend.c: Likewise.
2011-11-01 Sergey Poznyakoff <gray@gnu.org.ua>
Minor changes.
* mu/dbm.c: Remove unused variables.
* mu/wicket.c (wicket_args_doc): Fix argument name.
2011-11-01 Sergey Poznyakoff <gray@gnu.org.ua>
mu dbm: minor fix.
* mu/dbm.c (add_records): Initialize format.
2011-11-01 Sergey Poznyakoff <gray@gnu.org.ua>
mu dbm: improve command line interface.
* mu/dbm.c: Use subcommand (not options) to select operation
mode. New subcommand: dump.
* mu/help.c (mutool_help): Make sure argv[0] contains program
and command name.
* mu/mu.c (main): Likewise.
2011-11-01 Sergey Poznyakoff <gray@gnu.org.ua>
Introduce a better dbm dump format.
* include/mailutils/dbm.h (mu_dbm_get_name): New prototype.
* libmu_dbm/name.c: New file.
* libmu_dbm/Makefile.am (libmu_dbm_la_SOURCES): Add name.c
* mu/dbm.c: New dump format.
2011-10-31 Sergey Poznyakoff <gray@gnu.org.ua>
cctype: bugfix.
* include/mailutils/cctype.h (mu_isblank): Use mu_c_is_class.
* libmailutils/string/muctype.c (mu_c_tab): Mark ' ' and '\t'
as MU_CTYPE_BLANK.
2011-10-31 Sergey Poznyakoff <gray@gnu.org.ua>
inline-comment: bugfixes.
Fixes following bugs:
1. In whitespace-must-follow mode a comment sequence
immediately followed by a newline caused the next line to be
treated as a comment. Thus the following input:
; text
produced empty output (see test icmt-dec-08).
2. Line number information was not emitted before lines
starting with a comment sequence substring, e.g.:
; comment ;valid line
See test icmt-dec-09.
* libmailutils/filter/inline-comment.c (ilcmt_state) Withdraw
ilcmt_rollback_com state, use ilcmt_rollback instead. Withdraw
ilcmt_newline_ac state, use ILCMT_EMIT_LINE_INFO flag instead.
(ILCMT_EMIT_LINE_INFO): New flag.
(ilcmt_data) <replay>: Remove. <rollback_buffer, rollback_size>
<rollback_index>: New members.
(init_rollback): New function.
(_ilcmt_decoder): Use ilcmt_rollback state.
<ilcmt_comment_ws>: Do not skip newline following the comment.
Emit line info before rolling back, if required.
(_ilcmt_encoder): Use ilcmt_rollback state.
* libmailutils/tests/inline-comment.at: Rename tests. Add tests
for newline after a comment (icmt-dec-08) and line info with
whitespace-follow mode (icmt-dec-09).
2011-10-30 Sergey Poznyakoff <gray@gnu.org.ua>
Minor change.
2011-10-29 Sergey Poznyakoff <gray@gnu.org.ua>
Reorganize error codes.
* libmailutils/diag/errors (MU_ERR_TCP_NO_HOST)
(MU_ERR_TCP_NO_PORT): Change wording.
(MU_ERR_UNSAFE_PERMS): Remove error code.
(MU_ERR_NO_HANDLER): Remove. All uses replaced by ENOSYS.
(MU_ERR_OUT_NULL): Remove. MU_ERR_OUT_PTR_NULL is used instead.
(MU_ERR_MBX_NULL): Remove. Use EINVAL instead.
(MU_ERR_BAD_822_FORMAT): Rename to MU_ERR_INVALID_EMAIL. Change
wording.
(MU_ERR_REPLY): Change wording.
* libmailutils/url/create.c: Remove misguiding comments
* libmailutils/url/set-service.c: Likewise.
* libmailutils/mailbox/mailbox.c (mu_mailbox_open): Return
EACCES if trying to update quick-access mailboxes.
(mu_mailbox_get_stream): Mark for deletion.
* libmailutils/stream/fltstream.c (filter_read)
(filter_write_internal): Return MU_ERR_BUFSPACE if requested
more space than available in I/O buffers.
* libproto/mbox/mbox.c (mbox_expunge_unlocked): Send
MU_EVT_MAILBOX_CORRUPT event if the mailbox shrunk.
* libproto/mbox/mboxscan.c (mbox_scan_internal): Return
MU_ERR_NOENT if unable to locate message in quick-access mode.
2011-10-28 Sergey Poznyakoff <gray@gnu.org.ua>
pop3d: configurable APOP file and safety criteria.
* include/mailutils/dbm.h (mu_dbm_init)
(mu_dbm_get_hint): New prototypes.
* include/mailutils/util.h (mu_stpcpy)
(mu_file_safety_compose): New prototypes.
* libmailutils/string/Makefile.am (libstring_la_SOURCES): Add
stpcpy.c
* libmailutils/string/stpcpy.c: New file.
* libmu_cfg/tls.c (cb2_safety_checks): Use
mu_file_safety_compose.
* libmu_dbm/create.c (mu_dbm_create): Use mu_dbm_init.
* libmu_dbm/dbm.c (_mu_dbm_init): Rename mu_dbm_init. All uses
changed. Use URL composing interface to create hints.
* maidag/maidag.c (mu_dbm_get_hint): New function.
* pop3d/pop3d.c (cb2_forward_file_checks): Use
mu_file_safety_compose. (apop_database_name,
apop_database_safety)
(apop_database_safety_set): New variables. (pop3d_cfg_param)
<apop-database-file>
<apop-database-safety>: New configuration statements.
(main) [ENABLE_DBM]: Initialize dbm safety criteria.
* pop3d/apop.c (pop3d_apopuser): Use configured database name
and safety flags, if set.
* pop3d/pop3d.h [ENABLE_DBM] (APOP_PASSFILE): Add ".db" suffix.
(apop_database_name, apop_database_safety)
(apop_database_safety_set): New variables.
2011-10-28 Sergey Poznyakoff <gray@gnu.org.ua>
New interface for composing URLs from parts.
* include/mailutils/url.h (mu_url_sget_name)
(mu_url_aget_name,mu_url_get_name)
(mu_url_invalidate,mu_url_create_null)
(mu_url_set_user,mu_url_set_path,mu_url_set_scheme)
(mu_url_set_host,mu_url_set_port,mu_url_set_service)
(mu_url_set_auth,mu_url_set_secret,mu_url_add_param)
(mu_url_clear_param,mu_url_add_query,mu_url_clear_query): New
prototypes.
* libmailutils/tests/url-comp.at: New test case.
* libmailutils/tests/url-comp.c: New test program.
* libmailutils/tests/.gitignore: Update.
* libmailutils/tests/Makefile.am: Add new files.
* libmailutils/tests/testsuite.at: Add new tests.
* libmailutils/url/Makefile.am: Add new files.
* libmailutils/url/add-param.c: New file.
* libmailutils/url/add-query.c: New file.
* libmailutils/url/clr-param.c: New file.
* libmailutils/url/clr-query.c: New file.
* libmailutils/url/null.c: New file.
* libmailutils/url/set-auth.c: New file.
* libmailutils/url/set-host.c: New file.
* libmailutils/url/set-path.c: New file.
* libmailutils/url/set-port.c: New file.
* libmailutils/url/set-scheme.c: New file.
* libmailutils/url/set-secret.c: New file.
* libmailutils/url/set-service.c: New file.
* libmailutils/url/set-user.c: New file.
* libmailutils/url/urlinv.c: New file.
* libmailutils/url/create.c (mu_url_create_hint): Return EINVAL
if purl is NULL.
* libmailutils/url/scheme.c (mu_url_set_scheme): Remove. See
set-scheme.c
* libmailutils/url/urlstr.c (mu_url_sget_name)
(mu_url_aget_name,mu_url_get_name): New functions.
(mu_url_to_string): Rewrite using the above.
* libmailutils/base/Makefile.am: Add fscompose.c
* libmailutils/base/fscompose.c: New file.
2011-10-27 Sergey Poznyakoff <gray@gnu.org.ua>
Add testcases for file safety checking functions.
* libmailutils/tests/fsaf.at: New testcase.
* libmailutils/tests/fsaf.c: New file.
* libmailutils/tests/.gitignore: Add fsaf
* libmailutils/tests/Makefile.am: Likewise.
* libmailutils/tests/testsuite.at: Include fsaf.at.
2011-10-25 Sergey Poznyakoff <gray@gnu.org.ua>
Use MU_CTYPE_ENDLN to trim \r\n.
2011-10-25 Sergey Poznyakoff <gray@gnu.org.ua>
Reimplement DBM support.
* lib/mu_dbm.c: Remove.
* lib/mu_dbm.h: Remove.
* lib/Makefile.am: Remove mu_dbm.[ch].
* include/mailutils/sys/dbm.h: New file.
* include/mailutils/sys/Makefile.am: Add dbm.h
* include/mailutils/dbm.h: New file.
* include/mailutils/Makefile.am (pkginclude_HEADERS): Add
dbm.h.
* include/mailutils/types.hin (mu_dbm_file_t): New data type.
* libmu_dbm/Makefile.am: New file.
* libmu_dbm/berkeley.c: New file.
* libmu_dbm/close.c: New file.
* libmu_dbm/create.c: New file.
* libmu_dbm/datumfree.c: New file.
* libmu_dbm/dbm.c: New file.
* libmu_dbm/delete.c: New file.
* libmu_dbm/destroy.c: New file.
* libmu_dbm/errstr.c: New file.
* libmu_dbm/fetch.c: New file.
* libmu_dbm/firstkey.c: New file.
* libmu_dbm/gdbm.c: New file.
* libmu_dbm/mudbm.h: New file.
* libmu_dbm/ndbm.c: New file.
* libmu_dbm/nextkey.c: New file.
* libmu_dbm/open.c: New file.
* libmu_dbm/safety.c: New file.
* libmu_dbm/store.c: New file.
* Makefile.am [MU_COND_DBM]: Define LIBMU_DBM_DIR
(SUBDIRS): Add $(LIBMU_DBM_DIR)
* configure.ac: Revamp DBM support: several database types can
be specified at once.
(AC_CONFIG_FILES): Build libmu_dbm/Makefile
* libmu_sieve/extensions/vacation.c: Remove inclusion of
mu_dbm.h.
* maidag/Makefile.am (maidag_LDADD): Add DBM libraries.
* maidag/maidag.c: ENABLE_DBM instead of USE_DBM
* maidag/maidag.h: Include <mailutils/dbm.h> instead of
mu_dbm.h.
* maidag/mailquota.c (dbm_retrieve_quota): Rewrite using
libmu_dbm library calls.
* mu/Makefile.am [MU_COND_DBM]: Define DBM_C.
(MODULES): Add $(DBM_C).
(AM_CPPFLAGS): Define DBMLIBS.
* mu/ldflags.c (NEEDAUTH): Change definition.
(lib_descr) <weight>: New member. All uses changed.
(add_entry): Null arguments ignored.
(mutool_ldflags): Rewrite traversal of lib_descr.
* mu/dbm.c: New file.
* pop3d/Makefile.am (pop3d_LDADD, popauth_LDADD): Add DBM
libraries.
* pop3d/apop.c: Rewrite using libmu_dbm library calls.
* pop3d/bulletin.c: Likewise.
* pop3d/logindelay.c: Likewise.
* pop3d/pop3d.c: Change USE_DBM to ENABLE_DBM.
* pop3d/pop3d.h: Include mailutils/dbm.h instead of mu_dbm.h
* pop3d/popauth.c: Rewrite using libmu_dbm library calls.
* include/mailutils/cctype.h (MU_CTYPE_ENDLN): New character
class.
(mu_isendln): New macro.
* libmailutils/string/muctype.c (mu_c_tab): Mark \r and \n as
MU_CTYPE_ENDLN.
2011-10-24 Sergey Poznyakoff <gray@gnu.org.ua>
Simplify mu_file_safety_check call.
* include/mailutils/util.h (mu_file_safety_check): Change type
of the 3rd argument to uid_t.
* libmailutils/base/filesafety.c: Likewise. All uses updated.
2011-10-24 Sergey Poznyakoff <gray@gnu.org.ua>
Complement 1e33c774.
* mh/comp.c: Open mailbox in read-only mode.
2011-10-24 Sergey Poznyakoff <gray@gnu.org.ua>
imap4d: fix reading multi-line literals.
* imap4d/io.c (imap4d_tokbuf_decrlf): New function.
(imap4d_tokbuf_expand): Call imap4d_tokbuf_decrlf for literals.
2011-10-24 Sergey Poznyakoff <gray@gnu.org.ua>
Minor change.
* mh/tests/atlocal.in (mimeflt): ignore stderr, instead of
reading input from /dev/null, because this function can
theoretically be used as a filter.
2011-10-22 Sergey Poznyakoff <gray@gnu.org.ua>
Fixes in the testsuite & some minor fixes.
* comsat/comsat.c (main): Use real UID to determine user name.
Don't rely on environment variables.
* maidag/util.c (maidag_error): Re-initialize va_list before
reusing it.
* mh/ali.c (ali_print_name_list): Change printing loop to
correctly handle empty lists.
* mh/mh_whatnow.c (quit): Print newline before returning.
* comsat/tests/testsuite.at: Skip tests if run as root.
* maidag/tests/forward.at: Skip test if run as root.
* mh/tests/ali.at: Ignore comment lines in /etc/passwd and
/etc/group. Make sure awk is run with a valid stdin. Some
implementations (true awk, in particular) try to close stdin
even if it is not used and bail out if unable to do so.
* mh/tests/atlocal.in (mimeflt): Make sure awk is run with a
valid stdin (see above).
* mh/tests/anno.at: Always use semicolon before closing curly
brace in sed expressions.
* mh/tests/mark.at: Likewise.
* mh/tests/pick.at: Likewise.
* testsuite/testsuite.inc: Likewise.
* mh/tests/comp.at: Reflect changes to mh_whatnow.c.
* mh/tests/mhn.at: Don't rely on a particular tar output
format.
2011-10-22 Sergey Poznyakoff <gray@gnu.org.ua>
Make all status flags permanent.
* include/mailutils/attribute.h (MU_STATUS_BUF_SIZE): Add more
status letters.
* libmailutils/mailbox/attribute.c (flagtrans): Keep the same
ordering as in attribute.h. Add missing attributes.
* imap4d/select.c (imap4d_select_status): All flags are now
permanent.
* imap4d/testsuite/imap4d/IDEF0955.exp: Reflect changes in
PERMANENTFLAGS.
* imap4d/testsuite/imap4d/IDEF0956.exp: Likewise.
* imap4d/testsuite/imap4d/append.exp: Likewise.
* imap4d/testsuite/imap4d/create.exp: Likewise.
* imap4d/testsuite/imap4d/examine.exp: Likewise.
* imap4d/testsuite/imap4d/expunge.exp: Likewise.
* imap4d/testsuite/imap4d/fetch.exp: Likewise.
* imap4d/testsuite/imap4d/search.exp: Likewise.
2011-10-21 Sergey Poznyakoff <gray@gnu.org.ua>
Fix locking in pop3 and imap4d. This complements d0769b4f.
* lib/manlock.c (mailbox_open_and_lock): Open mailbox before
retrieving its locker, otherwise it is always NULL.
* pop3d/pop3d.c (main): Enforce mandatory locking.
2011-10-21 Sergey Poznyakoff <gray@gnu.org.ua>
Testsuite: add banners before groups of related tests.
2011-10-21 Sergey Poznyakoff <gray@gnu.org.ua>
amd: report MU_EVT_MAILBOX_CORRUPT if unable to rename message
file due to ENOENT.
* libmailutils/base/amd.c
* libproto/maildir/mbox.c
2011-10-20 Sergey Poznyakoff <gray@gnu.org.ua>
Change attribute handling in Maildir format.
* include/mailutils/message.h (MU_MSG_ATTRIBUTE_MODIFIED)
(MU_MSG_HEADER_MODIFIED,MU_MSG_BODY_MODIFIED): New flags.
* libmailutils/mailbox/message.c (mu_message_is_modified):
Return a bitmask from the above values.
* libmailutils/property/create.c (mu_property_create_init):
Return error code.
* include/mailutils/sys/amd.h (_amd_data) <chattr_msg>
<capabilities, prop>: New members.
<uidvalidity>: Remove.
* libmailutils/base/amd.c: Use MH-style proplist to keep the
mailbox properties: uidvalidity, last uid and to cache its
size. Store message attributes in the message header only if
the mailbox implementation is unable to keep them elsewhere.
Use chattr_msg method (if provided) to flush changes in message
attributes.
* libproto/maildir/folder.c (_maildir_list_p): Ignore .mh* and
.mu* files.
* libproto/mh/folder.c (_mh_list_p): Likewise.
* libproto/maildir/mbox.c: Implement all Maildir flags (except
P). Implement the chattr_msg method.
* libproto/mh/mbox.c: Remove special handling for uidvalidity.
* mh/tests/folder.at: Ignore .mu-prop in directory listings.
2011-10-20 Sergey Poznyakoff <gray@gnu.org.ua>
Bugfix.
* libmu_cfg/tls.c (cb2_safety_checks): Fix handling of "all"
and "none".
* maidag/maidag.c (cb2_forward_file_checks): Likewise.
* maidag/forward.c (maidag_forward): Handle MU_ERR_EXISTS
return properly.
2011-10-18 Sergey Poznyakoff <gray@gnu.org.ua>
File safety checks: Implement "default" keyword.
2011-10-17 Sergey Poznyakoff <gray@gnu.org.ua>
Provide a mechanism for configurable file safety checking.
Use it in maidag (.forward file safety) and in libmu_auth (TLS
files).
* include/mailutils/tls.h (mu_tls_module_config): New members
for safety check flags.
* include/mailutils/util.h
(MU_FILE_SAFETY_NONE,MU_FILE_SAFETY_ALL)
(MU_FILE_SAFETY_OWNER_MISMATCH)
(MU_FILE_SAFETY_GROUP_WRITABLE,MU_FILE_SAFETY_WORLD_WRITABLE)
(MU_FILE_SAFETY_GROUP_READABLE,MU_FILE_SAFETY_WORLD_READABLE)
(MU_FILE_SAFETY_LINKED_WRDIR)
(MU_FILE_SAFETY_DIR_IWGRP,MU_FILE_SAFETY_DIR_IWOTH): New
constants. (mu_file_safety_check,mu_file_safety_name_to_code)
(mu_file_safety_name_to_error): New protos.
* libmailutils/base/checkperms.c: New file.
* libmailutils/base/Makefile.am (libbase_la_SOURCES): Add
checkperms.c.
* libmailutils/diag/errors: Add new error codes.
(MU_ERR_UNSAFE_PERMS): change description wording.
* libmu_auth/tls.c (mu_check_tls_environment): Use
mu_file_safety_check.
* libmu_cfg/tls.c (tls_settings): Initialize.
(mu_tls_param): New configuration file statements:
key-file-safety-checks, cert-file-safety-checks,
ca-file-safety-checks.
* maidag/forward.c (maidag_forward): Use mu_file_safety_check.
* maidag/maidag.c (cb2_forward_file_checks): Use
mu_file_safety_name_to_code.
2011-10-16 Sergey Poznyakoff <gray@gnu.org.ua>
Minor changes, proposed by Jordi Mallach.
* scheme/sieve2scm.scmi: Tailor help output to meet help2man
expectations.
* libmu_scm/mailutils/Makefile.am (EXTRA_DIST): Remove
generated file mailutils.scm.
2011-10-16 Sergey Poznyakoff <gray@gnu.org.ua>
mh: open mailboxes in read-only mode unless the requested
operation mandates otherwise.
* mh/mhn.c: Open mailbox in read-only mode.
* mh/mhseq.c: Likewise.
* mh/scan.c: Likewise.
* mh/pick.c: If sequences are given, open mailbox for RW,
otherwise open it for reading only.
* testsuite/testsuite.inc (MUT_MBCHMOD): New macro.
(MUT_MBCOPY): Take optional third argument - mailbox mode.
* mh/tests/mhl.at: Make sure mailboxes are r/o.
* mh/tests/mhn.at: Likewise.
* mh/tests/mhseq.at: Likewise.
* mh/tests/scan.at: Likewise.
2011-10-15 Sergey Poznyakoff <gray@gnu.org.ua>
Bugfixes.
* libmailutils/base/amd.c (amd_open): Return error if the
mailbox cannot be opened for the required access permissions.
(amd_message_stream_open): Fix condition for determining r/w
access.
* mh/mh_list.c (eval_extras): Break the loop if
mu_header_aget_field_name fails.
2011-10-15 Sergey Poznyakoff <gray@gnu.org.ua>
imap4d: fix returned INTERNALDATE and date searches.
INTERNALDATE now includes a meaningful timezone information (it
used to return +0000).
Date searches disregard the time and timezone of the
INTERNALDATE or Date: header, as mandated by RFC 3501.
* libmailutils/base/date.c (mu_parse_ctime_date_time): In the
absence of TZ in ctime strings, return local time zone.
* imap4d/io.c (imap4d_tokbuf_getline): Kill trailing
whitespace.
* imap4d/util.c (adjust_tm): New function.
(util_parse_internal_date) (util_parse_822_date)
(util_parse_ctime_date): Take three arguments, the third one
controlling what information to return. All uses updated.
* imap4d/fetch.c (_frt_internaldate): Return meaningful
timezone. If all else fails, use local TZ.
* imap4d/imap4d.h (datetime_parse_mode): New enum.
(util_parse_internal_date) (util_parse_822_date)
(util_parse_ctime_date): Change signature.
* imap4d/search.c (parse_simple_key)
(_header_date,cond_before,cond_on,cond_since): Use
datetime_date_only mode.
* testsuite/spool/search.mbox: New file.
* testsuite/spool/DISTFILES: Add search.mbox
* imap4d/testsuite/lib/imap4d.exp (imap4d_start): New option
-mbox.
* imap4d/testsuite/imap4d/search.exp: Rewrite.
* imap4d/testsuite/imap4d/create.exp: Account for TZ part in
internaldate strings, which may vary.
* imap4d/testsuite/imap4d/fetch.exp: Likewise.
* imap4d/testsuite/imap4d/list.exp: List the new mailbox.
2011-09-22 Sergey Poznyakoff <gray@gnu.org.ua>
Bugfix.
* libmailutils/filter/crlfflt.c (_crlf_encoder): Reset state to
initial if any character other than \r and \n is read.
2011-09-10 Sergey Poznyakoff <gray@gnu.org.ua>
Minor changes.
* doc/texinfo/mailutils.texi: Update.
* doc/texinfo/rendition.texi: Rewrite.
2011-09-09 Sergey Poznyakoff <gray@gnu.org.ua>
Minor fix.
* doc/texinfo/programs.texi: Use @group inside @cartouche, not
vice-versa.
2011-09-09 Sergey Poznyakoff <gray@gnu.org.ua>
Fix generation of the doc files.
* doc/texinfo/Config: New file.
* doc/texinfo/Makefile.am (manual): Use texi2html.
* doc/texinfo/gendocs_template: Rewrite.
* doc/texinfo/maint.mk: Use VPATH to find source files. Add the
`clean' rule.
2011-08-29 Sergey Poznyakoff <gray@gnu.org.ua>
Fix testsuite.
* mh/tests/burst.at: Remove leading newlines from the test
messages.
2011-08-29 Sergey Poznyakoff <gray@gnu.org.ua>
Make sure header reads always return the trailing \n, even for
empty headers.
* libmailutils/mailbox/header.c (header_read): Always return
trailing \n.
2011-08-29 Sergey Poznyakoff <gray@gnu.org.ua>
Minor fix.
* libmailutils/stream/message_stream.c (_message_open): Return
MU_ERR_BAD_822_FORMAT if the input is not a valid RFC822.
2011-08-28 Sergey Poznyakoff <gray@gnu.org.ua>
Minor fix.
* libmailutils/stream/fltstream.c: Implement shutdown method.
2011-08-27 Sergey Poznyakoff <gray@gnu.org.ua>
Version 2.99.93.
2011-08-26 Sergey Poznyakoff <gray@gnu.org.ua>
Improve mime support, introduce ref/unref functions for
mu_message_t and mu_mime_t.
* include/mailutils/message.h (mu_message_ref): Change proto.
(mu_message_unref): New proto (instead of macro).
* include/mailutils/mime.h (mu_mime_ref)
(mu_mime_unref, mu_mime_to_message): New protos.
* include/mailutils/sys/message.h (MESSAGE_MODIFIED)
(MESSAGE_INTERNAL_STREAM): New constants (from mime.c)
(MESSAGE_MIME_OWNER): New constant.
(_mu_message) <ref_count>: Rename from ref.
* include/mailutils/sys/mime.h (MIME_SEEK_ACTIVE): New
constant.
(_mu_mime) <ref_count>: New member.
* libmailutils/mailbox/message.c (MESSAGE_MODIFIED)
(MESSAGE_INTERNAL_STREAM): Removed (see above).
* libmailutils/mailer/mailer.c (mu_message_unref): New
function.
(mu_message_destroy): Rewrite.
(mu_message_ref): Returns void.
(mu_message_lines): Don't access header and body directly to
give virtual functions a chance to initialize them.
(mu_message_quick_lines): likewise.
* libmailutils/mailer/mailer.c (send_fragments): Use
mu_mime_to_message instead of mu_message_unref.
* libmailutils/mime/mime.c (_mime_append_part): Set offset only
if mime->stream is not null.
(_mime_body_stream_seek): Implement (albeit inefficiently).
(mu_mime_create): Set ref_count.
(mu_mime_ref, mu_mime_unref): New functions.
(mu_mime_destroy): Reimplement as a wrapper over _mu_mime_free.
(mu_mime_get_message): Increase refcount of the message being
returned.
(mu_mime_to_message): New function.
* libmailutils/stream/message_stream.c (_message_open): Handle
arbitrary text as RFC822 without headers.
* libmu_sieve/actions.c: Unref the message returned by
mu_mime_get_message.
* libmu_sieve/extensions/vacation.c: Likewise.
* mh/mhn.c: Likewise.
* libmailutils/stream/stream.c (mu_stream_seek) <MU_SEEK_CUR>:
Bugfix.
2011-08-25 Sergey Poznyakoff <gray@gnu.org.ua>
Bugfixes.
* maidag/lmtp.c: Fix typo in a function name.
* mh/burst.c (burst_digest): Initialize result.
2011-08-04 Sergey Poznyakoff <gray@gnu.org.ua>
Various bugfixes.
* libmailutils/base/assoc.c (first): Set index to max value if
tab is NULL to indicate immediate end of iteration.
* libmu_auth/sql.c (mu_auth_sql_by_name)
(mu_auth_sql_by_uid): Check the return from mu_sql_num_tuples.
(mu_sql_getpass): Check the number of returned tuples. Return
failure if returned a NULL password.
* libmu_scm/mu_message.c (string_sloppy_member): Remove.
(mu-message-get-header-fields): Use scm_member instead of
string_sloppy_member.
* sql/postgres.c (chop): Handle NULL argument.
2011-07-27 Sergey Poznyakoff <gray@gnu.org.ua>
Fake commit to test whether git mail notification works.
2011-07-19 Sergey Poznyakoff <gray@gnu.org.ua>
Minor change.
* bootstrap.conf: Use the latest radius.m4
2011-07-18 Sergey Poznyakoff <gray@gnu.org.ua>
Bugfixes.
* libmailutils/base/rfc2047.c (mu_rfc2047_decode): Break if
reading from the filter fails.
* libmailutils/stream/fltstream.c (filter_read): Treat
mu_filter_moreinput in the lastbuf state as error.
2011-07-14 Sergey Poznyakoff <gray@gnu.org.ua>
Version 2.99.92.
* NEWS: Update.
* configure.ac: Update.
* po/POTFILES.in: Update.
2011-07-14 Sergey Poznyakoff <gray@gnu.org.ua>
Implement optional mailbox-independent locking for pop3d and
imap4d.
* lib/manlock.c: New file.
* lib/Makefile.am (libmuaux_a_SOURCES): Add manlock.c.
* lib/muaux.h (manlock_mandatory_locking)
(manlock_lock_dir): New externs. (manlock_open_mailbox,
manlock_lock)
(manlock_touchlock, manlock_unlock): New protos.
* libmailutils/base/amd.c (amd_cleanup): Remove unbalanced call
to mu_locker_unlock.
* libmailutils/base/locker.c (mu_locker_create): Bugfixes.
* imap4d/imap4d.c (imap4d_cfg_param): Add mandatory-locking
construct.
(main): Call manlock_cfg_init.
* imap4d/select.c (imap4d_select0): Use mandatory locking if
the mailbox is to be opened r/w.
* imap4d/rename.c (imap4d_rename): Note FIXME!
* imap4d/bye.c: Call manlock_unlock after closing the mailbox.
* imap4d/close.c: Likewise.
* imap4d/sync.c (imap4d_sync): Call manlock_touchlock.
* pop3d/lock.c: Remove.
* pop3d/Makefile.am (pop3d_SOURCES): Remove lock.c
* pop3d/extra.c (pop3d_abquit): Unlock mailbox.
* pop3d/pop3d.c (pop3d_cfg_param): Add mandatory-locking
construct.
(main): Call manlock_cfg_init.
(pop3d_mainloop): Call manlock_touchlock.
* pop3d/pop3d.h (pop3d_lock)
(pop3d_touchlock, pop3d_unlock): Remove.
* pop3d/quit.c (pop3d_quit): Unlock the mailbox.
* pop3d/user.c (pop3d_begin_session): Use manlock_open_mailbox.
2011-07-07 Sergey Poznyakoff <gray@gnu.org.ua>
Bugfix.
* libmailutils/string/vasnprintf.c (mu_vasnprintf): Operate on
a fresh copy of va_alist in each new iteration.
* libproto/imap/folder.c: Likewise.
* libproto/nntp/nntp_sendline.c: Likewise.
2011-07-05 Sergey Poznyakoff <gray@gnu.org.ua>
Allow caller to set up custom in,out,err,progname,tag before
calling mu_app_init.
* include/mailutils/stdstream.h (MU_STDSTREAM_RESET_STRIN)
(MU_STDSTREAM_RESET_STROUT,MU_STDSTREAM_RESET_STRERR)
(MU_STDSTREAM_RESET_NONE,MU_STDSTREAM_RESET_ALL): New flags.
(mu_stdstream_setup): Change signature. All uses updated.
* libmailutils/stdstream/basestr.c (mu_stdstream_setup): Use
the flags argument to decide whether to close existing streams.
Make sure stdstream_flushall enters the onexit queue only once.
* libmu_argp/muinit.c (mu_app_init): Don't override variables
that may be set by the caller (program_name, tag, streams).
2011-07-05 Sergey Poznyakoff <gray@gnu.org.ua>
Fixes.
* libmailutils/diag/errors: Fix typo.
* libproto/imap/connect.c: Add missing includes.
* mh/tests/mhn.at: Add extra argument quoting.
2011-07-04 Sergey Poznyakoff <gray@gnu.org.ua>
Minor fix.
* libmailutils/diag/wd.c (mu_wd): Revamp the loop to ensure the
proposed way of connecting with gdb works in case of a non-zero
timeout.
2011-06-20 Sergey Poznyakoff <gray@gnu.org.ua>
imap4d: bugfix.
* NEWS: Version 2.99.91
* configure.ac: Likewise.
* imap4d/imap4d.h (io_getline): Change return value
* imap4d/io.c (io_getline): Abort if a read error occurs.
2011-06-08 Sergey Poznyakoff <gray@gnu.org.ua>
Various minor fixes.
* include/mailutils/diag.h (mu_full_program_name): New extern.
* libmailutils/diag/diag.c (mu_full_program_name): New global.
(mu_set_program_name): Set mu_full_program_name.
(mu_diag_at_locus): Fix format specifier.
* libmailutils/diag/bt.c: Use mu_full_program_name instead of
program_invocation_name.
* libmailutils/diag/wd.c (mu_wd): Likewise.
* comsat/comsat.c: Fix format specifiers.
* lib/mailcap.c: Likewise.
* libmu_sieve/util.c: Cast formatted arguments to match format
specs.
* mh/mh_getopt.c: Likewise.
* libmailutils/cidr/fromstr.c: Add missing includes.
* libproto/mailer/smtp.c: Likewise.
* libproto/pop/mbox.c: Likewise.
* testsuite/smtpsend.c: Likewise.
* mu/getarg.c: Likewise.
* mu/imap.c: Likewise.
* mu/pop.c (com_connect): Protect TLS code with #ifdef.
* mu/Makefile.am (EXTRA_DIST): Add mu-setup.awk.
* mail/summary.c (mail_summary): Fix data types of the
counters.
2011-05-16 Sergey Poznyakoff <gray@gnu.org.ua>
Bugfixes.
* libmailutils/cfg/parser.y (STRTONUM, STRxTONUM)
(GETSNUM, GETUNUM): Remove unused arguments.
* libmailutils/stream/tcp.c (mu_tcp_stream_create_from_sa):
Take care not to destroy sockaddr arguments in case of failure.
2011-03-31 Sergey Poznyakoff <gray@gnu.org.ua>
Bugfixes.
* libmailutils/filter/base64.c (_base64_encoder): Fix for the
case when cmd==mu_filter_lastbuf and isize==0.
* libmailutils/stream/tcp.c
(mu_tcp_stream_create_with_source_ip)
(mu_tcp_stream_create_with_source_host): Don't treat EAGAIN and
EINPROGRESS as errors.
* libproto/mailer/smtp.c (smtp_open): Free sockaddr if
mu_tcp_stream_create_from_sa failed.
* libproto/pop/mbox.c (pop_open): Likewise.
* mu/imap.c (com_connect): Likewise.
* mu/pop.c (com_connect): Likewise.
2011-03-31 Sergey Poznyakoff <gray@gnu.org.ua>
cidr: Implement simplified IPv6 formats.
* include/mailutils/cidr.h (MU_CIDR_FMT_SIMPLIFY): New format
flag.
* libmailutils/cidr/tostr.c (format_ipv6_bytes): Take
additional argument, indicating whether to simplify the output.
(format_ipv6_bytes_normal)
(format_ipv6_bytes_simplified): New static functions.
(mu_cidr_to_string): Select appropriate ipv6 printer depending
on the MU_CIDR_FMT_SIMPLIFY bit.
* libmailutils/tests/cidr.c (main): New options -s and -S
2011-03-30 Sergey Poznyakoff <gray@gnu.org.ua>
Version 2.99.90.
2011-03-30 Sergey Poznyakoff <gray@gnu.org.ua>
New configuration options to disable groups of utilities.
* am/enable.m4 (MU_ENABLE_BUILD): Take optional 6th argument.
If given, append $1 to it.
* configure.ac: New options: --enable-build-servers and
--enable-build-clients. Print a list of selected utilities at
the end of the run.
* README: Document new options.
2011-03-30 Sergey Poznyakoff <gray@gnu.org.ua>
Bugfix.
* libmailutils/sockaddr/fromnode.c [!MAILUTILS_IPV6] Handle
AF_UNSPEC same way as AF_INET. Do not bail out if service is
not given, assume port = 0 instead.
* mailutils/base/version.c (mu_conf_option): Reflect IPv6
support.
2011-03-30 Sergey Poznyakoff <gray@gnu.org.ua>
Implement IPv6 support.
* am/ipv6.m4: New file.
* examples/sa.c: New file.
* include/mailutils/cidr.h: New file.
* include/mailutils/sockaddr.h: New file.
* libmailutils/cidr/Makefile.am: New file.
* libmailutils/cidr/fromsa.c: New file.
* libmailutils/cidr/fromstr.c: New file.
* libmailutils/cidr/match.c: New file.
* libmailutils/cidr/tosa.c: New file.
* libmailutils/cidr/tostr.c: New file.
* libmailutils/sockaddr/Makefile.am: New file.
* libmailutils/sockaddr/copy.c: New file.
* libmailutils/sockaddr/create.c: New file.
* libmailutils/sockaddr/free.c: New file.
* libmailutils/sockaddr/fromnode.c: New file.
* libmailutils/sockaddr/insert.c: New file.
* libmailutils/sockaddr/ipaddr.c: New file.
* libmailutils/sockaddr/str.c: New file.
* libmailutils/sockaddr/unlink.c: New file.
* libmailutils/sockaddr/url.c: New file.
* libmailutils/tests/cidr.c: New file.
* configure.ac: Call MU_ENABLE_IPV6. Build
libmailutils/sockaddr and libmailutils/cidr.
* examples/.gitignore: Add mblconv and sa
* examples/Makefile.am: (noinst_PROGRAMS): Add sa.
* examples/aclck.c: Use new ACL API.
* examples/echosrv.c: Use new mserv API.
* include/mailutils/Makefile.am (pkginclude_HEADERS): Add
cidr.h and sockaddr.h
* include/mailutils/acl.h (mu_acl_append, mu_acl_prepend)
(mu_acl_insert): Change signatures.
* include/mailutils/debug.h (mu_sockaddr_to_str): Remove proto.
* include/mailutils/mailutils.h: Include cidr.h and sockaddr.h
* include/mailutils/server.h (mu_ip_server_create): Change
signature.
(mu_ip_server_get_sockaddr): Likewise.
(mu_m_server_set_default_address)
(mu_m_server_get_default_address): Remove.
* include/mailutils/stream.h (mu_tcp_stream_create_from_sa):
New proto.
* include/mailutils/types.hin (mu_cidr, mu_sockaddr): New
structs.
* include/mailutils/url.h (MU_URL_IPV6): New flag.
(MU_URL_PARSE_DSLASH_OPTIONAL): New parse flag.
* libmailutils/Makefile.am: Descend into cidr and sockaddr.
Link in libcidr and libsockaddr.
* libmailutils/diag/debug.c (mu_debug_log_begin): Flush
mu_strerr.
* libmailutils/diag/errors (MU_ERR_NONAME)
(MU_ERR_BADFLAGS,MU_ERR_SOCKTYPE)
(MU_ERR_FAMILY,MU_ERR_SERVICE): New errors.
* libmailutils/server/acl.c: Rewrite API using mu_cidr.
* libmailutils/server/ipsrv.c: Rewrite AI using mu_sockaddr.
* libmailutils/server/msrv.c: Likewise.
* libmailutils/stream/tcp.c: Likewise.
* libmailutils/tests/.gitignore: Add cidr.
* libmailutils/tests/Makefile.am (noinst_PROGRAMS): Add cidr.
* libmailutils/tests/url-parse.c: Support command line options
to tune the parsing.
* libmailutils/tests/url.at: Pass options to url-parse.
* libmailutils/url/create.c (getkn): Return meaningful error
code.
(_mu_url_ctx_parse_host): Accept IPv6 addresses. Set the
MU_URL_IPV6 flag if one is given.
(_mu_url_ctx_parse): Unless MU_URL_PARSE_DSLASH_OPTIONAL flag
is given, request :// after scheme part.
(mu_url_create): Add MU_URL_PARSE_DSLASH_OPTIONAL flag.
* libmu_cfg/acl.c: Use new ACL API.
* mu/acl.c: Likewise.
* libproto/mailer/smtp.c (smtp_open): Use
mu_tcp_stream_create_from_sa
* libproto/pop/mbox.c (pop_open): Likewise.
* mu/imap.c (com_connect): Likewise.
* mu/pop.c (com_connect): Likewise.
* testsuite/smtpsend.c (main): Likewise.
2011-03-30 Sergey Poznyakoff <gray@gnu.org.ua>
Minor fix.
* mh/tests/comp.at: Remove trailing whitespace before
comparisons
2011-03-23 Sergey Poznyakoff <gray@gnu.org.ua>
New filter "c-escape".
* libmailutils/filter/c-escape.c: New file.
* include/mailutils/filter.h (mu_c_escape_filter): New extern.
* libmailutils/filter/Makefile.am (libfilter_la_SOURCES): Add
c-escape.c
* libmailutils/filter/filter.c (mu_filter_get_list): Add
mu_c_escape_filter to the list.
2011-03-17 Sergey Poznyakoff <gray@gnu.org.ua>
More bugfixes.
* examples/mblconv.c (main): Return 0.
* examples/murun.c (main): Fix iteration body.
* imap4d/append.c: Do not pass constructed string as format
argument to io_completion_response, use %s instead.
* imap4d/close.c: Likewise.
* imap4d/create.c: Likewise.
* imap4d/delete.c: Likewise.
* imap4d/rename.c: Likewise.
* imap4d/status.c: Likewise.
* libmailutils/base/mutil.c (mutil_parse_field_map): Fix return
code in case of wordsplit failure.
* libmailutils/cfg/parser.y (GETSNUM): Initialize sign.
* libmailutils/stream/streamref.c (_streamref_ctl)
<MU_IOCTL_SEEK_LIMITS>: Initialize lim.
* libmailutils/string/wordsplit.c: Typecast format width
arguments to int.
* libmu_sieve/extensions/vacation.c (check_db): Initialize
days. Pass correct time value to test_and_update_prop.
* libproto/pop/mbox.c (pop_create_pop3_message): Fix return
code.
* mail/mail.c (do_and_quit): Pass the command to
util_do_command via the %s format.
* mail/unset.c (mail_unset): Likewise.
* mh/mh_fmtgram.y (function production): Likewise for mu_error.
* mu/logger.c (mutool_logger): Fix return code in case of
mu_stdstream_strerr_create failure.
2011-03-17 Sergey Poznyakoff <gray@gnu.org.ua>
Bugfixes.
* comsat/action.c (action_echo): Set omit_newline.
* libmailutils/mailbox/mbx_default.c: Return 0 on success. Fix
memory overrun.
* libproto/mailer/smtp.c (smtp_open): Protect tls-related code
with #ifdef WITH_TLS.
* libproto/pop/mbox.c (pop_open): Likewise.
* mu/imap.c (com_connect): Likewise.
* mh/mhn.c (split_args): Preserve quotes.
(mhn_compose_command): Handle type arguments (%a escape).
(mhn_show_command): Likewise.
(store_handler): Fix call to mh_getyn.
(edit_mime): Pass typeargs to mhn_compose_command. Fix test for
missing filename.
* mh/tests/ali.at (ali04): The test wrongly assumed that the
`root' group has some members.
* mh/tests/folder.at: Always sort the output from find.
* mh/tests/rmf.at: Likewise.
* mh/tests/mhn.at: Likewise. Filter out timestamps from the tar
output produced by mhn.
* tests/testsuite.at (MH_SETUP): Define moreproc.
* mh/tests/mhparam.at: Account for changes in mh_profile
2011-03-10 Sergey Poznyakoff <gray@gnu.org.ua>
message_stream: deduce default envelope address from the
current user email.
* libmailutils/stream/message_stream.c: Unless specified
otherwise, set envelope address based on the current user
email.
* mh/tests/burst.at: Remove all X-Envelope headers before
comparison.
2011-03-09 Sergey Poznyakoff <gray@gnu.org.ua>
mail: bugfix.
* mail/mailline.c (ml_readline_internal): Remove trailing \n.
2011-03-07 Sergey Poznyakoff <gray@gnu.org.ua>
New global variable mu_site_rcfile keeps the name of the
site-wide configuration file.
* include/mailutils/gocs.h (mu_site_rcfile): New extern.
* include/mailutils/libcfg.h (MU_CONFIG_FILE): Remove.
(mu_register_cfg_capa): Remove proto.
(mu_libcfg_register_capa): New proto.
* libmailutils/cfg/gocs.c (mu_site_rcfile): New variable.
* libmu_argp/muinit.c (mu_app_init): Use mu_site_rcfile instead
of MU_CONFIG_FILE. Destroy parse_tree when no longer needed.
* libmu_cfg/init.c (cfg_capa_table): Static.
(find_cfg_capa): Likewise.
(reserved_name): Treat names starting with dot as reserved.
(mu_libcfg_register_capa): New function.
(mu_libcfg_parse_config): Use mu_site_rcfile instead of
MU_CONFIG_FILE.
* mu/query.c (mutool_query): Use mu_site_rcfile instead of
MU_CONFIG_FILE.
2011-03-05 Sergey Poznyakoff <gray@gnu.org.ua>
Simplify mu_cfg_tree_reduce.
This function used to handle include/program statements, which
is useless now, as these are expanded by
mu_cfg_tree_postprocess.
* include/mailutils/cfg.h (mu_cfg_tree_reduce): Change
signature.
(mu_format_config_tree): Change signature.
(mu_config_clone_root_container): New proto.
(mu_config_register_section): Rename to
mu_config_root_register_section.
mu_config_container_register_section. All uses changed.
(mu_config_root_register_section): New proto.
* libmailutils/cfg/driver.c (prog_parser)
(_cb_include): Remove unnecessary code.
(mu_build_container): Simplify. All uses updated.
(mu_cfg_tree_reduce): Simplify invocation. All uses updated.
* libmu_argp/muinit.c (mu_app_init): Re-implement --config-help
support.
* sieve/sieve.c (sieve_cfg_param): Fix docstring for "debug".
* sieve/tests/testsuite.at (MUT_SIEVE_DEFAULT_OPTIONS): New
variable.
(MUT_SIEVE_CMDLINE): Include MUT_SIEVE_DEFAULT_OPTIONS.
(MUT_SIEVE_COMPILE): Pass MUT_SIEVE_DEFAULT_OPTIONS to sieve.
2011-03-05 Sergey Poznyakoff <gray@gnu.org.ua>
Introduce "parser hints", to provide better control over
configuration parsing.
* include/mailutils/cfg.h (mu_cfg_parse_hints): New struct.
(mu_cfg_tree_postprocess): Change signature. Last argument is
struct mu_cfg_parse_hints *.
(MU_CFG_PARSE_SITE_RCFILE,MU_CFG_PARSE_CUSTOM_RCFILE)
(MU_CFG_PARSE_PROGRAM): New flags.
(mu_cfg_parse_config): New proto.
* libmailutils/cfg/lexer.l (mu_get_config): Fix call to
mu_cfg_tree_postprocess.
* libmailutils/cfg/parser.y (do_include): Takes hints as 2nd
argument.
(mu_cfg_tree_postprocess): Likewise.
(mu_cfg_parse_config): New function.
* libmu_cfg/init.c (mu_libcfg_parse_config): Rewrite as a
wrapper over mu_cfg_parse_config.
* libmu_argp/muinit.c (mu_app_init): Update.
* mu/query.c: New option --program.
(mutool_query): Use mu_cfg_parse_config interface.
2011-03-04 Sergey Poznyakoff <gray@gnu.org.ua>
mu: improve query interface.
* include/mailutils/cfg.h (mu_cfg_node) <parent>: New member.
(MU_CFG_FMT_VALUE_ONLY)
(MU_CFG_FMT_PARAM_PATH): New flags.
* libmailutils/cfg/format.c (format_path): New static.
(format_node,format_node_end): Handle new flags.
(mu_cfg_format_node): Clear MU_CFG_FMT_VALUE_ONLY if the
requested node is mu_cfg_node_statement.
* libmailutils/cfg/parser.y: Set node parents.
(mu_cfg_find_node): Fix coredump.
* mu/query.c: New options --value and --path.
2011-03-04 Sergey Poznyakoff <gray@gnu.org.ua>
Bugfixes.
* libmailutils/server/acl.c (_run_entry): Fix log output.
* mu/shell.c: Fix compilation without readline.
2011-02-19 Sergey Poznyakoff <gray@gnu.org.ua>
Minor changes.
* libmu_scm/Makefile.am (DOT_X_FILES, DOT_DOC_FILES): Add
mu_debug.x and mu_debug.doc.
* mail/send.c (fill_body): Remove extra \n after null message
body diagnostics.
2011-01-21 Sergey Poznyakoff <gray@gnu.org.ua>
Scheme: add primitives for manipulating the MU debug levels.
* include/mailutils/debug.h (mu_debug_get_iterator): New proto.
* libmailutils/diag/debug.c (mu_debug_get_iterator): New
function.
* libmu_scm/Makefile.am (lib_LTLIBRARIES): Add mu_debug.c.
* include/mailutils/guile.h (mu_scm_debug_init): New proto.
* libmu_scm/mu_scm.c (mu-register-format): Bugfix.
(mu_scm_init): Call mu_scm_debug_init.
2011-01-19 Sergey Poznyakoff <gray@gnu.org.ua>
Bugfix.
* libmailutils/base/amd.c: Add more debugging info. Always
check the return from amd_pool_open and amd_check_message
(which returns int now) and act accordingly.
2011-01-16 Sergey Poznyakoff <gray@gnu.org.ua>
Add useful debugging hooks.
* libmailutils/diag/bt.c: New file.
* libmailutils/diag/wd.c: New file.
* libmailutils/diag/Makefile.am (libdiag_la_SOURCES): Add bt.c
and wd.c
* include/mailutils/debug.h (mu_gdb_bt, mu_wd): New protos.
* include/mailutils/util.h (mu_getmaxfd): New protos.
* libmailutils/base/getmaxfd.c: New file.
* libmailutils/base/Makefile.am (libbase_la_SOURCES): Add
getmaxfd.c
* libmailutils/server/acl.c: Use mu_getmaxfd.
* libmailutils/stream/prog_stream.c: Likewise.
* mh/mh_whatnow.c: Likewise.
* libmu_scm/mu_body.c (mu-body?): Bugfix.
2011-01-15 Sergey Poznyakoff <gray@gnu.org.ua>
libmailutils: bugfix.
* libmailutils/mime/attachment.c (_attachment_setup): Remove
improper initialization of msg.
(mu_message_encapsulate): Initialize info->msg.
2011-01-15 Sergey Poznyakoff <gray@gnu.org.ua>
imap4d: redo signal handling.
Previously implemented way of signal handling was unsafe
because of the use of unsafe functions in signal handlers. It
also allowed for recursive invocations of MU calls not supposed
to handle recursion (such as mu_mailbox_expunge, for example).
This changeset fixes it.
* imap4d/imap4d.c (imap4d_child_signal_setup): Change signal
set.
(imap4d_mainloop): Set a jump point for signal handling.
Restore default handling for SIGILL, SIGBUS, SIGFPE, SIGSEGV,
SIGSTOP.
(master_jmp): New variable.
(imap4d_master_signal): New function.
(main): Redo signal handling.
* imap4d/imap4d.h (child_jmp): New extern.
(imap4d_enter_critical,imap4d_leave_critical): New protos.
* imap4d/signal.c (imap4d_master_signal): Move to imap4d.c
(imap4d_enter_critical,imap4d_leave_critical): New functions.
(imap4d_child_signal): Rewrite.
* imap4d/append.c: Protect critical sections.
* imap4d/bye.c: Likewise.
* imap4d/close.c: Likewise.
* imap4d/copy.c: Likewise.
* imap4d/delete.c: Likewise.
* imap4d/expunge.c: Likewise.
* imap4d/rename.c: Likewise.
* imap4d/select.c: Likewise.
* imap4d/status.c: Likewise.
* scheme/Makefile.am (sievemod_DATA): Add guimb.scmi.
2011-01-14 Sergey Poznyakoff <gray@gnu.org.ua>
imap4d: don't issue spurious unsolicited responses after
EXPUNGE.
* imap4d/expunge.c (imap4d_expunge): Clear attribute table
before resynching.
* imap4d/imap4d.h (imap4d_sync_invalidate): New extern.
* imap4d/sync.c (invalidate_attr_table): Rename to
imap4d_sync_invalidate; make extern. All callers updated.
2011-01-09 Sergey Poznyakoff <gray@gnu.org.ua>
imap4d: complement 435f1918df.
* imap4d/bye.c (imap4d_bye0): Set iostream to NULL, to avoid
further delivery of the SIGPIPE.
2011-01-08 Sergey Poznyakoff <gray@gnu.org.ua>
guimb: further improvements.
* libmu_scm/mu_body.c (mu-body?): New function.
* libmu_scm/mu_mailbox.c (mu-mailbox?): New function.
* libmu_scm/mu_message.c (mu-message?): New function.
* libmu_scm/mu_mime.c (mu-mime?): New function.
* scheme/guimb.scmi (guimb-process-mailbox): guimb-message
returns a message to be appended to the output mailbox.
2011-01-07 Sergey Poznyakoff <gray@gnu.org.ua>
Reincarnate guimb as a pure Scheme program.
* libmu_scm/mailutils.scm.in: Move to
libmu_scm/mailutils/mailutils.scm.in. Use the
MAILUTILS_SCM_LIBRARY_ROOT environment variable to load
libraries from the specified location (to be used in tests).
* libmu_scm/mailutils/.gitignore: New file.
* libmu_scm/mailutils/Makefile.am: New file.
* libmu_scm/Makefile.am (SUBDIRS): Add mailutils
(mailutils.scm): Remove goal and associated variables.
* scheme/guimb.scmi: New file. Reincarnation of guimb.
* scheme/Makefile.am: Build guimb from guimb.scmi.
* scheme/sieve2scm.scmi (sieve-version): Use mu-package and
mu-version global variables.
* configure.ac (AC_CONFIG_FILES): Add
libmu_scm/mailutils/Makefile.
2011-01-06 Sergey Poznyakoff <gray@gnu.org.ua>
Minor changes in scheme-related code.
* libmu_scm/mu_scm.c (_mu_scm_bugreport, mu-bugreport): New
variable.
(format_table): Add pops and imaps.
* scheme/reject.scm: Minor changes.
* scheme/sieve2scm.scmi: Minor changes.
2011-01-02 Sergey Poznyakoff <gray@gnu.org.ua>
Update copyright years.
Happy GNU year!
2010-12-31 Sergey Poznyakoff <gray@gnu.org.ua>
Remove guimb.
It was inoperational since 2009-03-27 and nobody complained, so
it seems to not be reclaimed at all. FWIW, it will be easy to
recreate it entirely in Scheme, should the need be.
* guimb/.gitignore: Remove.
* guimb/Makefile.am: Remove.
* guimb/collect.c: Remove.
* guimb/guimb.h: Remove.
* guimb/main.c: Remove.
* guimb/util.c: Remove.
* Makefile.am (GUIMB_DIR): Remove.
[MU_COND_LIBMU_SCM] (SCHEME_DIR): New variable.
(SUBDIRS): Add SCHEME_DIR instead of GUIMB_DIR.
* configure.ac (MU_GUILE_SIEVE_MOD_DATA): Remove substitution.
(AC_CONFIG_FILES): Remove guimb and guimb/scm, add scheme
* guimb/scm/.gitignore: move to scheme/.gitignore
* guimb/scm/Makefile.am: move to scheme/Makefile.am
* guimb/scm/README: move to scheme/README
* guimb/scm/mimeheader.scm: move to scheme/mimeheader.scm
* guimb/scm/numaddr.scm: move to scheme/numaddr.scm
* guimb/scm/redirect.scm: move to scheme/redirect.scm
* guimb/scm/reject.scm: move to scheme/reject.scm
* guimb/scm/sieve-core.scm: move to scheme/sieve-core.scm
* guimb/scm/sieve.scm.in: move to scheme/sieve2scm.scmi
* guimb/scm/vacation.scm: move to scheme/vacation.scm
2010-12-31 Sergey Poznyakoff <gray@gnu.org.ua>
imap4d: further improvements.
* imap4d/sync.c (notify): Do not emit FETCH replies for recent
messages.
2010-12-31 Sergey Poznyakoff <gray@gnu.org.ua>
imap4d: bugfixes.
* imap4d/imap4d.c (idle_timeout): Initialize to the default
value. (Needed for inetd mode)
* imap4d/sync.c: Revamp table handling.
2010-12-30 Sergey Poznyakoff <gray@gnu.org.ua>
Provide a function for quick retrieval of message lines.
* include/mailutils/message.h (mu_message_quick_lines): New
proto.
(mu_message_set_lines): Change signature of the 2nd argument.
* include/mailutils/sys/message.h (_mu_message) <lines>: Change
signature.
* libmailutils/diag/errors (MU_ERR_INFO_UNAVAILABLE): New error
code.
* libmailutils/mailbox/message.c (mu_message_set_lines): Change
signature of the 2nd argument.
(mu_message_lines): Update call to the _lines method.
(mu_message_quick_lines): New function.
* libproto/pop/mbox.c (_POP3_MSG_LINES): New flag.
(_pop3_message)<message_lines>: New member.
(pop_create_pop3_message): New function.
(pop_scan): Use LIST to obtain scan listing.
(pop_message_lines): New function.
(pop_create_message): Set _lines method.
(pop_get_message): Use pop_create_pop3_message.
* mail/from.c (hdr_quick_lines): New function.
(compile_headline): New escape %L
* pop3d/capa.c (pop3d_capa): Show XLINES capability if
configured.
* pop3d/list.c (pop3d_list): Optionally output the number of
lines in the message.
* pop3d/pop3d.c (pop3d_xlines): New global.
(pop3d_cfg_param): New statement "scan-lines".
* pop3d/pop3d.h (pop3d_xlines): New extern.
2010-12-29 Sergey Poznyakoff <gray@gnu.org.ua>
amd: bugfixes; speed up expunging.
* libmailutils/base/amd.c (_amd_message_delete): Remove.
(amd_array_expand): Fix element size.
(amd_array_shrink): Rewrite.
(amd_expunge): Shrink the array once, after everything has been
expunged. Generate MU_EVT_MAILBOX_MESSAGE_EXPUNGE for each
expunged message.
2010-12-29 Sergey Poznyakoff <gray@gnu.org.ua>
Make sure debugging calls don't dump core even if mu_strerr is
not initialized.
* libmailutils/diag/debug.c (mu_debug_log, mu_debug_log_begin):
Call mu_diag_init.
2010-12-29 Sergey Poznyakoff <gray@gnu.org.ua>
Bugfixes.
* libmailutils/url/create.c (_mu_url_create_internal): Fix
parsing of the '|' shortcuts.
* libmailutils/tests/url.at: Fix '|' test. Add 'prog://' test.
* movemail/movemail.c (set_program_id): Call
mu_stdstream_strerr_setup to flush changes.
* frm/common.c: Minor changes
2010-12-28 Sergey Poznyakoff <gray@gnu.org.ua>
frm: minor cleanup.
* frm/common.c (select_message, msg_index): Remove; use action
data instead.
(action): Use action data to get the selection function and
message index.
(frm_scan): Pass these data in action closure.
2010-12-28 Sergey Poznyakoff <gray@gnu.org.ua>
imap4d: speed up asynchronous mailbox notifications.
* imap4d/imap4d.h (util_format_attribute_flags): New prototype.
* imap4d/sync.c: Rewrite using flag table to keep attribute
flags, mu_mailbox_translate to convert uids to message numbers
and MU_EVT_MAILBOX_MESSAGE_EXPUNGE event to report expunged
messages.
* imap4d/util.c (_imap4d_attrlist): Remove \Recent
(util_attribute_to_type): Handle \Recent separately.
(util_format_attribute_flags): New function.
(util_print_flags): Rewrite as an extra entry point to the
above.
mailboxes: New event MU_EVT_MAILBOX_MESSAGE_EXPUNGE.
* include/mailutils/observer.h: Rearrange and partially rename
event constants (all uses updated): MU_EVT_MESSAGE_APPEND =>
MU_EVT_MAILBOX_MESSAGE_APPEND MU_EVT_AUTHORITY_FAILED =>
MU_EVT_FOLDER_AUTHORITY_FAILED
(MU_EVT_MAILBOX_MESSAGE_EXPUNGE): New event.
* libproto/mbox/mbox.c: Generate
MU_EVT_MAILBOX_MESSAGE_EXPUNGE.
* libproto/pop/mbox.c: Likewise.
* libmailutils/base/amd.c: Likewise.
2010-12-28 Sergey Poznyakoff <gray@gnu.org.ua>
mh,maildir: speed up scanning.
* include/mailutils/sys/amd.h (_amd_message_append, amd_sort):
New protos.
* libmailutils/base/amd.c (amd_array_expand): Call memmove only
if there is actually something to move.
(_amd_message_append, amd_sort): New functions.
* libproto/maildir/mbox.c (maildir_scan_dir): Append new
messages to the end of the array, and sort it afterward. This
avoids unnecessary memory moves, which improves performance
considerably, especially on large mailboxes.
* libproto/mh/mbox.c (mh_scan0): Likewise.
2010-12-28 Sergey Poznyakoff <gray@gnu.org.ua>
Various fixes.
* libmu_sieve/extensions/vacation.c (build_mime): Remove
superfluous seek.
(test_and_update_prop): days==0 means "forever", i.e. send a
replay to each user only once.
(vacation_reply): If :file tag is given, treat the argument as
the name of a file containing the reply message.
(vacation_tags): Add "sender" and "file" tags.
* libmu_sieve/extensions/moderator.c: Always unref transport
stream after passing it to mu_stream_to_message.
* maidag/lmtp.c: Likewise.
* mh/mh_stream.c: Likewise.
* mh/prompter.c: Likewise.
* mh/burst.c (flush_stream): Remove extra unref.
* sieve/sieve.c: Likewise.
* testsuite/smtpsend.c: Likewise.
2010-12-27 Sergey Poznyakoff <gray@gnu.org.ua>
vacation: remove dependency on DBM; other minor fixes.
* libmu_sieve/extensions/vacation.c: Use _sget accessors where
possible. Use mu_property_t instead of db database.
* libmu_sieve/sieve.y (mu_sieve_get_mailer): Verbosely report
errors.
* libmailutils/base/locker.c (mu_locker_create): Create the
locker if the file name part of its full name does not exist.
2010-12-26 Sergey Poznyakoff <gray@gnu.org.ua>
Bugfixes.
* libmu_auth/tls.c (_tls_ioctl): Fix typo (opcode used instead
of code).
* mu/filter.c (mutool_filter): Reference mu_strin to prevent it
from destroying.
* testsuite/smtpsend.c (main): Call mu_stdstream_setup.
2010-12-25 Sergey Poznyakoff <gray@gnu.org.ua>
pop client and movemail: bugfixes.
* libproto/pop/mbox.c (pop_close): Destroy the cached data.
(pop_destroy): Avoid freeing the same data twice.
(pop_body_get_stream,pop_body_size,pop_body_lines): Owner is
mu_message_t.
(pop_create_body): Change the owner of the created mu_body_t
object.
* movemail/movemail.c: Correctly close both mailboxes if
unhandled errors occur.
2010-12-24 Sergey Poznyakoff <gray@gnu.org.ua>
Minor bugfix.
* mail/escape.c (run_editor): Fix a typo.
2010-12-23 Sergey Poznyakoff <gray@gnu.org.ua>
movemail: minor improvements.
* libmailutils/base/list.c (list_itrctl): Accept
mu_itrctl_set_direction and mu_itrctl_qry_direction even if
mu_iterator_first has not been called yet.
* movemail/movemail.c: Rewrite using iterators.
* libmailutils/mailer/mailer.c (safe_address_create): Bugfix.
2010-12-23 Sergey Poznyakoff <gray@gnu.org.ua>
Bugfix (complements 6bd92d3c07).
* libmu_sieve/util.c (mu_sieve_error, mu_sieve_debug)
(mu_sieve_log_action): Format location only if locus.mu_file is
not NULL.
2010-12-23 Sergey Poznyakoff <gray@gnu.org.ua>
mailbox iterator: implement reverse direction and itrctl.
* libmailutils/mailbox/mbxitr.c (mailbox_iterator)<backwards>:
New member.
(mbx_first): Position to the last message if itr->backwards is
set.
(mbx_next): Decrement index if itr->backwards is set.
(mbx_finished_p): Take into account iteration direction.
(mbx_itrctl): new method.
(mu_mailbox_get_iterator): Set itrctl method.
2010-12-23 Sergey Poznyakoff <gray@gnu.org.ua>
movemail: various improvements.
New configuration options allow to specify the maximum number
of messages to be copied and control the actions of movemail
when an error occurs while appending a message.
* movemail/movemail.c (ONERROR_OPTION,MAX_MESSAGES_OPTION): New
option codes.
(options): New options --onerror and --max-messages.
(max_messages_option, onerror_flags): New variable.
(ONERROR_SKIP, ONERROR_DELETE, ONERROR_COUNT): New defines.
(parse_opt): Handle ONERROR_OPTION.
(cb_onerror): New callback.
(movemail_cfg_param): New configuration statements:
"max-messages" and "onerror".
(move_message): Delete the message if ONERROR_DELETE is set.
(main): Handle the limit on the number of processed messages
and onerror flags. Use mu_mailbox_expunge instead of
mu_mailbox_flush. This preserves the attributes of not
processed options (in case max_messages_option is not 0) and
speeds up the things considerably, especially on huge
mailboxes.
2010-12-23 Sergey Poznyakoff <gray@gnu.org.ua>
mailer: minor improvement.
Be more liberal when guessing sender and recipient names.
Tolerate deviations from RFC822.
* libmailutils/mailer/mailer.c (copy_fragment)
(recover_email, safe_address_create): New functions.
(_set_from, _set_to): Use safe_address_create.
2010-12-23 Sergey Poznyakoff <gray@gnu.org.ua>
Bugfixes.
* frm/common.c [!HAVE_LIBFRIBIDI] (puts_bidi): Fix definition.
* libproto/pop/mbox.c (pop_destroy): Fix coredump (occurred if
the mailbox has not been scanned).
2010-12-23 Sergey Poznyakoff <gray@gnu.org.ua>
Bugfixes.
* libmailutils/base/lcall.c (mu_parse_lc_all): Allow for
arg==NULL.
* mh/Makefile.am: Define mhlibdir.
* mh/pick.y (match_header): Use sget accessors.
* mh/repl.c: Accept -noquery silently.
2010-12-23 Sergey Poznyakoff <gray@gnu.org.ua>
mail: fix the "shell" ("!") command.
* mail/mail.h (mail_execute): Change signature. All callers
updated.
* mail/shell.c (expand_bang): Change signature. Take the string
to be expanded as the 2nd and the last command as 3rd
arguments. Always allocate the return string, even if there's
nothing to expand.
(mail_execute): fix memory management.
* mail/escape.c: Update.
* mail/escape.c: Update calls to mail_execute.
2010-12-23 Sergey Poznyakoff <gray@gnu.org.ua>
Follow-up to the previous commit.
* libmu_sieve/util.c: Update.
2010-12-23 Sergey Poznyakoff <gray@gnu.org.ua>
Bugfixes.
* libmailutils/stream/logstream.c (_log_ctl): Handle
MU_IOCTL_SYSLOGSTREAM, pass it to the transport stream.
* libmu_sieve/sieve.l (pop_source): Restore input_stream.
* libmu_sieve/util.c (mu_sieve_error, mu_sieve_debug)
(mu_sieve_log_action): Set location information on the
errstream.
2010-12-23 Sergey Poznyakoff <gray@gnu.org.ua>
sieve: test "list" extension test.
* sieve/tests/list.at: New file.
* sieve/tests/Makefile.am (TESTSUITE_AT): Add list.at.
* sieve/tests/testsuite.at: Include list.at.
2010-12-22 Sergey Poznyakoff <gray@gnu.org.ua>
Improve debug parser and output functions.
New parser accepts range specifications (mailbox.trace3-prot).
mu_debug_format_spec outputs specs in the canonical form.
* include/mailutils/debug.h (MU_DEBUG_LEVEL_RANGE): New macro.
(mu_debug_set_category_level): Change return type to int.
(mu_debug_get_category_level): New proto.
* libmailutils/diag/debug.c (mu_debug_set_category_level):
Change return type to int.
(mu_debug_get_category_level): New function.
(mu_debug_level_from_string): New function.
(parse_spec): Accept range specification. Negation at the start
of spec implies 'proto'.
(mu_debug_format_spec): Rewrite.
* libmailutils/tests/debugspec.c: New file.
* libmailutils/tests/debugspec.at: New file.
* libmailutils/tests/Makefile.am (noinst_PROGRAMS): Add
debugspec.
(TESTSUITE_AT): add debugspec.at
* libmailutils/tests/testsuite.at: Include debugspec.at.
* libmailutils/tests/.gitignore: Add debugspec.
* sieve/sieve.c: Do not advertise 'T' and 'P' arguments to
--debug.
(debug_level): Remove.
(set_debug_level): Rewrite the handling of legacy debug
specifiers 'TP'.
2010-12-22 Sergey Poznyakoff <gray@gnu.org.ua>
Improve debugging; fix c522de119a.
* include/mailutils/types.hin (mu_debug_handle_t)
(mu_debug_level_t): New data types.
* include/mailutils/debug.h (mu_debug_level_p)
(mu_debug_category_level)
(mu_debug_set_category_level): Change argument types to
mu_debug_handle_t/mu_debug_level_t.
* libmailutils/diag/debug.c: Likewise.
* libmailutils/server/acl.c (_run_entry): Call mu_debug_log_nl
instead of mu_debug_log_end with an empty format string.
* include/mailutils/sieve.h
* libmailutils/filter/base64.c
* libmailutils/stream/stream.c
* libmu_sieve/conf.c
* libmu_sieve/extensions/spamd.c
* libmu_sieve/sieve.y
* sieve/sieve.c: Commit the changes c522de119a failed to
commit.
2010-12-22 Sergey Poznyakoff <gray@gnu.org.ua>
Bugfixes.
* libmailutils/filter/iconvflt.c (_icvt_decoder): Do not
iconv_close if cd is -1.
* mh/mboxprop.c (mh_mailbox_get_cur): Ignore whitespace
following the cur value.
2010-12-22 Sergey Poznyakoff <gray@gnu.org.ua>
Minor fixes.
* libmu_sieve/extensions/pipe.c: Include sys/wait.h
* testsuite/Makefile.am: Distribute testsuite.inc
2010-12-22 Sergey Poznyakoff <gray@gnu.org.ua>
filter stream: make sure all input data get processed.
* include/mailutils/filter.h (MU_FILTER_MAX_AGAIN): Add a
comment.
* libmailutils/stream/fltstream.c (filter_read): Use mu_debug
on the filter.error level, instead of plain mu_error. If the
xcoder returns OK and does not consume all input when
processing the last buffer, assume mu_filter_again. Fix loop
condition.
(filter_write_internal): Use mu_debug on the filter.error
level, instead of plain mu_error.
2010-12-22 Sergey Poznyakoff <gray@gnu.org.ua>
sieve: bugfixes.
* include/mailutils/sieve.h (mu_sieve_debug_handle): New
declaration.
(mu_sieve_debug_init): New prototype.
* libmu_sieve/conf.c (mu_sieve_debug_handle): New global.
(mu_sieve_module_init): Call mu_sieve_debug_init.
* libmu_sieve/extensions/spamd.c (spamd_connect_tcp)
(spamd_connect_socket): Fix stream creation.
(spamd_send_message): Switch to full buffering on the transport
stream and indicate it is a payload (in case transcript is
enabled), before copying data. Restore things to their original
state afterward.
(spamd_read_line): Rewrite using mu_stream_getline.
(decode_float): Additional argument endp. Unless NULL, store
there the position in the input string where the parsing has
stopped.
(parse_response_line): New function.
(spamd_test): Rewrite using new API.
* sieve/sieve.c (parser): --dry-run implies --verbose.
* libmailutils/filter/base64.c (_base64_decoder): when not
enough data are available and cmd is not mu_filter_lastbuf,
return mu_filter_lastbuf.
* libmailutils/stream/stream.c (mu_stream_shutdown): Flush the
buffers before shutting the transport down.
* libmailutils/tests/fltst.c (main): New option bufsize=
2010-12-22 Sergey Poznyakoff <gray@gnu.org.ua>
Set library version to 4:0:0.
2010-12-22 Sergey Poznyakoff <gray@gnu.org.ua>
sieve: implement an option to add directory to the head of the
library search path.
* TODO: Update.
* include/mailutils/sieve.h (mu_sieve_library_path_prefix): New
variable.
* libmu_argp/sieve.c (sieve_argp_option): New option
--libdir-prefix.
(sieve_argp_parser): Handle --libdir-prefix.
* libmu_cfg/sieve.c (cb_library_path_prefix): New callback.
(mu_sieve_param): New statement "library-path-prefix".
* libmu_sieve/conf.c (mu_sieve_library_path_prefix): New
variable.
(mu_sieve_module_init): Process prefix paths. Do not call
mu_sv_load_add_path.
* libmu_sieve/load.c (sieve_init_load_path): Rewrite.
(mu_sv_load_add_path): Remove.
* libmu_sieve/sieve-priv.h (mu_sv_load_add_path): Remove
declaration.
(sieve_searchpath): Remove the unused "add" parameter.
* sieve/tests/moderator.at: Use MUT_SIEVE_OPTIONS in all tests.
* sieve/tests/testsuite.at (MUT_SIEVE_EXT_TEST): Use
--libdir-prefix option to ensure that our version of the
extension appears first in the path.
2010-12-22 Sergey Poznyakoff <gray@gnu.org.ua>
Pop3-client bugfixes (mostly).
* libmailutils/stream/fltstream.c (filter_ctl):
MU_IOCTL_TRANSPORT returns filter transport stream.
* libproto/pop/pop3_rdlist.c (mu_pop3_stream_to_list): Make
sure status is initialized and reflects the actual status.
* libproto/pop/pop3_stream.c (mu_pop3_filter_create): Do not
unref transport stream, it is done by the caller.
2010-12-21 Sergey Poznyakoff <gray@gnu.org.ua>
Minor fixes.
* am/enable.m4 (MU_ENABLE_SUPPORT): Add the additional-cond
argument.
(MU_ENABLE_BUILD): Likewise.
* configure.ac: Update 4th args in calls to MU_ENABLE_SUPPORT.
Do not use MU_ENABLE_BUILD within conditionals, use
additional-cond instead.
* libmailutils/stream/mapfile_stream.c: Include sys/stat.h
2010-12-20 Sergey Poznyakoff <gray@gnu.org.ua>
Assorted changes.
* include/mailutils/debug.h (mu_debug_format_spec): New
function.
* include/mailutils/stream.h (MU_IOCTL_SYSLOGSTREAM)
(MU_IOCTL_FILTER): New ioctls.
(MU_IOCTL_LOGSTREAM_GET_SEVERITY_MASK)
(MU_IOCTL_LOGSTREAM_SET_SEVERITY_MASK)
(MU_IOCTL_LOGSTREAM_CLONE) (MU_IOCTL_SYSLOGSTREAM_SET_LOGGER)
(MU_IOCTL_SYSLOGSTREAM_GET_LOGGER)
(MU_IOCTL_FILTER_GET_DISABLED)
(MU_IOCTL_FILTER_SET_DISABLED): And their opcodes.
* include/mailutils/sys/filter.h (_MU_FILTER_DISABLED)
(_MU_FILTER_EOF): New defines.
(_mu_filter_stream) <eof>: Replace with fltflag (a bitmask).
* include/mailutils/sys/logstream.h (_mu_log_stream) <sevmask>:
New member.
* include/mailutils/sys/syslogstream.h (_mu_syslog_stream)
<logger>: New member.
* include/mailutils/util.h (mu_onexit_run): New proto.
* libmailutils/base/onexit.c (_mu_onexit_run): Extra safety
check.
(mu_onexit_run): New function.
(mu_debug_level_str): New static.
(mu_debug_format_spec): New function.
* libmailutils/stream/fltstream.c (filter_read, filter_write):
Bypass the xcoder if _MU_FILTER_DISABLED is set. Use fltflag
instead of the removed eof.
(filter_ctl): Handle MU_IOCTL_FILTER.
* libmailutils/stream/logstream.c (_log_write): The sevmask
member masks out severity prefix output for certain severities.
(_log_ctl): Handle new opcodes (see above).
* libmailutils/stream/syslogstream.c (_syslog_stream_write):
Use <logger>, if supplied, instead of the system syslog(3).
(_syslog_ctl): Handle MU_IOCTL_SYSLOGSTREAM.
(mu_syslog_stream_create): Initialize logger to NULL.
* mu/ldflags.c (lib_descr): Protect entries with the
corresponding #ifdef ENABLE_whatever.
2010-12-19 Sergey Poznyakoff <gray@gnu.org.ua>
Update TODO.
2010-12-19 Sergey Poznyakoff <gray@gnu.org.ua>
maildir: speed up mailbox scanning.
* include/mailutils/sys/amd.h (_amd_message_lookup_or_insert):
New proto.
* libmailutils/base/amd.c (_amd_message_lookup_or_insert): New
function.
(_amd_message_insert): Rewrite using
_amd_message_lookup_or_insert.
* libproto/maildir/mbox.c (maildir_message_cmp): Stop
comparison on ':'.
(maildir_message_lookup): Remove.
(maildir_scan_dir): Use _amd_message_lookup_or_insert.
* po/POTFILES.in: Update.
2010-12-19 Sergey Poznyakoff <gray@gnu.org.ua>
Minor fixes.
* include/mailutils/debug.h (mu_debug_log_nl): New proto.
* libmailutils/diag/debug.c (mu_debug_log_nl): New function.
* libmailutils/mailer/progmailer.c: Use mu_debug_log_nl.
* libmailutils/server/acl.c: Likewise. Also, use
MU_DEBUG_TRACE9 instead of the numeric value.
* libmailutils/filter/iconvflt.c (_iconv_filter): Register
encoder (same as decoder).
2010-12-19 Wojciech Polak <polak@gnu.org>
Remove more old debug leftovers from the Python interface.
2010-12-19 Sergey Poznyakoff <gray@gnu.org.ua>
sieve: improve "pipe" action, implement "pipe" test.
* libmu_sieve/extensions/pipe.c: Allow to specify which parts
of the message should be piped. Implement "pipe" test.
* sieve/tests/pipeact.at: New file.
* sieve/tests/pipetest.at: New file.
* sieve/tests/Makefile.am (TESTSUITE_AT): Add pipeact.at and
pipetest.at
* sieve/tests/testsuite.at: Include pipeact.at and pipetest.at
(MUT_SIEVE_EXT_TEST): Redefine MUT_SIEVE_OPTIONS. Set envar
"cwd". Use cat and heredoc to create prog, instead of using
AT_DATA.
* sieve/tests/moderator.at: Update to these changes.
2010-12-18 Sergey Poznyakoff <gray@gnu.org.ua>
libmu_sieve: minor fix.
* libmu_sieve/util.c (mu_sieve_error): Fix typo.
2010-12-17 Sergey Poznyakoff <gray@gnu.org.ua>
sieve: improve moderator extension.
* libmu_sieve/extensions/moderator.c: Implement the :program
tag. Use _sget_ functions to reduce memory requirements.
* sieve/tests/moderator.mbox: New file.
* sieve/tests/moderator.at: New file.
* sieve/tests/Makefile.am (EXTRA_DIST): Add moderator.mbox.
(TESTSUITE_AT): Add moderator.at
* sieve/tests/testsuite.at (MUT_SIEVE_EXT_NAME): New define.
(MUT_SIEVE_EXT_TEST): New macro. Include moderator.at.
2010-12-17 Sergey Poznyakoff <gray@gnu.org.ua>
Minor change.
* imap4d/util.c (set_xscript_level): Fix typo.
2010-12-17 Sergey Poznyakoff <gray@gnu.org.ua>
Improve debugging in the category "auth".
* libmailutils/auth/mu_auth.c: Fix mu_debug calls. Use
different levels.
Remove --debug-auth option. Users should use --debug-level=auth
instead.
* libmu_argp/auth.c: Remove.
* libmu_argp/Makefile.am (libmu_argp_a_SOURCES): Remove auth.c
* include/mailutils/libargp.h (mu_auth_cmdline): Remove.
* libmu_argp/cmdline.c (all_cmdline_capa): Remove
mu_auth_cmdline.
2010-12-16 Sergey Poznyakoff <gray@gnu.org.ua>
Mark unfinished interfaces as experimental so they're not built
by default.
* am/enable.m4 (MU_ENABLE_SUPPORT): Fix the usage of the last
argument.
* configure.ac: Check for --enable-experimental before any
other checks. Mark cxx, python and nntp as experimental.
* mh/tests/mhn.at: Make sure all mailboxes are writable.
* mh/tests/testsuite.at (MTSTAILOR): Fix mailer URL.
* po/POTFILES.in: Comment out unused sources.
2010-12-16 Sergey Poznyakoff <gray@gnu.org.ua>
Remove the leftovers of mu_debug_t and obsoleted sieve
interfaces.
* include/mailutils/cpp/debug.h: Remove.
* include/mailutils/cpp/Makefile.am (cppinclude_HEADERS):
Remove debug.h
* libmu_cpp/debug.cc: Remove
* libmu_cpp/Makefile.am (libmu_cpp_la_SOURCES): Remove
debug.cc.
* python/libmu_py/debug.c: Remove.
* python/libmu_py/Makefile.am (libmu_py_la_SOURCES): Remove
debug.c
* include/mailutils/cpp/mailbox.h: Remove objects and methods
derived from mu_debug_t.
* include/mailutils/cpp/mailer.h: Likewise.
* include/mailutils/cpp/stream.h: Likewise.
* libmu_cpp/mailbox.cc: Likewise.
* libmu_cpp/mailer.cc: Likewise.
* libmu_cpp/sieve.cc: Likewise. Ditto for mu_sieve_printf_t,
mu_sieve_parse_error_t.
* include/mailutils/cpp/sieve.h: Likewise.
* libmu_cpp/stream.cc: Remove objects and methods derived from
mu_debug_t.
(ProgStream::ProgStream): Use mu_command_stream_create (see
FIXME).
(FilterProgStream::FilterProgStream): Rewrite.
* include/mailutils/python.h: Remove objects and methods
derived from mu_debug_t.
* python/libmu_py/filter.c (api_filter_iconv_create): Rewrite
using mu_filter_create_args.
* python/libmu_py/libmu_py.c: Likewise.
* python/libmu_py/libmu_py.h: Likewise.
* python/libmu_py/mailbox.c: Likewise.
* python/libmu_py/mailer.c: Likewise.
* python/libmu_py/stream.c: Likewise.
* python/libmu_py/url.c: Likewise.
* python/libmu_py/sieve.c: Likewise. Same for
mu_sieve_printf_t, mu_sieve_parse_error_t.
2010-12-13 Sergey Poznyakoff <gray@gnu.org.ua>
Remove mu_filter_iconv_create.
Callers should use mu_filter_create_args instead.
* examples/iconv.c: Rewrite using mu_filter_create_args.
* libmailutils/mime/mimehdr.c (mu_mimehdr_decode_param): Use
mu_decode_filter.
* imap4d/imap4d.h: Include prog.h
* include/mailutils/filter.h (mu_filter_iconv_create): Mark as
deprecated.
* include/mailutils/util.h (mu_decode_filter_args): New proto.
* libmailutils/base/msgid.c (mu_rfc2822_in_reply_to): Silence a
cast warning.
* libmailutils/tests/wicket.c (match_string): Likewise.
* libmailutils/filter/decode.c (mu_decode_filter_args): New
function.
(mu_decode_filter): Rewrite as an alternative entry point to
mu_decode_filter_args.
* ibmailutils/filter/filter_iconv.c: Remove.
* libmailutils/filter/Makefile.am (libfilter_la_SOURCES):
Remove filter_iconv.c
* libmu_compat/filter_iconv.c: New file.
* libmu_compat/Makefile.am (libmu_compat_la_SOURCES): Add
filter_iconv.c
* libmailutils/filter/iconvflt.c (_icvt_decoder): Set errcode
before returning failure.
* libmailutils/stream/fltstream.c (init_iobuf,
filter_stream_init): Provide a default value for io->errcode.
2010-12-13 Sergey Poznyakoff <gray@gnu.org.ua>
Re-implement iconv converter as a regular filter.
* include/mailutils/filter.h (mu_iconv_filter): New extern.
* libmailutils/filter/iconvflt.c: New file.
* libmailutils/filter/Makefile.am (libfilter_la_SOURCES): Add
iconvflt.c
* libmailutils/filter/filter.c (mu_filter_get_list): Register
mu_iconv_filter.
2010-12-11 Sergey Poznyakoff <gray@gnu.org.ua>
Remove an ugly debugging hack.
2010-12-11 Sergey Poznyakoff <gray@gnu.org.ua>
Minor fixes.
* libmailutils/base/argcvjoin.c (mu_argcv_join): Fix a memory
allocation error.
* libmailutils/base/msgid.c (concat): Remove.
(mu_rfc2822_references,mu_rfc2822_in_reply_to): Use
mu_argcv_join to concatenate strings.
2010-12-11 Sergey Poznyakoff <gray@gnu.org.ua>
mh,maildir: Minor fix.
* libmailutils/base/amd.c (amd_envelope_date): Remove the
trailing newline from the ctime output.
2010-12-11 Sergey Poznyakoff <gray@gnu.org.ua>
mail: use mu_strout; remove util_error in favor of mu_error.
2010-12-11 Sergey Poznyakoff <gray@gnu.org.ua>
mail: rewrite using MU streams.
* libmailutils/base/spawnvp.c (mu_spawnvp): Use fork and _exit,
unconditionally.
* libmailutils/stdstream/basestr.c (mu_stdstream_setup): Borrow
descriptors 0, 1, 2.
* mail/mail.h (compose_env) <filename, file, ofile>: Remove.
<compstr>: New member.
* mail/alias.c: Use MU streams instead of stdlib.
* mail/alt.c: Likewise.
* mail/copy.c: Likewise.
* mail/decode.c: Likewise.
* mail/echo.c: Likewise.
* mail/envelope.c: Likewise.
* mail/eq.c: Likewise.
* mail/escape.c: Likewise.
* mail/followup.c: Likewise.
* mail/from.c: Likewise.
* mail/inc.c: Likewise.
* mail/mail.c: Likewise.
* mail/mailline.c: Likewise.
* mail/mailvar.c: Likewise.
* mail/msgset.y: Likewise.
* mail/print.c: Likewise.
* mail/quit.c: Likewise.
* mail/reply.c: Likewise.
* mail/retain.c: Likewise.
* mail/send.c: Likewise.
* mail/setenv.c: Likewise.
* mail/shell.c: Likewise.
* mail/size.c: Likewise.
* mail/source.c: Likewise.
* mail/summary.c: Likewise.
* mail/top.c: Likewise.
* mail/unset.c: Likewise.
* mail/util.c: Likewise.
* mail/version.c: Likewise.
* mail/write.c: Likewise.
* mail/z.c: Likewise.
2010-12-11 Sergey Poznyakoff <gray@gnu.org.ua>
Minor change.
* libmailutils/stream/stream.c (mu_stream_set_stat): Allow for
statbuf==NULL.
2010-12-11 Sergey Poznyakoff <gray@gnu.org.ua>
Implement mu_onexit functions; use MU stdstream in mh and
mimeview.
* include/mailutils/types.hin (mu_onexit_t): New typedef.
* include/mailutils/util.h (mu_onexit_reset, mu_onexit): New
protos.
* libmailutils/base/onexit.c: New file.
* libmailutils/base/Makefile.am (libbase_la_SOURCES): Add
onexit.c
* libmailutils/stdstream/basestr.c (stdstream_flushall): New
function.
(mu_stdstream_setup): Rewrite the fd checking algorithm.
Register stdstream_flushall as an onexit function.
* mh/anno.c: Use MU stdstream.
* mh/mh.h: Include mailutils/stdstream.h.
* mh/mh_init.c (mh_init): Call mu_stdstream_setup; use MU
stdstream.
* mh/mh_whatnow.c (_whatnow): Use MU stdstream.
* mh/mhl.c (open_output,list_message): Likewise.
* mh/mhn.c (mhn_show,store_handler): Likewise.
* pop3d/popauth.c: Use MU stdstream.
* mimeview/mimetypes.y: Use MU stdstream.
* mimeview/mimeview.c: Likewise.
(mimeview_fp): Remove.
(mimeview_stream): New variable.
* mimeview/mimeview.h (mimeview_fp): Remove.
(mimeview_stream): New variable.
* lib/mailcap.c (find_entry): Don't report ENOENT.
2010-12-10 Sergey Poznyakoff <gray@gnu.org.ua>
Remove the MU_STREAM_FD_AUTOCLOSE stream flag.
This is the default behavior now. The reverse can be requested
by a special MU_IOCTL_FD,MU_IOCTL_FD_SET_BORROW ioctl.
* include/mailutils/stream.h (MU_STREAM_FD_AUTOCLOSE): Remove.
This is the default behavior now.
(MU_IOCTL_FD): New ioctl.
(MU_IOCTL_FD_GET_BORROW, MU_IOCTL_FD_SET_BORROW): New opcodes.
* include/mailutils/sys/file_stream.h
(_MU_FILE_STREAM_FD_BORROWED): New flag.
* libmailutils/stream/file_stream.c (fd_close): Close the fd
unless _MU_FILE_STREAM_FD_BORROWED bit is set.
(fd_open): Clear the _MU_FILE_STREAM_FD_BORROWED bit.
(fd_ioctl): Handle MU_IOCTL_FD.
(mu_file_stream_create): Remove MU_STREAM_FD_AUTOCLOSE.
* ibmailutils/base/version.c (mu_print_options): Set borrow
mode on the temporary stdout stream.
* libmailutils/cfg/driver.c (mu_cfg_tree_reduce): Set borrow
mode on the temporary stderr stream.
* libmailutils/stdstream/strerr.c (mu_stdstream_strerr_create):
Set borrow mode on the stderr stream.
* libmailutils/tests/tempfile.c: set borrow mode on the
temporary stream, because it may be reopened later (verify
mode).
* examples/mta.c: Remove MU_STREAM_FD_AUTOCLOSE.
* imap4d/io.c: Likewise.
* libmailutils/stream/prog_stream.c: Likewise.
* libmailutils/stream/socket_stream.c: Likewise.
* libmailutils/stream/temp_file_stream.c: Likewise.
* maidag/lmtp.c: Likewise.
* pop3d/extra.c: Likewise.
These will disappear when the corresponding utilities are
rewritten to use MU stdstream:
* mail/escape.c (quote0): set borrow mode on the output stream.
* mimeview/mimeview.c (display_file): set borrow mode on the
input stream.
Likewise, these will disappear when MH uses MU stdstream:
* mh/anno.c (main): Set borrow mode on the input stream.
* mh/mh_init.c (mh_real_install): Likewise.
* mh/mh_whatnow.c (_whatnow): Likewise.
* mh/mhl.c (open_output): Set borrow mode on the output stream.
* mh/mhn.c (mhn_show,store_handler): Likewise.
2010-12-10 Sergey Poznyakoff <gray@gnu.org.ua>
Remove MU_STREAM_AUTOCLOSE flag. Use mu_stream_unref, if
necessary.
* examples/mta.c: Use MU_STREAM_FD_AUTOCLOSE.
* imap4d/io.c: Likewise.
* libmailutils/stream/file_stream.c: Likewise.
* libmailutils/stream/prog_stream.c: Likewise.
* libmailutils/stream/socket_stream.c: Likewise.
* libmailutils/stream/temp_file_stream.c: Likewise.
* maidag/lmtp.c: Likewise.
* pop3d/extra.c: Likewise.
* imap4d/preauth.c: Do not use MU_STREAM_AUTOCLOSE. Instead
unref the transport stream after creating the derived one.
* libmailutils/base/rfc2047.c: Likewise.
* libmailutils/stream/fltstream.c: Likewise.
* libmailutils/tests/fltst.c: Likewise.
* libmu_auth/ldap.c: Likewise.
* libmu_auth/tls.c: Likewise.
* libmu_sieve/extensions/vacation.c: Likewise.
* libproto/pop/pop3_stream.c: Likewise.
* mail/decode.c: Likewise.
* mh/mhn.c: Likewise.
* libmailutils/filter/filter_iconv.c: Do not handle
MU_STREAM_AUTOCLOSE.
* libmailutils/stream/rdcache_stream.c: Likewise.
* libmailutils/stream/streamref.c: Likewise.
* libmailutils/stream/xscript-stream.c: Likewise.
* include/mailutils/stream.h (MU_STREAM_AUTOCLOSE): Rename to
MU_STREAM_FD_AUTOCLOSE.
2010-12-09 Sergey Poznyakoff <gray@gnu.org.ua>
Implement filter chains. Revamp filter output length support.
* include/mailutils/filter.h (mu_filter_chain_create_pred)
(mu_filter_chain_create): New prototypes.
(_mu_filter_record)<max_line_length>: Remove.
* libmailutils/filter/fltchain.c: New file.
* libmailutils/filter/Makefile.am (libfilter_la_SOURCES): Add
fltchain.c.
* libmailutils/filter/base64.c: Implement line length limit for
encoder.
(base64_state): New enum.
(base64_line): New struct.
(_base64_encoder): xd brings a pointer to struct base64_line.
Use it to limit the output line length.
(alloc_state): New function.
(_base64_filter): Register alloc_state.
(_base64_filter, _B_filter): Remove max_line_length
initialization.
* libmailutils/filter/binflt.c: Remove max_line_length
initialization.
* libmailutils/filter/crlfflt.c: Likewise.
* libmailutils/filter/dot.c: Likewise.
* libmailutils/filter/fromflt.c: Likewise.
* libmailutils/filter/header.c: Likewise.
* libmailutils/filter/inline-comment.c: Likewise.
* libmailutils/filter/linecon.c: Likewise.
* libmailutils/filter/qpflt.c: Likewise.
* libmailutils/filter/linelenflt.c: Redo line filter as a
regular filter.
(mu_linelen_filter): New global.
* libmailutils/filter/filter.c (mu_filter_get_list): Register
mu_linelen_filter.
(filter_create_rd, filter_create_wr): Remove.
(mu_filter_create_args): Use mu_filter_stream_create directly.
* examples/base64.c: Re-implement the -l option via filter
chains.
* libmailutils/tests/fltst.c: Remove the linelen option.
* libmailutils/tests/base64d.at: Remove the linelen option from
fltst invocations.
* mu/filter.c: Remove the --line-length option. Not needed now,
its effect is achieved by "FLT + [~]linelen" chain.
2010-12-08 Sergey Poznyakoff <gray@gnu.org.ua>
Minor improvement.
* examples/config/dot.biffrc: Update.
* comsat/comsat.c (main): In test mode, normalize biffrc names
that begin with ./ or ../
2010-12-08 Sergey Poznyakoff <gray@gnu.org.ua>
comsat: provide a fine-grained control over where biffrc errors
are output.
* comsat/comsat.c (biffrc_errors): New variable.
(comsat_cfg_param): New statements: biffrc-errors-to-tty and
biffrc-errors-to-err
(main): In test mode, set biffrc_errors to
BIFFRC_ERRORS_TO_ERR.
* comsat/comsat.h (BIFFRC_ERRORS_TO_TTY)
(BIFFRC_ERRORS_TO_ERR): New flags.
(biffrc_errors): New variable.
* comsat/action.c (report_error): Consult biffrc_errors.
2010-12-08 Sergey Poznyakoff <gray@gnu.org.ua>
Minor improvements in logstream and related code.
* include/mailutils/stream.h
(MU_IOCTL_LOGSTREAM_SET_LOCUS_LINE)
(MU_IOCTL_LOGSTREAM_SET_LOCUS_COL): New subcodes.
* libmailutils/stream/logstream.c (_log_ctl): Handle two new
subcodes.
* comsat/action.c (eval_biffrc): Use new ioctl subcode to
update the line number.
2010-12-08 Sergey Poznyakoff <gray@gnu.org.ua>
Test line info facility.
* libmailutils/tests/inline-comment.at: Add line info tests.
* libmailutils/tests/linecon.at: Likewise.
* libmailutils/filter/linecon.c (LINECON_CONTINUATION): New
flag.
(linecon_newline): Remove.
(_linecon_decoder): Correctly determine the end of continuation
in case when the last line contained standalone escapes.
2010-12-08 Sergey Poznyakoff <gray@gnu.org.ua>
Implement line number output in linecon and inline-comment
filters.
* libmailutils/filter/inline-comment.c: Implement line number
info facility.
* libmailutils/filter/linecon.c: Likewise.
* libmailutils/stream/logstream.c (_log_done, _log_close):
Always close/destroy the underlying transport stream.
* comsat/action.c: Rewrite using a table-driven parser. Use
line-info facility of the linecon filter.
2010-12-08 Sergey Poznyakoff <gray@gnu.org.ua>
comsat: improve biffrc evaluation.
* comsat/.gitignore: Add biff.rc.h
* comsat/Makefile.am (comsatd_SOURCES, BUILT_SOURCES): Add
biff.rc.h
(EXTRA_DIST): Add biffrc.sed and biff.rc
* comsat/action.c (default_action): Include biff.rc.h.
(biffrc_environ): New struct.
(eval_biffrc): New function.
(run_user_action): Rewrite via eval_biffrc. Default action is
evaluated if biff.rc cannot be opened, or it contains the
"default" keyword.
* comsat/tests/testsuite.at: Add "default" statement where
necessary.
2010-12-08 Sergey Poznyakoff <gray@gnu.org.ua>
comsat: improve tty handling, add testsuite.
* comsat/action.c (need_crlf, _open_tty, open_tty): Moved from
comsat.c
(open_default_tty): New function.
(run_user_action): Take device name as first argument. Reuse
wordsplit memory.
* comsat/comsat.c (notify_user): Update invocation of
run_user_action.
* comsat/comsat.h (open_tty): Remove prototype.
(run_user_action): Change signature.
* configure.ac: Add comsat tests.
* comsat/Makefile.am (SUBDIRS): Add tests.
* comsat/tests/.gitignore: New file.
* comsat/tests/Makefile.am: New file.
* comsat/tests/atlocal.in: New file.
* comsat/tests/testsuite.at: New file.
2010-12-07 Sergey Poznyakoff <gray@gnu.org.ua>
comsat: add a way to specify alternative biffrc file name; new
biffrc statement: tty.
* comsat/comsat.c (options): New option --file.
(biffrc): New variable.
(comsatd_parse_opt): Handle the --file option.
(open_tty): New function.
(notify_user): Open the tty using open_tty function and a
default set of filters.
(main): Handle --file option.
* comsat/action.c (run_user_action): Implement the `tty'
statement.
* comsat/comsat.h (biffrc): New extern.
(open_tty): New function.
mu: accept a chain of filters.
* mu/filter.c (filter_doc, filter_docstring): Update.
(mutool_filter): Accept a filter chain.
2010-12-07 Sergey Poznyakoff <gray@gnu.org.ua>
Rewrite prog stream support.
Two interfaces are provided: mu_prog_stream_create offers full
control over the program execution environment (i.e. running
privileges, cwd, resource limits) via a set of hints. A simpler
interface, mu_command_stream_create, runs the command in the
current environment.
mu_filter_prog_stream_create is removed, because its
functionality can be achieved by a correspondingly crafted set
of hints to mu_prog_stream_create.
* include/mailutils/prog.h: New file.
* include/mailutils/mailutils.h: Include mailutils/prog.h
* include/mailutils/Makefile.am (pkginclude_HEADERS): Add
prog.h
* include/mailutils/stream.h (mu_prog_stream_create)
(mu_filter_prog_stream_create): Remove prototypes.
* include/mailutils/sys/prog_stream.h (_mu_prog_stream): Change
structure.
(_mu_prog_limit_codes, _mu_prog_limit_flags): New externs.
* include/mailutils/util.h (mu_set_user_privileges)
(mu_switch_to_privs): New prototypes.
* lib/userprivs.c: Move to libmailutils/base.
* lib/Makefile.am (libmuaux_a_SOURCES): Remove userprivs.c
* libmailutils/base/Makefile.am (libbase_la_SOURCES): Add
userprivs.c
* libmailutils/base/userprivs.c (mu_set_user_privileges): New
function.
(mu_switch_to_privs): Rewrite as another entry point to
mu_set_user_privileges.
* libmailutils/stream/prog_stream.c (_mu_prog_limit_flags)
(_mu_prog_limit_codes): New global variables.
(start_program_filter): Use hints to control execution
environment.
(_prog_stream_create): Save hints.
(mu_prog_stream_create): Change signature.
(mu_command_stream_create): New function (corresponds to the
prior mu_prog_stream_create).
(mu_filter_prog_stream_create): Remove function.
* comsat/action.c (action_exec): Use new mu_prog_stream_create
calling convention.
* examples/murun.c: Rewrite.
* mh/mhn.c (show_internal): Use new mu_prog_stream_create
calling convention.
* mh/tests/mhn.at: Reflect changes to mhn.
* imap4d/preauth.c: Use mu_command_stream_create.
* libmu_sieve/extensions/pipe.c
* mail/decode.c
* mail/pipe.c
* mail/send.c
* mh/mhl.c
* mu/shell.c
* mail/mail.h: Include mailutils/prog.h
* mh/mh.h
* po/POTFILES.in: Add libmailutils/base/userprivs.c.
2010-12-07 Sergey Poznyakoff <gray@gnu.org.ua>
comsat: Use mu streams instead of stdio.
* comsat/action.c (action_beep, echo_string)
(action_echo, action_exec): Take mu_stream_t as first argument.
(open_rc): Take mu_stream_t as tty, return mu_stream_t as well.
Install the linecon filter.
(run_user_action): Take mu_stream_t as first arg. Pass it to
all invoked actions.
* comsat/comsat.c (get_newline_str): Remove.
(need_crlf): New function.
(notify_user): Use mu_stream_t instead of FILE. Install a 7bit
filter and CRLF filter (if the device requires it).
* comsat/comsat.h: Include mailutils/filter.h.
(run_user_action): Change signature.
2010-12-07 Sergey Poznyakoff <gray@gnu.org.ua>
file_stream: Bugfixes.
* libmailutils/stream/file_stream.c (fd_open): Remove file
state checks: it is the responsibility of the caller. Set
autoclose on the *stream* flags (bugfix, previously the
underlying fd was never closed). Clear MU_STREAM_SEEK flag if
seek fails.
(_mu_file_stream_create): Remove assignment to
stream.error_string
* include/mailutils/stream.h (MU_STREAM_ALLOW_LINKS): Remove
flag.
* libmailutils/base/amd.c (amd_message_stream_open): Initialize
flags to 0.
2010-12-07 Sergey Poznyakoff <gray@gnu.org.ua>
comsat: minor changes.
* libmailutils/mailbox/mailbox.c (mu_mailbox_open): Fix error
checking condition.
* comsat/action.c (act_getline): Remove.
(open_rc): Return mu_stream_t. Use linecon filter.
2010-12-07 Sergey Poznyakoff <gray@gnu.org.ua>
Implement a "line continuation" filter.
Line continuation filter removes from its input any sequence of
'\\\n' (a backslash followed by a newline). It is useful for
reading various UNIX configuration files.
* include/mailutils/filter.h (mu_linecon_filter): New extern.
* libmailutils/filter/linecon.c: New file.
* libmailutils/filter/Makefile.am (libfilter_la_SOURCES): Add
linecon.c
* libmailutils/filter/filter.c (mu_filter_get_list): Register
mu_linecon_filter.
* libmailutils/tests/linecon.at: New test.
* libmailutils/tests/Makefile.am (TESTSUITE_AT): Add linecon.at
* libmailutils/tests/testsuite.at: Include linecon.at
2010-12-06 Sergey Poznyakoff <gray@gnu.org.ua>
frm,messages,readmsg: Use MU streams instead of stdio.
* frm/common.c: Use MU streams instead of stdio.
* frm/frm.c: Likewise.
* messages/messages.c: Likewise.
* readmsg/readmsg.c: Likewise.
* frm/frm.h: Include mailutils/stdstream.h
* readmsg/readmsg.h: Likewise.
2010-12-06 Sergey Poznyakoff <gray@gnu.org.ua>
Revise stream ioctl support.
The mu_stream_ioctl function gets two argument that identify
the ioctl in question: "family", which identifies a family of
ioctls in question, and "opcode", which indicates the requested
operation within that family.
* include/mailutils/stream.h: Define ioctl families and
opcodes.
(mu_stream_ioctl): Change signature.
* include/mailutils/sys/stream.h (_mu_stream)<ctl>: Change
signature.
* include/mailutils/log.h (mu_severity_from_string)
(mu_severity_to_string): New protos.
* libmailutils/stream/stream.c (mu_stream_ioctl): Change
signature.
* libmailutils/filter/filter_iconv.c: Rewrite ioctl support.
* libmailutils/stream/file_stream.c: Likewise.
* libmailutils/stream/fltstream.c: Likewise.
* libmailutils/stream/iostream.c: Likewise.
* libmailutils/stream/logstream.c: Likewise.
* libmailutils/stream/mapfile_stream.c: Likewise.
* libmailutils/stream/memory_stream.c: Likewise.
* libmailutils/stream/nullstream.c: Likewise.
* libmailutils/stream/prog_stream.c: Likewise.
* libmailutils/stream/rdcache_stream.c: Likewise.
* libmailutils/stream/streamref.c: Likewise.
* libmailutils/stream/syslogstream.c: Likewise.
* libmailutils/stream/tcp.c: Likewise.
* libmailutils/stream/xscript-stream.c: Likewise.
* libmu_auth/tls.c: Likewise.
* comsat/action.c: Change calls to mu_stream_ioctl.
* imap4d/auth_gsasl.c: Likewise.
* imap4d/io.c: Likewise.
* imap4d/util.c: Likewise.
* libmailutils/base/getpass.c: Likewise.
* libmailutils/cfg/parser.y: Likewise.
* libmailutils/mailbox/body.c: Likewise.
* libmailutils/mime/mime.c: Likewise.
* libmailutils/stdstream/dbgstream.c: Likewise.
* libmailutils/stdstream/strerr.c: Likewise.
* libmu_sieve/runtime.c: Likewise.
* libmu_sieve/sieve.y: Likewise.
* libmu_sieve/util.c: Likewise.
* libproto/imap/trace.c: Likewise.
* libproto/mailer/smtp_data.c: Likewise.
* libproto/mailer/smtp_starttls.c: Likewise.
* libproto/mailer/smtp_trace.c: Likewise.
* libproto/pop/pop3_stls.c: Likewise.
* libproto/pop/pop3_stream.c: Likewise.
* libproto/pop/pop3_trace.c: Likewise.
* maidag/lmtp.c: Likewise.
* mail/source.c: Likewise.
* mu/logger.c: Likewise.
* pop3d/extra.c: Likewise.
* pop3d/retr.c: Likewise.
* TODO: Update.
* doc/texinfo/nullstream.texi: Update.
2010-12-06 Sergey Poznyakoff <gray@gnu.org.ua>
Implement severity suppression in log streams; other minor
fixes.
* include/mailutils/stream.h (MU_LOGSTREAM_ADVANCE_LOCUS_LINE)
(MU_LOGSTREAM_ADVANCE_LOCUS_COL): Rename to MU_IOCTL_.*. All
uses updated. (MU_IOCTL_LOGSTREAM_SUPPRESS_SEVERITY)
(MU_IOCTL_LOGSTREAM_SUPPRESS_SEVERITY_NAME): New ioctls.
* include/mailutils/sys/logstream.h
(_mu_log_stream)<threshold>: New member.
* include/mailutils/syslog.h (mu_log_severity_threshold): New
extern.
* libmailutils/cfg/parser.y (_cfg_default_printer): Remove
leftover static function.
* libmailutils/stream/logstream.c (mu_severity_from_string)
(mu_severity_to_string): New functions.
(_log_write): Fix double free. Implement severity suppression.
(_log_ioctl): Handle MU_IOCTL_LOGSTREAM_SUPPRESS_SEVERITY.
* libmu_cfg/common.c (mu_logging_param): New parameter
"severity".
2010-12-06 Sergey Poznyakoff <gray@gnu.org.ua>
Improve imap4d and pop3d testsuites.
* imap4d/testsuite/imap4d.rcin: Suppress syslog, use stderr.
* pop3d/testsuite/pop3d.rcin" Likewise.
2010-12-06 Sergey Poznyakoff <gray@gnu.org.ua>
mh: testsuite fix.
* mh/tests/mhn.at: Bugfix.
2010-12-06 Sergey Poznyakoff <gray@gnu.org.ua>
Rewrite debugging and logging support.
The mu_debug_t object and associated functions have been
removed. New debugging functions are based on the logstream
interface.
* include/mailutils/debug.hm4: Remove.
* include/mailutils/debug.h: New file.
* include/mailutils/Makefile.am (BUILT_SOURCES,EXTRA_DIST):
Remove debug.h, debug.hm4.
* mu-aux/debugdef.m4: Remove.
* mu-aux/debcat.awk: New file.
* mu-aux/Makefile.am (EXTRA_DIST): Replace debugdef.m4 with
debcat.awk.
* include/mailutils/sys/dbgstream.h: Remove.
* include/mailutils/sys/debug.h: Remove.
* include/mailutils/sys/Makefile.am (sysinclude_HEADERS):
Remove debug.h and dbgstream.h, add debcat.h
* include/mailutils/sys/.gitignore: Add debcat.h.
* libmailutils/diag/dbgstderr.c: Remove.
* libmailutils/diag/dbgsyslog.c: Remove.
* libmailutils/diag/gdebug.c: Remove.
* libmailutils/diag/debcat: New file.
* libmailutils/diag/Makefile.am (libdiag_la_SOURCES): Remove
these sources.
* libmailutils/diag/debug.c: Rewrite from scratch.
* libmailutils/diag/diag.c: Rewrite from scratch.
* libmailutils/diag/syslog.c (mu_diag_syslog_printer): Remove
function.
(mu_log_syslog, mu_log_print_severity): New variables.
* libmailutils/stream/dbgstream.c: Remove.
* libmailutils/stream/Makefile.am (libstream_la_SOURCES):
Remove dbgstream.c..
* libmailutils/stdstream/Makefile.am (libstdstream_la_SOURCES):
Add dbgstream.c.
* libmailutils/stream/logstream.c (_mu_severity_str): Change
strings to lower case.
(_log_write): Improve handling of unrecognized escapes.
(_log_ctl): Handle MU_LOGSTREAM_ADVANCE_LOCUS_LINE and
MU_LOGSTREAM_ADVANCE_LOCUS_COL.
* libmailutils/mailbox/folder.c (mu_folder_has_debug)
(mu_folder_get_debug, mu_folder_set_debug): Remove functions.
* mu-aux/debcat.awk: New file.
* libmailutils/stdstream/dbgstream.c: New file.
* comsat/action.c: Use new debug/log functions.
* comsat/comsat.c: Likewise.
* examples/aclck.c: Likewise.
* examples/echosrv.c: Likewise.
* examples/msg-send.c: Likewise.
* examples/nntpclient.c: Likewise.
* examples/numaddr.c: Likewise.
* frm/common.c: Likewise.
* imap4d/imap4d.c: Likewise.
* imap4d/io.c: Likewise.
* imap4d/util.c: Likewise.
* libmailutils/auth/mu_auth.c: Likewise.
* libmailutils/base/amd.c: Likewise.
* libmailutils/cfg/driver.c: Likewise.
* libmailutils/cfg/format.c: Likewise.
* libmailutils/cfg/lexer.l: Likewise.
* libmailutils/cfg/parser.y: Likewise.
* libmailutils/mailbox/mailbox.c: Likewise.
* libmailutils/mailbox/mbx_default.c: Likewise.
* libmailutils/mailer/mailer.c: Likewise.
* libmailutils/mailer/progmailer.c: Likewise.
* libmailutils/server/acl.c: Likewise.
* libmailutils/server/ipsrv.c: Likewise.
* libmailutils/server/msrv.c: Likewise.
* libmailutils/tests/wicket.c: Likewise.
* libmu_argp/auth.c: Likewise.
* libmu_argp/cmdline.c: Likewise.
* libmu_argp/common.c: Likewise.
* libmu_auth/ldap.c: Likewise.
* libmu_cfg/acl.c: Likewise.
* libmu_cfg/auth.c: Likewise.
* libmu_cfg/common.c: Likewise.
* libmu_cfg/ldap.c: Likewise.
* libmu_cfg/sieve.c: Likewise.
* libmu_cfg/sql.c: Likewise.
* libmu_scm/mu_message.c: Likewise.
* libmu_sieve/prog.c: Likewise.
* libmu_sieve/runtime.c: Likewise.
* libproto/imap/trace.c: Likewise.
* libproto/mailer/mbox.c: Likewise.
* libproto/mailer/prog.c: Likewise.
* libproto/mailer/sendmail.c: Likewise.
* libproto/mailer/smtp.c: Likewise.
* libproto/mailer/smtp_trace.c: Likewise.
* libproto/mbox/folder.c: Likewise.
* libproto/mbox/mbox.c: Likewise.
* libproto/nntp/folder.c: Likewise.
* libproto/nntp/nntp_debug.c: Likewise.
* libproto/pop/mbox.c: Likewise.
* libproto/pop/pop3_trace.c: Likewise.
* maidag/guile.c: Likewise.
* maidag/lmtp.c: Likewise.
* maidag/maidag.c: Likewise.
* maidag/util.c: Likewise.
* mail/mail.c: Likewise.
* mail/mailvar.c: Likewise.
* mail/send.c: Likewise.
* mail/source.c: Likewise.
* mh/mh_argp.c: Likewise.
* mh/send.c: Likewise.
* mimeview/mimeview.c: Likewise.
* movemail/movemail.c: Likewise.
* mu/wicket.c: Likewise.
* pop3d/extra.c: Likewise.
* pop3d/pop3d.c: Likewise.
* readmsg/readmsg.c: Likewise.
* sieve/sieve.c: Likewise.
* testsuite/mimetest.c: Likewise.
* libmu_sieve/sieve-priv.h (mu_sieve_machine)
<parse_error_printer>
<error_printer, debug_printer, debug>: Remove.
<errstream>: New member. (mu_sv_compile_error,
mu_sv_print_value_list)
(mu_sv_print_tag_list): Change prototypes.
* libmu_sieve/actions.c: Use new sieve debug functions.
* libmu_sieve/extensions/list.c: Likewise.
* libmu_sieve/extensions/moderator.c: Likewise.
* libmu_sieve/extensions/pipe.c: Likewise.
* libmu_sieve/extensions/spamd.c: Likewise.
* libmu_sieve/extensions/timestamp.c: Likewise.
* libmu_sieve/extensions/vacation.c: Likewise.
* libmu_sieve/sieve.y : Likewise.
* libmu_sieve/sieve.l: Likewise.
* libmu_sieve/tests.c: Likewise.
* libmu_sieve/util.c: Rewrite diagnostic support.
* /maidag/sieve.c: Use new debug/log and sieve diagnostic
functions.
* mu/mu.c (main): Remove call to mu_stdstream_setup. It is
called by mu_app_init now.
* libmailutils/base/wicket.c (mu_wicket_stream_match_url):
Change signature.
* libmailutils/cfg/gocs.c (mu_gocs_logging_init): Rewrite.
* libmailutils/mailbox/message.c (mu_message_save_to_mailbox):
Remove mu_debug_t argument.
* libmailutils/stdstream/basestr.c (mu_stdstream_setup): Minor
fixes.
* libmailutils/stdstream/strerr.c (mu_stdstream_strerr_create):
Do not install filter stream if tag is NULL.
(mu_stdstream_strerr_setup): New function.
* libmu_argp/muinit.c (mu_app_init): Set mu_log_tag. Call
mu_stdstream_setup.
* libmu_scm/mu_dbgport.c: Rewrite port support.
* include/mailutils/acl.h (mu_acl_get_debug)
(mu_acl_set_debug): Remove prototypes.
* include/mailutils/auth.h (mu_wicket_stream_match_url): Change
signature.
* include/mailutils/cfg.h (mu_cfg_locus_t): Remove typedef, use
struct mu_locus instead.
(mu_cfg_locus): Remove declaration.
(mu_cfg_node)<locus>: Change type.
(mu_cfg_node)<debug>: Remove. (mu_cfg_vperror,mu_cfg_perror)
(mu_cfg_parse_error,mu_cfg_format_error): Remove prototypes.
(mu_cfg_callback_t): Change signature. All uses updated.
(mu_cfg_get_debug): Remove prototype.
(mu_cfg_assert_value_type, mu_cfg_string_value_cb): Change
signature.
(mu_cfg_tree_set_debug): Remove prototype.
(mu_cfg_tree_create_node): Change signature.
* include/mailutils/diag.h (MU_DIAG_): Redefine via MU_LOG_
constants.
(mu_diag_get_debug,mu_diag_set_debug): Remove.
(mu_diag_cont_vprintf, mu_diag_cont_printf)
(mu_diag_at_locus): New functions.
* include/mailutils/folder.h (mu_folder_has_debug)
(mu_folder_get_debug, mu_folder_set_debug): Remove prototypes.
* include/mailutils/gocs.h (mu_gocs_logging): Remove structure.
(mu_gocs_debug)<errpfx>: Remove.
* include/mailutils/guile.h (mu_scm_make_debug_port): Change
prototype.
* include/mailutils/mailbox.h (mu_mailbox_has_debug)
(mu_mailbox_get_debug,mu_mailbox_set_debug): Remove.
* include/mailutils/mailer.h (mu_mailer_get_debug)
(mu_mailer_set_debug): Remove.
* include/mailutils/message.h (mu_message_save_to_mailbox):
Change signature.
* include/mailutils/mu_auth.h (mu_auth_set_debug): Remove
proto.
* include/mailutils/nntp.h (mu_nntp_set_debug): Remove.
* include/mailutils/progmailer.h (mu_progmailer_set_debug):
Remove proto.
* include/mailutils/server.h (mu_ip_server_set_debug)
(mu_ip_server_get_debug): Remove proto.
* include/mailutils/sieve.h (mu_sieve_locus_t): Remove. Use
struct mu_locus instead.
(mu_sieve_printf_t, mu_sieve_parse_error_t): Remove.
(mu_sieve_action_log_t): Change signature.
(mu_sieve_machine_init): Change signature.
(mu_sieve_machine_init_ex): New function.
(mu_sieve_get_diag_stream)
(mu_sieve_set_diag_stream): New functions.
(mu_sieve_set_data): New function.
(mu_sieve_get_locus): Change signature.
(mu_sieve_set_error,mu_sieve_set_parse_error)
(mu_sieve_set_debug,mu_sieve_set_debug_object): Remove protos.
* include/mailutils/stdstream.h (mu_stdstream_strerr_setup):
New proto.
* include/mailutils/stream.h (MU_LOGSTREAM_ADVANCE_LOCUS_LINE)
(MU_LOGSTREAM_ADVANCE_LOCUS_COL): New ioctls.
(mu_dbgstream_create): Change signature.
* include/mailutils/sys/folder.h (_mu_folder) <debug>: Remove.
* include/mailutils/sys/mailbox.h (_mu_mailbox) <debug>:
Remove.
* include/mailutils/sys/mailer.h (_mu_mailer) <debug>: Remove.
* include/mailutils/sys/nntp.h (_mu_nntp) <debug>: Remove.
* include/mailutils/syslog.h (mu_log_syslog)
(mu_log_print_severity): New externs.
* include/mailutils/types.hin (_mu_debug, mu_debug_t): Remove.
* lib/tcpwrap.h: Remove unused prototypes.
* imap4d/imap4d.h: Include mailutils/stdstream.h
* mail/mail.h: Likewise.
* pop3d/pop3d.h: Likewise.
* mh/comp.c (main): Bugfix.
* po/POTFILES.in: Update.
* TODO: Update.
2010-12-04 Sergey Poznyakoff <gray@gnu.org.ua>
Remove deprecated interfaces.
* include/mailutils/error.h (mu_error_pfn_t,
mu_default_error_printer)
(mu_syslog_error_printer): Remove deprecated interfaces.
* libmailutils/diag/muerror.c: Likewise.
* libmailutils/stream/logstream.c (_log_write): Send
MU_IOCTL_LOGSTREAM_SET_SEVERITY to the transport stream.
* libmailutils/stream/syslogstream.c (_syslog_ctl): Translate
MU severity to syslog priority level and vice versa.
* mu/logger.c (mutool_logger): Bugfix.
2010-12-04 Sergey Poznyakoff <gray@gnu.org.ua>
mu: use stdstream functions.
* include/mailutils/stdstream.h (mu_printf): New prototype.
* include/mailutils/version.h: Include mailutils/types.h
instead of stdio.h
(mu_fprint_options, mu_fprint_conf_option): Remove protos.
(mu_format_options, mu_format_conf_option): New protos.
* libmailutils/base/version.c (mu_fprint_options): Replace with
mu_format_options, which outputs formatted data to a
mu_stream_t.
(mu_fprint_conf_option): Ditto. Replaced by
mu_format_conf_option.
(mu_print_options): Update accordingly.
* libmailutils/stdstream/basestr.c (mu_printf): New function.
* mu/acl.c: Replace stdio calls with stdstream ones.
* mu/cflags.c: Likewise.
* mu/filter.c: Likewise.
* mu/flt2047.c: Likewise.
* mu/imap.c: Likewise.
* mu/info.c: Likewise.
* mu/ldflags.c: Likewise.
* mu/logger.c: Likewise.
* mu/mu.c: Likewise.
* mu/mu.h: Likewise.
* mu/pop.c: Likewise.
* mu/query.c: Likewise.
* mu/shell.c: Likewise.
* mu/verbose.c: Likewise.
* mu/wicket.c: Likewise.
2010-12-04 Sergey Poznyakoff <gray@gnu.org.ua>
Introduce stdstream module; move deprecated functions to
libmu_compat.
* include/mailutils/log.h: New file.
* include/mailutils/stdstream.h: New file.
* include/mailutils/Makefile.am (pkginclude_HEADERS): Add
stdstream.h and log.h.
* include/mailutils/argcv.h: Include mailutils/types.h
* include/mailutils/mailutils.h: Include stdstream.h Remove
vartab.h
* include/mailutils/types.hin (MU_DEPRECATED): New define.
* include/mailutils/vartab.h: Mark this header and all
prototypes it defines as deprecated.
* libmailutils/stdstream/Makefile.am: New file.
* libmailutils/stdstream/basestr.c: New file.
* libmailutils/stdstream/strerr.c: New file.
* libmu_compat/Makefile.am: New file.
* libmu_compat/tests/.gitignore: New file.
* libmu_compat/tests/Makefile.am: New file.
* libmu_compat/tests/atlocal.in: New file.
* libmu_compat/tests/testsuite.at: New file.
* libmailutils/base/Makefile.am (noinst_LTLIBRARIES): Remove
argcv.c and vartab.c.
* libmailutils/Makefile.am (SUBDIRS): Add stdstream.
(libmailutils_la_LIBADD): Add stdstream/libstdstream.la.
* libmailutils/tests/Makefile.am (noinst_PROGRAMS): Remove
argcv
(TESTSUITE_AT): Remove argcv.at
* libmailutils/tests/testsuite.at: Do not include argcv.at.
* libmailutils/base/argcv.c: Move to libmu_compat/argcv.c
* libmailutils/tests/argcv.at: Move to
libmu_compat/tests/argcv.at
* libmailutils/tests/argcv.c: Move to
libmu_compat/tests/argcv.c
* libmailutils/base/vartab.c: Move to libmu_compat/vartab.c
* Makefile.am (SUBDIRS): Add libmu_compat.
* configure.ac: Add libmu_compat/tests,
libmu_compat/tests/Makefile, libmu_compat/tests/atlocal,
libmu_compat/Makefile and libmailutils/stdstream/Makefile to
config file list.
* mu/ldflags.c (lib_descr): Add mu_compat.
* mu/logger.c (logger_parse_opt): -t does not imply --syslog.
(mutool_logger): Use inline-comment filter to insert "tag: "
prefix. Flush and destroy both streams before returning.
* po/POTFILES.in: Add libmailutils/stream/logstream.c,
libmailutils/stdstream/baseio.c,
libmailutils/stdstream/strerr.c and mu/logger.c.
2010-12-03 Sergey Poznyakoff <gray@gnu.org.ua>
Initial implementation of log streams.
* include/mailutils/mailutils.h: Include mailutils/log.h.
* include/mailutils/stream.h (MU_IOCTL_LOGSTREAM_GET_SEVERITY)
(MU_IOCTL_LOGSTREAM_SET_SEVERITY)
(MU_IOCTL_LOGSTREAM_GET_LOCUS,MU_IOCTL_LOGSTREAM_SET_LOCUS)
(MU_IOCTL_LOGSTREAM_GET_MODE,MU_IOCTL_LOGSTREAM_SET_MODE): New
ioctls.
* include/mailutils/sys/logstream.h: New file.
* include/mailutils/sys/syslogstream.h: New file.
* include/mailutils/sys/Makefile.am (sysinclude_HEADERS): Add
logstream.h and syslogstream.h
* include/mailutils/types.hin (mu_locus): New struct.
* libmailutils/stream/Makefile.am (libstream_la_SOURCES): Add
logstream.c and syslogstream.c.
* mu/logger.c: New file.
* mu/template.c: New file.
* mu/Makefile.am (MODULES): Add logger.c
(EXTRA_DIST): Add template.c.
2010-12-03 Sergey Poznyakoff <gray@gnu.org.ua>
streams: introduce setbuf hooks.
* include/mailutils/sys/stream.h (_mu_stream) <setbuf_hook>:
New member.
* libmailutils/stream/stream.c (mu_stream_set_buffer): Use
setbuf_hook to decide whether the operation is allowed.
2010-12-03 Sergey Poznyakoff <gray@gnu.org.ua>
streams: introduce setbuf hooks.
* include/mailutils/sys/stream.h (_mu_stream) <setbuf_hook>:
New member.
* libmailutils/stream/stream.c (mu_stream_set_buffer): Use
setbuf_hook to decide whether the operation is allowed.
2010-12-02 Sergey Poznyakoff <gray@gnu.org.ua>
mail: further improvements in quoting code.
* mail/escape.c (quote0): Simplify by using iterators.
2010-12-02 Sergey Poznyakoff <gray@gnu.org.ua>
Improve the inline-comment filter.
* libmailutils/filter/inline-comment.c: Recognize multi-char
comment sequences. Implement encode mode.
* libmailutils/tests/inline-comment.at: Test the new modes.
* mail/escape.c (quote0): Re-implement using inline-comment
encode mode.
* mail/mailvar.c (mailvar_tab): Fix a typo.
2010-12-02 Sergey Poznyakoff <gray@gnu.org.ua>
Minor change.
* configure.ac: Remove checks for strtok_r, strchrnul, strndup,
asprintf, vasprintf: none of these is used any more.
* maidag/lmtp.c (lmtp_reply): Use mu_vasnprintf.
* mh/mh.h (strchrnul): Remove proto.
* mh/mh_list.c (want_header): Rewrite.
(print): Use strcspn.
2010-12-02 Sergey Poznyakoff <gray@gnu.org.ua>
Avoid using strtok(_r)
* TODO: Update.
* gnulib.modules: Remove strtok_r
* imap4d/auth_gsasl.c (auth_gsasl_capa_init): Use mu_wordsplit
instead of strtok.
* imap4d/imap4d.h (strtok_r): Remove declaration.
* lib/mailcap.c (mime_context) <no_ask_str>: Remove. All uses
updated.
(mime_context_fill): Use mu_wordsplit instead of strtok.
(mime_context_write_input): Tolerate ENOSYS return from
mu_stream_seek.
(display_stream_mailcap): Use mu_wordsplit instead of strtok.
* libmailutils/diag/gdebug.c (mu_debug_level_from_string)
(mu_global_debug_from_string): Use mu_wordsplit instead of
strtok.
* libmu_cfg/sieve.c (_add_path): Likewise.
* libmu_sieve/extensions/list.c: Likewise.
* mail/escape.c (quote0): Likewise.
* mail/util.c (util_header_expand): Likewise.
(util_rfc2047_decode): Use mu_parse_lc_all.
* mh/mh_init.c (mh_charset): Use mu_parse_lc_all.
* frm/common.c (get_charset): Use mu_parse_lc_all.
* libmailutils/base/lcall.c: New file.
* libmailutils/base/Makefile.am (libbase_la_SOURCES): Add
lcall.c
* libmailutils/string/strlst.c: New file.
* libmailutils/string/Makefile.am (libstring_la_SOURCES): Add
strlst.c.
* include/mailutils/cstr.h: Include mailutils/types.h
(mu_string_split): New proto.
* include/mailutils/nls.h (MU_LC_LANG, MU_LC_TERR)
(MU_LC_CSET,MU_LC_MOD): New flags.
(mu_lc_all): New struct.
(mu_parse_lc_all, mu_lc_all_free): New protos.
(mu_charset_lookup): New proto (from util.h).
* include/mailutils/util.h (mu_charset_lookup): Move to nls.h
* libmailutils/base/tempfile.c (mu_tempname): Shut up compiler
warning.
2010-12-02 Sergey Poznyakoff <gray@gnu.org.ua>
Fixes in message_stream.
* libmailutils/mailbox/message.c (_message_stream_seek): Fix
ESPIPE conditional.
(_message_stream_read): Keep running until buffer is full or
_mss_eof state is reached.
(_message_stream_readdelim): Keep running until buffer is full,
_mss_eof state is reached or delimiter is found.
2010-12-01 Sergey Poznyakoff <gray@gnu.org.ua>
sieve: rewrite lexer to use MU streams API.
* libmu_sieve/sieve.l (input_string_ptr, input_string_level):
Remove.
(input_stream): New static variable.
(fillbuf): Use mu_stream_read
(buffer_ctx)<yyin>: Replace with mu_stream_t input;
(push_source, pop_source): Use stream API.
(mu_sv_lex_begin_string): Likewise.
* sieve/sieve.c (options): New option --expression.
(expression_option): New variable.
(parser): Handle the --expression option.
(main): Treat SCRIPT as program text if given the --expression
option.
2010-12-01 Sergey Poznyakoff <gray@gnu.org.ua>
Revise TODO.
2010-12-01 Sergey Poznyakoff <gray@gnu.org.ua>
imap4d: various fixes.
* imap4d/lsub.c (imap4d_lsub): Fix untagged responses.
* imap4d/imap4d.h (make_interdir): New proto.
* imap4d/create.c (mkdir_p): Remove function.
(MKDIR_PERMISSIONS): Move macro definition to imap4d.h
(imap4d_create): Use make_interdir instead of mkdir_p.
* imap4d/rename.c (make_interdir): New function.
(imap4d_rename): Create intermediate directories as required by
RFC 3501. Issue additional diagnostics if rename fails. Fix OK
response text.
* imap4d/imap4d.c (imap4d_mainloop): Implement idle timeout.
* imap4d/bye.c (imap4d_bye0): Reset the SIGPIPE before sending
the OK response in order to avoid recursion.
Unrelated changes:
* maidag/tests/forward.at: Fix the expected reply (see
f5374bc2ff).
2010-11-30 Sergey Poznyakoff <gray@gnu.org.ua>
Minor fix.
2010-11-30 Sergey Poznyakoff <gray@gnu.org.ua>
imap4d: rewrite subscription support from scratch.
This still needs some more work because imap4d does not check
whether the objects being subscribed to are valid folders or
mailboxes.
* imap4d/imap4d.h (open_subscription): New prototype.
* imap4d/lsub.c (imap4d_lsub): Rewrite using MU properties.
* imap4d/subscribe.c (open_subscription): New function.
(imap4d_subscribe): Rewrite using MU properties.
* imap4d/unsubscribe.c (imap4d_unsubscribe): Rewrite using MU
properties.
* examples/mblconv.c: New file.
* examples/Makefile.am: Add mblconv.c
2010-11-30 Sergey Poznyakoff <gray@gnu.org.ua>
sortm: update current message number; add testsuite.
* mh/sortm.c (current_num): New variable.
(sort): Keep track of the current message UID. Store it back to
mailbox if in reorder mode.
(main): Save initial current message UID. Save global and
mailbox status before exiting.
* mh/mh.h (mh_open_folder): Change last argument name.
* mh_open_folder (mh_open_folder): Change meaning of the 2nd
argument: it contains usual stream flags now. All uses changed.
* mh/tests/sortm.at: New file.
* mh/tests/testsuite.at: Include sortm.at
* mh/tests/Makefile.am (TESTSUITE_AT): Add sortm.at.
2010-11-30 Sergey Poznyakoff <gray@gnu.org.ua>
send: fix draftfolder support; add testsuite.
* examples/mta.c (mta_send): Don't print trailing spaces
instead of empty lines.
* mh/send.c: Redo draftfolder support.
(read_mts_profile): If MTSTAILOR environment variable is set,
it names the mtstailor file to use instead of the standard
ones.
* mh/tests/send.at: New file.
* mh/tests/Makefile.am (TESTSUITE_AT): Add send.at
* mh/tests/testsuite.at (MH_SETUP): Set MTSTAILOR.
(MH_MTSTAILOR): New macro Include send.at
2010-11-30 Sergey Poznyakoff <gray@gnu.org.ua>
Bugfix in libstream.
* libmailutils/stream/message_stream.c (_message_open): Don't
clobber len.
2010-11-30 Sergey Poznyakoff <gray@gnu.org.ua>
Minor fix in libstring.
* libmailutils/string/mkfilename.c (mu_make_file_name_suf):
Don't add leading / if dir=="".
2010-11-30 Sergey Poznyakoff <gray@gnu.org.ua>
mhn: fixes in compose mode.
* mh/mhn.c (edit_forw): Accept directives without explicit
folder spec. Fix creation of individual mime parts; set
Content-Type: message/rfc822 for each of them.
(mhn_edit): Fix some coredumps.
(main): Use -file argument, if it is given.
* mh/tests/atlocal.in (mimeflt): New function.
* mh/tests/mhn.at: Add tests for compose mode.
2010-11-30 Sergey Poznyakoff <gray@gnu.org.ua>
mime creation: bugfixes.
* libmailutils/mime/mime.c (_mime_append_part): All numeric
args are of type size_t.
(_mime_part_size): Fix calculations.
(mu_mime_get_part): Avoid coredump if stream is NULL.
2010-11-29 Sergey Poznyakoff <gray@gnu.org.ua>
mhn: minor fix in edit mode.
* mh/mhn.c (mhn_edit): Increase line_count after outputting a
line with a stripped-off initial #.
2010-11-29 Sergey Poznyakoff <gray@gnu.org.ua>
mh: improve testsuite.
* mh/mhn.c (mhn_pause): Fix type of the local buffer variable.
* mh/tests/mhn.at: Add more -show tests.
* testsuite/mh/mime/1: New file.
* testsuite/mh/mime/2: New file.
* testsuite/Makefile.am (EXTRA_DIST): Add mime.
2010-11-29 Sergey Poznyakoff <gray@gnu.org.ua>
streams: fix mu_stream_wait operation for buffered streams.
* libmailutils/stream/stream.c (mu_stream_wait): Fix condition
to determine if the buffer contains some data. Avoid passing
empty flags to the wait method.
2010-11-29 Sergey Poznyakoff <gray@gnu.org.ua>
Minor fixes.
2010-11-29 Sergey Poznyakoff <gray@gnu.org.ua>
mhn: compatibility fixes in show mode.
* mh/mhn.c (OPT_PAUSE): Remove define.
(pause_option): New variable.
(opt_handler): -pause/-nopause sets pause_option. If stdin is
not a tty, set pause_option to 0.
(check_type): New function.
(mhn_show_command): If mhn-show-<type>[/<subtype>] is not set,
use %pmoreproc '%F' for text/plain and message/rfc822 parts. If
content type is application/octet-stream and type=tar, use tar
to list the archive. Otherwise, complain and return NULL.
(MHN_CONFIRM): Rename to MHN_PAUSE.
(mhn_pause): New function.
(show_handler): The value of pause_option controls the %p
escape. Rewrite the MHN_PAUSE handling to avoid the use of the
fixed-size buffer. Implement C-c handling, as in other mhns. If
mhn_show_command returns NULL, do not attempt to show the
content. Remove dubious usage of mu_transport_t.
(mhn_store_command): handle application/octet-stream with
type=tar.
* mh/tests/mhn.at: Add a test for show mode.
2010-11-26 Sergey Poznyakoff <gray@gnu.org.ua>
mh: further improvements in mnh & mh testsuite.
* mh/mhn.c (_mhn_profile_get): Try mhn-<prefix>-<type> if
mhn-<prefix>-<type>/<subtype> does not exist.
(normalize_path): Use mu_normalize_path.
(store_handler) <store_to_file>: Honor mhn-<prefix>, if set.
* tests/atlocal.in (remove_curdir): New function.
* mh/tests/mhn.at: Implement more -store tests.
* mh/tests/testsuite.at (MH_SETUP): Set curdir for use by other
testcases.
* mh/tests/comp.at: Use remove_curdir to sort out the cwd.
* mh/tests/forw.at: Likewise.
* mh/tests/mark.at: Likewise.
* mh/tests/mhpath.at: Likewise.
* mh/tests/repl.at: Likewise.
2010-11-26 Sergey Poznyakoff <gray@gnu.org.ua>
mh: improve mhn store mode.
* mh/mhn.c (options): Add --build as an alias to --compose.
(options): Likewise.
(store_destination): New enum.
(mhn_store_command): Support all variants of mhn-store-*
components. Return store_destination type.
(store_handler): Rewrite accordingly.
(main): Consistently use mh_expand_name to expand the value of
input_file.
* mh/tests/mhn.at: New file.
* mh/tests/Makefile.am (TESTSUITE_AT): Add mhn.at.
* mh/tests/testsuite.at: Include mhn.at.
2010-11-26 Sergey Poznyakoff <gray@gnu.org.ua>
mhn: minor improvements.
* mh/mhn.c: Use _sget_ calls where appropriate. Eliminate
unnecessary memory allocations.
2010-11-25 Sergey Poznyakoff <gray@gnu.org.ua>
mhn: implement mhn-suffix-<type> profile component.
* mh/mhn.c (_mhn_profile_get): All arguments are const.
(mhn_tempfile_name): New function.
(mhn_show_command): Use mhn_tempfile_name.
2010-11-25 Sergey Poznyakoff <gray@gnu.org.ua>
Remove obsolete function.
* include/mailutils/body.h (mu_body_get_filename): Remove
proto.
* include/mailutils/sys/body.h (_mu_body) <filename>: Remove.
* libmailutils/mailbox/body.c (mu_body_get_filename): Remove
obsolete function.
(_body_get_stream): Use mu_temp_file_stream_create.
* libmailutils/stream/temp_file_stream.c
(mu_temp_file_stream_create): Return EINVAL if flags is set,
but hints is NULL.
* libmu_scm/mu_body.c (mu_scm_body_print): Don't use
mu_body_get_filename.
2010-11-25 Sergey Poznyakoff <gray@gnu.org.ua>
temp_file_stream: Use mu_tempfile_hints to control how the file
name is created.
* include/mailutils/stream.h (mu_temp_file_stream_create):
Change signature.
* include/mailutils/sys/Makefile.am (sysinclude_HEADERS): Add
temp_file_stream.h
* include/mailutils/util.h (mu_tempfile_hints): Remove const
qualifiers.
* libmailutils/stream/temp_file_stream.c: Include
sys/temp_file_stream.h.
(fd_temp_open): Use data from struct _mu_temp_file_stream.
(fd_temp_done): New function.
(mu_temp_file_stream_create): Take hints and flags as
arguments.
* examples/mta.c: Update calls to mu_temp_file_stream_create.
* libproto/mbox/mbox.c: Likewise.
* libproto/pop/mbox.c: Likewise.
* maidag/deliver.c: Likewise.
* maidag/lmtp.c: Likewise.
* mh/burst.c: Likewise.
* mh/prompter.c: Likewise.
2010-11-25 Sergey Poznyakoff <gray@gnu.org.ua>
Rewrite temporary file handling.
* include/mailutils/util.h (mu_make_file_name_suf): New proto.
(mu_make_file_name): Replace with a macro.
(MU_TEMPFILE_TMPDIR,MU_TEMPFILE_SUFFIX)
(MU_TEMPFILE_MKDIR): New flags.
(mu_tempfile_hints): New struct.
(mu_tempfile): Change signature.
* libmailutils/base/tempfile.c (mu_create_temp_file): New
function.
(mu_tempfile): Rewrite from scratch. Change signature. All
callers changed.
* libmailutils/string/mkfilename.c (mu_make_file_name): Remove.
(mu_make_file_name_suf): New function.
* libmailutils/stream/streamcpy.c (mu_stream_copy): Don't
return EIO on EOF.
* libmailutils/stream/file_stream.c (mu_fd_stream_create): If
MU_STREAM_SEEK is set, position fd to 0.
* guimb/collect.c: Update calls to mu_tempfile.
* lib/mailcap.c: Likewise.
* libmailutils/base/amd.c (_amd_tempfile): Rewrite using
mu_tempfile.
* libmailutils/tests/tempfile.c: New file.
* libmailutils/tests/Makefile.am (noinst_PROGRAMS): Add
tempfile.
2010-11-25 Sergey Poznyakoff <gray@gnu.org.ua>
mhn: minor changes.
* mh/etc/mhl.headers: New file.
* mh/etc/Makefile.am (MH_FILES): Add mhl.headers.
* mh/mhn.c (opt_handler): Use mh_find_file to resolve format
file name.
(mhn_show): Always open the formfile.
(copy_header_to_stream): Rewrite using mu_stream_copy + HEADER
filter.
2010-11-24 Sergey Poznyakoff <gray@gnu.org.ua>
mh: add a forgotten file.
* mh/tests/movemsg: add to the repository.
2010-11-24 Sergey Poznyakoff <gray@gnu.org.ua>
mh: minor changes in forw and repl; provide a set of
traditional scan formats.
* mh/.gitignore: Update.
* mh/compcommon.c (mh_comp_draft): Rewrite using mh_find_file
and simplify. All callers changed.
* mh/mh.h (mh_comp_draft): Change signature.
* mh/comp.c (opt_handler) <ARGP_KEY_FINI>: Make sure formfile
is initialized.
* mh/forw.c: Likewise.
* mh/repl.c (opt_handler): Remove unused variable.
* mh/tests/comp.at (compcmd): Remove -form.
* mh/tests/forw.at (forwcmd): Likewise.
* mh/etc/.gitignore: New file.
* mh/etc/Makefile.am: New file.
* mh/etc/forwcomps: New file.
* mh/etc/scan.default: New file.
* mh/etc/scan.mailx: New file.
* mh/etc/scan.size: New file.
* mh/etc/scan.time: New file.
* mh/etc/scan.timely: New file.
2010-11-24 Sergey Poznyakoff <gray@gnu.org.ua>
mh: move format files to a separate directory.
* mh/etc: New directory.
* mh/Makefile.am: New file.
* mh/components: Move to mh/etc.
* mh/mailutils-mh.eli: Move to mh/etc.
* mh/mhl.format: Move to mh/etc.
* mh/mhl.forward: Move to mh/etc.
* mh/mhl.repl: Move to mh/etc.
* mh/mhl.usenet: Move to mh/etc.
* mh/replcomps: Move to mh/etc.
* mh/replgroupcomps: Move to mh/etc.
* configure.ac (AC_CONFIG_FILES): Add mh/etc/Makefile.
* mh/Makefile.am (SUBDIRS): Add etc. Move mhlib_DATA and
related statements to mh/etc/Makefile.am
* mh/comp.c (formfile): Remove const qualifier.
(opt_handler): Use mh_find_file to set formfile.
* mh/forw.c: Likewise.
* mh/mh_init.c (mh_find_file): Make sure *resolved_name is
always set to the last tried name.
* mh/tests/comp.at: Remove directory components from the -from
argument.
* mh/tests/forw.at: Likewise.
* mh/tests/mhl.at: Likewise.
* mh/tests/testsuite.at (MH_SETUP): Change mhetcdir value.
2010-11-24 Sergey Poznyakoff <gray@gnu.org.ua>
mh: set a compatible search path for format files; other minor
fixes.
* mh/mh_format.c (builtin_friendly): If personal part is
present, return it. Otherwise, leave the address untouched.
(builtin_pers): Do not quote the return.
* mh/tests/inc.at: Reflect the above changes.
* mh/tests/scan.at: Likewise.
* mh/mh_list.c (eval_body): Offset each line.
* mh/tests/mhl.at: Test this change.
* mh/mhl.c: Use mh_find_file to resolve the argument to -form.
* mh/repl.c: Likewise. Same for replgroupcomps, mhl.repl and
-filter.
* mh/mhl.repl: New file.
* mh/mhl.usenet: New file.
* mh/Makefile.am (mhlib_DATA, EXTRA_DIST): Add new files.
2010-11-24 Sergey Poznyakoff <gray@gnu.org.ua>
wordsplit: fix whitespace trimming.
* libmailutils/string/wordsplit.c (mu_wordsplit_trimws): Do not
touch quoted nodes.
* libmailutils/tests/wordsplit.at: Test the above change.
2010-11-24 Sergey Poznyakoff <gray@gnu.org.ua>
mh: fix the use of mhl.forward in forw.
* mh/mhl.forward: New file.
* mh/forw.c (mh_option): the -format option is boolean.
(mhl_filter): Rename to mhl_filter_file.
(opt_handler) <ARG_FORMAT>: Use default mhl.filter.
<ARG_NOFORMAT>: Set encap_clear.
<ARG_FILTER>: Use mh_find_file to determine filter file name.
(finish_draft): Use MHL filter file if encap == encap_mhl.
* mh/mh.h (mh_find_file): New prototype.
* mh/mh_init.c (mh_find_file): New file.
(mh_read_formfile): Use mh_find_file to locate the file.
* mh/tests/forw.at: Test forw -format.
* mh/tests/mhparam.at: Update the -all test.
* tests/testsuite.at (MH_SETUP): Set the "mhetcdir" component.
* mh/scan.c (opt_handler): Exit if mh_read_formfile failed.
2010-11-24 Sergey Poznyakoff <gray@gnu.org.ua>
New type of stream: static memory stream.
Static memory stream is a read-only stream whose transport is
an arbitrary area of memory. Such streams allow the programmer
to access C strings using streams interface.
* include/mailutils/stream.h (mu_static_memory_stream_create):
New proto.
* libmailutils/stream/memory_stream.c
(mu_static_memory_stream_create): New function.
* imap4d/append.c (imap4d_append0): Use static memory stream to
create a temporary message.
* imap4d/preauth.c (decode64_buf): Use static memory stream.
* libmailutils/base/rfc2047.c (mu_rfc2047_decode): Likewise.
* libmailutils/mime/mimehdr.c (mu_mimehdr_decode_param):
Likewise.
* libmu_auth/ldap.c (chk_md5, chk_sha, chk_ssha): Likewise.
* libmu_sieve/extensions/vacation.c (build_mime): Likewise.
2010-11-24 Sergey Poznyakoff <gray@gnu.org.ua>
Fix body start calculation in message_stream. Fix compose
parser in mhn.
* libmailutils/stream/message_stream.c (scan_stream): Merge
with _message_open.
* mh/mhn.c (edit_forw): Do not set ws_delim. Fix message
addressing.
(mhn_edit): Remove the trailing newline.
2010-11-24 Sergey Poznyakoff <gray@gnu.org.ua>
mh: implement rmmproc.
* include/mailutils/sys/amd.h (_amd_data) <delete_msg>: New
method.
* libmailutils/base/amd.c (amd_expunge): If delete_msg is
defined, use it.
* libproto/mh/mbox.c (_mh_msg_delete): New method.
(_mailbox_mh_init): Set delete_msg if "rmmproc" component is
defined.
* mh/tests/movemsg: New file.
* mh/tests/Makefile.am (EXTRA_DIST): Add movemsg.
* mh/tests/rmm.at: Test rmmproc effects.
* mh/tests/rmf.at (MH_KEYWORDS): Fix copy-n-paste error.
* doc/texinfo/mu-mh.texi: Document rmmproc.
* mh/TODO: Update.
2010-11-23 Sergey Poznyakoff <gray@gnu.org.ua>
mh: add repl tests.
* mh/repl.c: Minor changes.
* tests/repl.at: New file.
* tests/Makefile.am (TESTSUITE_AT): Add repl.at
* mh/tests/testsuite.at: Include repl.at.
* mh/TODO: Update.
2010-11-23 Sergey Poznyakoff <gray@gnu.org.ua>
mh: improve forw; add tests.
* mh/forw.c (options): New option --file.
(input_file): New variable.
(opt_handler): Handle --file.
(finish_draft): Remove a leftover path hack. Implement raw file
forwarding.
(main): Minor fix.
* mh/mh_getopt.c (mh_option_init): Limit match_len to the
actual length of the option string.
* mh/tests/forw.at: New file.
* mh/tests/Makefile.am (TESTSUITE_AT): Add forw.at.
* mh/tests/testsuite.at: Include forw.at.
* mh/tests/comp.at: Add more keywords.
2010-11-22 Sergey Poznyakoff <gray@gnu.org.ua>
Provide a library function for translating message UIDs to
numbers and vice versa.
* include/mailutils/mailbox.h (MU_MAILBOX_UID_TO_MSGNO)
(MU_MAILBOX_MSGNO_TO_UID): New defines.
(mu_mailbox_translate): New proto.
* include/mailutils/sys/mailbox.h (_mu_mailbox) <_translate>:
New method.
* libmailutils/mailbox/mailbox.c (mu_mailbox_translate): New
function.
* libproto/mh/mbox.c (mh_translate): New function. Implements
the _translate method.
* mh/mh_msgset.c (mh_uid_to_msgno, mh_msgno_to_uid): Remove.
All callers updated to use mu_mailbox_translate instead.
(mh_search_message): Remove.
(mh_get_message): Rewrite using mu_mailbox_translate.
* mh/comp.c (copy_message): Check return from
mu_mailbox_get_message.
* mh/mh_init.c (mh_draft_message): Rewrite using
mu_url_sget_path.
* mh/tests/comp.at: Test draftfolder functionality.
2010-11-22 Sergey Poznyakoff <gray@gnu.org.ua>
mh: fix msgset parser and some more comp compatibility issues;
provide testsuite for comp. * mh/Makefile.am (bin_PROGRAMS):
Add mhseq. * mh/comp.c (main): Rewrite to fix compatibility
issues. * mh/mh.h (MH_MSGSET_UID): New define. (mh_msgset_t)
<flags,size>: New members. * mh/mh_init.c (mh_draft_message):
Bugfix: convert msgset to UIDs. * mh/mh_msgset.c: Rewrite from
scratch.
* mh/tests/comp.at: New file.
* mh/tests/mhseq.at: New file.
* mh/tests/Makefile.am (TESTSUITE_AT): Add comp.at, mhseq.at.
* mh/tests/testsuite.at: Include comp.at and mhseq.at.
* libmailutils/property/mhprop.c (_mh_prop_read_stream): Minor
fix. Do remove empty lines.
* mh/mh_whatnow.c (_whatnow): Detect EOF.
(call_send): Quit after successful send.
2010-11-21 Sergey Poznyakoff <gray@gnu.org.ua>
mh: Fix compatibility issues in the draftfolder facility.
Implement whatnowproc.
* mh/whatnowenv.c: New source.
* mh/Makefile.am (libmh_a_SOURCES): Add whatnowenv.c
* mh/TODO: Update.
* mh/comp.c: Implement draftfolder, whatnowproc and the -use
option.
* mh/forw.c: Likewise.
* mh/repl.c: Likewise.
* mh/compcommon.c (check_draft_disposition): Fix typo.
* mh/mh.h (mh_whatnow_env) <draftfolder>: Remove.
<mbox>: New member.
(mh_whatnowproc): New proto. (mh_whatnow_env_from_environ)
(mh_whatnow_env_to_environ): New proto.
* mh/mh_global.c (prop_merger): Bugfix: initialize dst.
* mh/mh_init.c (mh_draft_message): Update cur msg.
* mh/mh_whatnow.c (mh_whatnowproc): New function.
* mh/whatnow.c (opt_handler): Do not read Draft-Folder
variable.
(main): Initialize data from the environment.
2010-11-21 Sergey Poznyakoff <gray@gnu.org.ua>
mh: improve component reading (profile, context and whom).
* libmailutils/filter/header.c: New file.
* libmailutils/filter/Makefile.am (libfilter_la_SOURCES): Add
header.c.
* libmailutils/filter/filter.c (mu_filter_get_list): Register
mu_header_filter.
* libmailutils/filter/inline-comment.c: (ilcmt_ws)
(ilcmt_rollback): New states.
(ILCMT_REMOVE_EMPTY_LINES,ILCMT_SQUEEZE_WS): New flags.
(ilcmt_data)<buf,size,level,replay>: New members.
(ilcmt_action): New enum
(new_ilcmt_state): Return enum ilcmt_action.
(_ilcmt_decoder): Optionally remove empty lines and squeeze
leading white space.
* libmailutils/property/mhprop.c (_mh_prop_read_stream): Remove
empty lines from the input.
* libmailutils/tests/Makefile.am (TESTSUITE_AT): Add hdrflt.at
and inline-comment.at.
* libmailutils/tests/testsuite.at: Include hdrflt.at and
inline-comment.at.
* libmailutils/tests/fltst.c: Pass optional arguments to the
filter creation procedure.
* mh/mh_whom.c (read_header): New function.
(mh_whom): Rewrite using headers.
* include/mailutils/filter.h: Fix a typo.
* libmailutils/stream/fltstream.c: Likewise.
* libmu_auth/gsasl.c: Likewise.
2010-11-20 Sergey Poznyakoff <gray@gnu.org.ua>
Move MH profile & context support to libproto.
* mh/mh_ctx.c: Remove.
* mh/Makefile.am (libmh_a_SOURCES): Remove mh_ctx.c
* mh/folder.c (read_seq_file): Use mu_property_t.
* mh/mh.h (mh_context_iterator): Remove typedef.
(mh_global_profile_get, mh_global_profile_set)
(mh_global_profile_iterate)
(mh_global_context_set,mh_global_context_set)
(mh_global_context_iterate): Rewrite as macros.
(mh_global_sequences_iterate): Change signature.
(mh_read_property_file,mh_property_merge): New protos.
(mh_context_create,mh_context_read,mh_context_write)
(mh_context_get_value,mh_context_set_value,mh_context_iterate)
(mh_context_destroy,mh_context_merge): Remove protos.
* mh/mh_global.c (mh_global_profile_get, mh_global_profile_set)
(mh_global_profile_iterate)
(mh_global_context_set,mh_global_context_set)
(mh_global_context_iterate): Remove.
(mh_read_property_file,mh_property_merge): New functions.
(_mh_init_global_context,mh_read_profile)
(mh_set_current_folder,mh_global_sequences_iterate): Rewrite.
(mh_global_save_state): Rewrite.
* mh/mh_whom.c (mh_whom): Use mu_property_t.
* mh/send.c: Use mu_property_t.
* po/POTFILES.in: Add mh/mboxprop.c.
2010-11-20 Sergey Poznyakoff <gray@gnu.org.ua>
Re-implement MH sequences via mailbox properties.
* libmailutils/mailbox/header.c (mu_header_clear): New
function.
(mu_header_sget_value_n): Tolerate pval == NULL.
* libmailutils/property/assocprop.c (_assoc_prop_setval):
Bugfix.
(_assoc_prop_clear): New method.
(mu_assoc_property_init): Reference the stream.
(mu_assoc_property_init): Initialize _prop_clear.
* libmailutils/property/create.c (_mu_property_init): Now
extern.
* libmailutils/property/propset.c (mu_property_set_value): Null
value means unset.
* libmailutils/tests/prop.at: Test property clear and
invalidate.
* libmailutils/tests/prop.c: New commands: 0 for property clear
and ! for invalidate.
* libmailutils/property/mhprop.c: New file.
* libmailutils/property/propclr.c: New file.
* libmailutils/property/propinv.c: New file.
* libmailutils/property/Makefile.am (noinst_LTLIBRARIES): Add
new files.
* include/mailutils/header.h (mu_header_clear): New proto.
* include/mailutils/property.h (mu_property_clear)
(mu_property_invalidate): New protos.
(mu_mh_prop): New struct.
(mu_mh_property_init): New proto.
* include/mailutils/sys/property.h (_mu_property)
<_prop_clear>: New member.
(_mu_property_init): New proto.
* include/mailutils/mh.h: New file.
* include/mailutils/Makefile.am (pkginclude_HEADERS): Add mh.h
* libproto/mh/profile.c: New file.
* libproto/mh/Makefile.am (libmu_mh_la_SOURCES): Add new files.
* libproto/mh/mbox.c (mh_get_property): New static function.
(_mailbox_mh_init): Set _get_property.
* mh/mh_global.c (current_message, sequences): Remove. Use mbox
properties instead. (mh_global_sequences_get)
(mh_global_sequences_set) (mh_global_sequences_iterate)
(mh_global_sequences_drop): Take mbox as first argument. All
callers updated.
* mh/mh_init.c (mh_init2): Remove call to
mh_global_sequences_get.
* mh/mh_msgset.c (msgset_cur): Use mh_mailbox_get_cur.
* mh/mh_sequence.c (mh_seq_read, write_sequence)
(delete_sequence, mh_seq_add, mh_seq_delete): Take mbox as
first argument. All callers updated.
* mh/mh.h: Include mailutils/property.h.
(current_message): Remove.
(mh_mailbox_cur_default): New extern. (mh_global_sequences_get)
(mh_global_sequences_set) (mh_global_sequences_iterate)
(mh_global_sequences_drop): Take mbox as first argument. All
callers updated.
* mh/mh_format.c (builtin_cur): Rewrite using
mh_message_number.
* mh/mboxprop.c: New file.
* mh/Makefile.am (libmh_a_SOURCES): Add new file.
* mh/folder.c: Update calls to sequence management functions.
* mh/mark.c: Likewise.
* mh/pick.c: Likewise.
* mh/inc.c (main): Set mh_mailbox_cur_default to 1. Invalidate
properties if changecur is not set.
* mh/prompter.c (main): Destroy the iterator.
* mh/rmf.c: Rewrite using mu_mailbox_remove.
* mh/scan.c: Always close the mailbox.
* mh/tests/folder.at: Update.
* mh/tests/inc.at: Update. Inc now sets cur to 1 if it was not
originally set. This is what others MHs do.
2010-11-18 Sergey Poznyakoff <gray@gnu.org.ua>
Rewrite property support.
* configure.ac: Add libmailutils/property/Makefile to config
files.
* include/mailutils/property.h (mu_property_create)
(mu_property_destroy): Change signature.
(mu_property_get_owner): Remove. (mu_property_create_init)
(mu_property_set_init, mu_property_set_init_data)
(mu_property_ref, mu_property_unref)
(mu_property_save): New protos. (mu_property_get_iterator)
(mu_assoc_property_init): New protos.
* include/mailutils/sys/property.h (property_item): Remove
definition.
(MU_PROP_INIT, MU_PROP_FILL, MU_PROP_MODIFIED): New flags.
(_mu_property): Rewrite from scratch.
(_mu_property_check): New proto.
* libmailutils/property/Makefile.am: New file.
* libmailutils/property/assocprop.c: New file.
* libmailutils/property/create.c: New file.
* libmailutils/property/propget.c: New file.
* libmailutils/property/propitr.c: New file.
* libmailutils/property/propset.c: New file.
* libmailutils/Makefile.am (SUBDIRS): Add property.
(libmailutils_la_LIBADD): Add property/libproperty.la.
* libmailutils/base/property.c: Remove.
* libmailutils/base/Makefile.am (libbase_la_SOURCES): Remove
property.c
* libmailutils/base/assoc.c (first): Avoid coredumping on empty
hash table.
* include/mailutils/folder.h (mu_folder_set_property)
(mu_folder_get_property): New protos.
* include/mailutils/sys/folder.h (_mu_folder) <property>
<_get_property>: New members.
* libmailutils/mailbox/folder.c (mu_folder_destroy): Destroy
the property. (mu_folder_get_property)
(mu_folder_set_property): New functions.
* include/mailutils/mailbox.h (mu_mailbox_set_property): New
proto.
* libmailutils/mailbox/mailbox.c (mu_mailbox_set_property): New
function.
(mu_mailbox_get_property): Use _get_property method.
* include/mailutils/mailer.h (mu_mailer_set_property): New
proto.
* include/mailutils/sys/mailer.h (_mu_mailer) <_get_property>:
New member.
* libmailutils/mailer/mailer.c (mu_mailer_set_property): New
function.
(mu_mailer_get_property): Use _get_property method.
* include/mailutils/iterator.h (mu_iterator_set_dataptr): New
proto.
* include/mailutils/sys/iterator.h (_mu_iterator) <dataptr>:
New method.
* libmailutils/base/iterator.c (mu_iterator_set_dataptr): New
function.
(mu_iterator_current): Rewrite as a wrapper around
mu_iterator_current_kv.
(mu_iterator_current_kv): Use dataptr method (if defined) to
extract the data pointer.
* libmailutils/tests/prop.c: New file.
* libmailutils/tests/prop.at: New file.
* libmailutils/tests/Makefile.am (noinst_PROGRAMS): Add prop.
(TESTSUITE_AT): Add prop.at.
* libmailutils/tests/testsuite.at: Include prop.at.
2010-11-18 Sergey Poznyakoff <gray@gnu.org.ua>
mh: Minor fixes.
2010-11-18 Sergey Poznyakoff <gray@gnu.org.ua>
Minor fix.
* mh/prompter.c (main): Append terminating \0 to the opool.
2010-11-18 Sergey Poznyakoff <gray@gnu.org.ua>
mh: implement prompter.
* configure.ac (MU_COND_READLINE): New cond.
* mh/prompter.c: New file.
* mh/prompter-rl.c: New file.
* mh/prompter-tty.c: New file.
* mh/prompter.h: New file.
* mh/TODO: Update.
* mh/Makefile.am: Build prompter.
* doc/texinfo/mu-mh.texi: Document prompter
* po/POTFILES.in: Update.
2010-11-17 Sergey Poznyakoff <gray@gnu.org.ua>
Implement "inline-comment" filter.
* include/mailutils/filter.h (mu_filter_xcode_t): Change
signature.
(mu_filter_create_args): New proto.
(mu_inline_comment_filter): New extern.
* libmailutils/filter/inline-comment.c: New file.
* libmailutils/filter/Makefile.am (libfilter_la_SOURCES): Add
inline-comment.c.
* libmailutils/filter/crlfdot.c (alloc_state): Update
declaration.
* libmailutils/filter/crlfflt.c: Likewise.
* libmailutils/filter/dot.c: Likewise.
* libmailutils/filter/fromflt.c (_from_alloc_state): Likewise.
* libmailutils/filter/filter.c (mu_filter_create_args): New
function.
(mu_filter_create): Rewrite via mu_filter_create_args.
mh: inline comments are allowed for use in components and
forwcomp files.
* mh/compcommon.c (mh_comp_draft): Fix erroneous conditional.
* mh/components: Add comments.
* mh/mh_init.c (mh_file_copy): Rewrite using new API.
mu filter: new option to list supported filters.
* mu/filter.c (filter_options): New option --list (-L).
(filter_parse_opt): Handle the -L option.
(filter_printer, list_filters): New functions.
(main): Print a list of filters if --list was given.
2010-11-16 Sergey Poznyakoff <gray@gnu.org.ua>
mh: Optimize for speed.
* mh/burst.c (transtab): Revamp as a proper translation table.
It is indexed by the current state offset by 1 and the last
read character.
(token_num): Remove.
(finish_stream, flush_stream): Inline functions.
(burst_digest): Change transtab indexing.
2010-11-16 Sergey Poznyakoff <gray@gnu.org.ua>
mh: further fixes in burst testsuite.
* mh/burst.c: Minor changes.
* mh/tests/burst.at: Remove host-specific information.
2010-11-16 Sergey Poznyakoff <gray@gnu.org.ua>
mh: minor fix in traditional option handler.
* mh/mh_getopt.c (mh_option_init): Enforce the computed minlen
on each option which begins on the same letter as the sample.
2010-11-16 Sergey Poznyakoff <gray@gnu.org.ua>
mh: rmm now saves state before returning.
* mh/rmm.c (main): Call mh_global_save_state.
2010-11-16 Sergey Poznyakoff <gray@gnu.org.ua>
mh: fix burst, provide test cases.
* mh/burst.c (burst_stream): New struct.
(finish_stream): Change signature. Keep track of current part
number and flags.
(flush_stream): Rewrite.
(burst_digest): Remove extra buffering code. Rely on the stream
buffering instead. Fixed length-based EB detection. Return 0 if
the message has been burst successfully, 1 if it is not in
digest format.
(burst_or_copy): Revert the condition on burst_digest.
* tests/burst.at: New test.
* tests/Makefile.am (TESTSUITE_AT): Add burst.at
* tests/testsuite.at: Include burst.at
2010-11-15 Sergey Poznyakoff <gray@gnu.org.ua>
message_stream: Bugfix.
* libmailutils/stream/message_stream.c (copy_trimmed_value):
Fix memory allocation.
2010-11-15 Sergey Poznyakoff <gray@gnu.org.ua>
mh: fix testsuite, add new tests.
* mh/ali.c (ali_print_name_list): Print -list output.
* mh/tests/ali.at: New test case.
* mh/tests/Makefile.am (TESTSUITE_AT): Add ali.at
* mh/tests/testsuite.at: Include ali.at.
* mh/tests/anno.at: Fix MH_KEYWORDS definition.
* mh/tests/folder.at: Likewise.
* mh/tests/inc.at: Likewise.
* mh/tests/mark.at: Likewise.
* mh/tests/mhl.at: Likewise.
* mh/tests/mhparam.at: Likewise.
* mh/tests/mhpath.at: Likewise.
* mh/tests/refile.at: Likewise.
* mh/tests/rmf.at: Likewise.
* mh/tests/pick.at: Fix MH_KEYWORDS definition. Add more tests.
2010-11-15 Sergey Poznyakoff <gray@gnu.org.ua>
mh: Add new tests.
* mh/mh_init.c (mh_install): Exit with code 1 on errors.
* mh/tests/install-mh.at: New file.
* mh/tests/pick.at: New file.
* mh/tests/Makefile.am (TESTSUITE_AT): Add install-mh.at,
pick.at.
* mh/tests/testsuite.at: Include install-mh.at and pick.at.
2010-11-15 Sergey Poznyakoff <gray@gnu.org.ua>
mh: improve GNU option parser and help output.
* mh/mh_argp.c (mh_argp_children): Set group number -2, to
place help output between the application help and
informational options.
* mh/mhn.c (options): Regroup options,
* mh/pick.c: Likewise.
* mh/ali.c: Reword arg docs.
* mh/anno.c: Likewise.
* mh/burst.c: Likewise.
* mh/comp.c: Likewise.
* mh/fmtcheck.c: Likewise.
* mh/folder.c: Likewise.
* mh/forw.c: Likewise.
* mh/inc.c: Likewise.
* mh/install-mh.c: Likewise.
* mh/mark.c: Likewise.
* mh/mh_argp.c: Likewise.
* mh/mhl.c: Likewise.
* mh/mhn.c: Likewise.
* mh/mhparam.c: Likewise.
* mh/mhpath.c: Likewise.
* mh/pick.c: Likewise.
* mh/refile.c: Likewise.
* mh/repl.c: Likewise.
* mh/rmf.c: Likewise.
* mh/rmm.c: Likewise.
* mh/scan.c: Likewise.
* mh/send.c: Likewise.
* mh/sortm.c: Likewise.
* mh/whom.c: Likewise.
2010-11-15 Sergey Poznyakoff <gray@gnu.org.ua>
mh: improve traditional option parser and help output.
* mh/mh_getopt.h (mh_option): Move match_len to the end of the
structure. It should not be initialized.
(mh_option_init): New prototype.
* mh/mh_getopt.c (mh_option_init): New function.
* mh/mh_argp.c (mh_argp_parse): Call mh_option_init.
* mh/ali.c: Update mh_option declaration.
* mh/anno.c: Likewise.
* mh/burst.c: Likewise.
* mh/comp.c: Likewise.
* mh/fmtcheck.c: Likewise.
* mh/folder.c: Likewise.
* mh/forw.c: Likewise.
* mh/inc.c: Likewise.
* mh/install-mh.c: Likewise.
* mh/mark.c: Likewise.
* mh/mhl.c: Likewise.
* mh/mhn.c: Likewise.
* mh/mhparam.c: Likewise.
* mh/mhpath.c: Likewise.
* mh/pick.c: Likewise.
* mh/refile.c: Likewise.
* mh/repl.c: Likewise.
* mh/rmf.c: Likewise.
* mh/rmm.c: Likewise.
* mh/scan.c: Likewise.
* mh/send.c: Likewise.
* mh/sortm.c: Likewise.
* mh/whatnow.c: Likewise.
* mh/whom.c: Likewise.
2010-11-14 Sergey Poznyakoff <gray@gnu.org.ua>
pick: improve compatibility.
The traditional component matching syntax, `--COMP STRING', is
accepted, provided at least one of the following conditions is
met:
1. The word `COMP' contains at least one capital letter; 2. The
word `COMP' ends with a colon; 3. Standard input is not
connected to a terminal.
* mh/mh_getopt.c (mh_help_hook): New global variable.
(mh_help): Call mh_help_hook, if set.
* mh/mh_getopt.h (mh_help_hook): New extern.
* mh/pick.c (doc): Update.
(opt_handler): Remove ARGP_KEY_ERROR case.
(pick_help_hook): New function.
(main): Convert any instance of `--comp string' to
`--component=comp --pattern=string', if comp contains a capital
letter or ends with a colon, or fd 0 is not connected to
terminal.
* doc/texinfo/mu-mh.texi: Document changes to pick.
2010-11-12 Sergey Poznyakoff <gray@gnu.org.ua>
Minor fix in the test suite.
Replace 'Mirddin.farlep.net' with 'example.net' throughout the
testsuite. Change expected message/part sizes accordingly.
Files changed:
* imap4d/testsuite/imap4d/fetch.exp
* mail/testsuite/mail/folder.exp
* mail/testsuite/mail/read.exp
* mail/testsuite/mail/write.exp
* mh/tests/scan.at
* readmsg/tests/all.at
* testsuite/maildir/mbox1/new/1284628225.M20118P3883Q2.Trurl
* testsuite/maildir/mbox1/new/1284628225.M21284P3883Q3.Trurl
* testsuite/maildir/mbox1/new/1284628225.M22502P3883Q4.Trurl
* testsuite/mh/mbox1/3
* testsuite/mh/mbox1/4
* testsuite/mh/mbox1/5
* testsuite/mime.at
* testsuite/spool/mbox
* testsuite/spool/mbox1
* testsuite/spool/relational.mbox
2010-11-11 Sergey Poznyakoff <gray@gnu.org.ua>
Document null streams.
* doc/texinfo/nullstream.texi: New file.
* mh/mh_init.c (mh_real_install): Use mu_stream_t instead of
FILE.
* mh/mh_whatnow.c (_whatnow): Likewise.
2010-11-11 Sergey Poznyakoff <gray@gnu.org.ua>
anno: Minor improvements.
* mh/mh_init.c (mh_init): Make sure stdin is open.
* mh/anno.c (main): Use mu_stream_t to read the answer from
stdin. Do not display prompt if stdin is not connected to a
tty.
* mh/tests/anno.at: New testcase.
* mh/tests/Makefile.am (TESTSUITE_AT): Add anno.at
* mh/tests/testsuite.at: Include anno.at.
* doc/texinfo/mu-mh.texi: Document the changes in the behavior
of anno.
2010-11-11 Sergey Poznyakoff <gray@gnu.org.ua>
mhl: Improve backward compatibility. Provide a test case.
Mhl now accepts the traditional use of "ignores=", i.e. as a
single statement on a line and without double-quotes around the
argument.
Additional quotes around variable values are not needed in most
cases.
The name of a component is not printed if that component is not
present.
The offset variable works as in MH and nmh.
* mh/mh_list.c (parse_variable): Accept traditional use of
"ignores=", as a single statement on a line, without
double-quotes around the argument.
(mhl_format_compile): Use mu_streams instead of FILE. Fix line
counting.
(header_is_printed, want_header): Last argument is const char
*.
(ovf_print): Move to the specified offset no matter what the
value of prefix is.
(print_component_name): New function.
(eval_component): Call print_component_name and newline, if
necessary
(eval_body): Likewise.
(eval_extras): Likewise.
(eval_comp): Do not print component name, leave that to the
called function. Ditto for the trailing newline.
* mh/mhl.c: Ignore empty moreproc value.
* mh/mhl.format: Remove extra double-quotes.
* mh/tests/mhl.at: New testcase.
* mh/tests/Makefile.am (TESTSUITE_AT): Add mhl.at
* mh/tests/testsuite.at: Include mhl.at
* libmailutils/string/wordsplit.c (scan_qstring): Force
_WSNF_EMPTYOK.
(mu_wordsplit_len): Make sure the tail element is not joinable
* libmailutils/tests/wordsplit.at: Test these changes.
* doc/texinfo/mu-mh.texi: Update the description of mhl.
2010-11-11 Sergey Poznyakoff <gray@gnu.org.ua>
Add MH testsuite.
* configure.ac (mh/tests): New testdir
* mh/Makefile.am (SUBDIRS): Add tests
* tests/Makefile.am: New file.
* mh/tests/Makefile.am: New file.
* mh/tests/atlocal.in: New file.
* mh/tests/folder.at: New file.
* mh/tests/inc.at: New file.
* mh/tests/mark.at: New file.
* mh/tests/mhparam.at: New file.
* mh/tests/mhpath.at: New file.
* mh/tests/refile.at: New file.
* mh/tests/rmf.at: New file.
* mh/tests/rmm.at: New file.
* mh/tests/scan.at: New file.
* mh/tests/testsuite.at: New file.
* mh/tests/.gitignore: New file.
* testsuite/testsuite.inc (MUT_MBCOPY): Work correctly if DST
is a directory name (for MH and maildir formats).
* mh/folder.c (action_list): Treat empty value as equal to no
value.
* mh/install-mh.c (main): Honor MH environment variable.
* mh/mh_ctx.c (mh_context_read, mh_context_write): Use MU
streams instead of stdio FILE.
(mh_context_iterate): Add error checking. Do not coredump on
NULL header.
* mh/mh_global.c (_mh_init_global_sequences): Destroy
sequences.
* mh/TODO: Update.
* libmailutils/stream/message_stream.c (copy_trimmed_value):
New static function.
(scan_stream): Strip final newline from the saved envelope
values.
* mu/Makefile.am (BUILD_SOURCES, EXTRA_DIST): Add mu-setup.c
and mu-setup.h.
2010-11-10 Sergey Poznyakoff <gray@gnu.org.ua>
mhn: optimize using new API.
* mh/mhn.c (_get_hdr_value): Remove. All callers modified to
use mu_header_aget_value_unfold instead.
(mhn_message_size): Type of 2nd arg is mu_off_t *. Use null
stream & stream stats in realsize mode.
(list_handler): Fix rounding of the message size.
(copy_header): Use mu_header_sget* to avoid unnecessary memory
allocations.
2010-11-10 Sergey Poznyakoff <gray@gnu.org.ua>
Improve stream statistics interface. Introduce "null stream".
* include/mailutils/stream.h (MU_IOCTL_NULLSTREAM_SET_PATTERN)
(MU_IOCTL_NULLSTREAM_SET_PATCLASS)
(MU_IOCTL_NULLSTREAM_SETSIZE)
(MU_IOCTL_NULLSTREAM_CLRSIZE): New ioctl opcodes.
(mu_nullstream_pattern): New struct.
(MU_STREAM_STAT_IN,MU_STREAM_STAT_OUT)
(MU_STREAM_STAT_READS,MU_STREAM_STAT_WRITES)
(MU_STREAM_STAT_SEEKS,_MU_STREAM_STAT_MAX): New defines.
(MU_STREAM_STAT_MASK): New macro.
(MU_STREAM_STAT_MASK_ALL): New define.
(mu_stream_stat_buffer): New typedef. (mu_stream_set_stat,
mu_stream_get_stat)
(mu_nullstream_create): New protos.
(mu_stream_bytes_in, mu_stream_bytes_out): Remove protos.
* include/mailutils/sys/nullstream.h: New file.
* include/mailutils/sys/stream.h (_mu_stream) <bytes_in>,
<bytes_out>: Remove.
<statmask,statbuf>: New members.
* include/mailutils/sys/Makefile.am (sysinclude_HEADERS): Add
nullstream.h.
* libmailutils/stream/nullstream.c: New file.
* libmailutils/stream/stream.c (_stream_read, _stream_write)
(_stream_seek, _stream_stat_incr): New macros.
(_stream_fill_buffer, mu_stream_seek) (_stream_read_unbuffered)
(_stream_write_unbuffered): Use _stream_read, _stream_write and
_stream_seek instead of calling the corresponding methods
directly.
(mu_stream_bytes_in, mu_stream_bytes_out): Remove.
(mu_stream_unref): Clear statbuf, if provided.
(mu_stream_set_stat, mu_stream_get_stat): New functions.
* libmailutils/stream/Makefile.am (libstream_la_SOURCES): Add
nullstream.c.
* libmailutils/stream/fltstream.c (filter_wr_close): Check for
fs->eof.
* examples/base64.c (c_copy): Use new statistics interface.
* libmailutils/tests/fltst.c: Likewise.
2010-11-10 Sergey Poznyakoff <gray@gnu.org.ua>
attachment.c: redesign/simplify using the new API.
* libmailutils/mime/attachment.c (BUF_SIZE): Remove.
(_mu_mime_io_buffer)<buf, bufsize>: Remove members.
(MSG_HDR): Remove.
(mu_message_create_attachment): Use mu_asprintf instead of
manually crafting the string. (mu_mime_io_buffer_set_size)
(mu_mime_io_buffer_get_size): Remove.
(mu_message_save_attachment) (mu_message_encapsulate)
(mu_message_unencapsulate): Use mu_header_sget to avoid
unnecessary memory allocations. Use mu_stream_copy instead of
(ineffective) loops.
* include/mailutils/message.h (mu_mime_io_buffer_set_size)
(mu_mime_io_buffer_get_size): Remove prototypes.
* include/mailutils/header.h (MU_HEADER_RESENT_SENDER)
(MU_HEADER_CONTENT_TRANSFER_ENCODING) (MU_HEADER_DELIVERY_DATE)
(MU_HEADER_ENVELOPE_TO): Normalize spelling.
2010-11-09 Sergey Poznyakoff <gray@gnu.org.ua>
filter subsystem: bugfixes.
* include/mailutils/sys/filter.h (_mu_filter_stream)<eof>: New
member.
* libmailutils/filter/binflt.c (_bit8_filter): Change name
initializer to "8bit".
(_bit7_filter): Change name initializer to "7bit".
* libmailutils/filter/filter.c (mu_filter_create): Limit line
length for encoding streams only.
* libmailutils/stream/fltstream.c (filter_read): Use fs->eof
instead of the regular stream EOF marker.
* libmailutils/stream/stream.c (mu_stream_eof): Bugfix: take
into account eventual buffered data.
(_stream_read_unbuffered): Call mu_stream_eof instead of
checking the _MU_STR_EOF bit.
2010-11-09 Sergey Poznyakoff <gray@gnu.org.ua>
imap client: implement login and id commands.
* libproto/imap/id.c: New file.
* libproto/imap/login.c: New file.
* libproto/imap/Makefile.am: Add new files.
* libproto/imap/capability.c (mu_imap_capability): Clear
MU_IMAP_RESP before reading response. Add MU_WRDSF_QUOTE to
mu_wordsplit flags.
* libproto/imap/err.c (_mu_imap_seterrstr): Bugfix: initialize
imap->errstr.
* libproto/imap/logout.c (mu_imap_logout): Clear MU_IMAP_RESP
before reading response.
* libproto/imap/response.c (_mu_imap_response): Set error
string.
* mu/imap.c (com_login, com_id): New functions.
(imap_comtab) <login, id>: New keywords.
2010-11-09 Sergey Poznyakoff <gray@gnu.org.ua>
Make sure stream->offset points to the position in stream
corresponding to the start of the buffer.
* libmailutils/stream/stream.c (_stream_fill_buffer): Keep
track of the current offset.
(mu_stream_seek): avoid unnecessary seeks.
(_stream_skip_input_bytes): Call _stream_flush_buffer before
_stream_fill_buffer.
(_stream_write_unbuffered): Do not modify current offset.
(mu_stream_read,mu_stream_write): For unbuffered streams,
modify current offset after invoking the corresponding I/O
call.
(_stream_scandelim): Call _stream_flush_buffer before
_stream_fill_buffer.
2010-11-09 Sergey Poznyakoff <gray@gnu.org.ua>
Fix the "UNIX mailbox first message symptom".
UFMS, or "UNIX mailbox first message symptom", is a
long-standing bug that existed in all previous versions of
Mailutils: under certain circumstances, a fragment of the
message headers would get prepended to the body of the very
first message in a UNIX mailbox. See the detailed description
in testsuite/ufms.c.
Along with fixing this bug, this change also ensures a proper
restoring of UIDs from UNIX mailboxes.
* libproto/mbox/mbox.c (_msg_body_setup): Call
mu_body_clear_modified after constructing the body.
(new_message): Ditto for mu_message_clear_modified.
(mbox_reset): Rewrite. Drop all cached messages and rescan
entire mailbox to avoid the "1st message symptom".
(mbox_expunge0): Change the call to mbox_reset.
* libproto/mbox/mboxscan.c (IS_X_UID, IS_X_IMAPBASE): New
macros.
(mbox_scan_internal): Change handling of min_uid. Attempt to
get UID and imapbase from the corresponding message headers.
(mbox_scan0): Reflect the above changes.
* testsuite/.gitignore: Add ufms.
* testsuite/Makefile.am (noinst_PROGRAMS): Add ufms.
(TESTSUITE_AT): Add ufms.at.
* testsuite/testsuite.at: Include ufms.at.
* testsuite/ufms.at: New test case.
* testsuite/ufms.c: New test program.
* imap4d/testsuite/imap4d/expunge.exp: Fix UIDNEXT expectation.
2010-11-08 Sergey Poznyakoff <gray@gnu.org.ua>
Begin imap client implementation.
* include/mailutils/imap.h: New file.
* include/mailutils/Makefile.am (pkginclude_HEADERS): Add
imap.h
* libproto/imap/capability.c: New file.
* libproto/imap/capatst.c: New file.
* libproto/imap/carrier.c: New file.
* libproto/imap/connect.c: New file.
* libproto/imap/create.c: New file.
* libproto/imap/destroy.c: New file.
* libproto/imap/disconnect.c: New file.
* libproto/imap/err.c: New file.
* libproto/imap/fake-folder.c: New file.
* libproto/imap/logout.c: New file.
* libproto/imap/response.c: New file.
* libproto/imap/state.c: New file.
* libproto/imap/tag.c: New file.
* libproto/imap/trace.c: New file.
* libproto/imap/Makefile.am (libmu_imap_la_SOURCES):
Temporarily remove folder.c, mbox.c and url.c. Add new files.
* mu/getarg.c: New file.
* mu/imap.c: New file.
* mu/verbose.c: New file.
* mu/Makefile.am (IDLE_MODULES): New variable.
(IMAP_C): New variable.
(MODULES): Add $(IMAP_C).
(mu_SOURCES): Add getarg.c and verbose.c
(mu-setup.h, mu-setup.c): Add IDLE_MODULES both to the
dependencies and to the mu-setup.awk command line.
* mu/mu-setup.awk: New keyword mu-cond.
* mu/pop.c: Add mu-cond keyword.
* include/mailutils/sys/imap.h: Rewrite.
* include/mailutils/sys/pop3.h (MU_POP3_CHECK_EAGAIN): Take
into account MU_ERR_REPLY and MU_ERR_BADREPLY, which are
recoverable errors.
* libmailutils/base/list.c (mu_list_clear): Return immediately
if list is NULL.
* libmu_auth/sql.c (sql_escape_string): Remove unused variable.
* libproto/pop/pop3_carrier.c (mu_pop3_get_carrier): Increase
refcount on the returned stream.
* libproto/pop/pop3_response.c (mu_pop3_response): Check POP3
reply code.
2010-11-03 Sergey Poznyakoff <gray@gnu.org.ua>
Improve command module system in mu. Add a `help' command.
* mu/Makefile.am (MODULES): New variable. Put all commands
there.
(mu_SOURCES): Include $(MODULES).
(EXTRA_DIST): Add mu-setup.h mu-setup.c mu-setup.awk
(BUILT_SOURCES): New variable.
(mu-setup.h, mu-setup.c): New goals.
* mu/mu.c (doc): Remove command description: it is generated
automatically.
(mu_help_filter): New function.
(argp): Use mu_help_filter.
(mutool_action_tab): Remove.
(mutool_nosys,find_action): Remove.
(mu_help): New function.
(main): Use dispatch_find_action.
* mu/mu.h: Include mailutils/types.h (mutool_pop,
mutool_filter, mutool_flt2047) (mutool_info, mutool_query,
mutool_acl)
(mutool_wicket, mutool_ldflags, mutool_cflags): Remove protos.
(mu_help, dispatch_find_action, dispatch_docstring): New
protos.
* mu/acl.c: Add MU Setup comment.
* mu/cflags.c: Likewise.
* mu/filter.c: Likewise.
* mu/flt2047.c: Likewise.
* mu/info.c: Likewise.
* mu/ldflags.c: Likewise.
* mu/pop.c: Likewise.
* mu/query.c: Likewise.
* mu/wicket.c: Likewise.
* mu/mu-setup.awk: New file.
* mu/help.c: New file.
* mu/dispatch.c: New file.
* mu/.gitignore: Add mu-status.[ch]
* po/POTFILES.in: Add mu/dispatch.c and mu/help.c.
2010-11-02 Sergey Poznyakoff <gray@gnu.org.ua>
Remove the --license option.
It is not needed because the --version option shows a terse
info about the license, as well as a link to its full text.
2010-11-02 Sergey Poznyakoff <gray@gnu.org.ua>
Minor change.
* po/POTFILES.in: Fix erroneous filenames.
2010-11-02 Sergey Poznyakoff <gray@gnu.org.ua>
Use full buffering for streamrefs.
* libmailutils/stream/streamref.c
(mu_streamref_create_abridged): Set full buffering by default.
2010-11-02 Sergey Poznyakoff <gray@gnu.org.ua>
Minor changes.
* include/mailutils/wordsplit.h (mu_wordsplit_free_words): New
proto.
* libmu_auth/sql.c: Include wordsplit.h
2010-10-30 Sergey Poznyakoff <gray@gnu.org.ua>
Remove all uses of vartab, replacing them with wordsplit.
* libmailutils/string/wordsplit.c (mu_wordsplit_init): Call
mu_wordsplit_free_words to reclaim the memory.
(mu_wordsplit_free_words): New function.
(mu_wordsplit_free): Use mu_wordsplit_free_words.
* imap4d/imap4d.c (imap4d_session_setup0): Use wordsplit
instead of vartab.
* imap4d/imap4d.h: Don't include vartab.h.
* imap4d/preauth.c (do_preauth_ident): Use mu_str_stripws
instead of the static trimcrlf, which is removed.
(do_preauth_program): Use wordsplit instead of vartab and
mu_prog_stream_create instead of popen.
* libmailutils/mailbox/mbx_default.c: Include nls.h Don't
include vartab.h
(mu_construct_user_mailbox_url): Use wordsplit instead of
vartab.
* libmailutils/server/acl.c (expand_arg): Use wordsplit instead
of vartab.
* libmu_auth/ldap.c (_mu_ldap_search):L Likewise.
* libmu_auth/radius.c (_expand_query): Likewise.
* libmu_auth/sql.c (mu_sql_expand_query): Likewise.
* libproto/mailer/prog.c (_expand_sender, _expand_rcpt):
Rewrite.
(url_to_argv): : Use wordsplit instead of vartab.
* po/POTFILES.in: Add more files.
2010-10-29 Sergey Poznyakoff <gray@gnu.org.ua>
Use wordsplit to expand command prompt in mu.
* mu/mu.h (mutool_prompt_vartab): Remove.
(mutool_prompt_env): New extern.
* mu/pop.c (pop_prompt_vartab): Rewrite as pop_prompt_env. All
callers changed.
* mu/shell.c (mutool_prompt_vartab): Remove variable.
(mutool_prompt_env): New variable.
(expand_prompt): Remove function.
(input_line_interactive): Use mu_wordsplit to expand command
prompt.
2010-10-29 Sergey Poznyakoff <gray@gnu.org.ua>
Implement a Key/Value environment.
K/V is a new type of environment where variable names (keys)
and values are stored separately in adjacent environment
elements. This should simplify wordsplit initialization in many
cases.
* include/mailutils/wordsplit.h (MU_WRDSF_ENV_KV): New flag.
* libmailutils/string/wordsplit.c (mu_wordsplit_find_env):
Implement search in a K/V environment.
* libmailutils/tests/wordsplit.at: Test K/V environments.
* libmailutils/tests/wsp.c (bool_keytab): Implement env_kv.
(make_env_kv): New function.
(main): Convert environment if env_kv is given.
2010-10-29 Sergey Poznyakoff <gray@gnu.org.ua>
Fixes in wordsplit. Use wordsplit instead of vartab in
movemail.
Eventually this will lead to vartab fading out until it is
removed in some point in the future. Wordsplit provides a much
better variable substitution mechanism.
* include/mailutils/wordsplit.h (mu_wordsplit) <ws_getvar>:
Change signature.
<ws_closure>: New member.
(MU_WRDSF_CLOSURE): New flag.
* libmailutils/string/wordsplit.c (mu_wordsplit_init):
Initialize ws_closure to NULL, unless MU_WRDSF_CLOSURE is set.
Do not modify ws_wordn if MU_WRDSF_DOOFFS is set.
(wsnode_remove): Clear _WSNF_JOIN on the previous node if the
node being deleted is the last one in chain.
(expvar): Pass ws_closure as 3rd argument to ws_getvar. Insert
a NULL node if the variable is not defined.
* movemail/movemail.c: Use wordsplit instead of vartab. Note a
side effect: the "source:*" and "dest:*" variables are now
written as "source_*" and "dest_*", correspondingly.
(movemail_getvar_closure): New structure.
(DCL_VTX): Remove macro and its uses.
(get_url_part, movemail_getvar): New functions.
(set_program_id): Rewrite using wordsplit.
2010-10-28 Sergey Poznyakoff <gray@gnu.org.ua>
Add wordsplit module.
The wordsplit module (borrowed from another project of mine,
called 'grecs') provides a flexible and powerful mechanism for
parsing input in a way similar to posix-shell. In particular,
the POSIX function wordexp is a subset of the wordsplit
functionality.
The argcv module is now deprecated.
* include/mailutils/wordsplit.h: New file.
* include/mailutils/Makefile.am (pkginclude_HEADERS): Add
wordsplit.h
* libmailutils/string/wordsplit.c: New file.
* libmailutils/string/Makefile.am (libstring_la_SOURCES): Add
wordsplit.c.
* include/mailutils/argcv.h (mu_argcv_join): New proto.
(mu_argcv_get, mu_argcv_get_n, mu_argcv_get_np)
(mu_argcv_unquote_char, mu_argcv_quote_char)
(mu_argcv_quoted_length, mu_argcv_unquote_copy)
(mu_argcv_quote_copy): Mark as deprecated.
* include/mailutils/mailutils.h: Include wordsplit.h.
* libmailutils/tests/wsp.c: New file.
* libmailutils/tests/.gitignore: List wsp.
* libmailutils/tests/wordsplit.at: New file.
* libmailutils/tests/Makefile.am (noinst_PROGRAMS): Add wsp
(TESTSUITE_AT): Add wordsplit.at.
* libmailutils/tests/argcv.c: Define MU_ARCGV_DEPRECATED to
avoid deprecation warnings.
* libmailutils/tests/testsuite.at: Include wordsplit.at.
* libmailutils/base/argcvfree.c: New file.
* libmailutils/base/argcvjoin.c: New file.
* libmailutils/base/argcvrem.c: New file.
* libmailutils/base/Makefile.am (libbase_la_SOURCES): Add new
files.
* libmailutils/base/argcv.c: Define MU_ARCGV_DEPRECATED to
avoid deprecation warnings. (argcv_string, argcv_free,
argv_free)
(mu_argcv_remove): Rewrite in separate modules.
* comsat/comsat.h: Include wordsplit.h.
* imap4d/imap4d.h: Likewise.
* mail/mail.h: Likewise.
* mh/mh.h: Likewise.
* readmsg/readmsg.h: Likewise.
* comsat/action.c: Use wordsplit.
* imap4d/fetch.c: Likewise.
* lib/mailcap.c: Likewise.
* libmailutils/auth/mu_auth.c: Likewise.
* libmailutils/base/mutil.c: Likewise.
* libmailutils/cfg/format.c: Likewise.
* libmailutils/cfg/lexer.l: Likewise.
* libmailutils/cfg/parser.y: Likewise.
* libmailutils/diag/gdebug.c: Likewise.
* libmailutils/mailer/mailer.c: Likewise.
* libmailutils/server/acl.c: Likewise.
* libmailutils/stream/prog_stream.c: Likewise.
* libmailutils/tests/listop.c: Likewise.
* libmailutils/url/create.c: Likewise.
* libmu_auth/ldap.c: Likewise.
* libmu_auth/radius.c: Likewise.
* libmu_sieve/sieve.l: Likewise.
* libproto/mailer/mbox.c: Likewise.
* libproto/mailer/smtp.c: Likewise.
* libproto/mailer/smtp_gsasl.c: Likewise.
* mail/mailline.c: Likewise.
* mail/mailvar.c: Likewise.
* mail/send.c: Likewise.
* mail/util.c: Likewise.
* mh/folder.c: Likewise.
* mh/mh_alias.y: Likewise.
* mh/mh_argp.c: Likewise.
* mh/mh_init.c: Likewise.
* mh/mh_list.c: Likewise.
* mh/mh_msgset.c: Likewise.
* mh/mh_sequence.c: Likewise.
* mh/mh_whatnow.c: Likewise.
* mh/mh_sequence.c: Likewise.
* mh/mh_whatnow.c: Likewise.
* mh/mhn.c: Likewise.
* mh/send.c: Likewise.
* movemail/movemail.c: Likewise.
* mu/shell.c: Likewise.
* readmsg/readmsg.c: Likewise.
* testsuite/smtpsend.c: Likewise.
* pop3d/popauth.c: Use wordsplit. Use simplified input format
(username and password delimited by any amount of whitespace).
Read/produce old format if invoked with the --compatibility
option.
* examples/aclck.c: Use wordsplit instead of argcv.
* examples/header.c: Likewise.
* examples/mta.c: Likewise.
* examples/.gitignore: Remove pop3client.
* examples/Makefile.am: Remove pop3client.
* po/POTFILES.in: Add new files.
2010-10-27 Sergey Poznyakoff <gray@gnu.org.ua>
Fix allowed URL parts for local mailboxes.
Parameters are allowed: they are used to expand hashed or
indexed mailbox names.
* libproto/maildir/folder.c (_maildir_record): Add
MU_URL_PARAM.
* libproto/mbox/folder.c (_mbox_record): Likewise.
* libproto/mh/folder.c (_mh_record): Likewise.
2010-10-27 Sergey Poznyakoff <gray@gnu.org.ua>
Use mu_asprintf and mu_vasnprintf instead of asprintf and
vasprintf.
*gnulib.modules (snprintf, vasprintf): Remove.
*sieve/tests/reject.at: Use AT_PACKAGE_VERSION instead of the
hardcoded version number.
*lib/mu_asprintf.h: Remove.
* imap4d/auth_gss.c: Replace asprintf with mu_asprintf and
vasprintf by mu_vasnprintf.
* guimb/guimb.h: Likewise.
* imap4d/imap4d.h: Likewise.
* imap4d/unsubscribe.c: Likewise.
* lib/Makefile.am
* lib/mailcap.c: Likewise.
* libmu_argp/muinit.c: Likewise.
* maidag/deliver.c: Likewise.
* maidag/maidag.h: Likewise.
* mail/escape.c: Likewise.
* mail/mail.c: Likewise.
* mail/mail.h: Likewise.
* mail/util.c: Likewise.
* mail/write.c: Likewise.
* mh/burst.c: Likewise.
* mh/forw.c: Likewise.
* mh/mh.h: Likewise.
* mh/mh_alias.l: Likewise.
* mh/mh_format.c: Likewise.
* mh/mh_getopt.c: Likewise.
* mh/mh_init.c: Likewise.
* mh/mh_msgset.c: Likewise.
* mh/mh_sequence.c: Likewise.
* mh/mh_whatnow.c: Likewise.
* mh/mhn.c: Likewise.
* mh/send.c: Likewise.
* mimeview/mimetypes.l: Likewise.
* mimeview/mimetypes.y: Likewise.
* mimeview/mimeview.c: Likewise.
* movemail/movemail.c: Likewise.
* mu/ldflags.c: Likewise.
* pop3d/expire.c: Likewise.
* pop3d/pop3d.h: Likewise.
* sieve/sieve.c: Likewise.
2010-10-27 Sergey Poznyakoff <gray@gnu.org.ua>
Remove tcp wrapper configuration keywords that did not actually
change anything.
The allow_severity and deny_severity variables are valid only
for tcpd and related applications, hosts_access does not use
them.
* lib/tcpwrap.c (mu_tcp_wrapper_cb_hosts_allow_syslog)
(mu_tcp_wrapper_cb_hosts_deny_syslog): Remove functions.
(allow_severity, deny_severity): Remove variables.
(tcpwrapper_param): Remove allow-syslog-priority and
deny-syslog-priority.
2010-10-27 Sergey Poznyakoff <gray@gnu.org.ua>
Version 2.9.90.
* NEWS, configure: Set version number to 2.9.90 to avoid
confusion with 2.2.x branch.
2010-10-26 Sergey Poznyakoff <gray@gnu.org.ua>
Rewrite URL support.
The purpose is to make it modular and flexible. URLs are parsed
out as they are created. Missing URL parts can be supplied via
a "URL hint" at creation time (similar to the approach used in
creating mu_address_t). Ports can be specified either as
numbers or as service names. Original port string
representation can be retrieved from the URL, as well as its
numeric value.
* libmailutils/url/accessor.h: New file.
* libmailutils/url/copy.c: New file.
* libmailutils/url/create.c: New file.
* libmailutils/url/decode.c: New file.
* libmailutils/url/destroy.c: New file.
* libmailutils/url/dup.c: New file.
* libmailutils/url/expand.c: New file.
* libmailutils/url/flag.c: New file.
* libmailutils/url/get-auth.c: New file.
* libmailutils/url/get-host.c: New file.
* libmailutils/url/get-param.c: New file.
* libmailutils/url/get-path.c: New file.
* libmailutils/url/get-portstr.c: New file.
* libmailutils/url/get-query.c: New file.
* libmailutils/url/get-scheme.c: New file.
* libmailutils/url/get-secret.c: New file.
* libmailutils/url/get-user.c: New file.
* libmailutils/url/match.c: New file.
* libmailutils/url/port.c: New file.
* libmailutils/url/scheme.c: New file.
* libmailutils/url/uplevel.c: New file.
* libmailutils/url/urlstr.c: New file.
* configure.ac (AC_CONFIG_FILES): Add libmailutils/url/Makefile
* libmailutils/Makefile.am (SUBDIRS): Add url.
(libmailutils_la_LIBADD): Link with liburl.
* libmailutils/base/Makefile.am (libbase_la_SOURCES): Remove
url.c
* libmailutils/base/url.c: Remove.
* libmailutils/string/Makefile.am (libstring_la_SOURCES): Add
xdecode.c
* libmailutils/string/xdecode.c: New file.
* include/mailutils/sys/url.h (_mu_url): Change type to short.
<_get_port>: Change second argument to unsigned.
<_get_portstr>: New method.
* include/mailutils/url.h (MU_URL_SCHEME): New flag.
(MU_URL_PARSE_HEXCODE, MU_URL_PARSE_HIDEPASS)
(MU_URL_PARSE_PORTSRV, MU_URL_PARSE_PORTWC)
(MU_URL_PARSE_PIPE, MU_URL_PARSE_SLASH): New flags.
(mu_url_create_hint, mu_url_copy_hints): New prototypes.
(mu_url_parse): Remove.
(mu_url_get_port): Change second argument to unsigned.
(mu_url_decode_len,mu_url_decode): Remove.
(mu_url_decode): New proto. (mu_url_sget_portstr,
mu_url_aget_portstr)
(mu_url_get_portstr): New protos.
* include/mailutils/util.h (mu_str_url_decode)
(mu_str_url_decode_inline): New protos.
* libproto/pop/mbox.c (pop_open): Port is unsigned.
* libproto/imap/folder.c: Use MU_URL_SCHEME in url_may_have.
* libproto/maildir/folder.c: Likewise.
* libproto/mailer/prog.c: Likewise.
* libproto/mailer/remote.c: Likewise.
* libproto/mailer/sendmail.c: Likewise.
* libproto/mailer/smtp.c: Likewise.
* libproto/mbox/folder.c: Likewise.
* libproto/mh/folder.c: Likewise.
* libproto/nntp/folder.c: Likewise.
* libproto/pop/folder.c: Likewise.
* imap4d/imap4d.c: Remove calls to mu_url_parse.
* libmailutils/base/registrar.c: Likewise.
* libmailutils/base/wicket.c: Likewise.
* libmailutils/mailbox/folder.c: Likewise.
* libmailutils/mailbox/mailbox.c: Likewise.
* libmailutils/mailer/mailer.c: Likewise.
* libmailutils/tests/url-parse.c: Likewise.
* libmailutils/tests/wicket.c: Likewise.
* libproto/mailer/smtp_auth.c: Likewise.
* maidag/deliver.c: Likewise.
* mu/wicket.c: Likewise.
* libmailutils/mime/mimehdr.c (mu_mimehdr_decode_param): Use
mu_str_url_decode, instead of mu_url_decode.
* libmailutils/stream/tcp.c (_tcp_instance)<port>: Change type
to unsigned short. All uses updated.
(mu_tcp_stream_create_with_source_ip)
(mu_tcp_stream_create_with_source_host)
(mu_tcp_stream_create): Port is unsigned.
* include/mailutils/stream.h
(mu_tcp_stream_create_with_source_ip)
(mu_tcp_stream_create_with_source_host)
(mu_tcp_stream_create): Port is unsigned.
* include/mailutils/cpp/url.h (get_port): Return unsigned.
* libmu_cpp/url.cc (get_port): Return unsigned.
(parse): Empty function. Schedule for removal.
* python/libmu_py/url.c (api_url_parse): Empty function.
Schedule for removal.
(api_url_get_port): Port is unsigned.
* libmailutils/base/wicket.c (mu_wicket_file_match_url)
(mu_wicket_file_match_url): New parameter: parse_flags.
* mu/wicket.c (wicket_match): Use parse_flags to control
whether or not to show the plaintext password.
* doc/texinfo/url.texi: Update.
2010-10-25 Sergey Poznyakoff <gray@gnu.org.ua>
Minor fix.
* mh/mh_init.c (mh_safe_make_file_name): Avoid gcc warnings.
2010-10-25 Sergey Poznyakoff <gray@gnu.org.ua>
Improve URL matching code.
* libmailutils/base/url.c (mu_url_matches_ticket): Use
different weight values, depending on the missing part.
* libmailutils/base/wicket.c (mu_wicket_stream_match_url):
Refuse URLs that lack host and password parts.
2010-10-24 Sergey Poznyakoff <gray@gnu.org.ua>
Move `mailutils-config' functionality to `mu'. Retain
`mailutils-config' for backward compatibility.
* config/.gitignore: Remove.
* config/Makefile.am: Remove.
* config/mailutils-config.c: Remove.
* config/maint.mk: Remove.
* config/mailutils.m4: Move to mu-aux/mailutils.m4
* mu-aux/Makefile.am (m4datadir, dist_m4data_DATA): New
variables.
* Makefile.am (SUBDIRS) <config>: Remove.
* configure.ac (AC_CONFIG_FILES): Remove config.
* mu/mailutils-config: New file.
* mu/cflags.c: New file.
* mu/ldflags.c: New file.
* mu/Makefile.am (dist_bin_SCRIPTS, EXTRA_DIST): Add
mailutils-config.
(mu_SOURCES): Add cflags.c and ldflags.c.
(AM_CPPFLAGS): New variable.
* mu/mu.c: Add new modes: cflags and ldflags.
* mu/mu.h (mutool_ldflags, mutool_cflags): New protos.
* po/POTFILES.in: Update.
2010-10-24 Sergey Poznyakoff <gray@gnu.org.ua>
New `mu' mode: wicket.
* mu/wicket.c: New file.
* mu/mu.h (mutool_wicket): New proto.
* mu/mu.c (mutool_action_tab): Add an entry for wicket mode.
* mu/Makefile.am (mu_SOURCES): Add wicket.c
* .gitignore: Update.
2010-10-24 Sergey Poznyakoff <gray@gnu.org.ua>
Improve the algorithm for URL look up in wickets.
The new algorithm always returns the best match, i.e. the one
with the smallest number of wildcard comparisons.
* include/mailutils/auth.h (mu_wicket_stream_match_url)
(mu_wicket_file_match_url): New protos. Remove unnecessary
'extern' qualifiers.
* include/mailutils/url.h (mu_url_is_ticket): Remove.
(mu_url_matches_ticket): New proto.
* libmailutils/base/url.c (mu_url_parse): Fix name corruption
during password obfuscation.
(defined): Remove static function.
(mu_url_is_ticket): Remove function.
(mu_url_matches_ticket): New function.
* libmailutils/base/wicket.c (get_ticket_url): Remove.
(mu_wicket_stream_match_url)
(mu_wicket_file_match_url): New functions.
(file_ticket_get_cred): Use mu_wicket_file_match_url.
* libmailutils/tests/wicket.c: New file.
* libmailutils/tests/Wicketfile: New file.
* libmailutils/tests/wicket.at: New file.
* libmailutils/tests/Makefile.am (noinst_PROGRAMS): Add wicket.
(EXTRA_DIST): Add Wicketfile
(TESTSUITE_AT): Add wicket.at
* libmailutils/tests/testsuite.at: Include wicket.at
* libmailutils/tests/.gitignore: Update.
2010-10-22 Sergey Poznyakoff <gray@gnu.org.ua>
Improve SMTP client.
* include/mailutils/smtp.h (mu_smtp_dot): New proto.
* libproto/mailer/smtp_dot.c: New file.
* libproto/mailer/Makefile.am (libmu_mailer_la_SOURCES): Add
smtp_dot.c.
* libproto/mailer/smtp.c (smtp_send_message): Send RSET after
an unexpected SMTP reply. Call mu_smtp_dot after successful
sending.
* libproto/mailer/smtp_data.c (_mu_smtp_data_end): Set state to
MU_SMTP_DOT.
* libproto/mailer/smtp_rset.c (mu_smtp_rset): Improve state
selection algorithm.
* libproto/mailer/smtp_send.c (mu_smtp_send_stream): Don't
reset state: it is done by _mu_smtp_data_end.
* testsuite/smtpsend.c (main): Call mu_smtp_dot after sending
message.
2010-10-21 Sergey Poznyakoff <gray@gnu.org.ua>
Allow for `notls' parameter in pop URLs.
* libproto/pop/folder.c (_pop_record): Accept URL parameters.
* libproto/pop/mbox.c (pop_open): Don't start TLS if the
`notls' parameter is present in the URL.
2010-10-20 Sergey Poznyakoff <gray@gnu.org.ua>
Improve registrar/url interaction. Fix SMTP URLs to comply to
draft-earhart-url-smtp-00. Minor fix in maidag (url mode).
* include/mailutils/registrar.h (MU_RECORD_DEFAULT)
(MU_RECORD_LOCAL): New flags.
(_mu_record) <flags,url_may_have,url_must_have>: New members.
Remove unnecessary externs.
(mu_record_set_.*): Remove all protos.
(mu_record_check_url, mu_registrar_test_local_url): New protos.
* include/mailutils/sys/url.h (_mu_url) <flags>: New member.
(MU_URL_USER, MU_URL_SECRET, MU_URL_AUTH) (MU_URL_HOST,
MU_URL_PORT, MU_URL_PATH) (MU_URL_PARAM, MU_URL_QUERY)
(MU_URL_CRED, MU_URL_INET, MU_URL_ALL): New flags.
(mu_url_get_flags, mu_url_has_flag): New protos.
* libmailutils/base/registrar.c (mu_record_set_.*): Remove all.
(mu_record_check_url): New function.
(mu_registrar_test_local_url): New function.
* libmailutils/base/url.c (mu_url_copy0): Copy flags.
(mu_url_parse): Use flags intead of inspecting each structure
member. Set flags.
(mu_url_get_flags, mu_url_has_flag): New functions.
* libmailutils/diag/errors (MU_ERR_URL_MISS_PARTS)
(MU_ERR_URL_EXTRA_PARTS): New error codes.
* libmailutils/mailbox/folder.c (mu_folder_create_from_record):
Check the URL using mu_record_check_url.
* libproto/imap/folder.c (_imap_record, _imaps_record):
Initialize new fields.
* libproto/maildir/folder.c (_maildir_record): Likewise.
* libproto/mbox/folder.c (_mbox_record): Likewise.
* libproto/mh/folder.c (_mh_record): Likewise.
* libproto/nntp/folder.c (_nntp_record): Likewise.
* libproto/pop/folder.c (_pop_record, _pops_record): Likewise.
* libproto/mailer/prog.c (_prog_record): Likewise.
(_url_prog_init): Remove extra checks, rely on
mu_record_check_url.
* libproto/mailer/remote.c (_mu_remote_smtp_record)
(_mu_remote_sendmail_record,_mu_remote_prog_record): Initialize
new fields.
* libproto/mailer/sendmail.c (_url_sendmail_init): Remove extra
checks, rely on mu_record_check_url.
(_sendmail_record): Initialize new fields.
* libproto/nntp/url.c (url_nntp_destroy): Remove.
(_nntp_url_init): Remove extra checks.
* libproto/pop/url.c (url_pop_destroy): Remove.
(_url_pop_init, _url_pops_init): Remove extra checks.
* libproto/mailer/smtp.c (_url_smtp_init): Remove extra checks.
(_smtp_record): Initialize new fields.
(smtp_mailer_add_auth_mech): New function.
(smtp_open): Allow for auth= part before the host name.
* maidag/deliver.c (is_remote_url): New function.
(do_delivery): Do not try to switch user privileges if the URL
refers to a remote mailbox.
* maidag/maidag.c (main): Initialize TLS.
2010-10-19 Sergey Poznyakoff <gray@gnu.org.ua>
Provide an easy way of setting sender/recipient addresses in
smtp URLs.
* libmailutils/mailer/mailer.c (_set_from): Parameter from= can
be used to set the sender address explicitly.
(_set_to): New function. Parameter to= sets recipient addresses
explicitly.
(create_part): Use _set_to.
* libproto/mailer/mbox.c (remote_mbox_append_message): Use the
to= parameter.
2010-10-18 Sergey Poznyakoff <gray@gnu.org.ua>
Improve the algorithm of obtaining sender name from messages.
* include/mailutils/header.h: Remove unnecessary externs.
(mu_url_sget_param, mu_url_aget_param): New protos.
* libmailutils/base/url.c (mu_url_sget_param,
mu_url_aget_param): New functions.
* libmailutils/mailbox/hdrfirst.c: New file.
* libmailutils/mailbox/Makefile.am (libmailbox_la_SOURCES): Add
hdrfirst.c.
* libmailutils/mailbox/message.c (message_envelope_sender): Try
to restore the envelope sender from X-Envelope-Sender,
X-Envelope-From, X-Original-Sender, and From headers, in that
order.
* libmailutils/mailer/mailer.c (_set_from): Try to obtain
sender from the message envelope. If that fails, fall back to
the From header.
* libproto/mailer/mbox.c (parse_received,
guess_message_recipient): New static functions.
(remote_mbox_append_message): Get recipient address from the
first of X-Envelope-To, Delivered-To, X-Original-To headers, in
that order. If that fails, try to deduce it from the Received
header. If that fails too, fall back to the To header. If
recipient-headers URL parameter is defined, its value (a
comma-separated list of names) overrides this list. The
strip-domain parameter, if present, instructs the function to
strip domain part from the recipient address before resolving
it. The domain parameter, if present, supplies the domain name
which overrides the domain obtained from the URL.
2010-10-17 Wojciech Polak <polak@gnu.org>
Minor PEP 8 changes in Python API.
2010-10-16 Sergey Poznyakoff <gray@gnu.org.ua>
movemail: accept "smtp://" and "sendmail://" as a destination
mailbox.
* movemail/Makefile.am (movemail_LDADD): Add MU_LIB_MAILER.
* movemail/movemail.c: Register *all* mailbox formats,
including remote ones.
2010-10-12 Sergey Poznyakoff <gray@gnu.org.ua>
maidag/tests/forward.at: forgotten to add (see db1ee5e0a).
2010-10-12 Sergey Poznyakoff <gray@gnu.org.ua>
Improve mu_unroll_symlink interface.
* include/mailutils/util.h (mu_readlink): New function.
(mu_unroll_symlink): Change prototype.
* libmailutils/base/symlink.c (mu_qualify_link): Remove.
(mu_readlink): New function.
(mu_unroll_symlink): Rewrite. Don't use statically allocated
buffers.
* libmailutils/base/locker.c (mu_locker_create): Update calls
to mu_unroll_symlink.
2010-10-12 Sergey Poznyakoff <gray@gnu.org.ua>
Use mu_make_file_name where necessary.
* comsat/action.c (run_user_action): Use mu_make_file_name.
* imap4d/lsub.c (imap4d_lsub): Likewise.
* imap4d/subscribe.c (imap4d_subscribe): Likewise.
* imap4d/unsubscribe.c (imap4d_unsubscribe): Likewise.
* libmailutils/base/filename.c (mu_get_full_path): Likewise.
* libmailutils/base/tempfile.c (mu_tempfile): Likewise.
* libmailutils/base/url.c (_url_path_default): Likewise.
* libmu_auth/virtual.c (getpwnam_virtual)
(mu_auth_virt_domain_by_name): Likewise.
* libmu_sieve/extensions/vacation.c (check_db): Likewise.
* libmu_sieve/sieve.l (_try_include): Likewise.
* maidag/forward.c (maidag_forward): Likewise.
* mh/mh.h (mh_safe_make_file_name): New proto.
* mh/mh_init.c (mh_audit_open,mh_get_dir)
(mh_expand_name,mh_real_install): Use mh_safe_make_file_name.
(mh_safe_make_file_name): New function.
* mh/folder.c (read_seq_file, _scan): Use
mh_safe_make_file_name.
* mh/mh_global.c (mh_read_profile, _mh_init_global_sequences):
Likewise.
* mh/install-mh.c (main): Likewise.
* mh/mhn.c (normalize_path, store_handler, main): Likewise.
* mh/repl.c (make_draft): Likewise.
* mh/rmf.c (rmf): Likewise.
* mh/sortm.c (swap_message): Likewise.
* mimeview/mimetypes.l (mimetypes_open): Likewise.
* lib/mailcap.c: Add error checking.
2010-10-10 Wojciech Polak <polak@gnu.org>
Update Python API and the examples.
* python/libmu_py/folder.c (api_folder_set_stream): Remove.
* python/libmu_py/message.c (api_message_set_stream): Remove.
* python/libmu_py/stream.c (api_stream_ref, api_stream_unref):
Add.
(api_stream_sequential_readline, api_stream_sequential_write):
Remove.
2010-10-10 Sergey Poznyakoff <gray@gnu.org.ua>
Minor fix.
* libmailutils/base/getcwd.c: Add missing include file.
2010-10-10 Sergey Poznyakoff <gray@gnu.org.ua>
Rename mu_strcasestr to mu_c_strcasestr.
* include/mailutils/cstr.h (mu_strcasestr): Rename to
mu_c_strcasestr.
* libmailutils/string/cstrcasestr.c: Likewise. All uses
changed.
2010-10-10 Sergey Poznyakoff <gray@gnu.org.ua>
Split the mess in mutil.c into logically separated units.
* libmailutils/base/mutil.c (mu_hex2ul, mu_hexstr2ul): Move to
string/hexstr.c. (mu_get_homedir, mu_get_full_path)
(mu_expand_path_pattern): Move to base/filename.c.
(mu_getcwd): Move to base/getcwd.c.
(mu_tilde_expansion): Move to base/tilde.c
(mu_cpystr): Move to string/cpystr.c.
(mu_get_host_name): Move to base/hostname.c.
(mu_set_user_email,mu_set_user_email_domain)
(mu_get_user_email_domain,mu_aget_user_email_domain)
(mu_get_user_email,mu_normalize_path): Move to base/usremail.c.
(mu_tempfile,mu_tempname): Move to base/tempfile.c.
(mu_spawnvp): Move to base/spawnvp.c.
(mu_qualify_link,mu_unroll_symlink): Move to base/symlink.c.
(mu_rfc2822_references,mu_rfc2822_msg_id)
(mu_rfc2822_in_reply_to): Move to base/msgid.c.
(mu_strcasestr): Move to string/cstrcasestr.c.
(mu_string_unfold): Move to string/unfold.c.
(mu_true_answer_p): Move to string/trueans.c.
(mu_scheme_autodetect_p): Move to base/schemeauto.c.
(mu_fd_wait): Move to base/fdwait.c.
(mu_set_default_fallback,mu_decode_filter): Move to
filter/decode.c.
(__argp_base_name): Move to lib/argp_base.c.
* libmailutils/base/fdwait.c: New file.
* libmailutils/base/filename.c: New file.
* libmailutils/base/getcwd.c: New file.
* libmailutils/base/hostname.c: New file.
* libmailutils/base/msgid.c: New file.
* libmailutils/base/schemeauto.c: New file.
* libmailutils/base/spawnvp.c: New file.
* libmailutils/base/symlink.c: New file.
* libmailutils/base/tempfile.c: New file.
* libmailutils/base/tilde.c: New file.
* libmailutils/base/usremail.c: New file.
* libmailutils/base/Makefile.am: Add new files.
* libmailutils/filter/decode.c: New file.
* libmailutils/filter/Makefile.am: Add new files.
* libmailutils/string/cpystr.c: New file.
* libmailutils/string/cstrcasestr.c: New file.
* libmailutils/string/hexstr.c: New file.
* libmailutils/string/trueans.c: New file.
* libmailutils/string/unfold.c: New file.
* libmailutils/string/Makefile.am: Add new files.
* lib/argp_base.c: New file.
* lib/Makefile.am: Add new files.
* include/mailutils/io.h: Include stdarg.h
* include/mailutils/mutil.h: Rename to util.h. Reorder
prototypes and declarations in logical groups. All uses
changed.
* include/mailutils/cstr.h (mu_strcasestr): New proto, moved
from include/mailutils/mutil.h.
2010-10-09 Sergey Poznyakoff <gray@gnu.org.ua>
Fix copyleft notices to follow the GNU standards.
2010-10-09 Sergey Poznyakoff <gray@gnu.org.ua>
Reorganize libmailutils directory structure.
* configure.ac (AC_CONFIG_FILES): Add libmailutils/ subdirs.
* include/mailutils/Makefile.am: Update references to
libmailutils.
* po/POTFILES.in: Likewise.
* libmailutils/.gitignore: Update.
* libmailutils/Makefile.am: Use convenience libraries in
subdirs.
* libmailutils/string/Makefile.am: New file.
* libmailutils/cstrcasecmp.c: Move to libmailutils/string.
* libmailutils/cstrlower.c: Likewise.
* libmailutils/cstrupper.c: Likewise.
* libmailutils/strltrim.c: Likewise.
* libmailutils/strskip.c: Likewise.
* libmailutils/stripws.c: Likewise.
* libmailutils/strrtrim.c: Likewise.
* libmailutils/asnprintf.c: Likewise.
* libmailutils/asprintf.c: Likewise.
* libmailutils/muctype.c: Likewise.
* libmailutils/vasnprintf.c: Likewise.
* libmailutils/mkfilename.c: Likewise.
* libmailutils/stream/Makefile.am: New file.
* libmailutils/dbgstream.c: Move to libmailutils/stream.
* libmailutils/file_stream.c: Likewise.
* libmailutils/fltstream.c: Likewise.
* libmailutils/iostream.c: Likewise.
* libmailutils/mapfile_stream.c: Likewise.
* libmailutils/memory_stream.c: Likewise.
* libmailutils/message_stream.c: Likewise.
* libmailutils/prog_stream.c: Likewise.
* libmailutils/rdcache_stream.c: Likewise.
* libmailutils/socket_stream.c: Likewise.
* libmailutils/stdio_stream.c: Likewise.
* libmailutils/stream.c: Likewise.
* libmailutils/stream_printf.c: Likewise.
* libmailutils/stream_vprintf.c: Likewise.
* libmailutils/streamcpy.c: Likewise.
* libmailutils/streamref.c: Likewise.
* libmailutils/tcp.c: Likewise.
* libmailutils/temp_file_stream.c: Likewise.
* libmailutils/xscript-stream.c
* libmailutils/cfg/Makefile.am: New file.
* libmailutils/cfg/.gitignore: New file.
* libmailutils/cfg_driver.c: Move to libmailutils/cfg/driver.c.
* libmailutils/cfg_format.c: Move to libmailutils/cfg/format.c.
* libmailutils/cfg_lexer.l: Move to libmailutils/cfg/lexer.l.
* libmailutils/cfg_parser.y: Move to libmailutils/cfg/parser.y.
* libmailutils/gocs.c: Move to libmailutils/cfg/gocs.c.
* libmailutils/diag/Makefile.am: New file.
* libmailutils/diag/.gitignore: New file.
* libmailutils/debug.c: Move to libmailutils/diag.
* libmailutils/diag.c: Likewise.
* libmailutils/gdebug.c: Likewise.
* libmailutils/errors: Likewise.
* libmailutils/muerrno.cin: Likewise.
* libmailutils/syslog.c: Likewise.
* libmailutils/dbgstderr.c: Likewise.
* libmailutils/dbgsyslog.c: Likewise.
* libmailutils/address/Makefile.am: New file.
* libmailutils/address.c: Move to libmailutils/address.
* libmailutils/parse822.c: Likewise.
* libmailutils/mailbox/Makefile.am: New file.
* libmailutils/mailbox.c: Move to libmailutils/mailbox.
* libmailutils/mbx_default.c: Likewise.
* libmailutils/mbxitr.c: Likewise.
* libmailutils/attribute.c: Likewise.
* libmailutils/body.c: Likewise.
* libmailutils/envelope.c: Likewise.
* libmailutils/folder.c: Likewise.
* libmailutils/hdritr.c: Likewise.
* libmailutils/header.c: Likewise.
* libmailutils/message.c: Likewise.
* libmailutils/msgscan.c: Likewise.
* libmailutils/mailer/Makefile.am: New file.
* libmailutils/mailer.c: Move to libmailutils/mailer.
* libmailutils/progmailer.c: Likewise.
* libmailutils/mime/Makefile.am: New file.
* libmailutils/attachment.c: Move to libmailutils/mime.
* libmailutils/mime.c: Likewise.
* libmailutils/mimehdr.c: Likewise.
* libmailutils/server/Makefile.am: New file.
* libmailutils/acl.c: Move to libmailutils/server.
* libmailutils/server.c: Likewise.
* libmailutils/msrv.c: Likewise.
* libmailutils/ipsrv.c: Likewise.
* libmailutils/auth/Makefile.am: New file.
* libmailutils/auth.c: Move to libmailutils/auth.
* libmailutils/mu_auth.c: Likewise.
* libmailutils/system.c: Likewise.
* libmailutils/base/Makefile.am: New file.
* libmailutils/base/.gitignore: New file.
* libmailutils/alloc.c: Move to libmailutils/base.
* libmailutils/amd.c: Likewise.
* libmailutils/argcv.c: Likewise.
* libmailutils/assoc.c: Likewise.
* libmailutils/daemon.c: Likewise.
* libmailutils/date.c: Likewise.
* libmailutils/fgetpwent.c: Likewise.
* libmailutils/freeitem.c: Likewise.
* libmailutils/getpass.c: Likewise.
* libmailutils/iterator.c: Likewise.
* libmailutils/kwd.c: Likewise.
* libmailutils/list.c: Likewise.
* libmailutils/listlist.c: Likewise.
* libmailutils/locale.c: Likewise.
* libmailutils/locker.c: Likewise.
* libmailutils/mailcap.c: Likewise.
* libmailutils/md5.c: Likewise.
* libmailutils/monitor.c: Likewise.
* libmailutils/munre.c: Likewise.
* libmailutils/mutil.c: Likewise.
* libmailutils/nls.c: Likewise.
* libmailutils/nullrec.c: Likewise.
* libmailutils/observer.c: Likewise.
* libmailutils/opool.c: Likewise.
* libmailutils/parsedate.y: Likewise.
* libmailutils/permstr.c: Likewise.
* libmailutils/property.c: Likewise.
* libmailutils/registrar.c: Likewise.
* libmailutils/refcount.c: Likewise.
* libmailutils/rfc2047.c: Likewise.
* libmailutils/sha1.c: Likewise.
* libmailutils/secret.c: Likewise.
* libmailutils/ticket.c: Likewise.
* libmailutils/url.c: Likewise.
* libmailutils/vartab.c: Likewise.
* libmailutils/version.c: Likewise.
* libmailutils/wicket.c: Likewise.
2010-10-08 Sergey Poznyakoff <gray@gnu.org.ua>
mu: compile pop support conditionally.
* mu/Makefile.am [MU_COND_SUPPORT_POP]: Compile pop.c
conditionally.
* mu/mu.c (mutool_nosys): New function.
(mutool_action_tab): Compile pop support conditionally.
2010-10-08 Sergey Poznyakoff <gray@gnu.org.ua>
examples/mta.c: use streams instead of FILE; exit with codes
from sysexits.h.
2010-10-08 Sergey Poznyakoff <gray@gnu.org.ua>
maidag: improve forwarding capability, add a testcase for it.
* maidag/forward.c (check_forward_permissions): Keep track of
the processed files. Refuse to process a file twice.
(process_forward): Rewrite using streams instead of FILE.
(maidag_forward): Accept absolute file names (mainly for
testing).
* maidag/maidag.c (forward_checks): New keyword "owner".
(cb2_forward_file_checks): New keyword "none".
(main): Require at least one recipient in MDA mode.
* maidag/maidag.h (FWD_OWNER): New mask.
* maidag/tests/forward.at: New file.
* maidag/tests/Makefile.am (TESTSUITE_AT): Add forward.at
* maidag/tests/testsuite.at: Include forward.at.
2010-10-08 Sergey Poznyakoff <gray@gnu.org.ua>
Improve mta simulator output.
* examples/mta.c (mta_send): A line number refers to the start
of each line, not end of it.
* mail/testsuite/mail/send.exp: Reflect this change.
* sieve/tests/redirect.at: Likewise.
* sieve/tests/reject.at: Likewise.
2010-10-08 Sergey Poznyakoff <gray@gnu.org.ua>
maidag: optimize mda mode.
* maidag/deliver.c (make_tmp): Return mu_message_t. Use
mu_stream_to_message function.
(mda): Remove.
(maidag_stdio_delivery): Inline mda.
* maidag/maidag.h (mda): Remove.
2010-10-08 Sergey Poznyakoff <gray@gnu.org.ua>
maidag: remove `default' mode (superseded by --mda).
2010-10-08 Sergey Poznyakoff <gray@gnu.org.ua>
Maidag cleanup.
* maidag/maidag.c (mda_mode,lmtp_mode,url_option): Remove.
(maidag_mode): New variable.
(parse_opt): The --lmtp, --url and --mda options set the
delivery-mode configuration statement.
(cb_delivery_mode): New callback.
(maidag_cfg_param) <delivery-mode>: New statement.
(main): Redo delivery mode selection.
* maidag/maidag.h (maidag_mode): New enum.
(maidag_mode): New extern.
(mda_mode,lmtp_mode,url_option): Remove.
(maidag_delivery_fn): New typedef.
(maidag_stdio_delivery,mda): Change signature.
(deliver_to_url, deliver_to_user): New prototypes.
* maidag/deliver.c (mda): Take delivery function as a
parameter.
(maidag_stdio_delivery): Likewise.
(deliver_to_user): Rename to deliver_to_mailbox.
(deliver_url): Rename to do_delivery.
(deliver): Rename to deliver_to_url.
(deliver_to_user): New function.
* maidag/forward.c (process_forward): Use deliver_to_user.
* maidag/lmtp.c (dot_deliver): Likewise.
2010-10-07 Sergey Poznyakoff <gray@gnu.org.ua>
Improve maidag, add testsuite.
* configure.ac: Add maidag/tests
* maidag/Makefile.am (SUBDIRS): Add tests.
* maidag/deliver.c (make_tmp): Write a message delimiter.
(is_remote_url, is_mailer_url): Remove.
(deliver_url): Allow for URLs without user name.
* maidag/lmtp.c (lmtp_set_privs): Empty group list means do not
switch to any groups.
* maidag/maidag.c (mda_mode): New variable.
(options): New option --mda.
(cb_group, cb2_group): Create the list even if it is empty.
(main): Handle --mda.
* maidag/tests/.gitignore: New file.
* maidag/tests/Makefile.am: New file.
* maidag/tests/atlocal.in: New file.
* maidag/tests/input.msg: New file.
* maidag/tests/lmtp.at: New file.
* maidag/tests/mda.at: New file.
* maidag/tests/testsuite.at: New file.
* maidag/tests/url-mbox.at: New file.
* maidag/tests/input.msg: New file.
2010-10-07 Sergey Poznyakoff <gray@gnu.org.ua>
Fix a silly copy-paste error.
2010-10-07 Sergey Poznyakoff <gray@gnu.org.ua>
Implement a filter for quoting ^From. Use it for appending to
UNIX mailboxes.
* libmailutils/fromflt.c: New file.
* libmailutils/Makefile.am (libmailutils_la_SOURCES): Add
fromflt.c
* libmailutils/tests/testsuite.at: Include fromflt.at.
* include/mailutils/filter.h (mu_from_filter): New filter type.
* libmailutils/filter.c (mu_filter_get_list): Register
mu_from_filter.
* libmailutils/fromflt.at: New file.
* libmailutils/tests/Makefile.am (TESTSUITE_AT): Add
fromflt.at.
* libmailutils/tests/base64d.at: Mention `filter' in the
keywords.
* libmailutils/tests/base64e.at: Likewise.
* libmailutils/tests/fltst.c (main): Fix argc check.
* libproto/mbox/mbox.c (append_message_to_stream): Use "FROM"
filter.
2010-10-07 Sergey Poznyakoff <gray@gnu.org.ua>
Fixes in stream subsystem. Rewrite and optimize maidag lmtp
mode using streams.
* libmailutils/file_stream.c (mu_fd_stream_create): Mark stream
as open, do not call mu_stream_open explicitly.
* libmailutils/message_stream.c (mu_stream_to_message):
Bugfixes, wrong owner given to mu_envelope_set_ calls.
* libmailutils/stream.c (_MU_STR_FLUSH_ALL)
(_MU_STR_FLUSH_KEEP): New macros for _stream_flush_buffer.
(_stream_flush_buffer): Change the meaning of the last
argument. All callers updated.
(mu_stream_seek): Fix operation with MU_SEEK_END. Call
_mu_stream_cleareof on success.
(mu_stream_read): Call _stream_flush_buffer in buffered mode.
(mu_stream_getdelim, mu_stream_readdelim): Call
_stream_flush_buffer.
* libmailutils/streamcpy.c (mu_stream_copy): Reset size if
mu_stream_seek fails.
* libmailutils/temp_file_stream.c (mu_temp_file_stream_create):
Set full buffering mode by default.
* maidag/mailtmp.c: Remove.
* maidag/Makefile.am (maidag_SOURCES): Remove mailtmp.c
* po/POTFILES.in: Likewise.
* maidag/deliver.c (make_tmp): Rewrite. Return mu_mailbox_t.
All callers changed.
* maidag/lmtp.c (lmtp_transcript): Remove static.
(lmpt_transcript): New function.
(lmtp_reply): Use mu_stream_t instead of FILE.
(xlatnl): Remove. Superseded by mu_rtrim_cset and family.
(mtmp, mbox): Remove globals.
(mesg): New global. (cfun_unknown, cfun_mail_from,
cfun_rcpt_to) (dot_temp_fail, dot_deliver, cfun_rset)
(cfun_lhlo, cfun_quit, cfun_help): Use mu_stream_t instead of
FILE.
(cfun_data): Rewrite.
(cfun_dot): Remove.
(to_fgets): Rewrite using mu_stream_t.
(lmtp_loop): Change signature. Rewrite using mu_stream_t.
(lmtp_connection, maidag_lmtp_server): Update accordingly.
* maidag/maidag.c (maidag_transcript): New global.
(options, parse_opt): New option --transcript.
* maidag/maidag.h (maidag_transcript): New extern.
(mail_tmp_begin, mail_tmp_add_line, mail_tmp_finish)
(mail_tmp_destroy): Remove.
2010-10-06 Sergey Poznyakoff <gray@gnu.org.ua>
Improve scripting in mu pop shell.
* mu/pop.c (com_apop, com_pass): Require password in
non-interactive mode.
2010-10-06 Sergey Poznyakoff <gray@gnu.org.ua>
Minor changes.
* mu/shell.c (input_line_script): Use mu_getline.
* libmu_argp/compat.c: Remove.
* libmu_argp/Makefile.am: Remove compat.c
* po/POTFILES.in: Likewise.
2010-10-05 Sergey Poznyakoff <gray@gnu.org.ua>
Improve mu shell interface.
* mu/mu.h (mutool_command) <doc>: Rename to docstring.
<argdoc>: New member.
* mu/pop.c (com_apop): 2nd arg (password) is optional. If not
supplied, ask for it using the mu_getpass function.
(pop_comtab): Add argdocs. Use N_ wrappers around translatable
strings.
* mu/shell.c (default_comtab: Add argdocs. Use N_ wrappers
around translatable strings.
(print_comtab): Rewrite.
(shell_history): Use pager.
2010-10-05 Sergey Poznyakoff <gray@gnu.org.ua>
Minor bugfixes in pop client code.
* libproto/pop/pop3_carrier.c (mu_pop3_set_carrier): Switch to
MU_POP3_CONNECT state.
* libproto/pop/pop3_disconnect.c (mu_pop3_disconnect): Check if
the stream is actually open before trying to close it.
2010-10-05 Sergey Poznyakoff <gray@gnu.org.ua>
Add a missing function.
* libmailutils/strskip.c (mu_str_skip_cset): New function.
2010-10-05 Sergey Poznyakoff <gray@gnu.org.ua>
Implement echo control on fd streams. Implement mu_getpass
function.
* configure.ac: Test for tcgetattr and tcsetattr.
* gnulib.modules (getpass-gnu): Remove.
* include/mailutils/mutil.h (mu_getpass): New proto.
* include/mailutils/stream.h (MU_IOCTL_GET_ECHO)
(MU_IOCTL_SET_ECHO): New ioctls.
* include/mailutils/sys/file_stream.h
(_MU_FILE_STREAM_ECHO_OFF): New flag.
(_mu_file_stream) <echo_state>: New member.
* libmailutils/getpass.c: New file.
* libmailutils/Makefile.am (libmailutils_la_SOURCES): Add
getpass.c.
* libmailutils/file_stream.c (fd_done): Free echo_state.
(fd_ioctl): Implement MU_IOCTL_GET_ECHO and MU_IOCTL_SET_ECHO.
* mu/mu.h (mustrin): New extern.
* mu/pop.c (com_pass): Use mu_getpass.
* mu/shell.c (mustrin): New variable.
(readline): Use mu_stream_getline instead of getline.
(mutool_shell): Create mustrin.
* pop3d/popauth.c (options): Fix typo.
(fill_pass): Use mu_getpass.
2010-10-05 Sergey Poznyakoff <gray@gnu.org.ua>
Implement pager in mu shell.
* mu/mu.h (mutool_shell_interactive): New extern.
(mutool_open_pager): New proto.
* mu/pop.c (com_list, com_top, com_retr): Use pager.
* mu/shell.c (mutool_shell_interactive, mustrout): New
variables.
(print_comtab, print_help): Print to stream.
(shell_help): Use pager if necessary.
(mutool_open_pager): New function.
(mutool_shell): Create mutool_stream_out and destroy it before
returning.
(all functions): Use mu_stream_printf instead of printf.
2010-10-05 Sergey Poznyakoff <gray@gnu.org.ua>
Remove the use of MAXHOSTNAMELEN macro.
* comsat/comsat.c (hostname): Change type.
(comsat_init): Use mu_get_host_name.
* comsat/comsat.h (hostname): Change declaration.
* libmailutils/locker.c (lock_dotlock): Use mu_get_host_name.
* libmailutils/mutil.c (mu_get_host_name): Rewrite.
* pop3d/pop3d.c (pop3d_mainloop): Remove unnecessary call to
gethostbyname.
* pop3d/pop3d.h (MAXHOSTNAMELEN): Remove definition.
2010-10-05 Sergey Poznyakoff <gray@gnu.org.ua>
Minor bugfixes.
2010-10-04 Sergey Poznyakoff <gray@gnu.org.ua>
New mu submode: acl. Supersedes examples/aclck.c.
* mu/acl.c: New file.
* mu/Makefile.am: Add acl.c
* po/POTFILES.in: Add acl.c
* mu/mu.c (mutool_action_tab): Add acl mode.
* mu/mu.h (mutool_acl): New proto.
* mu/flt2047.c: Fix docstrings.
* mu/pop.c: Likewise.
2010-10-04 Sergey Poznyakoff <gray@gnu.org.ua>
Improve path parsing in mu_cfg_find_node.
* libmailutils/cfg_parser.y (split_cfg_path): New static.
(mu_cfg_find_node): Use the same parsing algorithm as
mu_cfg_create_subtree. This complements 68b7dc9dac.
(mu_cfg_create_subtree): Use split_cfg_path. Handle escaped '='
as a regular character.
* mu/mu.c (args_doc): Remove spurious word.
(main): Disable --version option in action handlers.
* mu/query.c (query_args_doc): Use `path' instead of `keyword'.
2010-10-03 Sergey Poznyakoff <gray@gnu.org.ua>
Fix docstrings in mu.
2010-10-03 Sergey Poznyakoff <gray@gnu.org.ua>
Bugfix.
* mu/filter.c (filter_options): Add missing arguments.
* mu/flt2047.c (flt2047_options): Likewise.
2010-10-03 Sergey Poznyakoff <gray@gnu.org.ua>
Bugfix.
* examples/http.c (main): Fix open/wait loop.
* libmailutils/stream.c (mu_stream_wait): May be used on
not-open streams.
* examples/.gitignore: Add more files.
2010-10-03 Sergey Poznyakoff <gray@gnu.org.ua>
New utility: mu.
The `mu' program is a multi-purpose tool for doing various
mail- and mailutils-related operations. It includes a pop3
shell, a coder/decoder for all filter formats supported by
Mailutils, a utility to extract arbitrary values from the MU
configuration files, a configuration information utility and
many more, in the short run. It supercedes examples/pop3client
and (partially) mailutils-config, both of which will be removed
in the future.
* Makefile.am (SUBDIRS): Add mu.
* configure.ac: Likewise.
* po/POTFILES.in: Add new files.
* mu/.gitignore: New file.
* mu/Makefile.am: New file.
* mu/filter.c: New file.
* mu/flt2047.c: New file.
* mu/info.c: New file.
* mu/mu.c: New file.
* mu/mu.h: New file.
* mu/pop.c: New file.
* mu/query.c: New file.
* mu/shell.c: New file.
2010-10-03 Sergey Poznyakoff <gray@gnu.org.ua>
Improve stream creation consistency.
One of stream flags bits indicates whether the stream is open
or not. The mu_stream_open function refuses to act if it
already is. The rest of functions (including mu_stream_close)
refuses to act if the stream was not open. A special function
(mu_stream_is_open) is provided to check if the stream is in
open state.
Any stream creation function returns an already open stream.
The function mu_stream_open should be called only if the stream
was previously closed by a call to mu_stream_close.
* include/mailutils/stream.h (mu_stream_is_open): New proto.
* include/mailutils/sys/stream.h (_MU_STR_OPEN): New flag.
* libmailutils/stream.c (_mu_stream_create): Permit setting the
_MU_STR_OPEN flag.
(_stream_init): New static.
(mu_stream_open): Return MU_ERR_OPEN if the stream is already
open.
(mu_stream_is_open): New function. (mu_stream_seek,
mu_stream_read, mu_stream_readdelim) (mu_stream_getdelim,
mu_stream_write, mu_stream_flush) (mu_stream_close,
mu_stream_size, mu_stream_wait)
(mu_stream_truncate): Check if the stream is open. Return
MU_ERR_NOT_OPEN otherwise.
* libmailutils/errors (MU_ERR_OPEN): Reword the diagnostics.
* libmailutils/dbgstream.c (mu_dbgstream_create): Open the
stream.
* libmailutils/file_stream.c (mu_file_stream_create)
(mu_fd_stream_create): Open the stream.
* libmailutils/filter_iconv.c (mu_filter_iconv_create): Open
the stream.
* libmailutils/mapfile_stream.c (mu_mapfile_stream_create):
Open the stream.
* libmailutils/fltstream.c (mu_filter_stream_create): Mark the
stream as open.
* libmailutils/iostream.c (mu_iostream_create): Likewise.
* libmailutils/memory_stream.c: Likewise.
* libmailutils/message.c (_message_stream_create): Likewise.
* libmailutils/message_stream.c (mu_message_stream_create):
Likewise.
* libmailutils/prog_stream.c (mu_prog_stream_create): Likewise.
* libmailutils/socket_stream.c (mu_socket_stream_create):
Likewise.
* libmailutils/temp_file_stream.c (mu_temp_file_stream_create):
Likewise.
* libmailutils/amd.c (_amd_attach_message): Mark stream as
open.
* libmailutils/body.c (_body_get_stream): Likewise.
* libmailutils/memory_stream.c: Likewise.
* libmailutils/rdcache_stream.c (mu_rdcache_stream_create:
Likewise.
* libmailutils/stdio_stream.c (mu_stdio_stream_create):
Likewise.
* libmailutils/streamref.c (mu_streamref_create_abridged):
Likewise.
* libmailutils/tcp.c (mu_tcp_stream_create_with_source_ip):
Likewise.
* libmailutils/xscript-stream.c (mu_xscript_stream_create):
Likewise.
* libmu_auth/tls.c (_mu_tls_io_stream_create): Likewise.
(_mu_tls_stream_create): Likewise.
* libproto/pop/pop3_stream.c (mu_pop3_stream_create): Likewise.
* examples/base64.c: Remove unnecessary mu_stream_open.
* examples/http.c: Likewise.
* examples/iconv.c: Likewise.
* examples/msg-send.c: Likewise.
* examples/murun.c: Likewise.
* examples/musocio.c: Likewise.
* examples/pop3client.c: Likewise.
* imap4d/append.c: Likewise.
* imap4d/io.c: Likewise.
* imap4d/preauth.c: Likewise.
* lib/mailcap.c: Likewise.
* libmailutils/attachment.c: Likewise.
* libmailutils/cfg_driver.c: Likewise.
* libmailutils/header.c: Likewise.
* libmailutils/mailcap.c: Likewise.
* libmailutils/mimehdr.c: Likewise.
* libmailutils/mutil.c: Likewise.
* libmailutils/tests/fltst.c: Likewise.
* libmailutils/tests/mailcap.c: Likewise.
* libmailutils/vartab.c: Likewise.
* libmailutils/wicket.c: Likewise.
* libmu_argp/muinit.c: Likewise.
* libmu_auth/ldap.c: Likewise.
* libmu_sieve/extensions/pipe.c: Likewise.
* libmu_sieve/extensions/spamd.c: Likewise.
* libmu_sieve/extensions/vacation.c: Likewise.
* libproto/imap/folder.c: Likewise.
* libproto/mailer/smtp.c: Likewise.
* libproto/mailer/smtp_starttls.c: Likewise.
* libproto/mbox/mbox.c: Likewise.
* libproto/nntp/nntp_connect.c: Likewise.
* libproto/pop/mbox.c: Likewise.
* libproto/pop/pop3_connect.c: Likewise.
* libproto/pop/pop3_stls.c: Likewise.
* maidag/mailtmp.c: Likewise.
* mail/decode.c: Likewise.
* mail/pipe.c: Likewise.
* mail/send.c: Likewise.
* mail/send.c: Likewise.
* mail/write.c: Likewise.
* mh/burst.c: Likewise.
* mh/comp.c: Likewise.
* mh/compcommon.c: Likewise.
* mh/forw.c: Likewise.
* mh/mh_init.c: Likewise.
* mh/mh_whatnow.c: Likewise.
* mh/mhl.c: Likewise.
* mh/mhn.c: Likewise.
* mh/repl.c: Likewise.
* mimeview/mimeview.c: Likewise.
* pop3d/extra.c: Likewise.
* sieve/sieve.c: Likewise.
* testsuite/smtpsend.c: Likewise.
2010-10-03 Sergey Poznyakoff <gray@gnu.org.ua>
Fix the SMTP SASL (client) without trace.
* include/mailutils/sys/smtp.h (_mu_smtp_get_streams)
(_mu_smtp_set_streams): New protos.
* libproto/mailer/smtp_gsasl.c (insert_gsasl_stream): Use
_mu_smtp_get_streams and _mu_smtp_set_streams to change
streams.
* libproto/mailer/smtp_starttls.c (smtp_get_streams): Rename to
_mu_smtp_get_streams. All callers changed.
(smtp_set_streams): Rename to _mu_smtp_set_streams. All callers
changed.
2010-09-25 Sergey Poznyakoff <gray@gnu.org.ua>
Disable installchecks for sieve.scm.
* guimb/scm/Makefile.am: Add sieve.scm to
AM_INSTALLCHECK_STD_OPTIONS_EXEMPT.
2010-09-25 Sergey Poznyakoff <gray@gnu.org.ua>
Redo the code for installing tls/sasl transport streams.
* include/mailutils/stream.h (MU_IOCTL_SWAP_STREAM): Remove.
(MU_IOCTL_GET_STREAM, MU_IOCTL_SET_STREAM): New ioctls.
* include/mailutils/sys/stream.h (_MU_SWAP_FIRST_ONLY)
(_MU_SWAP_IOCTL_MUST_SUCCEED): Remove.
(_mu_stream_swap_streams): Remove.
* libmailutils/stream.c (_mu_stream_swap_streams): Remove.
* libmailutils/filter_iconv.c (_icvt_ioctl): Handle
MU_IOCTL_GET_STREAM, MU_IOCTL_SET_STREAM instead of
MU_IOCTL_SWAP_STREAM.
* libmailutils/iostream.c (_iostream_ctl): Likewise.
* libmailutils/xscript-stream.c (_xscript_ctl): Likewise.
* imap4d/auth_gsasl.c (restore_and_return): Unref the contents
of str.
(auth_gsasl): Use MU_IOCTL_GET_STREAM/MU_IOCTL_SET_STREAM to
change the underlying transport streams.
* imap4d/io.c (imap4d_init_tls_server): Likewise.
* libproto/mailer/smtp_gsasl.c (insert_gsasl_stream): Likewise.
* pop3d/extra.c (pop3d_init_tls_server): Likewise.
* libproto/mailer/smtp_starttls.c (smtp_get_streams)
(smtp_set_streams): New functions.
(smtp_swap_streams): Remove.
(mu_smtp_starttls): Use smtp_get_streams and smtp_set_streams
instead of smtp_swap_streams.
* libproto/pop/pop3_stls.c (pop3_get_streams)
(pop3_set_streams): New functions.
(pop3_swap_streams): Remove.
(mu_pop3_stls): Use pop3_get_streams and pop3_set_streams.
* testsuite/smtpsend.c (main): Uncomment mu_stream_unref on the
carrier.
2010-09-25 Sergey Poznyakoff <gray@gnu.org.ua>
Fix prog streams.
* libmailutils/prog_stream.c (REDIRECT_STDIN_P)
(REDIRECT_STDOUT_P): Fix macros.
* libmailutils/stream.c (mu_stream_open): If stream is open
with MU_STREAM_APPEND, reposition to its end.
(_stream_write_unbuffered): Do not signal EACCES for
MU_STREAM_APPEND streams.
* mail/pipe.c (mail_pipe): Rewrite using streams instead of
FILEs.
* mail/send.c (fill_body): Likewise.
* mail/write.c (mail_write): Likewise.
2010-09-25 Sergey Poznyakoff <gray@gnu.org.ua>
Remove unnecessary use of FILEs in imap4d and pop3d.
* imap4d/imap4d.c (imap4d_mainloop): Take two file descriptor
as arguments. All uses updated.
* imap4d/imap4d.h (io_setio): Change signature.
* imap4d/io.c (io_setio): Take two file descriptor as
arguments. All uses updated.
* pop3d/extra.c (pop3d_setio): Take two file descriptor as
arguments. All uses updated.
* pop3d/pop3d.c (pop3d_mainloop): Likewise.
* pop3d/pop3d.h (pop3d_setio): Change signature.
2010-09-25 Sergey Poznyakoff <gray@gnu.org.ua>
Cleanup in bufferization code.
* examples/musocio.c: Use default stream buffer size.
* imap4d/io.c: Likewise.
* libmailutils/dbgstream.c: Likewise.
* libmailutils/iostream.c: Likewise.
* libmailutils/xscript-stream.c: Likewise.
* libmu_auth/gsasl.c: Likewise.
* libmu_auth/tls.c: Likewise.
* libproto/pop/mbox.c: Likewise.
* libproto/pop/pop3_stream.c: Likewise.
* pop3d/extra.c: Likewise.
* libmailutils/file_stream.c (mu_file_stream_create)
(mu_fd_stream_create): File streams are fully buffered by
default.
* libmailutils/stdio_stream.c (mu_stdio_stream_create): Stdio
streams are line buffered by default.
2010-09-25 Sergey Poznyakoff <gray@gnu.org.ua>
Bugfixes.
* libmailutils/streamcpy.c (mu_stream_copy): Use the number of
bytes actually read.
* libmailutils/base64.c (_base64_encoder): Return
mu_filter_again if not all data has been consumed on
mu_filter_lastbuf.
* libmailutils/message_stream.c (scan_stream): Fix calculation
of body_end.
(_body_obj_size): Fix calculation of body size.
* libproto/mailer/smtp_data.c (_mu_smtp_data_begin): Set full
buffering on the MU_TRANSPORT_OUTPUT stream.
2010-09-25 Sergey Poznyakoff <gray@gnu.org.ua>
Finish switching to new gnulib (see 52d2552d23).
* configure.ac: Use libmuaux.a instead of libmuaux.la.
* examples/Makefile.am: Likewise.
* examples/cpp/Makefile.am: Likewise.
* imap4d/Makefile.am: Likewise.
* mapi/Makefile.am: Likewise.
* mh/Makefile.am: Likewise.
* pop3d/Makefile.am: Likewise.
Remove old files from POTFILES.in (see c42bddb0b8).
* po/POTFILES.in: Remove comsat/oldcfg.c.
Build testsuites after the programs they are to test.
* frm/Makefile.am (SUBDIRS): Put . before tests.
* messages/Makefile.am: Likewise.
* readmsg/Makefile.am: Likewise.
* sieve/Makefile.am: Likewise.
Remove leftovers from CVS times:
* .cvsignore: Remove.
* am/.cvsignore: Remove.
* lib/.cvsignore: Remove.
* po/.cvsignore
2010-09-25 Sergey Poznyakoff <gray@gnu.org.ua>
Add back testsuite/etc/DISTFILES.
It is needed for the remaining DejaGNU tests and will go away
later, when they are rewritten.
2010-09-25 Sergey Poznyakoff <gray@gnu.org.ua>
Fix hex (%XX) expansion in URLs.
* mailbox/url.c (url_parse0): Take three arguments. Return in
the third one a boolean indicating whether to expand %XX
notations in the URL. Do not decode absolute file names and
pipes.
(mu_url_parse): Use this value to decide.
* movemail/movemail.c (main): In emacs mode: force UNIX mbox
format as a default. Send debugging output to stderr.
* libmailutils/tests/url.at: Add new tests.
2010-09-25 Sergey Poznyakoff <gray@gnu.org.ua>
Minor changes.
* am/debug.m4 (MU_DEBUG_MODE): Rewrite. Use
-Wdeclaration-after-statement if supported.
* comsat/oldcfg.c: Remove.
* comsat/Makefile.am (comsatd_SOURCES): Remove oldcfg.c.
* comsat/comsat.c: Remove the obsolete --config and
--convert-config options.
* comsat/comsat.h (convert_config): Remove.
2010-09-21 Sergey Poznyakoff <gray@gnu.org.ua>
Various SMTP improvements.
* Makefile.am: Shut up cmp's stderr.
* libmailutils/body.c (_body_get_stream): Set full buffering
mode on the body stream.
* libmailutils/errors (MU_ERR_AUTH_NO_CRED): New error code.
* libproto/mailer/smtp.c (smtp_open): Do not treat ENOSYS or
MU_ERR_AUTH_NO_CRED (returned by mu_smtp_auth) as errors.
(smtp_send_message): Do not try to submit the message if it is
bigger than the maximum imposed by the server.
* libproto/mailer/smtp_auth.c (mu_smtp_auth): Return
MU_ERR_AUTH_NO_CRED if neither user name nor password are
supplied.
* mail/send.c (mail_send0): Issue diagnostics if sending
attempt has failed.
2010-09-21 Wojciech Polak <polak@gnu.org>
Update C++ API and the examples.
* include/mailutils/cpp/pop3.h (capa): Add reread parameter.
(getline): Add new prototype.
(send, readline): Remove.
(response, stat): Change prototype.
* libmu_cpp/pop3.cc: Likewise.
* include/mailutils/cpp/stream.h
(read, write, readline): Change prototype.
(sequential_readline, sequential_write): Remove.
* libmu_cpp/stream.cc: Likewise.
2010-09-21 Sergey Poznyakoff <gray@gnu.org.ua>
Rewrite SMTP mailer.
* libproto/mailer/smtp.c: Rewrite using new SMTP API.
* libproto/mailer/smtp_quit.c (mu_smtp_quit): Return
immediately if already in closed state.
* libmailutils/ticket.c (mu_ticket_get_cred): Return
MU_ERR_FAILURE if all methods fail.
* mail/send.c: Port 23321cf7 from patches-2.2
(msg_to_pipe): Return status code.
(save_dead_message, send_message): New functions, extracted
from mail_send0.
(mail_send0): Call save_dead_message if sending failed.
2010-09-20 Sergey Poznyakoff <gray@gnu.org.ua>
Improve smtp sending functions.
* include/mailutils/smtp.h (mu_smtp_write): Mark as
printf-like.
(mu_smtp_mail_basic, mu_smtp_rcpt_basic): Take variable number
of arguments. Mark as printf-like.
(mu_smtp_data): New prototype.
* include/mailutils/sys/smtp.h (_MU_SMTP_SAVEBUF): New flag.
(_mu_smtp) <savebuf>: New member.
(_mu_smtp_data_begin, _mu_smtp_data_end): New protos.
* libproto/mailer/smtp_send.c: New file.
* libproto/mailer/smtp_data.c (_mu_smtp_data_begin)
(_mu_smtp_data_end, mu_smtp_data): New functions.
* libproto/mailer/Makefile.am (libmu_mailer_la_SOURCES): Add
smtp_send.c.
* libproto/mailer/smtp_ehlo.c (mu_smtp_ehlo): Switch to
MU_SMTP_EHLO only if in MU_SMTP_MAIL state.
* libproto/mailer/smtp_mail.c (mu_smtp_mail_basic): Take
variable number of arguments.
* libproto/mailer/smtp_param.c (mu_smtp_get_param): Add missing
typecast.
* libproto/mailer/smtp_rcpt.c (mu_smtp_rcpt_basic): Take
variable number of arguments.
* libproto/mailer/smtp_send.c (_smtp_data_send): Use
_mu_smtp_data_begin and _mu_smtp_data_end.
* testsuite/smtpsend.c: Emulate sending from a MU message.
2010-09-20 Sergey Poznyakoff <gray@gnu.org.ua>
Stream improvements.
* include/mailutils/stream.h (mu_stream_printf): Mark as
printf-like.
* include/mailutils/sys/stream.h (_MU_STR_EVENT_CLOSE): New
event.
(_mu_stream) <event_cb_data>: New member.
* libmailutils/stream.c (mu_stream_seek): Avoid unnecessary
seeks in mu_buffer_none mode. Complements 906499db.
(mu_stream_close): Mark _MU_STR_EVENT_CLOSE event.
2010-09-20 Sergey Poznyakoff <gray@gnu.org.ua>
Bugfix in message_stream.c.
* libmailutils/message_stream.c (scan_stream): Change
signature. All uses updated. Correct the calculation of
body_start.
(mu_message_stream_create): Return the stream.
2010-09-19 Sergey Poznyakoff <gray@gnu.org.ua>
Improve authentication interface in SMTP client.
* include/mailutils/smtp.h (MU_SMTP_PARAM_URL): New parameter
code.
* include/mailutils/sys/smtp.h (_MU_SMTP_CLNPASS): New flag.
(_mu_smtp) <secret>: New member.
* libproto/mailer/smtp_auth.c (get_ticket)
(_mu_smtp_fixup_params): New static functions.
(mu_smtp_auth): Call _mu_smtp_fixup_params to supply missing
parameters.
* libproto/mailer/smtp_create.c (mu_smtp_destroy): Destroy
secret. Take care to erase eventual plaintext representation of
the password.
* libproto/mailer/smtp_gsasl.c (_smtp_callback): Use
mu_smtp_get_param to obtain parameters.
* libproto/mailer/smtp_param.c (mu_smtp_set_param): Setting
MU_SMTP_PARAM_PASSWORD updates secret.
param[MU_SMTP_PARAM_PASSWORD] points (temporarily and on
request only) to plaintext password.
(mu_smtp_get_param): Likewise for retrieving password.
* testsuite/smtpsend.c (main): New parameter url=.
2010-09-19 Sergey Poznyakoff <gray@gnu.org.ua>
Bugfixes.
* libmu_auth/gsasl.c (_gsasl_encoder,_gsasl_decoder): Do not
free flt.
* include/mailutils/stream.h [__cplusplus]: Protect contents by
extern "C".
2010-09-19 Sergey Poznyakoff <gray@gnu.org.ua>
Avoid unnecessary rebuilds of git-describe and git-describe.h.
* Makefile.am: Avoid unnecessary rebuilds of git-describe and
git-describe.h
2010-09-19 Sergey Poznyakoff <gray@gnu.org.ua>
Bugfix.
* libmailutils/stream.c (_mu_stream_create): Mask out internal
flags.
* pop3d/pop3d.c (main): Do not handle SIGPIPE, to avoid
infinite recursion.
2010-09-19 Sergey Poznyakoff <gray@gnu.org.ua>
* testsuite/smtpsend.c (main): Retry ehlo after successful
authentication.
2010-09-18 Sergey Poznyakoff <gray@gnu.org.ua>
Implement SMTP AUTH (via GSASL).
* configure.ac (MU_COND_GSASL): New cond.
* include/mailutils/smtp.h (MU_SMTP_PARAM_DOMAIN)
(MU_SMTP_PARAM_USERNAME, MU_SMTP_PARAM_PASSWORD)
(MU_SMTP_PARAM_SERVICE, MU_SMTP_PARAM_REALM)
(MU_SMTP_PARAM_HOST, MU_SMTP_MAX_PARAM): New constants.
(mu_smtp_set_domain, mu_smtp_get_param): Remove.
(mu_smtp_set_param, mu_smtp_get_param): New prototypes.
(mu_smtp_auth, mu_smtp_add_auth_mech)
(mu_smtp_add_auth_mech_list, mu_smtp_mech_select): New
prototypes.
* include/mailutils/sys/smtp.h (_mu_smtp) <domain>: Remove.
(_mu_smtp) <authimpl, param, authmech>: New members.
(_mu_smtp_gsasl_auth, _mu_smtp_mech_impl): New prototypes.
* libproto/mailer/Makefile.am [MU_COND_GSASL]: Define
SMTP_GSASL.
(libmu_mailer_la_SOURCES): Add new sources.
* libproto/mailer/smtp_domain.c: Remove.
* libproto/mailer/smtp_param.c: New file.
* libproto/mailer/smtp_mech.c: New file.
* libproto/mailer/smtp_auth.c: New file.
* libproto/mailer/smtp_gsasl.c: New file.
* libproto/mailer/smtp_create.c (mu_smtp_destroy): Free new
members of struct _mu_smtp.
* libproto/mailer/smtp_ehlo.c (mu_smtp_ehlo): Use
param[MU_SMTP_PARAM_DOMAIN] instead of domain.
* testsuite/smtpsend.c: Handle SMTP AUTH.
* libmu_auth/gsasl.c (mu_gsasl_stream_create): Bugfix.
* libmailutils/xscript-stream.c (_xscript_ctl)
<MU_IOCTL_SWAP_STREAM>: If instream!=outstream, combine them
first into an iostream.
2010-09-18 Sergey Poznyakoff <gray@gnu.org.ua>
smtp client: implement more functions.
* include/mailutils/smtp.h (mu_smtp_mail_basic)
(mu_smtp_rcpt_basic, mu_smtp_send_stream)
(mu_smtp_rset, mu_smtp_quit): New prototypes.
* include/mailutils/sys/smtp.h (MU_SMTP_RCPT)
(MU_SMTP_MORE, MU_SMTP_DOT, MU_SMTP_QUIT, MU_SMTP_CLOS): New
states.
(_mu_smtp_xscript_level): New proto.
* libmailutils/errors (MU_ERR_REPLY): New error code.
* libproto/mailer/Makefile.am (libmu_mailer_la_SOURCES): Add
new sources.
* libproto/mailer/smtp_data.c: New file.
* libproto/mailer/smtp_mail.c: New file.
* libproto/mailer/smtp_quit.c: New file.
* libproto/mailer/smtp_rcpt.c: New file.
* libproto/mailer/smtp_rset.c: New file.
* libproto/mailer/smtp_ehlo.c: Return MU_ERR_REPLY if the
server replied with a code other than 2xx.
* libproto/mailer/smtp_open.c: Likewise.
* testsuite/smtpsend.c: Implement full sending cycle (excepting
authorization).
2010-09-18 Sergey Poznyakoff <gray@gnu.org.ua>
Bugfixes in the sieve testsuite.
* sieve/tests/reject.at: Fix dependency on TZ.
* sieve/tests/relational.at: Ensure that fileintos go to the
test folder.
* sieve/tests/mul-addr.at: Remove unneeded require.
2010-09-17 Sergey Poznyakoff <gray@gnu.org.ua>
Begin new implementation of the SMTP client.
* include/mailutils/smtp.h: New file.
* include/mailutils/Makefile.am (pkginclude_HEADERS): Add
smtp.h.
* include/mailutils/list.h (mu_list_clear): New proto.
* include/mailutils/sys/smtp.h: New file.
* include/mailutils/sys/Makefile.am (sysinclude_HEADERS): Add
smtp.h.
* libmailutils/errors (MU_ERR_BADREPLY, MU_ERR_SEQ): New error
codes.
* libmailutils/list.c (mu_list_clear): New function.
* libproto/mailer/Makefile.am (libmu_mailer_la_SOURCES): Add
new sources.
* libproto/mailer/smtp_capa.c: New file.
* libproto/mailer/smtp_carrier.c: New file.
* libproto/mailer/smtp_create.c: New file.
* libproto/mailer/smtp_disconnect.c: New file.
* libproto/mailer/smtp_domain.c: New file.
* libproto/mailer/smtp_ehlo.c: New file.
* libproto/mailer/smtp_io.c: New file.
* libproto/mailer/smtp_open.c: New file.
* libproto/mailer/smtp_starttls.c: New file.
* libproto/mailer/smtp_trace.c: New file.
* testsuite/smtpsend.c: New file.
* testsuite/Makefile.am (noinst_PROGRAMS): Add smtpsend.
2010-09-17 Sergey Poznyakoff <gray@gnu.org.ua>
Update for gnulib v0.0-4270-g18aae5b.
* bootstrap.conf: Build included listings in doc/texinfo.
* configure.ac: Require gettext 0.18
* doc/texinfo/Makefile.am: Remove the .c.inc rules.
* doc/texinfo/maint.mk: New file.
* lib/Makefile.am (libmuaux_la_SOURCES): Replace with
libmuaux_a_SOURCES.
2010-09-17 Sergey Poznyakoff <gray@gnu.org.ua>
testsuite: recreate missing maildir entries.
Git does not keep empty subdirectories, so we need to recreate
/cur and /tmp subdirs in maildir mailboxes retrieved from the
repo.
* bootstrap.conf: Recreate missing maildir parts.
* testsuite/testsuite.inc (MUT_MBCOPY): New macro.
* sieve/tests/ext.at: Use MUT_MBCOPY to copy mailboxes.
* sieve/tests/redirect.at: Likewise.
* sieve/tests/reject.at: Likewise.
* sieve/tests/testsuite.at: Likewise.
* testsuite/mbdel.at: Likewise.
* frm/tests/Makefile.am: Testsuite depends on
$(top_srcdir)/testsuite/testsuite.inc.
* libmailutils/tests/Makefile.am: Likewise.
* messages/tests/Makefile.am: Likewise.
* readmsg/tests/Makefile.am: Likewise.
* sieve/tests/Makefile.am: Likewise.
* testsuite/Makefile.am: Likewise.
2010-09-17 Sergey Poznyakoff <gray@gnu.org.ua>
Further improvement of the testsuite + some bugfixes.
That's the first commit since the merge six days ago that
passes distcheck (with python, cxx, imap and nntp disabled, of
course).
* testsuite/folder/DISTFILES: Restore. It is needed for some of
the remaining DejaGNU tests.
* testsuite/spool/DISTFILES: Likewise.
* testsuite/testsuite.at: New file.
* testsuite/atlocal.in: New file.
* libmailutils/tests/mbdel.at: Move to testsuite/.
* libmailutils/tests/mbdel.c: Likewise.
* libmailutils/tests/mime.at: Likewise.
* libmailutils/tests/mimetest.c: Likewise.
* Makefile.am (SUBDIRS): Place testsuite after libproto.
* configure.ac (AM_INIT_AUTOMAKE): Remove dist-lzma.
(AC_CONFIG_FILES): Add testsuite/atlocal.
* libmailutils/base64.c (_base64_decoder)
(_base64_encoder): Fix the use of uninitialized variables.
* libmailutils/tests/.gitignore: Remove mbdel and mimetest.
* libmailutils/tests/Makefile.am (noinst_PROGRAMS): Remove
mbdel and mimetest.
(LDADD): Leave only MU_LIB_MAILUTILS.
(TESTSUITE_AT): Remove mbdel.at and mime.at
* libmailutils/tests/atlocal.in (PATH): Bugfix.
* libmailutils/tests/testsuite.at: Remove inclusion of mbdel.at
and mime.at.
* po/POTFILES.in: Replace mailbox/ with libmailutils/.
* testsuite/.gitignore: Rewrite.
* testsuite/Makefile.am: Rewrite.
* testsuite/mbdel.at: Set +w on all copied mailboxes.
* testsuite/mimetest.c (main): Open mailbox for reading only.
* sieve/Makefile.am: Add examples/ to the distribution.
* libproto/mbox/mbox.c (mbox_open): Create locker only if the
mailbox is open for modification. All users updated to check
for mailbox->locker!=NULL before using it.
2010-09-16 Sergey Poznyakoff <gray@gnu.org.ua>
Test mailbox deletion.
* libmailutils/tests/mbdel.at: New testcase.
* libmailutils/tests/Makefile.am (TESTSUITE_AT): Add mbdel.at.
* libmailutils/tests/testsuite.at: Include mbdel.at.
* libproto/mbox/mbox.c (mbox_remove): Fix return code.
* testsuite/maildir/mbox1: New test mailbox.
* testsuite/mh/mbox1: New test mailbox.
* testsuite/etc/DISTFILES: Remove.
* testsuite/folder/DISTFILES: Remove.
* testsuite/lib/DISTFILES: Remove.
* testsuite/Makefile.am: Use EXTRA_DIST to distribute subdirs.
2010-09-16 Sergey Poznyakoff <gray@gnu.org.ua>
Minor fix.
* libmailutils/mailbox.c (mu_mailbox_open): Return MU_ERR_OPEN
if the mailbox has already been opened.
2010-09-16 Sergey Poznyakoff <gray@gnu.org.ua>
Implement `remove' method for mailboxes.
* include/mailutils/mailbox.h (mu_mailbox_remove): New
function.
* include/mailutils/stream.h: Add some comments.
* include/mailutils/sys/amd.h (_amd_data)<remove>: New method.
(amd_remove_dir): New function.
* include/mailutils/sys/mailbox.h (_mu_mailbox)<_remove>: New
method.
* libmailutils/amd.c (amd_remove_mbox): New function.
(amd_init_mailbox): Initialize the _remove method.
(amd_remove_dir): New function.
* libmailutils/errors (MU_ERR_MBX_REMOVED)
(MU_ERR_NOT_OPEN, MU_ERR_OPEN): New error codes.
* libmailutils/mailbox.c: Keep state of the mailbox (open vs.
not open, removed). Check it before doing anything on it.
(_MU_MAILBOX_OPEN, _MU_MAILBOX_REMOVED, _MU_MAILBOX_MASK): New
defines.
(mu_mailbox_open): Set _MU_MAILBOX_OPEN if the operation
succeeds.
(mu_mailbox_close): Clear _MU_MAILBOX_OPEN if the operation
succeeds. Refuse to run if the mailbox was not opened.
(mu_mailbox_remove): New function.
(all functions): return MU_ERR_MBX_NULL if the mbox argument is
NULL. Check mailbox state on entry and proceed accordingly.
* libproto/maildir/mbox.c: Implement _remove method.
(maildir_remove): New function.
(_mailbox_maildir_init): Initialize amd->_remove.
* libproto/mbox/mbox.c: Implement _remove method.
(mbox_remove): New function.
(_mailbox_mbox_init): Initialize amd->_remove.
* libproto/mh/mbox.c: Implement _remove method.
(mh_remove): New function.
(_mailbox_mh_init): Initialize amd->_remove.
* libmailutils/tests/mbdel.c: New file.
* libmailutils/tests/.gitignore: Add mbdel.
* libmailutils/tests/Makefile.am (noinst_PROGRAMS): Likewise.
(LDADD): List all mailbox formats.
* imap4d/delete.c (imap4d_delete): Use mu_mailbox_remove to
delete the folder. Fall back to remove() if it does not appear
to be a mailbox.
2010-09-15 Sergey Poznyakoff <gray@gnu.org.ua>
libmailutils/tests: test list and iterator operations.
* examples/listop.c: Move to libmailutils/tests.
* examples/Makefile.am (noinst_PROGRAMS): Remove listop.
* libmailutils/tests/Makefile.am (noinst_PROGRAMS): Add listop.
(TESTSUITE_AT): Add list.at.
* libmailutils/tests/.gitignore: New file.
* libmailutils/tests/list.at: New file.
* libmailutils/tests/testsuite.at: Include list.at.
* libmailutils/list.c (list_itrctl): Fix mu_itrctl_replace.
2010-09-15 Sergey Poznyakoff <gray@gnu.org.ua>
Optimize libmailutils testsuite.
* libmailutils/tests/testsuite.at (MU_TEST_GROUP)
(MU_TEST_KEYWORDS, MU_TEST_COMMAND): New defines.
(mu_trimstr, mu_firstline): New macros.
(MU_GENERIC_TEST): New macro.
* libmailutils/tests/addr.c: Accept addresses from stdin.
* libmailutils/tests/address.at (TESTADDR): If the address
contains single quotes, pass it to the program via stdin.
Uncomment all such tests.
* libmailutils/tests/argcv.at (TESTARGS): Rewrite as a wrapper
over MU_GENERIC_TEST.
* libmailutils/tests/decode2047.at (TESTDEC2047): Likewise.
* libmailutils/tests/mailcap.at (MAILCAP): Likewise.
* libmailutils/tests/url.at (TESTURL): Likewise.
* libmailutils/tests/mailcap.c: Accept data from stdin.
2010-09-15 Sergey Poznyakoff <gray@gnu.org.ua>
Bugfix.
* libmailutils/Makefile.am (SUBDIRS): Make sure tests are
descended into only when the libmailutils library is already
built.
2010-09-15 Sergey Poznyakoff <gray@gnu.org.ua>
Rewrite testsuite for messages in Autotest.
* configure.ac: Remove messages/testsuite
* messages/Makefile.am (SUBDIRS): Replace testsuite with tests.
* messages/tests/.gitignore: New file.
* messages/tests/Makefile.am: New file.
* messages/tests/atlocal.in: New file.
* messages/tests/testsuite.at: New file.
* messages/testsuite: Remove.
2010-09-15 Sergey Poznyakoff <gray@gnu.org.ua>
Rewrite libmailutils testsuite in Autotest.
* configure.ac: Create libmailutils/tests/atlocal and
libmailutils/tests/Makefile. Remove libmailutils/testsuite.
* examples/Makefile.am (noinst_PROGRAMS): Remove programs moved
to libmailutils/tests.
* examples/argcv.c -> libmailutils/tests/argcv.c
* libmailutils/testsuite/Decode -> libmailutils/tests/Decode
* libmailutils/testsuite/Encode -> libmailutils/tests/Encode
* examples/decode2047.c: Move to libmailutils/tests
* examples/encode2047.c: Move to libmailutils/tests
* examples/mailcap.c: Likewise.
* examples/url-parse.c: Likewise.
* include/mailutils/Makefile.am: Minor changes.
* libmailutils/Makefile.am (SUBDIRS): Replace testsuite with
tests.
* libmailutils/tests/Makefile.am: New file.
* libmailutils/tests/addr.c: New file.
* libmailutils/tests/address.at: New file.
* libmailutils/tests/argcv.at: New file.
* libmailutils/tests/atlocal.in: New file.
* libmailutils/tests/base64d.at: New file.
* libmailutils/tests/base64e.at: New file.
* libmailutils/tests/decode2047.at: New file.
* libmailutils/tests/encode2047.at: New file.
* libmailutils/tests/fltst.c: New file.
* libmailutils/tests/mailcap.at: New file.
* libmailutils/tests/mime.at: New file.
* libmailutils/tests/testsuite.at: New file.
* libmailutils/tests/url.at: New file.
* libmailutils/testsuite/: Delete.
* frm/tests/Makefile.am: Prefix package.m4 creation commands
with $(AM_V_GEN).
* readmsg/tests/Makefile.am: Likewise.
* sieve/tests/Makefile.am: Likewise.
* frm/tests/testsuite.at: Minor changes.
* readmsg/tests/testsuite.at: Include testsuite.inc.
* sieve/tests/testsuite.at: Likewise.
* sieve/tests/version.at: Comment out inclusion of
testsuite.inc.
* testsuite/testsuite.inc: Add m4_version_prereq.
2010-09-14 Sergey Poznyakoff <gray@gnu.org.ua>
Rename mailbox/ to libmailutils/.
This change has been waiting since 2005-08-16
(aaab88142c8193f1), when libmailbox had been renamed to
libmailutils. Back then MU was still under CVS, which didn't
like renames.
2010-09-14 Sergey Poznyakoff <gray@gnu.org.ua>
Rewrite readmsg testsuite in Autotest.
* configure.ac: Add readmsg/tests/
* readmsg/Makefile.am: New file.
* readmsg/tests/.gitignore: New file.
* readmsg/tests/Makefile.am: New file.
* readmsg/tests/all.at: New file.
* readmsg/tests/atlocal.in: New file.
* readmsg/tests/hdr.at: New file.
* readmsg/tests/nohdr.at: New file.
* readmsg/tests/testsuite.at: New file.
* readmsg/tests/twomsg.at: New file.
* readmsg/tests/weed.at: New file.
* readmsg/testsuite: Remove.
* testsuite/testsuite.inc (AT_SKIP_TEST): New macro.
* testsuite/spool/mbox1: Remove trailing whitespace after
Received headers.
* imap4d/testsuite/imap4d/fetch.exp: Reflect changes in mbox1.
* mail/testsuite/mail/read.exp: Likewise.
* mail/testsuite/mail/write.exp: Likewise.
* mailbox/testsuite/Mime: Likewise.
2010-09-14 Sergey Poznyakoff <gray@gnu.org.ua>
Rewrite frm testsuite in Autotest.
* configure.ac: Build frm/testsuite/Makefile.am and atlocal.
Remove frm/testsuite/Makefile.
* testsuite/testsuite.inc: New file.
* frm/testsuite: Remove DejaGNU-based testsuite.
* frm/tests: Autotest-based testsuite.
* frm/tests/.gitignore
* frm/tests/Makefile.am
* frm/tests/atlocal.in
* frm/tests/testsuite.at
* frm/Makefile.am (SUBDIRS): Replace testsuite with tests.
* sieve/tests/Makefile.am (TESTSUITE): Add an include option.
* sieve/tests/version.at: Use macro from testsuite.inc.
2010-09-14 Sergey Poznyakoff <gray@gnu.org.ua>
Remove files that are not necessary any more.
* sieve/examples/INBOX.orig
* sieve/examples/Test
* sieve/examples/test.out
2010-09-14 Sergey Poznyakoff <gray@gnu.org.ua>
Rewrite Sieve testsuite in Autotest.
* mailbox/cfg_parser.y (mu_cfg_create_subtree): Optional prefix
character may be used to alter the separator or to suppress
value splitting.
2010-09-13 Sergey Poznyakoff <gray@gnu.org.ua>
Optimize stream seeks and I/O. Expand stream event handlers.
Rewrite xscript stream.
* include/mailutils/sys/stream.h (_MU_STR_EVENT_SET): Rename to
_MU_STR_EVENT_SET.
(_MU_STR_EVENT_CLR): Rename to _MU_STR_EVENT_CLRFLAG.
(_MU_STR_EVENT_FILLBUF, _MU_STR_EVENT_FLUSHBUF): New event
codes.
(_MU_STR_EVMASK): New macro.
(_mu_stream) <cur>: Replace with pos, indicating current
position in the buffer.
(event_cb): Change signature.
(mu_stream_read_unbuffered): Remove.
(mu_stream_write_unbuffered): Remove.
* mailbox/iostream.c (mu_iostream_create): Provide the
readdelim method only if the underlying input transport stream
provides it.
* mailbox/streamref.c (mu_streamref_create_abridged): Likewise.
* mailbox/stream.c (_stream_event): New macro.
(mu_stream_read_unbuffered): Rename to static
_stream_read_unbuffered.
(mu_stream_write_unbuffered): Rename to static
_stream_write_unbuffered. (_stream_advance_buffer,
_stream_buffer_offset)
(_stream_orig_level): Remove macros.
(_stream_buffer_freespace): Rewrite.
(_stream_curp): New macro.
(_stream_fill_buffer): Make sure the `offset' indicates the
offset int the transport, corresponding to the beginning of the
current buffer.
(_stream_flush_buffer): Essentially rewritten.
(mu_stream_seek): Reflect changes to the _mu_stream structure.
Optimize calls to the seek method.
(_stream_skip_input_bytes): Likewise.
(mu_stream_read, _stream_scandelim, mu_stream_write): Rewrite
using new _mu_stream structure.
* mailbox/xscript-stream.c: Rewrite using stream events.
* mailbox/base64.c (_base64_encoder): Bugfix.
* libproto/pop/pop3_stream.c (_pop3_event_cb): Update signature
to match the changes above.
* examples/mimetest.c (main): Add more error checking.
* mail/testsuite/mail/write.exp: Minor fix.
2010-09-12 Sergey Poznyakoff <gray@gnu.org.ua>
Mailbox quota support in imap4d: initial implementation.
* imap4d/quota.c: New file.
* imap4d/Makefile.am (imap4d_SOURCES): Add quota.c
* imap4d/append.c (imap4d_append0): Refuse to append if the
quota is exceeded or would be exceeded after completing the
operation.
* imap4d/copy.c (imap4d_copy0): Refuse to copy messages if the
quota is exceeded or would be exceeded after completing the
operation. Return a meaningful textual description. Attempt to
restore mailbox to its original size if the operation failed.
* imap4d/imap4d.c (imap4d_session_setup0): Call quota_setup.
* imap4d/imap4d.h (quota_setup, quota_check, quota_update): New
functions.
* include/mailutils/folder.h (mu_list_response) <format>: New
member.
* include/mailutils/mailbox.h (mu_mailbox_create_from_record):
New function.
* include/mailutils/types.hin (MU_FOLDER_ATTRIBUTE_LINK): New
flag.
* libproto/mbox/folder.c (list_helper): Do not return symbolic
links unless MU_FOLDER_ATTRIBUTE_LINK is set. Fill in the
resp->format member.
* mailbox/mailbox.c (_mailbox_create_from_record): New static
function.
(_create_mailbox0): Rewrite as a wrapper over
_mailbox_create_from_record.
(mu_mailbox_create_from_record): New function.
2010-09-12 Sergey Poznyakoff <gray@gnu.org.ua>
movemail: bugfix.
* movemail/movemail.c (guess_mbox_owner): Fix setting GID with
--owner=set-id.
(main): Don't attempt to expunge source mailbox if
preserve_mail is set.
2010-09-12 Sergey Poznyakoff <gray@gnu.org.ua>
amd: bugfix.
* mailbox/amd.c (read_size_file): Fix return value.
2010-09-12 Sergey Poznyakoff <gray@gnu.org.ua>
Bugfix.
* libproto/pop/pop3_stream.c (_pop3_event_cb)
(mu_pop3_filter_create): Fix buffer size manipulation.
* libmu_auth/tls.c: Protect gnutls debugging code with
DEBUG_TLS.
2010-09-11 Sergey Poznyakoff <gray@gnu.org.ua>
Reimplement POP3 I/O over the DOT and CRLFDOT filters.
As a side note, previous versions of pop3d did not do
byte-stuffing when sending RETR output. This commit fixes it.
* include/mailutils/filter.h (mu_dot_filter): New filter.
* mailbox/dot.c: New file.
* mailbox/Makefile.am (libmailutils_la_SOURCES): Add dot.c
* mailbox/crlfdot.c (_crlfdot_encoder): Bugfix. Do not
dereference iobuf until we know it is not NULL.
* mailbox/filter.c (mu_filter_get_list): Register
mu_dot_filter.
* mailbox/fltstream.c (filter_wr_close, filter_rd_close): New
close methods, depending on the filter stream mode.
(mu_filter_stream_create): Set filter_rd_close for
MU_STREAM_READ and filter_wr_close for MU_STREAM_WRITE streams.
* mailbox/stream.c (mu_stream_readdelim): Update stream offset
when using stream->readdelim.
* pop3d/pop3d.h (pop3d_send_payload): New proto.
* pop3d/retr.c (pop3d_send_payload): Change function to be
optionally used in pop3d_top. Use DOT filter on output.
* pop3d/top.c (pop3d_top): Rewrite using pop3d_send_payload.
* libproto/pop/pop3_retr.c (mu_pop3_retr): Default return code
is EINPROGRESS.
* libproto/pop/pop3_stream.c: Remove the filter stuff. Use
CRLFDOT instead.
* mailbox/amd.c (amd_body_stream_readdelim): Bugfix. Increase
offset by nread bytes.
2010-09-11 Sergey Poznyakoff <gray@gnu.org.ua>
Improve filter framework. Implement a CRLFDOT filter.
* include/mailutils/filter.h (mu_filter_command)
<mu_filter_flush> New command.
(mu_filter_result) <mu_filter_again>: New result code.
(MU_FILTER_MAX_AGAIN): New constant.
(mu_crlfdot_filter): New filter.
* include/mailutils/sys/stream.h (_MU_STR_DIRTY, _MU_STR_WRT)
(_MU_STR_ERR, _MU_STR_EOF, _MU_STR_INTERN_MASK): Avoid
conflicts with MU_STREAM_ constants from mailutils/stream.h
* mailbox/crlfdot.c: New source.
* mailbox/Makefile.am (libmailutils_la_SOURCES): Add crlfdot.c.
* mailbox/filter.c (mu_filter_get_list): Register
mu_crlfdot_filter.
* mailbox/fltstream.c (init_iobuf): Fix initialization of isize
and input.
(filter_read): Redo the loop, allowing xcode to request a new
iteration by returning mu_filter_again.
(filter_write_internal): Likewise.
(filter_wr_flush): Call filter_write_internal with
mu_filter_flush, reserving mu_filter_lastbuf for really last
buffers.
(filter_close): Call filter_write_internal with
mu_filter_lastbuf.
* mailbox/stream.c (mu_stream_skip_input_bytes): Clear
MU_STREAM_SEEK bit before actually doing anything.
* include/mailutils/sys/pop3.h [DMALLOC]: Remove unneeded cond.
2010-09-10 Sergey Poznyakoff <gray@gnu.org.ua>
Version 2.2.90.
2010-09-09 Sergey Poznyakoff <gray@gnu.org.ua>
Optimize I/O bufferization.
New ioctls MU_IOCTL_GET_TRANSPORT_BUFFER and
MU_IOCTL_SET_TRANSPORT_BUFFER return and modify bufferization
mode in the lowest level transport stream. Both server and
client programs use this to switch to full buffering before
sending large amounts of data. This has a particular impact on
the output speed and CPU usage when TLS is in use.
* include/mailutils/stream.h (MU_IOCTL_GET_TRANSPORT_BUFFER)
(MU_IOCTL_SET_TRANSPORT_BUFFER): New ioctls.
(MU_TRANSPORT_INPUT, MU_TRANSPORT_OUTPUT): New constants.
(MU_TRANSPORT_VALID_TYPE): New macro.
(mu_buffer_query): New struct.
(mu_stream_get_buffer): New proto.
* libmu_auth/tls.c (_tls_io_ioctl): Return ENOSYS if op is not
supported.
(_tls_ioctl): Support MU_IOCTL_[GS]ET_TRANSPORT_BUFFER.
* mailbox/file_stream.c (fd_ioctl): Support
MU_IOCTL_[GS]ET_TRANSPORT_BUFFER. Return ENOSYS if op is not
supported.
* mailbox/filter_iconv.c (_icvt_ioctl): Likewise.
* mailbox/iostream.c (_iostream_ctl): Likewise.
* mailbox/mapfile_stream.c (_mapfile_ioctl): Likewise.
* mailbox/memory_stream.c (_memory_ioctl): Likewise.
* mailbox/rdcache_stream.c (rdcache_ioctl): Likewise.
* mailbox/xscript-stream.c (_xscript_ctl): Likewise.
* mailbox/prog_stream.c (_prog_ioctl): Return ENOSYS if op is
not supported.
* mailbox/tcp.c (_tcp_ioctl): Likewise.
* mailbox/stream.c (mu_stream_default_buffer_size): New global.
(mu_stream_seek): Do not call seek method if the requested
offset is the same as the current one.
(mu_stream_set_buffer): Size==0 means use the default value.
(mu_stream_get_buffer): New function.
(mu_stream_truncate): Flush the buffer before truncating.
* mailbox/mime.c (mime_reset_state): New function.
(_mime_body_stream_seek): Rewrite using mime_reset_state.
(_mime_body_stream_ioctl): Return ENOSYS if op is not
supported.
(create_mime_body_stream): Reset mime state
(_mime_body_stream_seek may not be called due to the
optimization in mu_stream_seek.
* mailbox/header.c (header_parse): Exit correctly if the buffer
is not terminated with a \n.
* libproto/mbox/mbox.c (mbox_open): Enforce full buffering on
the mailbox stream.
* libproto/pop/mbox.c (pop_header_fill): Minor fix.
* libproto/pop/pop3_stream.c (_POP3F_DONE)
(_POP3F_CHBUF): New constants.
(mu_pop3_stream)<done>: Remove. Replaced with flags.
<oldbuf>: New member.
(_pop3_event_cb): If _POP3F_CHBUF flag is set, restore the
initial buffering mode on the transport stream.
(mu_pop3_filter_create): Save away current buffering mode and
enforce full buffering while transferring bulk data.
* mail/from.c (hdr_from): Check return value from
mu_message_get_header.
* mail/mail.c (main): Allow for MAILRC having empty value.
Always close the mailbox before exiting.
* pop3d/pop3d.c (pop3d_cfg_param): New statement
output-buffer-size.
* pop3d/pop3d.h (pop3d_output_bufsize): New global.
* pop3d/retr.c (pop3d_send_payload): New function.
(pop3d_retr): Rewrite using pop3d_send_payload. Save away
current buffering mode and enforce full buffering while
transferring bulk data.
* pop3d/top.c (pop3d_top_: Likewise.
2010-09-09 Sergey Poznyakoff <gray@gnu.org.ua>
Bugfix.
* mailbox/url.c (ACCESSOR(is_same,field)): Fix coredump if one
of the accessors returned MU_ERR_NOENT.
2010-09-09 Sergey Poznyakoff <gray@gnu.org.ua>
Remove leftovers of ARG_LICENSE option from MH.
2010-09-08 Sergey Poznyakoff <gray@gnu.org.ua>
Rename XSCRIPT_ macros to MU_XSCRIPT.
2010-09-08 Sergey Poznyakoff <gray@gnu.org.ua>
Improve transcript stream.
* include/mailutils/stream.h (MU_IOCTL_LEVEL): New ioctl op.
(XSCRIPT_NORMAL, XSCRIPT_SECURE, XSCRIPT_PAYLOAD): New
constants.
* include/mailutils/sys/xscript-stream.h (_mu_xscript_stream)
<level>: New member.
* mailbox/xscript-stream.c (TRANS_DISABLED): New flag.
(print_transcript): Amount of output varies depending on the
current output level. For secure data, try to recognize
passwords and to replace them with *** on output.
(_xscript_ctl): Support MU_IOCTL_LEVEL.
* pop3d/extra.c (set_xscript_level): New function.
* pop3d/pop3d.h (set_xscript_level): New proto.
* pop3d/retr.c (pop3d_retr): Set XSCRIPT_PAYLOAD level before
sending actual data and reset it to XSCRIPT_NORMAL afterward.
* pop3d/top.c (pop3d_top): Likewise.
* pop3d/user.c: Set XSCRIPT_SECURE level while expecting the
PASS command.
* imap4d/fetch.c (imap4d_fetch): Run imap4d_fetch0 in
XSCRIPT_PAYLOAD level.
* imap4d/uid.c (imap4d_uid): Likewise.
* imap4d/imap4d.c (imap4d_mainloop): Unless started in preauth
mode, select XSCRIPT_SECURE mode until authentication has been
passed.
* imap4d/imap4d.h (set_xscript_level): New proto.
* imap4d/io.c (io_format_completion_response): Switch to
XSCRIPT_NORMAL level when changing to the authenticated state.
(imap4d_readline): Read literals in XSCRIPT_PAYLOAD level.
* imap4d/util.c (set_xscript_level): New function.
* include/mailutils/pop3.h (mu_pop3_trace_mask): New prototype.
(MU_POP3_XSCRIPT_MASK): New macro.
(_mu_pop3_xscript_level): New proto.
* libproto/pop/pop3_pass.c (mu_pop3_pass): Set XSCRIPT_SECURE
while sending the password.
* libproto/pop/pop3_retr.c (mu_pop3_retr): Set XSCRIPT_PAYLOAD
before going to MU_POP3_RETR_RX state.
* libproto/pop/pop3_stream.c (_pop3_event_cb): Set
XSCRIPT_NORMAL.
* libproto/pop/pop3_top.c (mu_pop3_top): Set XSCRIPT_PAYLOAD
before going to MU_POP3_TOP_RX state.
* libproto/pop/pop3_trace.c (mu_pop3_trace_mask)
(_mu_pop3_xscript_level): New functions.
* libproto/pop/mbox.c (pop_open): Set trace masks depending on
the trace6 and trace7 debug levels.
* examples/pop3client.c (com_verbose): Allow to mask/unmask
transcript levels.
2010-09-08 Sergey Poznyakoff <gray@gnu.org.ua>
Finish pop3 mailbox implementation.
* mailbox/msgscan.c: New file.
* mailbox/Makefile.am (libmailutils_la_SOURCES): Add it.
* include/mailutils/body.h (mu_body_set_get_stream): New
prototype.
* include/mailutils/message.h (MU_SCAN_SEEK, MU_SCAN_SIZE): New
defines.
(mu_message_scan): New structure.
(mu_stream_scan_message): New prototype.
(mu_message_set_get_stream): New prototype.
* include/mailutils/stream.h (mu_stream_copy): Change
signature: takes 4 arguments now.
* include/mailutils/sys/body.h (_mu_body) <_get_stream>: New
method.
* include/mailutils/sys/message.h (_mu_message) <_get_stream>:
New method.
* mailbox/body.c (_body_get_stream): Call _get_stream, if
provided.
* mailbox/message.c (_message_get_stream): Call _get_stream, if
provided.
* mailbox/stream.c (_stream_flush_buffer): Avoid infinite
recursion: call stream->seek directly.
* mailbox/streamcpy.c (mu_stream_copy): Return the number of
bytes actually copied in the fourth argument. All uses updated.
* mailbox/streamref.c (streamref_return): Do not propagate
internal flags.
(_streamref_readdelim): Ensure there is enough buffer space for
the mu_stream_readdelim call.
* libproto/pop/mbox.c: Finish client implementation.
* mail/print.c (mail_print_msg): Close pager before returning
on error.
2010-09-08 Sergey Poznyakoff <gray@gnu.org.ua>
Implement "read cache" streams. Rewrite stdio and socket
streams.
* include/mailutils/sys/stdio_stream.h: Remove.
* include/mailutils/sys/socket_stream.h: Remove.
* include/mailutils/sys/rdcache_stream.h: New file.
* include/mailutils/sys/Makefile.am: Update.
* mailbox/rdcache_stream.c: New file.
* mailbox/Makefile.am: Update.
* examples/mucat.c: New example.
* examples/musocio.c: New example.
* examples/Makefile.am (noinst_PROGRAMS): Build new examples.
* include/mailutils/stream.h (mu_fd_stream_create): New proto.
(mu_rdcache_stream_create): New proto.
* include/mailutils/sys/file_stream.h (_mu_file_stream_create):
Change prototype.
* mailbox/file_stream.c (fd_open): Raise the
MU_STREAM_AUTOCLOSE bit.
(fd_ioctl): Support MU_IOCTL_SET_TRANSPORT.
(_mu_file_stream_create): Change signature. All uses updated.
Allocate a copy of the filename argument, unless it is NULL.
(mu_fd_stream_create): New function.
* mailbox/socket_stream.c: Rewrite using file_stream directly.
* mailbox/stdio_stream.c: Rewrite. Use rdcache_stream if the
seek capability is required on an input stream.
* mailbox/streamcpy.c (mu_stream_copy): Handle eventual EACCES
return from mu_stream_seek as equivalent to ENOSYS.
2010-09-08 Sergey Poznyakoff <gray@gnu.org.ua>
Further improvements in pop3client: readline & history.
2010-09-08 Sergey Poznyakoff <gray@gnu.org.ua>
Begin rewriting pop3 mailbox support. Several bugfixes.
* examples/pop3client.c (com_capa): Call mu_pop3_capa_test.
(com_stat): Count is size_t.
* include/mailutils/opool.h (mu_opool_copy): New proto.
* mailbox/opool.c (mu_opool_copy): New function.
* mailbox/xscript-stream.c (_xscript_ctl)
<MU_IOCTL_SWAP_STREAM>: Avoid coredumping if sp->transport is
NULL.
* include/mailutils/pop3.h (pop3_capa_test): Rename to
mu_pop3_capa_test.
(mu_pop3_stat): Third argument is a pointer to mu_off_t.
* libproto/pop/pop3_capatst.c (pop3_capa_test): Rename to
mu_pop3_capa_test.
* libproto/pop/pop3_stat.c (mu_pop3_stat): Third argument is a
pointer to mu_off_t.
* libproto/pop/Makefile.am (libmu_pop_la_SOURCES): Put back
folder.c, url.c and mbox.c.
* libproto/pop/mbox.c: Begin rewriting.
2010-09-08 Sergey Poznyakoff <gray@gnu.org.ua>
Minor change in stream API. Improve POP3 client interface.
* include/mailutils/sys/stream.h (_MU_STR_EVENT_SET)
(_MU_STR_EVENT_CLR): New defines.
(_mu_stream) <event_cb, event_mask>: New members.
* mailbox/stream.c (_stream_setflag, _stream_clrflag): New
static functions. All functions use these instead of
setting/clearing flags directly.
(_mu_stream_cleareof, _mu_stream_seteof): New extern functions.
(_stream_cleareof): Remove define, use _mu_stream_cleareof
instead.
(_stream_fill_buffer): Set EOF marker when end of stream is
reached.
* mailbox/fltstream.c (filter_read): Call _mu_stream_seteof to
set EOF flag.
* include/mailutils/pop3.h: Get rid of the superfluous "extern"
in front of function prototypes. Add new prototypes. Remove
extra whitespace.
* libproto/pop/pop3_capatst.c: New file.
* libproto/pop/pop3_list_cmd.c: New file.
* libproto/pop/pop3_listas.c: New file.
* libproto/pop/pop3_rdlist.c: New file.
* libproto/pop/pop3_uidl_cmd.c: New file.
* libproto/pop/pop3_uidlas.c: New file.
* libproto/pop/Makefile.am: Add new files.
* libproto/pop/pop3_capa.c (_mu_pop3_fill_list): Remove. Use
mu_pop3_read_list instead.
(capa_comp): New comparator for capa lists.
* libproto/pop/pop3_list.c (mu_pop3_list): Fix format
specifier.
* libproto/pop/pop3_lista.c (mu_pop3_list_all): Rewrite.
* libproto/pop/pop3_retr.c (mu_pop3_retr) <MU_POP3_RETR_RX>: do
not reset state, this is done by the EOF event callback.
* libproto/pop/pop3_top.c (mu_pop3_top) <MU_POP3_TOP_RX>:
Likewise.
* libproto/pop/pop3_stream.c (pop3_decode_state): New state
pds_char. Change semantics of pds_init.
(newstate, _pop3_decoder): Handle .\r\n in the initial state.
(_pop3_event_cb): New event callback.
(mu_pop3_filter_create): Set event callback on the filter
stream.
* libproto/pop/pop3_uidla.c (mu_pop3_uidl_all): Rewrite.
* examples/Makefile.am (pop3client_CPPFLAGS): Add
MU_APP_COMMON_INCLUDES.
* examples/pop3client.c: Rewrite command parser.
2010-09-08 Sergey Poznyakoff <gray@gnu.org.ua>
Further fixes in pop3.
* libproto/pop/pop3_create.c (_mu_pop3_init): Fix return value.
* libproto/pop/pop3_destroy.c: Add missing includes.
* libproto/pop/pop3_stream.c (_pop3_decoder): Remove the final
.\r\n altogether.
* mailbox/fltstream.c (filter_read): Remove the hack for
supporting buggy filters.
2010-09-08 Sergey Poznyakoff <gray@gnu.org.ua>
Fix TLS support in smtp.
* include/mailutils/tls.h (mu_tls_readline_fn)
(mu_tls_writeline_fn, mu_tls_stream_ctl_fn): Remove typedefs.
(mu_tls_begin): Remove prototype.
* libmu_auth/tls.c (mu_tls_begin): Remove function.
* libproto/mailer/smtp.c: Revamp STARTTLS support.
2010-09-08 Sergey Poznyakoff <gray@gnu.org.ua>
Re-implement pop3 client functions.
* include/mailutils/filter.h (mu_filter_io) <eof>: New member.
* mailbox/fltstream.c (init_iobuf): Initialize eof to 0.
(filter_read): Break the loop if the decoder has set eof.
* mailbox/xscript-stream.c (_xscript_ctl)
<MU_IOCTL_SWAP_STREAM>: Handle a special case when the
transport does not support stream swapping.
* include/mailutils/pop3.h (mu_pop3_set_debug): Remove.
(MU_POP3_TRACE_CLR, MU_POP3_TRACE_SET, MU_POP3_TRACE_QRY): New
macros.
(mu_pop3_trace): New proto.
(mu_pop3_readline): Remove.
(mu_pop3_getline): New proto.
(mu_pop3_capa): Change signature.
* include/mailutils/sys/pop3.h (mu_pop3_state): Remove the
*_ACK states.
(mu_pop3_work_buf): Remove.
(MU_POP3_ACK, MU_POP3_TRACE): New defines.
(_mu_pop3): Rewrite the structure.
(mu_pop3_debug_cmd, mu_pop3_debug_ack): Remove functions.
(MU_POP3_FISSET, MU_POP3_FSET, MU_POP3_FCLR): New macros.
(_mu_pop3_trace_enable, _mu_pop3_trace_disable)
(_mu_pop3_init): New protos.
* include/mailutils/tls.h (mu_tls_stream_ctl_fn)
(mu_tls_writeline_fn): Change typedefs.
* libmu_auth/tls.c (mu_tls_begin): Update function calls
accordingly.
* libproto/pop/pop3_debug.c: Remove.
* libproto/pop/pop3_trace.c: New function.
* libproto/pop/Makefile.am (libmu_pop_la_SOURCES): Temporarly
comment out folder.c, mbox.c and url.c. Remove pop3_debug.c.
Add pop3_trace.c.
* libproto/pop/pop3_capa.c: Rewrite.
* libproto/pop/pop3_create.c: Rewrite.
* libproto/pop/pop3_iterator.c: Rewrite.
* libproto/pop/pop3_response.c: Rewrite.
* libproto/pop/pop3_sendline.c: Rewrite.
* libproto/pop/pop3_stls.c: Rewrite.
* libproto/pop/pop3_stream.c: Rewrite.
* libproto/pop/pop3_apop.c: Reflect changes to the pop3
framework.
* libproto/pop/pop3_carrier.c: Likewise.
* libproto/pop/pop3_connect.c: Likewise.
* libproto/pop/pop3_dele.c: Likewise.
* libproto/pop/pop3_destroy.c: Likewise.
* libproto/pop/pop3_disconnect.c: Likewise.
* libproto/pop/pop3_list.c: Likewise.
* libproto/pop/pop3_lista.c: Likewise.
* libproto/pop/pop3_noop.c: Likewise.
* libproto/pop/pop3_pass.c: Likewise.
* libproto/pop/pop3_quit.c: Likewise.
* libproto/pop/pop3_retr.c: Likewise.
* libproto/pop/pop3_readline.c: Likewise.
* libproto/pop/pop3_rset.c: Likewise.
* libproto/pop/pop3_stat.c: Likewise.
* libproto/pop/pop3_top.c: Likewise.
* libproto/pop/pop3_uidl.c: Likewise.
* libproto/pop/pop3_uidla.c: Likewise.
* libproto/pop/pop3_user.c: Likewise.
* examples/pop3client.c: Implement the stls command.
(main) [WITH_TLS]: Call mu_init_tls_libs.
(com_verbose): Redo verbose support.
(com_capa): Implement "reread" option.
2010-09-08 Sergey Poznyakoff <gray@gnu.org.ua>
Reorganize directory tree.
Move libproto/include/(*)0.h to include/mailutils/sys/\1.h
Remove libproto/include.
2010-09-08 Sergey Poznyakoff <gray@gnu.org.ua>
Remove unused constants.
* pop3d/pop3d.h (POP_MAXCMDLEN, BUFFERSIZE): Remove constants.
(_QNX_SOURCE): Remove define.
2010-09-08 Sergey Poznyakoff <gray@gnu.org.ua>
pop3d: bugfixes.
* pop3d/apop.c (pop3d_apopuser, pop3d_apopuser): Remove
statically allocated buffers.
* pop3d/pop3d.c (pop3d_mainloop): Likewise.
* pop3d/user.c (pop3d_begin_session): Likewise.
2010-09-08 Sergey Poznyakoff <gray@gnu.org.ua>
pop3d: optimize apop support.
* pop3d/apop.c (pop3d_apopuser): Fix highly ineffective
resource usage in both branches.
* pop3d/pop3d.c: Remove misleading comment.
2010-09-08 Sergey Poznyakoff <gray@gnu.org.ua>
Re-implement GSASL support.
* libmu_auth/lbuf.c: Removed.
* libmu_auth/lbuf.h: Removed.
* libmu_auth/Makefile.am : Remove lbuf stuff.
* include/mailutils/sys/gsasl-stream.h: New file.
* include/mailutils/sys/Makefile.am: Add gsasl-stream.h.
* include/mailutils/gsasl.h (mu_gsasl_stream_create): Remove.
(gsasl_encoder_stream, gsasl_decoder_stream): New prototypes.
* libmu_auth/gsasl.c: Rewrite.
* imap4d/authenticate.c (auth_data): Remove. Use struct
imap4d_auth instead.
(_auth_try): Use new authentication API.
(imap4d_authenticate): Likewise.
* imap4d/imap4d.h (util_register_event, util_event_remove)
(util_run_events): Remove.
(imap4d_auth_handler_fp): Change prototype.
(imap4d_auth): New struct.
(imap4d_auth_result): New enum.
* imap4d/io.c (io_format_completion_response)
(io_stream_completion_response): New functions.
(io_completion_response): Rewrite using
io_format_completion_response.
* imap4d/util.c (sc2string): Remove leftover prototype.
(util_register_event, util_event_remove)
(util_run_events): Remove.
* imap4d/auth_gsasl.c: Revamp using new streams and the new
authentication interface.
* imap4d/auth_gss.c: Likewise (though yet untested).
* mailbox/xscript-stream.c (_xscript_ctl): Remove unused
variables.
2010-09-08 Sergey Poznyakoff <gray@gnu.org.ua>
Port the new I/O scheme from pop3d to imap4d.
* mailbox/fltstream.c (filter_wr_flush): Fix erroneous
conditional.
(filter_wait): New method.
(mu_filter_stream_create): Set wait method.
* imap4d/io.c: New source.
* imap4d/Makefile.am: Add io.c
* imap4d/*: Update I/O function calls.
2010-09-08 Sergey Poznyakoff <gray@gnu.org.ua>
Minor change.
* pop3d/extra.c (pop3d_setio): Use the canonic name of the CRLF
filter, instead of the legacy "rfc822".
* imap4d/fetch.c: Likewise.
* imap4d/util.c: Likewise.
2010-09-08 Sergey Poznyakoff <gray@gnu.org.ua>
Implement an ioctl for replace bottom-level transport layers in
a stream chain.
* include/mailutils/stream.h (MU_IOCTL_SWAP_STREAM): New ioctl
op.
(mu_stream_seterr): New function.
* include/mailutils/sys/stream.h (_MU_SWAP_FIRST_ONLY)
(_MU_SWAP_IOCTL_MUST_SUCCEED): New defines.
(_mu_stream_swap_streams): New proto.
* mailbox/amd.c (amd_body_stream_read): Always update *pnread.
* mailbox/errors (MU_ERR_NO_TRANSPORT): New error code.
* mailbox/stream.c (_stream_seterror): Rename to
mu_stream_seterr, remove static qualifier. All uses updated.
(_mu_stream_swap_streams): New function.
* mailbox/filter_iconv.c (_icvt_ioctl): Implement
MU_IOCTL_SWAP_STREAM.
* mailbox/iostream.c (_iostream_ctl): Likewise.
* mailbox/xscript-stream.c (_xscript_ctl): Likewise.
* pop3d/extra.c (real_istream, real_ostream): Remove statics.
(pop3d_init_tls_server): Use MU_IOCTL_SWAP_STREAM to replace
bottom-level transport layers without recreating the entire
stream chain.
2010-09-08 Sergey Poznyakoff <gray@gnu.org.ua>
Redo the support for transport-based streams.
If a stream takes another stream(s) as a transport, it always
increases its reference count. This means that when that stream
is destroyed the underlying stream is not destroyed by default
(its refcount is decreased, that's all). To force destruction
of the underlying stream, the caller must explicitly
unreference it after creating the stream that uses it (or give
its creation function the MU_STREAM_AUTOCLOSE flag, if it
supports flags).
Similarly, if a stream uses a non-stream object (e.g. a file
descriptor) as the transport, it will not destroy it, unless it
has been created with the MU_STREAM_AUTOCLOSE flag. This
differs from the previous behavior.
The MU_STREAM_NO_CHECK and MU_STREAM_NO_CLOSE flags are
removed.
* examples/base64.c (main): Call mu_filter_create with the
MU_STREAM_AUTOCLOSE flag.
* examples/mimetest.c (message_display_parts): Likewise.
* examples/murun.c (main): Unref the input stream after passing
it to mu_filter_prog_stream_create.
* imap4d/fetch.c (fetch_io): Update arguments to
mu_filter_create and mu_memory_stream_create.
* imap4d/preauth.c (decode64_buf)
(do_preauth_ident): Update arguments to mu_memory_stream_create
and mu_tcp_stream_create.
* imap4d/util.c (util_setio): Update arguments to
mu_filter_create and mu_stdio_stream_create.
* include/mailutils/stream.h (MU_STREAM_NO_CLOSE)
(MU_STREAM_NO_CHECK): Remove.
(MU_STREAM_AUTOCLOSE): New flag.
(mu_iostream_create): Remove the `flags' argument.
* libmu_argp/muinit.c (mu_app_init): Update arguments to
mu_stdio_stream_create.
* libmu_auth/ldap.c: Update arguments to
mu_memory_stream_create and mu_filter_create.
* libmu_auth/tls.c (_tls_io_close, _tls_close): Always try to
close the transport stream. Rely on refcount to protect it.
(_tls_io_done, _tls_done): Likewise, always unreference it.
(_mu_tls_io_stream_create): Increase reference counter on the
transport stream, unless MU_STREAM_AUTOCLOSE is requested.
(_mu_tls_stream_create): Rewrite using the new
MU_STREAM_AUTOCLOSE logic.
* libmu_sieve/extensions/spamd.c (spamd_connect_tcp): Update
arguments to mu_tcp_stream_create.
(spamd_connect_tcp): Update arguments to
mu_socket_stream_create and mu_filter_create.
* libmu_sieve/extensions/vacation.c (build_mime): Update
arguments to mu_filter_create.
* mail/decode.c (display_submessage): Update arguments to
mu_filter_create.
* mailbox/attachment.c (mu_message_save_attachment): Update
arguments to mu_filter_create.
* mailbox/cfg_driver.c (mu_cfg_tree_reduce): Update arguments
to mu_stdio_stream_create.
* mailbox/dbgstream.c (_dbg_done): Use MU_STREAM_AUTOCLOSE bit
to decide whether to destroy the debug object.
(mu_dbgstream_create): Use MU_STREAM_AUTOCLOSE instead of
MU_STREAM_NO_CLOSE.
* mailbox/file_stream.c (fd_close): Use MU_STREAM_AUTOCLOSE bit
to decide whether to close the descriptor.
(mu_file_stream_create): Force MU_STREAM_AUTOCLOSE bit.
* mailbox/filter.c (filter_create_rd, filter_create_wr): Change
substream creation logic.
* mailbox/filter_iconv.c (_icvt_close): Always try to close the
transport stream. Rely on refcount to protect it.
(_icvt_done): Ditto for destroying it.
(mu_filter_iconv_create): Increase refcount on the transport
stream, unless MU_STREAM_AUTOCLOSE is requested.
* mailbox/fltstream.c (filter_done): Always dereference the
transport stream. Rely on refcount to protect it.
(filter_close): Ditto for closing it.
(mu_filter_stream_create): Increase refcount on the transport
stream, unless MU_STREAM_AUTOCLOSE is requested.
* mailbox/iostream.c (_iostream_close) : Always try to close
the transport stream. Rely on refcount to protect it.
(_iostream_done): Ditto for closing it.
(mu_iostream_create): Remove the use of MU_STREAM_NO_CLOSE.
* mailbox/mimehdr.c (mu_mimehdr_decode_param): Remove the use
of MU_STREAM_NO_CLOSE.
* mailbox/mutil.c (mu_decode_filter) Change substream creation
logic.
* mailbox/prog_stream.c (_prog_open): Use MU_STREAM_AUTOCLOSE
bit in arguments to mu_stdio_stream_create.
(mu_filter_prog_stream_create): Increase refcount on the
transport (input) stream.
* mailbox/rfc2047.c (mu_rfc2047_decode): Dereference in_stream
after passing it to mu_decode_filter. Pass MU_STREAM_AUTOCLOSE
in flags to mu_filter_create.
* mailbox/socket_stream.c (mu_socket_stream_create): Force
MU_STREAM_AUTOCLOSE bit.
* mailbox/streamref.c (_streamref_close): Always close the
transport stream (refcount will protect it, if necessary).
(mu_streamref_create_abridged): Mask out the
MU_STREAM_AUTOCLOSE bit.
* mailbox/temp_file_stream.c (mu_temp_file_stream_create: Force
MU_STREAM_AUTOCLOSE bit.
* mailbox/xscript-stream.c (_xscript_close): Always close the
transport stream (refcount will protect it, if necessary).
(mu_xscript_stream_create): Increase refcounts on both
underlying streams, unless MU_STREAM_AUTOCLOSE is set.
* pop3d/extra.c (pop3d_setio): Remove uses of
MU_STREAM_NO_CLOSE.
* examples/nntpclient.c: Remove uses of
MU_STREAM_NO_CHECK/MU_STREAM_NO_CLOSE.
* examples/pop3client.c: Likewise.
* libmu_auth/gsasl.c: Likewise.
* libproto/nntp/nntp_stream.c: Likewise.
* libproto/pop/pop3_stream.c: Likewise.
* mailbox/tcp.c: Likewise.
* mailbox/vartab.c: Likewise.
* mh/mh_list.c: Likewise.
* mimeview/mimeview.c: Likewise.
* mh/mhn.c: Likewise.
(edit_mime): Use MU_STREAM_AUTOCLOSE.
Bugfixes:
* mailbox/fltstream.c (init_iobuf): Fix input initialization.
(filter_write_internal): Bugfix.
* mailbox/stream.c (_stream_buffer_freespace): New macro.
(_stream_buffer_is_full): New macro.
(BUFFER_FULL_P): Remove, use _stream_buffer_is_full instead.
All callers updated.
(_stream_flush_buffer): Operation for full buffered streams
does not depend on the `all' flag.
(mu_stream_write): Fix calculation of the bytes available in
the buffer.
2010-09-08 Sergey Poznyakoff <gray@gnu.org.ua>
Add a framework for printing I/O transcripts; modify pop3d to
use it.
* include/mailutils/stream.h (MU_STREAM_RDTHRU)
(MU_STREAM_WRTHRU,MU_IOCTL_SET_TRANSPORT): New flags.
(mu_xscript_stream_create, mu_iostream_create)
(mu_dbgstream_create): New prototypes.
* include/mailutils/sys/dbgstream.h: New header.
* include/mailutils/sys/iostream.h: New header.
* include/mailutils/sys/xscript-stream.h: New header.
* include/mailutils/sys/Makefile.am (sysinclude_HEADERS): Add
dbgstream.h, iostream.h and xscript-stream.h
* mailbox/dbgstream.c: New file.
* mailbox/iostream.c: New file.
* mailbox/xscript-stream.c: New file.
* mailbox/Makefile.am (libmailutils_la_SOURCES): Add
dbgstream.c, iostream.c and xscript-stream.c
* mailbox/filter_iconv.c (_icvt_ioctl): Simplify the
declaration of ptrans.
* mailbox/mapfile_stream.c (_mapfile_ioctl): Likewise.
* mailbox/memory_stream.c (_memory_ioctl): Likewise.
* mailbox/prog_stream.c (_prog_ioctl): Likewise.
* mailbox/tcp.c (_tcp_ioctl): Likewise.
* mailbox/fltstream.c (filter_ctl): Likewise.
(filter_read_through, filter_write_through): New methods.
(mu_filter_stream_create): Allow for use of MU_STREAM_RDTHRU
and MU_STREAM_WRTHRU to create two-way filters (writing
triggers filtering while reading is transparent or vice versa).
* pop3d/extra.c (istream, ostream): Remove globals.
(iostream): New variable.
(real_istream, real_ostream): New variables.
(pop3d_setio): Set transcript stream on top of the I/O one, if
required.
(pop3d_init_tls_server): Rewrite. Revert the meaning of the
return code to match the usual convention (0 - success).
(transcript): Removed.
(pop3d_outf): Remove calls to transcript.
* pop3d/pop3d.h (istream, ostream): Remove externs.
(iostream): New extern.
* pop3d/retr.c: Use iostream, instear of ostream.
* pop3d/top.c: Likewise.
* pop3d/stls.c: Update the call to pop3d_init_tls_server.
* mailbox/stream_vprintf.c (mu_stream_vprintf): Fix return
value to match the usual convention.
2010-09-08 Sergey Poznyakoff <gray@gnu.org.ua>
Re-implement server TLS support.
STLS in pop3d is already working.
* include/mailutils/sys/tls-stream.h: New header.
* include/mailutils/tls.h (mu_tls_stream_create)
(mu_tls_stream_create_client)
(mu_tls_stream_create_client_from_tcp): Remove.
(mu_tls_server_stream_create, mu_tls_client_stream_create): New
protos.
* libmu_auth/tls.c: Rewrite.
* imap4d/util.c: Use mu_tls_server_stream_create.
* libproto/pop/mbox.c: Use mu_tls_server_stream_create/
mu_tls_client_stream_create.
* libproto/pop/pop3_stls.c: Use mu_tls_client_stream_create.
* libproto/imap/folder.c: Use mu_tls_client_stream_create.
* pop3d/capa.c (pop3d_capa): CAPA is allowed in both states.
* pop3d/extra.c (pop3d_setio): Rewrite.
2010-09-08 Sergey Poznyakoff <gray@gnu.org.ua>
amd, pop3d: bugfixes.
* mailbox/amd.c (amd_body_stream_readdelim): Fix the logic.
* mailbox/message.c (_message_stream_seek): Fix seeks in
backward direction.
* pop3d/top.c: Fix output of the body.
2010-09-08 Sergey Poznyakoff <gray@gnu.org.ua>
Bugfix.
* imap4d/append.c: Add a comment.
* imap4d/imap4d.h (imap4d_child_signal_setup): New proto.
* libmu_sieve/extensions/pipe.c (sieve_action_pipe): Use
mu_stream_copy, rewrite error handling.
* libmu_sieve/extensions/spamd.c (spamd_send_message): se
mu_stream_copy.
(spamd_test): Honor dry-run mode.
* libmu_sieve/extensions/vacation.c (build_mime): Remove
misleading FIXME. Use mu_stream_copy.
* libmu_sieve/extensions/moderator.c
(moderator_message_get_part): Use mu_body_get_streamref.
* examples/header.c (hstream): New global.
(cmd_load, cmd_free, cmd_remove, cmd_insert): Discard hstream.
(cmd_readline): Use hstream. Obtain it using
mu_stream_readline.
* libproto/mbox/mbox.c (mbox_envelope_date): Remove trailing
newline from the obtained envelope line.
* mailbox/amd.c (amd_body_stream_seek): Allow for off == size
(important for empty bodies).
2010-09-08 Sergey Poznyakoff <gray@gnu.org.ua>
libmu_sieve: cleanup.
* libmu_sieve/actions.c (mime_create_quote): Use
mu_stream_copy.
2010-09-08 Sergey Poznyakoff <gray@gnu.org.ua>
pop3d: cleanup.
* pop3d/pop3d.h: Include filter.h.
(istream, ostream): New externs.
* pop3d/extra.c (pop3d_setio): Set a crlf filter on the output
stream. This allows to forget about \r in the rest of the code.
* pop3d/retr.c (pop3d_retr): Use mu_stream_copy instead of
copying streams manually.
* pop3d/top.c (pop3d_top): Rewrite using streamrefs and
mu_stream_copy.
* all sources: Use \n instead of \r\n in output strings.
2010-09-08 Sergey Poznyakoff <gray@gnu.org.ua>
Fix mime creation and Sieve reject/redirect actions.
* examples/mta.c (finalize_option): New variable.
(message_finalize): Don't modify the message if finalize_option
is 0.
* include/mailutils/sys/message.h (_mu_message)
<orig_header_size>: New member.
* include/mailutils/sys/mime.h (_mu_mime) <part_stream>: New
member.
* libmu_sieve/actions.c (mime_create_reason)
(mime_create_ds): Use mu_body_get_streamref.
(mime_create_quote): Use
mu_body_get_streamref/mu_message_get_streamref.
(sieve_action_reject): Set the To: header.
* mailbox/message.c (mu_message_get_header): Set
orig_header_size.
(mu_message_get_body): Use orig_header_size instead of relying
on mu_header_size.
* mailbox/mime.c (_mime_part_size): New static.
(_mime_body_stream_size): New method.
(_mime_body_seek): Rename to _mime_body_stream_seek.
(_mime_body_read): Rewrite and rename to
_mime_body_stream_read.
(_mime_body_ioctl): Rename to _mime_body_stream_ioctl.
(create_mime_body_stream): Take mu_mime_t as the 2nd parameter.
Initialize sp->stream.size and sp->mime.
(_mime_body_size): Rewrite using _mime_part_size.
(mu_mime_destroy): Destroy part_stream.
* sieve/testsuite/Redirect: Reflect new mta behavior.
* sieve/testsuite/Reject: Likewise.
2010-09-08 Sergey Poznyakoff <gray@gnu.org.ua>
Further bugfixes.
* libproto/mbox/mbox.c (_msg_stream_setup): Fix abridgment
limits.
(mbox_expunge_unlocked): Don't write extra newline after each
message.
* mailbox/stream.c (mu_stream_seek): ESPIPE does not constitute
a permanent error.
2010-09-08 Sergey Poznyakoff <gray@gnu.org.ua>
Fix mime test.
* mailbox/mime.c (mu_mime_get_part): Fix the end limit for the
part's abridgment.
* mailbox/streamref.c (_streamref_seek): Fix ESPIPE condition.
2010-09-08 Sergey Poznyakoff <gray@gnu.org.ua>
pop3d: bugfixes.
* include/mailutils/message.h (mu_message_set_stream): Mark as
deprecated.
* pop3d/retr.c (pop3d_retr): Rewind the stream obtained from
mu_message_get_stream.
* pop3d/top.c (pop3d_top): Rewind the streams obtained from
mu_body_get_stream and mu_header_get_stream.
2010-09-08 Sergey Poznyakoff <gray@gnu.org.ua>
Fix encode2047 test.
* mailbox/base64.c (_base64_encoder): Fix the use of
uninitialized variable.
* mailbox/rfc2047.c (mu_rfc2047_encode): Rewind the input
stream before reading from it.
2010-09-08 Sergey Poznyakoff <gray@gnu.org.ua>
Fix decode2047 test.
* mailbox/filter_iconv.c (mu_filter_iconv_create): Set filter
flags.
* mailbox/fltstream.c (mu_filter_stream_create): Likewise.
* mailbox/qpflt.c (_qp_decoder): Handle '_'.
2010-09-08 Sergey Poznyakoff <gray@gnu.org.ua>
Fix base64 test.
* examples/base64.c (c_copy): Handle printable mode (-p).
(reset_line_length): New function.
(main): New option -lN sets the maximum length for output lines
to N (0 means unlimited).
* mailbox/testsuite/mailbox/base64.exp: Use -l0 in the Decode
test.
2010-09-08 Sergey Poznyakoff <gray@gnu.org.ua>
Bugfixes.
* include/mailutils/header.h (mu_header_invalidate): New proto.
* mailbox/header.c (mu_header_invalidate): New function.
* libmu_argp/muinit.c (get_canonical_name): Avoid coredumping
if argp_program_version is NULL.
* mailbox/base64.c (mu_base64_decode): Fix inconsistent return
code.
* mailbox/debug.c (mu_debug_destroy): Allow for debug->stream
== NULL.
* mailbox/mapfile_stream.c (_mapfile_truncate): Incorrect size
was used when unmapping.
* mailbox/message.c (mu_message_create_copy): Use a temporary
memory stream.
(mu_message_get_body): Comment out the check for
MESSAGE_INTERNAL_STREAM.
(_message_get_stream): Initialize message header and body.
* mailbox/progmailer.c (mu_progmailer_send): Check return from
the mu_header_get_streamref.
* mailbox/stream.c (_stream_scandelim, _stream_readdelim): If
size is 0, return MU_ERR_BUFSPACE.
2010-09-08 Sergey Poznyakoff <gray@gnu.org.ua>
Fix readmsg.
Readmsg passes all tests successfully.
* readmsg/msglist.c (msglist): Check return from
mu_message_get_streamref.
* readmsg/readmsg.c (print_header, print_body): Check return
values.
2010-09-08 Sergey Poznyakoff <gray@gnu.org.ua>
Bugfixes.
* mailbox/header.c (header_seek): Do not dereference
hstr->hdr->size directly, because it may not be initialized
yet. Use mu_header_size instead.
* mailbox/message.c (_message_stream_readdelim): Break the loop
if mu_stream_readdelim returned error or EOF.
2010-09-08 Sergey Poznyakoff <gray@gnu.org.ua>
Various fixes in imap4d.
Imap4d successfully passes all tests.
* imap4d/close.c (imap4d_close0): Fix improper use of
MU_STREAM_READ (flags changed their semantics since then).
* imap4d/fetch.c: Send \n terminated lines, rely on filters to
recode line terminators to \r\n.
(fetch_io): Rewrite using CRLF encoder and util_copy_out.
(_frt_header_fields): Rewind memory stream before reading from
it.
* imap4d/auth_gsasl.c: Send \n terminated lines, rely on
filters to recode line terminators to \r\n.
* imap4d/auth_gss.c: Likewise.
* imap4d/capability.c: Likewise.
* imap4d/copy.c: Likewise.
* imap4d/id.c: Likewise.
* imap4d/idle.c: Likewise.
* imap4d/list.c: Likewise.
* imap4d/namespace.c: Likewise.
* imap4d/preauth.c: Likewise.
* imap4d/search.c: Likewise.
* imap4d/status.c: Likewise.
* imap4d/store.c: Likewise.
* imap4d/select.c: Likewise.
(imap4d_select_status): Fix improper use of MU_STREAM_READ.
* imap4d/util.c: Send \n terminated lines, rely on filters to
recode line terminators to \r\n.
(util_setio): Apply CRLF filters to both input and output
streams (in opposite directions).
(util_copy_out): New function.
(remove_cr): Remove.
* imap4d/imap4d.h (util_copy_out): New prototype.
2010-09-08 Sergey Poznyakoff <gray@gnu.org.ua>
Fix for mbox read/write consistency.
* libproto/mbox/mbox.c (append_message_to_stream): Add \n after
each message (scanner relies on this to determine message
sizes).
2010-09-08 Sergey Poznyakoff <gray@gnu.org.ua>
Bugfixes in stream-related code.
* mailbox/fltstream.c (filter_read): Do not try to get more
input until the output buffer is drained.
* mailbox/mapfile_stream.c (_mapfile_seek): Fix conditional.
* mailbox/stream.c (_stream_fill_buffer): Fix increment.
(mu_stream_skip_input_bytes): Bugfixes.
2010-09-08 Sergey Poznyakoff <gray@gnu.org.ua>
Implement seek on filters in read-only mode.
* include/mailutils/stream.h (mu_stream_skip_input_bytes): New
proto.
* mailbox/stream.c (mu_stream_skip_input_bytes): New function.
* mailbox/fltstream.c (filter_seek): Re-implement on top of
mu_stream_skip_input_bytes.
(mu_filter_stream_create): Fix flag validity checking.
* examples/base64.c: Add new option (-s) for testing seek
operations on filters.
2010-09-08 Sergey Poznyakoff <gray@gnu.org.ua>
Make version output of the MH utilities more informative.
* mh/mh_argp.c [MU_ALPHA_RELEASE}: Include git-describe.h
(mh_program_version_hook): New function.
(mh_argp_init): Take no arguments. Set
argp_program_version_hook.
* mh/mh_getopt.h (ARG_LICENSE): Remove.
(mh_argp_init): Change proto.
All sources: Fix calls to mh_argp_init, remove --license
option.
2010-09-08 Sergey Poznyakoff <gray@gnu.org.ua>
For alpha version, include git tag info in the version output.
* include/mailutils/libargp.h (mu_program_version_hook): New
proto.
* libmu_argp/Makefile.am (libmu_argp_a_SOURCES): Remove
mu_argp.h.
* libmu_argp/mu_argp.h: Remove.
* libmu_argp/muinit.c [MU_ALPHA_RELEASE]: Include
git-describe.h
(mu_program_version_hook): New function.
(mu_argp_init): Set mu_program_version_hook, unless vers is
given.
* comsat/comsat.c (main): Call mu_argp_init with NULL
arguments.
* config/mailutils-config.c: Likewise.
* dotlock/dotlock.c: Likewise.
* examples/muauth.c: Likewise.
* frm/frm.c: Likewise.
* frm/from.c: Likewise.
* guimb/main.c: Likewise.
* imap4d/imap4d.c: Likewise.
* maidag/maidag.c: Likewise.
* mail/mail.c: Likewise.
* messages/messages.c: Likewise.
* mimeview/mimeview.c: Likewise.
* movemail/movemail.c: Likewise.
* pop3d/pop3d.c: Likewise.
* pop3d/popauth.c: Likewise.
* readmsg/readmsg.c: Likewise.
* sieve/sieve.c: Likewise.
2010-09-08 Sergey Poznyakoff <gray@gnu.org.ua>
Fix conditional compilation.
* .gitignore: Add git-describe and git-describe.h.
* Makefile.am (MU_COND_LIBMU_CPP): Replaced with
MU_COND_SUPPORT_CXX
(SUBDIRS): Begin with .
(EXTRA_DIST, BUILT_SOURCES): Add git-describe and
git-describe.h.
(git-describe, git-describe.h): New rules.
(alpha, alphacheck): Use git-describe to produce additional
suffix.
* enable.m4 (MU_ENABLE_SUPPORT): Create an Automake condition.
* configure.ac: Fix MU_ENABLE_SUPPORT calls.
(--without-python): Replace with --disable-python.
* examples/Makefile.am: Disable components based on MU_COND
conditions.
* libproto/Makefile.am: Likewise.
* include/mailutils/Makefile.am (MU_COND_LIBMU_CPP): Replace
with MU_COND_SUPPORT_CXX.
* mailbox/nullrec.c: New file.
* mailbox/Makefile.am (libmailutils_la_SOURCES): Add nullrec.c.
* mail/decode.c: Remove unused variable.
* mailbox/streamref.c: Likewise.
2010-09-08 Sergey Poznyakoff <gray@gnu.org.ua>
Simplify stream->seek.
* include/mailutils/sys/stream.h (_mu_stream) <seek>: Remove
the `whence' parameter.
* mailbox/stream.c (mu_stream_seek): Update the seek method
call.
* mailbox/streamref.c (_streamref_seek): Fix the signature.
Remove unnecessary code.
* mailbox/amd.c (amd_body_stream_seek): Likewise.
* mailbox/body.c (_body_seek): Likewise.
* mailbox/file_stream.c (fd_seek): Likewise.
* mailbox/filter_iconv.c (_icvt_seek): Likewise.
* mailbox/fltstream.c (filter_seek): Likewise.
* mailbox/header.c (header_seek): Likewise.
* mailbox/mapfile_stream.c (_mapfile_seek): Likewise.
* mailbox/memory_stream.c (_memory_seek): Likewise.
* mailbox/message.c (_message_stream_seek): Likewise.
* mailbox/message_stream.c (_message_stream_seek): Likewise.
* mailbox/mime.c (_mime_body_seek): Likewise.
* mailbox/stdio_stream.c (stdio_seek): Likewise.
2010-09-08 Sergey Poznyakoff <gray@gnu.org.ua>
Improve CRLF filter.
* include/mailutils/filter.h (mu_filter_new_data_t): Change
prototype.
* mailbox/filter.c (mu_filter_create): Reflect the above.
* mailbox/crlfflt.c (crlf_state): New enum.
(_crlf_encoder): Keep state info in xd. Do not modify eventual
input CRLFs.
(alloc_state): New function.
(_rfc822_filter,_crlf_filter): Provide the `newdata' method.
2010-09-08 Sergey Poznyakoff <gray@gnu.org.ua>
Bugfixes.
* mailbox/rfc2047.c (mu_rfc2047_decode): Rewind in_stream.
* mailbox/stream.c (_stream_scandelim): Break the loop when the
delimiter is found.
* mailbox/streamref.c (_streamref_readdelim): Take into account
the abridgment.
2010-09-08 Sergey Poznyakoff <gray@gnu.org.ua>
Optimize readline/readdelim/getdelim calls.
This speeds up common reading operations by factor of 4-6.
* include/mailutils/stream.h (mu_stream_readdelim): New proto.
* include/mailutils/sys/stream.h (_mu_stream) <readdelim>: New
method.
* mailbox/stream.c (_stream_scandelim, _stream_readdelim): New
functions.
(mu_stream_readdelim): New function.
(mu_stream_readline): Rewrite using mu_stream_readdelim.
(mu_stream_getdelim): Optimize.
* mailbox/amd.c (amd_body_stream_readdelim): New function.
(_amd_attach_message): Set the readdelim method.
* mailbox/header.c: Add a placeholder for readdelim method.
* mailbox/message.c (_message_stream_readdelim): New function.
(_message_stream_create): Set the readdelim method.
* mailbox/streamref.c (_streamref_readdelim): New function.
(mu_streamref_create_abridged): Set the readdelim method.
2010-09-08 Sergey Poznyakoff <gray@gnu.org.ua>
Fix amd.
* mailbox/amd.c (_amd_attach_message): Store body.
(amd_scan_message): Scan the message only if it has been
modified after the last scan. Fix loop condition. Store
mhm->mtime on success.
(amd_message_stream_open): Enforce full buffering.
(amd_body_stream_read): Fix.
(amd_body_stream_seek): Don't call mu_stream_seek on
mhm->stream.
2010-09-08 Sergey Poznyakoff <gray@gnu.org.ua>
Bugfixes.
* mailbox/message.c (_check_stream_state): Bugfix.
(_message_stream_seek): Bugfix.
(_message_stream_read): Always try to fill out the buffer.
(_message_stream_create): Set MU_STREAM_SEEK flag bit.
2010-09-08 Sergey Poznyakoff <gray@gnu.org.ua>
Bugfix in filter_iconv.
* mailbox/filter_iconv.c (mu_filter_iconv_create): Return the
created stream in *s.
2010-09-08 Sergey Poznyakoff <gray@gnu.org.ua>
Keep track of the current offset in the _mu_stream structure.
* include/mailutils/sys/stream.h (_mu_stream)<offset>: New
member.
* mailbox/stream.c (_stream_fill_buffer): Propagate return
value from mu_stream_read_unbuffered.
(_stream_flush_buffer): Use stream->offset. Honor the `all'
argument.
(mu_stream_seek): Rewrite using the `offset' member.
(mu_stream_read_unbuffered)
(mu_stream_write_unbuffered): Update offset.
(mu_stream_readline): Return EINVAL if size is 0.
2010-09-08 Sergey Poznyakoff <gray@gnu.org.ua>
Use stringrefs, add some guidelines for further editing.
* comsat/action.c
* imap4d/fetch.c
* imap4d/search.c
* mh/burst.c
* mh/comp.c
* mh/forw.c
* mh/mh_ctx.c
* mh/mh_format.c
* mh/mh_list.c
* mh/mhn.c
* mh/pick.y
* pop3d/retr.c
* pop3d/top.c
* readmsg/msglist.c
* readmsg/readmsg.c
2010-09-08 Sergey Poznyakoff <gray@gnu.org.ua>
Fix compilation of libmu_scm.
* libmu_scm/mu_body.c (mu_scm_body_free): Unref the stream.
Return 0.
(mu-body-read-line, mu-body-write): Use stringrefs.
* libmu_scm/mu_mailbox.c (mu-mailbox-get-port): Use stringrefs.
* libmu_scm/mu_message.c (mu-message-copy): Use stringrefs. Use
mu_stream_copy instead of manually copying stream contents.
(mu-message-get-port): Use stringrefs.
* libmu_scm/mu_port.c (mu_port_free): Unref the stream.
2010-09-08 Sergey Poznyakoff <gray@gnu.org.ua>
Fix compilation of several example programs.
* examples/header.c: Use streamrefs.
* examples/mimetest.c: Likewise.
* examples/mta.c: Likewise.
* examples/nntpclient.c: Remove an unused variable.
2010-09-08 Sergey Poznyakoff <gray@gnu.org.ua>
Fix compilation of mimeview.
* mimeview/mimeview.c (mimeview_fp): Restore the variable.
2010-09-08 Sergey Poznyakoff <gray@gnu.org.ua>
Fix UNIX mbox driver and mail utility.
The `mail' and `frm' utilities pass tests.
* include/mailutils/stream.h (mu_stream_err): New proto.
* libproto/mbox/mbox.c (_msg_stream_setup)
(_msg_body_setup): Fix stream abridgment.
(mbox_envelope_date, mbox_envelope_sender): Fix seek position.
(uid_to_stream): Fix invocation of mu_stream_printf.
(append_message_to_stream): Likewise.
(mbox_expunge_unlocked): Rewind tempstr before copying its
contents back to the mailbox.
(mbox_expunge0): Open tempstr.
* libproto/mbox/mbox0.h (_mbox_message)<header_from>: Rename to
envel_from.
<header_from_end>: Rename to envel_from_end. All uses changed.
* libproto/mbox/mboxscan.c: Minor changes.
* mail/decode.c: Use streamrefs.
* mail/escape.c: Likewise.
* mail/msgset.y: Likewise.
* mail/pipe.c: Likewise.
* mail/print.c: Likewise.
* mail/top.c: Likewise.
* mail/write.c: Likewise.
* mail/send.c: Use streamrefs.
(mail_send0): Reset env->header after assigning it to the
message.
* mailbox/body.c (_body_seek): Fix a typo which produced a
recursive call.
* mailbox/file_stream.c (fd_truncate): New function.
(_mu_file_stream_create): Initialize str->stream.truncate.
* mailbox/header.c (header_parse): Fix parsing of blurbs
lacking terminating empty line.
(header_seek): Fix boundary checks. Return new position in
presult.
* mailbox/message.c (string_find_eoh): Rewrite to handle \n\n
split between two successive invocations.
(_header_fill): Update the invocation of string_find_eoh.
* mailbox/stream.c (mu_stream_destroy): Call mu_stream_close.
(mu_stream_get_flags, mu_stream_set_flags)
(mu_stream_clr_flags): Ignore internal bits.
(mu_stream_err): New function.
(mu_stream_close): Close the stream only if it is not used by
anyone else.
* mailbox/streamref.c (_streamref_read): Clear transport error
if ESPIPE is returned.
(_streamref_size): Take into account sp->end and sp->start.
(mu_streamref_create_abridged): Set pointer to 0.
2010-09-08 Sergey Poznyakoff <gray@gnu.org.ua>
Bugfixes in stream code.
* mailbox/amd.c (amd_body_stream_seek): Fix boundary checking.
Return ESPIPE on boundary error.
* mailbox/header.c (header_seek): Likewise.
* mailbox/memory_stream.c (_memory_seek): Likewise.
* mailbox/message.c (_message_stream_seek): Likewise.
* mailbox/message_stream.c (_message_seek): Likewise.
* mailbox/stdio_stream.c (stdio_seek): Likewise.
* mailbox/file_stream.c (fd_open): Invert error condition. Fix
computation of open flags. Return immediately if open returns
-1.
(fd_seek): Fix boundary checking. Return ESPIPE on boundary
error.
* mailbox/mapfile_stream.c (_mapfile_open): Fix flags
calculation.
(_mapfile_seek): Fix boundary checking. Return ESPIPE on
boundary error.
* mailbox/streamref.c (_streamref_read): Fix calculation of the
top size boundary. Return 0 bytes if seek returns ESPIPE.
(_streamref_seek): Return ESPIPE on boundary error.
* mailbox/base64.c (_base64_decoder, _base64_encoder): Do not
dereference iobuf if cmd is mu_filter_init or mu_filter_done.
* mailbox/binflt.c (_copy_codec, _bit7_coder): Likewise.
* mailbox/crlfflt.c (_crlf_encoder, _crlf_decoder): Likewise.
* mailbox/linelenflt.c (_ll_encoder): Likewise.
* mailbox/qpflt.c (_qp_decoder, _qp_encoder): Likewise.
* mailbox/mailcap.c (mu_mailcap_parse): Fix loop condition.
2010-09-08 Sergey Poznyakoff <gray@gnu.org.ua>
Bugfixes.
* examples/sfrom.c (main): Check return from
mu_mailbox_messages_count.
* include/mailutils/sys/stream.h (_MU_STR_WRT): New constant.
* libproto/mbox/mbox.c (_msg_stream_setup): Fix 3rd argument to
mu_streamref_create_abridged.
* libproto/mbox/mboxscan.c (mbox_scan_internal): Don't use
mailbox->stream directly, because its offsets may get shifted
by observers. Use streamref instead.
* mailbox/argcv.c (argcv_get): Do nothing if argc <= 0.
* mailbox/mapfile_stream.c (_mapfile_seek): Fill the *presult.
* mailbox/memory_stream.c (_memory_done): Remove leftover free.
* mailbox/stream.c: Reorder functions.
(_mu_stream_create): Increase reference count (i.e. set it to
1) before returning.
(mu_stream_seek): Call _stream_flush_buffer instead of
mu_stream_flush.
(mu_stream_read_unbuffered): Return 0 on EOF.
(mu_stream_write_unbuffered): Set _MU_STR_WRT bit.
(mu_stream_readline, mu_stream_getdelim): Check the actual
number of bytes read.
(mu_stream_flush): Call flush method only if _MU_STR_WRT is
set. Clear it.
* mailbox/streamref.c (_streamref_seek): Optimization for
off==0 and whence == MU_SEEK_CUR.
(_streamref_seek): Return new offset in ppos.
(mu_streamref_create_abridged): Set MU_STREAM_NO_CLOSE.
* mailbox/memory_stream.c (_memory_seek) : Return new offset in
presult.
* mailbox/message_stream.c (_message_seek): Likewise.
* mailbox/stdio_stream.c (stdio_seek): Fix prototype.
2010-09-08 Sergey Poznyakoff <gray@gnu.org.ua>
Stream support rewritten from scratch.
Does not compile yet.
New files:
* mailbox/streamref.c
* include/mailutils/sys/streamref.h
* include/mailutils/sys/file_stream.h
* include/mailutils/sys/header_stream.h
* include/mailutils/sys/mapfile_stream.h
* include/mailutils/sys/memory_stream.h
* include/mailutils/sys/message_stream.h
* include/mailutils/sys/prog_stream.h
* include/mailutils/sys/socket_stream.h
* include/mailutils/sys/stdio_stream.h
* include/mailutils/sys/stream.h
* include/mailutils/sys/streamtrans.h
* mailbox/prog_stream.c
* mailbox/stdio_stream.c
* mailbox/stream_printf.c
* mailbox/stream_vprintf.c
* mailbox/temp_file_stream.c
* mailbox/streamcpy.c
* mailbox/binflt.c
* mailbox/crlfflt.c
* mailbox/fltstream.c
* mailbox/qpflt.c
* mailbox/linelenflt.c
Removed files:
* mailbox/filter_rfc822.c
* mailbox/filter_trans.c
Moved files (with edits):
* libproto/include/filter0.h -> include/mailutils/sys/filter.h
* libproto/include/header0.h -> include/mailutils/sys/header.h
* libproto/include/message0.h ->
include/mailutils/sys/message.h
* libproto/include/mime0.h -> include/mailutils/sys/mime.h
Modified files:
* comsat/action.c
* config/mailutils-config.c
* examples/base64.c
* examples/cpp/msg-send.cc
* examples/header.c
* examples/http.c
* examples/iconv.c
* examples/mimetest.c
* examples/msg-send.c
* examples/mta.c
* examples/murun.c
* examples/nntpclient.c
* examples/pop3client.c
* imap4d/append.c
* imap4d/auth_gsasl.c
* imap4d/fetch.c
* imap4d/preauth.c
* imap4d/search.c
* imap4d/util.c
* include/mailutils/body.h
* include/mailutils/folder.h
* include/mailutils/header.h
* include/mailutils/mailbox.h
* include/mailutils/mailer.h
* include/mailutils/mailutils.h
* include/mailutils/message.h
* include/mailutils/stream.h
* include/mailutils/sys/Makefile.am
* include/mailutils/sys/filter.h
* include/mailutils/sys/header.h
* include/mailutils/sys/message.h
* include/mailutils/sys/mime.h
* include/mailutils/sys/nntp.h
* include/mailutils/sys/pop3.h
* include/mailutils/sys/stream.h
* include/mailutils/types.hin
* lib/mailcap.c
* lib/mu_dbm.h
* libmu_argp/muinit.c
* libmu_auth/ldap.c
* libmu_auth/tls.c
* libmu_scm/Makefile.am
* libmu_scm/mu_body.c
* libmu_scm/mu_message.c
* libmu_scm/mu_port.c
* libmu_sieve/actions.c
* libmu_sieve/extensions/pipe.c
* libmu_sieve/extensions/spamd.c
* libmu_sieve/extensions/vacation.c
* libproto/mailer/smtp.c
* libproto/mbox/mboxscan.c
* libproto/mbox/mbox.c
* libproto/mbox/mbox0.h
* libproto/nntp/nntp_article.c
* libproto/nntp/nntp_carrier.c
* libproto/nntp/nntp_destroy.c
* libproto/nntp/nntp_ihave.c
* libproto/nntp/nntp_post.c
* libproto/nntp/nntp_readline.c
* libproto/nntp/nntp_sendline.c
* libproto/pop/pop3_carrier.c
* libproto/pop/pop3_destroy.c
* libproto/pop/pop3_readline.c
* libproto/pop/pop3_sendline.c
* libproto/pop/pop3_stat.c
* maidag/mailtmp.c
* mail/decode.c
* mail/escape.c
* mail/msgset.y
* mail/pipe.c
* mail/print.c
* mail/send.c
* mail/top.c
* mail/util.c
* mail/write.c
* mailbox/Makefile.am
* mailbox/amd.c
* mailbox/attachment.c
* mailbox/body.c
* mailbox/cfg_driver.c
* mailbox/cfg_format.c
* mailbox/debug.c
* mailbox/file_stream.c
* mailbox/folder.c
* mailbox/hdritr.c
* mailbox/header.c
* mailbox/mailbox.c
* mailbox/mailcap.c
* mailbox/mailer.c
* mailbox/mapfile_stream.c
* mailbox/memory_stream.c
* mailbox/message.c
* mailbox/message_stream.c
* mailbox/mime.c
* mailbox/mimehdr.c
* mailbox/mutil.c
* mailbox/prog_stream.c
* mailbox/progmailer.c
* mailbox/rfc2047.c
* mailbox/socket_stream.c
* mailbox/stream.c
* mailbox/stream_vprintf.c
* mailbox/tcp.c
* mailbox/vartab.c
* mailbox/wicket.c
* mh/burst.c
* mh/comp.c
* mh/compcommon.c
* mh/forw.c
* mh/mh_ctx.c
* mh/mh_format.c
* mh/mh_init.c
* mh/mh_list.c
* mh/mh_whatnow.c
* mh/mhl.c
* mh/mhn.c
* mh/pick.y
* mh/repl.c
* mimeview/mimeview.c
* mu-aux/generr.awk
* pop3d/extra.c
* pop3d/pop3d.h
* pop3d/retr.c
* pop3d/top.c
* readmsg/msglist.c
* readmsg/readmsg.c
* sieve/sieve.c
2010-09-08 Sergey Poznyakoff <gray@gnu.org.ua>
Version 2.2.
* NEWS, configure.ac: Update.
2010-09-07 Sergey Poznyakoff <gray@gnu.org.ua>
imap4d: fetch body with a nonempty section spec returns section
body without headers.
* imap4d/fetch.c (fetch_function_closure) <section_tag>: New
member.
(_frt_body_text): Output ffc->section_tag after the section
part by default.
(_frt_header, _frt_mime): Remove.
(_frt_header0): Rewrite as a general-purpose _frt_header
function.
(parse_section_text): Set _frt_header as a driver function and
set section_tag accordingly, instead of selecting
_frt_header/_frt_mime. Set section_tag when selecting
_frt_body_text.
(parse_section): Default to _frt_body_text and fall back to
_frt_body only when an empty section specifier is given.
* imap4d/testsuite/imap4d/fetch.exp: Update accordingly.
2010-08-26 Sergey Poznyakoff <gray@gnu.org.ua>
Bugfix.
* mailbox/acl.c (expand_arg): Fix a memory leak.
2010-08-12 Sergey Poznyakoff <gray@gnu.org.ua>
Minor change.
* examples/mimetest.c (message_display_parts): Remove not
needed locals.
2010-08-12 Sergey Poznyakoff <gray@gnu.org.ua>
Bugfixes.
* mailbox/mime.c (mu_mime_get_num_parts): Assume MIME message
is not scanned if nmtp_parts are 0 and boundary is NULL.
* mailbox/rfc2047.c (mu_rfc2047_decode): Free the buffer prior
to returning a non-zero status.
* mailbox/message.c (mu_message_destroy): Install a kludge to
work over the sloppy ref semantics.
* mailbox/auth.c (mu_authority_destroy): Free auth_methods
list.
* mailbox/locker.c (destroy_dotlock): Free data.dot.nfslock.
2010-06-02 Sergey Poznyakoff <gray@gnu.org.ua>
Minor fix.
* examples/Makefile.am (mta_CPPFLAGS): New variable.
2010-06-02 Sergey Poznyakoff <gray@gnu.org.ua>
Implement mu-mailbox-get-size function.
* libmu_scm/mu_mailbox.c (mu-mailbox-get-size): New function.
2010-05-26 Sergey Poznyakoff <gray@gnu.org.ua>
Fix mailbox corruption in imap4d.
Delivery of a signal when a previous signal was being handled
caused mailbox corruption.
* imap4d/imap4d.c (imap4d_child_signal_setup): New function.
(imap4d_mainloop): Call imap4d_child_signal_setup.
* imap4d/signal.c (imap4d_child_signal): Reset all signal
handlers before doing actual job.
* lib/signal.c (mu_set_signals): Use sigaction.
2010-05-20 Sergey Poznyakoff <gray@gnu.org.ua>
Movemail improved.
* movemail/movemail.c: New options: --ignore-errors and
--program-id.
(_compare_msgno): Remove now unneeded static.
(main): Handle --ignore-errors and --program-id settings.
Optimize the main loop for the case when --uidls is given.
Return 1 on errors.
* doc/texinfo/programs.texi: Document new features.
2010-05-20 Sergey Poznyakoff <gray@gnu.org.ua>
Allow to use `CALL proc' in MySQL queries.
* sql/mysql.c (mu_mysql_connect): Set CLIENT_MULTI_RESULTS
flag.
2010-05-18 Sergey Poznyakoff <gray@gnu.org.ua>
Bugfix.
* mailbox/url.c (_url_path_default): Fix improper use of sizeof
(a typo, probably).
2010-05-13 Sergey Poznyakoff <gray@gnu.org.ua>
MH: Improve handling of not implemented options.
* mh/mh_getopt.c (mh_opt_notimpl, mh_opt_notimpl_warning): New
functions.
* mh/mh_getopt.h (mh_opt_notimpl, mh_opt_notimpl_warning): New
protos.
* mh/ali.c (doc): Remove 'not implemented' stanza.
* mh/pick.c: Likewise.
* mh/anno.c: Use mh_opt_notimpl and mh_opt_notimpl_warning for
not implemented options.
* mh/comp.c: Likewise.
* mh/forw.c: Likewise.
* mh/mhn.c: Likewise.
* mh/refile.c: Likewise.
* mh/repl.c: Likewise.
* mh/scan.c: Likewise.
* mh/send.c: Likewise.
2010-05-13 Sergey Poznyakoff <gray@gnu.org.ua>
MH: a bugfix.
* mh/mh_global.c (mh_read_profile): Set MU folder directory to
mh_get_dir. This fixes the bug reported by Peter S Galbraith
(Id. <15312.1273667793@mixed>, ref.
http://sourceforge.net/mailarchive/forum.php?thread_name=15904.
1273699954%40mixed&forum_name=mh-e-devel)
2010-05-11 Sergey Poznyakoff <gray@gnu.org.ua>
Upgrade gint to a5774356.
2010-05-11 Sergey Poznyakoff <gray@gnu.org.ua>
Fix GINT_INIT usage.
* gint: Update to 4e48677eee5a
* configure.ac (--without-guile): Remove option. Handled by
GINT_INIT.
(GINT_INIT): Don't call it within a conditional.
2010-05-07 Sergey Poznyakoff <gray@gnu.org.ua>
Minor fix.
* mailbox/rfc2047.c (getword): Initialize *pret to NULL after
freeing it.
2010-04-29 Sergey Poznyakoff <gray@gnu.org.ua>
Minor change.
* libproto/include/mime0.h (struct _mu_mime): Use size_t for
offsets, ssize_t for line_ndx.
2010-04-29 Sergey Poznyakoff <gray@gnu.org.ua>
Allow for a sequence of semicolons before kw/value pair in a
structured header.
* mailbox/mimehdr.c (_header_get_param): Skip superfluous
semicolons.
2010-04-29 Sergey Poznyakoff <gray@gnu.org.ua>
Remove line length limitation in mime parser.
* libproto/include/mime0.h (struct _mu_mime): New member
line_size.
* mailbox/mime.c (_mime_setup_buffers): Use line_size instead
of MIME_MAX_HDR_LEN.
(_mime_parse_mpart_message): Reallocate cur_line as necessary.
(mu_mime_create): Initialize line_size.
2010-04-29 Sergey Poznyakoff <gray@gnu.org.ua>
Allow for certain class of broken headers.
* mailbox/mimehdr.c (_header_get_param): Tolerate unquoted
value parts which contain tspecials, except ';'.
2010-04-26 Sergey Poznyakoff <gray@gnu.org.ua>
Accept additional whitespace and quotes in the disposition part
of MIME headers.
* mailbox/mimehdr.c (disp_segment_len): New function.
(mu_mimehdr_get_disp, mu_mimehdr_aget_disp): Use
disp_segment_len. Unquote the returned string.
(_header_get_param): Allow for whitespace before '"'. Unquote
the string before comparison.
2010-04-18 Sergey Poznyakoff <gray@gnu.org.ua>
Bugfix.
* mailbox/cfg_lexer.l (mu_cfg_parse_file): Parse only regular
files.
2010-04-14 Sergey Poznyakoff <gray@gnu.org.ua>
Fix indirect memory leak in mu_decode_filter.
* include/mailutils/stream.h (mu_stream_clr_flags): New
function.
* mailbox/stream.c (mu_stream_clr_flags): New function.
* mailbox/mapfile_stream.c (_mapfile_open): Avoid unnecessary
boolean operation.
* mailbox/mutil.c (mu_decode_filter): Use mu_stream_clr_flags
to clear bits.
2010-04-14 Sergey Poznyakoff <gray@gnu.org.ua>
Improve mu_mimehdr_a?get_disp.
* mailbox/mimehdr.c (mu_mimehdr_get_disp)
(mu_mimehdr_aget_disp): Return disposition even if no
parameters have been given.
2010-04-14 Sergey Poznyakoff <gray@gnu.org.ua>
Fix memory leaks in filter and filter_iconv code.
* mailbox/filter.c (filter_destroy): Destroy the underlying
stream, unless flag is given.
(mu_filter_create): Treat last argument as stream flags.
* mailbox/filter_iconv.c (_icvt_destroy): Free the icvt_stream
structure.
* examples/mimetest.c (message_display_parts): Pass
MU_STREAM_NO_CLOSE to the invocation of mu_filter_create.
* mail/decode.c (display_submessage): Likewise.
* mailbox/attachment.c (mu_message_save_attachment): Likewise.
* mh/mh_list.c (eval_body): Likewise.
* mh/mhn.c (mhn_message_size, show_internal): Likewise.
(finish_text_msg): Likewise; call mu_stream_destroy
* imap4d/preauth.c (decode64_buf): remove unnecessary call to
mu_stream_destroy.
* libmu_auth/ldap.c (chk_md5, chk_smd5)
(chk_sha, chk_ssha): Likewise.
* mailbox/mutil.c: Fix indentation.
2010-04-14 Sergey Poznyakoff <gray@gnu.org.ua>
Fix memory leak in mu_rfc2047_decode.
* mailbox/rfc2047.c (getword): Change signature; return error
code.
(mu_rfc2047_decode): Reflect the above change.
2010-04-14 Sergey Poznyakoff <gray@gnu.org.ua>
Further improvements in the Guile-related code.
* gint: Upgrade.
* libmu_scm/Makefile.am: Initialize BUILT_SOURCES.
* libmu_scm/mu_address.c (address_get_fp): Change signature to
match those of mu_address_aget family.
(all functions): Use functions from mu_address_aget family.
Downcase argument names. Refer to them in the docstring using
@var notation.
* libmu_scm/mu_body.c: Downcase argument names. Refer to them
in the docstring using @var notation.
* libmu_scm/mu_logger.c: Likewise.
* libmu_scm/mu_mailbox.c: Likewise.
* libmu_scm/mu_message.c: Likewise.
* libmu_scm/mu_mime.c: Likewise.
* libmu_scm/mu_scm.c: Likewise.
* libmu_scm/mu_util.c: Likewise.
2010-04-12 Sergey Poznyakoff <gray@gnu.org.ua>
Migrate Guile support to GINT.
* gint: New module.
* am/guile.m4: Remove.
* mu-aux/guile-doc-snarf: Remove.
* mu-aux/guile-doc-snarf.awk: Remove.
* mu-aux/Makefile.am (EXTRA_DIST): Remove guile-doc-snarf,
guile-doc-snarf.awk
* Makefile.am: Add gint.
* bootstrap.conf: Init gint submodule.
* configure.ac: Rewrite Guile support using GINT_INIT.
(AC_CONFIG_FILES): Add gint/Makefile.
* guimb/scm/Makefile.am (sitedir): Change.
* guimb/scm/Makefile.am: Likewise.
* libmu_scm/Makefile.am: Include ../gint/gint.mk Adjust all
variables. Remove unnecessary rules.
* libmu_scm/mailutils.scm.in: Remove exports and includes.
Remove obsolete code.
* libmu_scm/mu_address.c: Use SCM_DEFINE_PUBLIC to declare
public interfaces.
* libmu_scm/mu_body.c: Likewise.
* libmu_scm/mu_mailbox.c: Likewise.
* libmu_scm/mu_message.c: Likewise.
* libmu_scm/mu_mime.c: Likewise.
* libmu_scm/mu_util.c: Likewise.
* libmu_scm/mu_logger.c: Likewise.
(mu_scm_logger_init): Make all constants public.
* libmu_scm/mu_scm.c: Likewise.
* libmu_scm/mu_guile.c: Use scm_c_catch instead of the obsolete
scm_internal_lazy_catch.
2010-04-08 Sergey Poznyakoff <gray@gnu.org.ua>
Fix all FIXMEs from b2c1b1ff. Revise attachment API.
* include/mailutils/message.h (mu_message_save_attachment)
(mu_message_encapsulate, mu_message_unencapsulate): Change type
of the last argument.
(mu_mime_io_buffer_create,mu_mime_io_buffer_destroy)
(mu_mime_io_buffer_set_size,mu_mime_io_buffer_get_size)
(mu_mime_io_buffer_set_charset,mu_mime_io_buffer_sget_charset)
(mu_mime_io_buffer_aget_charset): New prototypes.
(mu_mimehdr_get_disp,mu_mimehdr_aget_disp): Remove unneeded
parameter.
* include/mailutils/types.hin (mu_mime_io_buffer_t): New type.
* mailbox/attachment.c (_msg_info): Rename structure to
_mu_mime_io_buffer.
<header_buf,header_len,mu_header_size>: Remove unreferenced
members.
<refcnt,bufsize,charset>: New members.
<ioffset,ooffset>: Change type to size_t.
(mu_mime_io_buffer_create,mu_mime_io_buffer_destroy)
(mu_mime_io_buffer_set_size,mu_mime_io_buffer_get_size)
(mu_mime_io_buffer_set_charset,mu_mime_io_buffer_sget_charset)
(mu_mime_io_buffer_aget_charset): New functions.
(mu_message_save_attachment)
(mu_message_encapsulate, mu_message_unencapsulate): Take
mu_mime_io_buffer_t as the last argument.
* mailbox/mimehdr.c (mu_mimehdr_get_disp): Remove unneeded
parameter.
(mu_mimehdr_aget_disp): Remove unneeded parameter. Store return
value into pvalue.
* examples/mimetest.c (message_display_parts): Use
mu_mimehdr_aget_disp and mu_mime_io_buffer_* functions.
* mailbox/testsuite/Mime: Update.
* mh/mhn.c (options, opt_handler): New option --charset.
(store_handler): Use mu_message_aget_decoded_attachment_name.
2010-04-08 Sergey Poznyakoff <gray@gnu.org.ua>
Minor change.
* mailbox/rfc2047.c: Minor style fix.
2010-04-08 Wojciech Polak <polak@gnu.org>
Reflect recent RFC compatibility changes in Python/C++.
* examples/python/mimetest.py: Update.
* include/mailutils/cpp/message.h (get_attachment_name):
Overload.
* libmu_cpp/message.cc (Message::get_attachment_name):
Overload.
* python/libmu_py/message.c (api_message_get_attachment_name):
Update.
* python/mailutils/message.py (Message.get_attachment_name):
Add optional charset parameter. Return (name, lang) tuple.
2010-04-08 Sergey Poznyakoff <gray@gnu.org.ua>
Bugfix in mu_rfc2047_decode.
* mailbox/rfc2047.c (mu_rfc2047_decode): Use temporary buffer
for reading from the filter stream, to avoid preliminary
breaking from the read loop when end of the buffer is reached.
Realloc the buffer as necessary.
2010-04-08 Sergey Poznyakoff <gray@gnu.org.ua>
Bugfixes.
* mailbox/mimehdr.c (_header_get_param): If buf is NULL on
entry, make sure it always points to allocated memory
afterward.
* examples/mimetest.c (charset): New variable.
(main): New command line option -c.
(message_display_parts): Use
mu_message_aget_decoded_attachment_name. Pass fname to
mu_message_save_attachment.
2010-04-08 Sergey Poznyakoff <gray@gnu.org.ua>
Improve MIME parameter parsing.
* mailbox/mimehdr.c (_header_get_param): Improve error
checking. Allow for optional whitespace around the '='.
* mailbox/rfc2047.c (mu_rfc2047_decode): tocode=NULL is OK.
2010-04-06 Sergey Poznyakoff <gray@gnu.org.ua>
Improve compatibility with RFC 2231 and RFC 2047.
* mailbox/mimehdr.c: New file.
* mailbox/Makefile.am (libmailutils_la_SOURCES): Add
mailbox/mimehdr.c.
* mailbox/attachment.c (_header_get_param)
(_get_attachment_name, mu_message_aget_attachment_name)
(mu_message_get_attachment_name: Move to mailbox/mimehdr.c
(with edits).
(mu_message_save_attachment): Add a FIXME comment.
* include/mailutils/message.h (MU_MIMEHDR_MULTILINE)
(MU_MIMEHDR_CSINFO): New defines.
(mu_mimehdr_get_disp,mu_mimehdr_aget_disp)
(mu_mimehdr_get_param,mu_mimehdr_aget_param)
(mu_mimehdr_decode_param)
(mu_mimehdr_aget_decoded_param): New prototypes.
(mu_message_aget_attachment_name): Change signature.
(mu_message_aget_decoded_attachment_name): New prototype.
* mailbox/mutil.c (mu_hex2ul): Fix a silly bug (have anybody
ever tried to use that function?!?)
* mailbox/testsuite/Urls: Update.
* examples/mimetest.c (message_display_parts): Add a FIXME
comment.
* libmu_cpp/message.cc (Message::get_attachment_name):
Likewise.
* mh/mhn.c (store_handler): Likewise.
* python/libmu_py/message.c (api_message_get_attachment_name):
Likewise.
2010-04-03 Sergey Poznyakoff <gray@gnu.org.ua>
Make mu_message_(a?)get_attachment_name RFC-compatible.
* mailbox/attachment.c (_header_get_param): Rewrite.
(_get_attachment_name): New auxiliary function.
(mu_message_aget_attachment_name)
(mu_message_get_attachment_name): Rewrite using
_get_attachment_name.
* mh/mhn.c (store_handler): Use
mu_message_aget_attachment_name.
2010-04-01 Sergey Poznyakoff <gray@gnu.org.ua>
Implement mailbox iterators in Scheme.
* libmu_scm/mu_mailbox.c (struct mu_mailbox)<itr>: New member.
(mu_scm_mailbox_free): Destroy the iterator.
(mu_scm_mailbox_create0): Initialize itr to NULL.
(mu-mailbox-first-message, mu-mailbox-next-message)
(mu-mailbox-more-messages?): New function.
* guimb/scm/sieve-core.scm (sieve-run): Rewrite main loop in
the True Schemish Way.
2010-04-01 Sergey Poznyakoff <gray@gnu.org.ua>
Implement mailbox iterators.
* include/mailutils/mailbox.h (mu_mailbox_get_iterator): New
function.
* libproto/include/mailbox0.h (struct _mu_mailbox)<iterator>:
New member.
* mailbox/mbxitr.c: New file.
* mailbox/Makefile.am (libmailutils_la_SOURCES): Add mbxitr.c
2010-04-01 Sergey Poznyakoff <gray@gnu.org.ua>
Bugfix.
* mailbox/attachment.c (_ISSPECIAL): Fix definition.
2010-04-01 Sergey Poznyakoff <gray@gnu.org.ua>
Style fix.
* mailbox/attachment.c: Fix indentation.
2010-04-01 Sergey Poznyakoff <gray@gnu.org.ua>
Fix the use of deprecated Guile interfaces in port code.
* am/guile.m4 (MU_CHECK_GUILE): Check for SCM_DEVAL_P et al.
* libmu_scm/mu_guile.c (mu_guile_init): Protect calls to
SCM_DEVAL_P &c. by #ifdef GUILE_DEBUG_MACROS
* libmu_scm/mu_port.c [!HAVE_SCM_T_OFF](scm_t_off): New
typedef.
(mu_port_make_from_stream): Use scm_new_port_table_entry
instead of the deprecated scm_add_to_port_table
2010-04-01 Sergey Poznyakoff <gray@gnu.org.ua>
Fix SCM syslog interface.
* libmu_scm/mu_logger.c (log_tag): New static.
(mu-openlog): Preserve log tag in log_tag, because openlog
stores its first argument as-is. Simplify argument handling.
(mu-logger): Simplify argument handling.
(mu-closelog): Free log_tag.
2010-04-01 Sergey Poznyakoff <gray@gnu.org.ua>
Remove the uses of deprecated Guile functions.
* am/guile.m4 (MU_CHECK_GUILE): Check for scm_t_off.
* include/mailutils/guile.h (mu_scm_makenum)
(mu_set_variable): Remove prototypes.
* libmu_scm/mu_address.c: Remove calls to deprecated Guile
functions.
* libmu_scm/mu_body.c: Likewise.
* libmu_scm/mu_guile.c: Likewise.
* libmu_scm/mu_mailbox.c: Likewise.
* libmu_scm/mu_message.c: Likewise.
* libmu_scm/mu_mime.c: Likewise.
* libmu_scm/mu_util.c: Likewise.
* libmu_scm/mu_scm.c (mu_scm_makenum): Remove.
(mu_set_variable): Remove. Use scm_c_define instead.
2010-04-01 Sergey Poznyakoff <gray@gnu.org.ua>
Add missing include.
* mailutils/mutil.h: Include mailutils/mutil.h
2010-03-31 Sergey Poznyakoff <gray@gnu.org.ua>
Fix parsing of per-user configuration files.
The mu_cfg_parse_file function ignored special meaning of the
initial "~/" in file names. This led to user configuration
files not being read (mu_libcfg_parse_config creates such names
if mu_load_user_rcfile is set).
* mailbox/cfg_lexer.l (mu_cfg_parse_file): Expand initial tilde
in the file name. Store expanded file name in the opool.
(mu_get_config): Destroy tree only if it has actually been
created.
* mailbox/cfg_parser.y (mu_cfg_parse): Free allocated memory in
case of error.
(do_include): Fix memory leak.
2010-03-19 Sergey Poznyakoff <gray@gnu.org.ua>
Minor change.
* bootstrap.conf: Define COPYRIGHT_HOLDER.
2010-03-19 Simon Josefsson <simon@josefsson.org>
Bugfix.
* imap4d/auth_gsasl.c (auth_gsasl): Fix memory management.
2010-03-13 Sergey Poznyakoff <gray@gnu.org.ua>
Bugfix.
* mailbox/cfg_parser.y (mu_cfg_tree_union): Fix coredump on
b->nodes==NULL.
2010-02-21 Sergey Poznyakoff <gray@gnu.org.ua>
Re-do configuration tree support using mu_list_t.
* include/mailutils/cfg.h (mu_cfg_node)
<next,node>: Remove members.
<nodes>: New member.
(mu_cfg_tree)<head,tail>: Remove.
<nodes>: New member.
(mu_cfg_iter_closure): New struct.
(mu_cfg_preorder): Change prototype.
(mu_cfg_postorder): Remove.
(mu_cfg_create_node_list): New proto.
(mu_cfg_tree_create_node): Change signature.
(mu_cfg_tree_add_nodelist): New proto.
(mu_cfg_find_node): Change signature.
* include/mailutils/libargp.h (mu_argp_node_list): Remove
struct. (mu_argp_node_list_init, mu_argp_node_list_add)
(mu_argp_node_list_new, mu_argp_node_list_finish): Change
signature.
* libmu_argp/cmdline.c (mu_argp_node_list_init,
mu_argp_node_list_add)
(mu_argp_node_list_new, mu_argp_node_list_finish): Take
mu_list_t as the nodelist argument.
* mailbox/cfg_parser.y (parse_head,parse_tail): Remove.
(parse_node_list): New static, used instead of the above. All
uses updated.
(mu_cfg_alloc_node): Last argument is mu_list_t.
(mu_cfg_create_node_list): New function.
(mu_cfg_tree_postprocess): Rewrite.
(mu_cfg_preorder): Rewrite.
(mu_cfg_postorder): Remove.
(mu_cfg_destroy_tree): Use mu_list_destroy to free the node
list.
(mu_cfg_scan_tree): Update calls to mu_cfg_preorder.
(mu_cfg_tree_add_node): Rewrite.
(mu_cfg_tree_add_nodelist): New function.
(mu_cfg_find_node): Change type of the first argument.
(mu_cfg_create_subtree): Rewrite.
* mailbox/cfg_format.c (mu_cfg_format_parse_tree)
(mu_cfg_format_node): Use new mu_cfg_preorder function.
* libmu_argp/common.c: Update calls to mu_argp_node_ functions.
* libmu_argp/auth.c: Likewise.
* comsat/comsat.c: Likewise.
* config/mailutils-config.c: Likewise.
* dotlock/dotlock.c: Likewise.
* imap4d/imap4d.c: Likewise.
* libmu_argp/sieve.c: Likewise.
* libmu_argp/tls.c: Likewise.
* maidag/maidag.c: Likewise.
* mimeview/mimeview.c: Likewise.
* movemail/movemail.c: Likewise.
* pop3d/pop3d.c: Likewise.
* readmsg/readmsg.c: Likewise.
* sieve/sieve.c: Likewise.
2010-02-21 Sergey Poznyakoff <gray@gnu.org.ua>
Bugfixes.
* mailbox/listlist.c (mu_list_append_list)
(mu_list_prepend_list): Initialize head.next and head.prev if
the destination list was empty.
* mailbox/freeitem.c: Include stdlib.h.
* mailbox/list.c: Minor style fix.
2010-02-20 Sergey Poznyakoff <gray@gnu.org.ua>
Implement bidirectional iteration over lists.
* include/mailutils/iterator.h (mu_itrctl_qry_direction)
(mu_itrctl_set_direction): New mu_itrctl_req constants.
* mailbox/iterator.c (mu_iterator_dup): Bugfix: copy dup as
well.
* mailbox/list.c (struct list_iterator)
<backwards>: New member.
(first, next): Move direction depends on the value of
list_iterator.backwards.
(list_itrctl): Handle mu_itrctl_qry_direction and
mu_itrctl_set_direction
* examples/listop.c (ictl_dir): New function.
(ictl_ins): Handle new subcommand "dir".
(help): Show new subcommand "dir".
* mailbox/testsuite/mailbox/list.exp: Add tests for iteration
backwards.
2010-02-20 Sergey Poznyakoff <gray@gnu.org.ua>
Mu_list_replace and mu_list_remove actually reclaim the memory
associated with the item.
* include/mailutils/iterator.h (mu_itrctl_delete_nd)
(mu_itrctl_replace_nd): New mu_itrctl_req constants.
* include/mailutils/list.h (mu_list_remove_nd)
(mu_list_replace_nd): New prototypes.
(mu_list_destroy_item_t): New typedef.
(mu_list_set_destroy_item): Return mu_list_destroy_item_t.
* mailbox/list.c (DESTROY_ITEM): New macro.
(mu_list_destroy): Use DESTROY_ITEM.
(mu_list_remove, mu_list_replace): Actually destroy the item
being removed.
(mu_list_remove_nd, mu_list_replace_nd): New functions.
(mu_list_set_destroy_item): Return previous value of
destroy_item.
(list_itrctl): Handle mu_itrctl_delete_nd and
mu_itrctl_replace_nd.
* mailbox/observer.c (mu_observable_create): Register
destroy_item function.
(mu_observable_destroy): Remove explicit loop. Rely on
destroy_item instead.
(mu_observable_detach): Use mu_iterator_ctl to actually remove
the event.
* mh/mh_alias.y (_insert_list): Remove.
(alias_expand_list): Use mu_iterator_ctl to insert replacement
list and remove the current item.
* mh/sortm.c (addop): Register destroy_item function.
(remop): Remove call to free.
* movemail/movemail.c (main): <uidl loop>: Use mu_itrctl_delete
to remove items.
* libmu_sieve/util.c: Minor change.
* mail/util.c (util_slist_compare): New static function.
(util_slist_add): Register destroy_item and comparison
functions for the new list.
(util_slist_remove,util_slist_destroy): Rewrite.
* imap4d/authenticate.c (auth_add): Use mu_list_free_item as
destroy_item function.
* imap4d/util.c (util_register_event): Likewise.
* include/mailutils/cpp/list.h (List)<set_destroy_item>: Change
return value.
* libmu_cpp/list.cc (List::set_destroy_item): Reflect changes
to mu_list_set_destroy_item.
* libmu_argp/common.c: Include stdlib.h
2010-02-20 Sergey Poznyakoff <gray@gnu.org.ua>
Implement `iterator_ctl' function.
* include/mailutils/iterator.h (mu_itrctl_req): New enum.
(mu_iterator_skip, mu_iterator_ctl)
(mu_iterator_set_itrctl): New prototypes.
* include/mailutils/list.h (mu_list_free_item): New prototype.
* libproto/include/iterator0.h (struct _mu_iterator)<itrctl>:
New method.
* libproto/include/list0.h (_mu_list_clear): New proto.
* mailbox/iterator.c (mu_iterator_set_itrctl): New function.
(mu_iterator_skip, mu_iterator_ctl): New functions.
* mailbox/list.c (_insert_item): Re-implement function.
(mu_list_insert): Use _insert_item again.
(mu_list_remove): Don't keep track of the previous item.
(list_itrctl): New function.
(mu_list_get_iterator): Set itrctl method.
* mailbox/listlist.c (clear_list): Rename to _mu_list_clear,
remove static qualifier. All uses updated.
* mailbox/freeitem.c: New file.
* mailbox/Makefile.am (libmailutils_la_SOURCES): Add
freeitem.c.
* examples/listop.c (read_list): Rewrite to simplify calling
convention. All callers updated.
(inctl_tell,ictl_del,ictl_repl)
(ictl_ins,ictl): New functions.
(help): Add new commands.
(shell): Handle "inctl" command.
(delete): Fix memory leak.
(main): Set mu_list_free_item as a destroy_item function.
* mailbox/testsuite/mailbox/listop.c: Add ictl tests.
* libmu_cfg/sieve.c (_add_path): Set mu_list_free_item as a
destroy_item function.
* mailbox/gocs.c (mu_gocs_store): Likewise.
* maidag/lmtp.c (cfun_rcpt_to): Likewise.
* imap4d/namespace.c (namespace_init): Likewise.
* libmu_sieve/conf.c (_path_append): Likewise.
2010-02-19 Sergey Poznyakoff <gray@gnu.org.ua>
Implement new list functions.
* include/mailutils/list.h (_mu_list_ptr_comparator)
(mu_list_insert_list, mu_list_append_list)
(mu_list_prepend_list): New prototypes.
* libproto/include/list0.h (_mu_list_insert_sublist): New
prototype.
* mailbox/listlist.c: New function.
* mailbox/Makefile.am (libmailutils_la_SOURCES): Add
listlist.c.
* mailbox/list.c: Remove unnecessary parentheses.
(def_comp): Rename to _mu_list_ptr_comparator. Remove static
qualifier. All uses updated.
(_insert_item): Remove.
(mu_list_insert): Use _mu_list_insert_sublist instead of
_insert_item.
* examples/listop.c (print): Print number of elements.
(count): New function.
(ins): Use mu_list_insert if only one new element was given,
mu_list_insert_list otherwise.
(help): Update.
(main)<count>: New keyword.
* mailbox/testsuite/mailbox/list.exp: Update. Add new tests.
2010-02-19 Sergey Poznyakoff <gray@gnu.org.ua>
Minor fixes.
* mailbox/attachment.c (MAX_HDR_LEN): Remove unused define.
* sieve/sieve.c (parser) <ARGP_KEY_NO_ARGS>: Don't check for
the script,
(main): ... do it here, instead.
2010-02-19 Sergey Poznyakoff <gray@gnu.org.ua>
Work around a libtool bug.
* configure.ac [WITH_GSSAPI]: Remove any -Wl directives from
GSSAPI_LIBS.
2010-02-17 Sergey Poznyakoff <gray@gnu.org.ua>
Minor fix.
* mail/send.c (mail_send0): Pipe message to the program if the
value of sendmail variable begins with a slash. Otherwise,
issue meaningful error messages if the mailer cannot be created
or opened.
2010-02-17 Sergey Poznyakoff <gray@gnu.org.ua>
Bugfix.
* libproto/mbox/mbox.c (mbox_append_message): Fix qid
calculation.
2010-02-11 Sergey Poznyakoff <gray@gnu.org.ua>
Bugfix.
* libproto/mailer/smtp.c (cram_md5): Remove left-over
assignment to challenge_len.
2010-02-10 Sergey Poznyakoff <gray@gnu.org.ua>
Fix memory override in smtp.c code. Fix ESMTP capability
parsing.
* mailbox/base64.c (mu_base64_encode): Make sure output buffer
is null-terminated.
* imap4d/auth_gss.c (auth_gssapi): Assume buffer returned by
mu_base64_encode is null-terminated.
* libproto/mailer/smtp.c (cram_md5): Take challenge_len as
argument. All callers updated.
(smtp_auth): Fix eventual memory override. Assume buffer
returned by mu_base64_encode is nul-terminated.
(smtp_parse_ehlo_ack): Fix capability parsing: (a) do not
depend on the continuation marker ('-' or ' ') and (b) fix
parsing of the SIZE capability. Move call to mu_rtrim_cset out
of the internal loop.
2010-02-09 Sergey Poznyakoff <gray@gnu.org.ua>
Fix TLS stream leak.
* libmu_auth/tls.c (_tls_destroy): Destroy underlying streams,
unless MU_STREAM_NO_CLOSE is set.
(_tls_close): Likewise for close.
2010-02-09 Sergey Poznyakoff <gray@gnu.org.ua>
Bugfixes.
* libproto/imap/mbox.c (imap_append_message0): Send trailing
CRLF, not just LF.
* mailbox/cfg_parser.y (mu_cfg_parse): Zero out _mu_cfg_debug
to avoid destroying it doubly.
* mailbox/mbx_default.c (plus_expand): Remove unused variable.
2010-02-09 Sergey Poznyakoff <gray@gnu.org.ua>
Fix improperly placed variable declarations.
* imap4d/id.c
* libproto/imap/folder.c
* libproto/pop/mbox.c
* sieve/sieve.c
2010-02-09 Sergey Poznyakoff <gray@gnu.org.ua>
Minor fix.
* sieve/testsuite/sieve/ext.exp [!HAVE_LIBLTDL]: Use
unsupported instead of returning 0.
2010-02-09 Sergey Poznyakoff <gray@gnu.org.ua>
Fix compilation without sendmail.
* libproto/mailer/remote.c: Fix compilation with
--disable-sendmail.
* mail/testsuite/mail/send.exp: Ignore test (return
UNSUPPORTED), if sendmail support is not compiled.
* sieve/testsuite/sieve/redirect.exp: Likewise.
* sieve/testsuite/sieve/reject.exp: Likewise.
2010-01-27 Sergey Poznyakoff <gray@gnu.org.ua>
MH-related bugfixes.
* mailbox/mbx_default.c (plus_expand): Do not treat the part
between initial + and / as user name.
* mh/mh_format.c (print_fmt_segment): New function.
(print_fmt_string): Correctly handle multi-line inputs.
2010-01-14 Sergey Poznyakoff <gray@gnu.org.ua>
More fixes in libmu_scm.
* libmu_scm/mu_mailbox.c (mu-mailbox-get-port): Fix return
value.
* libmu_scm/mu_port.c (mu_port_flush): Avoid warnings on
passing arg 2 to mu_stream_write.
(mu_port_free): Return 0.
* libmu_scm/mu_message.c (mu_scm_message_free): Return 0.
2010-01-13 Sergey Poznyakoff <gray@gnu.org.ua>
Do not use deprecated Guile functions.
* libmu_scm/mu_address.c: Use scm_to_locale_string instead of
relying on scm_i_string_chars.
* libmu_scm/mu_logger.c: Likewise.
* libmu_scm/mu_mailbox.c: Likewise.
* libmu_scm/mu_scm.c: Likewise.
* libmu_scm/mu_util.c: Likewise.
* libmu_scm/mu_message.c: Likewise.
(mu_scm_message_add_owner): Don't use SCM_NEWCELL.
(mu-message-get-envelope)
(mu-message-get-envelope-date): New functions.
(string_sloppy_member): Compare scm_i_string_length bytes from
the car.
(mu-message-get-header-fields): Don't use SCM_NEWCELL.
* libmu_scm/mu_port.c (mu_port_make_from_stream): Don't use
SCM_NEWCELL.
2010-01-05 Sergey Poznyakoff <gray@gnu.org.ua>
Bugfixes.
* mailbox/stream.c (mu_stream_readline): Account for
terminating null (fixes buffer overrun).
(mu_stream_getline): Fix reallocation condition.
2010-01-05 Sergey Poznyakoff <gray@gnu.org.ua>
Remove incompatibly-copyrighted material.
* configure.ac: Remove doc/rfc/Makefile.am
* doc/Makefile.am (SUBDIRS): Remove rfc.
(EXTRA_DIST): Add rfc/README.
* doc/rfc/README: New file.
* doc/rfc/CMC_V1.PS.gz: Remove.
* doc/rfc/Makefile.am: Remove.
* doc/rfc/rfc1413.txt: Remove.
* doc/rfc/rfc1521.txt: Remove.
* doc/rfc/rfc1731.txt: Remove.
* doc/rfc/rfc1734.txt: Remove.
* doc/rfc/rfc1738.txt: Remove.
* doc/rfc/rfc1870.txt: Remove.
* doc/rfc/rfc1891.txt: Remove.
* doc/rfc/rfc1892.txt: Remove.
* doc/rfc/rfc1893.txt: Remove.
* doc/rfc/rfc1894.txt: Remove.
* doc/rfc/rfc1939.txt: Remove.
* doc/rfc/rfc1957.txt: Remove.
* doc/rfc/rfc2045.txt: Remove.
* doc/rfc/rfc2046.txt: Remove.
* doc/rfc/rfc2047.txt: Remove.
* doc/rfc/rfc2049.txt: Remove.
* doc/rfc/rfc2060-errata
* doc/rfc/rfc2060.txt: Remove.
* doc/rfc/rfc2087.txt: Remove.
* doc/rfc/rfc2088.txt: Remove.
* doc/rfc/rfc2111.txt: Remove.
* doc/rfc/rfc2177.txt: Remove.
* doc/rfc/rfc2180.txt: Remove.
* doc/rfc/rfc2192.txt: Remove.
* doc/rfc/rfc2193.txt: Remove.
* doc/rfc/rfc2195.txt: Remove.
* doc/rfc/rfc2221.txt: Remove.
* doc/rfc/rfc2222.txt: Remove.
* doc/rfc/rfc2231.txt: Remove.
* doc/rfc/rfc2245.txt: Remove.
* doc/rfc/rfc2298.txt: Remove.
* doc/rfc/rfc2342.txt: Remove.
* doc/rfc/rfc2368.txt: Remove.
* doc/rfc/rfc2384.txt: Remove.
* doc/rfc/rfc2444.txt: Remove.
* doc/rfc/rfc2449.txt: Remove.
* doc/rfc/rfc2595.txt: Remove.
* doc/rfc/rfc2683.txt: Remove.
* doc/rfc/rfc2808.txt: Remove.
* doc/rfc/rfc2821.txt: Remove.
* doc/rfc/rfc2822.txt: Remove.
* doc/rfc/rfc2831.txt: Remove.
* doc/rfc/rfc3028.txt: Remove.
* doc/rfc/rfc3206.txt: Remove.
* doc/rfc/rfc3348.txt: Remove.
* doc/rfc/rfc3431.txt: Remove.
* doc/rfc/rfc3501.txt: Remove.
* doc/rfc/rfc3691.txt: Remove.
* doc/rfc/rfc4314.txt: Remove.
* doc/rfc/rfc821.txt: Remove.
* doc/rfc/rfc822.txt: Remove.
* doc/rfc/rfc934.txt: Remove.
* doc/rfc/sasl-mechanisms: Remove.
2010-01-05 Sergey Poznyakoff <gray@gnu.org.ua>
Fix indentation in Sieve scripts.
* sieve/examples/ex-1.10.2.sv: Use GNU indentation style
* sieve/examples/ex-2.3a.sv: Likewise.
* sieve/examples/ex-2.5.1.sv: Likewise.
* sieve/examples/ex-2.7.3.sv: Likewise.
* sieve/examples/ex-3.1a.sv: Likewise.
* sieve/examples/ex-3.1b.sv: Likewise.
* sieve/examples/ex-3.2.sv: Likewise.
* sieve/examples/ex-4.1.sv: Likewise.
* sieve/examples/ex-4.2.sv: Likewise.
* sieve/examples/ex-4.4a.sv: Likewise.
* sieve/examples/ex-4.4b.sv: Likewise.
* sieve/examples/ex-4.5.sv: Likewise.
* sieve/examples/ex-5.1.sv: Likewise.
* sieve/examples/ex-5.7.sv: Likewise.
* sieve/examples/ex-9.sv: Likewise.
* sieve/examples/ex-save-all.sv: Likewise.
* sieve/examples/example.sv: Likewise.
* sieve/examples/exn-5.4.sv: Likewise.
* sieve/examples/t-complex.sv: Likewise.
* sieve/examples/t-exists.sv: Likewise.
* sieve/examples/t-fileinto.sv: Likewise.
* sieve/examples/t-mailutils.sv: Likewise.
2010-01-05 Sergey Poznyakoff <gray@gnu.org.ua>
Update copyright years.
Happy GNU year!
2010-01-02 Sergey Poznyakoff <gray@gnu.org.ua>
Bugfixes.
* libmu_cfg/init.c (mu_libcfg_parse_config): Do not produce
error if user configuration file is absent.
* libmu_sieve/sieve.l: Include config.h in %top section.
* mh/mh_alias.l: Likewise.
* mimeview/mimetypes.l: Likewise.
* mailbox/cfg_lexer.l: Likewise.
(mu_get_config): Call mu_cfg_tree_postprocess.
2009-12-29 Sergey Poznyakoff <gray@gnu.org.ua>
Version 2.1.90.
* configure.ac, NEWS: Set version number 2.1.90
* testsuite/lib/mailutils.exp: Quote arguments to the --set
option.
(mu_exec): escape backslashes and double-quotes in $sw.
* frm/testsuite/frm/test.exp: Quote arguments to the --set
option.
* mail/testsuite/lib/mail.exp: Likewise.
* mailbox/testsuite/lib/mailbox.exp: Likewise.
* messages/testsuite/messages/test.exp: Likewise.
* sieve/testsuite/sieve/action.exp: Likewise.
* readmsg/testsuite/readmsg/test.exp: Remove extra backslashes,
not needed due to the changes in mu_exec
2009-12-29 Sergey Poznyakoff <gray@gnu.org.ua>
Support for multibyte-encoding in MH.
* gnulib.modules (mbchar, mbiter, mbslen): New modules.
* mh/mh.h (mh_charset): New function.
* mh/mh_format.c (DFLWIDTH): New macro.
(mbsubstrlen, mbsnlen): New functions.
(compress_ws): Handle multibyte strings.
(put_string): Use number of characters, not octets, to update
ind.
(print_hdr_segment): Handle multibyte strings.
(print_simple_segment, print_fmt_string): Likewise.
(reset_fmt_defaults): Restore default WS compression.
(mh_format): Set LC_TYPE based on the settings of profile
variables Charset and LC_BASE (new variable).
* mh/mh_init.c (mh_charset): New function.
(mh_decode_2047): Use mh_charset.
2009-12-28 Sergey Poznyakoff <gray@gnu.org.ua>
Improve configuration parsing (step 1).
Remove obsolete options (these have been made hidden in v.
2.0). Handle "include" and "program" after parsing the sources,
not while reducing the tree, as was previously. Retain,
however, old functions for compatibility, making them
deprecated. Add "query" mode to mailutils-config.
* include/mailutils/cfg.h (mu_cfg_node_tag): Remove
(mu_cfg_statement): Rename to mu_cfg_node_statement.
(mu_cfg_tree): New member: tail.
(mu_cfg_perror): Change signature.
(mu_cfg_vperror, mu_cfg_parse_error): New protos.
(MU_CFG_PATH_DELIM, MU_CFG_PATH_DELIM_STR): New defines.
(MU_PARSE_CONFIG_PLAIN,MU_CFG_FMT_LOCUS): New constant.
(MU_CFG_DEPRECATED): New macro.
(mu_parse_config,mu_get_config): Deprecated.
(mu_cfg_format_parse_tree): Change signature.
(mu_cfg_format_node, mu_cfg_parse_file): New protos.
(mu_cfg_tree_free): Remove stale proto.
(mu_cfg_find_node, mu_cfg_create_subtree): New protos.
* include/mailutils/libcfg.h (mu_libcfg_parse_config): New
proto.
(mu_parse_config_files): Deprecated.
* include/mailutils/mutil.h (mu_make_file_name): New proto.
(mu_retrieve_fp, mu_register_retriever)
(mu_retrieve): Remove unused prototypes.
* include/mailutils/opool.h (mu_opool_union): New proto.
* libmu_argp/Makefile.am (libmu_argp_a_SOURCES): Remove sources
(see below):
* po/POTFILES.in: Likewise.
* libmu_argp/gsasl.c: Remove.
* libmu_argp/pam.c: Remove.
* libmu_argp/radius.c: Remove.
* libmu_argp/sql.c: Remove.
* libmu_argp/tls.c: Remove.
* libmu_argp/virtdomain.c: Remove.
* config/mailutils-config.c: New option --query (-q)
(main): Handle query mode.
* comsat/comsat.c: Define MU_CFG_COMPATIBILITY to suppress
deprecation warnings.
* bootstrap.conf (XGETTEXT_OPTIONS): Add mu_cfg error reporting
functions.
* mailbox/Makefile.am (libmailutils_la_SOURCES): Add
mkfilename.c
* mailbox/mkfilename.c: New file.
* imap4d/imap4d.c: Remove obsolete option (hidden since 2.0)
* libmu_argp/auth.c: Likewise.
* libmu_argp/cmdline.c: Likewise.
* libmu_argp/tls.c: Likewise.
* pop3d/pop3d.c: Likewise.
* libmu_argp/common.c: Likewise.
(mu_common_argp_options): New option --set.
* libmu_argp/muinit.c (mu_app_init): Rewrite using parse tree
as a principal entity.
* libmu_cfg/init.c (mu_libcfg_parse_config): New function.
* mailbox/cfg_driver.c (make_file_name): Remove.
(_cb_include): Use mu_make_file_name.
(mu_build_container): Use deprecated code only unless
MU_PARSE_CONFIG_PLAIN flag is set.
(mu_cfg_tree_reduce): Do nothing if the tree is NULL.
* mailbox/cfg_format.c (format_node): Print locus optionally.
(mu_cfg_format_parse_tree): Take additional argument.
(mu_cfg_format_node): New function.
* mailbox/cfg_lexer.l: Update calls to diagnostic functions.
(mu_cfg_parse_file): New function.
(mu_get_config): Rewrite.
* mailbox/cfg_parser.y (parse_tree): Replace with parse_head,
parse_tail. All usages updated.
(mu_cfg_free_node): New function.
(mu_cfg_vperror): New function.
(mu_cfg_perror,mu_cfg_parse_error): New function.
(mu_cfg_tree_union): New function.
(mu_cfg_tree_postprocess): New function.
(mu_cfg_find_section): Use MU_CFG_PATH_DELIM instead of
hardcoded slash.
(mu_cfg_value_eq): New function.
(mu_cfg_find_node): New function. Redesign of an old idea.
(mu_cfg_create_subtree): New function.
* mailbox/opool.c (mu_opool_union): New function.
* frm/testsuite/frm/test.exp: use --set option instead of the
obsolete --mail-folder.
* messages/testsuite/messages/test.exp: Likewise.
* sieve/testsuite/sieve/action.exp: Likewise.
* mail/testsuite/lib/mail.exp: use --set option instead of the
obsolete --mail-spool.
* mailbox/testsuite/lib/mailbox.exp: Likewise.
* testsuite/lib/mailutils.exp: Likewise.
* mailbox/mutil.c (mu_register_retriever)
(mu_retrieve): Remove unused functions.
Minor fix:
* frm/common.c (frm_abort): Initialize URL before usage.
(frm_scan): Don't call frm_abort on a mailbox that was not
opened successfully.
2009-12-26 Sergey Poznyakoff <gray@gnu.org.ua>
Disable whitespace compression in MH formatting code.
Whitespace compression in its current form interacts badly with
wide-character encodings. To prevent it from spoiling wide
character text, it is disabled by default. The user may turn it
back on by setting "Compress-WS: yes" in his .mh_profile.
* mh/mh.h (MH_FMT_COMPWS): New format flag.
* mh/mh_format.c (COMPRESS_WS): New macro.
(reset_fmt_defaults): Set MH_FMT_COMPWS flag if Compress-WS
global parameter is set to true.
(mh_format, builtin_concat): Call COMPRESS_WS.
2009-12-16 Sergey Poznyakoff <gray@gnu.org.ua>
Fix format specifiers and usage of const char*
arguments/variables.
Affected files:
* comsat/comsat.c
* examples/header.c
* examples/mailcap.c
* examples/pop3client.c
* examples/url-parse.c
* imap4d/fetch.c
* imap4d/id.c
* imap4d/list.c
* imap4d/select.c
* imap4d/status.c
* imap4d/store.c
* imap4d/sync.c
* imap4d/util.c
* include/mailutils/sieve.h
* libmu_argp/common.c
* libmu_argp/muinit.c
* libmu_sieve/actions.c
* libmu_sieve/extensions/pipe.c
* libmu_sieve/extensions/vacation.c
* libmu_sieve/prog.c
* libmu_sieve/require.c
* libmu_sieve/runtime.c
* libmu_sieve/sieve-priv.h
* libmu_sieve/sieve.y
* libproto/imap/folder.c
* libproto/imap/mbox.c
* libproto/mailer/sendmail.c
* libproto/mbox/mbox.c
* libproto/pop/pop3_list.c
* libproto/pop/pop3_stat.c
* maidag/lmtp.c
* maidag/sieve.c
* mail/copy.c
* mail/decode.c
* mail/envelope.c
* mail/eq.c
* mail/escape.c
* mail/from.c
* mail/mail.h
* mail/mailline.c
* mail/mailvar.c
* mail/size.c
* mail/util.c
* mail/write.c
* mailbox/cfg_format.c
* mailbox/folder.c
* mailbox/parse822.c
* mailbox/system.c
* messages/messages.c
* mh/folder.c
* mh/forw.c
* mh/inc.c
* mh/mh.h
* mh/mh_alias.l
* mh/mh_fmtgram.y
* mh/mh_getopt.h
* mh/mh_init.c
* mh/mh_msgset.c
* mh/mh_whatnow.c
* mh/mhn.c
* mh/pick.y
* mimeview/mimetypes.y
* python/libmu_py/debug.c
* sieve/sieve.c
2009-12-16 Sergey Poznyakoff <gray@gnu.org.ua>
Add TLS to MH. Handle --debug-level and --debug-line-info
options.
* mailbox/mbx_default.c (attach_auth_ticket): Do not proceed if
auth is NULL.
* mh/mh_getopt.h (struct mh_argp_data): Change return type and
signature of handler.
(mh_argp_parse): Likewise.
* mh/mh_argp.c (parse_opt): Rewrite using new handler
prototype.
(mh_argp_parse): Use new handler type. Assign argp children.
* mh/mh_init.c (mh_init): Call mu_init_tls_libs.
* mh/ali.c: Update opt_handler
* mh/anno.c: Update opt_handler
* mh/burst.c: Update opt_handler
* mh/comp.c: Update opt_handler
* mh/fmtcheck.c: Update opt_handler
* mh/folder.c: Update opt_handler
* mh/forw.c: Update opt_handler
* mh/inc.c: Update opt_handler
* mh/install-mh.c: Update opt_handler
* mh/mark.c: Update opt_handler
* mh/mhl.c: Update opt_handler
* mh/mhn.c: Update opt_handler
* mh/mhparam.c: Update opt_handler
* mh/mhpath.c: Update opt_handler
* mh/pick.c: Update opt_handler
* mh/refile.c: Update opt_handler
* mh/repl.c: Update opt_handler
* mh/rmf.c: Update opt_handler
* mh/rmm.c: Update opt_handler
* mh/scan.c: Update opt_handler
* mh/send.c: Update opt_handler
* mh/sortm.c: Update opt_handler
* mh/whatnow.c: Update opt_handler
* mh/whom.c: Update opt_handler
2009-12-02 Sergey Poznyakoff <gray@gnu.org.ua>
Bugfix.
* libproto/mailer/smtp.c (smtp_open): Don't issue second EHLO
if STARTTLS failed.
2009-12-01 Sergey Poznyakoff <gray@gnu.org.ua>
Fix reusability of smtp mailers.
* libproto/mailer/smtp.c (_smtp_set_rcpt): Initialize smtp->ptr
to smtp->buffer, not NULL.
(smtp_close): Reset smtp->state.
2009-11-05 Sergey Poznyakoff <gray@gnu.org.ua>
Bugfix.
* mail/mail.c (parse_opt): Fix handling of the --user option.
2009-10-31 Jordi Mallach <jordi@gnu.org>
Spelling fixes.
2009-10-31 Sergey Poznyakoff <gray@gnu.org.ua>
Bugfixes.
* libmu_scm/mu_guile.c: Include setjmp.h.
* readmsg/readmsg.c (readmsg_parse_opt): Bugfixes. Patch by
Steve Cotton.
2009-10-25 Sergey Poznyakoff <gray@gnu.org.ua>
Revamp common mu_gsasl_module_data as extern.
* include/mailutils/gsasl.h (mu_gsasl_module_data): Mark as
extern.
2009-10-25 Sergey Poznyakoff <gray@gnu.org.ua>
Various fixes (mostly to placate gcc)
* examples/base64.c, examples/mta.c, imap4d/auth_gss.c,
imap4d/imap4d.c, imap4d/preauth.c, libmu_auth/ldap.c,
libmu_auth/virtual.c, libmu_scm/mu_body.c, libmu_scm/mu_port.c,
libproto/mailer/smtp.c, mailbox/acl.c, mailbox/secret.c,
pop3d/pop3d.c, python/libmu_py/address.c, sql/odbc.c: Fix
argument signedness.
* imap4d/fetch.c, imap4d/store.c (closures): Change type of
`count' to int, to match the signature of util_msgset.
* include/mailutils/guile.h (mu_scm_message_get): Fix return
type (const is useless here).
* libmu_scm/mu_message.c (mu_scm_message_get): Likewise.
(scm_mu_message_copy): Fix type of the `wr' automatic variable.
* libmu_scm/mu_mime.c (mu_scm_mime_get): Remove const qualifier
from the return type.
* libmu_argp/cmdline.c: Include stdlib.h.
2009-10-25 Sergey Poznyakoff <gray@gnu.org.ua>
Bugfixes.
* mailbox/assoc.c (assoc_remove): Fix incorrect copying between
assoc slots.
* mailbox/cfg_parser.y (STRTONUM): Remove useless
dereferencing. Change the loop from `while' to `for'.
2009-09-28 Sergey Poznyakoff <gray@gnu.org.ua>
Fix program descriptions (docstings).
* config/mailutils-config.c: Terminate docstring with a period.
* dotlock/dotlock.c: Likewise.
* frm/frm.c: Likewise.
* frm/from.c: Likewise.
* imap4d/imap4d.c: Likewise.
* maidag/maidag.c: Likewise.
* pop3d/pop3d.c: Likewise.
* readmsg/readmsg.c: Likewise.
* sieve/sieve.c: Likewise.
2009-09-28 Jordi Mallach <jordi@gnu.org>
Harmonise --help output.
* comsat/comsat.c: Add docstring.
* movemail/movemail.c: Add docstring.
2009-09-24 Sergey Poznyakoff <gray@gnu.org.ua>
Minor fixes.
* include/mailutils/cfg.h (mu_cfg_perror): Mark as printflike.
(mu_cfg_format_error): Likewise.
* libmu_argp/radius.c (mu_radius_argp_option): Fix typo in the
docstring.
* mail/mail.h [!WITH_READLINE] (mailvar_set_compl): New define.
2009-09-24 Simon Josefsson <simon@josefsson.org>
SASL related fixes.
* imap4d/auth_gsasl.c (auth_gsasl): Make IMAP server wait for
empty final client response.
* include/mailutils/gsasl.h (mu_gsasl_stream_create): Don't use
deprecated GNU SASL types.
2009-09-24 Sergey Poznyakoff <gray@gnu.org.ua>
Implement global transcript settings in imap4d and pop3d.
* imap4d/imap4d.c (imap4d_cfg_param): New global statement
'transcript'.
(imap4d_connection): The transcript parameter overrides global
imap4d_transcript settings.
* pop3d/pop3d.c (pop3d_cfg_param, pop3d_connection): Likewise.
2009-09-24 Sergey Poznyakoff <gray@gnu.org.ua>
Bugfixes.
* imap4d/util.c (imap4d_getline): Do not report ERR_NO_IFILE if
an empty line is read.
* mailbox/msrv.c (server_section_parser): Catch null tags.
Bugs reported by Simon Josefsson.
2009-09-24 Sergey Poznyakoff <gray@gnu.org.ua>
Bugfix.
* libproto/mbox/mboxscan.c (mbox_scan_internal): Fix body size
calculation: -1 was returned for empty body. Bug reported by
Con Tassios <ct@swin.edu.au>.
* po/POTFILES.in: Add mail/mailvar.c
2009-09-10 Sergey Poznyakoff <gray@gnu.org.ua>
Version 2.1 "Ten Years Later"
* NEWS: Update for version 2.1
* configure.ac: Update for version 2.1
(AM_INIT_AUTOMAKE): Add dist-lzma and dist-xz.
* bootstrap (slurp): Remove call to silentize: not needed with
recent gnulib.
2009-09-08 Wojciech Polak <polak@gnu.org>
Correct some pydocs.
2009-09-02 Wojciech Polak <polak@gnu.org>
Python: Allow to set mu_pam_service.
* python/libmu_py/auth.c (api_set_pam_service): New function.
* python/mailutils/auth.py (set_pam_service): New function.
2009-09-01 Wojciech Polak <polak@gnu.org>
Update NEWS.
2009-09-01 Sergey Poznyakoff <gray@gnu.org.ua>
Bugfixes.
* mailbox/assoc.c (mu_assoc_count): Initialize count.
* NEWS: Update.
2009-08-29 Wojciech Polak <polak@gnu.org>
Update pydocs.
* python/mailutils/__init__.py: Update pydocs.
* python/mailutils/mailbox.py: Likewise.
* python/mailutils/mailcap.py: Likewise.
* python/mailutils/registrar.py: Likewise.
* python/mailutils/sieve.py: Likewise.
2009-08-29 Sergey Poznyakoff <gray@gnu.org.ua>
Minor fixes.
* libproto/mailer/smtp.c: fix indentation
2009-08-28 Sergey Poznyakoff <gray@gnu.org.ua>
Minor fix.
* libmu_scm/Makefile.am (install-data-hook): Make sure
libguile-mailutils links to the versioned .so file.
2009-08-27 Wojciech Polak <polak@gnu.org>
Fix RPM spec.
* mu-aux/mailutils.spec.in: Fix.
2009-08-27 Sergey Poznyakoff <gray@gnu.org.ua>
Improve configure script.
* configure.ac: New option --with-pythondir
(PYTHON_SITE_DIR, PYTHON_EXEC_DIR): New subst variables.
* python/libmu_py/Makefile.am: use pythonexec_LTLIBRARIES,
instead of pythonexec_LTLIBRARIES.
(pythonexecdir): New variable.
* python/mailutils/Makefile.am: use pythonsite_PYTHON, instead
of pkgpython_PYTHON.
(pythonsitedir): New variable.
2009-08-27 Sergey Poznyakoff <gray@gnu.org.ua>
Fix leftover diagnostic messages.
* movemail/movemail.c (_cb_mailbox_ownership): Fix leftover
diagnostic messages.
* config/mailutils-config.c (options): Fix typo.
2009-08-27 Wojciech Polak <polak@gnu.org>
Update docs.
* doc/texinfo/programs.texi: Update maidag scripting info.
2009-08-25 Sergey Poznyakoff <gray@gnu.org.ua>
Minor improvements in comsat and frm.
* comsat/action.c (action_exec): Remove `line' argument. Do not
explicitly add locus to the messages.
(run_user_action): Add locus to diagnostics mu_debug_t, so it
is prepended to all diagnostic messages automatically.
* comsat/comsat.c: Improve help output
* frm/frm.c (attr_help): Remove unnecessary variable.
2009-08-25 Sergey Poznyakoff <gray@gnu.org.ua>
Fix help messages.
Option descriptions in `--help' output do not constitute
conceptual sentences. Therefore, they should not begin with a
capital letter, nor end with a final point.
Affected files:
comsat/comsat.c, config/mailutils-config.c, dotlock/dotlock.c,
frm/frm.c, frm/from.c, guimb/main.c, imap4d/imap4d.c,
libmu_argp/auth.c, libmu_argp/common.c, libmu_argp/gsasl.c,
libmu_argp/pam.c, libmu_argp/radius.c, libmu_argp/sieve.c,
libmu_argp/sql.c, libmu_argp/tls.c, libmu_argp/virtdomain.c,
libmu_auth/sql.c, libmu_cfg/sql.c, maidag/maidag.c,
maidag/mailquota.c, maidag/mailtmp.c, mail/mail.c,
messages/messages.c, mh/ali.c, mh/anno.c, mh/burst.c,
mh/comp.c, mh/fmtcheck.c, mh/folder.c, mh/forw.c, mh/inc.c,
mh/install-mh.c, mh/mark.c, mh/mh_init.c, mh/mhl.c, mh/mhn.c,
mh/mhparam.c, mh/mhpath.c, mh/pick.c, mh/refile.c, mh/repl.c,
mh/rmf.c, mh/rmm.c, mh/scan.c, mh/send.c, mh/sortm.c,
mh/whatnow.c, mh/whom.c, mimeview/mimeview.c,
movemail/movemail.c, pop3d/pop3d.c, pop3d/popauth.c,
readmsg/readmsg.c, sieve/sieve.c
2009-08-25 Sergey Poznyakoff <gray@gnu.org.ua>
Change error messages to comply with the GNU standards.
The string MESSAGE should not begin with a capital letter when
it
follows a program name and/or file name, because that isn't
the
beginning of a sentence. (The sentence conceptually starts at
the
beginning of the line.) Also, it should not end with a period.
* include/mailutils/diag.h (mu_diag_funcall): New prototype.
* mailbox/diag.c: New function.
* comsat/action.c, comsat/comsat.c, comsat/oldcfg.c,
config/mailutils-config.c, configure.ac, dotlock/dotlock.c,
frm/common.c, frm/from.c, guimb/collect.c, guimb/main.c,
guimb/util.c, imap4d/auth_gsasl.c, imap4d/auth_gss.c,
imap4d/bye.c, imap4d/close.c, imap4d/imap4d.c, imap4d/login.c,
imap4d/preauth.c, imap4d/signal.c, imap4d/starttls.c,
imap4d/util.c, lib/mailcap.c, lib/tcpwrap.c,
libmu_argp/mu_argp.c, libmu_auth/ldap.c, libmu_auth/radius.c,
libmu_auth/sql.c, libmu_auth/tls.c, libmu_cfg/acl.c,
libmu_cfg/common.c, libmu_cfg/init.c, libmu_cfg/ldap.c,
libmu_cfg/sql.c, libmu_sieve/actions.c,
libmu_sieve/comparator.c, libmu_sieve/extensions/moderator.c,
libmu_sieve/prog.c, libmu_sieve/sieve.l,
libproto/imap/folder.c, libproto/mbox/mbox.c, maidag/deliver.c,
maidag/lmtp.c, maidag/maidag.c, maidag/mailquota.c,
maidag/mailtmp.c, maidag/script.c, mail/alias.c, mail/cd.c,
mailbox/cfg_lexer.l, mailbox/cfg_parser.y,
mailbox/file_stream.c, mailbox/gocs.c, mailbox/msrv.c,
mailbox/mutil.c, mailbox/registrar.c, messages/messages.c,
mh/folder.c, mh/forw.c, mh/inc.c, mh/mark.c, mh/mh_ctx.c,
mh/mh_fmtgram.y, mh/mh_format.c, mh/mh_init.c, mh/mh_list.c,
mh/mh_msgset.c, mh/mh_whatnow.c, mh/mh_whom.c, mh/mhl.c,
mh/mhn.c, mh/pick.c, mh/refile.c, mh/repl.c, mh/rmf.c,
mh/scan.c, mh/send.c, mimeview/mimetypes.l,
mimeview/mimeview.c, movemail/movemail.c, pop3d/apop.c,
pop3d/bulletin.c, pop3d/extra.c, pop3d/lock.c,
pop3d/logindelay.c, pop3d/pop3d.c, pop3d/popauth.c,
pop3d/quit.c, pop3d/signal.c, pop3d/user.c, readmsg/readmsg.c,
sieve/sieve.c: Fix error messages.
2009-08-21 Wojciech Polak <polak@gnu.org>
Python: Bugfixes.
* python/libmu_py/mailbox.c (api_mailbox_append_message):
Bugfix.
* python/libmu_py/header.c (api_header_get_value_n): New
function.
* python/mailutils/header.py (Header.get_value_n): New method.
* python/mailutils/mailbox.py (Mailbox.__str__): New method.
* python/mailutils/message.py (Message.__str__): Likewise.
2009-08-21 Sergey Poznyakoff <gray@gnu.org.ua>
Minor fixes.
* .gitignore: Add pathdefs.h
* examples/Makefile.am (muauth_CPPFLAGS)
(muemail_CPPFLAGS): New variables.
* examples/argcv.c (main): Remove unused local.
* include/mailutils/gsasl.h [USE_GSASL]: Change to WITH_GSASL.
* include/mailutils/libcfg.h (mu_acl_cfg_init): New prototype.
* include/mailutils/mu_auth.h (mu_authenticate): Password is
const.
* include/mailutils/python.h: Fix indentation.
(mu_py_script_data): module_name is const char *.
* libmu_auth/radius.c: Include radius/debug.h
* libproto/mailer/smtp.c: Include io.h and secret.h
* mail/mail.c: Fix indentation.
* mail/util.c (util_rfc2047_decode): Fix local variable
declaration.
* mailbox/mu_auth.c (mu_authenticate): Password is const.
* mh/mh.h (mh_alias_get, mh_alias_get_address)
(mh_alias_get_alias): Name is const.
* mh/mh_alias.y: Likewise.
* mh/mh_list.c (print_header_value): Fix improper use of
mu_toupper.
* mh/mh_whatnow.c (invoke): Add typecasts.
* python/libmu_py/nls.c (api_nls_set_locale): Remove unused
automatic.
* python/libmu_py/sieve.c (_sieve_error_printer): Provide
missing return value.
(_sieve_debug_printer): Likewise.
2009-08-20 Sergey Poznyakoff <gray@gnu.org.ua>
Movemail: allow to copy mailbox ownership when run as root.
* movemail/movemail.c: Implement new configuration keyword
"mailbox-ownership" (and the --owner command line option).
* doc/texinfo/programs.texi: Document new movemail features.
(Ownership): New subsection stub.
* NEWS: Update
2009-08-20 Sergey Poznyakoff <gray@gnu.org.ua>
Fix in configure.ac.
* configure.ac: Use PATH_MAILDIR (without leading underscore).
2009-08-15 Sergey Poznyakoff <gray@gnu.org.ua>
Mail: bugfixes.
* mail/file.c: Use "headers" instead of non-standard "z."
* mail/mail.c: Avoid % interpretation in the argument to
util_cache_command.
* mail/util.c (_run_and_free): Avoid % interpretation in the
argument to util_do_command.
2009-08-14 Sergey Poznyakoff <gray@gnu.org.ua>
Mail: configurable `headers' output format.
* mail/from.c: Rewrite using format string.
* mail/mail.c (default_setup): Set default value for
`headline'.
(main): Fix call to util_do_command.
* mail/mail.h [HAVE_STDARG_H]: Remove conditions.
(mail_compile_headline): New proto.
* mail/mailvar.c (mailvar_tab): New variable "headline".
* mail/util.c: Minor fixes.
* NEWS, doc/programs.texi: Update.
2009-08-13 Sergey Poznyakoff <gray@gnu.org.ua>
Minor fixes.
* comsat/comsat.h: Include confpaths.h, not paths.h.
* lib/utmp.c: Likewise.
* libmu_scm/mu_scm.h: Likewise.
* libproto/mailer/sendmail.c: Likewise.
* mail/mail.h: Likewise.
* mailbox/mbx_default.c: Likewise.
* mailbox/version.c: Likewise.
* lib/daemon.c: Likewise.
* include/mailutils/mailer.h (struct timeval): forward decl.
2009-08-13 Sergey Poznyakoff <gray@gnu.org.ua>
Improve memory allocation in pop3d.
* pop3d/pop3d.c (pop3d_alloc_die): New function.
(main): Set mu_alloc_die_hook.
(pop3d_mainloop): Use mu_alloc.
* pop3d/pop3d.h: Include mailutils/alloc.h
2009-08-13 Sergey Poznyakoff <gray@gnu.org.ua>
Further improvements of the configure system.
* Makefile.am (MU_COND_LIBMU_CPP): New cond.
(SUBDIRS): Use LIBMU_CPP_DIR
* configure.ac: Rename --disable-c++ to --disable-cxx: autoconf
cannot handle the former.
(MU_COND_LIBMU_CPP): New cond.
(AC_CONFIG_FILES): Add include/mailutils/cpp/Makefile
* include/mailutils/Makefile.am (nobase_pkginclude_HEADERS):
Remove
(MU_COND_LIBMU_CPP): New cond.
(SUBDIRS): Add CPP_DIR
* include/mailutils/cpp/Makefile.am: Remove substitution vars.
(cppincludedir, cppinclude_HEADERS): New variables.
* include/mailutils/sys/Makefile.am (sysincludedir)
(sysinclude_HEADERS): New variables.
2009-08-13 Sergey Poznyakoff <gray@gnu.org.ua>
Fix building with fribidi2.
* configure.ac: Check for wcwidth and wchar.h.
* frm/common.c (get_charset): Aways allocate output_charset.
Provide a substitution for fribidi_wcwidth if it is not
available.
(puts_bidi): Use mu_fribidi_wcwidth.
2009-08-13 Sergey Poznyakoff <gray@gnu.org.ua>
Fixes in configure.ac.
* am/enable.m4 (MU_ENABLE_SUPPORT): Change semantics of the
last argument.
(MU_ENABLE_BUILD): 4th argument gives additional conditions for
AM_CONDITIONAL.
* configure.ac: Enable building c++ interface when possible.
Fix checks for guimb and mh utilities.
* libmu_cpp/Makefile.am: Remove unnecessary substitution
variables.
2009-08-12 Wojciech Polak <polak@gnu.org>
Restore old CVS ChangeLog.
2009-08-12 Sergey Poznyakoff <gray@gnu.org.ua>
Rewrite conditional compilation support.
* Makefile.am: Conditionally add directories to SUBDIRS.
* am/enable.m4 (MU_ENABLE_BUILD): New macro.
* configure.ac: Require automake 1.11 Add MU_ENABLE_BUILDs for
each utility. Remove unused substitution variables.
* guimb/Makefile.am: Remove substitution variables.
* guimb/scm/Makefile.am: Likewise.
* libmu_scm/Makefile.am: Likewise.
* mh/Makefile.am: Likewise.
* python/libmu_py/Makefile.am: Likewise.
* python/mailutils/Makefile.am: Likewise.
* README: Document --disable-build-* options.
2009-08-11 Sergey Poznyakoff <gray@gnu.org.ua>
Minor fix.
* mailbox/mu_auth.c (mu_auth_runlist): Do not overwrite last
meaningful error code by ENOSYS.
2009-08-11 Sergey Poznyakoff <gray@gnu.org.ua>
Improve command line and error handling in pop3d.
* pop3d/pop3d.h: Remove unused includes.
(ABORT): New state.
(pop3d_command_handler_t, struct pop3d_command): New types.
(pop3d_find_command): New function.
(pop3d_stat,pop3d_top,pop3d_uidl,pop3d_user,pop3d_apop)
(pop3d_auth,pop3d_capa,pop3d_dele,pop3d_list,pop3d_noop)
(pop3d_quit,pop3d_retr,pop3d_rset): Remove const from the
arguments. Functions are free to modify it.
(pop3d_parse_command): New function.
* pop3d/cmd.c: New file.
* pop3d/Makefile.am: Link in cmd.o
* pop3d/apop.c: Use pop3d_parse_command to parse commands
* pop3d/auth.c: Likewise.
* pop3d/extra.c (pop3d_args, pop3d_cmd): Remove.
(pop3d_parse_command): New function.
(pop3d_abquit): use pop3d_error_string to convert error numbers
to messages.
* pop3d/pop3d.c (cb_bulletin_db): Protect by #ifdef USE_DBM
(pop3d_mainloop): Change loop condition. Use
pop3d_parse_command to parse commands, pop3d_find_command to
lookup handlers in the command table and pop3d_error_string to
convert error numbers to messages.
(main): Call enable_stls if necessary.
* pop3d/capa.c, pop3d/dele.c, pop3d/list.c, pop3d/noop.c,
pop3d/quit.c, pop3d/retr.c, pop3d/rset.c, pop3d/stat.c,
pop3d/stls.c, pop3d/top.c, pop3d/uidl.c, pop3d/user.c: Remove
const qualifier from the command handler argument.
2009-08-10 Sergey Poznyakoff <gray@gnu.org.ua>
Minor fixes.
* examples/argcv.c (main): Use fgets instead of getline.
* mail/decode.c (mime_descend): Use util_get_hdr_value which
does not cut off the additional arguments after the ';'.
2009-08-09 Wojciech Polak <polak@gnu.org>
Improve C++ and Python APIs.
* include/mailutils/cpp/header.h (Header.has_key): New method.
* libmu_cpp/header.cc: Likewise.
* include/mailutils/cpp/mailbox.h (MailboxDefault): Make name
optional.
* libmu_cpp/mailbox.cc: Likewise.
* python/mailutils/header.py (__contains__, has_key): New
method.
2009-08-09 Wojciech Polak <polak@gnu.org>
Update descriptions.
* README: Update.
* doc/texinfo/mailutils.texi: Update.
* mu-aux/mailutils.spec.in: Update.
* direntry: Not used anymore. Remove.
2009-08-08 Wojciech Polak <polak@gnu.org>
* mailbox/version.c: Add missing TC DBM info.
2009-08-08 Wojciech Polak <polak@gnu.org>
Bugfix.
* python/libmu_py/mailbox.c (api_mailbox_create_default): Make
name optional.
* python/mailutils/mailbox.py (MailboxDefault.__init__):
Likewise.
2009-08-08 Wojciech Polak <polak@gnu.org>
Add ESMTP AUTH support.
* libproto/mailer/smtp.c (smtp_auth, cram_md5): New function.
2009-08-08 Wojciech Polak <polak@gnu.org>
Move base64 routines to libmailutils.
* mailbox/base64.c: New file.
* imap4d/auth_gss.c: Use mu_base64_encode() and
mu_base64_decode().
* imap4d/util.c (util_base64_encode, util_base64_decode):
Remove.
2009-08-08 Wojciech Polak <polak@gnu.org>
Add Tokyo Cabinet DBM support.
* configure.ac: Add new option --with-tokyocabinet.
* lib/mu_dbm.c: Add Tokyo Cabinet support.
* lib/mu_dbm.h: Likewise.
* pop3d/popauth.c: Likewise.
2009-08-05 Wojciech Polak <polak@gnu.org>
* configure.ac: Fix typo.
2009-08-04 Wojciech Polak <polak@gnu.org>
Fix readmsg's printing the last message in the mailbox ($).
* readmsg/msglist.c (msglist): Bugfix.
2009-08-04 Wojciech Polak <polak@gnu.org>
Fix movemail --uidl.
* mailbox/message.c (mu_message_get_uidl): Do not remove angle
brackets from X-UIDL header.
2009-08-04 Sergey Poznyakoff <gray@gnu.org.ua>
Minor changes.
* NEWS: Reword some passages.
* mail/mail.c: Fix indentation.
* mailbox/folder.c (mu_folder_create): Return meaningful error
code.
2009-08-01 Wojciech Polak <polak@gnu.org>
Enable GNU TLS by default.
* am/tls.m4: Use --without-gnutls instead of --with-gnutls.
2009-07-31 Wojciech Polak <polak@gnu.org>
* Makefile.am: Bugfix. Build libmu_sieve before libmu_py.
2009-07-29 Wojciech Polak <polak@gnu.org>
Add SieveMachine to C++/Python.
* include/mailutils/cpp/sieve.h: New file.
* libmu_cpp/sieve.cc: New file.
* python/libmu_py/sieve.c: New file.
* python/mailutils/sieve.py: New file.
* include/mailutils/cstr.h: Do not use C++ keywords.
* include/mailutils/tls.h: Likewise.
2009-07-14 Wojciech Polak <polak@gnu.org>
Add NLS to libmu_py.
* python/libmu_py/nls.c: New file.
* python/mailutils/nls.py: Likewise.
2009-07-13 Wojciech Polak <polak@gnu.org>
Add more is/set/unset attribute methods (Python).
* python/libmu_py/attribute.c: Add userflag functions.
* python/mailutils/attribute.py: Add more is/set/unset methods.
* python/mailutils/mailbox.py (open): Bugfix.
2009-07-13 Sergey Poznyakoff <gray@gnu.org.ua>
Fixes in client pop3.
* libproto/pop/mbox.c (pop_get_message): Make sure the mailbox
is scanned.
(pop_top): Handle -ERR case.
2009-07-13 Sergey Poznyakoff <gray@gnu.org.ua>
mail: implement struct command.
* NEWS, doc/texinfo/programs.texi: Document struct command.
* mail/struct.c: New file.
* mail/Makefile.am (mail_SOURCES): Add struct.c
* mail/decode.c (fprint_msgset, mime_descend): New functions.
Rewrite the rest using mime_descend.
* mail/mail.h (mail_struct): New function.
(MDHINT_SELECTED_HEADERS): New define.
(struct mime_descend_closure, mime_descend_fn): New types.
(mime_descend): New proto.
(util_get_content_type): Get two arguments.
* mail/table.c (mail_command_table): Add st[ruct].
* mail/util.c (util_get_content_type): Get two arguments. All
callers updated.
(util_get_hdr_value): use mu_header_aget_value_unfold and
mu_rtrim_class.
2009-07-12 Paul Vojta <vojta@math.berkeley.edu>
Fix the way mail accounts for the status of messages.
* mail/mail.h (MAIL_ATTRIBUTE_PRESERVED)
(MAIL_ATTRIBUTE_TOUCHED): New define.
* mail/from.c (mail_from0): Mark with 'R' only those messages
that have been read in this mail session.
* mail/hold.c (hold0): Set MAIL_ATTRIBUTE_PRESERVED
* mail/mbox.c (mbox0): Don't mark message as read.
* mail/quit.c (mail_mbox_commit): Force keepsave on not system
mailboxes.
* mail/touch.c: Use MAIL_ATTRIBUTE_TOUCHED
* mail/undelete.c: Clear MAIL_ATTRIBUTE_PRESERVED and
MAIL_ATTRIBUTE_MBOXED bits.
* mail/testsuite/mail/write.exp: Account for the above changes.
2009-07-12 Sergey Poznyakoff <gray@gnu.org.ua>
Implement `mail -F'.
* NEWS, doc/texinfo/programs.texi: Update.
* mail/mail.c (parse_opt): Remove the fixme.
* mail/mailvar.c (mailvar_tab): Add `byname'.
* mail/reply.c (reply0): Use `byname' when deciding where to
save the message.
* mail/util.c: Fix comment.
2009-07-12 Sergey Poznyakoff <gray@gnu.org.ua>
Further improvements in `mail'.
* NEWS: Update.
* mail/mail.h (MOPTF_UNSET): New constant.
* mail/mailvar.c (MAILVAR_TYPEMASK): New define.
(struct mailvar_symbol): Remove `type'. Add `handler'. The
latter supplies special handling for certain variables.
(mailvar_tab): Update accordingly. Implement "debug" variable.
(mailvar_set): Enforce correct variable type in variable-strict
mode. Handle MOPTF_UNSET flag. Remove kludgy special handling
for some attributes, use sym->handler instead.
(set_decode_fallback, set_replyregex)
(set_screen, set_mailbox_debug_level, set_debug): New
functions.
(describe_symbol): Handle alternative symbol types.
* mail/set.c: Use MOPTF_UNSET when unsetting the variable.
* mail/source.c: Set correct locus. This allows to display
locations along with error messages.
2009-07-12 Sergey Poznyakoff <gray@gnu.org.ua>
Improve mail compliance to POSIX standard.
* mail/mail.c: Redo -f option handling to fully comply to POSIX
Set default diagnostics printer for interactive mode.
* NEWS, doc/texinfo/programs.texi: Document the use of -f
option.
2009-07-11 Sergey Poznyakoff <gray@gnu.org.ua>
Improve internal variable handling in mail. Implement envelope
and variable commands.
* NEWS: Update.
* doc/texinfo/programs.texi: Document new variables and
commands.
* mail/envelope.c: New file.
* mail/mailvar.c: New file.
* mail/Makefile.am (mail_SOURCES): Add envelope.c and
mailvar.c.
* mail/mail.h (EF_HIDDEN): New constant (mail_env_data_t,
mail_env_entry, mail_env_entry_is_set) (mail_env_entry,
util_getenv, util_printenv, util_setenv) (var_iterator_t,
var_iterate_next, var_iterate_first)
(var_iterate_end, var_compl): Removed.
(union mailvar_value, struct mailvar_variable (mail_variable,
mail_envelope, print_envelope) (mailvar_find_variable,
mailvar_get, mailvar_print)
(mailvar_variable_format, mailvar_set, mailvar_set_compl): Add
prototypes. (MOPTF_OVERWRITE, MOPTF_QUIET)
* mail/table.c: List new commands: envelope, setq, variable.
Implement completion for `set'.
* mail/testsuite/mail/if.exp: Use setq to set a read-only
variable.
mail/alias.c, mail/decode.c, mail/delete.c, mail/escape.c
mail/file.c, mail/folders.c, mail/from.c, mail/if.c,
mail/mail.c, mail/mailline.c, mail/msgset.y, mail/pipe.c,
mail/print.c, mail/quit.c, mail/reply.c, mail/send.c,
mail/set.c, mail/shell.c, mail/top.c, mail/unset.c,
mail/util.c: Use mailvar functions.
2009-07-11 Wojciech Polak <polak@gnu.org>
Add mailbox.get_uidls() to Python/C++.
* libmu_cpp/mailbox.cc (get_uidls): New method.
* python/libmu_py/mailbox.c (api_mailbox_get_uidls): New
function.
* python/mailutils/mailbox.py (get_uidls): New method.
2009-07-09 Sergey Poznyakoff <gray@gnu.org.ua>
Minor fixes.
* libmu_auth/ldap.c: Include mailutils/cstr.h.
* libmu_auth/sql.c: Likewise.
* mimeview/mimetypes.y: Use mu_tolower, instead of tolower.
2009-07-08 Sergey Poznyakoff <gray@gnu.org.ua>
Implement the mu_mailbox_get_uidls function and --uidl option
in movemail.
* include/mailutils/mailbox.h (MU_UIDL_LENGH)
(MU_UIDL_BUFFER_SIZE): New defines.
(struct mu_uidl): New struct.
(mu_mailbox_get_uidls): New prototype.
* libproto/include/mailbox0.h (struct _mu_mailbox): New member
_get_uidls.
* libproto/pop/mbox.c: Implement _get_uidls.
* libproto/pop/folder.c: Include mailutils/cctype.h.
* mailbox/mailbox.c (mu_mailbox_get_uidls): New function.
* movemail/movemail.c: Implement --uidl option: use UIDLs to
avoid downloading same messages twice. Based on the idea of
Alfred M. Szmidt. Implement --verbose option.
* libproto/imap/mbox.c: Fix comment.
* NEWS: Update.
* doc/texinfo/programs.texi: Update.
2009-07-07 Sergey Poznyakoff <gray@gnu.org.ua>
Update include/.gitignore.
2009-07-07 Sergey Poznyakoff <gray@gnu.org.ua>
Use new string trimming functions in parsers.
* include/mailutils/cstr.h (mu_str_stripws): New function.
* mailbox/stripws.c: New file.
* mailbox/Makefile.am (libmailutils_la_SOURCES): Add stripws.c
* examples/nntpclient.c (stripwhite): Remove. Use
mu_str_stripws instead.
(execute_line): Rewrite using new string functions.
* examples/pop3client.c: Likewise.
* mailbox/mailcap.c (stripwhite): Remove. Use mu_str_stripws
instead.
* mailbox/mime.c (_strltrim, _strttrim, _strtrim): Remove. Use
mu_str_stripws instead.
* mail/mail.c: Use mu_str_stripws.
* mail/mail.h (util_stripwhite): Remove prototype.
* mail/util.c (util_stripwhite): Remove
* examples/pop3client.c: Likewise.
* imap4d/util.c: Use new string functions.
* maidag/forward.c: Likewise.
* maidag/lmtp.c: Likewise.
* mh/mhn.c: Likewise.
* libproto/imap/folder.c: Remove unused local.
* libproto/mailer/smtp.c (smtp_writeline): Minor optimization.
2009-07-07 Sergey Poznyakoff <gray@gnu.org.ua>
Minor changes.
* include/mailutils/cstr.h (mu_str_skip_class_comp)
(mu_str_skip_cset_comp): New prototypes.
* mailbox/strskip.c (mu_str_skip_class_comp)
(mu_str_skip_cset_comp): New functions.
* libmu_auth/ldap.c (find_pwcheck): Fix typo in function call.
* libproto/pop/mbox.c: Fix typos in diagnostic messages.
2009-07-07 Sergey Poznyakoff <gray@gnu.org.ua>
Introduce locale-independent character type and string
functions.
* include/mailutils/cctype.h: New file.
* include/mailutils/cstr.h: New file.
* include/mailutils/Makefile.am: Add new files.
* mailbox/cstrcasecmp.c: New file.
* mailbox/cstrlower.c: New file.
* mailbox/cstrupper.c: New file.
* mailbox/muctype.c: New file.
* mailbox/strltrim.c: New file.
* mailbox/strrtrim.c: New file.
* mailbox/strskip.c: New file.
* mailbox/Makefile.am: Add new files.
* .gitignore: Update
* gnulib.modules: Remove strcase.
* comsat/comsat.h, imap4d/imap4d.h,
include/mailutils/mailutils.h, include/mailutils/mutil.h,
include/mailutils/sys/pop3.h, libmu_scm/mu_scm.h, mail/mail.h:
Include cstr.h and cctype.h.
* comsat/oldcfg.c, config/mailutils-config.c,
examples/mimetest.c, examples/mta.c, examples/nntpclient.c,
examples/pop3client.c, imap4d/append.c, imap4d/create.c,
imap4d/delete.c, imap4d/fetch.c, imap4d/id.c, imap4d/idle.c,
imap4d/list.c, imap4d/namespace.c, imap4d/rename.c,
imap4d/search.c, imap4d/status.c, imap4d/store.c, imap4d/uid.c,
imap4d/util.c, libmu_argp/compat.c, libmu_auth/ldap.c,
libmu_auth/sql.c, libmu_scm/mu_message.c,
libmu_sieve/actions.c, libmu_sieve/comparator.c,
libmu_sieve/extensions/list.c, libmu_sieve/extensions/spamd.c,
libmu_sieve/extensions/vacation.c, libmu_sieve/load.c,
libmu_sieve/sieve.l, libmu_sieve/tests.c,
libproto/imap/folder.c, libproto/mailer/smtp.c,
libproto/mbox/mbox.c, libproto/mh/folder.c, libproto/mh/mbox.c,
libproto/pop/folder.c, libproto/pop/mbox.c,
libproto/pop/pop3_connect.c, maidag/forward.c, maidag/lmtp.c,
maidag/maidag.c, maidag/maidag.h, maidag/mailquota.c,
mail/alt.c, mail/copy.c, mail/decode.c, mail/escape.c,
mail/followup.c, mail/mail.c, mail/mailline.c, mail/msgset.y,
mail/print.c, mail/reply.c, mail/send.c, mail/shell.c,
mail/util.c, mail/write.c, mailbox/address.c, mailbox/amd.c,
mailbox/assoc.c, mailbox/attachment.c, mailbox/attribute.c,
mailbox/cfg_lexer.l, mailbox/date.c, mailbox/filter.c,
mailbox/gdebug.c, mailbox/header.c, mailbox/kwd.c,
mailbox/locale.c, mailbox/mailcap.c, mailbox/mailer.c,
mailbox/message.c, mailbox/message_stream.c, mailbox/mime.c,
mailbox/msrv.c, mailbox/mutil.c, mailbox/parse822.c,
mailbox/progmailer.c, mailbox/rfc2047.c, mailbox/syslog.c,
mailbox/url.c, mailbox/version.c, mh/mh.h, mh/mh_alias.l,
mh/mh_ctx.c, mh/mh_fmtgram.y, mh/mh_init.c, mh/mh_list.c,
mh/mh_msgset.c, mh/mh_sequence.c, mh/mh_whatnow.c,
mh/mh_whom.c, mh/mhn.c, mh/mhparam.c, mh/pick.y, mh/sortm.c,
mimeview/mimetypes.y, pop3d/bulletin.c, pop3d/expire.c,
pop3d/pop3d.c, pop3d/pop3d.h, pop3d/popauth.c, pop3d/user.c,
readmsg/msglist.c, readmsg/readmsg.c, readmsg/readmsg.h,
sql/mysql.c, sql/postgres.c: Use locale-independent cclass and
str functions.
2009-07-06 Sergey Poznyakoff <gray@gnu.org.ua>
Define the necessary PATH_ constants.
* paths: New file.
* am/config_paths.m4: New file.
* include/confpaths.h.in: New file.
* Makefile.am (EXTRA_DIST): Add paths.
(DISTCLEANFILES): Add pathdefs.h
* configure.ac: Invoke MU_CONFIG_PATHS
(AC_CONFIG_FILES): Add include/confpaths.h
* include/Makefile.am (EXTRA_DIST): Add confpaths.h.in
* lib/utmp.c, libmu_scm/mu_scm.c, libproto/mailer/sendmail.c,
mail/mail.c: Use PATH_* constants.
* mail/mail.h: Remove definition of _PATH_SENDMAIL.
* .gitignore, include/.gitignore: Update.
2009-07-05 Wojciech Polak <polak@gnu.org>
Fix libmu_cpp compilation.
* examples/cpp/http.cc, examples/cpp/iconv.cc,
examples/cpp/lsf.cc, examples/cpp/mailcap.cc,
examples/cpp/msg-send.cc, examples/cpp/sfrom.cc,
libmu_cpp/message.cc, libmu_cpp/mutil.cc, libmu_cpp/pop3.cc:
Include missing <cstdlib>.
2009-07-05 Sergey Poznyakoff <gray@gnu.org.ua>
Add maintainer-specific files.
* maint.mk: New file.
* config/maint.mk: New file.
* README-hacking: Update.
2009-07-05 Sergey Poznyakoff <gray@gnu.org.ua>
Fix namespaces and inclusion directories.
* README-hacking: Update.
* configure.ac (MU_COMMON_INCLUDES): Remove.
(MU_LIB_COMMON_INCLUDES,MU_APP_COMMON_INCLUDES): New variables.
Link lib/gettext.h and lib.intprops.h to include.
* gnulib.modules: Remove fnmatch.
* comsat/Makefile.am, config/Makefile.am, dotlock/Makefile.am,
frm/Makefile.am, guimb/Makefile.am, imap4d/Makefile.am,
maidag/Makefile.am, mail/Makefile.am, movemail/Makefile.am,
pop3d/Makefile.am, python/libmu_py/Makefile.am,
readmsg/Makefile.am sieve/Makefile.am (INCLUDES): Use
MU_APP_COMMON_INCLUDES
* lib/Makefile.am, examples/Makefile.am,
libmu_argp/Makefile.am, libmu_auth/Makefile.am,
libmu_cpp/Makefile.am, libmu_sieve/Makefile.am,
libproto/imap/Makefile.am, libproto/mailer/Makefile.am,
libproto/mh/Makefile.am, libproto/nntp/Makefile.am,
libproto/pop/Makefile.am, mailbox/Makefile.am,
mapi/Makefile.am, messages/Makefile.am, mh/Makefile.am,
sql/Makefile.am (INCLUDES): Use MU_LIB_COMMON_INCLUDES
2009-07-05 Sergey Poznyakoff <gray@gnu.org.ua>
Minor changes.
* examples/mta.c: Remove include mu_asprintf.h.
* libmu_auth/radius.c: Remove include inttostr.h.
* libmu_scm/mu_dbgport.c: Silence gcc warnings.
* libmu_sieve/extensions/pipe.c: Remove include <mu_dbm.h>.
* libmu_sieve/sieve-priv.h: Remove include mu_asprintf.h.
* maidag/python.c: Remove unused locals.
* python/libmu_py/address.c: Likewise.
* python/libmu_py/auth.c: Likewise.
* python/libmu_py/body.c: Likewise.
* python/libmu_py/secret.c: Likewise.
* python/libmu_py/stream.c: Likewise.
* python/libmu_py/url.c: Likewise.
* python/libmu_py/util.c: Likewise.
2009-07-05 Sergey Poznyakoff <gray@gnu.org.ua>
Bugfixes.
* mailbox/debug.c (mu_debug_printv): use mu_debug_vprintf
* mailbox/message_stream.c (restore_envelope): supplied sender
address must be a single word.
2009-06-18 Sergey Poznyakoff <gray@gnu.org.ua>
Bugfix.
* mailbox/mutil.c (mu_fd_wait): Handle exceptions.
2009-05-28 Wojciech Polak <polak@gnu.org>
Add Secret class to Python interface.
* python/libmu_py/secret.c: New file.
* python/mailutils/secret.py: New file.
* python/mailutils/url.py (get_secret): New method.
(get_passwd): Remove.
* python/mailutils/mailbox.py (MailboxBase.open): Access mode
argument value can be now one of the following strings: "r",
"w", "a", "c".
2009-05-26 Wojciech Polak <polak@gnu.org>
Add Secret class to libmu_cpp.
2009-05-26 Sergey Poznyakoff <gray@gnu.org.ua>
Enable Makefile silent rules.
* Makefile.am (AUTOMAKE_OPTIONS): Remove.
* bootstrap: Import from mailfromd.
* configure.ac: Require autoconf 2.63 Enable silent-rules mode
by default.
* guimb/scm/Makefile.am: Add silent-rules markers.
* include/mailutils/Makefile.am: Likewise.
* libmu_scm/Makefile.am: Likewise.
* testsuite/Makefile.am: Likewise.
2009-05-26 Sergey Poznyakoff <gray@gnu.org.ua>
Bugfix.
2009-05-26 Sergey Poznyakoff <gray@gnu.org.ua>
Minor changes.
* guimb/main.c (main_sym): Remove const qualifier.
* imap4d/imap4d.h (util_getfullpath): 1st arg is const.
* imap4d/util.c: Likewise.
* include/mailutils/guile.h (mu_guile_load): 1st arg is const.
* include/mailutils/sql.h (mu_sql_get_field): 3rd arg is const.
* libmu_auth/radius.c: Cleanup trailing whitespace.
* libmu_scm/mu_guile.c (mu_guile_load): 1st arg is const.
(struct load_closure): Filename is const. All uses updated.
* mailbox/monitor.c (RWLOCK_TRYRDLOCK, RWLOCK_TRYWRLOCK):
Remove
[!WITH_PTHREAD] (RWLOCK_DESTROY): Empty define.
* mailbox/mutil.c (mu_aget_user_email_domain): Minor fix.
* sql/sql.c (mu_sql_get_field): 3rd arg is const.
2009-05-25 Sergey Poznyakoff <gray@gnu.org.ua>
* include/mailutils/secret.h: New file. *
include/mailutils/types.hin (mu_secret_t): New type. *
include/mailutils/auth.h (mu_ticket_destroy): Remove 2nd arg
(owner). (mu_ticket_ref, mu_ticket_unref): New functions.
(mu_ticket_set_destroy): New function. (mu_ticket_set_pop):
Remove. (mu_ticket_get_cred, mu_ticket_set_get_cred): New
functions. (mu_ticket_get_data): Return data pointer.
(mu_ticket_set_secret, mu_ticket_set_plain): New functions.
(mu_wicket_create): Remove 2nd arg. (mu_wicket_set_filename,
mu_wicket_get_filename): Remove. (mu_wicket_set_ticket):
Remove. (mu_wicket_get_ticket): Change proto.
(mu_wicket_set_destroy, mu_wicket_set_data)
(mu_wicket_get_data, mu_wicket_set_get_ticket): New functions.
(mu_file_wicket_create): New function. *
include/mailutils/mailutils.h: Include secret.h [MU_COMPAT]:
Remove. * include/mailutils/url.h (mu_url_sget_passwd,
mu_url_aget_passwd) (mu_url_get_passwd) (mu_url_get_secret):
New function.
* libproto/include/auth0.h: Rewrite.
* libproto/include/imap0.h (struct _f_imap): Replace passwd
with mu_secret_t secret.
* libproto/include/url0.h (struct _mu_url): Replace passwd with
mu_secret_t secret.
(_get_passwd): Replace with _get_secret
* mailbox/secret.c: New function.
* mailbox/Makefile.am (libmailutils_la_SOURCES): Add secret.c.
* mailbox/ticket.c: Rewrite from scratch.
* mailbox/wicket.c: Rewrite from scratch.
* libproto/imap/folder.c: Rewrite using mu_secret_t.
* libproto/pop/mbox.c: Rewrite using mu_secret_t.
* libproto/mailer/prog.c, libproto/mailer/sendmail.c,
mailbox/auth.c, mailbox/url.c, movemail/movemail.c: Reflect
changes to ticket/wicket system.
* mailbox/mbx_default.c: Use new mu_wicket_t functions.
* python/libmu_py/auth.c (api_wicket_get_filename)
(api_wicket_set_filename): Remove. Not applicable any more.
* python/libmu_py/url.c (api_url_get_passwd): Temporarily
commented out.
* include/mailutils/Makefile.am (pkginclude_HEADERS): Add
secret.h.
* examples/url-parse.c: Use mu_secret_t calls.
* imap4d/namespace.c: Minor changes.
* libmu_auth/pam.c: Likewise.
2009-05-25 Sergey Poznyakoff <gray@gnu.org.ua>
Fix some special cases of using mu_app_init.
* libmu_argp/muinit.c (mu_app_init): Allow capa==NULL.
* mailbox/cfg_driver.c (mu_config_clone_container): Do nothing
if cont == NULL.
2009-05-19 Sergey Poznyakoff <gray@gnu.org.ua>
Bugfixes.
* maidag/deliver.c: Run filter scripts with user privileges.
* maidag/script.c (apply_script): Use stat, not access, to
check for the existence of the script file. Access takes into
account accessibility of intermediate directories, which is
irrelevant in this case.
* mailbox/mutil.c (mu_expand_path_pattern): Bugfix. Remove the
% format specifiers after expanding them.
2009-05-11 Sergey Poznyakoff <gray@gnu.org.ua>
Bugfixes.
* mailbox/filter.c (filter_close): Do not close transport
stream if the MU_STREAM_NO_CLOSE flag is set.
* imap4d/fetch.c (fetch_io): Fix memory leak: open the filter
with MU_STREAM_NO_CLOSE flag and destroy it after use.
* include/mailutils/header.h (mu_header_set_stream): Comment
out. There is no such function, but perhaps there should be?
* libproto/mbox/folder.c (_folder_mbox_init): If there is no
explicit path in the URL, use ".". This makes it possible to
use URLs like: mbox:file.
* mailbox/nls.c (mu_set_locale) [ENABLE_NLS]: Remove ifdef.
Setlocale must be enabled whenever possible, otherwise we
cannot relay on mu_strftime malfunctions in non-english
locales.
* mh/mh_whom.c (mh_alias_expand): Handle NULL or empty inputs.
2009-04-16 Sergey Poznyakoff <gray@gnu.org.ua>
Minor changes.
* include/mailutils/address.h (struct _mu_address): Rename to
struct mu_address: it is public interface.
* include/mailutils/types.hin: Likewise.
* examples/addr.c: Likewise.
* mailbox/address.c: Likewise.
* mailbox/parse822.c: Likewise.
* libmu_sieve/extensions/vacation.c (vacation_reply): Fix
memory leaks.
* libproto/mailer/mbox.c (remote_mbox_append_message): Use
mu_address_create_hint instead of
mu_set_user_email_domain/mu_address_create.
* maidag/maidag.c (main): Set both diag and debug printers
explicitly.
* mail/from.c (mail_from0): minor change.
* mail/reply.c (reply0): Fix memory leak.
* mailbox/header.c: minor change.
2009-04-15 Sergey Poznyakoff <gray@gnu.org.ua>
Improve RFC822 address parsing.
* examples/addr.c: Allow to modify hints via command line (-v)
and within the shell (\...).
* include/mailutils/address.h (MU_ADDR_HINT_*): New defines.
(struct _mu_address): Definition.
(mu_address_create_hint): New prototype.
* include/mailutils/parse822.h (mu_parse822_address_list)
(mu_parse822_mail_box, mu_parse822_group) (mu_parse822_address,
mu_parse822_route_addr) (mu_parse822_route,
mu_parse822_addr_spec)
(mu_parse822_unix_mbox, mu_parse822_local_part): Take hint and
hint flags.
* mailbox/parse822.c: Likewise.
* libproto/include/Makefile.am (noinst_HEADERS): Remove
address0.h
* libproto/include/address0.h: Removed.
* mailbox/address.c (mu_address_create_hint): New function.
(mu_address_create): Rewrite using mu_address_create_hint.
* mh/mh_init.c (mh_expand_aliases): Use
mu_header_sget_field_name
* mh/mh_whom.c (mh_alias_expand): Rewrite using
mu_address_create_hint. This fixes parsing addresses similar to
"a@b <a@b>".
* mh/send.c: New command line option --preserve (--keep)
2009-04-14 Sergey Poznyakoff <gray@gnu.org.ua>
Allow to set user's personal namespace in imap4d.
* imap4d/imap4d.c (homedir): Remove variable.
(real_homedir, imap4d_homedir, modify_homedir): New variables.
(imap4d_cfg_param): New statements: homedir,
personal-namespace.
(imap4d_session_setup0): Initialize real_homedir and
imap4d_homedir.
* imap4d/imap4d.h (homedir, rootdir): Remove declarations.
(real_homedir, imap4d_homedir, modify_homedir): New
declarations. Include mailutils/vartab.h.
* imap4d/list.c, imap4d/lsub.c, imap4d/namespace.c,
imap4d/subscribe.c, imap4d/unsubscribe.c, imap4d/util.c: Use
imap4d_homedir and real_homedir, where appropriate.
* NEWS: Update.
* imap4d/preauth.c: Remove inclusion of mailutils/vartab.h
2009-04-13 Sergey Poznyakoff <gray@gnu.org.ua>
Bugfix.
* libproto/imap/folder.c (imap_list): Fix memory overrun. Set
response->level.
2009-04-07 Sergey Poznyakoff <gray@gnu.org.ua>
Bugfix.
* mailbox/mbx_default.c (mu_mailbox_create_default): Reset mail
to NULL if it is "".
2009-04-07 Sergey Poznyakoff <gray@gnu.org.ua>
Allow to use mailer URLs as append-only mailboxes (deprecates
remote+ mailboxes)
* NEWS: Update.
* configure.ac (MU_LIB_REMOTE): Remove.
(AC_CONFIG_FILES): Remove libproto/remote/Makefile.
* include/mailutils/registrar.h (mu_remote_mbox_record):
Remove.
(MU_REMOTE_MBOX_PRIO): Remove.
* libproto/Makefile.am (SUBDIRS): Remove remote.
* libproto/include/mailer0.h (_mu_mailer_mailbox_init)
(_mu_mailer_folder_init): New protos.
* libproto/include/registrar0.h (_url_smtp_init)
(_mailer_smtp_init): Remove.
(_mu_mailer_sendmail_init, _mu_mailer_prog_init): Add
prototype.
* libproto/include/url0.h (struct _mu_url._uplevel): New
member.
* libproto/mailer/Makefile.am (libmu_mailer_la_SOURCES): Remove
url_sendmail.c and url_smtp.c.
* libproto/mailer/mbox.c: Move from ../remote.
* libproto/mailer/url_sendmail.c: Remove.
* libproto/mailer/url_smtp.c: Remove.
* libproto/mailer/prog.c: Fix namespace.
* libproto/mailer/sendmail.c: Likewise.
* libproto/mailer/smtp.c: Likewise.
* libproto/mailer/remote.c: New file.
* libproto/remote/: Remove.
* maidag/Makefile.am (maidag_LDADD): Remove ${MU_LIB_REMOTE}.
* maidag/deliver.c (deliver_url): Remove `remote+' hack.
(deliver): Fix error message.
* maidag/guile.c: Fix indentation.
* maidag/maidag.c: Support `remote+' mailboxes for backward
compatibility.
* mailbox/mailbox.c (_create_mailbox0): Call u_init after
ensuring that url->scheme coincides with record->scheme.
* mailbox/url.c (mu_url_uplevel): Use url->_uplevel, if
defined.
* libmu_argp/mu_argp.h (mu_check_option): Remove duplicate and
incorrect prototype.
2009-04-06 Sergey Poznyakoff <gray@gnu.org.ua>
Bugfix.
* libproto/remote/folder.c (_remote_is_scheme): Fix invalid
return value.
2009-03-30 Wojciech Polak <polak@gnu.org>
Capture Python output in maidag.
* include/mailutils/python.h (mu_py_capture_stdout,
mu_py_capture_stderr): New prototypes.
* maidag/python.c (python_check_msg): Redirect output.
2009-03-28 Sergey Poznyakoff <gray@gnu.org.ua>
Bugfixes.
* libmu_scm/mailutils.scm.in: Remove leftover reference to
mu_guimb.inc
2009-03-28 Sergey Poznyakoff <gray@gnu.org.ua>
Bugfixes.
* imap4d/copy.c: Set target mailbox permissions.
* imap4d/rename.c: Remove useless variable. Add some comments.
2009-03-27 Sergey Poznyakoff <gray@gnu.org.ua>
Implement guile output redirection in maidag.
* libmu_scm/mu_guimb.c: Remove
* libmu_scm/mu_dbgport.c: New file.
* libmu_scm/Makefile.am: Update.
* include/mailutils/guile.h (mu_process_mailbox): Remove.
(mu_scm_make_debug_port, mu_scm_debug_port_init): New
prototypes.
* libmu_scm/mu_scm.c (mu_scm_init): Call
mu_scm_debug_port_init.
* maidag/guile.c (scheme_check_msg): Redirect error/output to
MU port.
* mailbox/mutil.c (mu_expand_path_pattern): Expand ~.
2009-03-27 Sergey Poznyakoff <gray@gnu.org.ua>
Finish removing mail.local and mail.remote.
2009-03-25 Sergey Poznyakoff <gray@gnu.org.ua>
Remove mail.local and mail.remote, Maidag should be used
instead.
* mail.local: Remove.
* mail.remote: Remove.
* Makefile.am, configure.ac: Update.
* doc/texinfo/mailutils.texi: Rebuild master menu.
* doc/texinfo/programs.texi: Update.
2009-03-25 Wojciech Polak <polak@gnu.org>
Return int from mu_py_init_*()
2009-03-25 Wojciech Polak <polak@gnu.org>
Update mailutils.spec.in.
2009-03-25 Wojciech Polak <polak@gnu.org>
Add python to mailutils-config.
2009-03-25 Sergey Poznyakoff <gray@gnu.org.ua>
Remove vestiges of scripts/ in Makefiles.
2009-03-24 Wojciech Polak <polak@gnu.org>
Add Python scripting to maidag.
* maidag/python.c: New file.
* maidag/script.c (script_tab): Add Python.
* maidag/maidag.h (python_check_msg): New prototype.
* configure.ac: Conditionally define python-related variables.
2009-03-24 Sergey Poznyakoff <gray@gnu.org.ua>
Rewrite scripting support in maidag.
* include/mailutils/guile.h (mu_guile_init, mu_guile_load)
(mu_guile_eval, mu_guile_mailbox_apply, mu_guile_message_apply)
(mu_guile_safe_exec, mu_guile_safe_proc_call): New protos.
* libmu_scm/Makefile.am: Add mu_guile.c
* libmu_scm/mu_guile.c: New file.
* libmu_scm/mu_mailbox.c (struct mu_mailbox): Kludge: new
member noclose.
(mu_scm_mailbox_free): Do not close/destroy mailbox if it is
marked noclose.
(mu_scm_mailbox_create0): Kludge: new function.
* libmu_scm/mu_message.c (mu_scm_message_print): Bugfix.
* maidag/Makefile.am: Add guile.c and sieve.c.
* maidag/deliver.c (maidag_stdio_delivery) [WITH_GUILE]: Remove
block.
(deliver_url): Call script_apply, instead of sieve_test.
* maidag/maidag.c: Rewrite scripting support in a modular way.
Remove options: --sieve, --source (and the corresponding config
statements). Add options: --language, --script. Add configure
statement: filter (block).
* maidag/maidag.h (progfile_pattern, sieve_pattern): Remove.
(script_list, sieve_debug_flags, message_id_header,
sieve_enable_log): New prototypes.
[WITH_GUILE]: Remove.
(maidag_script_fun, struct maidag_script): New data type.
(script_handler): New extern. (script_lang_handler,
script_suffix_handler)
(script_register, script_apply): New protos.
(scheme_check_msg, sieve_check_msg): New protos.
* maidag/script.c: Rewrite. Provide general-purpose serialized
script support.
* guimb/guimb.h (struct guimb_data): Remove.
* guimb/main.c: Rewrite in a cleaner way, using functions from
mu_guile.c.
* guimb/collect.c (guimb_catch_body, guimb_catch_handler)
(guimb_exit): Remove.
* guimb/scm/sieve-core.scm (sieve-current-message,
sieve-mailbox): Public.
(sieve-run-current-message): New public function.
(sieve-run): Call sieve-run-current-message for each message.
* guimb/scm/sieve.scm.in (sieve-save-program): Change code
generation to suit both per-mailbox and per-message invocation.
This kicks mail.local out of whack.
* maidag/guile.c: New file.
* maidag/sieve.c: New file.
2009-03-24 Sergey Poznyakoff <gray@gnu.org.ua>
Minor fixes.
* configure.ac (GUIMB): Rename to MU_SCM_BIN_PROGRAMS_BUILD.
* guimb/Makefile.am: Likewise.
2009-03-24 Sergey Poznyakoff <gray@gnu.org.ua>
Fix imap4d input tokenizer.
The proper delimiters are ( and ), listed in RFC as
atom_specials. The characters "[]<>." are delimiters for FETCH,
and "." is a delimiter for STORE. Fix tokenizer to recognize
these only in the corresponding contexts.
In particular, it fixes parsing of input atoms containing dots,
as foo@bar.baz, which previous versions incorrectly split in
three.
* imap4d/util.c (ISDELIM): Delimiters are only ( and )
* imap4d/imap4d.h (struct imap4d_parsebuf): new data type.
(imap4d_parsebuf_t): New data type. (imap4d_parsebuf_exit,
imap4d_parsebuf_peek) (imap4d_parsebuf_next,
imap4d_parsebuf_token)
(imap4d_parsebuf_data, imap4d_with_parsebuf): New prototypes.
* imap4d/parsebuf.c: New file.
* imap4d/Makefile.am: Add parsebuf.c
* imap4d/fetch.c, imap4d/store.c: Rewrite using parsebuf
functions.
2009-03-22 Sergey Poznyakoff <gray@gnu.org.ua>
Bugfix.
* mailbox/stream.c (mu_stream_readline): Fix byte counting.
2009-03-22 Sergey Poznyakoff <gray@gnu.org.ua>
Improve autoconf machinery, drop support for Guile < 1.8.
* scripts/guile-1.4: Removed.
* scripts/guile-1.6/guile-doc-snarf: Move to the parent dir.
* scripts/guile-1.6/guile-doc-snarf.awk: Move to the parent
dir.
* scripts: Rename to mu-aux. All references updated.
* am/enable.m4 (MU_ENABLE_SUPPORT): add fourth argument,
action-default Translate + to x.
* am/guile.m4 (MU_RESULT_ACTIONS): Remove.
(MU_CHECK_GUILE): Rewrite. Drop support for versions < 1.8
* am/lib.m4 (MU_CHECK_LIB): Rewrite using a cleaner approach.
* bootstrap.conf: Remove build_aux assignment.
* configure.ac: Assume a new naming scheme for optional builds:
for each subst variable named MU_whatever_BUILD there is a
corresponding Makefile.am variable named MU_whatever_LIST, if
`whatever' is to be built MU_whatever_BUILD is set to
'$(MU_whatever_LIST)' New option --disable-c++. Improve status
output.
* examples/Makefile.am, examples/cpp/Makefile.am,
include/mailutils/Makefile.am, libmu_cpp/Makefile.am,
libmu_scm/Makefile.am, libmu_sieve/Makefile.am,
libmu_sieve/extensions/Makefile.am, libmu_sieve/load.c,
mail.remote/Makefile.am, mail.remote/testsuite/Makefile.am,
mailbox/Makefile.am, mh/Makefile.am, mimeview/Makefile.am,
mu-aux/Makefile.am, python/mailutils/Makefile.am: Reflect
changes to autoconf machinery.
* /include/mailutils/guile.h: Drop support for versions < 1.8
* libmu_scm/mu_util.c: Likewise.
2009-03-19 Sergey Poznyakoff <gray@gnu.org.ua>
Mail: fix parsing of arguments containing =.
* mail/util.c (util_do_command): Do not use = as a delimiter.
* mail/set.c (mail_set): = is no longer returned as a token.
* mail/setenv.c (mail_setenv): Likewise.
2009-03-18 Wojciech Polak <polak@gnu.org>
Add scripting to libmu_py.
* python/libmu_py/script.c: New file.
2009-03-14 Wojciech Polak <polak@gnu.org>
Split Python interface into libmu_py and c_api.so.
* include/mailutils/python.h: New file.
* python/c_api: Rename to python/libmu_py.
2009-03-12 Sergey Poznyakoff <gray@gnu.org.ua>
Bugfixes.
* imap4d/bye.c: Discern between input and output errors.
* imap4d/imap4d.h (ERR_NO_IFILE): New error code.
* imap4d/util.c: Discern between input and output errors.
Improve trace output.
(imap4d_getline): Signal ERR_NO_IFILE on EOF.
* movemail/movemail.c: Fix include statements.
2009-03-08 Wojciech Polak <polak@gnu.org>
Add new Python interface and example programs.
2009-03-07 Wojciech Polak <polak@gnu.org>
Improve libmu_cpp.
* libmu_cpp/address.cc, libmu_cpp/envelope.cc,
libmu_cpp/header.cc, libmu_cpp/url.cc: Use sget instead of
aget.
* libmu_cpp/list.cc (mulist_to_stl): New function.
(List::to_stl): New method.
* include/mailutils/cpp/list.h: Likewise.
2009-03-05 Wojciech Polak <polak@gnu.org>
Add Envelope class to libmu_cpp. Add new methods.
* include/mailutils/cpp/envelope.h, libmu_cpp/envelope.cc: New
files.
2009-03-05 Sergey Poznyakoff <gray@gnu.org.ua>
Fix coredumps on null passwords in pam and ldap auth.
* libmu_auth/pam.c (mu_pam_service): Initialize to package
name.
(mu_pam_conv): Raise PAM_AUTHTOK_RECOVER_ERR, if password is
NULL. Fix memory leak on errors.
(mu_authenticate_pam): Fix return value.
* libmu_auth/ldap.c (mu_ldap_authenticate): Prevent coredump on
empty password.
2009-03-04 Sergey Poznyakoff <gray@gnu.org.ua>
Fix the return of get_ticket.
2009-03-04 Sergey Poznyakoff <gray@gnu.org.ua>
Fix semantics of mu_attribute_to_string.
* include/mailutils/attribute.h (MU_STATUS_BUF_SIZE): New
define.
* libproto/mbox/mbox.c: Update use of mu_attribute_to_string.
* mailbox/amd.c: Likewise.
* mailbox/attribute.c (mu_string_to_flags): Rewrite.
(mu_attribute_to_string): Fill the string with flag letters
only, without "Status:" prefix and final newline.
* NEWS: Update.
2009-03-03 Sergey Poznyakoff <gray@gnu.org.ua>
All client utilities: read ~/.mu-tickets.
* NEWS: Update.
* include/mailutils/mailbox.h (mu_ticket_file): New extern.
* include/mailutils/message.h (mu_message_save_to_mailbox):
Change proto.
* include/mailutils/sieve.h (mu_sieve_get_ticket,
mu_sieve_set_ticket): Remove.
* libmu_sieve/actions.c (sieve_action_fileinto): Update call to
mu_message_save_to_mailbox.
* libmu_sieve/sieve-priv.h (struct mu_sieve_machine): Remove
ticket.
* libmu_sieve/sieve.y (mu_sieve_get_ticket,
mu_sieve_set_ticket): Remove.
* mailbox/mbx_default.c (mu_mailbox_create_default): Read a
wicket file and attach a ticket if mailbox opened successfully.
* mailbox/wicket.c: Re-format.
* sieve/sieve.c: Remove special wicket-handling code.
* libmu_auth/radius.c, movemail/movemail.c: Add missing
includes
2009-02-27 Wojciech Polak <polak@gnu.org>
Update libmu_cpp.
* libmu_cpp/filter.cc, include/mailutils/cpp/filter.h,
include/mailutils/cpp/stream.h: Split FilterStream.
* libmu_cpp/mailbox.cc, include/mailutils/cpp/mailbox.h: Add
new methods.
* examples/cpp/iconv.cc: Reflect changes in filter.h.
* examples/cpp/mimetest.cc: Likewise.
* examples/cpp/http.cc: Bugfix.
2009-02-20 Sergey Poznyakoff <gray@gnu.org.ua>
Bugfixes in AMD code.
* libproto/include/amd.h (new_msg_file_name): Add an argument
indicating whether an actual expunging is going to take place,
as opposed to saving message flags.
* libproto/maildir/mbox.c (maildir_new_message_name): Sync with
above changes.
* libproto/mh/mbox.c (_mh_new_message_name): Likewise.
* mailbox/amd.c (_amd_message_save): Handle unlink requests
(new_msg_file_name returning NULL name). This avoids creating
temp files.
(amd_expunge): Remove messages that have had
MU_ATTRIBUTE_DELETED on mailbox open, if the underlying mailbox
implementation allows that.
2009-02-20 Sergey Poznyakoff <gray@gnu.org.ua>
Define LOG_AUTHPRIV if syslog.h does not.
2009-02-20 Sergey Poznyakoff <gray@gnu.org.ua>
Remove leftover dependencies of libmailutils from gnulib.
* bootstrap.conf (gnulib_extra_files): Remove.
* gnulib.modules (inttostr): Add module.
* include/mailutils/io.h: New file.
* include/mailutils/Makefile.am: Add io.h
* mailbox/inttostr.c, mailbox/inttostr.h: Remove
* mailbox/imaxtostr.c, mailbox/offtostr.c, mailbox/umaxtostr.c:
Remove
* mailbox/intprops.h: Remove
* mailbox/asnprintf.c, mailbox/asprintf.c,
mailbox/vasnprintf.c: New files.
* mailbox/Makefile.am: Update.
* mailbox/mu_umaxtostr.c: rename to lib/mu_umaxtostr.c
* mailbox/mu_umaxtostr.h: rename to lib/mu_umaxtostr.h
* lib/Makefile.am (libmuaux_la_SOURCES): Add mu_umaxtostr.[ch]
* libmu_auth/radius.c, libmu_cfg/common.c, libmu_scm/mu_port.c,
libproto/imap/folder.c, libproto/imap/mbox.c,
libproto/mbox/mbox.c, libproto/mh/mbox.c, libproto/pop/mbox.c,
mailbox/acl.c, mailbox/daemon.c, mailbox/mailer.c,
mailbox/message.c, mailbox/mutil.c, mailbox/stream.c: Use
mu_strerror. Avoid using mu_umaxtostr.
2009-02-19 Wojciech Polak <polak@gnu.org>
* imap4d/util.c (imap4d_readline): Bugfix.
2009-02-19 Sergey Poznyakoff <gray@gnu.org.ua>
Bugfix.
* libproto/mailer/prog.c (_expand_sender): Allocate memory.
2009-02-18 Wojciech Polak <polak@gnu.org>
Update mailutils-config after renaming libraries.
2009-02-18 Sergey Poznyakoff <gray@gnu.org.ua>
Update timestamp.
2009-02-18 Sergey Poznyakoff <gray@gnu.org.ua>
Bugfix.
* libproto/imap/folder.c (imap_parse): fix parsing of numeric
values after UIDNEXT, UIDVALIDITY and UNSEEN.
* NEWS: Sync with configure.ac
2009-02-18 Sergey Poznyakoff <gray@gnu.org.ua>
Bugfix.
* libproto/imap/folder.c (imap_parse): fix parsing of numeric
values after UIDNEXT, UIDVALIDITY and UNSEEN.
2009-02-17 Wojciech Polak <polak@gnu.org>
Update RPM spec.
2009-02-16 Wojciech Polak <polak@gnu.org>
* am/lib.m4 (MU_CHECK_LIB): Switch to AC_TRY_LINK_FUNC.
2009-02-14 Wojciech Polak <polak@gnu.org>
Update docs.
* doc/texinfo/libmuauth.texi: Move to libmu_auth.texi
* doc/texinfo/libsieve.texi: Move to libmu_sieve.texi
2009-02-14 Wojciech Polak <polak@gnu.org>
Rename libraries.
Rename libmuauth to libmu_auth, libargp to libmu_argp, libcfg
to libmu_cfg, and libsieve to libmu_sieve.
* auth/*: Move to libmu_auth/*
* libargp/*: Move to libmu_argp/*
* libcfg/*: Move to libmu_cfg/*
* libsieve/*: Move to libmu_sieve/*
* libmu_sieve/sieve.h: Rename to sieve-priv.h
* include/mailutils/libsieve.h: Rename to sieve.h
* configure.ac: Update, bump to 2.0.90.
2009-02-13 Sergey Poznyakoff <gray@gnu.org.ua>
Find best matching registrar records.
* mailbox/registrar.c (mu_registrar_lookup_url): Find best
matching record.
2009-02-11 Sergey Poznyakoff <gray@gnu.org.ua>
Update THANKS.
2009-02-11 Sergey Poznyakoff <gray@gnu.org.ua>
Bugfix.
* libproto/imap/mbox.c (imap_envelope_sender): Bugfix. Address
was freed before using its member.
2009-02-11 Sergey Poznyakoff <gray@gnu.org.ua>
Fix opening remote mailbox URLs with path component.
* include/mailutils/folder.h (mu_folder_create_from_record):
Change type of the 2nd argument to mu_url_t.
* include/mailutils/url.h (mu_url_uplevel): New proto.
* mailbox/folder.c (mu_folder_create_from_record): Change type
of the 2nd argument to mu_url_t.
(mu_folder_create): Reflect changes to
mu_folder_create_from_record.
* mailbox/mailbox.c (mailbox_folder_create): Use
mu_url_uplevel.
* mailbox/url.c (mu_url_uplevel): New function.
2009-02-10 Sergey Poznyakoff <gray@gnu.org.ua>
Bugfix.
* libproto/imap/mbox.c (imap_envelope_sender): Fix operation
when buf == NULL or buflen == 0.
2009-02-10 Serge Monkewitz <smm@ipac.caltech.edu>
Fix alignment bug in assoc.c.
2009-01-30 Wojciech Polak <polak@gnu.org>
Add Folder class to libmu_cpp. Provide new examples lsf.cc and
msg-send.cc.
* examples/cpp/lsf.cc, examples/cpp/msg-send.cc,
include/mailutils/cpp/folder.h, libmu_cpp/folder.cc: New files.
2009-01-04 Wojciech Polak <polak@gnu.org>
Add Debug class to libmu_cpp.
* include/mailutils/cpp/debug.h, libmu_cpp/debug.cc: New files.
* examples/cpp/mimetest.cc, examples/cpp/sfrom.cc,
libmu_cpp/header.cc, include/mailutils/cpp/header.h: Accept
default header value if missing.
2009-01-03 Wojciech Polak <polak@gnu.org>
libmu_cpp refactoring and improvements.
* examples/cpp/mimetest.cc, include/mailutils/cpp/attribute.h,
include/mailutils/cpp/body.h, include/mailutils/cpp/mime.h,
include/mailutils/cpp/mutil.h,
include/mailutils/cpp/registrar.h, libmu_cpp/attribute.cc,
libmu_cpp/body.cc, libmu_cpp/mime.cc, libmu_cpp/mutil.cc,
libmu_cpp/registrar.cc: New files.
2008-12-26 Sergey Poznyakoff <gray@gnu.org.ua>
Version 2.0.
* NEWS, configure.ac: Version 2.0
* README: Update
* doc/texinfo/mailutils.texi: Update.
* doc/texinfo/programs.texi: Update.
* doc/Makefile.am: Add usage.texi.
* imap4d/imap4d.c (imap4d_cfg_param): Fix typo.
* auth/tls.c (mu_tls_module_init): Add missing break.
2008-12-25 Sergey Poznyakoff <gray@gnu.org.ua>
Update docs.
2008-12-24 Sergey Poznyakoff <gray@gnu.org.ua>
Minor fix.
2008-12-24 Sergey Poznyakoff <gray@gnu.org.ua>
Fix TLS support, improve GOCS subsystem.
* include/mailutils/gocs.h (gocs_init_fp): Rename to
mu_gocs_init_fp. Change signature. (mu_gocs_mailbox_init,
mu_gocs_locking_init, mu_gocs_source_email_init)
(mu_gocs_mailer_init, mu_gocs_logging_init)
(mu_gocs_debug_init): Fix prototypes.
* include/mailutils/gsasl.h (mu_gsasl_module_init): Update
prototype.
* include/mailutils/libsieve.h (mu_sieve_module_init): Update
prototype.
* include/mailutils/mu_auth.h (struct mu_auth_module.init):
Update type to mu_gocs_init_fp.
* include/mailutils/radius.h (mu_radius_module_init): Update
prototype.
* include/mailutils/tls.h (struct
mu_tls_module_config.client_enable): Replace with .enable. It
affects entire TLS subsystem, not only client part.
(mu_tls_module_init): Update prototype.
* include/mailutils/types.hin (mu_gocs_op): New enum.
* mailbox/gocs.c (mu_gocs_dummy, mu_gocs_mailbox_init)
(mu_gocs_locking_init, mu_gocs_source_email_init)
(mu_gocs_mailer_init, mu_gocs_logging_init)
(mu_gocs_debug_init): Take two arguments.
(mu_gocs_flush): After running set stage, call all init
callbacks with mu_gocs_op_flush.
* auth/tls.c (mu_tls_module_config): Initialize .enable to 1.
(mu_tls_module_init): Rewrite using new prototype. Use
mu_gocs_op_flush to initialize the library.
(mu_init_tls_libs): Initialize the library only if
mu_tls_module_config.enable is set.
* auth/gsasl.c (mu_gsasl_module_init): Update.
* auth/ldap.c (mu_ldap_module_init): Update.
* auth/pam.c (mu_pam_module_init): Update.
* auth/radius.c (mu_radius_module_init): Update.
* auth/sql.c (mu_sql_module_init): Update.
* auth/virtual.c (mu_virtual_module_init): Update.
* libcfg/tls.c (mu_tls_param): Update.
* libsieve/conf.c (mu_sieve_module_init): Update.
* doc/texinfo/programs.texi: Update.
2008-12-24 Sergey Poznyakoff <gray@gnu.org.ua>
Fixes.
* doc/texinfo/Makefile.am (final): Add fix-sentence-spacing.
* doc/texinfo/mailutils.texi: Update.
* doc/texinfo/programs.texi: Update.
* pop3d/pop3d.c, sieve/sieve.c: Use mu_cfg_bool, where
appropriate.
2008-12-23 Sergey Poznyakoff <gray@gnu.org.ua>
Update the docs.
2008-12-09 Sergey Poznyakoff <gray@gnu.org.ua>
Bugfix.
* mailbox/parsedate.y (DATE_SET): Change >= comparison to
strict >.
(__SET_SECOND,__SET_MINUTE,__SET_HOUR): Fix upper limit.
2008-12-08 Sergey Poznyakoff <gray@gnu.org.ua>
Update .gitignores.
2008-12-08 Sergey Poznyakoff <gray@gnu.org.ua>
Makefile.am: Remove gen_start_date.
2008-12-08 Sergey Poznyakoff <gray@gnu.org.ua>
Switched to Git repository.
* m4: Rename to am.
* README-alpha, README-hacking: Reflect the switch.
* */.cvsignore: Rename to .gitignore, update.
* gnulib.modules: Add gitlog-to-changelog.
* ChangeLog: Remove.
2008-12-04 Wojciech Polak <polak@gnu.org>
* include/mailutils/cpp/url.h, libmu_cpp/url.cc,
examples/cpp/addr.cc, examples/cpp/url-parse.cc:
Reflect recent API changes.
2008-12-03 Sergey Poznyakoff <gray@gnu.org.ua>
* testsuite/etc/mailutils.rc.in: New file.
* testsuite/etc/DISTFILES: Add mailutils.rc.in
* testsuite/lib/mailutils.exp (mu_copy_file): Define $arg
variable to simplify using $ in template files.
* sieve/testsuite/lib/sieve.exp (SIEVE_ETC_DIR): New global
(sieve_test): Explicitly pass -f.
Use SIEVE_ETC_DIR/mailutils.rc as configuration file.
* imap4d/testsuite/imap4d/list.exp: Update the '*' test to match
new contents of $MU_DATA_DIR/etc
* libproto/pop/url.c (_url_pop_init): Remove obsolete call to
mu_url_init.
* sieve/sieve.c (sieve_mailbox): Print actual mailbox URL in case
of failure.
2008-11-28 Sergey Poznyakoff <gray@gnu.org.ua>
* include/mailutils/opool.h (mu_opool_set_bucket_size)
(mu_opool_get_bucket_size): New protos.
* mailbox/opool.c (struct _mu_opool.bucket_size): New member.
(alloc_pool, copy_chars): Use opool->bucket_size to set bucket
size.
(mu_opool_create): Initialize bucket_size with the default
value.
(mu_opool_set_bucket_size,mu_opool_get_bucket_size): New
functions.
2008-11-27 Sergey Poznyakoff <gray@gnu.org.ua>
Add iterator support to opool.
* include/mailutils/opool.h (mu_opool_get_iterator): New function.
* mailbox/opool.c (mu_opool_get_iterator): New function.
* mailbox/hdritr.c (hdr_data_dup): Bugfix: notify owner about the
new iterator.
2008-11-21 Sergey Poznyakoff <gray@gnu.org.ua>
* auth/sql.c (get_field): NULL value in an optional field is
equivalent to MU_ERR_NOENT.
2008-11-18 Sergey Poznyakoff <gray@gnu.org.ua>
* mailbox/amd.c (_amd_attach_message): Call mu_body_clear_modified
and mu_message_clear_modified after constructing the message to
make sure it is not marked as modified.
2008-11-16 Sergey Poznyakoff <gray@gnu.org.ua>
* mailbox/argcv.c (quote_transtab): Add vertical tabulation
character.
2008-11-15 Sergey Poznyakoff <gray@gnu.org.ua>
* mailbox/cfg_driver.c (mu_cfg_tree_reduce): Format parse tree
before scanning the tree.
* mailbox/cfg_parser.y (block rule): Accept empty blocks.
(parse_param): bail out if callback is not declared when it
should.
* mailbox/daemon.c (mu_daemon_create_pidfile)
(mu_daemon_remove_pidfile): If running with UID=0 and EUID != 0,
temporarily switch to EUID=0 for accessing pidfile (when
creating or deleting).
2008-11-12 Sergey Poznyakoff <gray@gnu.org.ua>
* mailbox/cfg_parser.y (mu_cfg_format_error): Raise
mu_cfg_error_count only if level is less or equal to error.
(_scan_tree_helper): "unknown section" is a warning.
* configure.ac, NEWS: Version 1.9.93.
* include/mailutils/libargp.h (mu_app_cfg_verifier): New extern.
* libargp/muinit.c (mu_app_cfg_verifier): New variable.
(mu_app_init): Call mu_app_cfg_verifier if in lint mode.
* mailbox/cfg_driver.c (mu_cfg_tree_reduce): Return 0 if no
configuration is supplied.
2008-11-11 Sergey Poznyakoff <gray@gnu.org.ua>
* libargp/muinit.c (mu_app_init): Do not parse configs if
--config-help was given.
2008-11-09 Wojciech Polak <polak@gnu.org>
Fix typos.
* doc/texinfo/mailcap.texi, doc/texinfo/mailutils.texi
doc/texinfo/mom.texi, doc/texinfo/mu-mh.texi,
doc/texinfo/mu_message.texi, doc/texinfo/programs.texi,
doc/texinfo/sieve.texi: Fix typos.
2008-11-09 Sergey Poznyakoff <gray@gnu.org.ua>
Rewrite default mailbox format support to make sure it does not
break format autodetection. Improve the docs.
* configure.ac (MU_DEFAULT_SCHEME): New configuration variable.
* mailbox/version.c (mu_conf_opt): Include default scheme.
* examples/mimetest.c, examples/mta.c, libmu_scm/mu_scm.c: Remove
mu_path_record. Use mu_registrar_set_default_record.
* libproto/mbox/folder.c (_path_is_scheme): Rename to
_mbox_is_scheme. Minor changes as well.
(_path_record, mu_path_record): Removed.
(_mbox_record): Use _mbox_is_scheme.
* libsieve/actions.c: Remove unused variable.
* include/mailutils/Makefile.am (types.h rule): Replace
_MU_DEFAULT_RECORD_. Change MU_OFF_TYPE replacement pattern to
_MU_OFF_TYPE_.
* include/mailutils/mailbox.h (mu_mailbox_set_default_proto)
(mu_mailbox_get_default_proto): Remove. See below.
* include/mailutils/registrar.h (mu_registrar_set_default_scheme)
(mu_registrar_get_default_scheme)
(mu_registrar_get_default_record)
(mu_registrar_set_default_record)
(mu_registrar_lookup_scheme): New prototypes.
(mu_path_record): Remove.
(mu_register_all_mbox_formats): Remove mu_path_record.
Set default scheme using mu_registrar_set_default_record.
(mu_register_local_mbox_formats): Likewise.
* include/mailutils/types.hin (MU_OFF_TYPE): Rename to
_MU_OFF_TYPE_.
(MU_DEFAULT_RECORD): New define.
* mailbox/mailbox.c (mu_mailbox_set_default_proto)
(mu_mailbox_get_default_proto): Remove.
(mu_mailbox_create): Remove default_proto kludge. mu_registrar
stuff is responsible for finding the correct record.
* mailbox/registrar.c (mu_registrar_set_default_record)
(mu_registrar_get_default_record)
(mu_registrar_set_default_scheme)
(mu_registrar_get_default_scheme)
(mu_registrar_lookup_scheme): New functions.
(mu_registrar_lookup_url): Fall back to default record if no
matching record is found and the URL was not set explicitly
(i.e. does not begin with a scheme).
* mailbox/gocs.c: Use mu_registrar_set_default_scheme instead of
mu_mailbox_set_default_proto.
* libsieve/extensions/pipe.c, libsieve/extensions/spamd.c,
libsieve/extensions/vacation.c: Fix comments.
* doc/texinfo/getdate.texi: New file (from gnulib).
* doc/texinfo/Makefile.am (mailutils_TEXINFOS): Add getdate.texi
(fix-sentence-spacing): New rule. Forces single-space
inter-sentence spacing.
(check-tabs, check-sentence-spacing): New rules.
(check-format): Depend on the above two.
(check-refs, check-fixmes, check-unrevised): Fix copy-paste
errors. Print diagnostics to stderr.
* doc/texinfo/auth.texi, doc/texinfo/fdl.texi,
doc/texinfo/framework.texi, doc/texinfo/imap4.texi,
doc/texinfo/libmuauth.texi, doc/texinfo/mailbox.texi,
doc/texinfo/mailcap.texi, doc/texinfo/mailutils.texi,
doc/texinfo/mbox.texi, doc/texinfo/message.texi,
doc/texinfo/mom.texi, doc/texinfo/mu_message.texi,
doc/texinfo/mu_mime.texi, doc/texinfo/mu_scm.texi,
doc/texinfo/muint.texi, doc/texinfo/pop3.texi,
doc/texinfo/rendition.texi, doc/texinfo/sieve.texi,
doc/texinfo/url.texi, doc/texinfo/usage.texi: Use GNU instead of
@sc{gnu}, because latter looks awful when typeset (especially when
followed by a capitalized word). Fix format by running `make final'.
* doc/texinfo/programs.texi: Document more config statements.
* doc/texinfo/libsieve.texi: Document loadable actions and tests.
2008-11-07 Sergey Poznyakoff <gray@gnu.org.ua>
Bugfix
* mailbox/amd.c (_amd_message_save): Make sure message files have
right permissions.
(amd_message_stream_open): Remove useless flags addition.
Permissions are taken care of in _amd_message_save.
Allow to set mailbox permissions using fileinto Sieve action.
* mailbox/permstr.c: New file.
* mailbox/Makefile.am (libmailutils_la_SOURCES): Add permstr.c.
* imap4d/imap4d.c (parse_mode_spec): Remove function.
(cb_mailbox_mode): Use mu_parse_stream_perm_string instead of
parse_mode_spec.
* imap4d/imap4d.h (namespace_getfullpath)
(namespace_checkfullpath): First arg is const.
* imap4d/namespace.c (namespace_getfullpath)
(namespace_checkfullpath): First arg is const.
* include/mailutils/message.h (mu_message_save_to_mailbox): Add
5th argument (permissions).
* mailbox/message.c: Likewise.
* include/mailutils/mutil.h (mu_parse_stream_perm_string): New
proto.
(mu_stream_flags_to_mode): Add isdir argument.
* libsieve/actions.c (sieve_action_fileinto): New tag :permissions
allows to set permissions to the mailbox being created.
* mailbox/mutil.c (mu_stream_flags_to_mode): Add 2nd argument
(isdir). Any bits in [go] sets imply raising 'x' bit for
directories (i.e. if isdir != 0).
* libproto/maildir/mbox.c, mailbox/amd.c: Update calls to
mu_stream_flags_to_mode.
* NEWS, doc/texinfo/sieve.texi: Update.
Allow to set file permissions of the local mailboxes during
creation.
* include/mailutils/stream.h (MU_STREAM_IRGRP, MU_STREAM_IWGRP)
(MU_STREAM_IROTH, MU_STREAM_IWOTH, MU_STREAM_IMASK): New defines.
* include/mailutils/mutil.h (mu_stream_flags_to_mode): New
prototype.
* libproto/maildir/mbox.c (maildir_create, maildir_flush)
(maildir_scan0): Consider mailbox flags to determine its file
mode.
* mailbox/amd.c (amd_open, amd_message_stream_open): Likewise.
* mailbox/file_stream.c (_file_open): Likewise.
* mailbox/mutil.c (mu_stream_flags_to_mode): New file.
* imap4d/namespace.c (namespace_getfullpath)
(namespace_checkfullpath): Return the namespace number in the last
argument (if not null).
* imap4d/append.c, imap4d/copy.c, imap4d/delete.c, imap4d/list.c,
imap4d/rename.c, imap4d/select.c, imap4d/status.c: Update calls to
namespace_getfullpath.
* imap4d/create.c (imap4d_create): Set mailbox flags depending on
the namespace it is created in.
* imap4d/imap4d.c (mailbox_mode): New variable.
(parse_mode_spec): New function.
(imap4d_cfg_param): New statements other-mailbox-mode and
shared-mailbox-mode.
* imap4d/imap4d.h (mailbox_mode): New proto.
(namespace_getfullpath, namespace_checkfullpath): Add a parameter.
* mailbox/progmailer.c (mu_progmailer_set_debug): Add missing
return statement.
2008-11-05 Sergey Poznyakoff <gray@gnu.org.ua>
Implement forwarding functionality in Maidag.
* maidag/forward.c: New file.
* maidag/Makefile.am (maidag_SOURCES): Add forward.c.
* maidag/deliver.c (deliver_url): Call maidag_forward for local
users.
* maidag/maidag.c (forward_file, forward_file_checks): New
variables.
(maidag_cfg_param): New keywords forward-file and
forward-file-checks.
* maidag/maidag.h (FWD_IWGRP, FWD_IWOTH, FWD_LINK, FWD_DIR_IWGRP)
(FWD_DIR_IWOTH, FWD_ALL): New defines.
(forward_file, forward_file_checks): New variables.
(enum maidag_forward_result): New data type.
(maidag_forward): New prototype.
Simplify calls to final delivery functions.
* maidag/deliver.c (mda): Pass msg as a 1st argument to deliver.
(deliver_to_user): Remove 1st argument.
(deliver): Change type of the 1st argument to mu_message_t.
* maidag/lmtp.c (dot_deliver): Pass msg as a 1st argument to
deliver.
* maidag/maidag.c (sieve_test): Change type of the 2nd argument to
mu_message_t.
* maidag/maidag.h (sieve_test, deliver): Pass mu_message_t,
instead of mu_message_t.
* mailbox/mailer.c (mu_mailer_create_from_url): Set default debug
level.
* sql/mysql.c (mu_mysql_connect): Avoid coredumps if conn->server
is NULL.
2008-10-28 Sergey Poznyakoff <gray@gnu.org.ua>
Make maidag handle mailer URLs.
This makes it possible to `deliver' mails to mailers without
explicitly specifying `remote+mailer' mailbox URLs. In
particular, it is handy for implementing mailing lists using
`prog' mailers (as with Mailman).
* maidag/deliver.c (notify_action): Do nothing if biff_user_name
is empty.
(deliver_to_user): Remove `name' argument. Allow for auth==NULL.
(is_remote_url): Use case-sensitive comparison.
(is_mailer_url): New function.
(deliver_url): Handle mailer URLs as if they were corresponding
`remote+' mailbox URLs. This allows to handle mailing lists.
* maidag/lmtp.c (lmtp_groups): New global.
(lmtp_set_privs): New function. Sets primary and
supplementary group privileges.
(maidag_lmtp_server): Call lmtp_set_privs.
* maidag/maidag.c (lmtp_group): Remove. It is superseded by
lmtp_groups.
(maidag_cfg_param): Allow to specify supplementary groups.
* maidag/maidag.h (lmtp_group): Replace with lmtp_groups.
Change mailer creation mechanism.
* include/mailutils/mailer.h (mu_mailer_create_from_url): New
proto.
* mailbox/mailer.c (mu_mailer_create_from_url): New
function.
(mu_mailer_create): Rewrite using mu_mailer_create_from_url.
* libproto/mailer/prog.c (_url_prog_init): Do not call
mu_url_init.
(url_to_argv): Reflect changes to mu_url functions.
* libproto/mailer/url_sendmail.c (_url_sendmail_init): Do not call
mu_url_init.
* libproto/mailer/url_smtp.c (_url_smtp_init): Likewise.
Minor fixes.
* mailbox/mailbox.c (_create_mailbox0): Take care not to destroy
url, if creation of the mailbox failed.
(_create_mailbox): Destroy url if unable to create mailbox.
* mailbox/mutil.c (mu_is_proto): Take starting | as a protocol
specification. A kludge.
* include/mailutils/argcv.h: Fix indentation.
Change handling of query part in a URL.
Queries are now parsed into arguments and returned as arrays
of arguments.
* libproto/include/url0.h (struct _mu_url): Replace query with
array of query arguments.
* include/mailutils/url.h (mu_url_dup): New proto.
(mu_url_get_query): Remove.
(mu_url_sget_query, mu_url_aget_query): Return query split into
arguments.
(mu_url_set_scheme): New function.
(mu_url_decode_len): New function.
* mailbox/url.c (mu_url_dup): New function.
(mu_url_get_query): Remove.
(mu_url_sget_query, mu_url_aget_query): Return query split into
arguments.
(mu_url_set_scheme): New function.
(mu_url_decode_len): New function.
* libproto/remote/mbox.c (remote_mbox_init): Use parsed out URL,
instead of the full URL string.
* examples/url-parse.c: Change query output.
* mailbox/testsuite/Urls: Reflect changes to url-parse. Add new
testcases.
* libproto/imap/url.c, libproto/pop/url.c: Reflect changes to URL
functions.
2008-10-25 Sergey Poznyakoff <gray@gnu.org.ua>
Initial implementation of a `prog' mailer.
* configure.ac: Enable/disable prog mailer support.
* include/mailutils/progmailer.h: New file.
* include/mailutils/Makefile.am (pkginclude_HEADERS): Add
progmailer.h
* include/mailutils/mailutils.h: Include progmailer.h
* include/mailutils/registrar.h (MU_PROG_PRIO): New define.
(mu_prog_record): New extern.
(mu_register_all_mailer_formats): Register mu_prog_record.
* include/mailutils/types.hin (mu_progmailer_t): New typedef.
* libproto/include/registrar0.h (MU_PROG_SCHEME)
(MU_PROG_SCHEME_LEN): New defines.
* libproto/mailer/prog.c: New file.
* libproto/mailer/Makefile.am (libmu_mailer_la_SOURCES): Add
prog.c
* libproto/mailer/sendmail.c: Rewrite using mu_progmailer_t
* libproto/remote/folder.c (_remote_is_scheme): Remove unused
variable.
* mailbox/progmailer.c: New file
* mailbox/Makefile.am (libmailutils_la_SOURCES): Add progmailer.c
* mailbox/acl.c (_expand_aclno): Add a fixme.
* mail/send.c (msg_to_pipe): Bugfix: use pclose, instead of fclose.
* examples/config/mailutils.schema: Update.
2008-10-24 Sergey Poznyakoff <gray@gnu.org.ua>
* examples/config/mailutils.dict: Use GNU OID number.
* examples/config/mailutils.schema: Use sub-OID assigned to GNU
Mailutils.
* libsieve/prog.c (mu_sv_code_command): Ensure tag arguments have
the proper type.
Fix handling of stdin stream (in particular, in sieve).
* libsieve/extensions/spamd.c (spamd_test): Fix typo.
* mailbox/file_stream.c (struct _file_stream): New members
size and size_computed.
(_stdin_file_read, _stdin_file_readline): Fix types of fs_offset.
(_stdin_file_size): New function.
(_stdout_file_write): Register _stdin_file_size as stream_size
method if seekable flag is set.
* mailbox/message_stream.c (struct _mu_rfc822_message): Remove
unused member.
* sieve/sieve.c (sieve_message): Create a seekable stream.
2008-10-23 Sergey Poznyakoff <gray@gnu.org.ua>
* libsieve/extensions/spamd.c: New tag :user.
* sieve/sieve.c: New working mode: if `-f -' is given, treat
stdin as an RFC2822 message, apply the script to it and exit with
1 if the message gets deleted, 0 if it is not and EX_SOFTWARE on
software errors.
In traditional mode, exit with standard sysexit codes.
* testsuite/sieve/i-numeric.exp: Reflect changes in sieve.
* NEWS: Update.
2008-10-19 Sergey Poznyakoff <gray@gnu.org.ua>
* auth/sql.c (decode_tuple): Use new tuple parsing mode, unless
`positional' is set to true.
* include/mailutils/sql.h (struct mu_sql_module_config)
(struct mu_internal_sql_config): New member `positional'.
* libcfg/sql.c (mu_sql_param): New statement `positional'.
* auth/virtual.c (getpwnam_virtual): Close file.
* doc/texinfo/programs.texi: Document virtmode.
* testsuite/Makefile.am (EXTRA_DIST): Remove
* testsuite/makespool: Remove.
* NEWS: Update.
* doc/texinfo/libmuauth.texi: Update.
* doc/texinfo/mailutils.texi: Update.
* doc/texinfo/programs.texi: Update.
* include/mailutils/mailbox.h (mu_mailbox_create_from_url): New
function.
* include/mailutils/mutil.h (mu_aget_user_email_domain): New
function.
* libproto/include/address0.h: Remove obsolete comment.
* libproto/remote/mbox.c (remote_mbox_append_message): If
recipient address is not given, try to construct it from the URL.
* mailbox/mailbox.c (mu_mailbox_create_from_url): New function.
* mailbox/mutil.c (mu_aget_user_email_domain): New function.
* maidag/deliver.c (deliver_to_user): Mailbox and auth must be
freed by the caller.
(deliver_url): New function.
(deliver): Rewrite to allow for delivering to mailboxes explicitly
specified by URLs (--url command line option).
* maidag/maidag.c (options): New option --url.
(main): Handle --url.
* maidag/maidag.h (url_option): New global.
* maidag/mailquota.c (check_quota): Return if auth == NULL.
2008-10-17 Sergey Poznyakoff <gray@gnu.org.ua>
* include/mailutils/libsieve.h (mu_sieve_match_part_checker): New
prototype.
* libsieve/comparator.c (mu_sv_match_part_checker): Rename back to
mu_sieve_match_part_checker. The function was mistakingly renamed
on 2008-07-19. All references updated.
* libsieve/tests.c: Likewise.
* libsieve/sieve.h (mu_sv_match_part_checker): Remove prototype.
* doc/texinfo/programs.texi: Update.
2008-10-16 Sergey Poznyakoff <gray@gnu.org.ua>
* libproto/mailer/smtp.c: Implement SIZE extension (RFC 1870).
* doc/rfc/rfc1870.txt: New file.
2008-10-15 Sergey Poznyakoff <gray@gnu.org.ua>
* po/POTFILES.in: Change cfg_lexer.c to cfg_lexer.l
2008-10-14 Sergey Poznyakoff <gray@gnu.org.ua>
* mailbox/url.c (url_parse0): Allow for
<user>:<password>;AUTH=<auth> syntax.
2008-10-05 Sergey Poznyakoff <gray@gnu.org.ua>
Fix remote+ records.
* libproto/remote/folder.c (remote_url_init): Remove.
(_remote_is_scheme): New function.
(_remote_mbox_record): Add _is_scheme method.
* libproto/remote/mbox.c (remote_mbox_init): Remove useless
check.
* mailbox/assoc.c (mu_assoc_clear): Return immediately if assoc
tab is NULL.
* mailbox/mailbox.c (_create_mailbox0): Do not enforce exact record
scheme match if the scheme ends with a plus sign.
Minor fixes in configuration.
* doc/texinfo/programs.texi: Document Locking, ACL, and
Tcp-wrappers.
* mailbox/cfg_driver.c (mu_cfg_assert_value_type): Convert
MU_CFG_STRING to MU_CFG_ARRAY.
* mailbox/cfg_parser.y: Replace `tag: value' with `tag: vallist'.
This allows for constructs like `acl a b c {', which were
understood by the previous version.
* mailbox/version.c (mu_conf_opt): Add WITH_LIBWRAP.
2008-09-29 Sergey Poznyakoff <gray@gnu.org.ua>
* config/mailutils-config.c (main): Do not print flag descriptions
on --info, this breaks existing scripts.
New option --verbose makes --info print verbose descriptions.
* include/mailutils/version.h (mu_fprint_options)
(mu_fprint_conf_option): Take additional argument.
* mailbox/argcv.c (quote_transtab): Handle \".
* mailbox/cfg_driver.c (mu_cfg_string_value_cb): Bugfix
* mailbox/cfg_lexer.l: Allow * and = in non-quoted words.
Improve 'stray character' diagnostics'.
(unescape_to_line): Handle \\ and \".
* mailbox/version.c (mu_fprint_options)
(mu_fprint_conf_option): New argument `verbose' instructs whether
to print textual descriptions.
(mu_fprint_conf_option): Print single space after the flag to
facilitate writing parser scripts.
* testsuite/lib/mailutils.exp: Reflect this change.
2008-09-22 Sergey Poznyakoff <gray@gnu.org.ua>
* configure.ac: Define LOG_FACILITY_STRING, a string
representation of syslog facility.
* mailbox/cfg_lexer.l: Re-introduce pragmatic comment
#debug=, for setting debugging level in config module.
* mailbox/cfg_parser.y: Likewise.
* mailbox/gdebug.c (mu_debug_level_from_string): Ignore trailing
newline.
* mailbox/version.c (mu_conf_option): Add SYSCONFDIR, MAILSPOOLDIR
and LOG_FACILITY.
* mh/mh_init.c (mh_list_format): Reformat to make it more
readable. Use decode primitive on header fields that may be
encoded.
* doc/texinfo/mailutils.texi: Further update.
* doc/texinfo/programs.texi: Likewise.
2008-09-21 Sergey Poznyakoff <gray@gnu.org.ua>
* configure.ac: Configure doc hints.
* config/mailutils-config.c (main): Use mu_fprint_conf_option.
* mailbox/version.c (mu_conf_option): Change type.
(mu_fprint_conf_option): New function.
(mu_fprint_options): Use mu_fprint_conf_option.
(mu_print_options): Fix signature
(mu_check_option): Change return type.
* testsuite/lib/mailutils.exp (mu_version): Reflect changes in the
output produced by --show-config-options.
* include/mailutils/version.h (struct mu_conf_option): New data
type.
(mu_check_option): Change return type.
(mu_fprint_conf_option): New prototype.
* libargp/common.c (mu_common_argp): Rename --rcfile-* options
to --config-*. Retain old names for a while.
* doc/texinfo/Makefile.am (RENDITION_TEXI): New variable.
(check-format, check-refs, check-fixmes, check-unrevised)
(all-check-docs, check-docs): New rules.
* doc/texinfo/rendition.texi: New file.
* doc/texinfo/macros.texi: New file.
* doc/texinfo/mailutils.texi: Start rewriting
* doc/texinfo/programs.texi: Likewise.
* doc/texinfo/c-api.texi: Reformat.
* doc/texinfo/fdl.texi: Likewise.
* doc/texinfo/libmuauth.texi: Likewise.
* doc/texinfo/libsieve.texi: Likewise.
* doc/texinfo/mu-mh.texi: Likewise.
* doc/texinfo/sieve.texi: Likewise.
* doc/texinfo/gendocs_template: Rewrite.
2008-08-24 Sergey Poznyakoff <gray@gnu.org.ua>
Fix testsuite to avoid spawning /bin/cp.
* imap4d/testsuite/imap4d.rcin: New file.
* imap4d/testsuite/Makefile.am (EXTRA_DIST): Add imap4d.rcin
* imap4d/testsuite/.cvsignore: Add imap4d.rc
* imap4d/testsuite/lib/imap4d.exp: Use mu_makespool to prepare
mailspools and mu_create_config to create test configuration
file. Specify the maximum amount of configuration data in the
latter, instead of using command line options.
* mail.local/testsuite/lib/mail.local.exp: Likewise.
* pop3d/testsuite/lib/pop3d.exp: Likewise.
* pop3d/testsuite/pop3d.rcin: New file.
* pop3d/testsuite/Makefile.am (EXTRA_DIST): Add pop3d.rcin
* pop3d/testsuite/.cvsignore: Add pop3d.rc.
* testsuite/etc/passwd.in: Use Tcl variable for expansion.
* testsuite/lib/mailutils.exp (mu_copy_file): New function.
(mu_makespool, mu_create_config): New function.
(mu_init): Remove unused variable MU_MAKESPOOL.
(mu_prepare_spools): Use mu_makespool.
(mu_cleanup_spools): Remove.
* libcfg/init.c (mu_parse_config_files): Minor change.
* mailbox/cfg_lexer.l (mu_get_config): Fix return value.
2008-08-21 Sergey Poznyakoff <gray@gnu.org.ua>
* include/mailutils/mutil.h, mailbox/mutil.c (mu_normalize_path):
Remove useless second argument. All uses changed.
Rewrite IMAP namespace support.
* imap4d/imap4d.c (imap4d_cfg_param): other-namespace and
shared-namespace take proper lists as arguments.
(imap4d_session_setup0): Call namespace_init_session.
(main): Call namespace_init.
* imap4d/imap4d.h (set_namespace): Remove.
(namespace_init): Change proto.
(namespace_init_session): New prototype.
(namespace): New declaration.
* imap4d/namespace.c: Rewrite using lists.
* mailbox/cfg_parser.y (parse_param): Cast string to lists if
the parameter has list type.
2008-08-20 Sergey Poznyakoff <gray@gnu.org.ua>
Implement ID extension.
* imap4d/id.c: New file.
* imap4d/Makefile.am (imap4d_SOURCES): Add id.c, remove version.c.
* imap4d/commands.c: Add ID command.
Remove X-VERSION command.
(SELECT,EXAMINE): Switch to authenticated mode on failure.
* imap4d/imap4d.c (imap4d_argc, imap4d_argv): New variables.
(imap4d_cfg_param): New keyword `id-fields'.
(main): Save command line arguments.
* imap4d/imap4d.h (imap4d_argc, imap4d_argv): New declarations.
* imap4d/select.c (imap4d_select0): Do not reset state to auth on
failure, this is done by util_finish.
* imap4d/version.c: Remove.
* imap4d/capability.c: Announce ID capability, remove X-VERSION.
* imap4d/testsuite/imap4d/x.exp: Use ID instead of X-VERSION.
* TODO, NEWS: Update.
* mailbox/cfg_parser.y (_set_fun,parse_param): Bugfix.
2008-08-19 Sergey Poznyakoff <gray@gnu.org.ua>
Bugfixes.
* libcfg/acl.c (parsearg): Initialize size.
* mailbox/cfg_driver.c (mu_cfg_assert_value_type): Bugfix.
* mailbox/cfg_lexer.l (mu_get_config): Close file.
* mailbox/cfg_parser.y: Fix array creation.
Change configuration file parser based on the lexer/parser from
GNU Dico.
* auth/gsasl.c: Remove deprecated data types.
* imap4d/auth_gsasl.c (retrieve_password): Minor fix.
* imap4d/imap4d.c, imap4d/imap4d.h, imap4d/namespace.c,
lib/tcpwrap.c, libcfg/acl.c, libcfg/auth.c, libcfg/common.c,
libcfg/ldap.c, libcfg/sieve.c, libcfg/sql.c, maidag/maidag.c,
mail.local/main.c, mailbox/gdebug.c, mailbox/msrv.c,
mimeview/mimeview.c, pop3d/bulletin.c, pop3d/pop3d.c,
pop3d/pop3d.h, sieve/sieve.c: Reflect changes to the configuration
system.
* mailbox/Makefile.am (AM_LFLAGS): New variable.
(EXTRA_DIST) Add cfg_lexer.l.
(libmailutils_la_SOURCES): Add alloc.c and opool.c
(BUILT_SOURCES): Add cfg_lexer.c.
(cfg_lexer.c): New goal.
* mailbox/alloc.c, mailbox/opool.c: New files.
* mailbox/cfg_lexer.c: Remove.
* mailbox/cfg_lexer.l: New file.
* mailbox/.cvsignore: Add cfg_lexer.c.
* include/mailutils/Makefile.am: Add alloc.h and opool.h
* include/mailutils/alloc.h: New file.
* include/mailutils/opool.h: New file.
* include/mailutils/cfg.h (mu_cfg_lexer_t,mu_cfg_alloc_t)
(mu_cfg_free_t): Remove types.
(MU_CFG_STRING, MU_CFG_LIST, MU_CFG_ARRAY): New defines.
(mu_config_value_t): New data type.
(struct mu_cfg_node): Change type of `label'.
(struct mu_cfg_tree): Remove `alloc', `free'.
New member `pool'.
(mu_cfg_parse): Simplify the signature by removing superfluous
arguments.
(mu_cfg_tie_in): Remove.
(mu_cfg_lexer_pool): New function.
(mu_cfg_find_node, mu_cfg_find_node_label): Remove.
(mu_cfg_callback_t): Change signature.
(MU_CFG_LIST_MASK): New define.
(MU_CFG_LIST_OF, MU_CFG_TYPE, MU_CFG_IS_LIST): New defines.
(mu_cfg_get_debug): New function.
(mu_cfg_assert_value_type, mu_cfg_string_value_cb): New functions.
(mu_cfg_tree_set_alloc, mu_cfg_tree_alloc): Remove.
* mailbox/cfg_driver.c: Adapt for new node structure.
(mu_cfg_assert_value_type, mu_cfg_string_value_cb): New function.
* mailbox/cfg_format.c: Adapt for new node structure.
* mailbox/cfg_parser.y: Adapt for changes in cfg data types and
lexer.
* include/mailutils/mailutils.h: Include alloc.h and opool.h
* include/mailutils/mu_auth.h (mu_authorization_add_module)
(mu_authentication_add_module): New prototypes.
* include/mailutils/syslog.h (mu_string_to_syslog_facility)
(mu_string_to_syslog_priority): First argument is const char *.
* mailbox/syslog.c: Likewise.
* include/mailutils/types.hin (mu_opool_t): New type.
* mailbox/list.c (mu_list_get_comparator): Add missing return
statement.
2008-08-18 Sergey Poznyakoff <gray@gnu.org.ua>
Autobuild setup.
* configure.ac: Add AB_INIT.
* gnulib.modules: Add autobuild.
Bugfixes.
* TODO: Update.
* imap4d/fetch.c: Prevent coredumps on inexpected end of statement
(e.g. `FETCH 1:* (uid')
* imap4d/imap4d.h (imap4d_select0): Update prototype.
* imap4d/select.c (imap4d_select0): Do not advertise actual
mailbox name with a NO response.
Return to authenticated state on failure.
* doc/rfc/Makefile.am (EXTRA_DIST): Add new rfcs.
* doc/rfc/rfc1413.txt, doc/rfc/rfc2087.txt, doc/rfc/rfc2180.txt,
doc/rfc/rfc2683.txt, doc/rfc/rfc3348.txt,
doc/rfc/rfc4314.txt: New files.
2008-08-17 Sergey Poznyakoff <gray@gnu.org.ua>
Bugfix.
* lib/tcpwrap.c (mu_tcp_wrapper_cb_hosts_deny_syslog):
(mu_tcp_wrapper_cb_hosts_allow_syslog): Use syslog priorities,
not facilities.
(tcpwrapper_param): Rename allow-syslog-level and
deny-syslog-level to allow-syslog-priority and
deny-syslog-priority, correspondingly.
Version 1.9.92.
* imap4d/list.c (imap4d_list): Fix addslash condition.
Improve folder listing.
* include/mailutils/registrar.h (_mu_record): New method
`_list_p'.
(mu_record_list_p): New function.
* libproto/include/amd.h (MU_AMD_SIZE_FILE_NAME): New define.
* libproto/maildir/folder.c (_maildir_is_scheme): Return
MU_FOLDER_ATTRIBUTE_FILE|MU_FOLDER_ATTRIBUTE_DIRECTORY, on
success.
Implement _list_p method.
* libproto/mbox/folder.c (list_helper): Change semantics of the
2nd argument. The record is used to determine whether or not
to list a particular file.
* libproto/mh/folder.c: Implement _list_p method.
* mailbox/amd.c (SIZE_FILE_NAME): Replace with
MU_AMD_SIZE_FILE_NAME from amd.h.
* mailbox/registrar.c (mu_record_list_p): New function.
Bugfix.
* libproto/maildir/mbox.c (info_to_flags): Fix return value.
Implement UNSELECT extension.
* doc/rfc/Makefile.am: Add rfc3691.txt
* doc/rfc/rfc3691.txt: New file.
* imap4d/capability.c: Announce UNSELECT capability.
* imap4d/close.c: Implement UNSELECT command.
* imap4d/commands.c: Add UNSELECT command.
* imap4d/imap4d.h (imap4d_unselect): New proto.
* imap4d/testsuite/imap4d/anystate.exp: Reflect UNSELECT
capability.
* imap4d/testsuite/imap4d/examine.exp: Reflect yesterday's changes
to STATUS output.
2008-08-16 Sergey Poznyakoff <gray@gnu.org.ua>
* imap4d/status.c (imap4d_status): Remove extra whitespace
before closing parenthesis in untagged reply.
Bugfixes.
* imap4d/fetch.c (parse_fetch_body): Bugfix, allow another tokens
after BODY.
* imap4d/util.c (util_msgset): Make sure returned number of
elements in set is always correct.
* mailbox/folder.c (is_known_folder): Compare paths as well. It
was commented out on 2001-04-10 (7 years ago!!!) for unknown
reasons.
* mailbox/url.c (DECL_CMP): Bugfix. The macro effectively created
a scheme comparator, no matter what its second argument was.
2008-08-14 Sergey Poznyakoff <gray@gnu.org.ua>
New functions.
* include/mailutils/list.h (mu_list_get_comparator)
(mu_list_intersect_dup, mu_list_intersect): New prototypes.
* mailbox/list.c (mu_list_get_comparator)
(mu_list_intersect_dup, mu_list_intersect): New functions.
Fix GSASL in imap4d.
* auth/gsasl.c (_gsasl_readline): Prevent getting stuck in
blocking streams.
* imap4d/auth_gsasl.c: Remove deprecated functions and data types.
* imap4d/auth_gss.c (auth_gssapi): Fix signature.
* imap4d/copy.c (imap4d_copy0): Fix return value.
* imap4d/imap4d.c (imap4d_cfg_param): Fix type of login-disabled.
* include/mailutils/gsasl.h (struct mu_gsasl_module_data): New
members: service, realm, hostname, anon_user.
* libcfg/gsasl.c (mu_gsasl_param): New keywords: service,
realm, hostname, anonymous-user.
2008-08-13 Sergey Poznyakoff <gray@gnu.org.ua>
* imap4d/util.c (imap4d_readline): Fix loop break condition.
* imap4d/testsuite/lib/imap4d.exp: Send newline after a literal.
Bugfixes.
* imap4d/copy.c, imap4d/fetch.c, imap4d/store.c: Do not report
error on non-existing message sets (RFC 3501, section 6.4.8).
* imap4d/testsuite/imap4d/IDEF0955.exp: Reflect this behavior.
* imap4d/testsuite/imap4d/fetch.exp: Header names in replies
to BODY[HEADER.FIELDS...] are no longer quoted.
2008-08-11 Sergey Poznyakoff <gray@gnu.org.ua>
More bugfixes in imap4d.
* imap4d/authenticate.c (_auth_try): Fix call to p->handler.
* imap4d/fetch.c (fetch_send_section_part): New argument
close_bracket.
Never print .PEEK, it confuses some clients (notably Thunderbird).
I need to verify RFC, though.
All callers updated.
* imap4d/idle.c: Use imap4d_getline to get the reply, to avoid
modifying tok and command.
* imap4d/imap4d.h (util_send_bytes, util_trim_nl): New prototypes.
* imap4d/util.c (util_trim_nl): New function.
(imap4d_getline): Use util_trim_nl.
Bugfixes.
* imap4d/fetch.c (fetch_send_section_part): Make sure the item tag
always reflects peek status. All callers updated.
(fetch_io): Try to allocate as large a buffer as possible.
Use util_send_bytes where fit.
* imap4d/imap4d.h (imap4d_auth_handler_fp): Remove unused argument.
* imap4d/store.c (imap4d_store0): Take into account eventual UID
prefix.
* imap4d/util.c (util_send_bytes): New function.
(util_send): Comment out transcript.
(util_do_command): Fix coredump on invalid commands.
(imap4d_readline): Transcript only first line of the input.
Ensure entire literal is read.
Fix input operations and RFC-compliance in imap4d.
* imap4d/util.c (util_getword, util_getitem, util_token)
(util_unquote): Remove.
(imap4d_readline): Rewrite to reduce memory reallocation. Add
support for non-synchronizing literals (RFC 2088).
(imap4d_readline_ex): Remove.
(util_do_command): Rewrite using new imap4d_readline.
(util_parse_internal_date0): Remove.
(imap4d_tokbuf_init, imap4d_tokbuf_destroy, imap4d_tokbuf_argc)
(imap4d_tokbuf_getarg, util_isdelim)
(imap4d_tokbuf_from_string): New functions.
* imap4d/append.c, imap4d/auth_gss.c, imap4d/authenticate.c,
imap4d/check.c, imap4d/close.c, imap4d/commands.c, imap4d/copy.c,
imap4d/create.c, imap4d/delete.c, imap4d/examine.c,
imap4d/imap4d.h, imap4d/list.c, imap4d/login.c, imap4d/logout.c,
imap4d/lsub.c, imap4d/expunge.c, imap4d/idle.c, imap4d/noop.c,
imap4d/rename.c, imap4d/search.c, imap4d/select.c,
imap4d/starttls.c, imap4d/status.c, imap4d/store.c,
imap4d/subscribe.c, imap4d/uid.c, imap4d/unsubscribe.c,
imap4d/version.c: Rewrite using new imap4d_readline.
* imap4d/namespace.c: Use new imap4d_readline. Ensure that
each reported prefix ends with a hierarchy delimiter.
* imap4d/imap4d.c (imap4d_mainloop): Use new imap4d_readline.
* imap4d/fetch.c: Rewrite parser from scratch.
* imap4d/capability.c (imap4d_capability_init): Report LITERAL+
capability.
* imap4d/testsuite/imap4d/anystate.exp: Account for the LITERAL+
capability.
* imap4d/testsuite/imap4d/append.exp: Fix APPEND arguments (imap4d
requires exactly three arguments, as per RFC3501.
Fix octet count in literals returned by fetch (previous versions
failed to include the trailing CRLF).
* imap4d/testsuite/imap4d/create.exp: Likewise.
* imap4d/testsuite/imap4d/fetch.exp: Fix FETCH arguments (previous
versions incorrectly accepted header-list without parentheses.
Fix result of FETCH 4 BODY[2.2.1]: it returns entire part, in the
contrast to previous versions, which treated it as
BODY[2.2.1.TEXT].
* maidag/mailtmp.c (mail_tmp_finish): Ensure /dev/null is treated
as mailbox.
2008-08-08 Sergey Poznyakoff <gray@gnu.org.ua>
Fix imap appends for AMD mailboxes.
* imap4d/append.c (imap4d_append0): Provide size method for the
message stream.
* imap4d/select.c (imap4d_select0): Call mu_mailbox_create_default.
* mailbox/amd.c (amd_append_message): Improve error checking.
2008-08-07 Sergey Poznyakoff <gray@gnu.org.ua>
* imap4d/create.c: Rewrite to create mailboxes honoring
mailbox-type.
* mailbox/mailbox.c (mu_mailbox_create): Bugfix.
2008-08-04 Sergey Poznyakoff <gray@gnu.org.ua>
* pop3d/retr.c (pop3d_retr): Use constant-size buffer. This
avoids running out of memory on messages that do not contain
trailing newline.
* pop3d/top.c (pop3d_top): Likewise.
2008-07-31 Sergey Poznyakoff <gray@gnu.org.ua>
* libproto/include/amd.h: Fix indentation.
* libproto/maildir/mbox.c (maildir_scan_dir): Do not assign uids
before inserting message, it breaks their ordering.
(maildir_scan0): Assign uids here. A temporary solution.
2008-07-19 Sergey Poznyakoff <gray@gnu.org.ua>
Minor fix.
* mh/mhn.c (normalize_path): First arg is const char *.
(store_handler): Avoid unnecessary allocations (and coredumps,
if mhn-storage profile is not set.
Finish namespace cleanup in libsieve.
* libsieve/actions.c, libsieve/comparator.c, libsieve/conf.c,
libsieve/load.c, libsieve/prog.c, libsieve/register.c,
libsieve/relational.c, libsieve/require.c, libsieve/runtime.c,
libsieve/sieve.h, libsieve/sieve.l, libsieve/sieve.y,
libsieve/tests.c, libsieve/util.c: Prefix all external
identifiers, that are not intended for use by application
programs, with mu_sv_.
Minor fixes.
* NEWS, configure.ac: Raise version to 1.9.91
* mail/mailline.c (ml_getc): Fix indentation.
* mailbox/mime.c (mu_mime_get_part): Return MU_ERR_NOENT if part
is out of range.
Keep namespace clean
* libsieve/comparator.c, libsieve/prog.c, libsieve/require.c,
libsieve/runtime.c, libsieve/sieve.h, libsieve/sieve.l,
libsieve/sieve.y, libsieve/util.c: Prefix instr_ functions with
mu_.
(sieve_filename, sieve_line_num): Removed. Use new global
mu_sieve_locus instead.
2008-07-04 Sergey Poznyakoff <gray@gnu.org.ua>
Fix converting RFC822 streams to messages.
* mailbox/message_stream.c (_mu_rfc822_stream): New members
envelope, and envelope_length.
(_mu_rfc822_read, _mu_rfc822_readline, _mu_rfc822_size): Skip
eventual envelope string.
(_mu_rfc822_open): Save envelope.
(_mu_rfc822_destroy): Free envelope.
(restore_envelope): Use message envelope, if it is present.
2008-06-17 Sergey Poznyakoff <gray@gnu.org.ua>
* mailbox/header.c (header_readline): Revert yesterday's change.
2008-06-16 Sergey Poznyakoff <gray@gnu.org.ua>
* auth/ldap.c (chk_sha): Remove useless return.
* mailbox/header.c (mu_hdrent_find_stream_pos): Check for
hrd->tail != NULL.
(header_readline): Return immediately if header size is 0.
2008-06-03 Sergey Poznyakoff <gray@gnu.org.ua>
* auth/radius.c (mu_grad_logger): New function.
(mu_radius_module_init): Install a custom logger function.
2008-05-31 Sergey Poznyakoff <gray@gnu.org.ua>
* libproto/include/amd.h (struct _amd_message.has_new_msg): New
field.
* mailbox/amd.c (amd_append_message): Cache information about
mailbox size in file .mu-size.
(make_size_file_name, read_size_file, write_size_file): New
functions.
(amd_expunge, amd_sync): Update size cache file.
(amd_get_size): Use size cache file if no mailbox_size method is
provided.
* mailbox/mbx_default.c (mu_normalize_mailbox_url): Accept `='
suffix for all mailbox types.
* movemail/movemail.c (main): Call mu_mailbox_sync before closing
destination mailbox.
2008-05-28 Sergey Poznyakoff <gray@gnu.org.ua>
* lib/Makefile.am (libmuaux_la_SOURCES): Add userprivs.c.
* lib/userprivs.c: New file.
* lib/muaux.h (mu_switch_to_privs): New prototype.
* libproto/include/amd.h (_amd_data.msg_finish_delivery): Pass
original message as the 3rd argument.
* libproto/maildir/mbox.c (maildir_msg_finish_delivery): Take
original message as the 3rd argument.
Use message attributes to select the subdirectory to place it
into.
* mailbox/amd.c (amd_append_message): Pass original message as the
3rd argument to msg_finish_delivery.
* mailbox/filter_trans.c (SOFTBRK): Remove unused macro.
* movemail/movemail.c: New option --copy-permissions (-P).
2008-04-07 Sergey Poznyakoff <gray@gnu.org.ua>
Implement compilation of Sieve sources from the memory.
* include/mailutils/libsieve.h (mu_sieve_compile_buffer): New
function.
* libsieve/sieve.h (sieve_lex_begin_string): New function.
* libsieve/sieve.l: Remove support for AT&T lex.
(sieve_lex_begin_string): New function.
* libsieve/sieve.y (mu_sieve_compile_buffer): New
function.
* mailbox/header.c: Fix indentation.
2008-03-15 Sergey Poznyakoff <gray@gnu.org.ua>
* libargp/tls.c (_tls_argp_parser): Take care not to pass NULL as
the argument to the "tls" statement.
2008-03-07 Sergey Poznyakoff <gray@gnu.org.ua>
* comsat/comsat.c, imap4d/imap4d.c, imap4d/preauth.c,
libargp/sieve.c, libcfg/ldap.c, libcfg/sieve.c: Fix translatable
strings.
2008-03-07 Sergey Poznyakoff <gray@gnu.org.ua>
* configure.ac: Require gettext 0.17
* auth/ldap.c, auth/radius.c, libargp/tls.c, mailbox/cfg_lexer.c,
pop3d/logindelay.c: Fix diagnostic messages.
2008-03-03 Sergey Poznyakoff <gray@gnu.org.ua>
* maidag/maidag.c (main): Fix autodetection of log_to_stderr.
* maidag/deliver.c, maidag/maidag.h, maidag/mailtmp.c: Rename
mailer_err to maidag_error.
* maidag/util.c (mailer_err): Rename to maidag_error. Print to
stderr only if log_to_stderr is set.
Fix bootstrapping with gettext 0.17.
* bootstrap.conf (avoided_gnulib_modules): Remove size_max
(excluded_files): Remove m4/size_max.m4.
(gnulib_extra_files): Add m4/inttostr.m4
* gnulib.modules: Add intprops and stdint.
* m4/intmax.m4, m4/intmax_t.m4, m4/inttostr.m4, m4/inttypes-h.m4,
m4/inttypes-pri.m4, m4/inttypes.m4, m4/inttypes_h.m4: Remove
2008-03-02 Sergey Poznyakoff <gray@gnu.org.ua>
* bootstrap.conf (XGETTEXT_OPTIONS): Update flags.
* configure.ac, NEWS: Version 1.9.90
* m4/.cvsignore: Add environ.m4
* po/ca.po, po/es.po, po/fr.po, po/pl.po, po/ro.po, po/ru.po,
po/rw.po, po/sv.po, po/uk.po, po/LINGUAS, po/ChangeLog: Remove.
We will get po files directly from translationproject.org.
2008-03-01 Sergey Poznyakoff <gray@gnu.org.ua>
* mh/folder.c, mh/mh_argp.c, mh/mh_getopt.c, mh/mh_init.c,
mh/rmf.c: Use mu_program_name instead of
program_invocation_short_name.
2008-02-29 Sergey Poznyakoff <gray@gnu.org.ua>
* mh/mh_ctx.c (mh_context_read): Allow for header continuation
lines.
* mh/mh_whom.c (mh_whom): Improve diagnostics.
2008-02-28 Sergey Poznyakoff <gray@gnu.org.ua>
* examples/Makefile.am (AM_LDFLAGS): Remove.
(LDADD): Add the necessary libraries.
(aclck_LDADD, argcv_LDADD): Remove.
(muemail_LDADD): Needs MU_APP_LIBRARIES.
2008-02-26 Sergey Poznyakoff <gray@gnu.org.ua>
* libcfg/init.c: Fix error reporting.
* mailbox/cfg_driver.c (mu_parse_config): Fix memory leak.
2008-02-21 Sergey Poznyakoff <gray@gnu.org.ua>
* libsieve/load.c: Add forward declaration of _add_load_dir
* mailbox/parsedate.y (DATE_SET): Fix bug introduced 2008-01-02:
val can sometimes be negative.
* examples/Makefile.am (aclck_LDADD): Define.
2008-02-09 Sergey Poznyakoff <gray@gnu.org.ua>
* comsat/comsat.c (comsat_cfg_param): Reword a help message
for require-tty.
* examples/header.c (cmd_readline): New function.
New command 'readline'.
* po/POTFILES.in: Remove stray reference to muerrno.c
2008-02-08 Sergey Poznyakoff <gray@gnu.org.ua>
* comsat/action.c (act_getline): Bugfix. Do not return eof
on an empty line. Reported by Damon Harper.
2008-02-06 Sergey Poznyakoff <gray@gnu.org.ua>
* examples/pop3client.c: Implement variable expansions in the
prompt.
* NEWS: Update.
* pop3d/bulletin.c (read_bulletin_db): Return success if db does
not exist.
* lib/strexit.c: New file.
* lib/signal.c: New file.
2008-02-05 Sergey Poznyakoff <gray@gnu.org.ua>
* pop3d/extra.c (pop3d_readline): After a failed authorization
attempt many clients simply disconnect without issuing QUIT.
Do not count this as a protocol error.
* NEWS: Update.
* imap4d/bye.c, imap4d/starttls.c, imap4d/util.c: Use exit codes
from sysexits.h
* imap4d/imap4d.c: Use mu_set_signals to install signals.
Use exit codes from sysexits.h.
* imap4d/imap4d.h: Include sysexits.h and muaux.h
(ERR_TERMINATE): New define.
(imap4d_sigchld,imap4d_signal): Remove.
(imap4d_master_signal,imap4d_child_signal): New prototypes.
* imap4d/signal.c (imap4d_master_signal,imap4d_child_signal): New
functions.
* pop3d/pop3d.h Include sysexits.h and muaux.h
(ERR_TERMINATE): New define.
(pop3d_signal): Remove.
(pop3d_master_signal, pop3d_child_signal): New protos.
* pop3d/signal.c (pop3d_master_signal, pop3d_child_signal): New
functions.
* pop3d/extra.c, pop3d/popauth.c
* pop3d/pop3d.c: Use mu_set_signals to install signals.
Use exit codes from sysexits.h.
* include/mailutils/server.h (mu_m_server_set_strexit): New
prototype.
* include/mailutils/types.hin (MU_ARRAY_SIZE): New define.
* lib/Makefile.am (libmuaux_la_SOURCES): Add signal.c, strexit.c.
(noinst_HEADERS): Add muaux.h
* lib/muaux.h: New file.
* libsieve/extensions/spamd.c: Add NLS markers.
* mailbox/header.c (header_readline): Minor rewrite.
* mailbox/msrv.c (struct _mu_m_server): New member `strexit'.
(mu_m_server_begin): Call alloc_children.
(mu_m_server_restore_signals): New function.
(mu_m_server_end): Call mu_m_server_restore_signals.
(m_srv_conn): Reset signals in child branch.
* po/POTFILES.in: Update.
* mailbox/header.c (header_readline): Bugfix: account for
multi-line headers.
* imap4d/list.c (imap4d_list): Speed up LIST "" INBOX.
* libproto/imap/folder.c (folder_imap_list): Remove erroneous
assignments to f_imap->folder.
Fix handling of remote mailboxes in clients:
* libproto/imap/url.c (_url_imap_init,_url_imaps_init): Remove
call to mu_url_init.
* libproto/pop/url.c (_url_pop_init): Remove call to mu_url_init.
* mailbox/mailbox.c (mailbox_folder_create): Bugfix: Lack of path
component is not an error.
2008-02-04 Sergey Poznyakoff <gray@gnu.org.ua>
* mailbox/msrv.c (struct _mu_m_server): New member `num_children'.
New member `child_pid'.
(children): Remove global.
(m_server_list): New variable. Keeps track of created m_servers.
(alloc_children, register_child, unregister_child)
(terminate_children): New functions.
(m_server_cleanup): New function.
(mu_m_server_idle): Iterate over all registered m-servers until
one of them recognizes the child.
(mu_m_server_create,mu_m_server_destroy): Keep track of existing
m-servers using m_server_list.
(mu_m_server_set_max_children): Rewrite using alloc_children.
(mu_m_server_run): Terminate all children before returning.
(m_srv_conn): Use register_child to remember created children.
* NEWS: Update.
* examples/header.c: New command `itr'.
(main): Empty input repeats the recent command.
* include/mailutils/header.h (mu_header_get_iterator): New
function.
* libproto/include/header0.h (struct _mu_header): New member itr.
* mailbox/Makefile.am (libmailutils_la_SOURCES): Add hdritr.c
* mailbox/hdritr.c: New file.
* mailbox/header.c (mu_header_remove): Bugfix. Invalidate the
header after removal.
2008-01-31 Sergey Poznyakoff <gray@gnu.org.ua>
* auth/radius.c (_expand_query): Fix typo.
* mailbox/cfg_lexer.c (copy_string0): New function.
(copy_string): Rewrite using copy_string0.
(copy_to): Parse strings correctly.
(default_lexer): Bugfix. Return string if tag is quoted.
2008-01-28 Sergey Poznyakoff <gray@gnu.org.ua>
* pop3d/bulletin.c (open_bulletin_mailbox): Bugfix.
2008-01-24 Sergey Poznyakoff <gray@gnu.org.ua>
* mailbox/cfg_driver.c (mu_cfg_section_add_params): Initialize
section.target with param->data;
* mailbox/stream.c (mu_stream_vprintf): Bugfix.
2008-01-22 Sergey Poznyakoff <gray@gnu.org.ua>
* examples/listop.c (find): Fix copy-n-paste error.
(iter): Return error code.
(main): Create iterators on demand.
New command `close'.
* mailbox/iterator.c (mu_iterator_detach): Bugfix.
2008-01-16 Sergey Poznyakoff <gray@gnu.org.ua>
* include/mailutils/acl.h, include/mailutils/debug.hm4,
mailbox/acl.c (mu_sockaddr_to_str, mu_sockaddr_to_astr)
(mu_acl_check_sockaddr, mu_acl_check_inaddr): Use const pointers
when appropriate.
* include/mailutils/cfg.h (mu_offsetof): Move mu_offsetof to
types.hin.
* include/mailutils/types.hin (mu_offsetof): New macro.
* mailbox/acl.c (MU_S_UN_NAME): New macro.
(debug_sockaddr, mu_sockaddr_to_str, _acl_match)
(_run_entry): Take into account salen for AF_UNIX.
2008-01-14 Sergey Poznyakoff <gray@gnu.org.ua>
* include/mailutils/gocs.h (log_facility): Remove.
* include/mailutils/syslog.h (mu_log_facility, mu_log_tag): New
declarations.
(MU_LOG_TAG): New define.
* mailbox/gocs.c (mu_gocs_logging_init): Set mu_log_tag.
* mailbox/syslog.c (mu_log_facility, mu_log_tag): New variables.
* libcfg/common.c (mu_logging_param): New statement `tag'.
* comsat/comsat.c, imap4d/imap4d.c, imap4d/login.c,
maidag/maidag.c, mail.local/main.c, pop3d/pop3d.c, pop3d/user.c,
sieve/sieve.c: Use MU_LOG_TAG in openlog, and
program_version in mu_m_server_create calls.
* libsieve/conf.c (mu_sieve_module_init): Remove initial call to
_path_append.
* libsieve/load.c (sieve_init_load_path): New function.
(load_module,sieve_load_add_path,sieve_load_add_dir): Call
sieve_init_load_path.
* mail.local/main.c (parse_opt): Bugfix. Translate -S option to
sieve-filter configuration statement.
2008-01-13 Sergey Poznyakoff <gray@gnu.org.ua>
Fix NLS issues.
* configure.ac: Define DEFAULT_TEXT_DOMAIN
* comsat/comsat.c, dotlock/dotlock.c, frm/frm.c, frm/from.c,
guimb/main.c, imap4d/imap4d.c, maidag/maidag.c, mail/mail.c,
mail.local/main.c, mail.remote/mail.remote.c, messages/messages.c,
mh/ali.c, mh/anno.c, mh/burst.c, mh/comp.c, mh/fmtcheck.c,
mh/folder.c, mh/forw.c, mh/inc.c, mh/install-mh.c, mh/mark.c,
mh/mhl.c, mh/mhn.c, mh/mhparam.c, mh/mhpath.c, mh/pick.c,
mh/refile.c, mh/repl.c, mh/rmf.c, mh/rmm.c, mh/scan.c, mh/send.c,
mh/sortm.c, mh/whatnow.c, mh/whom.c, mimeview/mimeview.c,
movemail/movemail.c, pop3d/pop3d.c, pop3d/popauth.c,
readmsg/readmsg.c, sieve/sieve.c,
Use MU_APP_INIT_NLS instead of mu_init_nls.
* mailbox/nls.c (mu_init_nls): Do not call textdomain.
* guimb/guimb.h, guimb/util.c (util_error): fmt is const.
* include/mailutils/debug.hm4: include <mailutils/error.h>
* include/mailutils/nls.h: Define _ and N_ only if
DEFAULT_TEXT_DOMAIN is defined (for use in the library).
* maidag/maidag.h, maidag/util.c (mailer_err) : fmt is const.
* mail.local/mail.local.h (mailer_err): All mandatory args are
consts.
* mailbox/msrv.c: Include limits.h
2008-01-12 Sergey Poznyakoff <gray@gnu.org.ua>
* NEWS, configure.ac: Version 1.2.91.
* mailbox/gdebug.c (mu_debug_level_from_string): Bugfix.
2008-01-09 Sergey Poznyakoff <gray@gnu.org.ua>
* auth/ldap.c (_mu_ldap_search): Provide %u expansion for backward
compatibility with other modules.
* auth/radius.c, auth/sql.c: Use mu_vartab_t for expansion.
* include/mailutils/mailutils.h: Include mailutils/assoc.h
* lib/tcpwrap.c (mu_tcpwrapper_access): Ignore local sockets.
* libargp/muinit.c (mu_app_init): Re-assign mu_program_name after
command line parsing, so that --program-name takes effect.
* libcfg/sql.c (mu_sql_param): Fix typo in statement name.
* libproto/include/amd.h (struct _amd_message.create): New member.
* libproto/maildir/mbox.c (maildir_create): New function.
(_mailbox_maildir_init): Set amd->create.
* mailbox/amd.c (amd_open): Call amd->create after successfully
creating the directory.
* mailbox/cfg_driver.c (_cb_include): Mask out
MU_PARSE_CONFIG_GLOBAL in the flags.
(mu_build_container): Bugfix. Take struct include_data as
argument, instead of using an auto variable. All callers updated.
* mailbox/ipsrv.c (mu_ip_tcp_accept): Bugfix: use client address,
not server, to print diagnostics.
* mailbox/msrv.c (m_srv_conn): Fix prefork condition for
single-process mode.
* TODO: Update.
* include/mailutils/server.h (mu_m_server_set_foreground)
(mu_m_server_foreground,mu_m_server_pidfile)
(mu_m_server_set_default_address)
(mu_m_server_get_srvlist)
(mu_m_server_get_default_address): New functions.
* libargp/muinit.c (get_canonical_name): Do not use xmalloc.
* mailbox/ipsrv.c (mu_ip_server_get_sockaddr): Return
MU_ERR_BUFSPACE if provided buffer is not long enough to
accommodate the result.
* mailbox/msrv.c (mu_m_server_set_foreground)
(mu_m_server_foreground,mu_m_server_pidfile)
(mu_m_server_set_default_address)
(mu_m_server_get_srvlist)
(mu_m_server_get_default_address)
(mu_m_server_parse_url): New functions.
2008-01-06 Sergey Poznyakoff <gray@gnu.org.ua>
Fix message delivery to maildir boxes.
* libproto/include/amd.h (struct _amd_message): Remove `deleted',
add `orig_flags' instead.
(struct _amd_data): Remove `msg_file_name', add `cur_msg_file_name'
and `new_msg_file_name'.
Add `mailbox_size'.
* libproto/maildir/mbox.c (struct _maildir_message): Remove
`newflag', add `dir'.
(maildir_name_info_ptr): New function.
(mk_info_filename): Bugfix.
(maildir_cur_message_name, maildir_new_message_name): New
functions.
(maildir_msg_init): Set ->dir
(maildir_msg_finish_delivery): Handle error conditions.
(maildir_scan_dir): New argument `dirname'. Initialize orig_flags.
(maildir_qfetch): Initialize dir.
(_mailbox_maildir_init): Set cur_msg_file_name and
new_msg_file_name.
* libproto/mh/mbox.c (_mh_cur_message_name)
(_mh_new_message_name): New functions.
(mh_scan0): Initialize orig_flags.
(_mailbox_mh_init): Set cur_msg_file_name and
new_msg_file_name.
* mailbox/amd.c (amd_message_qid, _amd_message_save)
(amd_append_message, amd_expunge, amd_scan_message)
(amd_pool_open, amd_header_fill): Use appropriate msg_file_name
functions.
(amd_get_size): Implemented.
* mailbox/mailbox.c (mu_mailbox_flush): Bugfix.
2008-01-05 Sergey Poznyakoff <gray@gnu.org.ua>
* NEWS: Update.
* mailbox/Makefile.am: Replace tcpsrv.c with ipsrv.c.
* mailbox/tcpsrv.c: Replace with ...
* mailbox/ipsrv.c: ... this file, which supports both TCP and UDP.
* mailbox/msrv.c: Use mu_ip_server_t.
* mailbox/server.c (mu_server_destroy): Bugfix.
* comsat/comsat.c, comsat/comsat.h: Use m-server.
* maidag/lmtp.c, maidag/maidag.h, pop3d/pop3d.c: Update to match
changed m-server types.
* include/mailutils/server.h (mu_tcp_*): Replace with mu_ip_*.
Add new prototypes.
* include/mailutils/types.hin: Likewise.
* lib/tcpwrap.c, lib/tcpwrap.h (mu_tcp_wrapper_prefork): Update
signature to match mu_m_server_prefork_fp.
* examples/echosrv.c: Use mu_ip_server_t
* imap4d/idle.c, imap4d/imap4d.c, imap4d/imap4d.h,
imap4d/preauth.c, imap4d/util.c: Remove mu_gocs_daemon.
* include/mailutils/gocs.h, include/mailutils/libargp.h,
include/mailutils/libargp.h, libargp/cmdline.c,
libargp/common.c, libcfg/common.c, libcfg/init.c,
mailbox/daemon.c, mailbox/gocs.c: Remove mu_gocs_daemon.
* mailbox/amd.c (amd_open): Provide a null-locker.
* include/mailutils/locker.h, mailbox/locker.c
(mu_locker_mod_flags): New function.
* examples/config/mailutils.schema: LDAP schema for Mailutils.
* examples/config/Makefile.am: Add mailutils.schema
* dotlock/dotlock.c (main): Remove superfluous invocation of
mu_locker_set_flags.
* libproto/mbox/mbox.c (mbox_quick_get_message): Return
MU_ERR_NOENT if mailbox is empty.
* mailbox/tcpsrv.c (family_to_proto): Rename to
mu_address_family_to_domain.
* po/POTFILES.in: Update.
* pop3d/lock.c (pop3d_lock): use mu_locker_mod_flags, instead of
mu_locker_set_flags.
* include/mailutils/server.h (mu_m_server_prefork_fp): New
function type.
(mu_m_server_destroy, mu_m_server_set_prefork)
(mu_m_server_configured_count, mu_m_server_end): New functions.
* mailbox/msrv.c (struct _mu_m_server.prefork): New member.
(mu_m_server_set_prefork): New function.
(m_srv_conn): Use prefork to decide whether to proceed with a
connection.
* lib/tcpwrap.c, lib/tcpwrap.h (mu_tcp_wrapper_prefork): New
function.
* imap4d/imap4d.c, maidag/lmtp.c, maidag/maidag.c,
pop3d/pop3d.c: Use m-server prefork to handle TCP wrappers.
* po/POTFILES.in: Add more files.
2008-01-04 Sergey Poznyakoff <gray@gnu.org.ua>
* TODO, NEWS: Update.
* mailbox/msrv.c: New file.
* mailbox/Makefile.am: Add msrv.c.
* include/mailutils/server.h (mu_tcp_server_conn_fp): Take
sockaddr as argument
(mu_tcp_server_create,mu_tcp_server_get_sockaddr): Likewise.
(mu_m_server_*): New prototypes.
* include/mailutils/types.hin (mu_m_server_t): New type.
* mailbox/acl.c: Fix debugging output.
(mu_sockaddr_to_str, mu_sockaddr_to_astr): New functions.
* mailbox/tcpsrv.c: Handle AF_INET and AF_UNIX sockets.
* examples/echosrv.c: Update mu_tcp_server_* calls.
* examples/config/Makefile.am: Remove comsat.conf and
mailutils.rc.
* imap4d/imap4d.c, imap4d/imap4d.h, imap4d/signal.c,
maidag/lmtp.c, maidag/maidag.c, maidag/maidag.h, pop3d/extra.c,
pop3d/pop3d.c, pop3d/pop3d.h, pop3d/signal.c: Rewrite using
m-server.
* include/mailutils/cfg.h (mu_offsetof): Bug fix.
* mailbox/cfg_driver.c (dup_container): Bugfix. Offset was not
copied.
(mu_cfg_section_add_params): If identifier starts with a dot, it
is hidden, i.e. its substatements are copied directly into the
parent structure.
* mailbox/cfg_lexer.c (isword): Take care of opening braces.
(default_lexer): Several fixes.
* mailbox/cfg_parser.y (mu_cfg_parse): Initialize debugging level
from global settings.
(_scan_tree_helper): Ensure debugging object has correct locus
information before calling the section parser.
(mu_cfg_scan_tree): If no debugging object is supplied, use the
one from diag.c
* mailbox/daemon.c (mu_daemon_create_pidfile): Return a meaningful
error code.
* mailbox/debug.c (mu_debug_create): Initialize printer to NULL.
(mu_debug_vprintf): If printer is NULL, use
mu_debug_default_printer.
(mu_debug_check_level): Bugfix.
* mailbox/server.c: Minor indentation fix.
* mailbox/syslog.c (mu_diag_syslog_printer): Chop off \r as well.
* mailbox/folder.c (mu_folder_create_from_record): Bugfixes.
* include/mailutils/debug.hm4 (mu_sockaddr_to_str)
(mu_sockaddr_to_astr): New functions.
* include/mailutils/.cvsignore: Add debug.h
* po/POTFILES.in: Update.
2008-01-02 Sergey Poznyakoff <gray@gnu.org.ua>
* include/mailutils/property.h: Update
* libproto/include/property0.h (struct property_item): Remove
key, set and next.
(struct _mu_property): Use mu_assoc_t to keep the items.
* mailbox/property.c: Rewrite using mu_assoc_t for storage.
* mailbox/parsedate.y (DATE_SET): Take an additional argument
specifying upper limit for the value. Bail out if val is out of
range. All callers updated.
(SET_.*): Rewrite via __SET_.*
2007-12-30 Sergey Poznyakoff <gray@gnu.org.ua>
* comsat/comsat.c: New config statement require-tty.
(main): Use /dev/null as the tty if require-tty is false.
* examples/config/comsat.conf: Remove obsolete example file.
* examples/config/mailutils.rc: Remove obsolete example file.
* comsat/oldcfg.c: New file.
* comsat/Makefile.am: Add oldcfg.c.
* comsat/comsat.c: Handle old -c option and provide a new option
for converting old-style config file to the new format.
* comsat/Makefile.am: Remove cfg.c
* comsat/cfg.c: Remove.
* comsat/comsat.c: Use MU configuration and acls.
* comsat/comsat.h: Include acl.h
* libproto/maildir/mbox.c (maildir_qfetch): Bugfix.
* NEWS: Update.
* frm/testsuite/frm/test.exp: Call mu_init with -noflags option.
Use --mail-folder option when necessary.
* messages/testsuite/messages/test.exp: Likewise.
* readmsg/testsuite/readmsg/test.exp: Likewise.
* sieve/testsuite/lib/sieve.exp: Likewise.
* sieve/testsuite/sieve/action.exp: Likewise.
* sieve/testsuite/scripts/fileinto.sv: Use +file, instead of
%file.
* imap4d/imap4d.c: Register mailbox formats before parsing
configuration.
* imap4d/util.c (util_wcard_match): Replaced with a more efficient
implementation, based on wildmat from GNU Radius.
* imap4d/testsuite/imap4d/list.exp: Expect two non-mailbox files
to appear in the list output (see libproto/mbox/folder.c, 2007-12-28).
* libargp/common.c: New option --mail-folder.
* libcfg/common.c: New statement mailbox/folder
* libproto/maildir/folder.c (_maildir_is_scheme): Never return
MU_FOLDER_ATTRIBUTE_DIRECTORY bit: maildir folders cannot contain
subfolders.
* libproto/maildir/mbox.c (maildir_msg_init): Bugfix: use full
file name.
Print additional diagnostics if stat fails.
* libproto/mbox/folder.c (list_helper): Take additional argument,
record, specifying a mu_record_t object to match entries
against. If it is NULL, mu_registrar_lookup is used.
Fix descending into subdirectories.
* maidag/deliver.c (deliver): Split off deliver_to_user function;
call it with user privileges. This fixes privileges of any created
maildir folders.
* maidag/maidag.c (set_debug_flags): Bugfix.
* mail/mail.c (main): Open the mailbox with MU_STREAM_CREAT flag.
* mailbox/amd.c (amd_open): Do not initialize amd->mtime to
trigger initial scanning.
(_amd_message_save): Check rename return value.
(amd_is_updated): Do not check for msg_count==0, rely on the
timestamp.
* mailbox/mailbox.c (mu_mailbox_set_default_proto): Accept an
argument without trailing semicolon.
* mailbox/mbx_default.c (mu_set_mail_directory): Accept NULL
argument.
(mu_set_mailbox_pattern): Likewise.
(mu_mailbox_create_default): Use FOLDER or MAIL environment
variables only if _mu_mailbox_pattern is not set. In other words,
setting mail-spool in the configuration file overrides these
variables.
2007-12-28 Sergey Poznyakoff <gray@gnu.org.ua>
Additional mailbox URL parameters `type', `user' and `param' can
appear in any local URLs.
* TODO, NEWS: Update.
* examples/url-parse.c: Print field/value pairs.
* include/mailutils/argcv.h (MU_ARGCV_RETURN_DELIMS): New macro.
(mu_argcv_get_np): New function.
(mu_argcv_remove): New function.
* include/mailutils/mutil.h (mu_scheme_autodetect_p): Change
prototype.
* include/mailutils/registrar.h (mu_registrar_lookup_url): New
function.
(struct _mu_record._is_scheme): Change signature.
* include/mailutils/url.h (mu_url_sget_fvpairs)
(mu_url_aget_fvpairs): New functions.
(mu_url_expand_path): New function.
* libproto/imap/folder.c (folder_imap_list): Fix signature.
* libproto/nntp/folder.c (nntp_folder_list): Fix signature.
* libproto/include/amd.h (amd_url_init): Remove.
* libproto/include/registrar0.h: Fix scheme defines.
* libproto/include/url0.h (struct _mu_url.fvpairs,fvcount): New
members.
* libproto/maildir/folder.c (_maildir_is_scheme): Change
signature.
(_maildir_url_init): Remove
(_maildir_record): Remove url_init.
* libproto/mbox/folder.c (_path_record): Remove url_init.
(_mbox_record): Use mu_url_expand_path as url_init.
(_path_is_scheme): Change signature.
* libproto/mh/folder.c (_mh_is_scheme): Change signature.
(_mh_url_init): Remove.
(_mh_record): Use
mu_url_expand_path as url_init.
* libproto/mbox/Makefile.am (libmu_mbox_la_SOURCES): Remove url.c
* libproto/mbox/url.c: Remove.
* mail/mail.h, mail/util.c (util_url_to_string): New function.
* mail/quit.c, mail/summary.c: Use util_url_to_string where
appropriate.
* mailbox/amd.c (amd_url_destroy, amd_url_init): Remove.
* mailbox/argcv.c (mu_argcv_get_np): New function.
(argcv_scan): Change signature. All callers updated.
(argcv_get_n): Rewrite using argcv_get_np.
(mu_argcv_remove): New function.
* mailbox/file_stream.c (struct _prog_stream.argc): Fix data type.
* mailbox/folder.c (mu_folder_create_from_record): URL initializer
is optional.
* mailbox/gdebug.c (mu_global_debug_from_string): Fix datatype of
argc.
* mailbox/mailbox.c (mailbox_folder_create): Rewrite.
(_create_mailbox): Split off _create_mailbox0 function.
Make URL initializer optional.
* mailbox/mutil.c (mu_scheme_autodetect_p): Rewrite.
* mailbox/registrar.c (mu_registrar_lookup_url): New function.
(mu_registrar_lookup): Rewrite using mu_registrar_lookup_url.
(mu_record_is_scheme,mu_record_set_is_scheme): Change signature.
* mailbox/url.c (mu_url_destroy): Destroy fvpairs.
(url_parse0): Use scheme "file" for URLs beginning with a /.
Parse parameters.
(mu_url_sget_fvpairs, mu_url_aget_fvpairs): New functions.
(mu_url_expand_path): New function.
* mailbox/testsuite/Urls: Update.
* pop3d/bulletin.c (set_bulletin_db,set_bulletin_source): Allocate
string storage.
(read_bulletin_db): Return 0 if no record was found.
(get_last_delivered_num): Return error code.
(deliver_pending_bulletins): Rewrite.
* pop3d/capa.c (pop3d_capa): Bugfix.
2007-12-21 Sergey Poznyakoff <gray@gnu.org.ua>
* examples/lsf.c: Use mu_folder_enumerate + callback function, for
speed up.
* imap4d/imap4d.h (WCARD_NOMATCH,WCARD_MATCH)
(WCARD_RECURSE_MATCH): Remove.
* imap4d/list.c: Rewrite using mu_folder_enumerate.
* imap4d/lsub.c (imap4d_lsub): Fix call to util_wcard_match.
* imap4d/util.c (util_wcard_match): Return 0 for match, 1
otherwise.
* imap4d/testsuite/imap4d/list.exp: Fix two testcases to match
the new (stricter RFC-compliant) behavior.
* include/mailutils/folder.h (mu_folder_match_fp): New typedef.
(mu_folder_enumerate_fp): New typedef.
(mu_folder_enumerate): New function.
(mu_folder_set_match, mu_folder_get_match): New functions.
* libproto/imap/folder.c, libproto/include/imap0.h,
libproto/nntp/folder.c : Use new folder list framework.
* libproto/include/folder0.h (struct _mu_folder._list): Change
signature.
(_match): New member.
* libproto/mbox/folder.c (_path_is_scheme): Improve automatic
mailbox format detection.
(folder_mbox_list): Do not use glob, recursively scan
subdirectories instead.
* mailbox/folder.c (mu_folder_match): New function.
(mu_folder_create_from_record): Set mu_folder_match as the default
matcher.
(mu_folder_set_match, mu_folder_get_match): New functions.
(mu_folder_enumerate): New function.
(mu_folder_list): Rewrite using mu_folder_enumerate.
2007-12-19 Sergey Poznyakoff <gray@gnu.org.ua>
* NEWS: Update.
* configure.ac (MU_LIB_REMOTE): New substitution variable.
(AC_CONFIG_FILES): Add libproto/remote/Makefile.
* imap4d/copy.c, imap4d/create.c, imap4d/delete.c, imap4d/fetch.c,
imap4d/imap4d.c, imap4d/list.c, imap4d/lsub.c, imap4d/rename.c,
imap4d/subscribe.c, imap4d/unsubscribe.c, imap4d/util.c: Spelling
fixes.
* include/mailutils/cfg.h (mu_cfg_error_count): New variable.
* include/mailutils/gocs.h (struct mu_gocs_mailbox): New member
mailbox_pattern
* include/mailutils/libargp.h (mu_rcfile_lint): New variable.
* include/mailutils/mailbox.h (mu_set_mailbox_pattern): New
function.
(mu_mail_directory): Removed.
(mu_mailbox_url): New function.
* include/mailutils/mutil.h (mu_normalize_mailbox_url): Remove.
* include/mailutils/registrar.h (mu_0_6_registrar_lookup): Remove.
* libargp/common.c: New options --rcfile-lint and
--mailbox-pattern.
* libargp/muinit.c: Handle --rcfile-lint.
* libcfg/common.c: New statement mailbox-pattern
* libmu_scm/mu_mailbox.c (mu-mail-directory): Deprecated.
(mu-user-mailbox-url): New function.
* libproto/remote: New directory.
* libproto/remote/folder.c: New file.
* libproto/remote/mbox.c: New file.
* libproto/remote/.cvsignore: New file.
* libproto/Makefile.am (SUBDIRS): Add remote
* libproto/mbox/folder.c, libproto/mbox/url.c: Indentation and
spelling fixes.
* maidag/Makefile.am (maidag_LDADD): Add MU_LIB_REMOTE.
* maidag/maidag.c: Register mu_remote_mbox_record.
* mailbox/cfg_parser.y (mu_cfg_error_count): New variable.
(mu_cfg_format_error,_mu_cfg_vperror): Increment
mu_cfg_error_count.
* mailbox/debug.c (mu_debug_check_level): Do not mask out
inheritance bit.
* mailbox/gocs.c (mu_gocs_mailbox_init): Set mailbox pattern.
* mailbox/mailbox.c (_create_mailbox): Bugfix.
* mailbox/mbx_default.c (mu_set_mailbox_pattern): New function.
(mu_set_mail_directory): Rewrite.
(user_mailbox_name): Rewrite.
* mailbox/mutil.c (mu_normalize_mailbox_url): Remove.
* mailbox/registrar.c (mu_0_6_registrar_lookup): Remove.
* guimb/scm/sieve-core.scm (sieve-main): Use mu-user-mailbox-url.
2007-12-15 Sergey Poznyakoff <gray@gnu.org.ua>
* libcfg/acl.c (getword): Bugfix.
* maidag/lmtp.c, maidag/maidag.c, maidag/maidag.h: Use ACLs.
* pop3d/pop3d.c (pop3d_cfg_param): Add acl section.
2007-12-13 Sergey Poznyakoff <gray@gnu.org.ua>
* examples/aclck.c, examples/addr.c, examples/base64.c,
examples/decode2047.c, examples/echosrv.c, examples/encode2047.c,
examples/header.c, examples/http.c, examples/iconv.c,
examples/listop.c, examples/lsf.c, examples/mailcap.c,
examples/mimetest.c, examples/msg-send.c, examples/muemail.c,
examples/murun.c, examples/nntpclient.c, examples/pop3client.c,
examples/sfrom.c, examples/url-parse.c: Include config.h. Use
MU_ASSERT instead of assert.
* include/mailutils/cfg.h (struct mu_cfg_section.offset): New
member.
* include/mailutils/debug.hm4 (MU_ASSERT): New member.
* lib/utmp.c: Include config.h.
* libcfg/Makefile.am (libmucfg_la_SOURCES): Add acl.c.
* libcfg/acl.c: New file.
* libcfg/common.c (cb_debug_level): Immediately set debugging
level.
* mailbox/acl.c: mu_acl_log expands its argument.
* mailbox/cfg_driver.c (mu_create_canned_section)
(mu_create_canned_param): Avoid creating container twice.
* mailbox/cfg_format.c (format_param): Do not print type if
argname contains a colon.
* mailbox/cfg_parser.y (_scan_tree_helper): Compute target
pointer.
* imap4d/imap4d.c, imap4d/imap4d.h, pop3d/pop3d.c,
pop3d/pop3d.h: Use MU ACLs
2007-12-11 Sergey Poznyakoff <gray@gnu.org.ua>
* comsat/comsat.c, imap4d/imap4d.c, maidag/maidag.c,
pop3d/pop3d.c: Call mu_tcpwrapper_cfg_init.
* include/mailutils/cfg.h (mu_cfg_section_add_container)
(mu_cfg_section_add_params, mu_create_canned_section)
(mu_create_canned_param, mu_get_canned_container): New functions.
* lib/tcpwrap.c (mu_tcpwrapper_cfg_init): New function.
* lib/tcpwrap.h (TCP_WRAPPERS_CONFIG): Change definition.
* mailbox/cfg_driver.c (mu_create_canned_section)
(mu_create_canned_param): Change prototypes.
(add_parameters): Rename to mu_cfg_section_add_params, make
extern. All callers changed.
* include/mailutils/cfg.h (mu_cfg_section): New type.
(struct mu_cfg_param.offset): New member
(mu_offsetof): New define
(mu_cfg_section_fp): Change signature
(struct mu_cfg_section.label,target): New members.
(struct mu_cfg_section.data): Remove.
(struct mu_cfg_section.children): New member, instead of
param and subsec which are removed.
(mu_cfg_scan_tree): Change signature.
(mu_config_register_section): Change signature.
(mu_parse_config): Change signature.
(mu_parse_config_tree): Rename to mu_cfg_tree_reduce.
(mu_get_config): New proto.
* include/mailutils/libcfg.h (mu_parse_config_files): Change
prototype.
* dotlock/dotlock.c, imap4d/imap4d.c, lib/tcpwrap.h,
libargp/muinit.c, libcfg/auth.c, libcfg/common.c, libcfg/gsasl.c,
libcfg/init.c, libcfg/ldap.c, libcfg/pam.c, libcfg/radius.c,
libcfg/sieve.c, libcfg/sql.c, libcfg/tls.c, libcfg/virtdomain.c,
maidag/maidag.c, mail.local/main.c, mail.remote/mail.remote.c,
mailbox/cfg_format.c, mailbox/cfg_parser.y, mimeview/mimeview.c,
movemail/movemail.c, pop3d/pop3d.c, readmsg/readmsg.c,
sieve/sieve.c: Reflect changes to the cfg framework.
* mailbox/Makefile.am (libmailutils_la_SOURCES): Add cfg_driver.c.
* mailbox/cfg_driver.c: New file.
* mailbox/cfg_lexer.c: Move driver part into a separate file.
* examples/Makefile.am (AM_LDFLAGS): Remove libmuaux
* examples/echosrv.c: Remove getopt.h
2007-12-09 Sergey Poznyakoff <gray@gnu.org.ua>
* examples/Makefile.am: add echosrv.c.
* examples/echosrv.c: New file.
* include/mailutils/Makefile.am: Add server.h.
* include/mailutils/server.h: New file.
* include/mailutils/acl.h (mu_acl_t): Move to types.hin
* include/mailutils/types.hin (mu_acl_t,mu_server_t)
(mu_tcp_server_t): New types.
* mailbox/Makefile.am: Add server.c and tcpsrv.c.
* mailbox/server.c: New file.
* mailbox/tcpsrv.c: New file.
* mailbox/acl.c: Include <sys/wait.h>
Rename all `sin' and `sun' to avoid name clashes.
* mailbox/errors (MU_ERR_LOCK_EXT_FAIL): Do not abbreviate
anything in error description.
* auth/ldap.c (_construct_attr_array): Use mu_vartab_* to expand
filter.
* imap4d/preauth.c: Fix misleading comment.
* mailbox/vartab.c (mu_vartab_expand): Support old prefix (%) for
single-character variables.
2007-12-07 Sergey Poznyakoff <gray@gnu.org.ua>
* NEWS, TODO: Update.
* examples/Makefile.am: Add aclck
* examples/aclck.c: New file. Test program for ACLs.
* include/mailutils/Makefile.am (pkginclude_HEADERS): Add acl.h,
kwd.h and vartab.h.
* include/mailutils/acl.h: New file. ACL declarations.
* include/mailutils/kwd.h: New file. Declarations for simple
string to token conversion.
* include/mailutils/vartab.h: New file. Declarations of functions
for variable expansion.
* include/mailutils/mailutils.h: Include acl.h, kwd.h and
vartab.h.
* include/mailutils/types.hin: Define mu_vartab_t
* mailbox/Makefile.am (libmailutils_la_SOURCES): Add acl.c, kwd.c,
and vartab.c.
* mailbox/acl.c: New file.
* mailbox/kwd.c: New file.
* mailbox/vartab.c: New file.
* mailbox/cfg_parser.y (parse_cidr): Fix typo.
* mailbox/list.c: Fix indentation.
* mailbox/mailbox.c (_create_mailbox): Fix type of level.
* mailbox/syslog.c: Use mu_kwd_* functions.
2007-12-05 Sergey Poznyakoff <gray@gnu.org.ua>
* configure.ac: Add TCP wrappers support.
* imap4d/Makefile.am, mu_daemon_argp_parser (LDADD): Add
TCPWRAP_LIBRARIES.
* imap4d/imap4d.c: Include tcpwrap.h
(imap4d_mainloop): Check the connection using tcp wrappers.
* imap4d/preauth.c: Fix a typo in the comment.
* maidag/maidag.h: Include tcpwrap.h
* maidag/maidag.c, maidag/lmtp.c: Add TCP wrappers support.
* pop3d/pop3d.c: Include tcpwrap.h
(pop3d_mainloop): Check the connection using tcp wrappers.
* lib/Makefile.am: Add tcpwrap.c and tcpwrap.h
* lib/tcpwrap.c: New file.
* lib/tcpwrap.h: New file.
* libargp/common.c (mu_daemon_argp_parser): Bugfix.
2007-12-04 Sergey Poznyakoff <gray@gnu.org.ua>
II. Extend --config-help output. Each configuration parameter
has a docstring which is displayed as a comment before it.
A docstring is also added to the configuration group structure,
for use in future.
* include/mailutils/cfg.h (struct mu_cfg_param): New members
`docstring' and `argname'.
(struct mu_cfg_section): New member `docstring'.
(mu_cfg_format_docstring): New function.
* include/mailutils/libargp.h (mu_help_config_mode): New
declaration.
* libargp/cmdline.h (mu_help_config_mode): Remove.
* libargp/muinit.c (mu_app_init): Better format the initial
comment.
* mailbox/cfg_format.c (mu_cfg_data_type_string): Use NLS.
(mu_cfg_format_docstring): New function.
(format_param,format_section): Use mu_cfg_format_docstring.
* mailbox/cfg_lexer.c (mu_config_create_container): Initialize
allocated memory chunk with zeros.
(dup_container): Duplicate docstring.
(mu_build_container): Document include statement.
* dotlock/dotlock.c, imap4d/imap4d.c, libargp/tls.c,
libcfg/auth.c, libcfg/common.c, libcfg/gsasl.c, libcfg/ldap.c,
libcfg/pam.c, libcfg/radius.c, libcfg/sieve.c, libcfg/sql.c,
libcfg/tls.c, libcfg/virtdomain.c, maidag/maidag.c,
mail.local/main.c, mail.remote/mail.remote.c, mimeview/mimeview.c,
movemail/movemail.c, pop3d/pop3d.c, readmsg/readmsg.c,
sieve/sieve.c: Document configuration file statements.
* pop3d/pop3d.h (expire): Change type to unsigned int.
* po/POTFILES.in: Add missing files.
I. Implement --config-help option, which displays configuration
file statements understood by the given program.
* imap4d/imap4d.h: Include xalloc.h
* frm/common.c, imap4d/imap4d.c: Shut compiler warnings.
* include/mailutils/cfg.h (mu_cfg_format_tree): Rename to
mu_cfg_format_parse_tree.
(mu_cfg_format_container,mu_format_config_tree): New functions.
(mu_parse_config_tree): New prototype.
(mu_cfg_tree_create_node): Change signature (const char* instead
of char*).
* include/mailutils/gocs.h (mu_gocs_register): First arg is const.
* include/mailutils/libargp.h (mu_argp_node_list_new): Mark
invariable arguments as const.
* include/mailutils/libcfg.h (mu_libcfg_init): Remove const from
the arg.
* include/mailutils/mutil.h (mu_spawnvp): Remove const from the
2nd arg.
* libargp/cmdline.c (mu_argp_node_list_new): Mark invariable
arguments as const.
* lib/mailcap.h: New file.
* lib/Makefile.am (libmuaux_la_SOURCES): Add mailcap.h
* libargp/cmdline.h (mu_help_config_mode): New extern.
* libargp/common.c: New option --config-help displays a
configuration file summary.
* libargp/muinit.c (mu_app_init): Handle --config-help.
* libcfg/init.c (mu_libcfg_init): Remove const from the arg.
* maidag/maidag.h (mda): New prototype.
* mail/decode.c: Include mailcap.h
* mail/mail.h: Define _GNU_SOURCE before including stdio.h
* mail/send.c: Fix includes.
* mail.remote/mail.remote.c: Include mu_umaxtostr.h
* mailbox/cfg_format.c (mu_cfg_data_type_string)
(mu_cfg_format_container): New function.
* mailbox/cfg_lexer.c (mu_build_container): New function.
(mu_parse_config_tree): Use mu_build_container.
(mu_format_config_tree): New function.
* mailbox/cfg_parser.y (mu_cfg_tree_create_node): Change proto.
* mailbox/gocs.c (struct mu_gocs_entry): Name is const.
(mu_gocs_register): 1st arg (capa) is const.
* mailbox/mutil.c (mu_spawnvp): Remove const from the 2nd arg.
* mh/mh_whatnow.c (invoke): Shut compiler warnings.
* mimeview/mimetypes.l (mimetypes_open): Shut compiler warnings.
* mimeview/mimeview.c: Include mailcap.h
(display_file): Shut compiler warnings.
* readmsg/readmsg.c: Include mu_umaxtostr.h
* sieve/sieve.c (parser): Remove unused variable.
2007-12-03 Sergey Poznyakoff <gray@gnu.org.ua>
* auth/virtual.c (site_virtual_pwddir): Replace with global
struct mu_gocs_virtual mu_virtual_module_config
* include/mailutils/cfg.h (MU_PARSE_CONFIG_GLOBAL)
(MU_PARSE_CONFIG_VERBOSE, MU_PARSE_CONFIG_DUMP): New defines.
(mu_cfg_tree_create,mu_cfg_tree_set_debug,mu_cfg_tree_set_alloc)
(mu_cfg_tree_alloc,mu_cfg_tree_free)
(mu_cfg_tree_create_node,mu_cfg_tree_add_node): New functions.
* include/mailutils/gocs.h (struct mu_gocs_virtual): New data
type.
* include/mailutils/libargp.h (struct mu_argp_node_list): New data
type.
(mu_argp_node_list_init, mu_argp_node_list_add)
(mu_argp_node_list_new, mu_argp_node_list_finish): New functions.
* libargp/cmdline.h: New header.
* libargp/Makefile.am (libmuargp_a_SOURCES): Add cmdline.h.
* dotlock/dotlock.c, imap4d/imap4d.c, libargp/auth.c,
libargp/cmdline.c, libargp/common.c, libargp/compat.c,
libargp/gsasl.c, libargp/mu_argp.c, libargp/muinit.c,
libargp/pam.c, libargp/radius.c, libargp/sieve.c, libargp/sql.c,
libargp/tls.c, libargp/virtdomain.c, libcfg/common.c,
libcfg/init.c, libcfg/virtdomain.c, maidag/maidag.c,
mail.local/main.c, mail.remote/mail.remote.c, mimeview/mimeview.c,
movemail/movemail.c, pop3d/pop3d.c, readmsg/readmsg.c,
sieve/sieve.c: Change option parsing, using mu_cfg_tree_ functions.
* mailbox/argcv.c: Fix a typo in comment.
* mailbox/cfg_lexer.c (mu_parse_config_tree): New function.
(_mu_parse_config): Rewrite using mu_parse_config_tree.
* mailbox/cfg_parser.y (mu_cfg_format_error,_mu_cfg_vperror)
(debug_print_node): Use default diag debug_t object, if the passed
one is NULL. Reset locus after formatting.
(mu_cfg_postorder): Return immediately if node == NULL.
(mu_cfg_tree_create,mu_cfg_tree_set_debug,mu_cfg_tree_set_alloc)
(mu_cfg_tree_alloc,mu_cfg_tree_free,mu_cfg_tree_create_node)
(mu_cfg_tree_add_node): New functions.
* mailbox/gocs.c (mu_gocs_store): Make sure no capa/data tuple
gets registered twice.
* NEWS: Update.
* gnulib.modules: Add des. Sort lines.
* imap4d/Makefile.am (imap4d_SOURCES): Add preauth.c
* imap4d/preauth.c: New file.
* imap4d/authenticate.c (imap4d_authenticate): Use
imap4d_session_setup.
* imap4d/imap4d.c (imap4d_session_setup)
(imap4d_session_setup0): New functions.
(imap4d_mainloop): Implement PREAUTH mode.
* imap4d/imap4d.h (RESP_PREAUTH): New define.
(enum imap4d_preauth): New data type.
(preauth_mode,preauth_program,preauth_only,ident_port): New
globals.
(imap4d_session_setup,imap4d_session_setup0): New functions.
* imap4d/login.c (imap4d_login): Use imap4d_session_setup0.
* imap4d/util.c (sc2string): Handle RESP_PREAUTH
* lib/.cvsignore, m4/.cvsignore: Update.
* mailbox/tcp.c: Fix indentation.
2007-12-02 Sergey Poznyakoff <gray@gnu.org.ua>
* mailbox/cfg_format.c: New file.
* mailbox/Makefile.am (libmailutils_la_SOURCES): Add cfg_format.c
* mailbox/cfg_parser.y (mu_cfg_print_tree): Remove
* include/mailutils/cfg.h (mu_cfg_format_tree): New prototype.
2007-12-01 Sergey Poznyakoff <gray@gnu.org.ua>
* configure.ac (AC_CONFIG_FILES): Remove include/gnu/Makefile.
2007-11-30 Sergey Poznyakoff <gray@gnu.org.ua>
* NEWS, TODO: Update
* include/mailutils/types.hin: New type mu_log_level_t.
* include/mailutils/debug.hm4, include/mailutils/diag.h,
mailbox/cfg_lexer.c, mailbox/cfg_parser.y, mailbox/dbgstderr.c,
mailbox/dbgsyslog.c, mailbox/debug.c, mailbox/diag.c,
mailbox/gdebug.c, mailbox/muerror.c, mailbox/syslog.c,
sieve/sieve.c: Use mu_log_level_t instead of size_t for debugging
and logging levels.
2007-11-29 Sergey Poznyakoff <gray@gnu.org.ua>
* comsat/action.c, comsat/comsat.c, imap4d/auth_gsasl.c,
imap4d/auth_gss.c, imap4d/authenticate.c, imap4d/bye.c,
imap4d/close.c, imap4d/imap4d.c, imap4d/login.c, imap4d/search.c,
imap4d/signal.c, imap4d/starttls.c, imap4d/util.c, maidag/lmtp.c,
maidag/maidag.c, maidag/script.c, mail.local/main.c,
mail.local/script.c, pop3d/apop.c, pop3d/bulletin.c,
pop3d/extra.c, pop3d/lock.c, pop3d/logindelay.c, pop3d/pop3d.c,
pop3d/quit.c, pop3d/signal.c, pop3d/user.c, libsieve/util.c: Use
mu_diag_output instead of syslog.
* sieve/sieve.c: New option --no-program-name, for testsuite.
* sieve/testsuite/lib/sieve.exp: Call sieve with the
--no-program-name option.
* mailbox/cfg_lexer.c, mailbox/cfg_parser.y: Improve debugging.
* mailbox/diag.c: New file.
* mailbox/gdebug.c (mu_debug_level_from_string): New function.
* mailbox/muerror.c (mu_verror, mu_error): Rewrite using mu_diag
functions.
* mailbox/syslog.c (mu_diag_level_to_syslog): New function.
(mu_diag_syslog_printer): New function.
* mh/mh_argp.c (mh_argp_parse): Set program name using
mu_set_program_name.
* mh/mh_init.c (mu_error_printer): No longer needed.
* movemail/movemail.c (movemail_error_printer): No longer needed.
* include/mailutils/Makefile.am (pkginclude_HEADERS): Add diag.h
* include/mailutils/diag.h: New file.
* include/mailutils/cfg.h (mu_cfg_lexer_t): Take mu_debug_t as its
second argument.
* include/mailutils/error.h: Include diag.h
(mu_program_name,mu_set_program_name): Remove. Already declared in
diag.h.
(mu_error_set_print): Deprecated.
* mailbox/Makefile.am (libmailutils_la_SOURCES): Add diag.c
2007-11-28 Sergey Poznyakoff <gray@gnu.org.ua>
III. Use mu_debug_t for diagnostics in cfg framework.
* include/mailutils/cfg.h, mailbox/cfg_lexer.c,
mailbox/cfg_parser.y (mu_cfg_tree_t):
New data type.
(mu_cfg_perror_t): Remove
(mu_cfg_parse): Change prototype.
(mu_cfg_perror): Change type.
(mu_cfg_format_error): New function.
(mu_cfg_destroy_tree): Change signature.
(mu_cfg_callback_t): Take mu_debug_t as its first argument,
instead of mu_cfg_locus_t. The mu_debug_t is to be used for error
reporting and debugging diagnostics. The cfg_lexer is responsible
for storing the necessary locus data into it before calling
callbacks.
(mu_cfg_section_fp): Take an additional argument.
(mu_cfg_scan_tree): Simplified prototype. The mu_cfg_tree_t passed
as its first argument already contains all necessary data that
were passed as arguments previously.
(mu_parse_config): First two args are consts.
* include/mailutils/libcfg.h, imap4d/imap4d.c, libcfg/auth.c,
libcfg/common.c, libcfg/ldap.c, libcfg/sieve.c, libcfg/sql.c,
maidag/maidag.c, mail.local/main.c, mimeview/mimeview.c,
pop3d/pop3d.c, sieve/sieve.c: Reflect changes to the cfg
framework.
* mailbox/debug.c (mu_debug_vprintf): Make sure the locus info is
formatted on the first call.
II. Further improvement of mu_debug_t.
* include/mailutils/debug.hm4 (struct mu_debug_locus): New data
type.
(mu_debug_set_locus, mu_debug_get_locus)
(mu_debug_set_function, mu_debug_get_function): New prototypes.
(mu_debug_printer_fp, mu_debug_syslog_printer)
(mu_debug_stderr_printer): Change type of the first argument.
(mu_debug_set_data): New function.
(all proto): Remove argument names, use only types to avoid
problems on some broken systems (FreeBSD comes to mind).
* libproto/include/debug0.h (struct _mu_debug): printer: change
type of the first argument.
locus, function, data, destroy: New fields.
* mailbox/dbgstderr.c (mu_debug_stderr_printer): Change type of
the first argument.
* mailbox/dbgsyslog.c (mu_debug_syslog_printer): Change type of
the first argument.
* mailbox/debug.c (mu_debug_destroy): Flush any left over data.
Call destroy, if supplied.
(mu_debug_set_data): New function.
(mu_debug_vprintf): Print locus and function (if supplied) at the
beginning of the buffer.
(mu_debug_set_locus, mu_debug_get_locus, mu_debug_set_function)
(mu_debug_get_function): New functions.
* scripts/debugdef.m4 (MKDEBUG): Use mu_debug_set_locus and
mu_debug_set_function to print source locations. This allows for
easy i18n of the MU_DEBUG[0-9]* format strings.
I. Introduce "global debug settings". Mailutils objects are supposed
to set their default mu_debug_t objects basing on these settings.
* include/mailutils/Makefile.am: Add debug.hm4. Build debug.h from
it.
* include/mailutils/debug.hm4: New file.
* include/mailutils/debug.h: Remove generated file.
* scripts/Makefile.am (EXTRA_DIST): Add debugdef.m4
* scripts/debugdef.m4: New file.
* include/mailutils/gocs.h (struct mu_gocs_debug): New data type.
(mu_gocs_register_std): Argument is const.
(mu_gocs_debug_init): New function.
* include/mailutils/libargp.h (mu_debug_cmdline): New extern.
* include/mailutils/libcfg.h (mu_debug_cfg_capa): New extern.
* libargp/cmdline.c: Add mu_debug_cmdline
* libargp/common.c: Add debug settings.
* libargp/mu_argp.c (struct cap_buf.capa): Remove const qualifier.
* libcfg/common.c (mu_locking_param): Remove superfluous `lock-'
prefix from the statement names.
(mu_debug_param): New parameter group.
* libcfg/init.c: Add mu_debug_param.
* mailbox/gocs.c (mu_gocs_debug_init): New function.
* mailbox/Makefile.am (libmailutils_la_SOURCES): Add gdebug.c
* mailbox/gdebug.c: New file
* mailbox/debug.c (mu_debug_printf, mu_debug_vprintf)
(mu_debug_check_level): New functions.
(mu_debug_printv, mu_debug_print): Rewrite using new basic calls.
* comsat/comsat.c, dotlock/dotlock.c, examples/muauth.c,
mail.remote/mail.remote.c: Add debug capability.
* frm/frm.c, frm/from.c, guimb/main.c, imap4d/imap4d.c,
mail/mail.c, mail.local/main.c, messages/messages.c,
pop3d/pop3d.c, readmsg/readmsg.c: Add locking and debug capabilities.
* examples/mimetest.c, examples/msg-send.c, frm/common.c,
libargp/auth.c, libmu_scm/mu_message.c, mail/send.c, mh/send.c,
mimeview/mimeview.c, movemail/movemail.c, sieve/sieve.c: Update
invocation of mu_debug_set_level.
* libproto/imap/folder.c, libproto/imap/mbox.c,
libproto/include/folder0.h, libproto/include/mailbox0.h,
libproto/include/mailer0.h, libproto/mailer/sendmail.c,
libproto/mailer/smtp.c, libproto/mbox/mbox.c,
libproto/nntp/folder.c, libproto/nntp/nntp_debug.c,
libproto/pop/mbox.c, libproto/pop/pop3_debug.c, mailbox/amd.c,
mailbox/mailer.c, mailbox/message.c, mailbox/mu_auth.c: Use
MU_DEBUG[0-9] for debugging.
* mailbox/muerror.c: Include string.h
* mailbox/syslog.c (syslog_to_n): Remove unused variable.
* mailbox/assoc.c (struct _mu_assoc_elem): name is not const.
* mailbox/cfg_lexer.c: Quoted strings can be continued to the
following line either by using a trailing backslash or by
concatenating strings together, as in C.
* mailbox/mailbox.c (_create_mailbox): Initialize debug object
using global "mailbox" level.
(mu_mailbox_create): Fix bug introduced on 2007-11-26.
* include/mailutils/libsieve.h (mu_sieve_set_debug_level): Change
prototype.
(mu_sieve_set_debug_object): New prototype.
* libsieve/sieve.y (mu_sieve_machine_init): Initialize debug
object from "sieve" global level.
(mu_sieve_set_debug_level): Set only debug_level.
(mu_sieve_set_debug_object): New function.
* maidag/maidag.c: Remove explicit setting of debug object. Add
"debug" group, which provides the required functionality.
(set_debug_flags): Likewise. This function and the corresponding
command line option are fading out in favor of global debug
settings.
2007-11-26 Sergey Poznyakoff <gray@gnu.org.ua>
* configure.ac (MU_APP_LIBRARIES): Load libmuaux after libmuargp
and libcfg.
(fgetpwent): Use AC_CHECK_FUNCS
* auth/virtual.c: Use mu_fgetpwent if fgetpwent is not available.
* lib/Makefile.am: Add back utmp.c
* lib/utmp.c: Restore after unintended remove.
* m4/utmp.m4: Fix quoting.
* libcfg/gsasl.c, libcfg/ldap.c, libcfg/pam.c, libcfg/radius.c,
libcfg/sieve.c, libcfg/sql.c, libcfg/tls.c, libcfg/virtdomain.c:
Include stdlib.h
* libproto/imap/folder.c, libproto/mbox/mbox.c,
libproto/mbox/mbox0.h, libproto/pop/mbox.c, mailbox/attachment.c,
mailbox/mailbox.c, mailbox/parsedate.y: Do not use alloca.
* mailbox/Makefile.am (libmailutils_la_SOURCES): Add fgetpwent.c
and intprops.h.
* mailbox/fgetpwent.c (fgetpwent): Rename to mu_fgetpwent.
* mailbox/gocs.c: Revert recent change. It broke the testsuite in
sieve.
* mailbox/syslog.c (log_facility): Initialize to LOG_FACILITY.
* configure.ac, NEWS: Add LDAP support.
* auth/Makefile.am (libmuauth_la_SOURCES): Add ldap.c.
* auth/ldap.c: New file.
* include/mailutils/Makefile.am (pkginclude_HEADERS): Add ldap.h.
* include/mailutils/ldap.h: New file.
* include/mailutils/libcfg.h (mu_ldap_cfg_capa): New extern.
* include/mailutils/mu_auth.h (mu_auth_ldap_module): New extern.
(MU_AUTH_REGISTER_ALL_MODULES): Register ldap.
* libcfg/Makefile.am (libmucfg_la_SOURCES): Add ldap.
* libcfg/ldap.c: New file.
* libcfg/init.c (cfg_capa_table): Add ldap.
* mailbox/gocs.c (mu_gocs_logging_init): Initialize log_facility
to default if not specified otherwise. Need to revise this later.
* mailbox/version.c (mu_conf_option): Reveal ldap, if supported.
* mailbox/mu_auth.c (mu_auth_data_alloc): Add safety
checks. Provide reasonable defaults for missing arguments.
* mailbox/mutil.c (mutil_parse_field_map): Bugfix - increment by 2
on each loop.
* libargp/mu_argp.c (mu_build_argp): Do not bail out if an unknown
capability is requested.
* include/mailutils/assoc.h (mu_assoc_count): New function.
* mailbox/assoc.c: Likewise.
* auth/radius.c (_expand_query): Static
* mailbox/cfg_lexer.c: Fixed memory management during cloning.
2007-11-24 Sergey Poznyakoff <gray@gnu.org.ua>
Improve debugging.
* imap4d/login.c, pop3d/user.c: Print user db source along with
the login name.
* include/mailutils/debug.h (mu_debug_set_print): Change
prototype.
(mu_debug_printer_fp): New data type.
(mu_debug_default_printer): New extern.
(mu_debug_syslog_printer,mu_debug_stderr_printer): New prototypes.
* libproto/include/debug0.h (struct _mu_debug): Remove unused
`buffer' and `buflen'. Add `stream'. Change signature of `_print' and
rename it to `printer'.
* mailbox/debug.c: Rewrite debugging support.
(mu_debug_default_printer): New global.
* mailbox/gocs.c (mu_gocs_logging_init): Initialize
mu_debug_default_printer.
* mailbox/memory_stream.c (_memory_truncate): Bugfix.
(_memory_get_transport2): Implement method.
* mailbox/Makefile.am (libmailutils_la_SOURCES): Add dbgstderr.c
and dbgsyslog.c
* mailbox/dbgstderr.c, mailbox/dbgsyslog.c: New files.
* maidag/maidag.c, mail.local/main.c, sieve/sieve.c: Remove
_mu_debug_printer, the default implementation will do.
* mailbox/mu_auth.c: Improve debugging.
* libsieve/comparator.c, libsieve/load.c, libsieve/sieve.l:
Include ctype.h
* include/mailutils/libargp.h: Remove option declarations.
* include/mailutils/mu_auth.h (struct mu_auth_data): New member
`source'.
(mu_auth_set_debug): New proto.
* libargp/common.c: Define option values. New option --debug-auth.
* libargp/auth.c, libargp/gsasl.c,
libargp/pam.c, libargp/radius.c, libargp/sieve.c, libargp/sql.c,
libargp/tls.c, libargp/virtdomain.c: Define option values.
2007-11-22 Sergey Poznyakoff <gray@gnu.org.ua>
* libsieve/conf.c (mu_sieve_module_init): Initialize
mu_sieve_library_path with SIEVE_MODDIR.
2007-11-20 Sergey Poznyakoff <gray@gnu.org.ua>
* mail.local/mail.local.h, mail.local/main.c: Limit verbosity of
messages printed to stderr.
* libsieve/extensions/pipe.c: Fix indentation.
* libsieve/extensions/spamd.c: Use socket stream.
* mailbox/socket_stream.c (_s_open): Default to RDWR mode.
* libcfg/common.c (mu_logging_param): Use callback to parse the
facility.
* README-alpha: Update.
* auth/pam.c (mu_pam_module_init): Use struct.
* include/mailutils/gocs.h (struct mu_gocs_pam): New data type.
* include/mailutils/libcfg.h (mu_sieve_cfg_capa)
(mu_daemon_cfg_capa,mu_auth_cfg_capa): New declarations.
* libargp/common.c (mu_daemon_argp_parser): Handle ARGP_KEY_INIT.
* libargp/pam.c (service_name): Remove.
(pam_settings): Add new variable.
(mu_pam_argp_parser): Reflect this.
* libcfg/auth.c (mu_auth_section_parser): New function.
(mu_auth_cfg_capa): New variable.
* libcfg/common.c (mu_daemon_section_parser): Handle
mu_cfg_section_start.
* libcfg/init.c (cfg_capa_table): Add auth, sieve, daemon.
(reserved_name): Remove auth and daemon.
* mailbox/Makefile.am (EXTRA_DIST): Remove @MU_EXTRA_DIST@.
* mailbox/daemon.c (mu_gocs_daemon_init): Remove extra checks.
* mailbox/mu_auth.c (_add_module_list): Skip delimiters.
* po/POTFILES.in: Update.
2007-11-19 Sergey Poznyakoff <gray@gnu.org.ua>
* configure.ac: Add AM_PROG_LIBTOOL.
* include/mailutils/libargp.h (mu_argp_build): Change proto.
* libargp/compat.c (mu_argp_parse): Update call to mu_argp_build.
* libargp/mu_argp.c (mu_argp_build): Optionally return expanded
capability list in the third argument.
* libargp/muinit.c (mu_app_init): Pass expanded capability list to
mu_libcfg_init.
* include/mailutils/cfg.h (mu_cfg_parser_verbose): New variable.
* include/mailutils/libargp.h (OPT_RCFILE_VERBOSE): New value.
* libargp/Makefile.am (AM_CFLAGS): Rename to AM_CPPFLAGS, define
SYSCONFDIR.
* libargp/common.c (mu_common_argp, mu_common_argp_parser): New
option rcfile-verbose.
* mailbox/Makefile.am (AM_CPPFLAGS): define SYSCONFDIR.
* mailbox/cfg_lexer.c (_mu_parse_config): Implement `include'
statement. Add verbose logging.
* mailbox/cfg_parser.y (mu_cfg_parser_verbose): New variable.
(mu_cfg_parse): Zero out parse_tree before returning.
(_scan_tree_helper): Remove dependency on MU_CONFIG_VERBOSE envar.
Use mu_cfg_parser_verbose instead.
* config/mailutils.m4: New file
* config/Makefile.am: Install mailutils.m4 to $(datadir)/aclocal
* configure.ac (VI_CURRENT): Raise to 3;
(MU_APP_LIBRARIES): Rename libargp.a to libmuargp.a
* NEWS: Update.
* comsat/comsat.c, dotlock/dotlock.c, examples/muauth.c,
examples/muemail.c, frm/frm.h, guimb/main.c, imap4d/imap4d.c,
libargp/auth.c, libargp/cmdline.c, libargp/common.c,
libargp/gsasl.c, libargp/mu_argp.c, libargp/pam.c,
libargp/radius.c, libargp/sieve.c, libargp/sql.c, libargp/tls.c,
libargp/virtdomain.c, maidag/maidag.h, mail/mail.c,
mail.local/main.c, mail.remote/mail.remote.c, messages/messages.c,
mimeview/mimetypes.y, mimeview/mimeview.c, movemail/movemail.c,
pop3d/extra.c, pop3d/pop3d.c, pop3d/popauth.c, readmsg/readmsg.c,
sieve/sieve.c: Include mailutils/libargp.h.
* config/mailutils-config.c: New arguments to --link: cfg and argp.
* include/mailutils/Makefile.am (pkginclude_HEADERS): Remove
compat.h, add libargp.h, libcfg.h and version.h
* include/mailutils/compat.h: Remove
* include/mailutils/libargp.h: New file (from libargp/cmdline.h)
* include/mailutils/libcfg.h: New file (from (libcfg/)
* include/mailutils/version.h: New file
* include/mailutils/folder.h (struct mu_0_6_folder_list): Remove
(mu_0_6_folder_list, mu_0_6_folder_lsub)
(mu_0_6_folder_list_destroy): Remove.
* include/mailutils/mailutils.h: Include version.h
Remove 0.6 compatibility layer.
* mailbox/folder.c (list_to_0_6_folder_list, mu_0_6_folder_list)
(mu_0_6_folder_lsub, mu_0_6_folder_list_destroy): Remove.
* lib/Makefile.am (libmuaux_la_SOURCES): Remove argpinit.c,
muinit.h and muinit.c
* libargp/Makefile.am (noinst_LIBRARIES, noinst_HEADERS): Remove
(lib_LIBRARIES): Add libmuargp.a
* libargp/compat.c: New file.
* libargp/muinit.c: New file.
* libargp/cmdline.h: Remove.
* libcfg/Makefile.am (noinst_HEADERS): Remove.
* libcfg/auth.c, libcfg/common.c, libcfg/gsasl.c, libcfg/init.c,
libcfg/pam.c, libcfg/radius.c, libcfg/sieve.c, libcfg/sql.c,
libcfg/tls.c, libcfg/virtdomain.c: Include mailutils/libcfg.h
* mailbox/Makefile.am (libmailutils_la_SOURCES): Add version.c
* mailbox/cfg_lexer.c (_mu_parse_config): Do nothing if
root_container is NULL.
* mh/ali.c, mh/anno.c, mh/burst.c, mh/comp.c, mh/fmtcheck.c,
mh/folder.c, mh/forw.c, mh/inc.c, mh/install-mh.c, mh/mark.c,
mh/mhl.c, mh/mhn.c, mh/mhparam.c, mh/mhpath.c, mh/pick.c,
mh/refile.c, mh/repl.c, mh/rmf.c, mh/rmm.c, mh/scan.c, mh/send.c,
mh/sortm.c, mh/whatnow.c, mh/whom.c: Use mh_argp_init instead of
mu_argp_init.
* mh/mh_argp.c, mh/mh_getopt.h (mh_argp_init): New function
2007-11-18 Sergey Poznyakoff <gray@gnu.org.ua>
* bootstrap (cp_mark_as_generated): Create target directory if
needed.
Make libmailutils independent from gnulib. Remove generated files
from the repository. Bootstrap directly from the gnulib CVS.
* scripts/gnulib-sync, autogen.sh: Remove.
* bootstrap, bootstrap.conf: New files.
* README-hacking: New file.
* configure.ac: Update.
* lib/Makefile.am: Update.
* mailbox/Makefile.am: Update.
* include/mailutils/Makefile.am (SUBDIRS): Remove gnu
* include/mailutils/gnu/Makefile.am: Remove
* examples/argcv.c, examples/mta.c, guimb/guimb.h,
imap4d/imap4d.h, libargp/mu_argp.c, libargp/tls.c,
maidag/maidag.h, mail/mail.h, mail/send.c,
mail.local/mail.local.h, mh/mh.h: Remove getline.h
* libproto/nntp/mbox.c: Include mailutils/md5.h
* libargp/cmdline.h: Include strings.h
* m4/debug.m4, m4/enable.m4, m4/gsasl.m4, m4/guile.m4,
m4/mu_libobj.m4: Minor fix
* m4/intmax.m4,m4/inttypes-pri.m4,m4/inttypes_h.m4: Update
* mailbox/alloca.h: Remove
* mailbox/mailbox.c: Include string.h
* mailbox/nls.c: Include locale.h
* po/Makevars: Remove.
* absolute-header.m4, alloca.m4, allocsa.m4, argp.m4, codeset.m4,
d-type.m4, eealloc.m4, eoverflow.m4, error.m4, exitfail.m4,
extensions.m4, fnmatch.m4, full-header-path.m4, getdelim.m4,
getline.m4, getlogin_r.m4, getndelim2.m4, getopt.m4, getpass.m4,
gettext.m4, glibc2.m4, glibc21.m4, glob.m4, gnulib.m4, iconv.m4,
intdiv0.m4, isc-posix.m4, lcmessage.m4, lib-ld.m4, lib-link.m4,
lib-prefix.m4, lock.m4, longdouble.m4, longlong.m4,
mailbox-link.m4, mbchar.m4, mbiter.m4, mbrtowc.m4, mbstate_t.m4,
mbswidth.m4, memchr.m4, mempcpy.m4, minmax.m4, obstack.m4,
onceonly.m4, po.m4, printf-posix.m4, progtest.m4, regex.m4,
restrict.m4, setenv.m4, signed.m4, size_max.m4, snprintf.m4,
ssize_t.m4, stat-macros.m4, stdbool.m4, stdint.m4, stdint_h.m4,
strcase.m4, strchrnul.m4, strdup.m4, strerror_r.m4, strndup.m4,
strnlen.m4, strtok_r.m4, sysexits.m4, uint32_t.m4, uintmax_t.m4,
ulonglong.m4, unistd_h.m4, unlocked-io.m4, vasnprintf.m4,
vasprintf.m4, visibility.m4, vsnprintf.m4, wchar_t.m4, wcwidth.m4,
wint_t.m4, xalloc.m4, xsize.m4: Remove.
* alloca.c, allocsa.c, allocsa.h, asprintf.c, basename.c, error.c,
error.h, exit.h, exitfail.c, exitfail.h, fnmatch.c, fnmatch_.h,
fnmatch_loop.c, getpass.c, getpass.h, intprops.h, malloc.c,
mbswidth.c, mbswidth.h, md5.c, md5.h, obstack.c, obstack.h,
realloc.c, setenv.c, setenv.h, snprintf.c, snprintf.h, stdbool.h,
stdbool_.h, strcasecmp.c, strncasecmp.c, strsignal.c, strtok_r.c,
unsetenv.c, utmp.c, vasprintf.c, vasprintf.h, vsyslog.c,
xalloc-die.c, xalloc.h, xalloc_die.c, xmalloc.c, xsize.h,
xstrdup.c: Remove.
* alloca.c, alloca_.h, argp-ba.c, argp-eexst.c, argp-fmtstream.c,
argp-fmtstream.h, argp-fs-xinl.c, argp-help.c, argp-namefrob.h,
argp-parse.c, argp-pin.c, argp-pv.c, argp-pvh.c, argp-xinl.c,
argp.h, asnprintf.c, fnmatch.c, fnmatch_.h, fnmatch_loop.c,
getdelim.c, getdelim.h, getline.c, getline.h, getlogin_r.c,
getlogin_r.h, getndelim2.c, getndelim2.h, getopt.c, getopt.h,
getopt1.c, getopt_.h, getopt_int.h, gettext.h, glob-libc.h,
glob.c, glob_.h, malloc.c, mbchar.c, mbchar.h, mbuiter.h,
memchr.c, mempcpy.c, mempcpy.h, minmax.h, pin.c, printf-args.c,
printf-args.h, printf-parse.c, printf-parse.h, regcomp.c, regex.c,
regex.h, regex_internal.c, regex_internal.h, regexec.c,
stat-macros.h, stdbool_.h, stdint_.h, strcase.h, strcasecmp.c,
strchrnul.c, strchrnul.h, strdup.c, strdup.h, strncasecmp.c,
strndup.c, strndup.h, strnlen.c, strnlen.h, strnlen1.c,
strnlen1.h, strtok_r.c, strtok_r.h, sysexit_.h, unlocked-io.h,
vasnprintf.c, vasnprintf.h, vsnprintf.c, vsnprintf.h, wcwidth.h,
xsize.h: Remove.
2007-11-17 Sergey Poznyakoff <gray@gnu.org.ua>
* mailbox/sha1.h: Remove.
* include/mailutils/sha1.h: Add.
* mailbox/md5.h: Remove.
* include/mailutils/md5.h: Add.
* include/mailutils/Makefile.am: Update.
* mailbox/Makefile.am: Update.
* libproto/pop/mbox.c, libproto/pop/pop3_apop.c,
libproto/pop/pop3_stls.c, mailbox/md5.c, mailbox/message.c,
mailbox/sha1.c, pop3d/apop.c, pop3d/pop3d.h, sql/mysql.c: Fix
usage of sha1_ and md5_.
* mailbox/mu_auth.c, mailbox/mutil.c, mailbox/rfc2047.c: Eliminate
strtok_r.
* auth/sql.h (mu_internal_sql_config): Move to ...
* include/mailutils/sql.h: ... here
* imap4d/auth_gsasl.c: Bugfix.
Move rc file and argp parsing into separate abstract layers.
* include/mailutils/gocs.h, include/mailutils/pam.h,
include/mailutils/radius.h, include/mailutils/syslog.h: New files
* lib/argpinit.c, lib/muinit.c, lib/muinit.h: New files.
* libsieve/conf.c: New file.
* libcfg: New directory
* libcfg/libcfg.h, libcfg/auth.c, libcfg/common.c, libcfg/init.c,
libcfg/gsasl.c, libcfg/pam.c, libcfg/radius.c, libcfg/sieve.c,
libcfg/sql.c, libcfg/tls.c, libcfg/virtdomain.c,
libcfg/.cvsignore: New files.
* libargp: New directory
* libargp/auth.c, libargp/cmdline.h, libargp/common.c,
libargp/gsasl.c, libargp/mu_argp.h, libargp/mu_argp.c,
libargp/pam.c, libargp/radius.c, libargp/sieve.c, libargp/sql.c,
libargp/tls.c, libargp/virtdomain.c, libargp/.cvsignore: New
files.
* mailbox/.cvsignore: Add cfg_parser.c and cfg_parser.h.
* mailbox/gocs.c: New file.
* Makefile.am (SUBDIRS): Add libargp and libcfg.
* configure.ac (MU_APP_LIBRARIES): New variable
(MU_COMMON_INCLUDES): add libargp and libcfg
(AC_CONFIG_FILES): Add libargp and libcfg.
* auth/gsasl.c, auth/pam.c, auth/radius.c, auth/sql.c, auth/sql.h,
auth/tls.c, auth/virtual.c, comsat/comsat.h, frm/frm.h,
guimb/guimb.h, imap4d/imap4d.h, include/mailutils/gsasl.h,
include/mailutils/libsieve.h, include/mailutils/mailutils.h,
include/mailutils/mu_auth.h, include/mailutils/tls.h,
include/mailutils/sql.h, maidag/maidag.h, mail/mail.h,
mail.local/mail.local.h, mailbox/daemon.c, mailbox/system.c,
mh/mh_argp.c, mh/mh_getopt.h, pop3d/pop3d.h,
readmsg/readmsg.h: Remove argp stuff
* comsat/comsat.c, config/mailutils-config.c, dotlock/dotlock.c,
examples/muauth.c, examples/muemail.c, frm/frm.c, frm/from.c,
guimb/main.c, imap4d/idle.c, imap4d/imap4d.c, imap4d/util.c,
imap4d/version.c, maidag/lmtp.c, maidag/maidag.c,
maidag/mailquota.c, mail/mail.c, mail/send.c, mail/version.c,
mail.local/mailquota.c, mail.local/main.c,
mail.remote/mail.remote.c, mailbox/mu_auth.c, messages/messages.c,
mimeview/mimeview.c, movemail/movemail.c, pop3d/extra.c,
pop3d/pop3d.c, pop3d/popauth.c, readmsg/readmsg.c, sieve/sieve.c:
Use mu_app_init for parsing command line and
configuration files.
* comsat/Makefile.am, config/Makefile.am, dotlock/Makefile.am,
examples/Makefile.am, frm/Makefile.am, guimb/Makefile.am,
imap4d/Makefile.am, maidag/Makefile.am, mail/Makefile.am,
mail.local/Makefile.am, mail.remote/Makefile.am,
mailbox/Makefile.am, messages/Makefile.am, mimeview/Makefile.am,
movemail/Makefile.am, pop3d/Makefile.am, readmsg/Makefile.am,
sieve/Makefile.am: Use MU_APP_LIBRARIES.
* include/mailutils/Makefile.am: Add new files.
* include/mailutils/argp.h: Remove.
* include/mailutils/cfg.h: New file.
* include/mailutils/daemon.h (MODE_INTERACTIVE,MODE_DAEMON): New
defines (from removed argp.h).
(mu_gocs_daemon): New decl.
* include/mailutils/error.h (mu_program_name): New variable
(mu_set_program_name): New function.
* lib/Makefile.am (libmuaux_la_SOURCES): Add new files.
* libsieve/Makefile.am (libsieve_la_SOURCES): Remove argp.c, add
conf.c instead.
* libsieve/argp.c: Remove.
* mailbox/cfg_parser.y (mu_cfg_parse_boolean): New function.
* mailbox/mu_argp.c: Remove.
* mailbox/muerror.c (mu_program_name): New variable
(mu_set_program_name): New function
(mu_default_error_printer): Print program name before diagnostic
string.
* mailbox/mutil.c (mu_sql_decode_password_type): New function.
* mh/mh_whom.c (mh_alias_expand): Bugfix
* po/POTFILES.in: Update
* testsuite/lib/mailutils.exp (mu_init): Pass --no-site-rcfile
--no-user-rcfile to all programs.
2007-11-12 Sergey Poznyakoff <gray@gnu.org.ua>
* maidag/lmtp.c: Use English reply texts.
* auth/sql.c (decode_tuple_v1_0): Allow mailbox to be NULL.
* comsat/comsat.c: Use mu_error for diagnostics where possible.
* libproto/include/amd.h (struct _amd_data. qfetch): New member.
* libproto/maildir/mbox.c (maildir_qfetch): Implement quick_get
method.
* libproto/mh/mbox.c (mh_qfetch): Likewise.
* mailbox/amd.c (amd_quick_get_message): Likewise.
2007-11-11 Sergey Poznyakoff <gray@gnu.org.ua>
* auth/sql.c, libproto/mbox/folder.c: Rename MU_READ_ERROR to
MU_ERR_READ, for consistency.
* comsat/Makefile.am (comsatd_LDADD): Add all mailbox formats.
* comsat/cfg.c: Use mu_error instead of syslog.
* comsat/comsat.c (comsat_daemon): Implement test mode.
(notify_user): Use mailbox quick access mode instead of directly
fiddling with the UNIX mailbox stream.
* include/mailutils/stream.h (MU_STREAM_QACCESS): New define.
* libproto/mbox/mbox.c: Implement _quick_get_message method.
* libproto/mbox/mbox0.h (mbox_scan1): New function.
* libproto/mbox/mboxscan.c (mbox_scan0): Split into mbox_scan0
proper and mbox_scan_internal.
(mbox_scan1): New function.
Remove unused defines.
* libsieve/load.c: Do not deallocate loaded modules.
* mail.local/main.c (set_debug_flags): Fix typo.
* mailbox/amd.c: Implement get_qid method.
(amd_append_message): Signal MU_EVT_MESSAGE_APPEND.
* mailbox/errors (MU_ERR_BADOP): New error code.
(MU_READ_ERROR): Rename to MU_ERR_READ, for consistency.
* mailbox/file_stream.c (_prog_destroy,_prog_close): Fix waiting
for the children to terminate. Do not forcefully kill them.
* mailbox/mailbox.c: Control allowed operations, depending on
MU_STREAM_QACCESS bit.
2007-11-10 Sergey Poznyakoff <gray@gnu.org.ua>
* NEWS: Update
* mailbox/Makefile.am: Update
* libsieve/extensions/pipe.c: Update
* libsieve/extensions/Makefile.am: Add pipe.c
* libsieve/extensions/pipe.c: New file
* Makefile.am, configure.ac: Add maidag.
* frm/common.c, imap4d/sync.c, libsieve/runtime.c,
mh/scan.c: Update declaration of observable actions.
* imap4d/select.c, imap4d/status.c, mh/anno.c, mh/forw.c,
mh/repl.c: Use mu_mailbox_sync instead of
mu_mailbox_save_attributes.
* include/mailutils/mailbox.h (mu_mailbox_sync): New function
(mu_mailbox_save_attributes): Deprecated.
* include/mailutils/message.h (mu_message_get_qid)
(mu_message_set_qid): New functions.
* include/mailutils/observer.h (MU_EVT_MESSAGE_APPEND): New event.
(mu_observer_set_action_data): New function. Registers
action-specific data.
(mu_observable_notify): Get call-specific data as the third
argument.
* include/mailutils/types.hin (mu_message_qid_t): New data type.
* libproto/imap/folder.c, libproto/imap/mbox.c,
libproto/include/amd.h, libproto/maildir/mbox.c,
libproto/mailer/sendmail.c, libproto/mailer/smtp.c,
libproto/mbox/mboxscan.c, libproto/mh/mbox.c,
libproto/nntp/mbox.c, libproto/pop/mbox.c, mailbox/folder.c,
mailbox/mailer.c : Update calls to mu_observable_notify.
* libproto/include/mailbox0.h (struct _mu_mailbox): Rename
_save_attributes to _sync.
* mailbox/amd.c: Likewise.
(_quick_get_message): New member.
(MAILBOX_NOTIFY): Remove.
* libproto/include/message0.h (struct _mu_message): New member
_get_qid.
* libproto/include/observer0.h (struct _mu_observer): New member
_action_data.
* libproto/mbox/mbox.c: Implement mbox_message_qid. Update calls
to mu_observable_notify.
(mbox_append_message): Report MU_EVT_MESSAGE_APPEND.
* mailbox/observer.c (mu_observer_destroy): Call _destroy with
_action_data as its third argument.
(mu_observer_action, mu_observable_notify): Takes third argument
(call data)
(mu_observer_set_action, mu_observer_set_destroy): Update signature.
(mu_observer_set_action_data): New function.
* libproto/mbox/mbox0.h, mail.local/main.c: Minor change
* mail.local/Makefile.am (mail_local_LDADD): Add MU_LIB_MAILER
* mailbox/file_stream.c (_file_open): Fix handling of
MU_STREAM_APPEND. Remove assertion.
* mailbox/mailbox.c (mu_mailbox_quick_get_message): New function
(mu_mailbox_sync): New function.
(mu_mailbox_get_size): Implement brute-force approach in case the
mailbox does not provide a method.
* mailbox/message.c (mu_message_get_qid, mu_message_set_qid): New
function.
* maildag/: New directory. A general-purpose mail delivery agent.
* maildag/deliver.c: New file.
* maildag/lmtp.c: New file.
* maildag/maidag.c: New file.
* maildag/maidag.h: New file.
* maildag/mailtmp.c: New file.
* maildag/mailquota.c: New file.
* maildag/script.c: New file.
* maildag/util.c: New file.
* maildag/Makefile.am: New file.
* maildag/.cvsignore: New file.
2007-11-08 Sergey Poznyakoff <gray@gnu.org.ua>
* mailbox/cfg_lexer.c: Do not use obstack.
* mailbox/refcount.c (mu_refcount_inc, mu_refcount_dec): Bugfix
* auth/pam.c, auth/radius.c: Add configuration keywords.
* mailbox/cfg_lexer.c (isword): Allow dots in words.
* configure.ac, NEWS: version 1.2.90
* mailbox/Makefile.am: Additional dependency
cfg_parser.h:cfg_parser.y
* mailbox/cfg_lexer.c (_mu_config_register_section): Zero out
the root container after creation.
(_mu_parse_config): Use `program' not `prog' for per-program
sections.
* pop3d/pop3d.c (cb_bulletin_db): Fix typo
(pop3d_cfg_param): Protect some variables by ifdefs.
* include/mailutils/argp.h (mu_argp_set_config_param): New
function.
* include/mailutils/cfg.h (mu_cfg_time): New value
(struct mu_cfg_section): Revamp using lists.
(enum mu_cfg_cont_type, struct mu_cfg_cont): New types.
(mu_config_create_container, mu_config_clone_container)
(mu_config_destroy_container): New functions.
(mu_parse_config): New function.
* include/mailutils/mu_auth.h (mu_authentication_clear_list)
(mu_authorization_clear_list): New functions.
* mailbox/cfg_lexer.c: Add missing includes
(mu_config_create_container, mu_config_clone_container)
(mu_config_destroy_container): New functions.
(mu_parse_config): New function.
(_mu_config_register_section): New function.
(mu_config_register_section): New function.
(_mu_parse_config): Fully implement system-wide/per-user
configuration semantics.
(mu_parse_config): Take two more arguments.
* mailbox/cfg_parser.h: Remove automatically generated file.
* mailbox/cfg_parser.y (find_container): New function
(find_subsection,find_param): Rewrite using find_container
(parse_param): Implement new data type mu_cfg_time (time_t value).
(_scan_tree_helper): Complain about unknown sections only if
MU_CONFIG_VERBOSE environment variable is set.
* mailbox/mu_argp.c (assign_string): Bugfix.
(mu_argp_set_config_param): New function.
(mu_argp_parse): Remove eventual `lt-' prefix from program names.
* mailbox/mu_auth.c: New options --clear-authorization and
--clear-authentication.
(mu_authorization_clear_list,mu_authentication_clear_list): New
functions.
* include/mailutils/refcount.h (struct _mu_refcount): Move to
refcount.c
(mu_refcount_inc,mu_refcount_dec): Change return value.
(mu_refcount_value): New function.
* mailbox/refcount.c (struct _mu_refcount): Moved from refcount.h
(mu_refcount_value): New function.
(mu_refcount_create,mu_refcount_destroy,mu_refcount_inc)
(mu_refcount_dec): Fix monitor usage.
(mu_refcount_inc,mu_refcount_dec): Fix return type.
* mailbox/Makefile.am (libmailutils_la_SOURCES): Add refcount.c
* dotlock/dotlock.c, imap4d/imap4d.c, mail.local/main.c,
mail.remote/mail.remote.c, mimeview/mimeview.c,
movemail/movemail.c, pop3d/pop3d.c, pop3d/signal.c,
readmsg/readmsg.c, sieve/sieve.c: Implement new configuration.
* testsuite/lib/mailutils.exp: Set MU_CONFIG_FLAVOR envar to
`none' to avoid reading configuration files.
2007-11-06 Sergey Poznyakoff <gray@gnu.org.ua>
* mailbox/message.c (message_stream_size): Bugfix.
2007-11-05 Sergey Poznyakoff <gray@gnu.org.ua>
Implement socket stream type and shutdown method for streams:
* mailbox/socket_stream.c: New file.
* include/mailutils/stream.h (mu_socket_stream_create)
(mu_stream_shutdown, mu_stream_set_shutdown): New functions.
* libproto/include/stream0.h (struct _mu_stream): New member
`_shutdown'.
* mailbox/file_stream.c (mu_stream_create): Bugfix.
* mailbox/stream.c (mu_stream_shutdown)
(mu_stream_set_shutdown): New functions.
* mailbox/tcp.c (_tcp_shutdown): New function.
(_tcp_stream_init): New function.
(mu_tcp_stream_create_with_source_ip): Register _tcp_shutdown.
Implement normal UNIX-style configuration files:
* mailbox/cfg_lexer.c: New file.
* mailbox/cfg_parser.y: New file.
* mailbox/cfg_parser.h: New file.
* mailbox/Makefile.am: Add cfg_ sources and socket_stream.c.
* include/mailutils/cfg.h: New file.
* include/mailutils/Makefile.am (pkginclude_HEADERS): Add cfg.h.
* include/mailutils/argp.h: Include cfg.h.
(mu_create_argcv): Remove prototype.
* include/mailutils/mu_auth.h (struct mu_auth_module): New member
`cfg'.
(MU_AUTH_REGISTER_ALL_MODULES): Call mu_auth_init first.
* mailbox/mu_argp.c: Rewrite. Implement normal configuration
(resource) file support. Overloaded command line options begin to
phase out.
* mailbox/mu_auth.c, auth/gsasl.c, auth/pam.c, auth/radius.c,
auth/sql.c, auth/tls.c, auth/virtual.c, libsieve/argp.c,
mailbox/system.c: Implement configuration statements.
* imap4d/imap4d.c: Begin switching to the new configuration scheme.
* mh/mh_whatnow.c, mh/send.c, sql/mysql.c, sql/odbc.c,
sql/postgres.c: Keep the namespace clean.
2007-10-24 Sergey Poznyakoff <gray@gnu.org.ua>
* mail/escape.c (escape_deadletter): Add missing check.
2007-10-12 Sergey Poznyakoff <gray@gnu.org.ua>
* NEWS: Update
* mailbox/url.c (url_parse0): The notation proto:///file means
absolute file name.
* mailbox/testsuite/Urls: Likewise
2007-09-04 Sergey Poznyakoff <gray@gnu.org.ua>
* README: Reword yesterdays changing by pointing to the
documentation, instead of the raw texi file.
* doc/texinfo/Makefile.am (master-menu, untabify, final): New
goals.
* doc/texinfo/mastermenu.el, doc/texinfo/untabify.el: New files
* doc/texinfo/mailutils.texi: Rebuild master menu.
2007-09-03 Darel Henman <dhenman@gmail.com>
* README: Edited text in README file related to the
-enable-mh-utils option. This was to correct a reference from
a now non-existent mh README file to the ..doc/texinfo/mh-mh.texi file.
2007-08-27 Sergey Poznyakoff <gray@gnu.org.ua>
* config/mailutils-config.c (lib_descr): Add mailer.
* doc/texinfo/programs.texi (Loader Flags): Update
2007-08-24 Darel Henman <dhenman@gmail.com>
* mailbox/mailer.c: Include <sys/time.h> to fix builds on CygWin.
2007-08-21 Sergey Poznyakoff <gray@gnu.org.ua>
* examples/mta.c: Accommodate for the change from 2007-08-09
2007-08-18 Wojciech Polak <polak@gnu.org>
* doc/texinfo/mailutils.texi (References): Added RFC 2487 and 2595.
* doc/texinfo/url.texi (URL): Document POPS and IMAPS protocols.
2007-08-09 Sergey Poznyakoff <gray@gnu.org.ua>
* libproto/mailer/smtp.c (smtp_send_message): Do not output space
character after MAIL FROM: and RCPT TO:
2007-07-18 Wojciech Polak <polak@gnu.org>
Added support for new protocols: POPS (pops://)
and IMAPS (imaps://).
* include/mailutils/registrar.h: Register new protocols:
mu_pops_record and mu_imaps_record.
* libproto/imap/folder.c (_imaps_record, mu_imaps_record): Added.
(folder_imap_open): Handle IMAPS connection.
* libproto/imap/mbox.c (_mailbox_imap_and_imaps_init): New function.
(_mailbox_imaps_init): Likewise.
(_mailbox_imap_init): Call _mailbox_imap_and_imaps_init.
* libproto/include/imap0.h (_f_imap): Added new variable imaps.
* libproto/include/registrar0.h (MU_IMAPS_PORT, MU_IMAPS_SCHEME)
(MU_IMAPS_SCHEME_LEN): Added new constants.
(MU_POPS_PORT, MU_POPS_SCHEME, MU_POPS_SCHEME_LEN): Likewise.
* libproto/pop/folder.c (_pops_record, mu_pops_record): Added.
* libproto/pop/mbox.c (_pop_data): Added new variable pops.
(_mailbox_pop_and_pops_init): New function.
(_mailbox_pops_init): Likewise.
(_mailbox_pop_init): Call _mailbox_pop_and_pops_init.
(pop_open): Handle POPS connection.
2007-07-18 Wojciech Polak <polak@gnu.org>
* libproto/mailer/Makefile.am (libmu_mailer_la_SOURCES):
Added url_sendmail.c and url_smtp.c.
* libproto/mailer/url_sendmail.c: Moved from mailbox/url_sendmail.c.
(_url_sendmail_init): Call mu_url_init.
* libproto/mailer/url_smtp.c: Moved from mailbox/url_smtp.c.
(_url_smtp_init): Call mu_url_init.
* libproto/pop/url.c (_url_pop_init, _url_pops_init): Call mu_url_init.
* libproto/imap/url.c (_url_imap_init, _url_imaps_init): Likewise.
* mailbox/Makefile.am (libmailutils_la_SOURCES):
Removed url_sendmail.c and url_smtp.c.
* mailbox/url_sendmail.c: Moved to libproto/mailer/url_sendmail.c.
* mailbox/url_smtp.c: Moved to libproto/mailer/url_smtp.c.
* mailbox/url.c (mu_url_init): New function.
* include/mailutils/url.c (mu_url_init): New prototype.
2007-07-17 Sergey Poznyakoff <gray@gnu.org.ua>
* include/mailutils/libsieve.h (mu_stream_printf): Remove
conflicting prototype.
2007-07-17 Wojciech Polak <polak@gnu.org>
* libproto/mailer: New directory. Keeps libmu_mailer.la.
* libproto/mailer/Makefile.am: New file.
* libproto/mailer/sendmail.c: Moved from mailbox/sendmail.c.
* libproto/mailer/smtp.c: Moved from mailbox/smtp.c.
* libproto/Makefile.am (SUBDIR): Added mailer.
* examples/Makefile.am, guimb/Makefile.am, libmu_scm/Makefile.am,
mail/Makefile.am, mail.remote/Makefile.am, mh/Makefile.am,
sieve/Makefile.am: Added ${MU_LIB_MAILER}.
* mailbox/sendmail.c: Moved to libproto/mailer/sendmail.c.
* mailbox/smtp.c: Moved to libproto/mailer/smtp.c.
* mailbox/mutil.c (mu_tls_begin): Removed placeholder.
* mailbox/Makefile.am (libmailutils_la_SOURCES):
Removed sendmail.c and smtp.c.
* configure.ac: Added MU_LIB_MAILER.
2007-07-16 Sergey Poznyakoff <gray@gnu.org.ua>
* mh/mh_ctx.c (mh_context_read): Avoid writing past blurb end.
* mh/send.c: New mtstailor variable "username"
2007-07-14 Sergey Poznyakoff <gray@gnu.org.ua>
* imap4d/imap4d.h (util_parse_822_date): First arg is const
* imap4d/util.c: Likewise.
* imap4d/search.c: Rewrite using parse tree instead of instruction
array. Implement boolean shortcut evaluation.
2007-07-10 Sergey Poznyakoff <gray@gnu.org.ua>
* imap4d/fetch.c, imap4d/select.c, imap4d/status.c, mh/inc.c,
mh/mh_init.c, pop3d/bulletin.c: Fix format strings
* imap4d/search.c, libproto/mbox/folder.c, mailbox/envelope.c,
examples/url-parse.c, mailbox/mu_auth.c: Minor fixes
* include/mailutils/libsieve.h (mu_stream_printf): Remove
* libsieve/actions.c (mu_stream_printf): Remove
(mime_create_ds): Bugfix: datestr was never initialized! Nobody
noticed this far?
2007-07-10 Wojciech Polak <polak@gnu.org>
* auth/tls.c (mu_tls_begin): New function.
(_tls_stream_push): Added mu_error call.
(_tls_open_client): Return MU_ERR_FAILURE instead of -1.
* include/mailutils/tls.h (mu_tls_readline_fn)
(mu_tls_writeline_fn, mu_tls_stream_ctl_fn): New data types.
(mu_tls_begin): New prototype.
* mailbox/mutil.c (mu_tls_begin): Placeholder.
* libproto/pop/mbox.c (pop_parse_capa): New function.
(pop_capa): Send CAPA, but don't parse the response,
call pop_parse_capa() instead.
(pop_reader, pop_writer, pop_stream_ctl): New static functions.
(pop_stls): Uses now mu_tls_begin() from libmuauth.
* libproto/imap/folder.c: (imap_reader, imap_writer)
(imap_stream_ctl): New static functions.
(tls): Uses now mu_tls_begin() from libmuauth.
(folder_imap_open): Use MU_IMAP_PORT.
* mailbox/smtp.c: Added STARTTLS support.
(smtp_parse_ehlo_ack): New function.
(smtp_starttls): New function.
(stmp_reader, smtp_writer, smtp_stream_ctl): New static
functions.
* mailbox/stream.c: (mu_stream_vprintf)
(mu_stream_printf, mu_stream_sequential_vprintf)
(mu_stream_sequential_printf): New functions.
* include/mailutils/stream.h: (mu_stream_vprintf)
(mu_stream_printf, mu_stream_sequential_vprintf)
(mu_stream_sequential_printf): New prototypes.
2007-07-09 Sergey Poznyakoff <gray@gnu.org.ua>
* NEWS, configure.ac: Version 1.2.1
* THANKS: Add Robby Villegas
* examples/mta.c, libproto/imap/folder.c, libproto/nntp/folder.c,
mimeview/mimetypes.l: Fix format string
* libproto/imap/mbox.c: Minor fixes
* mail/mail.c (mail_mainloop): Use "%s" to properly pass command
to util_do_command. Remove call to util_escape_percent
* mail/mail.h, mail/util.c (util_escape_percent): Delete
* libproto/include/envelope0.h (date,sender): New members
(_sender,_date): Rename to _get_sender, _get_date
[__cplusplus]: Add missing }
* include/mailutils/envelope.h, mailbox/envelope.c
(mu_envelope_get_sender)
(mu_envelope_sget_sender, mu_envelope_aget_sender)
(mu_envelope_get_date, mu_envelope_sget_date)
(mu_envelope_aget_date): New functions
(mu_envelope_sender, mu_envelope_date): Rewrite as macros
* guimb/util.c, imap4d/append.c, imap4d/fetch.c, imap4d/search.c,
libmu_scm/mu_message.c, libsieve/actions.c, libsieve/tests.c,
mail/from.c, mailbox/amd.c, mailbox/mutil.c,
readmsg/readmsg.c: Rewrite using new envelope accessors
* libproto/mbox/mbox.c (write_array): New function
(mbox_append_message0): Rewrite using new envelope accessors +
write_array
2007-07-06 Sergey Poznyakoff <gray@gnu.org.ua>
* configure.ac (INTLINCS): Remove leftover variable
(MU_LINK_POSTFLAGS): New subst
* auth/Makefile.am, comsat/Makefile.am,
dotlock/Makefile.am, examples/Makefile.am,
examples/cpp/Makefile.am, frm/Makefile.am, guimb/Makefile.am,
imap4d/Makefile.am, lib/Makefile.am, libmu_cpp/Makefile.am,
libmu_scm/Makefile.am, libproto/imap/Makefile.am,
libproto/maildir/Makefile.am, libproto/mbox/Makefile.am,
libproto/mh/Makefile.am, libproto/nntp/Makefile.am,
libproto/pop/Makefile.am, libsieve/Makefile.am,
libsieve/extensions/Makefile.am, mail/Makefile.am,
mail.local/Makefile.am, mail.remote/Makefile.am,
mailbox/Makefile.am, messages/Makefile.am, mh/Makefile.am,
mimeview/Makefile.am, movemail/Makefile.am,
pop3d/Makefile.am, readmsg/Makefile.am, sql/Makefile.am,
sieve/Makefile.am(INCLUDES): Remove INTLINCS
* config/Makefile.am (INCLUDES): Remove INTLINCS
(mailutils_config_CFLAGS): Use MU_LINK_POSTFLAGS
2007-07-05 Sergey Poznyakoff <gray@gnu.org.ua>
* NEWS: Update
* configure.ac: Change library version info
* examples/url-parse.c: Rewrite using sget accessors
* include/mailutils/url.h, mailbox/url.c (mu_url_sget_scheme)
(mu_url_aget_scheme, mu_url_sget_user, mu_url_aget_user)
(mu_url_sget_passwd, mu_url_aget_passwd, mu_url_sget_auth)
(mu_url_aget_auth, mu_url_sget_host, mu_url_aget_host)
(mu_url_sget_path, mu_url_aget_path, mu_url_sget_query)
(mu_url_aget_query): New functions
(mu_url_get_scheme, mu_url_get_user, mu_url_get_passwd)
(mu_url_get_auth, mu_url_get_host, mu_url_get_path)
(mu_url_get_query)
(mu_url_is_same_scheme, mu_url_is_same_user, mu_url_is_same_path)
(mu_url_is_same_host, mu_url_is_same_port): Rewrite using sget
accessors.
* libproto/imap/folder.c, libproto/imap/mbox.c,
libproto/mbox/folder.c, libproto/mbox/mbox.c,
libproto/nntp/folder.c, libproto/nntp/mbox.c, libproto/pop/mbox.c,
mailbox/amd.c, mailbox/sendmail.c, mailbox/smtp.c,
mailbox/wicket.c: Use mu_url_sget or mu_url_aget, depending on the
needs.
* mailbox/mailbox.c (mu_mailbox_get_debug): Propagate the debug
state to the underlying folder.
2007-07-03 Sergey Poznyakoff <gray@gnu.org.ua>
* mail.local/Makefile.am (mail_local_LDADD): Add missing
libraries. Reported by Robby Villegas.
2007-07-01 Sergey Poznyakoff <gray@gnu.org.ua>
* mailbox/assoc.c (assoc_rehash): Fix an incorrect element
size calculation.
2007-06-29 Sergey Poznyakoff <gray@gnu.org.ua>
* COPYING, COPYING.LESSER: Install official versions
* configure.ac, NEWS: Version 1.2
* libsieve/extensions/spamd.c: Append `X-' headers.
* mail.local/main.c: Read message contents from the message
stream, so any changes to its headers and/or body are propagated
to the final delivery.
2007-06-28 Sergey Poznyakoff <gray@gnu.org.ua>
* configure.ac: Remove the definition of ARG_UNUSED
* mailbox/header.c (mu_hdrent_create): Minor change
* libsieve/argp.c (sieve_argp_parser): Bug fix
* libsieve/prog.c (sieve_code_command: Bug fixes
* include/mailutils/types.hin (MU_ARG_UNUSED, MU_PRINTFLIKE): New
macros.
* lib/daemon.c: Use __attribute__ instead of ARG_UNUSED
* auth/pam.c, auth/radius.c, auth/sql.c, auth/virtual.c,
examples/nntpclient.c, examples/pop3client.c, imap4d/capability.c,
imap4d/check.c, imap4d/close.c, imap4d/fetch.c,
libproto/imap/folder.c, libproto/imap/url.c,
libproto/maildir/folder.c, libproto/maildir/mbox.c,
libproto/mbox/folder.c, libproto/mbox/url.c, libproto/mh/folder.c,
libproto/mh/mbox.c, libproto/nntp/url.c, libproto/pop/mbox.c,
libproto/pop/url.c, libsieve/util.c, libsieve/extensions/spamd.c,
mail/decode.c, mail/escape.c, mail/exit.c, mail/folders.c,
mail/if.c, mail/inc.c, mail/list.c, mail/mail.c, mail/mailline.c,
mail/msgset.y, mail/quit.c, mail/source.c, mail/summary.c,
mail/tag.c, mail/version.c, mailbox/amd.c, mailbox/auth.c,
mailbox/file_stream.c, mailbox/filter_iconv.c,
mailbox/filter_trans.c, mailbox/message_stream.c,
mailbox/monitor.c, mailbox/mu_auth.c, mailbox/parsedate.y,
mailbox/system.c, mailbox/url_sendmail.c, mh/ali.c,
mh/mhparam.c, pop3d/auth.c, pop3d/signal.c, sql/odbc.c: Use
MU_ARG_UNUSED to mark unused formal parameters.
* guimb/guimb.h, imap4d/imap4d.h, include/mailutils/debug.h,
include/mailutils/error.h, include/mailutils/libsieve.h,
include/mailutils/nntp.h, include/mailutils/pop3.h,
libproto/include/imap0.h, libsieve/sieve.h, mail/mail.h,
mail.local/mail.local.h, mh/mh.h, pop3d/pop3d.h: Mark printf-like
calls with MU_PRINTFLIKE.
* po/Makevars (XGETTEXT_OPTIONS): Add Mailutils-specific
printf-like calls.
* NEWS: Update
* include/mailutils/header.h (mu_header_append,mu_header_prepend):
New functions
* mailbox/header.c: Likewise
* include/mailutils/mailer.h (mu_mailer_send_fragments): New
function
* mailbox/mailer.c: Likewise
* include/mailutils/mutil.h (mu_rfc2822_msg_id): New function
* mailbox/mutil.c: Likewise
* mailbox/mime.c (_mime_set_content_type): Avoid risky usage of
static buffers.
* mh/TODO: Update
* mh/mh_getopt.h (ARG_CHUNKSIZE): New value
* mh/mh_init.c (mh_create_message_id): Rewrite using
mu_rfc2822_msg_id
* mh/send.c: Implement `--send'.
2007-06-27 Sergey Poznyakoff <gray@gnu.org.ua>
Prepare for the GPL v.3 release.
Relicense programs under GPL v.3, libraries under LPGL v.3
2007-06-27 Sergey Poznyakoff <gray@gnu.org.ua>
* examples/header.c: Implement a terse runtime help.
2007-06-26 Sergey Poznyakoff <gray@gnu.org.ua>
* NEWS: Update
* mailbox/header.c (header_readline): Always nul-terminate the
buffer.
(mu_hdrent_find): Allow negative instance indices, meaning
scanning from the bottom up.
* include/mailutils/list.h: Fix typo
* libsieve/argp.c: New option --clearpath
* libsieve/load.c: Minor change
* libsieve/sieve.h: Minor change
* sieve/testsuite/sieve/ext.exp: Pass --clearpath option to sieve
* mh/anno.c, mh/burst.c, mh/comp.c, mh/compcommon.c, mh/folder.c,
mh/forw.c, mh/inc.c, mh/mark.c, mh/mh.h, mh/mh_alias.y,
mh/mh_argp.c, mh/mh_ctx.c, mh/mh_global.c, mh/mh_init.c,
mh/mh_msgset.c, mh/mh_sequence.c, mh/mh_whatnow.c, mh/mh_whom.c,
mh/mhl.c, mh/mhn.c, mh/mhparam.c, mh/mhpath.c, mh/pick.c,
mh/refile.c, mh/repl.c, mh/rmf.c, mh/rmm.c, mh/scan.c, mh/send.c,
mh/sortm.c, mh/whom.c: Use mu_header_sget to retrieve context and
configuration settings. Update all callers.
* include/mailutils/header.h (MU_HEADER_REPLACE)
(MU_HEADER_BEFORE): New macros
(mu_header_remove,mu_header_insert)
(mu_header_sget_value_n,mu_header_get_value_n)
(mu_header_aget_value_n,mu_header_get_address_n)
(mu_header_sget_field_name,mu_header_sget_field_value)
(mu_header_get_value_unfold_n,mu_header_aget_value_unfold_n): New
functions;
(mu_header_sget_value,mu_header_get_value,mu_header_aget_value)
(mu_header_get_address,mu_header_get_value_unfold)
(mu_header_aget_value_unfold): Rewrite as macros
(mu_header_set_set_value,mu_header_set_get_value)
(mu_header_set_size,mu_header_set_lines): Remove functions
* libproto/include/header0.h: Rewrite from scratch
* mailbox/header.c: Rewrite from scratch
* examples/header.c: New program
* examples/Makefile.am (noinst_PROGRAMS): Add header
* examples/addr.c: Remove unused vars
* lib/mu_dbm.c, libproto/maildir/mbox.c, mh/mh_format.c: Remove
unused functions
* libmu_scm/mu_message.c (_get_envelope_sender): Bugfix: the return
value was wrong.
* examples/mimetest.c, libproto/imap/mbox.c, libproto/mbox/mbox.c,
libsieve/actions.c, mail/decode.c, mail/escape.c, mail/mail.h,
mail/print.c, mail/retain.c, mail/send.c, mail.local/mailquota.c,
mailbox/amd.c, mailbox/sendmail.c: Prefer mu_header_sget
where possible. Remove obsolete header calls.
* mail.remote/testsuite/Data: Remove extra white space
* mail.local/main.c (main): Register all mailbox formats
* mailbox/mime.c: Fix indentation
* mh/mhn.c: shut up the gcc warning
2007-06-24 Sergey Poznyakoff <gray@gnu.org.ua>
* NEWS: Update
* examples/addr.c, examples/mta.c, frm/common.c, imap4d/fetch.c,
libmu_scm/mu_message.c, mail/alias.c, mail/alt.c, mail/from.c,
mail/mail.h, mail/reply.c, mail/send.c, mail/util.c,
mailbox/attachment.c, mailbox/mutil.c, mailbox/sendmail.c,
mailbox/smtp.c, mh/mh.h, mh/mh_format.c, mh/mh_format.h,
mh/mh_init.c: Use mu_address_sget functions, where possible.
* include/mailutils/address.h (mu_address_set_local_part)
(mu_address_set_domain,mu_address_set_route)
(mu_address_set_email,mu_address_sget_comments)
(mu_address_sget_local_part,mu_address_sget_personal)
(mu_address_sget_domain,mu_address_sget_route)
(mu_address_sget_email): New functions
* mailbox/address.c: Likewise
2007-06-22 Sergey Poznyakoff <gray@gnu.org.ua>
* configure.ac: Use AM_PROG_CC_C_O and AC_PROG_CXX
* include/mailutils/property.h (mu_property_sget_value)
(mu_property_aget_value): New functions
* mailbox/property.c: Likewise
* mailbox/Makefile.am: Merge DEFS and AM_CPPFLAGS
* mailbox/mailer.c (mu_mailer_send_message): Set envelope from
address according to the underlying mailer type.
* mailbox/smtp.c (smtp_open,smtp_send_message): On invalid
arguments, return EINVAL instead of spitting out assertion.
(smtp_send_message): Null from address is an error.
* mh/sortm.c: Stable sort.
2007-05-14 Sergey Poznyakoff <gray@gnu.org.ua>
* README: Fix typos, use LDFLAGS instead of LIBS
* auth/tls.c (_tls_stream_push): Flush data. before returning.
2007-05-09 Sergey Poznyakoff <gray@gnu.org.ua>
* scripts/ylwrap: Rename to ...
* scripts/gylwrap: ... this
* doc/texinfo/Makefile.am, libsieve/Makefile.am,
mailbox/Makefile.am, mailbox/Makefile.am, mh/Makefile.am,
mimeview/Makefile.am, scripts/Makefile.am: Update to the
above change.
2007-05-08 Sergey Poznyakoff <gray@gnu.org.ua>
* Makefile.am (alpha): Change distdir format
* examples/mimetest.c: Print more information about the message
structure.
* mailbox/mime.c (_mime_parse_mpart_message): One more fix
* mailbox/testsuite/Mime: Fix to match new mimetest output and
bugfixes in mime.c
* imap4d/testsuite/imap4d/fetch.exp, mail/testsuite/mail/read.exp,
mail/testsuite/mail/write.exp,
readmsg/testsuite/readmsg/test.exp: Update to match bugfixes in
mime.c
* testsuite/spool/mbox1: Fix msg#5
2007-05-07 Sergey Poznyakoff <gray@gnu.org.ua>
* mailbox/daemon.c (mu_daemon_remove_pidfile): Reset pidfile.
2007-04-30 Sergey Poznyakoff <gray@gnu.org.ua>
* configure.ac (MU_BUILT_CXX_EXAMPLES): Define if c++ libs
requested.
* examples/cpp/Makefile.am: Build c++ examples
* libmu_cpp/Makefile.am (libmu_cpp_la_LDFLAGS): Add -rpath
2007-04-30 Wojciech Polak <polak@gnu.org>
* libproto/pop/mbox.c: Fixed APOP handling.
2007-04-12 Sergey Poznyakoff <gray@gnu.org.ua>
* mailbox/header.c (mu_header_get_value): Bugfix
* mailbox/mbx_default.c (mu_mailbox_create_default): Fix memory
leaks.
2007-03-16 Sergey Poznyakoff <gray@gnu.org.ua>
* pop3d/bulletin.c (read_bulletin_db): Do not close DB too early.
2007-03-07 Sergey Poznyakoff <gray@gnu.org.ua>
* imap4d/testsuite/imap4d/expunge.exp: Fix pattern
* include/mailutils/assoc.h (mu_assoc_create): Add third argument.
(mu_assoc_destroy,mu_assoc_clear): New functions
* include/mailutils/header.h (mu_header_set_get_fvalue): Remove
function.
* libproto/imap/mbox.c (imap_header_get_fvalue): Remove
* libproto/include/header0.h (struct _mu_header): Remove
`fhdr_count' and `fhdr', add `cache'.
Remove `_get_fvalue'
* libproto/mbox/mbox.c: Remove rudimentary header caching
* libproto/mbox/mbox0.h: Likewise
* libproto/mbox/mboxscan.c: Likewise
* mail/alias.c, mailbox/mutil.c: Update calls to mu_assoc_create
* mailbox/assoc.c (mu_assoc_create): Take 3 arguments
(mu_assoc_clear, mu_assoc_destroy): New functions
* mailbox/header.c: Rewrite header caching
* include/mailutils/locker.h: Rewrite
* mailbox/locker.c: Rewrite
2007-03-06 Sergey Poznyakoff <gray@gnu.org.ua>
* mailbox/mime.c (_mime_parse_mpart_message): The CRLF preceding
the encapsulation line is conceptually attached to the boundary.
* NEWS: Update
2007-02-27 Sergey Poznyakoff <gray@gnu.org.ua>
* Makefile.am: Add libmu_cpp
* NEWS, README: Update
* configure.ac: Add `--enable-experimental' option
Rewrite DBM handling
Withdraw old DBM support
* auth/sql.c: Actually set quota if it is available
* include/mailutils/mu_auth.h (struct mu_auth_data): New field
`flags'.
(mu_auth_data_set_quota): New function
* lib/mu_dbm.h, lib/mu_dbm.c: Withdraw old DBM support. Fix style
issues.
* mail.local/mail.local.h (check_quota): Change signature
* mail.local/mailquota.c: Get quota value from mu_auth_data, if
available.
* mail.local/main.c (check_quota): Change signature
* mailbox/mu_auth.c (mu_auth_data_alloc): Fill auth object with
zeroes.
(mu_auth_data_set_quota): New function
* pop3d/apop.c: Remove unused variables
* pop3d/bulletin.c (deliver_pending_bulletins): Return
immediately, if unable to count messages in the bulletin box
* pop3d/popauth.c (action_list): Do not check db permissions.
* pop3d/bulletin.c (read_bulletin_db,write_bulletin_db): Fix
permissions.
(open_bulletin_mailbox): Open the mailbox in read-only mode
(set_bulletin_db): Do not try to open the mailbox.
2007-02-25 Sergey Poznyakoff <gray@gnu.org.ua>
* pop3d/bulletin.c: Fix copyright year
* pop3d/expire.c, pop3d/top.c: A message is marked for expiration
after RETR or TOP.
* pop3d/logindelay.c (check_login_delay): Fix error message
* pop3d/pop3d.c (pop3d_parse_opt): --expire=0 implies
--delete-expired.
* doc/texinfo/programs.texi: Document new pop3d options
* libproto/mbox/mbox.c: Indentation fixes
* NEWS: Update
2007-02-23 Sergey Poznyakoff <gray@gnu.org.ua>
* auth/sql.c: Implement field mapping and retrieval by field
names.
* include/mailutils/mu_auth.h (struct mu_auth_data.quota): New
field
(mu_auth_data_destroy): New function
* include/mailutils/mutil.h (mutil_parse_field_map): New function
* include/mailutils/sql.h (mu_sql_dispatch.get_field_number): New
field
(mu_sql_get_field): New function
* lib/mu_dbm.c, lib/mu_dbm.h (mu_dbm_datum_free): New function
* mailbox/mu_auth.c (mu_auth_data_destroy): New function
* mailbox/mutil.c (mutil_parse_field_map): New function
* pop3d/bulletin.c: Implement bulletin facility
* pop3d/Makefile.am: Add bulletin.c
* pop3d/apop.c (pop3d_apop): Call pop3d_begin_session instead of
duplicating code from user.c
* pop3d/pop3d.c (--bulletin-source, --bulletin-db): New options
* pop3d/pop3d.h (auth_data): New global
* pop3d/user.c (pop3d_begin_session): New function. Implement
bulletin facility
* pop3d/popauth.c (action_list): Call mu_dbm_datum_free
* readmsg/readmsg.c (main): -h shows `From ' headers as well.
* readmsg/testsuite/readmsg/test.exp: Adapt for the new readmsg
behavior
* sql/sql.c, sql/mysql.c, sql/odbc.c, sql/postgres.c: Implement
retrieval by field name.
2007-02-22 Sergey Poznyakoff <gray@gnu.org.ua>
* mailbox/assoc.c: New file. Implementation of associative arrays.
* mailbox/Makefile.am: Add assoc.c
* mailbox/errors (MU_ERR_EXISTS): New error code
* include/mailutils/assoc.h: New file
* include/mailutils/Makefile.am: Add assoc.h
* auth/radius.c (mu_radius_authenticate): Remove unused variable
* include/mailutils/iterator.h (mu_iterator_current_kv): New
function
(mu_iterator_set_getitem): Change signature. All references
updated.
* mailbox/iterator.c: Likewise
* libproto/nntp/nntp_iterator.c, libproto/pop/pop3_iterator.c,
mailbox/list.c: Likewise
* include/mailutils/types.hin (mu_assoc_t): New data type
* libproto/include/iterator0.h (getitem): Change signature
* mail/alias.c: Reimplement using mu_assoc_t
* mail/mail.h: Include mailutils/assoc.h
* mailbox/mu_argp.c: Improve diagnostics of errors in rc files.
2007-02-13 Sergey Poznyakoff <gray@gnu.org.ua>
* mail/pipe.c (mail_pipe): Fix handling of cmd variable and
command argument.
* mail/send.c (compose_destroy): Do not free outfiles[i], the
caller is responsible for that.
* mailbox/amd.c (amd_envelope_date, amd_envelope_sender): If buf
is NULL, return required length of the buffer.
* mailbox/argcv.c (argcv_get_n): Prevent coredump if command='"'
* mailbox/testsuite/Argcv: Test '"' case.
* mailbox/header.c: Indentation fix
* readmsg/readmsg.c: Improve compatibility with elm's
implementation.
* readmsg/readmsg.h: Add some includes
* THANKS: Add Neil R. Ormos
* NEWS: Update
2006-12-31 Wojciech Polak <polak@gnu.org>
Updated libmu_cpp to the current API 1.0.
All method names now begin with a lowercase letter.
Files affected:
* libmu_cpp/address.cc, libmu_cpp/filter.cc, libmu_cpp/header.cc,
libmu_cpp/iterator.cc, libmu_cpp/list.cc, libmu_cpp/mailbox.cc,
libmu_cpp/mailcap.cc, libmu_cpp/mailer.cc, libmu_cpp/message.cc,
libmu_cpp/pop3.cc, libmu_cpp/stream.cc, libmu_cpp/url.cc,
include/mailutils/cpp/address.h, include/mailutils/cpp/error.h,
include/mailutils/cpp/filter.h, include/mailutils/cpp/header.h,
include/mailutils/cpp/iterator.h, include/mailutils/cpp/list.h,
include/mailutils/cpp/mailbox.h, include/mailutils/cpp/mailcap.h,
include/mailutils/cpp/mailer.h, include/mailutils/cpp/mailutils.h,
include/mailutils/cpp/message.h, include/mailutils/cpp/pop3.h,
include/mailutils/cpp/stream.h, include/mailutils/cpp/url.h
* examples/cpp/addr.cc, examples/cpp/http.cc, examples/cpp/iconv.cc,
examples/cpp/listop.cc, examples/cpp/mailcap.cc, examples/cpp/murun.cc,
examples/cpp/sfrom.cc, examples/cpp/url-parse.cc: Updated.
* libmu_cpp/Makefile.am: Updated.
2006-12-29 Sergey Poznyakoff <gray@gnu.org.ua>
* configure.ac, NEWS: Version 1.1.90
* mail/mail.c (default_setup): Set nullbody and nullbodymsg
* mail/send.c: Sent empty messages only if nullbody is set
* mailbox/amd.c (amd_open): Create directory if MU_STREAM_CREAT is
given.
* mimeview/mimeview.c (doc): Remove leftover \v
* doc/texinfo/programs.texi (Mail Variables): Document nullbody
and nullbodymsg
2006-12-15 Sergey Poznyakoff <gray@gnu.org.ua>
* configure.ac: Require at least version 2.60 of autoconf
* include/mailutils/stream.h (MU_STREAM_READY_EX): New define
* mail.local/main.c: Allow to be run from console by a
non-privileged user (useful with fetchmail)
* mailbox/mutil.c (mu_fd_wait): Handle MU_STREAM_READY_EX
* mailbox/sendmail.c (sendmail_send_message): Failing waitpid is
not an error if errno==ECHILD (the calling program might have
ignored SIGCHLD).
2006-11-13 Sergey Poznyakoff <gray@gnu.org.ua>
* configure.ac: Fix creation of MU_LTLIBOBJS. Patch submitted by
Kevin Buckley and Kenji Miyake
* include/mailutils/stream.h (MU_STREAM_READY_EX): New define
* mailbox/mutil.c (mu_fd_wait): Handle MU_STREAM_READY_EX
* mail.local/main.c
2006-10-30 Sergey Poznyakoff <gray@gnu.org.ua>
* configure.ac, NEWS: Raise version number to 1.1
* NEWS: Update
* mail.remote/mail.remote.c, sieve/sieve.c: Fix docstrings.
* libproto/imap/folder.c (imap_parse): Preserve the remainder of
the OK line after '[whatever]' for diagnostic purposes.
* doc/texinfo/programs.texi: Document changes to mail
* TODO: Update
* examples/encode2047.c: new options -o/-t enable/disable special
interpretation of the octal escapes in the input.
* mailbox/testsuite/Argcv: Comment out 8-bit test case. Sorry, tcl
looses badly in handling eight-bit binary data.
* mailbox/testsuite/Encode2047: Feed input in octal notation and
use encode2047 \o command to override tcl brokenness.
* mailbox/testsuite/mailbox/encode2047.exp: Allow test string to
begin with two back slashes.
* m4/.cvsignore: Update
* mail/escape.c (escape_sign): Print "-- \n" before the signature
* mail/mail.h: Remove the declaration of cursor
* mail/util.c: Allow use of ^ and $ as positioning commands
2006-10-25 Sergey Poznyakoff <gray@gnu.org.ua>
* configure.ac: Check for large file support and fseeko. Replace
the latter with fseek if it is not available.
(MU_GUILE_SITE_DIR,MU_GUILE_SIEVE_MOD_DIR)
(MU_GUILE_SIEVE_SCRIPTS,MU_GUILE_SIEVE_MOD_DATA): New variables
* guimb/scm/Makefile.am: Do not try to install anything if Guile
is not available
* libmu_scm/Makefile.am: Likewise
* mailbox/file_stream.c: Use fseeko instead of fseek
2006-10-20 Sergey Poznyakoff <gray@gnu.org.ua>
* NEWS: Updated
* doc/texinfo/programs.texi: Updated
* configure.ac (MU_GUILE_SITE_DIR,MU_GUILE_SIEVE_MOD_DIR)
(MU_GUILE_SIEVE_SCRIPTS,MU_GUILE_SIEVE_MOD_DATA): New variables to
clean build without Guile
* guimb/scm/Makefile.am: Likewise
* libmu_scm/Makefile.am: Likewise
* mail/escape.c (escape_sign): Print "-- \n" before the signature.
* mail/util.c (util_do_command): Implement ^ and $.
2006-10-18 Sergey Poznyakoff <gray@gnu.org.ua>
* configure.ac: Require gettext 0.15
(check_bdb): Bugfix
* m4/iconv.m4, m4/intmax.m4, m4/inttypes.m4, m4/nls.m4,
m4/printf-posix.m4, m4/progtest.m4: Update
* mail.local/main.c: Formatting fix
* scripts/gnulib-sync (copy_files): Adjust for gettext 0.15
2006-10-17 Sergey Poznyakoff <gray@gnu.org.ua>
* doc/texinfo/mu_address.texi: Added to the repository
* doc/texinfo/mu_body.texi: Likewise
* doc/texinfo/mu_logger.texi: Likewise
* doc/texinfo/mu_mailbox.texi: Likewise
* doc/texinfo/mu_message.texi: Likewise
* doc/texinfo/mu_mime.texi: Likewise
* doc/texinfo/mu_scm.texi: Likewise
* doc/texinfo/.cvsignore: Update
2006-10-16 Sergey Poznyakoff <gray@gnu.org.ua>
* configure.ac: Add support for Berkeley DB 3 and 4
* auth/radius.c: Return meaningful error codes.
* auth/sql.c: Likewise
* auth/virtual.c: Likewise
* mailbox/system.c: Likewise
* sql/mysql.c (octet2hex): Rename to mu_octet_to_hex to avoid name
clashes with mysql
* config/Makefile.am (mailutils_config_CFLAGS): Define I18NLIBS
unconditional.
* examples/Makefile.am (muath): New target
* include/mailutils/mu_auth.h (enum mu_auth_key_type): New data
type.
(mu_get_auth): New function.
* lib/mu_dbm.c: Support for Berkeley DB 3, 4
* mailbox/mu_auth.c (mu_get_auth): New function.
(mu_auth_runlist): Change return code convention: underlying calls
should return meaningful error codes, not just 0/1.
* examples/muauth.c: new file
2006-10-04 Sergey Poznyakoff <gray@gnu.org.ua>
* libsieve/extensions/vacation.c (vacation_subject): Improve
yesterday's fix, following Kostas' suggestion.
2006-10-03 Sergey Poznyakoff <gray@gnu.org.ua>
* libsieve/prog.c (sieve_code_command): Avoid dead loop if a tag
is not given the argument it requires. Improve the diagnostics.
Bug reported by Kostas Zorbadelos.
* libsieve/extensions/vacation.c (vacation_subject): Make sure
subject is not null.
2006-09-27 Sergey Poznyakoff <gray@gnu.org.ua>
* comsat/action.c: Minor fixes
* libproto/mbox/mboxscan.c (FAST_HEADER): Fix unfolding: Advance p
only if ':' was found.
Minor macro style fixes
* mail/mail.h (struct mail_env_entry): New member v.bool
* mail/set.c (mail_set): Init dummy to 1
* mail/util.c: mail_env_entry->set means that the entry was ever
set. mail_env_entry->v.bool is the actual value of boolean
variables.
* mail.local/main.c: Minor indentation fixes
* mailbox/mutil.c (mu_string_unfold): Convert \n followed by any
amount of whitespace to single space.
* mh/sortm.c: Minor fix
2006-09-10 Sergey Poznyakoff <gray@gnu.org.ua>
* dotlock/dotlock.c, mail.local/main.c, mail.remote/mail.remote.c,
mh/ali.c, mh/anno.c, mh/burst.c, mh/comp.c, mh/fmtcheck.c,
mh/folder.c, mh/forw.c, mh/inc.c, mh/install-mh.c, mh/mark.c,
mh/mhl.c, mh/mhn.c, mh/mhparam.c, mh/mhpath.c, mh/pick.c,
mh/refile.c, mh/repl.c, mh/rmf.c, mh/rmm.c, mh/scan.c, mh/send.c,
mh/sortm.c, mh/whom.c, mimeview/mimeview.c, sieve/sieve.c:
Reformat argp docstring in accordance with the new argp
guidelines. Remove unneeded translators comment.
* config/mailutils-config.c, mh/mh.h, mh/mh_getopt.c,
movemail/movemail.c: Include argp-namefrob.h is no longer needed
Update by gnulib-sync.
* lib/Makefile.am: Updated
* m4/gnulib.m4: Updated
* mailbox/Makefile.am: Updated
* lib/allocsa.c: Updated
* lib/allocsa.h: Updated
* lib/allocsa.valgrind: Updated
* lib/asprintf.c: Updated
* lib/error.c: Updated
* lib/error.h: Updated
* lib/exit.h: Updated
* lib/exitfail.c: Updated
* lib/exitfail.h: Updated
* lib/getpass.c: Updated
* lib/getpass.h: Updated
* lib/mbswidth.c: Updated
* lib/mbswidth.h: Updated
* lib/obstack.c: Updated
* lib/obstack.h: Updated
* lib/realloc.c: Updated
* lib/setenv.c: Updated
* lib/setenv.h: Updated
* lib/snprintf.c: Updated
* lib/snprintf.h: Updated
* lib/unsetenv.c: Updated
* lib/vasprintf.c: Updated
* lib/vasprintf.h: Updated
* lib/xalloc-die.c: Updated
* lib/xalloc.h: Updated
* lib/xmalloc.c: Updated
* lib/xsize.h: Updated
* m4/absolute-header.m4: Added to the repository
* m4/alloca.m4: Updated
* m4/allocsa.m4: Updated
* m4/argp.m4: Updated
* m4/d-type.m4: Updated
* m4/eealloc.m4: Updated
* m4/eoverflow.m4: Updated
* m4/error.m4: Updated
* m4/exitfail.m4: Updated
* m4/extensions.m4: Updated
* m4/fnmatch.m4: Updated
* m4/getdelim.m4: Updated
* m4/getline.m4: Updated
* m4/getlogin_r.m4: Updated
* m4/getopt.m4: Updated
* m4/getpass.m4: Updated
* m4/glob.m4: Updated
* m4/intmax_t.m4: Updated
* m4/inttostr.m4: Updated
* m4/inttypes_h_gl.m4: Updated
* m4/longdouble.m4: Updated
* m4/longdouble.m4: Updated
* m4/longlong_gl.m4: Updated
* m4/longlong_gl.m4: Updated
* m4/mbchar.m4: Updated
* m4/mbiter.m4: Updated
* m4/mbrtowc.m4: Updated
* m4/mbrtowc.m4: Updated
* m4/mbstate_t.m4: Updated
* m4/mbstate_t.m4: Updated
* m4/mbswidth.m4: Updated
* m4/md5.m4: Updated
* m4/memchr.m4: Updated
* m4/mempcpy.m4: Updated
* m4/minmax.m4: Updated
* m4/onceonly.m4: Updated
* m4/onceonly.m4: Updated
* m4/regex.m4: Updated
* m4/setenv.m4: Updated
* m4/sha1.m4: Updated
* m4/signed.m4: Updated
* m4/size_max.m4: Updated
* m4/snprintf.m4: Updated
* m4/ssize_t.m4: Updated
* m4/stat-macros.m4: Updated
* m4/stdbool.m4: Updated
* m4/stdint.m4: Updated
* m4/stdint_h_gl.m4: Updated
* m4/strcase.m4: Updated
* m4/strchrnul.m4: Updated
* m4/strdup.m4: Updated
* m4/strndup.m4: Updated
* m4/strnlen.m4: Updated
* m4/strtok_r.m4: Updated
* m4/sysexits.m4: Updated
* m4/unistd_h.m4: Updated
* m4/vasnprintf.m4: Updated
* m4/vasprintf.m4: Updated
* m4/vsnprintf.m4: Updated
* m4/wchar_t.m4: Updated
* m4/wcwidth.m4: Added to the repository
* m4/wint_t.m4: Updated
* m4/xalloc.m4: Updated
* m4/xsize.m4: Updated
* m4/xsize.m4: Updated
* mailbox/alloca.c: Updated
* mailbox/alloca_.h: Updated
* mailbox/argp-ba.c: Updated
* mailbox/argp-eexst.c: Updated
* mailbox/argp-fmtstream.c: Updated
* mailbox/argp-fmtstream.h: Updated
* mailbox/argp-fs-xinl.c: Updated
* mailbox/argp-help.c: Updated
* mailbox/argp-namefrob.h: Updated
* mailbox/argp-parse.c: Updated
* mailbox/argp-pin.c: Updated
* mailbox/argp-pv.c: Updated
* mailbox/argp-pvh.c: Updated
* mailbox/argp-xinl.c: Updated
* mailbox/argp.h: Updated
* mailbox/asnprintf.c: Updated
* mailbox/fnmatch.c: Updated
* mailbox/fnmatch_.h: Updated
* mailbox/fnmatch_loop.c: Updated
* mailbox/getdelim.c: Updated
* mailbox/getdelim.h: Updated
* mailbox/getline.c: Updated
* mailbox/getline.h: Updated
* mailbox/getlogin_r.c: Updated
* mailbox/getlogin_r.h: Updated
* mailbox/getopt.c: Updated
* mailbox/getopt1.c: Updated
* mailbox/getopt_.h: Updated
* mailbox/getopt_int.h: Updated
* mailbox/gettext.h: Updated
* mailbox/glob-libc.h: Updated
* mailbox/glob.c: Updated
* mailbox/glob_.h: Updated
* mailbox/imaxtostr.c: Updated
* mailbox/intprops.h: Updated
* mailbox/inttostr.c: Updated
* mailbox/inttostr.h: Updated
* mailbox/malloc.c: Updated
* mailbox/mbchar.c: Updated
* mailbox/mbchar.h: Updated
* mailbox/mbuiter.h: Updated
* mailbox/md5.c: Updated
* mailbox/md5.h: Updated
* mailbox/memchr.c: Updated
* mailbox/mempcpy.c: Updated
* mailbox/mempcpy.h: Updated
* mailbox/minmax.h: Updated
* mailbox/offtostr.c: Updated
* mailbox/printf-args.c: Updated
* mailbox/printf-args.h: Updated
* mailbox/printf-parse.c: Updated
* mailbox/printf-parse.h: Updated
* mailbox/regcomp.c: Updated
* mailbox/regex.c: Updated
* mailbox/regex.h: Updated
* mailbox/regex_internal.c: Updated
* mailbox/regex_internal.h: Updated
* mailbox/regexec.c: Updated
* mailbox/sha1.c: Updated
* mailbox/sha1.h: Updated
* mailbox/size_max.h: Updated
* mailbox/stat-macros.h: Updated
* mailbox/stdbool_.h: Updated
* mailbox/stdint_.h: Updated
* mailbox/strcase.h: Updated
* mailbox/strcasecmp.c: Updated
* mailbox/strchrnul.c: Updated
* mailbox/strchrnul.h: Updated
* mailbox/strdup.c: Updated
* mailbox/strdup.h: Updated
* mailbox/strncasecmp.c: Updated
* mailbox/strndup.c: Updated
* mailbox/strndup.h: Updated
* mailbox/strnlen.c: Updated
* mailbox/strnlen.h: Updated
* mailbox/strnlen1.c: Updated
* mailbox/strnlen1.h: Updated
* mailbox/strtok_r.c: Updated
* mailbox/strtok_r.h: Updated
* mailbox/sysexit_.h: Updated
* mailbox/umaxtostr.c: Updated
* mailbox/vasnprintf.c: Updated
* mailbox/vasnprintf.h: Updated
* mailbox/vsnprintf.c: Updated
* mailbox/vsnprintf.h: Updated
* mailbox/wcwidth.h: Added to the repository
* mailbox/xsize.h: Updated
2006-08-29 Sergey Poznyakoff <gray@gnu.org.ua>
* THANKS: Add Damon Harper
Implement changes proposed by Damon Harper:
* comsat/action.c (act_getline): Change return type to
unsigned. Return actual number of input lines processed or 0 on
failure (either I/O, or memory allocation or EOF).
(action_echo): Rewritten to use shell-like syntax
(run_user_action): Rewritten main loop to make it cleaner. In
particular, expand arguments after word splitting. Use new echo
semantics.
* mail/table.c (mail_escape_table): Add ~x
2006-08-23 Sergey Poznyakoff <gray@gnu.org.ua>
* mailbox/mailbox.c: Include alloca.h
2006-07-27 Sergey Poznyakoff <gray@gnu.org.ua>
* mail/page.c (top_of_page,cursor,page_map,page_size)
(page_avail,page_map): Hide as static
(fill_page_map): Reset cursor if it points past the last
message.
* mail/testsuite/mail/write.exp: Add new testcase
2006-07-22 Sergey Poznyakoff <gray@gnu.org.ua>
* configure.ac: Raise version number to 1.0.1
* NEWS: Version 1.0.1
* lib/mailcap.c (expand_string, run_test, run_mailcap): Fix memory
allocation bugs. Place all temporary strings in the obstack.
Fix coredump on `cd x<TAB>' in mail. Bug reported by
Daniel Kahn Gillmor.
* include/mailutils/folder.h (mu_folder_create_from_record): New
function.
* mailbox/folder.c (mu_folder_create_from_record): New
function.
(mu_folder_create): Interface to mu_folder_create_from_record
* mailbox/mutil.c (mu_scheme_autodetect_p): Return true if scheme
is the name of an existing file or directory.
* mail/mailline.c (file_generator): Remove leading pathlen
characters from the returned names.
* libproto/mbox/folder.c: Minor formatting changes
* mail/mail.c: Likewise
* THANKS: Add Daniel Kahn Gillmor
2006-07-07 Sergey Poznyakoff <gray@gnu.org.ua>
* configure.ac (AC_CHECK_FUNCS): Add setlocale
2006-07-06 Sergey Poznyakoff <gray@gnu.org.ua>
* doc/rfc/rfc2231.txt: New file
* doc/rfc/Makefile.am (EXTRA_DIST): Add rfc2231.txt
* mh/TODO: Update
Sources at this point are tagged rel-1_0
* NEWS: Update
* configure.ac: Raise version number to 1.0
* direntry: Update for 1.0
* doc/texinfo/Makefile.am: Removed hack introduced on
2006-06-15. It triggered unnecessary doc updates.
* scripts/guile-1.6/guile-doc-snarf (snarf_doc): Do not use \n in
the replacement part of a sed expression for the sake of older
seds. Use a more sophisticated approach with changing hold/pattern
spaces instead.
* scripts/guile-1.6/guile-doc-snarf.awk: Adopt for the new output
format of snarf_doc
2006-06-27 Sergey Poznyakoff <gray@gnu.org.ua>
* gnulib.modules (mailutils): Add sha1
* lib/Makefile.am: Update
* mailbox/Makefile.am: Update
* m4/gnulib.m4: Update
* sql/mysql.c: Implement verification against mysql v4 passwords.
Update by gnulib-sync.
* lib/allocsa.c: Updated
* lib/allocsa.h: Updated
* lib/allocsa.valgrind: Updated
* lib/asprintf.c: Updated
* lib/error.c: Updated
* lib/error.h: Updated
* lib/exit.h: Updated
* lib/exitfail.c: Updated
* lib/exitfail.h: Updated
* lib/getpass.c: Updated
* lib/getpass.h: Updated
* lib/mbswidth.c: Updated
* lib/mbswidth.h: Updated
* lib/obstack.c: Updated
* lib/obstack.h: Updated
* lib/realloc.c: Updated
* lib/setenv.c: Updated
* lib/setenv.h: Updated
* lib/snprintf.c: Updated
* lib/snprintf.h: Updated
* lib/unsetenv.c: Updated
* lib/vasprintf.c: Updated
* lib/vasprintf.h: Updated
* lib/xalloc-die.c: Updated
* lib/xalloc.h: Updated
* lib/xmalloc.c: Updated
* lib/xsize.h: Updated
* m4/alloca.m4: Updated
* m4/allocsa.m4: Updated
* m4/argp.m4: Updated
* m4/d-type.m4: Updated
* m4/eealloc.m4: Updated
* m4/eoverflow.m4: Updated
* m4/error.m4: Updated
* m4/exitfail.m4: Updated
* m4/extensions.m4: Updated
* m4/fnmatch.m4: Updated
* m4/full-header-path.m4: Added to the repository
* m4/getdelim.m4: Updated
* m4/getline.m4: Updated
* m4/getlogin_r.m4: Updated
* m4/getopt.m4: Updated
* m4/getpass.m4: Updated
* m4/glob.m4: Updated
* m4/intmax_t.m4: Updated
* m4/inttostr.m4: Updated
* m4/inttypes_h_gl.m4: Updated
* m4/inttypes_h_gl.m4: Updated
* m4/longdouble.m4: Updated
* m4/longdouble.m4: Updated
* m4/longlong_gl.m4: Updated
* m4/longlong_gl.m4: Updated
* m4/mbchar.m4: Updated
* m4/mbiter.m4: Updated
* m4/mbrtowc.m4: Updated
* m4/mbrtowc.m4: Updated
* m4/mbstate_t.m4: Updated
* m4/mbstate_t.m4: Updated
* m4/mbswidth.m4: Updated
* m4/md5.m4: Updated
* m4/memchr.m4: Updated
* m4/mempcpy.m4: Updated
* m4/minmax.m4: Updated
* m4/obstack.m4: Updated
* m4/onceonly.m4: Updated
* m4/onceonly.m4: Updated
* m4/regex.m4: Updated
* m4/restrict.m4: Updated
* m4/setenv.m4: Updated
* m4/sha1.m4: Added to the repository
* m4/signed.m4: Updated
* m4/size_max.m4: Updated
* m4/snprintf.m4: Updated
* m4/ssize_t.m4: Updated
* m4/stat-macros.m4: Updated
* m4/stdbool.m4: Updated
* m4/stdint.m4: Updated
* m4/stdint_h_gl.m4: Updated
* m4/stdint_h_gl.m4: Updated
* m4/strcase.m4: Updated
* m4/strchrnul.m4: Updated
* m4/strdup.m4: Updated
* m4/strerror_r.m4: Updated
* m4/strndup.m4: Updated
* m4/strnlen.m4: Updated
* m4/strtok_r.m4: Updated
* m4/sysexits.m4: Updated
* m4/uintmax_t_gl.m4: Updated
* m4/uintmax_t_gl.m4: Updated
* m4/ulonglong_gl.m4: Updated
* m4/ulonglong_gl.m4: Updated
* m4/unistd_h.m4: Added to the repository
* m4/vasnprintf.m4: Updated
* m4/vasprintf.m4: Updated
* m4/vsnprintf.m4: Updated
* m4/wchar_t.m4: Updated
* m4/wint_t.m4: Updated
* m4/xalloc.m4: Updated
* m4/xsize.m4: Updated
* m4/xsize.m4: Updated
* mailbox/alloca.c: Updated
* mailbox/alloca_.h: Updated
* mailbox/argp-ba.c: Updated
* mailbox/argp-eexst.c: Updated
* mailbox/argp-fmtstream.c: Updated
* mailbox/argp-fmtstream.h: Updated
* mailbox/argp-fs-xinl.c: Updated
* mailbox/argp-help.c: Updated
* mailbox/argp-namefrob.h: Updated
* mailbox/argp-parse.c: Updated
* mailbox/argp-pin.c: Updated
* mailbox/argp-pv.c: Updated
* mailbox/argp-pvh.c: Updated
* mailbox/argp-xinl.c: Updated
* mailbox/argp.h: Updated
* mailbox/asnprintf.c: Updated
* mailbox/fnmatch.c: Updated
* mailbox/fnmatch_.h: Updated
* mailbox/fnmatch_loop.c: Updated
* mailbox/getdelim.c: Updated
* mailbox/getdelim.h: Updated
* mailbox/getline.c: Updated
* mailbox/getline.h: Updated
* mailbox/getlogin_r.c: Updated
* mailbox/getlogin_r.h: Updated
* mailbox/getopt.c: Updated
* mailbox/getopt1.c: Updated
* mailbox/getopt_.h: Updated
* mailbox/getopt_int.h: Updated
* mailbox/gettext.h: Updated
* mailbox/glob-libc.h: Updated
* mailbox/glob.c: Updated
* mailbox/glob_.h: Updated
* mailbox/imaxtostr.c: Updated
* mailbox/intprops.h: Updated
* mailbox/inttostr.c: Updated
* mailbox/inttostr.h: Updated
* mailbox/malloc.c: Updated
* mailbox/mbchar.c: Updated
* mailbox/mbchar.h: Updated
* mailbox/mbuiter.h: Updated
* mailbox/md5.c: Updated
* mailbox/md5.h: Updated
* mailbox/memchr.c: Updated
* mailbox/mempcpy.c: Updated
* mailbox/mempcpy.h: Updated
* mailbox/minmax.h: Updated
* mailbox/offtostr.c: Updated
* mailbox/printf-args.c: Updated
* mailbox/printf-args.h: Updated
* mailbox/printf-parse.c: Updated
* mailbox/printf-parse.h: Updated
* mailbox/regcomp.c: Updated
* mailbox/regex.c: Updated
* mailbox/regex.h: Updated
* mailbox/regex_internal.c: Updated
* mailbox/regex_internal.h: Updated
* mailbox/regexec.c: Updated
* mailbox/sha1.c: Added to the repository
* mailbox/sha1.h: Added to the repository
* mailbox/size_max.h: Updated
* mailbox/stat-macros.h: Updated
* mailbox/stdbool_.h: Updated
* mailbox/stdint_.h: Updated
* mailbox/strcase.h: Updated
* mailbox/strcasecmp.c: Updated
* mailbox/strchrnul.c: Updated
* mailbox/strchrnul.h: Updated
* mailbox/strdup.c: Updated
* mailbox/strdup.h: Updated
* mailbox/strncasecmp.c: Updated
* mailbox/strndup.c: Updated
* mailbox/strndup.h: Updated
* mailbox/strnlen.c: Updated
* mailbox/strnlen.h: Updated
* mailbox/strnlen1.c: Updated
* mailbox/strnlen1.h: Updated
* mailbox/strtok_r.c: Updated
* mailbox/strtok_r.h: Updated
* mailbox/sysexit_.h: Updated
* mailbox/umaxtostr.c: Updated
* mailbox/vasnprintf.c: Updated
* mailbox/vasnprintf.h: Updated
* mailbox/vsnprintf.c: Updated
* mailbox/vsnprintf.h: Updated
* mailbox/xsize.h: Updated
End of update
* auth/sql.c: Minor fixes to get rid of the spurious gcc warnings.
* libsieve/actions.c: Likewise
* libsieve/prog.c: Likewise
* libsieve/sieve.h: Likewise
* libsieve/sieve.l: Likewise
* libsieve/extensions/vacation.c: Likewise
* mail/escape.c: Likewise
* mailbox/argcv.c: Likewise
* mailbox/file_stream.c: Likewise
* mailbox/munre.c: Likewise
* mailbox/mutil.c: Likewise
* mh/mh_alias.l: Likewise
* mh/mh_alias.y: Likewise
* mh/mh_init.c: Likewise
* mh/mh_whatnow.c: Likewise
* mh/mh_whom.c: Likewise
* mh/mhn.c: Likewise
* sql/sql.c: Likewise
* include/mailutils/header.h (MU_HEADER_DCC): New macro. Dcc is a
header traditionally used by MH
* include/mailutils/mutil.h (mu_unre_set_regex): First argument is
const.
* lib/daemon.c: Include stdlib.h
* lib/mailcap.c: All functions, except display_stream_mailcap, are
static.
* libmu_scm/mu_message.c (struct mu_message.needs_destroy): New
member
(mu_scm_message_mark): Raise needs_destroy if the message has null
owner.
(mu_scm_message_free): Do not attempt to reference msg, unless its
needs_destroy is set.
(mu_scm_message_create): Initialize needs_destroy to 0.
* libsieve/extensions/moderator.c (moderator_action): set deleted
flag manually, do not use undeclared sieve_mark_deleted.
* mailbox/amd.c (amd_close): Unlock the monitor before returning
* mh/send.c (fix_fcc): Minor fix
(fix_dcc): New function. Rewrites MH Dcc as standard Bcc header.
(_action_send): Call fix_dcc
* sql/mysql.c (mu_check_mysql_scrambled_password): Use
get_salt_from_scrambled.
2006-06-16 Sergey Poznyakoff <gray@gnu.org.ua>
* mailbox/filter_trans.c (trans_read): Break the loop if both
transcoder and read return 0 bytes. This is necessary to correctly
handle unfinished input strings
* mailbox/testsuite/Decode2047: New testcase: an example of
unfinished input.
* configure.ac: Raise version number to 0.6.95
* NEWS: Update
2006-06-15 Sergey Poznyakoff <gray@gnu.org.ua>
Fix generation of libmu_scm documentation.
* doc/texinfo/Makefile.am (INCFILES): Add mu_*.texi files
* doc/texinfo/libmu_scm.texi: Include snarfed files.
* libmu_scm/Makefile.am (GUILE_BUILT_SOURCES_X)
(DISTCLEANFILES): Add guile-procedures.texi
(guile-procedures.texi): New rule
* libmu_scm/mailutils.scm.in: Use documentation module. Update
documentation-files to make sure MU docs are found.
* libmu_scm/mu_address.c, libmu_scm/mu_logger.c,
libmu_scm/mu_mailbox.c, libmu_scm/mu_message.c,
libmu_scm/mu_mime.c, libmu_scm/mu_scm.c,
libmu_scm/mu_util.c: Update docstrings
* scripts/guile-1.6/guile-doc-snarf: Fix docfile generation
* scripts/guile-1.6/guile-doc-snarf.awk: Likewise
* libmu_scm/.cvsignore, doc/texinfo/.cvsignore,
include/mailutils/.cvsignore: Update
* libproto/.cvsignore: New file
2006-06-14 Sergey Poznyakoff <gray@gnu.org.ua>
* mailbox/tcp.c (mu_tcp_stream_create_with_source_ip):
(mu_tcp_stream_create_with_source_host): New functions
* include/mailutils/stream.h: Likewise
* mailbox/mailbox.c (mailbox_folder_create): Bugfix,
strncmp(fname...
* mailbox/registrar.c: Stop iterating when the matching record was
found.
2006-06-10 Thomas Seeling <thomas.seeling@gmx.net> (trivial changes)
* mailbox/registrar.c (mu_registrar_record): Tolerate NULL
argument.
2006-05-26 Sergey Poznyakoff <gray@gnu.org.ua>
* guimb/main.c: Remove leftover optind usage. Thanks Jay
Sulzberger <jays@panix.com> for reporting.
2006-05-23 Sergey Poznyakoff <gray@gnu.org.ua>
* m4/mu_libobj.m4 (MU_REPLACE_FUNCS): Remove erroneous AC_DEFINE
* examples/encode2047.c: Allow to change encoding and charset
at runtime.
* mailbox/filter_trans.c (trans_read): Bugfix. Do not break the
loop if there are characters left in the buffer.
* mailbox/testsuite/Makefile.am (EXTRA_DIST): Add Encode2047
* mailbox/testsuite/RFC2047: Rename to ...
* mailbox/testsuite/Decode2047: ... this
* mailbox/testsuite/Encode2047: New file
* mailbox/testsuite/mailbox/DISTFILES: Update
* mailbox/testsuite/mailbox/rfc2047.exp: Rename to ...
* mailbox/testsuite/mailbox/decode2047.exp: ... this
* mailbox/testsuite/mailbox/encode2047.exp: New test
2006-05-22 Sergey Poznyakoff <gray@gnu.org.ua>
* libproto/mbox/mbox.c (mbox_is_updated): Return 1 (not updated)
if unable to measure stream size.
* mail/quit.c (mail_mbox_close): Initialize held_count to 0
* mailbox/header.c (mu_header_set_value): Fix length calculation.
2006-05-21 Sergey Poznyakoff <gray@gnu.org.ua>
* mh/folder.c (main): Minor fix
* mailbox/smtp.c (smtp_send_message): Avoid generating spurious
newline when skipping an Fcc header.
2006-05-20 Sergey Poznyakoff <gray@gnu.org.ua>
* mailbox/mailer.c (save_fcc): Handle comma-delimited folder lists
in Fcc lines.
* mh/Makefile.am: Add mh_format.h
* mh/mh_format.h: New file
* mh/TODO: Update
* mh/mh_format.c: Move declarations of strobj functions to
mh_format.h
* mh/mh_init.c (mh_file_to_message): Fix a memory leak
* mh/mh_whatnow.c (mh_whatnow): consult VISUAL and EDITOR
environment variables for the default editor
* mh/repl.c (opt_handler, make_draft): Handle --fcc
* mh/rmf.c (main): Fix coredump if invoked with no options.
* mh/send.c (check_file): Change format of the mesg_list entries.
(fix_fcc): Correctly handle comma-delimited lists of folders.
(backup_file): New function.
(_action_send): Rename draft file after sending it.
* NEWS: Update.
2006-05-17 Sergey Poznyakoff <gray@gnu.org.ua>
* mh/send.c (_action_send): Use %z instead of %Z to form Date
header.
* NEWS: Update
* doc/texinfo/mu-mh.texi: Minor fix
* mh/ali.c, mh/burst.c, mh/comp.c, mh/compcommon.c, mh/fmtcheck.c,
mh/folder.c, mh/forw.c, mh/inc.c, mh/mark.c, mh/mh_alias.l,
mh/mh_alias.y, mh/mh_argp.c, mh/mh_ctx.c, mh/mh_fmtgram.y,
mh/mh_format.c, mh/mh_init.c, mh/mh_list.c, mh/mh_msgset.c,
mh/mh_stream.c, mh/mh_whatnow.c, mh/mh_whom.c, mh/mhl.c, mh/mhn.c,
mh/pick.c, mh/pick.y, mh/refile.c, mh/repl.c, mh/rmf.c, mh/scan.c,
mh/send.c, mh/sortm.c: Remove mh_error function, use mu_error
instead.
* mh/folder.c: Improve compatibility with nmh: if a folder is
specified along with -all, set the recursion depth to 2 (unless
-recurse has also been given).
(print_header,print_total): Default to -1
(recurse): Removed in favor of max_depth.
(has_folder,max_depth): New variable.
(OPTION_IS_SET): New macro.
(opt_handler): Updated for new variable usage.
(_scan): Depth argument is now size_t
Take into account max_depth.
(action_print): Use OPTION_IS_SET with the three-state variables
(main): Properly set/clear show_all and max_depth.
2006-05-16 Sergey Poznyakoff <gray@gnu.org.ua>
* mh/folder.c (opt_handler): Allow -noheader and -nototal to be
used with -all.
* mh/mh_init.c (mh_error): Moved from mh_error.c
* mh/Makefile.am (libmh_a_SOURCES): Remove mh_error.c
* mh/mh_error.c: Removed
2006-05-15 Sergey Poznyakoff <gray@gnu.org.ua>
* mh/folder.c (_scan): Bugfix
* mh/mh.h (mh_makedir): New function
* mh/mh_init.c (mh_makedir): New function
(mh_check_folder): Use mh_makedir to create directories (or
directory hierarchies).
* NEWS: Update
2006-05-12 Sergey Poznyakoff <gray@gnu.org.ua>
* mh/folder.c (_scan): Test for existence of the folder even if
--fast was given. Exit with code 1 if the folder does not exist.
2006-04-26 Sergey Poznyakoff <gray@gnu.org.ua>
* doc/texinfo/mu-mh.texi: New file
* doc/texinfo/programs.texi: Update
* doc/texinfo/Makefile.am (mailutils_TEXINFOS): Add mu-mh.texi
(info_TEXINFOS): Remove muint.texi
* mh/README: Removed. Documentation moved to its proper place in
mailutils.info.
* Makefile.am (SUBDIRS): Remove intl
* configure.ac: Require external gettext
Always define GNULIB_ARGP_EXTERN_BASENAME
* config/Makefile.am (AM_CPPFLAGS): Removed
* mailbox/Makefile.am: Likewise
* movemail/Makefile.am: Likewise
* include/mailutils/address.h (mu_address_set_personal)
(mu_address_set_comments): New functions
* mailbox/address.c: Likewise
* mailbox/sendmail.c: Add extra debug info
* mh/mh.h: Include <argp-namefrob.h>
* mh/mh_getopt.c: Likewise
* mh/mh_alias.y (mh_alias_get_internal): Set `inclusive'
only if the alias matches
(mh_alias_get_address): Initialize incl
Use mu_address_set_personal to handle alias inclusion
* mh/mh_whom.c (mh_alias_expand): Initialize incl
2006-04-22 Sergey Poznyakoff <gray@gnu.org.ua>
* NEWS, README: Updated
* configure.ac: Minor change
* guimb/scm/Makefile.am (sieve.scm): Use auxiliary sed script to
create.
(pkgdata_DATA): Rename to sievemod_DATA
* guimb/scm/redirect.scm: Use handle-exception where necessary
* guimb/scm/reject.scm: Likewise.
* guimb/scm/vacation.scm: Likewise.
* guimb/scm/sieve-core.scm: Rewrite as module. Change
initialization of the syntax tables.
(handle-exception,sieve-verbose-print): New macro
(action-fileinto,action-keep,action-stop,action-discard): Produce
verbose diagnostics if required.
(sieve-run): Take thunk as an argument. Report implicit keep if it
returns #t and the verbose mode is on.
(sieve-main): Take thunk as an argument.
* guimb/scm/sieve.scm.in: Load sieve-core as a module.
Do not use make-shared-substring. Change
initialization of the syntax tables. Construct the code so, that
it returns #t if implicit keep is performed, pass the code as an
argument to sieve-main.
Fix handling of command line arguments when executing the compiled
code (call without -o option).
(lex-error,syntax-error): Rewritten
(sieve-preprocess-arguments): Correctly handle #:comparator
tags
(sieve-parse-arguments): Fix handling of keywords (did not work with
Guile 1.6.x)
(sieve-parse-test): Bugfix 1: Some tests are not procedures.
Bugfix 2: Do not ignore last test in allof, anyof constructs
(sieve-save-program): Rewrite using with-output-to-file
(grammar): New option --verbose.
* include/mailutils/guile.h: Update
* libmu_scm/Makefile.am (pkgdata_DATA): Rename to site_DATA
* libmu_scm/mailutils.scm.in: Change module definition
* libmu_scm/mu_message.c: Throw exceptions on errors.
* libmu_scm/mu_scm.c (mu-strerror): New function
* libmu_scm/mu_scm.h: Include mailutils/errno.h
* m4/guile.m4: New option --with-guiledir. AC_SUBST all GUILE_.*
variables. Use $GUILE_CONFIG instead of guile-config.
2006-04-20 Sergey Poznyakoff <gray@gnu.org.ua>
* guimb/scm/sieve-core.scm: Always load mailutils module
(sieve-main): Use (mu-mail-directory) instead of mu-path-maildir.
* include/mailutils/guile.h: Add support for Guile 1.8
(mu_scm_error): New function
* include/mailutils/mutil.h (mu_spawnvp): Change type of the 2nd
argument.
* libmu_scm/mailutils.scm.in (mu-libs): Use "libmailutils" instead
of "libmailbox"
* libmu_scm/mu_address.c: Rewritten using Guile 1.8 API.
Throw 'mailutils-error instead of returning #f on error.
* libmu_scm/mu_body.c: Likewise
* libmu_scm/mu_logger.c: Likewise
* libmu_scm/mu_mailbox.c: Likewise
* libmu_scm/mu_message.c: Likewise
* libmu_scm/mu_mime.c: Likewise
* libmu_scm/mu_port.c: Likewise
* libmu_scm/mu_scm.c: Likewise
* libmu_scm/mu_util.c: Likewise
* libproto/imap/mbox.c (imap_envelope_date): bugfix
* mailbox/amd.c [WITH_PTHREAD][HAVE_PTHREAD_H]: Fix typo
* mailbox/locker.c (lock_external): Minor fix
* mailbox/mutil.c (mu_spawnvp): Change type of the 2nd argument.
2006-04-19 Sergey Poznyakoff <gray@gnu.org.ua>
* NEWS: Update
* gnulib.modules (muaux): Remove xstrtol
* libproto/pop/mbox.c (parse_answer0,parse_answer1): Use strtoul
instead of strtoumax. This is a temporary change.
* m4/gnulib.m4: Remove gl_XSTRTOL.
* m4/xstrtol.m4: Removed
* lib/xstrtol.h: Removed
* lib/xstrtol.c: Removed
* lib/xstrtoul.c: Removed
* NEWS: Update
* README: Document --with-berkeley-db option
* configure.ac (--with-berkeley-db): New option
(--with-db2): Deprecated. Remove from the help list.
Raise version number to 0.6.94
* lib/mu_dbm.c: Add support for Berkeley DB >= 3
* lib/mu_dbm.h: Likewise
* pop3d/popauth.c: Likewise
* mailbox/nls.c: Include stdlib.h
* doc/texinfo/address.texi, doc/texinfo/attribute.texi,
doc/texinfo/auth.texi, doc/texinfo/body.texi,
doc/texinfo/envelope.texi, doc/texinfo/folder.texi,
doc/texinfo/framework.texi, doc/texinfo/headers.texi,
doc/texinfo/imap4.texi, doc/texinfo/iterator.texi,
doc/texinfo/libsieve.texi, doc/texinfo/locker.texi,
doc/texinfo/mailbox.texi, doc/texinfo/mailcap.texi,
doc/texinfo/mailer.texi, doc/texinfo/mbox.texi,
doc/texinfo/message.texi, doc/texinfo/mime.texi,
doc/texinfo/nntp.texi, doc/texinfo/parse822.texi,
doc/texinfo/pop3.texi, doc/texinfo/smtp.texi,
doc/texinfo/stream.texi, doc/texinfo/url.texi: Reflect namespace
changes.
2006-04-05 Sergey Poznyakoff <gray@gnu.org.ua>
* THANKS: Add Willem Jaap Zwart
* NEWS: Update
* imap4d/imap4d.h (is_atom): New function
* imap4d/list.c (print_file,print_dir): Rewrite using an
auxiliary function. Make sure the string is properly quoted if it
is not a valid atom.
* imap4d/util.c (is_atom): New function.
* libproto/imap/folder.c (list_copy): Do nothing if src is NULL.
(imap_list): Use mu_argcv_get instead of strtok_r to parse last
two tokens of the reply, so that file names containing white space
are processed.
* mailbox/argcv.c: Fix indentation.
2006-03-12 Sergey Poznyakoff <gray@gnu.org.ua>
* imap4d/append.c, imap4d/fetch.c, libproto/imap/mbox.c,
libproto/mbox/mbox.c, libsieve/actions.c, mailbox/message.c,
mailbox/message_stream.c, mh/mh_init.c, mh/send.c: Use mu_strftime
* include/mailutils/envelope.h (MU_ENVELOPE_DATE_FORMAT)
(MU_ENVELOPE_DATE_LENGTH): New defines
* include/mailutils/mutil.h (mu_strftime): New function
* include/mailutils/nls.h (mu_set_locale,mu_restore_locale): New
functions
* mailbox/mutil.c (mu_strftime): New function
* mailbox/nls.c (mu_locale_set): New variable
(mu_set_locale,mu_restore_locale): New functions
(mu_init_nls): Use mu_set_locale. Store its return in mu_locale_set.
* scripts/generr.awk: Report error if no output lines were
produced.
2006-03-03 Sergey Poznyakoff <gray@gnu.org.ua>
* Makefile.am (SUBDIRS): Add libproto
* configure.ac: Define MU_LIB_.* variables
(MU_AUTHLIBS): Initialize to empty value.
(AC_CONFIG_FILES): Add libproto Makefiles
* libproto: New directory
* libproto/Makefile.am: New file
* libproto/imap: New directory
* libproto/include: New directory
* libproto/maildir: New directory
* libproto/mbox: New directory
* libproto/mh: New directory
* libproto/nntp: New directory
* libproto/pop: New directory
* mailbox/imap/folder.c, mailbox/imap/mbox.c, mailbox/imap/url.c,
mailbox/imap/Makefile.am, mailbox/imap/.cvsignore: Move to
libproto/imap
* mailbox/include/address0.h, mailbox/include/amd.h,
mailbox/include/attribute0.h, mailbox/include/auth0.h,
mailbox/include/body0.h, mailbox/include/debug0.h,
mailbox/include/envelope0.h, mailbox/include/filter0.h,
mailbox/include/folder0.h, mailbox/include/header0.h,
mailbox/include/imap0.h, mailbox/include/iterator0.h,
mailbox/include/list0.h, mailbox/include/mailbox0.h,
mailbox/include/mailer0.h, mailbox/include/message0.h,
mailbox/include/mime0.h, mailbox/include/monitor0.h,
mailbox/include/observer0.h, mailbox/include/property0.h,
mailbox/include/registrar0.h, mailbox/include/stream0.h,
mailbox/include/url0.h, mailbox/include/Makefile.am,
mailbox/include/.cvsignore: Move to libproto/include
* mailbox/maildir/folder.c, mailbox/maildir/maildir.h,
mailbox/maildir/mbox.c, mailbox/maildir/Makefile.am,
mailbox/maildir/.cvsignore: Move to libproto/maildir
* mailbox/mbox/folder.c, mailbox/mbox/mbox.c,
mailbox/mbox/mbox0.h, mailbox/mbox/mboxscan.c, mailbox/mbox/url.c,
mailbox/mbox/Makefile.am, mailbox/mbox/.cvsignore: Move to
libproto/mbox.
* mailbox/mh/folder.c, mailbox/mh/mbox.c, mailbox/mh/Makefile.am,
mailbox/mh/.cvsignore: Move to libproto/mh
* mailbox/nntp/folder.c, mailbox/nntp/mbox.c,
mailbox/nntp/nntp0.h, mailbox/nntp/nntp_article.c,
mailbox/nntp/nntp_body.c, mailbox/nntp/nntp_carrier.c,
mailbox/nntp/nntp_connect.c, mailbox/nntp/nntp_create.c,
mailbox/nntp/nntp_date.c, mailbox/nntp/nntp_debug.c,
mailbox/nntp/nntp_destroy.c, mailbox/nntp/nntp_disconnect.c,
mailbox/nntp/nntp_group.c, mailbox/nntp/nntp_head.c,
mailbox/nntp/nntp_help.c, mailbox/nntp/nntp_ihave.c,
mailbox/nntp/nntp_iterator.c, mailbox/nntp/nntp_last.c,
mailbox/nntp/nntp_list_active.c,
mailbox/nntp/nntp_list_distribpats.c,
mailbox/nntp/nntp_list_distributions.c,
mailbox/nntp/nntp_list_extensions.c,
mailbox/nntp/nntp_list_newsgroups.c,
mailbox/nntp/nntp_list_times.c, mailbox/nntp/nntp_mode_reader.c,
mailbox/nntp/nntp_newgroups.c, mailbox/nntp/nntp_newnews.c,
mailbox/nntp/nntp_next.c, mailbox/nntp/nntp_post.c,
mailbox/nntp/nntp_quit.c, mailbox/nntp/nntp_readline.c,
mailbox/nntp/nntp_response.c, mailbox/nntp/nntp_sendline.c,
mailbox/nntp/nntp_stat.c, mailbox/nntp/nntp_stream.c,
mailbox/nntp/nntp_timeout.c, mailbox/nntp/url.c,
mailbox/nntp/Makefile.am, mailbox/nntp/.cvsignore: Move to
libproto/nntp
* mailbox/pop/folder.c, mailbox/pop/mbox.c,
mailbox/pop/pop3_apop.c, mailbox/pop/pop3_capa.c,
mailbox/pop/pop3_carrier.c, mailbox/pop/pop3_connect.c,
mailbox/pop/pop3_create.c, mailbox/pop/pop3_debug.c,
mailbox/pop/pop3_dele.c, mailbox/pop/pop3_destroy.c,
mailbox/pop/pop3_disconnect.c, mailbox/pop/pop3_iterator.c,
mailbox/pop/pop3_list.c, mailbox/pop/pop3_lista.c,
mailbox/pop/pop3_noop.c, mailbox/pop/pop3_pass.c,
mailbox/pop/pop3_quit.c, mailbox/pop/pop3_readline.c,
mailbox/pop/pop3_response.c, mailbox/pop/pop3_retr.c,
mailbox/pop/pop3_rset.c, mailbox/pop/pop3_sendline.c,
mailbox/pop/pop3_stat.c, mailbox/pop/pop3_stls.c,
mailbox/pop/pop3_stream.c, mailbox/pop/pop3_timeout.c,
mailbox/pop/pop3_top.c, mailbox/pop/pop3_uidl.c,
mailbox/pop/pop3_uidla.c, mailbox/pop/pop3_user.c,
mailbox/pop/url.c, mailbox/pop/Makefile.am,
mailbox/pop/.cvsignore: Move to libproto/pop.
* auth/Makefile.am, comsat/Makefile.am, config/Makefile.am,
dotlock/Makefile.am, examples/Makefile.am, frm/Makefile.am,
guimb/Makefile.am, imap4d/Makefile.am, libmu_scm/Makefile.am,
libsieve/Makefile.am, libsieve/extensions/Makefile.am,
mail/Makefile.am, mail.local/Makefile.am, mail.remote/Makefile.am,
mailbox/Makefile.am, mapi/Makefile.am, messages/Makefile.am,
mh/Makefile.am, mimeview/Makefile.am, movemail/Makefile.am,
pop3d/Makefile.am, readmsg/Makefile.am, sieve/Makefile.am: Use
MU_LIB_.* variables instead of referring to the libraries by their
relative paths.
* po/POTFILES.in: Update
* mailbox/amd.c: Protect definition of _XOPEN_SOURCE by an extra
ifdef.
* libsieve/extensions/vacation.c (regex_comparator): Fix error
diagnostics
* mail/mail.h (cursor): Fix declaration
* mailbox/Makefile.am: Fix INCLUDES and SUBDIRS
* mailbox/filter_trans.c (base64_encode): Split into two
functions.
(B_encode): New function for RFC 2047 encoding
* mailbox/rfc2047.c: Minor indentation fix
* mh/mhn.c (finish_msg): Make sure part header is preserved.
2006-02-24 Sergey Poznyakoff <gray@gnu.org.ua>
* auth/Makefile.am, libmu_cpp/Makefile.am, libmu_scm/Makefile.am,
mailbox/imap/Makefile.am, mailbox/maildir/Makefile.am,
mailbox/mbox/Makefile.am, mailbox/mh/Makefile.am,
mailbox/nntp/Makefile.am, mailbox/pop/Makefile.am,
mapi/Makefile.am: Set version info
* mailbox/Makefile.am: Compile libmailutils first, then recurse
into the subdirs.
* m4/guile.m4: Use improved sed expression, proposed by Thien-Thi
Nguyen.
2006-02-17 Sergey Poznyakoff <gray@gnu.org.ua>
* NEWS: Update
* mh/mhn.c (split_args): New function
(_message_is_external_body ): Use split_args to parse
additional arguments
(mhn_edit): Fix invocation of edit_modify (was not getting
additional arguments after ';')
(parse_header_directive): New function
(mhn_header): New function
(mhn_compose): Bugfix: initialize env.line
Call mhn_header to optionally encode Subject line
* mailbox/rfc2047.c (mu_rfc2047_encode): Return EINVAL if any of
the arguments is NULL.
* frm/common.c (get_personal): Fix coredump on empty From: headers.
2006-02-09 Sergey Poznyakoff <gray@gnu.org.ua>
* mailbox/message_stream.c (restore_envelope): Restore line
accidentally deleted with the recent changes.
2006-02-08 Sergey Poznyakoff <gray@gnu.org.ua>
Fix displaying source locations in Sieve action logs:
* libsieve/prog.c (sieve_change_source)
(sieve_check_source_changed): New functions
(sieve_code_action,sieve_code_test): Call
sieve_check_source_changed.
* libsieve/sieve.h (sieve_change_source): New function
* libsieve/sieve.l (push_source,pop_source): Do not code
SOURCE instruction directly, use sieve_change_source() to let the
code generator know it should do it.
Fix build on platforms without program_invocation_short_name:
* mailbox/Makefile.am (AM_CFLAGS): Use AM_CPPFLAGS instead.
* config/Makefile.am, movemail/Makefile.am (AM_CPPFLAGS): Add
GNULIB_ARGP_EXTERN_BASENAME=1
* config/mailutils-config.c, movemail/movemail.c: Include
argp-namefrob.h
2006-02-07 Sergey Poznyakoff <gray@gnu.org.ua>
* mailbox/stream.c (mu_stream_getline)
(mu_stream_sequential_getline): New function
* mailbox/message_stream.c (_mu_rfc822_open, restore_envelope): Use
mu_stream_getline
* include/mailutils/stream.h (mu_stream_getline)
(mu_stream_sequential_getline): New function
* include/mailutils/libsieve.h (mu_sieve_machine_inherit_report):
Replace by mu_sieve_machine_inherit
* libsieve/sieve.y: Likewise
* libsieve/extensions/moderator.c: Likewise.
* libsieve/extensions/vacation.c: Fix the leading comment.
* mailbox/argp-namefrob.h: Restored changes accidentally lost in
gnulib.
2006-02-06 Sergey Poznyakoff <gray@gnu.org.ua>
* NEWS: Raise version number to 0.6.93
* include/mailutils/libsieve.h (mu_sieve_machine_dup)
(mu_sieve_machine_inherit_report): New functions
* include/mailutils/message.h (mu_stream_to_message): New
function.
* include/mailutils/mutil.h (mu_mh_delim): New function
* libsieve/actions.c: Minor stylistic changes
* libsieve/require.c: Likewise
* libsieve/sieve.h: Likewise
* libsieve/sieve.y (mu_sieve_machine_inherit_report)
(mu_sieve_machine_dup): New functions
* libsieve/util.c: Minor stylistic changes
* libsieve/extensions/moderator.c: New file. Automatic moderator
for Mailman-driven mailing lists.
* libsieve/extensions/Makefile.am: Add moderator module
* mailbox/message_stream.c: New file. Derived from mh/mh_stream.c
* mailbox/Makefile.am: Add message_stream.c
* mailbox/mutil.c (mu_mh_delim): New function
* mh/mh_stream.c: Rewritten using mu_stream_to_message. Actually,
the source can be removed now and the function moved elsewhere,
e.g. to mh_init...
* sieve/sieve.c (main): Register all mailbox/mailer formats.
2006-01-27 Sergey Poznyakoff <gray@gnu.org.ua>
* mh/comp.c: Fix semantics of -build/-draftmessage/-[no]draftfolder
options for compatibility with other implementations of MH
* mh/forw.c: Likewise
* mh/whatnow.c: Likewise
* mh/repl.c: Likewise
* mh/compcommon.c: Bugfix.
* mh/mh.h (mh_draft_message): New prototype.
(xmalloc,xrealloc): Remove prototypes
* mh/mh_argp.c (parse_opt): Pass ARGP_KEY_INIT to the application
handler.
* mh/mh_init.c (mh_draft_message): New function
* mh/mh_whatnow.c (quit): Don't call rename if both file and
draftfile are the same.
* imap4d/select.c (imap4d_select0): Fix status display.
2006-01-25 Sergey Poznyakoff <gray@gnu.org.ua>
* imap4d/select.c (imap4d_select0): Create INBOX if it does not
exist.
* mailbox/Makefile.am (AM_CFLAGS): Define
GNULIB_ARGP_EXTERN_BASENAME
* mailbox/argp-namefrob.h: Bugfix (stray #)
* mailbox/mutil.c (__argp_base_name): New function
* THANKS: Add Helmut Leitner.
* mail/mail.c (parse_opt): Try to catch arguments separated from
the option by whitespace. Solution proposed by Helmut Leitner.
Avoid queueing multiple "set mode=send" options.
* sql/mysql.c (connect): Initialize socket_name to NULL
* include/mailutils/compat.h (registrar_lookup): Define to
mu_0_6_registrar_lookup
* include/mailutils/mailbox.h (mu_mailbox_set_default_proto)
(mu_mailbox_get_default_proto): New prototypes.
* include/mailutils/registrar.h (mu_registrar_lookup): Changed
declaration.
(mu_0_6_registrar_lookup): New prototype.
* mailbox/mailbox.c (mu_mailbox_set_default_proto)
(mu_mailbox_get_default_proto): New functions.
(mu_mailbox_create): Append default_proto to the mailbox URL, if
the latter does not already contain one.
Update invocation of mu_registrar_lookup
* mailbox/mbx_default.c (tilde_expand): Remove
(mu_mailbox_create_default): Use mu_tilde_expansion instead of
tilde_expand
* mailbox/mu_argp.c (mu_mailbox_argp_option)
(mu_common_argp_parser): New option --mailbox-type
* mailbox/mutil.c (mu_tilde_expansion): Expand tilde after
the protocol specification.
* mailbox/registrar.c (mu_registrar_lookup): Return error
code. Use an extra argument to return the flags.
(mu_0_6_registrar_lookup): New function for compatibility with
previous versions.
* mailbox/folder.c: Update invocations of mu_registrar_lookup
* mailbox/mailer.c: Likewise
* mailbox/mbox/folder.c: Likewise.
* NEWS: Update
2006-01-24 Sergey Poznyakoff <gray@gnu.org.ua>
* mh/mh_ctx.c (mh_context_read): Allow for empty lines and
conventional comment characters ('#') in the context file.
* mh/mh_init.c (mh_is_my_name): Bugfix: do not use strtok_r, which
modifies its argument.
* include/mailutils/header.h (MU_HEADER_X_MAILER): New define
* mail/send.c (mail_send0): Use MU_HEADER_X_MAILER
* mh/replcomps: Remove X-Mailer. Send will add it if needed.
* mh/replgroupcomps: Likewise
* mh/send.c (read_mts_profile): Support localname and localdomain
variables.
(read_mts_profile): Support x-mailer variable.
* NEWS: Updated
2006-01-23 Sergey Poznyakoff <gray@gnu.org.ua>
* mail/mail.h (exec_compl): New prototype
* mail/mailline.c (ml_command_completion): Fix coredump
(exec_compl,exec_generator): New functions
* mail/table.c: Use exec_compl to complete first argument to !
* mailbox/parse822.c (mu_parse822_time): Assume UTC for invalid or
unknown timezones.
2006-01-20 Sergey Poznyakoff <gray@gnu.org.ua>
Sources before this point are tagged alpha_0_6_92
* mailbox/mu_umaxtostr.c: New file
* mailbox/mu_umaxtostr.h: New file
* configure.ac: Remove HAVE_DECL_PROGRAM_INVOCATION_NAME hack,
newer argp does that itself.
Raise version number to 0.6.93
* gnulib.modules (mailutils): Add inttostr
* examples/Makefile.am, imap4d/Makefile.am,
libsieve/extensions/Makefile.am, pop3d/Makefile.am (AM_LDFLAGS):
Load libmuaux before libmailutils.
* mailbox/imap/Makefile.am (libmu_imap_la_LIBADD): New variable
* mailbox/pop/Makefile.am (libmu_pop_la_LIBADD): New variable
* examples/muemail.c: Include stdlib.h
* imap4d/fetch.c, imap4d/imap4d.c, imap4d/search.c,
mailbox/daemon.c, mailbox/message.c, mailbox/imap/mbox.c,
mh/burst.c, mh/compcommon.c, mh/folder.c, mh/forw.c,
mh/mh_global.c, mh/mh_msgset.c, mh/mh_sequence.c, mh/mhn.c,
mh/mhpath.c, mh/pick.c, mh/repl.c, mh/sortm.c, pop3d/apop.c,
pop3d/capa.c, pop3d/dele.c, pop3d/list.c, pop3d/logindelay.c,
pop3d/pop3d.c, pop3d/stat.c, pop3d/uidl.c, pop3d/user.c: Use
mu_umaxtostr to format size_t and off_t values
* imap4d/imap4d.h, libmu_scm/mu_port.c, mh/mh.h, pop3d/pop3d.h:
Include mu_umaxtostr.h
* mh/mh_format.c: Recognize EET and EEST time zones
* mailbox/pop/mbox.c: Fix parsing of pop3 server replies.
Use mu_umaxtostr to format size_t and off_t values
* mailbox/imap/folder.c: Add gettext markers
* mailbox/mbox/mbox.c: Likewise
* mailbox/mbox/mbox0.h: Include mailutils/nls.h
* mail/set.c, mail/unset.c, mail/mail.h,
mail/util.c (util_printenv): Change return type to void.
All callers updated.
* mail.local/mail.local.h: Define USE_MAILBOX_QUOTAS after
including mu_dbm.h
* mail.local/mailquota.c: Issue error message if unable to open
the database.
* mailbox/Makefile.am (AM_CFLAGS): Define
GNULIB_ARGP_DISABLE_DIRNAME
(EXTRA_DIST): Remove pin.c
* po/POTFILES.in: Updated. Sorted alphabetically
* scripts/gnulib-sync (expand_modules): Implement 'avoid' feature.
Avoid expanding dirname into mailbox/, since it drags xalloc with
it.
Update by gnulib-sync.
* lib/fnmatch.c: Updated
* lib/malloc.c: Updated
* lib/strcasecmp.c: Updated
* lib/strncasecmp.c: Updated
* m4/gnulib.m4: Updated
* m4/xstrtol.m4: Updated
* lib/allocsa.c: Updated
* lib/allocsa.h: Updated
* lib/allocsa.valgrind: Updated
* lib/asprintf.c: Updated
* lib/error.c: Updated
* lib/error.h: Updated
* lib/exit.h: Updated
* lib/exitfail.c: Updated
* lib/exitfail.h: Updated
* lib/getpass.c: Updated
* lib/getpass.h: Updated
* lib/mbswidth.c: Updated
* lib/mbswidth.h: Updated
* lib/obstack.c: Updated
* lib/obstack.h: Updated
* lib/realloc.c: Updated
* lib/setenv.c: Updated
* lib/setenv.h: Updated
* lib/snprintf.c: Updated
* lib/snprintf.h: Updated
* lib/unsetenv.c: Updated
* lib/vasprintf.c: Updated
* lib/vasprintf.h: Updated
* lib/xalloc-die.c: Updated
* lib/xalloc.h: Updated
* lib/xmalloc.c: Updated
* lib/xsize.h: Updated
* m4/alloca.m4: Updated
* m4/allocsa.m4: Updated
* m4/argp.m4: Updated
* m4/d-type.m4: Updated
* m4/eealloc.m4: Updated
* m4/eoverflow.m4: Updated
* m4/error.m4: Updated
* m4/exitfail.m4: Updated
* m4/extensions.m4: Updated
* m4/fnmatch.m4: Updated
* m4/getdelim.m4: Updated
* m4/getline.m4: Updated
* m4/getlogin_r.m4: Updated
* m4/getopt.m4: Updated
* m4/getpass.m4: Updated
* m4/glob.m4: Updated
* m4/intmax_t.m4: Updated
* m4/inttostr.m4: Added to the repository
* m4/inttypes.m4: Updated
* m4/inttypes_h_gl.m4: Updated
* m4/inttypes_h_gl.m4: Updated
* m4/longdouble.m4: Updated
* m4/longdouble.m4: Updated
* m4/longlong_gl.m4: Updated
* m4/longlong_gl.m4: Updated
* m4/mbchar.m4: Updated
* m4/mbiter.m4: Updated
* m4/mbrtowc.m4: Updated
* m4/mbrtowc.m4: Updated
* m4/mbstate_t.m4: Updated
* m4/mbstate_t.m4: Updated
* m4/mbswidth.m4: Updated
* m4/md5.m4: Updated
* m4/memchr.m4: Updated
* m4/mempcpy.m4: Updated
* m4/minmax.m4: Updated
* m4/obstack.m4: Updated
* m4/onceonly.m4: Updated
* m4/onceonly.m4: Updated
* m4/regex.m4: Updated
* m4/restrict.m4: Updated
* m4/setenv.m4: Updated
* m4/signed.m4: Updated
* m4/size_max.m4: Updated
* m4/snprintf.m4: Updated
* m4/stat-macros.m4: Updated
* m4/stdbool.m4: Updated
* m4/stdint.m4: Updated
* m4/stdint_h_gl.m4: Updated
* m4/stdint_h_gl.m4: Updated
* m4/strcase.m4: Updated
* m4/strchrnul.m4: Updated
* m4/strdup.m4: Updated
* m4/strerror_r.m4: Updated
* m4/strndup.m4: Updated
* m4/strnlen.m4: Updated
* m4/strtok_r.m4: Updated
* m4/sysexits.m4: Updated
* m4/uintmax_t_gl.m4: Updated
* m4/uintmax_t_gl.m4: Updated
* m4/ulonglong_gl.m4: Updated
* m4/ulonglong_gl.m4: Updated
* m4/vasnprintf.m4: Updated
* m4/vasprintf.m4: Updated
* m4/vsnprintf.m4: Updated
* m4/wchar_t.m4: Updated
* m4/wint_t.m4: Updated
* m4/xalloc.m4: Updated
* m4/xsize.m4: Updated
* m4/xsize.m4: Updated
* mailbox/alloca.c: Updated
* mailbox/alloca_.h: Updated
* mailbox/argp-ba.c: Updated
* mailbox/argp-eexst.c: Updated
* mailbox/argp-fmtstream.c: Updated
* mailbox/argp-fmtstream.h: Updated
* mailbox/argp-fs-xinl.c: Updated
* mailbox/argp-help.c: Updated
* mailbox/argp-namefrob.h: Updated
* mailbox/argp-parse.c: Updated
* mailbox/argp-pin.c: Added to the repository
* mailbox/argp-pv.c: Updated
* mailbox/argp-pvh.c: Updated
* mailbox/argp-xinl.c: Updated
* mailbox/argp.h: Updated
* mailbox/asnprintf.c: Updated
* mailbox/fnmatch.c: Updated
* mailbox/fnmatch_.h: Updated
* mailbox/fnmatch_loop.c: Updated
* mailbox/getdelim.c: Updated
* mailbox/getdelim.h: Updated
* mailbox/getline.c: Updated
* mailbox/getline.h: Updated
* mailbox/getlogin_r.c: Updated
* mailbox/getlogin_r.h: Updated
* mailbox/getopt.c: Updated
* mailbox/getopt1.c: Updated
* mailbox/getopt_.h: Updated
* mailbox/getopt_int.h: Updated
* mailbox/gettext.h: Updated
* mailbox/glob-libc.h: Updated
* mailbox/glob.c: Updated
* mailbox/glob_.h: Updated
* mailbox/imaxtostr.c: Added to the repository
* mailbox/intprops.h: Added to the repository
* mailbox/inttostr.c: Added to the repository
* mailbox/inttostr.h: Added to the repository
* mailbox/malloc.c: Updated
* mailbox/mbchar.c: Updated
* mailbox/mbchar.h: Updated
* mailbox/mbuiter.h: Updated
* mailbox/md5.c: Updated
* mailbox/md5.h: Updated
* mailbox/memchr.c: Updated
* mailbox/mempcpy.c: Updated
* mailbox/mempcpy.h: Updated
* mailbox/minmax.h: Updated
* mailbox/offtostr.c: Added to the repository
* mailbox/printf-args.c: Updated
* mailbox/printf-args.h: Updated
* mailbox/printf-parse.c: Updated
* mailbox/printf-parse.h: Updated
* mailbox/regcomp.c: Updated
* mailbox/regex.c: Updated
* mailbox/regex.h: Updated
* mailbox/regex_internal.c: Updated
* mailbox/regex_internal.h: Updated
* mailbox/regexec.c: Updated
* mailbox/size_max.h: Updated
* mailbox/stat-macros.h: Updated
* mailbox/stdbool_.h: Updated
* mailbox/stdint_.h: Updated
* mailbox/strcase.h: Updated
* mailbox/strcasecmp.c: Updated
* mailbox/strchrnul.c: Updated
* mailbox/strchrnul.h: Updated
* mailbox/strdup.c: Updated
* mailbox/strdup.h: Updated
* mailbox/strncasecmp.c: Updated
* mailbox/strndup.c: Updated
* mailbox/strndup.h: Updated
* mailbox/strnlen.c: Updated
* mailbox/strnlen.h: Updated
* mailbox/strnlen1.c: Updated
* mailbox/strnlen1.h: Updated
* mailbox/strtok_r.c: Updated
* mailbox/strtok_r.h: Updated
* mailbox/sysexit_.h: Updated
* mailbox/umaxtostr.c: Added to the repository
* mailbox/vasnprintf.c: Updated
* mailbox/vasnprintf.h: Updated
* mailbox/vsnprintf.c: Updated
* mailbox/vsnprintf.h: Updated
* mailbox/xsize.h: Updated
2006-01-20 Sergey Poznyakoff <gray@gnu.org.ua>
Fix bug reported by Ronan KERYELL <Ronan.Keryell@enstb.org>
(Debian Bug#344420):
* mailbox/file_stream.c (_file_write): Return ENOSPC if fwrite
returns 0.
* mailbox/mbox/mbox.c (mbox_append_message0): Preserve return
status from mu_stream_write, if it is not 0.
* movemail/movemail.c (main): Exit on first detected IO
error. Make sure the source mailbox is not modified if not all
messages were moved successfully.
* THANKS: Add Ronan KERYELL
Support automatic home directory creation in imap4d
* imap4d/authenticate.c (imap4d_authenticate): Call
imap4d_check_home_dir before switching to user's privileges. Bail
out if it returns with an error.
Use util_chdir instead of chdir to change to user's home
directory.
* imap4d/login.c (imap4d_login): Likewise
* imap4d/imap4d.c (create_home_dir,home_dir_mode): New variables
(options): New option --create-home-dir
(imap4d_check_home_dir): New function
* imap4d/imap4d.h (imap4d_check_home_dir,util_chdir): New
prototype.
* imap4d/util.c (util_chdir): New function.
* doc/texinfo/programs.texi: Document --create-home-dir option.
* NEWS: Update
2006-01-18 Sergey Poznyakoff <gray@gnu.org.ua>
* README-alpha: Update cvs co information
2006-01-16 Sergey Poznyakoff <gray@gnu.org.ua>
* NEWS: Updated
* THANKS: Add Walter Neumann
* doc/texinfo/programs.texi: Document inplacealiases and
recursealiases.
* mail/alias.c (alias_expand): Recursively expand aliases if
recursealiases is set.
* mail/mail.c (default_setup): Provide defaults for inplacealiases
and recursealiases.
* mail/mail.h (is_address_field): New prototype.
* mail/send.c (compose_header_set): Check for valid arguments at
the beginning of the function (value can be NULL, e.g. if the user hit
C-D at Cc: prompt).
Call util_merge_addresses() only if inplacealiases is set. Expand
aliases before calling it.
* mail/util.c (is_address_field): Remove static qualifier.
(util_header_expand): Expand aliases unless inplacealiases is set.
* mail/testsuite/mail/send.exp: Set inplacealiases.
2005-12-14 Sergey Poznyakoff <gray@gnu.org.ua>
* lib/mu_dbm.c: Allow specifying full file name (including the
suffix).
2005-12-08 Sergey Poznyakoff <gray@gnu.org.ua>
* mh/comp.c, mh/forw.c, mh/repl.c: Make sure -nodraftfolder
cancels Draft-Folder variable, not only -draftfolder option.
2005-12-05 Sergey Poznyakoff <gray@gnu.org.ua>
* mail/util.c (util_do_command): Bugfix
2005-12-04 Sergey Poznyakoff <gray@gnu.org.ua>
* imap4d/list.c (list_file,print_dir,print_file): Use
mkfullname. Fixes [bug #15144].
* imap4d/create.c: Do not create anything and return OK if the
argument is suffixed with a hierarchy separator. Fixes [bug #15142].
* imap4d/status.c (imap4d_status): Flush attributes before opening
the mailbox.
(status_unseen): Remove superfluous condition
Fixes [bug #15143].
2005-12-03 Sergey Poznyakoff <gray@gnu.org.ua>
* mh/burst.c (finish_stream): Set map.first if necessary
(burst_digest): Initialize eb_length
(burst_rename): Skip messages that do not need to be renamed.
(main): Do not process inplace if burst_count is 0
* include/mailutils/stream.h (mu_temp_file_stream_create): New
function.
* mailbox/file_stream.c: Likewise.
* mh/burst.c: New option --length allows to set a minimal
encapsulation boundary length.
(burst_digest): Take into account minimal EB length.
* mh/README: Update
* mh/TODO: Update
* mh/burst.c (burst): Keep message sequence number in msgno.
(burst_rename): Fix loop limits
(main): Fix calculation of last_uid.
Keep message sequence numbers in ms.
(burst_digest): Initial implementation of RFC 934
2005-11-29 Sergey Poznyakoff <gray@gnu.org.ua>
* doc/rfc/rfc934.txt: New file.
* doc/rfc/Makefile.am (EXTRA_DIST): Add rfc934.txt
* mailbox/amd.c (amd_msg_lookup): Bugfix. Use msg_count == 0
to determine if the msg_array is empty.
* mailbox/mime.c (mu_mime_get_part): Set stream_size function.
* mh/burst.c: New file. Initial implementation of burst command.
* mh/Makefile.am (PROGRAMS_MH,EXTRA_PROGRAMS): Add burst
* mh/TODO: Update
* mh/forw.c (msg_copy): Implement FSA described in RFC 934
* mh/mh_getopt.h (enum mh_arg): New declaration, instead of
multiple defines.
* mh/mh_init.c (mh_expand_name): Accept names starting with mh:/
protocol indicator.
* mh/.cvsignore: Add burst, sort entries.
2005-11-28 Sergey Poznyakoff <gray@gnu.org.ua>
* mailbox/header.c: Fix indentation
* mh/mh.h (mh_context_destroy,mh_context_merge): New proto
* mh/mh_ctx.c (mh_context_destroy,mh_context_merge): New
functions.
* mh/mh_init.c (mh_expand_name): Make sure the returned value can
safely be freed.
* mh/send.c (read_mts_profile): Allow .mtstailor to override
system-wide configuration values.
2005-11-26 Sergey Poznyakoff <gray@gnu.org.ua>
* mail/msgset.y (msgset_negate): Fix loop break condition.
* sieve/sieve.c (options): Add --dry-run, an alias for -n.
2005-11-25 Sergey Poznyakoff <gray@gnu.org.ua>
* mail/cd.c, mh/folder.c: Fix diagnostic messages
2005-11-16 Sergey Poznyakoff <gray@gnu.org.ua>
* configure.ac: Declare HAVE_DECL_PROGRAM_INVOCATION_NAME,
otherwise argp-help.c can bail out at line 1693
* examples/argcv.c: Temporarily include config.h to make sure
replaced symbols are referenced properly.
The use of config.h in example files should be reduced to minimum.
* auth/sql.h (sql_interface): Fix data type
* include/mailutils/errno.hin: Include errno.h
Provide ECANCELED if it is missing (mainly for cygwin).
* mailbox/errors (MU_ERR_CANCELED): New error code.
* Makefile.am (EXTRA_DIST): Remove MU_EXTRA_DIST
* configure.ac: Call MU_FINISH
* m4/mu_libobj.m4 (MU_LIBSOURCE,MU_LIBSOURCES): Construct the list
of EXTRA_DIST sources.
(MU_FINISH): New defun
* mailbox/Makefile.am (EXTRA_DIST): Add MU_EXTRA_DIST
2005-11-15 Sergey Poznyakoff <gray@gnu.org.ua>
* configure.ac: Determine the size of off_t and define an
equivalent mu_off_t type. We cannot use off_t in the library since
its size depends on whether large file support is used or not,
which will lead to arbitrary crashes if a user application and the
library use off_t of different sizes.
(MU_COMMON_INCLUDES): New substitute variable
* gnulib.modules (mailutils): Add glob
* include/mailutils/types.h: Removed
* include/mailutils/types.hin: New file
* include/mailutils/Makefile.am: Build types.h
* auth/Makefile.am (UNCLUDES): Rewritten using MU_COMMON_INCLUDES
* comsat/Makefile.am: Likewise
* config/Makefile.am: Likewise
* dotlock/Makefile.am: Likewise
* examples/Makefile.am: Likewise
* frm/Makefile.am: Likewise
* guimb/Makefile.am: Likewise
* imap4d/Makefile.am: Likewise
* lib/Makefile.am: Likewise
* libmu_cpp/Makefile.am: Likewise
* libmu_scm/Makefile.am: Likewise
* libsieve/Makefile.am: Likewise
* libsieve/extensions/Makefile.am: Likewise
* mail/Makefile.am: Likewise
* mail.local/Makefile.am: Likewise
* mail.remote/Makefile.am: Likewise
* mailbox/Makefile.am: Likewise
* mailbox/imap/Makefile.am: Likewise
* mailbox/maildir/Makefile.am: Likewise
* mailbox/mbox/Makefile.am: Likewise
* mailbox/mh/Makefile.am: Likewise
* mailbox/nntp/Makefile.am: Likewise
* mailbox/pop/Makefile.am: Likewise
* mapi/Makefile.am: Likewise
* messages/Makefile.am: Likewise
* mh/Makefile.am: Likewise
* mimeview/Makefile.am: Likewise
* movemail/Makefile.am: Likewise
* pop3d/Makefile.am: Likewise
* readmsg/Makefile.am: Likewise
* sieve/Makefile.am: Likewise
* sql/Makefile.am: Likewise
* auth/tls.c: Use mu_off_t instead of off_t
* examples/argcv.c: Likewise
* examples/base64.c: Likewise
* examples/mimetest.c: Likewise
* examples/murun.c: Likewise
* examples/nntpclient.c: Likewise
* examples/pop3client.c: Likewise
* include/mailutils/header.h: Likewise
* include/mailutils/mailbox.h: Likewise
* include/mailutils/stream.h: Likewise
* include/mailutils/types.h: Likewise
* libmu_scm/mu_port.c: Likewise
* mail.local/main.c: Likewise
* mailbox/amd.c: Likewise
* mailbox/body.c: Likewise
* mailbox/file_stream.c: Likewise
* mailbox/filter.c: Likewise
* mailbox/filter_iconv.c: Likewise
* mailbox/filter_rfc822.c: Likewise
* mailbox/filter_trans.c: Likewise
* mailbox/header.c: Likewise
* mailbox/mailbox.c: Likewise
* mailbox/mapfile_stream.c
* mailbox/memory_stream.c
* mailbox/message.c: Likewise
* mailbox/mime.c: Likewise
* mailbox/stream.c: Likewise
* mailbox/tcp.c: Likewise
* mailbox/imap/folder.c: Likewise
* mailbox/imap/mbox.c: Likewise
* mailbox/include/amd.h: Likewise
* mailbox/include/filter0.h: Likewise
* mailbox/include/header0.h: Likewise
* mailbox/include/imap0.h: Likewise
* mailbox/include/mailbox0.h: Likewise
* mailbox/include/stream0.h: Likewise
* mailbox/mbox/mbox.c: Likewise
* mailbox/mbox/mboxscan.c: Likewise
* mailbox/nntp/mbox.c: Likewise
* mailbox/nntp/nntp_stream.c: Likewise
* mailbox/pop/mbox.c: Likewise
* mailbox/pop/pop3_stream.c: Likewise
* mh/mh_stream.c: Likewise
* pop3d/pop3d.c: Likewise
* m4/gnulib.m4: Update
* m4/mu_libobj.m4: Update
Update by gnulib-sync:
* lib/allocsa.c: Updated
* lib/allocsa.h: Updated
* lib/allocsa.valgrind: Updated
* lib/asprintf.c: Updated
* lib/error.c: Updated
* lib/error.h: Updated
* lib/exit.h: Updated
* lib/exitfail.c: Updated
* lib/exitfail.h: Updated
* lib/getpass.c: Updated
* lib/getpass.h: Updated
* lib/intprops.h: Updated
* lib/mbswidth.c: Updated
* lib/mbswidth.h: Updated
* lib/obstack.c: Updated
* lib/obstack.h: Updated
* lib/realloc.c: Updated
* lib/setenv.c: Updated
* lib/setenv.h: Updated
* lib/snprintf.c: Updated
* lib/snprintf.h: Updated
* lib/unsetenv.c: Updated
* lib/vasprintf.c: Updated
* lib/vasprintf.h: Updated
* lib/xalloc-die.c: Updated
* lib/xalloc.h: Updated
* lib/xmalloc.c: Updated
* lib/xsize.h: Updated
* lib/xstrtol.c: Updated
* lib/xstrtol.h: Updated
* lib/xstrtoul.c: Updated
* m4/alloca.m4: Updated
* m4/allocsa.m4: Updated
* m4/argp.m4: Updated
* m4/d-type.m4: Added to the repository
* m4/eealloc.m4: Updated
* m4/eoverflow.m4: Updated
* m4/error.m4: Updated
* m4/exitfail.m4: Updated
* m4/extensions.m4: Updated
* m4/fnmatch.m4: Updated
* m4/getdelim.m4: Updated
* m4/getline.m4: Updated
* m4/getlogin_r.m4: Added to the repository
* m4/getopt.m4: Updated
* m4/getpass.m4: Updated
* m4/glob.m4: Added to the repository
* m4/intmax_t.m4: Updated
* m4/inttypes.m4: Updated
* m4/inttypes_h_gl.m4: Updated
* m4/longdouble.m4: Updated
* m4/longlong_gl.m4: Updated
* m4/mbchar.m4: Updated
* m4/mbiter.m4: Added to the repository
* m4/mbrtowc.m4: Updated
* m4/mbstate_t.m4: Updated
* m4/mbswidth.m4: Updated
* m4/md5.m4: Updated
* m4/memchr.m4: Updated
* m4/mempcpy.m4: Updated
* m4/minmax.m4: Updated
* m4/obstack.m4: Updated
* m4/onceonly.m4: Updated
* m4/regex.m4: Updated
* m4/restrict.m4: Updated
* m4/setenv.m4: Updated
* m4/signed.m4: Updated
* m4/size_max.m4: Updated
* m4/snprintf.m4: Updated
* m4/stat-macros.m4: Added to the repository
* m4/stdbool.m4: Updated
* m4/stdint.m4: Added to the repository
* m4/stdint_h_gl.m4: Updated
* m4/strcase.m4: Updated
* m4/strchrnul.m4: Updated
* m4/strdup.m4: Added to the repository
* m4/strerror_r.m4: Updated
* m4/strndup.m4: Updated
* m4/strnlen.m4: Updated
* m4/strtok_r.m4: Updated
* m4/sysexits.m4: Updated
* m4/uintmax_t_gl.m4: Updated
* m4/ulonglong_gl.m4: Updated
* m4/vasnprintf.m4: Updated
* m4/vasprintf.m4: Updated
* m4/vsnprintf.m4: Updated
* m4/wchar_t.m4: Updated
* m4/wint_t.m4: Updated
* m4/xalloc.m4: Updated
* m4/xsize.m4: Updated
* m4/xstrtol.m4: Updated
* mailbox/alloca.c: Updated
* mailbox/alloca_.h: Updated
* mailbox/argp-ba.c: Updated
* mailbox/argp-eexst.c: Updated
* mailbox/argp-fmtstream.c: Updated
* mailbox/argp-fmtstream.h: Updated
* mailbox/argp-fs-xinl.c: Updated
* mailbox/argp-help.c: Updated
* mailbox/argp-namefrob.h: Updated
* mailbox/argp-parse.c: Updated
* mailbox/argp-pv.c: Updated
* mailbox/argp-pvh.c: Updated
* mailbox/argp-xinl.c: Updated
* mailbox/argp.h: Updated
* mailbox/asnprintf.c: Updated
* mailbox/fnmatch.c: Added to the repository
* mailbox/fnmatch_.h: Added to the repository
* mailbox/fnmatch_loop.c: Added to the repository
* mailbox/getdelim.c: Updated
* mailbox/getdelim.h: Updated
* mailbox/getline.c: Updated
* mailbox/getline.h: Updated
* mailbox/getlogin_r.c: Added to the repository
* mailbox/getlogin_r.h: Added to the repository
* mailbox/getopt.c: Updated
* mailbox/getopt1.c: Updated
* mailbox/getopt_.h: Updated
* mailbox/getopt_int.h: Updated
* mailbox/gettext.h: Updated
* mailbox/glob-libc.h: Added to the repository
* mailbox/glob.c: Added to the repository
* mailbox/glob_.h: Added to the repository
* mailbox/malloc.c: Added to the repository
* mailbox/mbchar.c: Updated
* mailbox/mbchar.h: Updated
* mailbox/mbuiter.h: Added to the repository
* mailbox/md5.c: Updated
* mailbox/md5.h: Updated
* mailbox/memchr.c: Updated
* mailbox/mempcpy.c: Updated
* mailbox/mempcpy.h: Updated
* mailbox/minmax.h: Updated
* mailbox/printf-args.c: Updated
* mailbox/printf-args.h: Updated
* mailbox/printf-parse.c: Updated
* mailbox/printf-parse.h: Updated
* mailbox/regcomp.c: Updated
* mailbox/regex.c: Updated
* mailbox/regex.h: Updated
* mailbox/regex_internal.c: Updated
* mailbox/regex_internal.h: Updated
* mailbox/regexec.c: Updated
* mailbox/size_max.h: Updated
* mailbox/stat-macros.h: Added to the repository
* mailbox/stdbool_.h: Updated
* mailbox/stdint_.h: Added to the repository
* mailbox/strcase.h: Updated
* mailbox/strcasecmp.c: Updated
* mailbox/strchrnul.c: Updated
* mailbox/strchrnul.h: Updated
* mailbox/strdup.c: Added to the repository
* mailbox/strdup.h: Added to the repository
* mailbox/strncasecmp.c: Updated
* mailbox/strndup.c: Updated
* mailbox/strndup.h: Updated
* mailbox/strnlen.c: Updated
* mailbox/strnlen.h: Updated
* mailbox/strnlen1.c: Updated
* mailbox/strnlen1.h: Updated
* mailbox/strtok_r.c: Updated
* mailbox/strtok_r.h: Updated
* mailbox/sysexit_.h: Updated
* mailbox/vasnprintf.c: Updated
* mailbox/vasnprintf.h: Updated
* mailbox/vsnprintf.c: Updated
* mailbox/vsnprintf.h: Updated
* mailbox/xsize.h: Updated
* examples/argcv.c: Add missing includes
* examples/mailcap.c: Likewise
* examples/url-parse.c: Likewise
* mail/send.c: Likewise
* mailbox/list.c: Likewise
* mh/mh_alias.l: Likewise
* mimeview/mimetypes.l: Likewise
* examples/nntpclient.c: Add missing forward declarations
* libsieve/sieve.h (mu_sieve_yylex,mu_sieve_yyerror): Add
declarations.
* libsieve/sieve.y (yylex,yyerror): Remove declarations
* include/mailutils/mutil.h (mu_is_proto): New function.
* mailbox/mutil.c: Likewise
* mailbox/mbx_default.c (is_proto): Replace by mu_is_proto. All
callers updated
* mailbox/mailbox.c (mailbox_folder_create): Do not try to select
previous level if given a protocol spec, other than `file:'
* mh/mh.h (mh_file_to_message): Change signature
* mh/mh_init.c: Likewise
* mimeview/Makefile.am (AM_CPPFLAGS): Add -D_GNU_SOURCE=1, needed
for compiling lex sources
* mh/Makefile.am: Likewise
2005-11-14 Sergey Poznyakoff <gray@gnu.org.ua>
* examples/argcv.c: Include <mailutils/error.h>
* examples/base64.c: Include <config.h>
* readmsg/readmsg.h: Likewise
* mail/z.c (z_parse_args): change type of return_count
(mail_z): Change type of count to off_t
* include/mailutils/stream.h: Fix indentation
* scripts/gnulib-sync: Replace AC_LIBSOURCE with MU_LIBSOURCE
2005-11-14 Sergey Poznyakoff <gray@gnu.org.ua>
* examples/argcv.c: Include <mailutils/error.h>
* examples/base64.c: Include <config.h>
* readmsg/readmsg.h: Likewise
* mail/z.c (z_parse_args): change type of return_count
(mail_z): Change type of count to off_t
* include/mailutils/stream.h: Fix indentation
* mailbox/file_stream.c (struct _fise_stream.offset): Change type
to off_t
2005-11-12 Sergey Poznyakoff <gray@gnu.org.ua>
* configure.ac (AUTHLIBS,AUTHLIBS_DEPENDENCY,AUTHINCS): Prefixed
with MU_
* mail/msgset.y (check_set): Was displaying `inappropriate message'
diagnostics if the first message from the set was deleted. Fixed.
* mail/util.c, mailbox/registrar.c: Add typecasts
* mh/mh.h: Add includes needed for W.*() macros
* comsat/Makefile.am, config/Makefile.am, examples/Makefile.am,
frm/Makefile.am, guimb/Makefile.am, imap4d/Makefile.am,
libmu_scm/Makefile.am, libsieve/Makefile.am, mail/Makefile.am,
mail.local/Makefile.am, mail.remote/Makefile.am,
mailbox/Makefile.am, messages/Makefile.am, mh/Makefile.am,
movemail/Makefile.am, pop3d/Makefile.am, readmsg/Makefile.am,
sieve/Makefile.am: Load MU_AUTHLIBS before libmailutils. Fixes
cygwin build.
2005-11-09 Sergey Poznyakoff <gray@gnu.org.ua>
* configure.ac: Somewhat reluctantly append $(EXEEXT) to popauth
binary name to fix cygwin builds.
* mail.remote/Makefile.am (PROGRAMS_SMTP): Likewise
* mh/Makefile.am (PROGRAMS_MH): Likewise
2005-11-07 Sergey Poznyakoff <gray@gnu.org.ua>
* configure.ac (GUIMB): Fix assignment to work on cygwin too
* THANKS: Add D. J. Henman
2005-11-03 Sergey Poznyakoff <gray@gnu.org.ua>
* comsat/Makefile.am, dotlock/Makefile.am, examples/Makefile.am,
frm/Makefile.am, guimb/Makefile.am, imap4d/Makefile.am,
mail.local/Makefile.am, mail.remote/Makefile.am, mapi/Makefile.am,
messages/Makefile.am, mh/Makefile.am, movemail/Makefile.am,
pop3d/Makefile.am, readmsg/Makefile.am, sieve/Makefile.am: Load
libmuauth before libmailutils.
2005-11-02 Sergey Poznyakoff <gray@gnu.org.ua>
* configure.ac: Fix typo
* comsat/comsat.c: Fix typo in the comment
2005-11-01 Sergey Poznyakoff <gray@gnu.org.ua>
* libsieve/sieve.l (pop_source): Clear sieve_filename if
context_stack is empty.
2005-10-31 Sergey Poznyakoff <gray@gnu.org.ua>
* Makefile.am (release): Rename to alpha
(alphacheck): New rule
* configure.ac: Always define program_name to
program_invocation_name
* libsieve/actions.c (build_mime): Split into three smaller
functions, each for its own task.
Add Content-Type,Content-Transfer-Encoding headers to the
DSN. Proposed by Kostas Zorbadelos.
* sieve/testsuite/Reject: Updated to match the above changes
* sieve/testsuite/sieve/reject.exp: Updated
* examples/http.c: Include <sys/time.h>
* mailbox/imap/folder.c (imap_writeline): Fix handling of input
lines longer than 254 chars. Proposed by Daniel Kahn Gillmor.
* THANKS: Add Kostas Zorbadelos and Daniel Kahn Gillmor.
2005-10-30 Sergey Poznyakoff <gray@gnu.org.ua>
* NEWS: Updated
* include/mailutils/compat.h: New file. Compatibility defines for
programs using mailutils interface version 0:0:0.
* include/mailutils/Makefile.am (pkginclude_HEADERS): Add compat.h
* include/mailutils/folder.h (mu_0_6_folder_list)
(mu_0_6_folder_lsub,mu_0_6_folder_list_destroy): Compatibility
functions.
* include/mailutils/mailutils.h: Include compat.h, if required
* include/mailutils/message.h (message_unref): Rename to
mu_message_unref. All callers updated
* include/mailutils/mime.h (MIME_INCREAMENTAL_PARSER): Remove
(MIME_MULTIPART_MIXED,MIME_MULTIPART_ALT): Prefix with MU_. All
uses changed.
* include/mailutils/monitor.h (struct mu__monitor): Rename to
mu_monitor. All uses changed.
* include/mailutils/registrar.h (struct _mu_record): Fix member
names. All uses changed
* include/mailutils/sql.h (rdl_init_t,rdl_done_t): Prefix with mu_
* mail/util.c (util_do_command): Minor fix
* libsieve/actions.c,libsieve/extensions/vacation.c,
mailbox/filter.c, mailbox/folder.c, mailbox/mime.c,
mailbox/registrar.c, mailbox/rfc2047.c, mh/mhl.c, mh/mhn.c: Synch
with the above changes.
* mail/if.c (mail_if): Fix 'r' condition
(mail_else): Fix handling of nested ifs
* mail/mail.c: New option --exec (-E)
(mail_cmdline): Invalidate the page when a new mail arrives
(main): Fix handling of modes.
* mail/quit.c (mail_mbox_close): mbox can be NULL (e.g.
--exec=quit was given)
* mail/util.c (util_do_command): Accept traditional contracted
forms (`d*', `p9')
Fix bug in handling conditional branches (bug introduced on
2005-08-11).
* mail/testsuite/if.mail: New test script.
* mail/testsuite/Makefile.am (EXTRA_DIST): Add if.mail
* mail/testsuite/mail/if.exp: New test case.
* mail/testsuite/mail/DISTFILES: Add if.exp
2005-10-28 Sergey Poznyakoff <gray@gnu.org.ua>
* examples/argcv.c: Include config.h
2005-10-17 Sergey Poznyakoff <gray@gnu.org.ua>
* configure.ac: New option --without-fribidi allows to disable
fribidi support.
Check for FRIBIDI_CHARSET_CAP_RTL vs. FRIBIDI_CHAR_SET_CAP_RTL.
* README: Updated
2005-09-29 Sergey Poznyakoff <gray@gnu.org.ua>
* examples/decode2047.c: Allow to specify charset from the command
line.
* examples/encode2047.c: Allow to specify charset and encoding
from the command line.
* include/mailutils/filter.h (mu_rfc_2047_B_filter): New filter.
* include/mailutils/libsieve.h (MU_SIEVE_CHARSET): New define
* libsieve/extensions/vacation.c: Implemented :mime. Correctly
handle subject line, no matter what the charset is.
Fixed bug in creating `References:' header.
* mailbox/filter.c (mu_filter_get_list): Add mu_rfc_2047_B_filter
* mailbox/filter_trans.c (mu_rfc_2047_B_filter): New filter. Alias
to base64.
* include/mailutils/iterator.h: Minor stylistic changes
* mailbox/iterator.c: Likewise
* mailbox/wicket.c: Likewise
* mh/mhn.c: Likewise
2005-09-22 Sergey Poznyakoff <gray@gnu.org.ua>
* NEWS: Minor wording change.
* config/mailutils-config.c: New command line argument "sieve".
2005-09-19 Sergey Poznyakoff <gray@gnu.org.ua>
* mailbox/imap/mbox.c (delete_to_string): Make sure the message
set does not end with a comma. Bug reported by Gerd Flaig
(<gefla@pond.sub.org>), I suppose.
2005-09-17 Sergey Poznyakoff <gray@gnu.org.ua>
* mh/send.c (expand_aliases): Use mh_expand_aliases
* mh/forw.c,mh/repl.c: Implemented --annotate
* mh/mh_init.c (mh_quote,mh_expand_aliases): New functions
* mh/mh.h (mh_quote,mh_expand_aliases): New functions
(struct mh_whatnow_env): New fields to support annotation.
* mh/mh_whatnow.c: Support message annotation. Improved error
reporting after launching external programs.
* mh/anno.c (main): Make the first annotated message current.
(opt_handler): Quote --text argument, if necessary.
* mh/TODO: Updated
2005-09-14 Sergey Poznyakoff <gray@gnu.org.ua>
* mail/page.c (cond_page_invalidate,page_move): Bugfix.
2005-09-09 Sergey Poznyakoff <gray@gnu.org.ua>
* imap4d/search.c (imap4d_search): Fix potential vulnerability:
pass format string as a third argument to util_finish
* imap4d/copy.c, imap4d/fetch.c, imap4d/store.c: Always pass
format string as a third argument to util_finish. Although this is not
necessary, since 'buffer' is guaranteed to contain a normal error
string, without format specifiers, yet this will simplify maintenance.
2005-08-31 Sergey Poznyakoff <gray@gnu.org.ua>
* examples/lsf.c: New test program. List folders
* examples/Makefile.am: Add lsf
* mailbox/imap/folder.c (guess_level,list_copy): Fixed
(imap_parse): Handle NO case explicitly.
* mailbox/mbox/folder.c: Minor fix.
2005-08-30 Sergey Poznyakoff <gray@gnu.org.ua>
Remove obsolete usage of mu_folder_list (ex. folder_list). It
seems to have been introduced when mu_list_t (ex. list_t) has
not yet been there. All callers updated. Mbox format
implementation has been tested. Imap format one is being tested.
* include/mailutils/folder.h (struct mu_list_response.level): New
member
(struct mu_folder_list): Removed. Use mu_list_t instead
(mu_folder_list): Use mu_list_t. Take an extra argument: a maximum
recursion level.
(mu_folder_lsub): Change typo of the last argument (mu_list_t
now).
(mu_folder_list_destroy): Removed
(mu_list_response_free): New function
* lib/mu_asprintf.h: Remove vestiges of __P(). Define _GNU_SOURCE,
if not already defined.
* mailbox/imap/folder.c: Rewritten for new
mu_folder_list,mu_folder_lsub semantics.
* mailbox/imap/mbox.c: Likewise
* mailbox/include/folder0.h: Likewise.
* mailbox/include/imap0.h: Likewise.
* mailbox/mbox/folder.c: Likewise.
* mailbox/nntp/folder.c: Likewise.
* mail/mailline.c: Use new mu_folder_list
* mailbox/folder.c: Likewise.
* auth/radius.c: Updated for recent libgnuradius
* mh/folder.c: Implement --pack, --verbose, --dry-run (just in case).
* mh/TODO: Updated
* mh/inc.c: Minor bugfixes.
* mh/mark.c: Likewise
* mh/mh.h (mh_context_iterator): Changed signature
* mh/mh_ctx.c (mh_context_iterate): Bugfix
* mh/mh_getopt.h (ARG_PACK): New define
2005-08-29 Sergey Poznyakoff <gray@gnu.org.ua>
* configure.ac: Raise version number to 0.6.92
Raise library current interface version to 1
* NEWS: Updated
* include/mailutils/filter.h,
include/mailutils/registrar.h, include/mailutils/types.h,
mailbox/filter.c, mailbox/filter_rfc822.c, mailbox/filter_trans.c,
mailbox/folder.c, mailbox/getopt.h, mailbox/locker.c,
mailbox/parse822.c, mailbox/registrar.c, mailbox/sendmail.c,
mailbox/smtp.c, mailbox/url.c, mailbox/imap/folder.c,
mailbox/include/address0.h, mailbox/include/attribute0.h,
mailbox/include/auth0.h, mailbox/include/body0.h,
mailbox/include/debug0.h, mailbox/include/envelope0.h,
mailbox/include/filter0.h, mailbox/include/folder0.h,
mailbox/include/header0.h, mailbox/include/iterator0.h,
mailbox/include/list0.h, mailbox/include/mailbox0.h,
mailbox/include/mailer0.h, mailbox/include/message0.h,
mailbox/include/mime0.h, mailbox/include/observer0.h,
mailbox/include/property0.h, mailbox/include/stream0.h,
mailbox/include/url0.h, mailbox/maildir/folder.c,
mailbox/mbox/folder.c, mailbox/mh/folder.c, mailbox/nntp/folder.c,
mailbox/pop/folder.c: Fix-up structure names from types.h
Final seasoning: Replace munre_ with mu_unre_
* include/mailutils/mutil.h
* libsieve/extensions/vacation.c
* mail/followup.c
* mail/reply.c
* mail/util.c
* mailbox/munre.c
* mh/mh_format.c
* mh/mh_init.c
2005-08-27 Wojciech Polak <polak@gnu.org>
Normalize global namespace. Part 2: Symbols defined in header files
mailer.h, message.h, mime.h, monitor.h, observer.h, parse822.h,
property.h, registrar.h, stream.h, tls.h, types.h, url.h.
Files affected:
* auth/gsasl.c, auth/tls.c, comsat/action.c, comsat/comsat.c,
comsat/comsat.h, dotlock/dotlock.c, examples/addr.c,
examples/base64.c, examples/decode2047.c, examples/encode2047.c,
examples/http.c, examples/iconv.c, examples/listop.c,
examples/mailcap.c, examples/mimetest.c, examples/msg-send.c,
examples/mta.c, examples/murun.c, examples/nntpclient.c,
examples/numaddr.c, examples/pop3client.c, examples/sfrom.c,
examples/url-parse.c, frm/common.c, frm/frm.c, frm/frm.h,
frm/from.c, guimb/collect.c, guimb/guimb.h, guimb/util.c,
imap4d/append.c, imap4d/auth_gsasl.c, imap4d/authenticate.c,
imap4d/capability.c, imap4d/copy.c, imap4d/fetch.c, imap4d/imap4d.c,
imap4d/imap4d.h, imap4d/rename.c, imap4d/search.c, imap4d/status.c,
imap4d/store.c, imap4d/sync.c, imap4d/util.c,
include/mailutils/address.h, include/mailutils/attribute.h,
include/mailutils/auth.h, include/mailutils/body.h,
include/mailutils/envelope.h, include/mailutils/filter.h,
include/mailutils/folder.h, include/mailutils/gsasl.h,
include/mailutils/guile.h, include/mailutils/header.h,
include/mailutils/iterator.h, include/mailutils/libsieve.h,
include/mailutils/list.h, include/mailutils/locker.h,
include/mailutils/mailbox.h, include/mailutils/mailcap.h,
include/mailutils/mailer.h, include/mailutils/message.h,
include/mailutils/mime.h, include/mailutils/monitor.h,
include/mailutils/mu_auth.h, include/mailutils/mutil.h,
include/mailutils/nntp.h, include/mailutils/observer.h,
include/mailutils/parse822.h, include/mailutils/pop3.h,
include/mailutils/property.h, include/mailutils/refcount.h,
include/mailutils/registrar.h, include/mailutils/stream.h,
include/mailutils/tls.h, include/mailutils/types.h,
include/mailutils/url.h, include/mailutils/sys/nntp.h,
include/mailutils/sys/pop3.h, lib/mailcap.c, libmu_scm/mu_address.c,
libmu_scm/mu_body.c, libmu_scm/mu_mailbox.c, libmu_scm/mu_message.c,
libmu_scm/mu_mime.c, libmu_scm/mu_port.c, libmu_scm/mu_scm.c,
libsieve/actions.c, libsieve/argp.c, libsieve/comparator.c,
libsieve/load.c, libsieve/prog.c, libsieve/register.c,
libsieve/relational.c, libsieve/require.c, libsieve/runtime.c,
libsieve/sieve.h, libsieve/sieve.l, libsieve/sieve.y, libsieve/tests.c,
libsieve/util.c, libsieve/extensions/list.c, libsieve/extensions/spamd.c,
libsieve/extensions/timestamp.c, libsieve/extensions/vacation.c,
mail/alias.c, mail/alt.c, mail/copy.c, mail/decode.c, mail/delete.c,
mail/edit.c, mail/escape.c, mail/file.c, mail/followup.c, mail/from.c,
mail/hold.c, mail/mail.c, mail/mail.h, mail/mailline.c, mail/mbox.c,
mail/msgset.y, mail/next.c, mail/page.c, mail/pipe.c, mail/previous.c,
mail/print.c, mail/quit.c, mail/reply.c, mail/retain.c, mail/send.c,
mail/size.c, mail/summary.c, mail/tag.c, mail/top.c, mail/touch.c,
mail/undelete.c, mail/util.c, mail/visual.c, mail/write.c,
mail.local/mail.local.h, mail.local/main.c, mail.local/script.c,
mail.remote/mail.remote.c, mailbox/address.c, mailbox/amd.c,
mailbox/attachment.c, mailbox/attribute.c, mailbox/auth.c,
mailbox/body.c, mailbox/envelope.c, mailbox/file_stream.c,
mailbox/filter.c, mailbox/filter_iconv.c, mailbox/filter_rfc822.c,
mailbox/filter_trans.c, mailbox/folder.c, mailbox/header.c,
mailbox/iterator.c, mailbox/list.c, mailbox/locker.c, mailbox/mailbox.c,
mailbox/mailcap.c, mailbox/mailer.c, mailbox/mapfile_stream.c,
mailbox/mbx_default.c, mailbox/memory_stream.c, mailbox/message.c,
mailbox/mime.c, mailbox/monitor.c, mailbox/mu_argp.c, mailbox/mu_auth.c,
mailbox/mutil.c, mailbox/observer.c, mailbox/parse822.c,
mailbox/property.c, mailbox/registrar.c, mailbox/rfc2047.c,
mailbox/sendmail.c, mailbox/smtp.c, mailbox/stream.c, mailbox/tcp.c,
mailbox/ticket.c, mailbox/url.c, mailbox/url_sendmail.c,
mailbox/url_smtp.c, mailbox/wicket.c, mailbox/imap/folder.c,
mailbox/imap/mbox.c, mailbox/imap/url.c, mailbox/include/amd.h,
mailbox/include/attribute0.h, mailbox/include/auth0.h,
mailbox/include/body0.h, mailbox/include/envelope0.h,
mailbox/include/filter0.h, mailbox/include/folder0.h,
mailbox/include/header0.h, mailbox/include/imap0.h,
mailbox/include/iterator0.h, mailbox/include/list0.h,
mailbox/include/mailbox0.h, mailbox/include/mailer0.h,
mailbox/include/message0.h, mailbox/include/mime0.h,
mailbox/include/observer0.h, mailbox/include/property0.h,
mailbox/include/registrar0.h, mailbox/include/stream0.h,
mailbox/include/url0.h, mailbox/maildir/folder.c, mailbox/maildir/mbox.c,
mailbox/mbox/folder.c, mailbox/mbox/mbox.c, mailbox/mbox/mbox0.h,
mailbox/mbox/mboxscan.c, mailbox/mbox/url.c, mailbox/mh/folder.c,
mailbox/mh/mbox.c, mailbox/nntp/folder.c, mailbox/nntp/mbox.c,
mailbox/nntp/nntp0.h, mailbox/nntp/nntp_article.c,
mailbox/nntp/nntp_body.c, mailbox/nntp/nntp_carrier.c,
mailbox/nntp/nntp_connect.c, mailbox/nntp/nntp_destroy.c,
mailbox/nntp/nntp_disconnect.c, mailbox/nntp/nntp_head.c,
mailbox/nntp/nntp_help.c, mailbox/nntp/nntp_ihave.c,
mailbox/nntp/nntp_iterator.c, mailbox/nntp/nntp_list_active.c,
mailbox/nntp/nntp_list_distribpats.c,
mailbox/nntp/nntp_list_distributions.c,
mailbox/nntp/nntp_list_extensions.c, mailbox/nntp/nntp_list_newsgroups.c,
mailbox/nntp/nntp_list_times.c, mailbox/nntp/nntp_newgroups.c,
mailbox/nntp/nntp_newnews.c, mailbox/nntp/nntp_post.c,
mailbox/nntp/nntp_readline.c, mailbox/nntp/nntp_sendline.c,
mailbox/nntp/nntp_stream.c, mailbox/nntp/url.c, mailbox/pop/folder.c,
mailbox/pop/mbox.c, mailbox/pop/pop3_capa.c, mailbox/pop/pop3_carrier.c,
mailbox/pop/pop3_connect.c, mailbox/pop/pop3_destroy.c,
mailbox/pop/pop3_disconnect.c, mailbox/pop/pop3_iterator.c,
mailbox/pop/pop3_lista.c, mailbox/pop/pop3_readline.c,
mailbox/pop/pop3_retr.c, mailbox/pop/pop3_sendline.c,
mailbox/pop/pop3_stls.c, mailbox/pop/pop3_stream.c,
mailbox/pop/pop3_top.c, mailbox/pop/pop3_uidla.c, mailbox/pop/url.c,
messages/messages.c, mh/ali.c, mh/anno.c, mh/comp.c, mh/compcommon.c,
mh/folder.c, mh/forw.c, mh/inc.c, mh/mark.c, mh/mh.h, mh/mh_alias.y,
mh/mh_ctx.c, mh/mh_format.c, mh/mh_init.c, mh/mh_list.c, mh/mh_msgset.c,
mh/mh_stream.c, mh/mh_whatnow.c, mh/mh_whom.c, mh/mhl.c, mh/mhn.c,
mh/mhpath.c, mh/pick.c, mh/pick.h, mh/pick.y, mh/refile.c, mh/repl.c,
mh/rmf.c, mh/rmm.c, mh/scan.c, mh/send.c, mh/sortm.c,
mimeview/mimetypes.y, mimeview/mimeview.c, movemail/movemail.c,
pop3d/apop.c, pop3d/dele.c, pop3d/expire.c, pop3d/extra.c, pop3d/list.c,
pop3d/lock.c, pop3d/pop3d.c, pop3d/pop3d.h, pop3d/quit.c, pop3d/retr.c,
pop3d/rset.c, pop3d/stat.c, pop3d/top.c, pop3d/uidl.c, pop3d/user.c,
readmsg/msglist.c, readmsg/readmsg.c, readmsg/readmsg.h, sieve/sieve.c,
sql/odbc.c.
2005-08-26 Sergey Poznyakoff <gray@gnu.org.ua>
Normalize global namespace. All exportable symbols begin with mu_.
Part 1: Symbols defined in header files address.h, argcv.h,
attribute.h, auth.h, body.h, daemon.h, debug.h, envelope.h,
errno.h, error.h, filter.h, folder.h, gsasl.h, guile.h, header.h,
iterator.h, libsieve.h, list.h, locker.h, mailbox.h.
Files affected:
* configure.ac, auth/gsasl.c, auth/radius.c, comsat/action.c,
comsat/cfg.c, comsat/comsat.c, dotlock/dotlock.c, examples/addr.c,
examples/argcv.c, examples/base64.c, examples/iconv.c,
examples/listop.c, examples/mimetest.c, examples/msg-send.c,
examples/mta.c, examples/murun.c, examples/nntpclient.c,
examples/numaddr.c, examples/pop3client.c, examples/sfrom.c,
frm/common.c, frm/frm.c, frm/from.c, guimb/collect.c,
guimb/main.c, guimb/util.c, imap4d/append.c, imap4d/auth_gsasl.c,
imap4d/authenticate.c, imap4d/bye.c, imap4d/capability.c,
imap4d/close.c, imap4d/copy.c, imap4d/expunge.c, imap4d/fetch.c,
imap4d/imap4d.c, imap4d/imap4d.h, imap4d/rename.c,
imap4d/search.c, imap4d/select.c, imap4d/status.c, imap4d/store.c,
imap4d/sync.c, imap4d/util.c, include/mailutils/address.h,
include/mailutils/argcv.h, include/mailutils/attribute.h,
include/mailutils/auth.h, include/mailutils/body.h,
include/mailutils/daemon.h, include/mailutils/envelope.h,
include/mailutils/error.h, include/mailutils/filter.h,
include/mailutils/folder.h, include/mailutils/gsasl.h,
include/mailutils/guile.h, include/mailutils/header.h,
include/mailutils/iterator.h, include/mailutils/libsieve.h,
include/mailutils/list.h, include/mailutils/locker.h,
include/mailutils/mailbox.h, include/mailutils/nntp.h,
include/mailutils/pop3.h, include/mailutils/types.h,
lib/mailcap.c, libmu_scm/mu_address.c, libmu_scm/mu_body.c,
libmu_scm/mu_guimb.c, libmu_scm/mu_logger.c,
libmu_scm/mu_mailbox.c, libmu_scm/mu_message.c,
libmu_scm/mu_mime.c, libmu_scm/mu_scm.c, libmu_scm/mu_util.c,
libsieve/Makefile.am, libsieve/actions.c, libsieve/argp.c,
libsieve/comparator.c, libsieve/load.c, libsieve/prog.c,
libsieve/register.c, libsieve/relational.c, libsieve/require.c,
libsieve/runtime.c, libsieve/sieve.h, libsieve/sieve.l,
libsieve/sieve.y, libsieve/tests.c, libsieve/util.c,
libsieve/extensions/list.c, libsieve/extensions/spamd.c,
libsieve/extensions/timestamp.c, libsieve/extensions/vacation.c,
m4/longdouble.m4, m4/signed.m4, m4/size_max.m4, m4/wchar_t.m4,
m4/wint_t.m4, m4/xsize.m4, mail/alias.c, mail/copy.c,
mail/decode.c, mail/delete.c, mail/escape.c, mail/exit.c,
mail/file.c, mail/followup.c, mail/from.c, mail/hold.c,
mail/inc.c, mail/mail.c, mail/mailline.c, mail/mbox.c,
mail/msgset.y, mail/next.c, mail/page.c, mail/print.c,
mail/quit.c, mail/reply.c, mail/retain.c, mail/send.c,
mail/shell.c, mail/summary.c, mail/tag.c, mail/touch.c,
mail/undelete.c, mail/util.c, mail/write.c, mail.local/main.c,
mail.local/script.c, mail.remote/mail.remote.c,
mailbox/Makefile.am, mailbox/address.c, mailbox/amd.c,
mailbox/argcv.c, mailbox/attachment.c, mailbox/attribute.c,
mailbox/auth.c, mailbox/body.c, mailbox/daemon.c,
mailbox/envelope.c, mailbox/file_stream.c, mailbox/filter.c,
mailbox/filter_iconv.c, mailbox/filter_rfc822.c,
mailbox/filter_trans.c, mailbox/folder.c, mailbox/header.c,
mailbox/iterator.c, mailbox/list.c, mailbox/locker.c,
mailbox/mailbox.c, mailbox/mailer.c, mailbox/mbx_default.c,
mailbox/message.c, mailbox/mime.c, mailbox/mu_argp.c,
mailbox/mu_auth.c, mailbox/muerror.c, mailbox/mutil.c,
mailbox/observer.c, mailbox/parse822.c, mailbox/registrar.c,
mailbox/rfc2047.c, mailbox/sendmail.c, mailbox/smtp.c,
mailbox/ticket.c, mailbox/wicket.c, mailbox/imap/Makefile.am,
mailbox/imap/folder.c, mailbox/imap/mbox.c, mailbox/include/amd.h,
mailbox/include/folder0.h, mailbox/include/imap0.h,
mailbox/include/list0.h, mailbox/include/mime0.h,
mailbox/maildir/Makefile.am, mailbox/maildir/mbox.c,
mailbox/mbox/Makefile.am, mailbox/mbox/folder.c,
mailbox/mbox/mbox.c, mailbox/mbox/mboxscan.c,
mailbox/mh/Makefile.am, mailbox/mh/folder.c, mailbox/mh/mbox.c,
mailbox/nntp/Makefile.am, mailbox/nntp/folder.c,
mailbox/nntp/mbox.c, mailbox/nntp/nntp_iterator.c,
mailbox/nntp/nntp_list_active.c,
mailbox/nntp/nntp_list_distribpats.c,
mailbox/nntp/nntp_list_distributions.c,
mailbox/nntp/nntp_list_extensions.c,
mailbox/nntp/nntp_list_newsgroups.c,
mailbox/nntp/nntp_list_times.c, mailbox/pop/Makefile.am,
mailbox/pop/folder.c, mailbox/pop/mbox.c, mailbox/pop/pop3_capa.c,
mailbox/pop/pop3_iterator.c, messages/messages.c, mh/ali.c,
mh/anno.c, mh/comp.c, mh/folder.c, mh/forw.c, mh/inc.c, mh/mark.c,
mh/mh_alias.y, mh/mh_argp.c, mh/mh_ctx.c, mh/mh_format.c,
mh/mh_init.c, mh/mh_list.c, mh/mh_msgset.c, mh/mh_sequence.c,
mh/mh_stream.c, mh/mh_whatnow.c, mh/mh_whom.c, mh/mhn.c,
mh/mhpath.c, mh/pick.c, mh/pick.y, mh/refile.c, mh/repl.c,
mh/rmf.c, mh/rmm.c, mh/scan.c, mh/send.c, mh/sortm.c,
mimeview/mimetypes.y, mimeview/mimeview.c, movemail/movemail.c,
pop3d/apop.c, pop3d/dele.c, pop3d/expire.c, pop3d/extra.c,
pop3d/list.c, pop3d/lock.c, pop3d/pop3d.c, pop3d/popauth.c,
pop3d/quit.c, pop3d/retr.c, pop3d/rset.c, pop3d/stat.c,
pop3d/top.c, pop3d/uidl.c, pop3d/user.c, readmsg/msglist.c,
readmsg/readmsg.c, sieve/sieve.c, sql/odbc.c.
2005-08-24 Sergey Poznyakoff <gray@gnu.org.ua>
* scripts/ylwrap: Updated from Radius repository
2005-08-24 Sergey Poznyakoff <gray@gnu.org.ua>
* mailbox/testsuite/Makefile.am (EXTRA_DIST): Add Argcv
2005-08-16 Sergey Poznyakoff <gray@gnu.org.ua>
* auth/sql.h: Avoid redefinition of _XOPEN_SOURCE
* mailbox/imap/folder.c: Likewise
* mailbox/maildir/mbox.c: Likewise
* mailbox/mbox/mbox0.h: Likewise
* mailbox/mh/mbox.c: Likewise
* lib/Makefile.am: Updated
* mailbox/Makefile.am: Updated
Update by gnulib-sync:
* lib/allocsa.c: Updated
* lib/allocsa.h: Updated
* lib/allocsa.valgrind: Updated
* lib/asprintf.c: Updated
* lib/error.c: Updated
* lib/error.h: Updated
* lib/exit.h: Updated
* lib/exitfail.c: Updated
* lib/exitfail.h: Updated
* lib/fnmatch.c: Updated
* lib/fnmatch_.h: Updated
* lib/fnmatch_loop.c: Updated
* lib/getpass.c: Updated
* lib/getpass.h: Updated
* lib/intprops.h: Added to the repository
* lib/malloc.c: Updated
* lib/mbswidth.c: Updated
* lib/mbswidth.h: Updated
* lib/obstack.c: Updated
* lib/obstack.h: Updated
* lib/realloc.c: Updated
* lib/setenv.c: Updated
* lib/setenv.h: Updated
* lib/snprintf.c: Updated
* lib/snprintf.h: Updated
* lib/unsetenv.c: Updated
* lib/vasprintf.c: Updated
* lib/vasprintf.h: Updated
* lib/xalloc-die.c: Added to the repository
* lib/xalloc.h: Updated
* lib/xmalloc.c: Updated
* lib/xsize.h: Updated
* lib/xstrtol.c: Updated
* lib/xstrtol.h: Updated
* lib/xstrtoul.c: Updated
* m4/alloca.m4: Updated
* m4/allocsa.m4: Updated
* m4/argp.m4: Updated
* m4/eealloc.m4: Updated
* m4/eoverflow.m4: Updated
* m4/error.m4: Updated
* m4/exitfail.m4: Updated
* m4/extensions.m4: Updated
* m4/fnmatch.m4: Updated
* m4/getdelim.m4: Added to the repository
* m4/getline.m4: Updated
* m4/getopt.m4: Updated
* m4/getpass.m4: Updated
* m4/intmax_t.m4: Updated
* m4/intmax_t.m4: Updated
* m4/inttypes_h_gl.m4: Updated
* m4/inttypes_h_gl.m4: Updated
* m4/longdouble.m4: Updated
* m4/longdouble.m4: Updated
* m4/longlong_gl.m4: Updated
* m4/longlong_gl.m4: Updated
* m4/mbchar.m4: Added to the repository
* m4/mbrtowc.m4: Updated
* m4/mbrtowc.m4: Updated
* m4/mbstate_t.m4: Updated
* m4/mbswidth.m4: Updated
* m4/md5.m4: Updated
* m4/memchr.m4: Added to the repository
* m4/mempcpy.m4: Updated
* m4/minmax.m4: Added to the repository
* m4/obstack.m4: Updated
* m4/onceonly.m4: Updated
* m4/onceonly.m4: Updated
* m4/regex.m4: Updated
* m4/restrict.m4: Updated
* m4/setenv.m4: Updated
* m4/signed.m4: Updated
* m4/size_max.m4: Updated
* m4/snprintf.m4: Updated
* m4/stdbool.m4: Updated
* m4/stdint_h_gl.m4: Updated
* m4/stdint_h_gl.m4: Updated
* m4/strcase.m4: Updated
* m4/strchrnul.m4: Updated
* m4/strerror_r.m4: Updated
* m4/strndup.m4: Updated
* m4/strnlen.m4: Updated
* m4/strtok_r.m4: Updated
* m4/sysexits.m4: Updated
* m4/uint32_t.m4: Updated
* m4/uintmax_t_gl.m4: Updated
* m4/ulonglong_gl.m4: Updated
* m4/unlocked-io.m4: Updated
* m4/vasnprintf.m4: Updated
* m4/vasprintf.m4: Updated
* m4/vsnprintf.m4: Updated
* m4/wchar_t.m4: Updated
* m4/wint_t.m4: Updated
* m4/xalloc.m4: Updated
* m4/xsize.m4: Updated
* m4/xsize.m4: Updated
* m4/xstrtol.m4: Updated
* mailbox/alloca.c: Updated
* mailbox/alloca_.h: Updated
* mailbox/argp-ba.c: Updated
* mailbox/argp-eexst.c: Updated
* mailbox/argp-fmtstream.c: Updated
* mailbox/argp-fmtstream.h: Updated
* mailbox/argp-fs-xinl.c: Updated
* mailbox/argp-help.c: Updated
* mailbox/argp-namefrob.h: Updated
* mailbox/argp-parse.c: Updated
* mailbox/argp-pv.c: Updated
* mailbox/argp-pvh.c: Updated
* mailbox/argp-xinl.c: Updated
* mailbox/argp.h: Updated
* mailbox/asnprintf.c: Updated
* mailbox/getdelim.c: Added to the repository
* mailbox/getdelim.h: Added to the repository
* mailbox/getline.c: Updated
* mailbox/getline.h: Updated
* mailbox/getopt.c: Updated
* mailbox/getopt1.c: Updated
* mailbox/getopt_.h: Updated
* mailbox/getopt_int.h: Updated
* mailbox/gettext.h: Updated
* mailbox/mbchar.c: Added to the repository
* mailbox/mbchar.h: Added to the repository
* mailbox/md5.c: Updated
* mailbox/md5.h: Updated
* mailbox/memchr.c: Added to the repository
* mailbox/mempcpy.c: Updated
* mailbox/mempcpy.h: Updated
* mailbox/minmax.h: Updated
* mailbox/printf-args.c: Updated
* mailbox/printf-args.h: Updated
* mailbox/printf-parse.c: Updated
* mailbox/printf-parse.h: Updated
* mailbox/regcomp.c: Added to the repository
* mailbox/regex.c: Updated
* mailbox/regex.h: Updated
* mailbox/regex_internal.c: Added to the repository
* mailbox/regex_internal.h: Added to the repository
* mailbox/regexec.c: Added to the repository
* mailbox/size_max.h: Added to the repository
* mailbox/stdbool_.h: Added to the repository
* mailbox/strcase.h: Updated
* mailbox/strcasecmp.c: Updated
* mailbox/strchrnul.c: Updated
* mailbox/strchrnul.h: Updated
* mailbox/strncasecmp.c: Updated
* mailbox/strndup.c: Updated
* mailbox/strndup.h: Updated
* mailbox/strnlen.c: Updated
* mailbox/strnlen.h: Added to the repository
* mailbox/strnlen1.c: Added to the repository
* mailbox/strnlen1.h: Added to the repository
* mailbox/strtok_r.c: Updated
* mailbox/strtok_r.h: Updated
* mailbox/sysexit_.h: Updated
* mailbox/unlocked-io.h: Updated
* mailbox/vasnprintf.c: Updated
* mailbox/vasnprintf.h: Updated
* mailbox/vsnprintf.c: Updated
* mailbox/vsnprintf.h: Updated
* mailbox/xsize.h: Updated
End of gnulib update
* README-alpha,gnulib.modules,comsat/Makefile.am,
config/Makefile.am,config/mailutils-config.c,dotlock/Makefile.am,
examples/Makefile.am,frm/Makefile.am,guimb/Makefile.am,
imap4d/Makefile.am,lib/.cvsignore,lib/Makefile.am,
libsieve/extensions/Makefile.am,mail/Makefile.am,
mail.local/Makefile.am,mail.remote/Makefile.am,
mailbox/Makefile.am,mailbox/imap/folder.c,mapi/Makefile.am,
messages/Makefile.am,mh/Makefile.am,mimeview/Makefile.am,
movemail/Makefile.am,readmsg/Makefile.am,scripts/gnulib-sync,
sieve/Makefile.am: Rename libmailbox to libmailutils. Rename
the convenience library (lib/libmailutils) to libmuaux.
* auth/lbuf.h,comsat/comsat.c,examples/mta.c,guimb/guimb.h,
imap4d/auth_gsasl.c,imap4d/fetch.c,imap4d/imap4d.c,
imap4d/imap4d.h,imap4d/list.c,imap4d/namespace.c,imap4d/search.c,
imap4d/status.c,imap4d/util.c,include/mailutils/address.h,
include/mailutils/argcv.h,include/mailutils/argp.h,
include/mailutils/attribute.h,include/mailutils/auth.h,
include/mailutils/body.h,include/mailutils/daemon.h,
include/mailutils/debug.h,include/mailutils/envelope.h,
include/mailutils/error.h,include/mailutils/filter.h,
include/mailutils/folder.h,include/mailutils/gsasl.h,
include/mailutils/guile.h,include/mailutils/header.h,
include/mailutils/iterator.h,include/mailutils/libsieve.h,
include/mailutils/list.h,include/mailutils/locker.h,
include/mailutils/mailbox.h,include/mailutils/mailcap.h,
include/mailutils/mailer.h,include/mailutils/message.h,
include/mailutils/mime.h,include/mailutils/monitor.h,
include/mailutils/mu_auth.h,include/mailutils/mutil.h,
include/mailutils/nls.h,include/mailutils/observer.h,
include/mailutils/parse822.h,include/mailutils/property.h,
include/mailutils/refcount.h,include/mailutils/registrar.h,
include/mailutils/stream.h,include/mailutils/tls.h,
include/mailutils/types.h,include/mailutils/url.h,lib/md5.h,
lib/mu_asprintf.h,lib/mu_dbm.h,lib/strsignal.c,
libmu_scm/mu_address.c,libsieve/argp.c,libsieve/sieve.h,
libsieve/sieve.l,libsieve/sieve.y,mail/alias.c,mail/decode.c,
mail/folders.c,mail/mail.c,mail/mail.h,mail/mailline.c,
mail/msgset.y,mail/send.c,mail/util.c,mail.local/mail.local.h,
mail.local/main.c,mailbox/amd.c,mailbox/attribute.c,
mailbox/auth.c,mailbox/body.c,mailbox/debug.c,mailbox/envelope.c,
mailbox/filter.c,mailbox/filter_rfc822.c,mailbox/filter_trans.c,
mailbox/folder.c,mailbox/header.c,mailbox/locker.c,
mailbox/mailbox.c,mailbox/mailer.c,mailbox/message.c,
mailbox/mu_argp.c,mailbox/mu_auth.c,mailbox/observer.c,
mailbox/property.c,mailbox/registrar.c,mailbox/stream.c,
mailbox/ticket.c,mailbox/wicket.c,mailbox/imap/folder.c,
mailbox/imap/mbox.c,mailbox/include/amd.h,
mailbox/include/attribute0.h,mailbox/include/auth0.h,
mailbox/include/debug0.h,mailbox/include/envelope0.h,
mailbox/include/filter0.h,mailbox/include/folder0.h,
mailbox/include/header0.h,mailbox/include/imap0.h,
mailbox/include/list0.h,mailbox/include/mailbox0.h,
mailbox/include/mailer0.h,mailbox/include/message0.h,
mailbox/include/observer0.h,mailbox/include/registrar0.h,
mailbox/include/stream0.h,mailbox/include/url0.h,
mailbox/maildir/maildir.h,mailbox/mbox/folder.c,
mailbox/mbox/mbox.c,mailbox/mbox/mbox0.h,mailbox/nntp/folder.c,
mailbox/nntp/mbox.c,mailbox/nntp/nntp0.h,mh/fmtcheck.c,mh/mh.h,
mh/mh_alias.l,mh/mh_alias.y,mh/mh_format.c,mh/mh_getopt.h,
mh/mh_list.c,mh/mh_msgset.c,mh/mhn.c,mh/pick.h,mh/refile.c,
mh/scan.c,mh/sortm.c,readmsg/readmsg.c,readmsg/readmsg.h,
sieve/sieve.c,include/mailutils/errno.hin: Remove __P() and
__PMT() wrappers.
2005-08-15 Sergey Poznyakoff <gray@gnu.org.ua>
* mh/mhn.c (has_nonascii,finish_text_msg): New functions
(mhn_edit): Use quoted-printable encoding if the text contains
non-ascii characters.
2005-08-12 Sergey Poznyakoff <gray@gnu.org.ua>
* configure.ac: Add -lgnuradius to AUTHLIBS
* auth/radius.c (mu_radius_argp_parser): Only run init() if radius
auth is really required.
(mu_radius_authenticate,mu_auth_radius_user_by_name)
(mu_auth_radius_user_by_uid): Fail if the module was not
initialized
* mail/escape.c: Use strerror uniformly
* mailbox/argcv.c: Make handling of quotes consistent with shell
rules. In particular, single quotes need not be quoted, and are
not removed when appearing within a doubly-quoted string.
* mailbox/testsuite/Argcv: Adapt to the modified argcv.c
* auth/radius.c: New file. Radius authentication/authorization.
* auth/Makefile.am (libmuauth_la_SOURCES): Add radius.c. Sorted
sources alphabetically
* examples/config/mailutils.dict: New file.
* examples/config/Makefile.am (EXTRA_DIST): Add mailutils.dict.
Sorted files alphabetically
* NEWS: Updated
* configure.ac: Raised version number to 0.6.91.
Check for libgnuradius (new option --disable/--enable-radius)
At the end of configuration display the summary of enabled
features.
* include/mailutils/mu_auth.h (mu_auth_radius_module): New module
(MU_AUTH_REGISTER_ALL_MODULES): Register radius
* m4/enable.m4 (MU_ENABLE_SUPPORT): Fixed quoting error. Allow
action-if-true to disable the feature.
* mailbox/mu_argp.c (mu_conf_option): Reflect radius capability.
* po/POTFILES.in: Updated
2005-08-11 Sergey Poznyakoff <gray@gnu.org.ua>
* mail/var.c: Renamed to ...
* mail/escape.c: ... to fix a long-standing historical
inconsistency.
(var_shell,var_command,var_help,var_sign,var_bcc)
(var_cc,var_deadletter,var_editor,var_print,var_headers)
(var_insert,var_quote,var_type_input,var_read,var_subj)
(var_to,var_visual,var_write,var_exit,var_pipe): Renamed:
s/var_/escape_/. All callers updated
* mail/Makefile.am,mail/mail.h,mail/table.c: Likewise
* include/mailutils/argcv.h (argcv_get_n): New function
* mailbox/argcv.c: Likewise
* mail/alias.c (alias_iterate_first,alias_iterate_next)
(alias_iterate_end): New functions for readline completion
support.
* mail/cd.c (mail_cd): Check chdir return value
* mail/file.c (mail_expand_name): Do not proceed to opening the
mailbox if failed to get its name
* mail/help.c (mail_help): Use mail_command_help()
* mail/list.c (mail_list): Use mail_command_list()
* mail/mail.h (mail_command_entry): Rewritten
(mail_escape_entry,struct mail_command): New data type
(mail_command_table,mail_escape_table): Variables removed
(util_find_entry): Change prototype
(util_help,util_command_list)
(mail_find_command,mail_find_escape,mail_command_help)
(mail_escape_help,mail_command_list): New functions
(util_help): Removed
(alias_iterate_first,alias_iterate_next,alias_iterate_end)
(var_iterate_first,var_iterate_next,var_iterate_end): New functions
(file_compl,no_compl,msglist_compl,msglist_file_compl,dir_compl
(command_compl,alias_compl,var_compl): New functions for readline
completion support
* mail/mailline.c (file_compl,no_compl,msglist_compl)
(msglist_file_compl,dir_compl)
(command_compl,alias_compl,var_compl): New functions for readline
completion support
* mail/send.c: Use mail_find_escape()
* mail/table.c (mail_command_table,mail_escape_table): Changed
data type
(mail_find_command,mail_command_help,mail_command_list)
(mail_command_name,mail_find_escape,mail_escape_help): New
functions
* mail/util.c: Rewritten mail variables support using list_t.
(util_find_entry,util_help): Rewritten to work with opaque data
tables
(util_command_list): New function
(var_iterate_first,var_iterate_next,var_iterate_end): New
functions
(util_folder_path): Convert folder to full name
* mail/var.c: Use mail_find_command() and mail_escape_help().
* mailbox/mbox/folder.c (get_pathname): Make sure no extra slash
is inserted.
* mailbox/list.c (list_to_array): Bugfix. The counter was not
incremented.
* po/POTFILES.in: Add mail/cd.c
2005-08-10 Sergey Poznyakoff <gray@gnu.org.ua>
* doc/rfc/rfc3501.txt: New file
* doc/rfc/Makefile.am: Add rfc3501.txt
* imap4d/copy.c (imap4d_copy0): Minor improvement
* imap4d/fetch.c (imap4d_fetch0): Ignore non-existing uids instead
of diagnosing an error. This complies to RFC 3501.
* imap4d/util.c (util_msgset): For message sets in form X:Y where
Y is a not-existing UID greater than maximum UID value in the
mailbox, replace Y with the latter.
* imap4d/testsuite/imap4d/IDEF0955.exp: Synchronize with the
recent changes.
2005-07-26 Sergey Poznyakoff <gray@gnu.org.ua>
* NEWS: Updated
* examples/mimetest.c: Produce more detailed diagnostics
* mail/copy.c: Likewise
* mail/quit.c: Likewise
* mail/send.c: Likewise
* mail/page.c (cond_page_invalidate): Bugfix
* mailbox/errors (MU_READ_ERROR): New error code
* include/mailutils/folder.h: Moved MU_FOLDER_ATTRIBUTE_.* to
types.h
* include/mailutils/types.h (MU_FOLDER_ATTRIBUTE_FILE)
(MU_FOLDER_ATTRIBUTE_DIRECTORY): New defines
* include/mailutils/registrar.h (_is_scheme, registrar_lookup):
Take three arguments. All callers updated
Raised path_record priority to 1000.
* mailbox/registrar.c: Likewise
* mailbox/folder.c: Updated calls to registrar_lookup and
declarations of _is_scheme methods
* mailbox/mailer.c: Likewise
* mailbox/maildir/folder.c: Likewise
* mailbox/mbox/folder.c: Likewise
* mailbox/mh/folder.c: Likewise
* mailbox/list.c (_insert_item): Bugfix
* mailbox/testsuite/mailbox/list.exp: New tests
* mailbox/mailbox.c (mailbox_folder_create): New function
(mailbox_create): Use mailbox_folder_create.
* mailbox/rfc2047.c (rfc2047_encode): Bugfix.
* mail/page.c (page_move): Fix start msg calculation
* include/mailutils/list.h (list_insert): Accept additional
argument indicating whether to insert item before or after the
reference one.
* mailbox/list.c: Likewise
* examples/listop.c (ins): New option 'before' allows to insert an
item before another one.
* mailbox/testsuite/mailbox/list.exp: Test new list operations.
* mh/mh_alias.y: Updated list_insert invocations
* mh/mh_format.c (builtin_putnum): Minor fix
* comsat/comsat.c: Use registrar_record instead of directly
accessing registrar list.
* examples/mimetest.c: Likewise
* examples/msg-send.c: Likewise
* examples/mta.c: Likewise
* libmu_scm/mu_scm.c: Likewise
* mail.local/main.c: Likewise
* mail.remote/mail.remote.c: Likewise
* mailbox/registrar.c (registrar_get_list): Split into two
calls. The registrar_get_list proper is deprecated.
(registrar_get_iterator,registrar_lookup): New functions
(registrar_record,unregistrar_record): Use _registrar_get_list
* mailbox/folder.c (folder_create): Rewritten using
registrar_lookup()
* mailbox/mailbox.c (mailbox_create): Likewise
* mailbox/mailer.c (mailer_create): Likewise
* mailbox/sendmail.c: Updated declarations of struct _record
objects.
* mailbox/smtp.c: Likewise
* mailbox/imap/folder.c: Likewise
* mailbox/maildir/folder.c: Likewise
* mailbox/mbox/folder.c: Likewise
* mailbox/mh/folder.c: Likewise
* mailbox/nntp/folder.c: Likewise
* mailbox/pop/folder.c: Likewise
* include/mailutils/registrar.h (struct _record.priority): New
member.
(registrar_get_list): Mark as deprecated
(registrar_get_iterator,registrar_lookup): New function
(MU_IMAP_PRIO etc): New defines
(mu_register_all_mbox_formats,mu_register_local_mbox_formats)
(mu_register_remote_mbox_formats,mu_register_all_mailer_formats)
(mu_register_extra_formats): Use registrar_record
* include/mailutils/types.h: Minor stylistic fix
2005-07-25 Sergey Poznyakoff <gray@gnu.org.ua>
* mailbox/locker.c (locker_lock): Allow for non-absolute file
names.
2005-07-10 Sergey Poznyakoff <gray@gnu.org.ua>
* libsieve/extensions/vacation.c: Unconditionally include mu_dbm.h
* mailbox/mutil.c (mu_get_homedir): Use EUID to determine user
identity.
2005-07-08 Sergey Poznyakoff <gray@Mirddin.farlep.net>
* mailbox/mime.c (_mime_get_param): Initialize was_quoted to
0. Problem reported by Shashank Kavishwar <s_kavishwar@hotmail.com>.
2005-07-07 Sergey Poznyakoff <gray@Mirddin.farlep.net>
* libsieve/actions.c: Fall back to "Sender:" and "From:" headers
(in that order), if the envelope sender is not available.
2005-06-29 Sergey Poznyakoff <gray@Mirddin.farlep.net>
* mailbox/argcv.c (argcv_scan): Improved scanning.
* mailbox/testsuite/Argcv: New tests
* mailbox/argcv.c (argcv_scan,argcv_quoted_length)
(argcv_quote_copy): Fixed handling of unmatched quotes.
2005-06-27 Sergey Poznyakoff <gray@Mirddin.farlep.net>
* include/mailutils/argcv.h (argcv_unescape_char): Renamed to
argcv_unquote_char
(argcv_escape_char): Renamed to argcv_quote_char.
(argcv_quoted_length,argcv_quote_copy): New functions
* mailbox/argcv.c (argcv_scan,xtonum): Improved parser
(argcv_unescape_char): Renamed to
argcv_unquote_char
(argcv_escape_char): Renamed to argcv_quote_char.
(argcv_quoted_length,argcv_quote_copy): New functions
(argcv_unquote_copy): (ex. unescape_copy): Fixed handling of
escaped sequences.
(argcv_get,argcv_free,argcv_string): Standardized return value.
* comsat/action.c: argcv_unescape_char renamed to argcv_unquote_char
* libsieve/sieve.l: Likewise
* examples/argcv.c: New file
* examples/Makefile.am: Add argcv.c
* mailbox/testsuite/Argcv: New file
* mailbox/testsuite/mailbox/argcv.exp: New test
* mailbox/testsuite/mailbox/DISTFILES: Add argcv.exp
2005-06-23 Sergey Poznyakoff <gray@Mirddin.farlep.net>
* NEWS: Updated
* README-alpha: Updated
* include/mailutils/mailbox.h
(mu_path_maildir,mu_path_folder_dir): Removed
(mu_set_mail_directory,mu_set_folder_directory)
(mu_mail_directory,mu_folder_directory)
(mu_construct_user_mailbox_url,mailbox_get_flags): New functions.
* mailbox/mbx_default.c: Likewise.
* include/mailutils/mutil.h (mu_normalize_maildir): Renamed to
(mu_normalize_mailbox_url)
* libmu_scm/mu_mailbox.c (scm_mu_mail_directory)
(scm_mu_folder_directory): New function
* libmu_scm/mu_scm.c (_mu_scm_path_maildir)
(_mu_scm_path_folder_dir): Removed
* auth/sql.c: Use mu_mail_directory, mu_folder_directory and
related calls.
* guimb/collect.c: Likewise.
* mailbox/mu_argp.c: Likewise.
* mailbox/mutil.c: Likewise.
* mailbox/system.c: Likewise.
* mh/comp.c: Likewise.
* mh/folder.c: Likewise.
* mh/forw.c: Likewise.
* mh/mh_init.c: Likewise.
* mh/mhn.c: Likewise.
* mh/mhpath.c: Likewise.
* mh/refile.c: Likewise.
* mh/repl.c: Likewise.
* mh/send.c: Likewise.
* mh/whom.c: Likewise.
* mh/mh.h (mh_global_profile_get): Changed prototype.
* mh/mh_global.c: Likewise.
* mailbox/imap/mbox.c (imap_messages_count): Use SELECT or EXAMINE
depending on the mailbox status.
(imap_expunge): Return EACCES if the mailbox is read-only
* examples/http.c: Accept up to two arguments: hostname to connect
to and URL of the page to get.
* imap4d/close.c: Do not attempt to flush a mailbox opened in
read-only mode.
* mail/file.c (mail_file): Invalidate current page map.
* mail/mail.h: Updated
* mail/page.c (set_cursor): Use page_move(0) to correctly update
the map.
* mailbox/errors (MU_ERR_BAD_FILENAME): New error code.
* mailbox/mailbox.c (mailbox_get_flags): New function
* imap4d/util.c: Minor correction
* mail/decode.c: Likewise
* mail.local/main.c: Likewise
* frm/from.c: Removed unused variable
2005-06-15 Sergey Poznyakoff <gray@Mirddin.farlep.net>
* examples/mta.c (mta_smtp): Fixed race condition between printing
the port number, which will be used by the testsuite, and actually
starting to listen on that port.
* mail/page.c: New file. Implements an abstract output page.
* mail/Makefile.am (mail_SOURCES): Add page.c. Alphabetized
sources.
* mail/delete.c, mail/edit.c, mail/eq.c, mail/file.c,
mail/followup.c, mail/from.c, mail/headers.c, mail/hold.c,
mail/mail.c, mail/mailline.c, mail/mbox.c, mail/msgset.y,
mail/next.c, mail/previous.c, mail/print.c, mail/reply.c,
mail/size.c, mail/summary.c, mail/top.c, mail/touch.c,
mail/undelete.c, mail/util.c, mail/visual.c, mail/write.c,
mail/z.c: Use new pager functions.
* mail/mail.h: New declarations
* mail/testsuite/mail/z.exp: Fixed tests to match our improved
output.
2005-06-13 Sergey Poznyakoff <gray@Mirddin.farlep.net>
* mailbox/amd.c (amd_expunge): Unlink the message file if
msg_file_name returns NULL.
* mailbox/maildir/mbox.c (maildir_message_name): Return NULL for
deleted messages.
* mailbox/include/stream0.h (struct rbuffer.count): Changed type
to size_t. Reported by Joseph Caputo <caputo@qedinfo.com>
* mailbox/stream.c (refill): Removed useless typecast
* mail/util.c (util_save_outgoing): Rewritten using mailbox
functions. `set record' can now point to any valid mailbox type.
2005-06-12 Sergey Poznyakoff <gray@Mirddin.farlep.net>
* frm/common.c (get_charset): Make sure output_charset is not NULL.
2005-06-06 Sergey Poznyakoff <gray@Mirddin.farlep.net>
* mailbox/amd.c (amd_envelope_date): Always convert date to ctime
format.
2005-05-31 Sergey Poznyakoff <gray@Mirddin.farlep.net>
* mailbox/maildir/mbox.c (maildir_uniq): Fix memory overwrite.
2005-05-27 Sergey Poznyakoff <gray@Mirddin.farlep.net>
* mailbox/amd.c (amd_envelope_date): Reformat Delivery-Date value
to standard ctime format. Fix memory leak.
(amd_envelope_sender): Propagate return from header_aget_value()
back to the caller.
* mailbox/mbox/mbox.c (restore_sender,restore_date): New
functions.
(mbox_append_message0): Use above functions to create sender/date
values if these are not supplied.
* movemail/movemail.c (move_message): Fix error diagnostics format.
2005-05-24 Sergey Poznyakoff <gray@Mirddin.farlep.net>
* examples/Makefile.am (noinst_PROGRAMS): Add encode2047. Sorted
alphabetically.
* examples/encode2047.c: New file.
* examples/base64.c (main): Add option -E (encoding). The program
can now be used to test any encoder/decoder filters, so its name
is kind of misnomer.
* mailbox/errors (MU_ERR_BAD_2047_ENCODING): New error code.
* mailbox/filter_trans.c (qp_encode): Do not keep track of the
whitespace. Proposed by Amit Jhawar <ajhawar@frontbridge.com>.
(Q_printable_char_p): TAB is not a printable char.
(Q_encode): Bugfix: 0x20 is represented by underscore, not vice
versa.
* mailbox/rfc2047.c (rfc2047_encode): Bugfix. Use proper encoding
types. Convert "base64" to "B" and "quoted-printable" to
"Q". Check return values from stream creation functions. Do not
destroy input_stream if output_stream was destroyed (prevents
coredump).
* scripts/config.rpath: Removed automatically generated file.
* THANKS: Added Kidong Lee and Amit Jhawar.
* examples/.cvsignore: Add encode2047. Sort entries.
2005-05-23 Kidong Lee <briankdlee@yahoo.com>
* mailbox/rfc2047.c (rfc2047_encode): Rewritten using filters
and streams.
2005-05-23 Sergey Poznyakoff <gray@Mirddin.farlep.net>
* mailbox/mutil.c: include <sys/select.h>
* lib/mailcap.c: Provide a replacement for FNM_CASEFOLD
Reported by Jerry Heyman <heymanj@acm.org>.
* configure.ac: Compute the value of ULONG_MAX for use in the
testsute.
* imap4d/testsuite/Makefile.am (site.exp): Set MU_ULONG_MAX
* imap4d/testsuite/imap4d/IDEF0955.exp: Compute upper limit for
the message set spec based on the value of MU_ULONG_MAX.
* imap4d/testsuite/imap4d/IDEF0956.exp: Likewise
2005-05-20 Sergey Poznyakoff <gray@Mirddin.farlep.net>
* imap4d/fetch.c (fetch_getcommand): Changed proto to make gcc 4.0
happy.
2005-05-19 Sergey Poznyakoff <gray@Mirddin.farlep.net>
* auth/sql.c (sql_escape_string): Escape backslashes.
The sources before this point are tagged alpha_0_6_90.
2005-05-17 Sergey Poznyakoff <gray@Mirddin.farlep.net>
* configure.ac: Updated FSF address. Raised version number to
0.6.90
Updated FSF address:
* COPYING, COPYING.LESSER, Makefile.am, NEWS,
auth/Makefile.am, auth/gsasl.c, auth/lbuf.c, auth/lbuf.h,
auth/pam.c, auth/sql.c, auth/sql.h, auth/tls.c,
auth/virtual.c, comsat/Makefile.am, comsat/action.c,
comsat/cfg.c, comsat/comsat.c, comsat/comsat.h,
config/Makefile.am, config/mailutils-config.c,
doc/Makefile.am, doc/man/Makefile.am, doc/rfc/Makefile.am,
doc/texinfo/COPYING.DOC, doc/texinfo/Makefile.am,
doc/texinfo/fdl.texi, doc/texinfo/mailutils.texi,
doc/texinfo/muint.texi, dotlock/Makefile.am,
dotlock/dotlock.c, examples/Makefile.am, examples/addr.c,
examples/base64.c, examples/decode2047.c, examples/http.c,
examples/iconv.c, examples/listop.c, examples/mailcap.c,
examples/mimetest.c, examples/msg-send.c,
examples/mta.c, examples/muemail.c, examples/murun.c,
examples/nntpclient.c, examples/numaddr.c,
examples/pop3client.c, examples/sfrom.c,
examples/url-parse.c, examples/config/Makefile.am,
examples/cpp/Makefile.am, examples/scheme/Makefile.am,
examples/scheme/reply.scm, frm/Makefile.am,
frm/common.c, frm/frm.c, frm/frm.h, frm/from.c,
frm/testsuite/Makefile.am, frm/testsuite/frm/test.exp,
guimb/Makefile.am, guimb/collect.c, guimb/guimb.h,
guimb/main.c, guimb/util.c, guimb/scm/Makefile.am,
guimb/scm/mimeheader.scm, guimb/scm/numaddr.scm,
guimb/scm/redirect.scm, guimb/scm/reject.scm,
guimb/scm/sieve-core.scm, guimb/scm/sieve.scm.in,
guimb/scm/vacation.scm, imap4d/Makefile.am,
imap4d/append.c, imap4d/auth_gsasl.c, imap4d/auth_gss.c,
imap4d/authenticate.c, imap4d/bye.c, imap4d/capability.c,
imap4d/check.c, imap4d/close.c, imap4d/commands.c,
imap4d/copy.c, imap4d/create.c, imap4d/delete.c,
imap4d/examine.c, imap4d/expunge.c, imap4d/fetch.c,
imap4d/idle.c, imap4d/imap4d.c, imap4d/imap4d.h,
imap4d/list.c, imap4d/login.c, imap4d/logout.c,
imap4d/lsub.c, imap4d/namespace.c, imap4d/noop.c,
imap4d/rename.c, imap4d/search.c, imap4d/select.c,
imap4d/signal.c, imap4d/starttls.c, imap4d/status.c,
imap4d/store.c, imap4d/subscribe.c, imap4d/sync.c,
imap4d/uid.c, imap4d/unsubscribe.c, imap4d/util.c,
imap4d/version.c, imap4d/testsuite/Makefile.am,
imap4d/testsuite/imap4d/IDEF0955.exp,
imap4d/testsuite/imap4d/IDEF0956.exp,
imap4d/testsuite/imap4d/anystate.exp,
imap4d/testsuite/imap4d/append.exp,
imap4d/testsuite/imap4d/create.exp,
imap4d/testsuite/imap4d/examine.exp,
imap4d/testsuite/imap4d/expunge.exp,
imap4d/testsuite/imap4d/fetch.exp,
imap4d/testsuite/imap4d/list.exp,
imap4d/testsuite/imap4d/search.exp,
imap4d/testsuite/imap4d/x.exp,
imap4d/testsuite/lib/imap4d.exp,
include/Makefile.am, include/mailutils/Makefile.am,
include/mailutils/address.h, include/mailutils/argcv.h,
include/mailutils/argp.h, include/mailutils/attribute.h,
include/mailutils/auth.h, include/mailutils/body.h,
include/mailutils/daemon.h, include/mailutils/debug.h,
include/mailutils/envelope.h, include/mailutils/errno.hin,
include/mailutils/error.h, include/mailutils/filter.h,
include/mailutils/folder.h, include/mailutils/gsasl.h,
include/mailutils/guile.h, include/mailutils/header.h,
include/mailutils/iterator.h, include/mailutils/libsieve.h,
include/mailutils/list.h, include/mailutils/locker.h,
include/mailutils/mailbox.h, include/mailutils/mailcap.h,
include/mailutils/mailer.h, include/mailutils/mailutils.h,
include/mailutils/message.h, include/mailutils/mime.h,
include/mailutils/monitor.h, include/mailutils/mu_auth.h,
include/mailutils/mutil.h, include/mailutils/nls.h,
include/mailutils/nntp.h, include/mailutils/observer.h,
include/mailutils/parse822.h, include/mailutils/pop3.h,
include/mailutils/property.h, include/mailutils/refcount.h,
include/mailutils/registrar.h, include/mailutils/sql.h,
include/mailutils/stream.h, include/mailutils/tls.h,
include/mailutils/types.h, include/mailutils/url.h,
include/mailutils/gnu/Makefile.am,
include/mailutils/sys/Makefile.am,
include/mailutils/sys/nntp.h, include/mailutils/sys/pop3.h,
lib/Makefile.am, lib/allocsa.c, lib/allocsa.h,
lib/asprintf.c, lib/daemon.c, lib/error.c, lib/error.h,
lib/exit.h, lib/exitfail.c, lib/exitfail.h,
lib/fnmatch_.h, lib/fnmatch_loop.c, lib/getpass.c,
lib/getpass.h, lib/mailcap.c, lib/malloc.c,
lib/mbswidth.c, lib/mbswidth.h, lib/mu_asprintf.h,
lib/mu_dbm.c, lib/mu_dbm.h, lib/obstack.c, lib/obstack.h,
lib/realloc.c, lib/setenv.c, lib/setenv.h, lib/snprintf.c,
lib/snprintf.h, lib/stdbool_.h, lib/unsetenv.c, lib/utmp.c,
lib/vasprintf.c, lib/vasprintf.h, lib/xalloc.h,
lib/xalloc_die.c, lib/xmalloc.c, lib/xsize.h,
lib/xstrtol.c, lib/xstrtol.h, libmu_scm/Makefile.am,
libmu_scm/mailutils.scm.in, libmu_scm/mu_address.c,
libmu_scm/mu_body.c, libmu_scm/mu_guimb.c,
libmu_scm/mu_logger.c, libmu_scm/mu_mailbox.c,
libmu_scm/mu_message.c, libmu_scm/mu_mime.c,
libmu_scm/mu_port.c, libmu_scm/mu_scm.c,
libmu_scm/mu_scm.h, libmu_scm/mu_util.c,
libsieve/Makefile.am, libsieve/actions.c, libsieve/argp.c,
libsieve/comparator.c, libsieve/load.c, libsieve/prog.c,
libsieve/register.c, libsieve/relational.c,
libsieve/require.c, libsieve/runtime.c, libsieve/sieve.h,
libsieve/sieve.l, libsieve/sieve.y, libsieve/tests.c,
libsieve/util.c, libsieve/extensions/Makefile.am,
libsieve/extensions/list.c, libsieve/extensions/spamd.c,
libsieve/extensions/timestamp.c,
libsieve/extensions/vacation.c, m4/db2.m4, m4/enable.m4,
m4/gnulib.m4, m4/gsasl.m4, m4/guile.m4, m4/mu_libobj.m4,
m4/tls.m4, mail/Makefile.am, mail/alias.c,
mail/alt.c, mail/cd.c, mail/copy.c, mail/decode.c,
mail/delete.c, mail/dp.c, mail/echo.c, mail/edit.c,
mail/eq.c, mail/exit.c, mail/file.c, mail/folders.c,
mail/followup.c, mail/from.c, mail/headers.c, mail/help.c,
mail/hold.c, mail/if.c, mail/inc.c, mail/list.c,
mail/mail.c, mail/mail.h, mail/mailline.c, mail/mbox.c,
mail/msgset.y, mail/next.c, mail/pipe.c, mail/previous.c,
mail/print.c, mail/quit.c, mail/reply.c, mail/retain.c,
mail/save.c, mail/send.c, mail/set.c, mail/setenv.c,
mail/shell.c, mail/size.c, mail/source.c, mail/summary.c,
mail/table.c, mail/tag.c, mail/top.c, mail/touch.c,
mail/unalias.c, mail/undelete.c, mail/unset.c,
mail/util.c, mail/var.c, mail/version.c, mail/visual.c,
mail/write.c, mail/z.c, mail/testsuite/Makefile.am,
mail/testsuite/lib/mail.exp, mail/testsuite/mail/alias.exp,
mail/testsuite/mail/folder.exp,
mail/testsuite/mail/read.exp, mail/testsuite/mail/send.exp,
mail/testsuite/mail/tag.exp, mail/testsuite/mail/write.exp,
mail/testsuite/mail/z.exp, mail.local/Makefile.am,
mail.local/mail.local.h, mail.local/mailquota.c,
mail.local/main.c, mail.local/script.c,
mail.local/testsuite/Data,
mail.local/testsuite/Makefile.am,
mail.local/testsuite/lib/mail.local.exp,
mail.local/testsuite/mail.local/deliver.exp,
mail.remote/Makefile.am, mail.remote/mail.remote.c,
mail.remote/testsuite/Data,
mail.remote/testsuite/Makefile.am,
mail.remote/testsuite/lib/mail.remote.exp,
mail.remote/testsuite/mail.remote/send.exp,
mailbox/Makefile.am, mailbox/address.c, mailbox/alloca_.h,
mailbox/amd.c, mailbox/argcv.c, mailbox/argp-ba.c,
mailbox/argp-eexst.c, mailbox/argp-fmtstream.c,
mailbox/argp-fmtstream.h, mailbox/argp-fs-xinl.c,
mailbox/argp-help.c, mailbox/argp-namefrob.h,
mailbox/argp-parse.c, mailbox/argp-pv.c,
mailbox/argp-pvh.c, mailbox/argp-xinl.c, mailbox/argp.h,
mailbox/asnprintf.c, mailbox/attachment.c,
mailbox/attribute.c, mailbox/auth.c, mailbox/body.c,
mailbox/daemon.c, mailbox/date.c, mailbox/debug.c,
mailbox/envelope.c, mailbox/errors, mailbox/fgetpwent.c,
mailbox/file_stream.c, mailbox/filter.c,
mailbox/filter_iconv.c, mailbox/filter_rfc822.c,
mailbox/filter_trans.c, mailbox/folder.c,
mailbox/getline.c, mailbox/getline.h, mailbox/getndelim2.c,
mailbox/getndelim2.h, mailbox/getopt.c,
mailbox/getopt1.c, mailbox/getopt_.h, mailbox/getopt_int.h,
mailbox/gettext.h, mailbox/header.c, mailbox/iterator.c,
mailbox/list.c, mailbox/locale.c, mailbox/locker.c,
mailbox/mailbox.c, mailbox/mailcap.c, mailbox/mailer.c,
mailbox/mapfile_stream.c, mailbox/mbx_default.c,
mailbox/md5.c, mailbox/md5.h, mailbox/memory_stream.c,
mailbox/mempcpy.c, mailbox/mempcpy.h, mailbox/message.c,
mailbox/mime.c, mailbox/minmax.h, mailbox/monitor.c,
mailbox/mu_argp.c, mailbox/mu_auth.c, mailbox/muerrno.cin,
mailbox/muerror.c, mailbox/munre.c, mailbox/mutil.c,
mailbox/nls.c, mailbox/observer.c, mailbox/parse822.c,
mailbox/parsedate.y, mailbox/printf-args.c,
mailbox/printf-args.h, mailbox/printf-parse.c,
mailbox/printf-parse.h, mailbox/property.c,
mailbox/regex.c, mailbox/regex.h, mailbox/registrar.c,
mailbox/rfc2047.c, mailbox/sendmail.c, mailbox/smtp.c,
mailbox/strcase.h, mailbox/strcasecmp.c,
mailbox/strchrnul.c, mailbox/strchrnul.h,
mailbox/stream.c, mailbox/strndup.c, mailbox/strndup.h,
mailbox/strnlen.c, mailbox/strtok_r.c, mailbox/strtok_r.h,
mailbox/sysexit_.h, mailbox/system.c, mailbox/tcp.c,
mailbox/ticket.c, mailbox/unlocked-io.h, mailbox/url.c,
mailbox/url_sendmail.c, mailbox/url_smtp.c,
mailbox/vasnprintf.c, mailbox/vasnprintf.h,
mailbox/vsnprintf.c, mailbox/vsnprintf.h, mailbox/wicket.c,
mailbox/xsize.h, mailbox/imap/Makefile.am,
mailbox/imap/folder.c, mailbox/imap/mbox.c,
mailbox/imap/url.c, mailbox/include/Makefile.am,
mailbox/include/address0.h, mailbox/include/amd.h,
mailbox/include/attribute0.h, mailbox/include/auth0.h,
mailbox/include/body0.h, mailbox/include/debug0.h,
mailbox/include/envelope0.h, mailbox/include/filter0.h,
mailbox/include/folder0.h, mailbox/include/header0.h,
mailbox/include/imap0.h, mailbox/include/iterator0.h,
mailbox/include/list0.h, mailbox/include/mailbox0.h,
mailbox/include/mailer0.h, mailbox/include/message0.h,
mailbox/include/mime0.h, mailbox/include/monitor0.h,
mailbox/include/observer0.h, mailbox/include/property0.h,
mailbox/include/registrar0.h, mailbox/include/stream0.h,
mailbox/include/url0.h, mailbox/maildir/Makefile.am,
mailbox/maildir/folder.c, mailbox/maildir/maildir.h,
mailbox/maildir/mbox.c, mailbox/mbox/Makefile.am,
mailbox/mbox/folder.c, mailbox/mbox/mbox.c,
mailbox/mbox/mbox0.h, mailbox/mbox/mboxscan.c,
mailbox/mbox/url.c, mailbox/mh/Makefile.am,
mailbox/mh/folder.c, mailbox/mh/mbox.c,
mailbox/nntp/Makefile.am, mailbox/nntp/folder.c,
mailbox/nntp/mbox.c, mailbox/nntp/nntp0.h,
mailbox/nntp/nntp_article.c, mailbox/nntp/nntp_body.c,
mailbox/nntp/nntp_carrier.c, mailbox/nntp/nntp_connect.c,
mailbox/nntp/nntp_create.c, mailbox/nntp/nntp_date.c,
mailbox/nntp/nntp_debug.c, mailbox/nntp/nntp_destroy.c,
mailbox/nntp/nntp_disconnect.c, mailbox/nntp/nntp_group.c,
mailbox/nntp/nntp_head.c, mailbox/nntp/nntp_help.c,
mailbox/nntp/nntp_ihave.c, mailbox/nntp/nntp_last.c,
mailbox/nntp/nntp_list_active.c,
mailbox/nntp/nntp_list_distribpats.c,
mailbox/nntp/nntp_list_distributions.c,
mailbox/nntp/nntp_list_extensions.c,
mailbox/nntp/nntp_list_newsgroups.c,
mailbox/nntp/nntp_list_times.c,
mailbox/nntp/nntp_mode_reader.c,
mailbox/nntp/nntp_newgroups.c, mailbox/nntp/nntp_newnews.c,
mailbox/nntp/nntp_next.c, mailbox/nntp/nntp_post.c,
mailbox/nntp/nntp_quit.c, mailbox/nntp/nntp_readline.c,
mailbox/nntp/nntp_response.c, mailbox/nntp/nntp_sendline.c,
mailbox/nntp/nntp_stat.c, mailbox/nntp/nntp_stream.c,
mailbox/nntp/nntp_timeout.c, mailbox/nntp/url.c,
mailbox/pop/Makefile.am, mailbox/pop/folder.c,
mailbox/pop/mbox.c, mailbox/pop/pop3_apop.c,
mailbox/pop/pop3_capa.c, mailbox/pop/pop3_carrier.c,
mailbox/pop/pop3_connect.c, mailbox/pop/pop3_create.c,
mailbox/pop/pop3_debug.c, mailbox/pop/pop3_dele.c,
mailbox/pop/pop3_destroy.c, mailbox/pop/pop3_disconnect.c,
mailbox/pop/pop3_list.c, mailbox/pop/pop3_lista.c,
mailbox/pop/pop3_noop.c, mailbox/pop/pop3_pass.c,
mailbox/pop/pop3_quit.c, mailbox/pop/pop3_readline.c,
mailbox/pop/pop3_response.c, mailbox/pop/pop3_retr.c,
mailbox/pop/pop3_rset.c, mailbox/pop/pop3_sendline.c,
mailbox/pop/pop3_stat.c, mailbox/pop/pop3_stls.c,
mailbox/pop/pop3_stream.c, mailbox/pop/pop3_timeout.c,
mailbox/pop/pop3_top.c, mailbox/pop/pop3_uidl.c,
mailbox/pop/pop3_uidla.c, mailbox/pop/pop3_user.c,
mailbox/pop/url.c, mailbox/testsuite/Addrs,
mailbox/testsuite/Mailcap, mailbox/testsuite/Makefile.am,
mailbox/testsuite/Mime, mailbox/testsuite/RFC2047,
mailbox/testsuite/Urls, mailbox/testsuite/lib/mailbox.exp,
mailbox/testsuite/mailbox/address.exp,
mailbox/testsuite/mailbox/base64.exp,
mailbox/testsuite/mailbox/list.exp,
mailbox/testsuite/mailbox/mailcap.exp,
mailbox/testsuite/mailbox/mime.exp,
mailbox/testsuite/mailbox/rfc2047.exp,
mailbox/testsuite/mailbox/url.exp, messages/Makefile.am,
messages/messages.c, messages/testsuite/Makefile.am,
messages/testsuite/messages/test.exp, mh/Makefile.am,
mh/ali.c, mh/anno.c, mh/comp.c, mh/compcommon.c,
mh/fmtcheck.c, mh/folder.c, mh/forw.c, mh/inc.c,
mh/install-mh.c, mh/mailutils-mh.eli, mh/mark.c, mh/mh.h,
mh/mh_alias.l, mh/mh_alias.y, mh/mh_argp.c, mh/mh_ctx.c,
mh/mh_error.c, mh/mh_fmtgram.y, mh/mh_format.c,
mh/mh_getopt.c, mh/mh_getopt.h, mh/mh_global.c,
mh/mh_init.c, mh/mh_list.c, mh/mh_msgset.c,
mh/mh_sequence.c, mh/mh_stream.c, mh/mh_whatnow.c,
mh/mh_whom.c, mh/mhl.c, mh/mhn.c, mh/mhparam.c,
mh/mhpath.c, mh/pick.c, mh/pick.h, mh/pick.y, mh/refile.c,
mh/repl.c, mh/rmf.c, mh/rmm.c, mh/scan.c, mh/send.c,
mh/sortm.c, mh/whatnow.c, mh/whom.c, mimeview/Makefile.am,
mimeview/mimetypes.l, mimeview/mimetypes.y,
mimeview/mimeview.c, mimeview/mimeview.h,
movemail/Makefile.am, movemail/movemail.c,
po/.cvsignore, po/ca.po, po/es.po, po/fr.po, po/pl.po,
po/ro.po, po/ru.po, po/uk.po, pop3d/Makefile.am,
pop3d/apop.c, pop3d/auth.c, pop3d/capa.c, pop3d/dele.c,
pop3d/expire.c, pop3d/extra.c, pop3d/list.c, pop3d/lock.c,
pop3d/logindelay.c, pop3d/noop.c, pop3d/pop3d.c,
pop3d/pop3d.h, pop3d/popauth.c, pop3d/quit.c,
pop3d/retr.c, pop3d/rset.c, pop3d/signal.c, pop3d/stat.c,
pop3d/stls.c, pop3d/top.c, pop3d/uidl.c, pop3d/user.c,
pop3d/testsuite/Makefile.am, pop3d/testsuite/lib/pop3d.exp,
pop3d/testsuite/pop3d/read.exp, readmsg/Makefile.am,
readmsg/msglist.c, readmsg/readmsg.c,
readmsg/readmsg.h, readmsg/testsuite/Makefile.am,
readmsg/testsuite/readmsg/test.exp,
scripts/Makefile.am, scripts/config.rpath,
scripts/generr.awk, scripts/texify.sed,
scripts/ylwrap, scripts/guile-1.4/Makefile.am,
scripts/guile-1.4/guile-doc-snarf,
scripts/guile-1.4/guile-func-name-check,
scripts/guile-1.4/guile-snarf.awk,
scripts/guile-1.6/Makefile.am,
scripts/guile-1.6/guile-doc-snarf,
scripts/guile-1.6/guile-doc-snarf.awk, sieve/Makefile.am,
sieve/sieve.c, sieve/testsuite/Makefile.am,
sieve/testsuite/Redirect, sieve/testsuite/Reject,
sieve/testsuite/lib/sieve.exp,
sieve/testsuite/sieve/action.exp,
sieve/testsuite/sieve/address.exp,
sieve/testsuite/sieve/allof.exp,
sieve/testsuite/sieve/anyof.exp,
sieve/testsuite/sieve/envelope.exp,
sieve/testsuite/sieve/exists.exp,
sieve/testsuite/sieve/ext.exp,
sieve/testsuite/sieve/false.exp,
sieve/testsuite/sieve/header.exp,
sieve/testsuite/sieve/i-casemap.exp,
sieve/testsuite/sieve/i-numeric.exp,
sieve/testsuite/sieve/i-octet.exp,
sieve/testsuite/sieve/mul-addr.exp,
sieve/testsuite/sieve/not.exp,
sieve/testsuite/sieve/redirect.exp,
sieve/testsuite/sieve/reject.exp,
sieve/testsuite/sieve/relational.exp,
sieve/testsuite/sieve/size.exp,
sieve/testsuite/sieve/true.exp, sql/Makefile.am,
sql/mysql.c, sql/odbc.c, sql/postgres.c, sql/sql.c,
testsuite/Makefile.am, testsuite/makespool,
testsuite/lib/mailutils.exp
2005-05-13 Sergey Poznyakoff <gray@Mirddin.farlep.net>
* imap4d/fetch.c (imap4d_fetch0): Reduce memory consumption within
the mailbox scanning loop. Break the loop when an invalid msgno is
encountered or the message cannot be retrieved.
(fetch_io): Check for integer overflow (IDEF0956).
(fetch_full,fetch_rfc822_header,fetch_rfc822_text)
(fetch_operation): Propagate return value back to the caller.
* imap4d/util.c (util_finish): Fix potential vulnerability
(IDEF0954).
(util_msgset): Do not allow values greater than the maximum id
number (either message number or UID) in the mailbox. Fixes (IDEF0955).
* mailbox/header.c (header_get_field_name): Fix buffer overflow
(IDEF0957).
* doc/texinfo/sieve.texi: Fix typo
* imap4d/testsuite/imap4d/IDEF0955.exp: New test
* imap4d/testsuite/imap4d/IDEF0956.exp: New test
* imap4d/testsuite/imap4d/DISTFILES: Add new files
2005-05-11 Sergey Poznyakoff
* mailbox/parsedate.y (DATE_INIT): Bugfix. Several fields in
struct pd_date are used regardless of .mask, so it is better to
zero out the entire structure.
2005-03-25 Sergey Poznyakoff
* NEWS: Updated
* mail/decode.c (display_message0): Do not interpret MIME
parts if metamail is unset.
* mail/mail.c (default_setup): Set metamail
* testsuite/etc/mail.rc: Unset metamail
* doc/texinfo/programs.texi: Updated metamail documentation
2005-03-18 Sergey Poznyakoff
* TODO: Updated
* README-alpha: Updated
* mail/shell.c (mail_execute): Restore argv[0] before exiting,
else argcv_free coredumps.
2005-03-15 Sergey Poznyakoff
* mailbox/mailbox.c (mailbox_flush): Do not re-save all messages
if the mailbox was opened in append mode.
2005-03-14 Sergey Poznyakoff
* mimeview/mimetypes.l (<HEX>): Bugfix
* mimeview/mimetypes.y (b_string): Bugfix
2005-03-13 Sergey Poznyakoff
Sources are tagged alpha_0_6_1
* Makefile.am (SUBDIRS): Reordered. Due to the specifics
of gnulib imports, libmailutils depends on libmailbox.
Added config/.
* configure.ac (AC_CONFIG_FILES): Added config/Makefile
* lib/mailcap.c (mime_context_fill): Return integer code
(display_stream_mailcap): Bail out if mime_context_fill
returns 1
* mailbox/Makefile.am: Removed mailutils-config.c. It should
live in a separate directory to satisfy interlibrary dependencies.
* mailbox/mailutils-config.c: Moved to config
* config: New directory
* config/mailutils-config.c: New file
* config/Makefile.am: New file
* po/POTFILES.in: Updated
2005-03-13 Sergey Poznyakoff
* lib/mailcap.c Include ctype.h
(mime_context_fill): Remove leading whitespace
when preparing lists.
(mime_context_get_content_type_value): Return integer code.
(expand_string): Fixed expansion of %{name}
* mh/send.c: Use gettext markers in verbose diagnostics.
2005-03-12 Sergey Poznyakoff
* README: Updated. Switch to outline mode.
* README-alpha: Updated. Switch to outline mode.
* mailbox/mutil.c: Minor indentation fix
* mailbox/pop/pop3_sendline.c: Do not redefine _GNU_SOURCE
* mailbox/nntp/nntp_sendline.c: Likewise
2005-03-12 Sergey Poznyakoff
* lib/mailcap.c: New file. Routines for displaying MIME
messages.
* lib/Makefile.am: Added mailcap.c
* mimeview/mimeview.c: Rewritten using display_stream_mailcap.
* mail/decode.c: Implemented built-in mailcap mechanism
* mail/Makefile.am: (mail_LDADD): Changed order of loading
libmailutils/libmailbox
* mimeview/Makefile.am (mimeview_LDADD): Likewise
* doc/texinfo/programs.texi (mail): Documented variable
mimenoask
* po/POTFILES.in: Updated
* examples/mta.c (header): Removed unused global
* NEWS: Updated
2005-03-10 Sergey Poznyakoff
* TODO: Updated
* imap4d/imap4d.h (define _GNU_SOURCE): Removed. Defined
in config.h
* mailbox/mailcap.c (mu_mailcap_entry_get_value): Bugfix: return
ENOENT if no matching entry is found.
* mailbox/mutil.c (mu_true_answer_p): Ignore leading whitespace.
* mh/mh_init.c (mh_vgetyn): Synchronize with the changes to
mu_true_answer_p().
* mimeview/mimeview.c: Handle --no-ask and --no-interactive (-h)
options. Continue search for a matching entry when necessary.
Implement 'test' and 'print' commands.
* doc/texinfo/programs.texi (mimeview): Documented new options
2005-03-09 Sergey Poznyakoff
* mimeview/mimetypes.l: Bugfix: accept ',' as OR
* mimeview/mimetypes.y: Fixed precedences of ',' and '+'.
2005-03-08 Sergey Poznyakoff
* TODO: Updated
* configure.ac (DEFAULT_CUPS_CONFDIR): New variable
* doc/texinfo/programs.texi (mimeview): Documented the program
* mimeview/Makefile.am (AM_CFLAGS): Use DEFAULT_CUPS_CONFDIR
* mimeview/mimeview.c (create_filter,print_exit_status)
(get_pager): New function
(run_mailcap): Pipe file contents to the command if its invocation
does not contain %s.
Use pager if `copiousoutput' is specified in mailcap
* po/POTFILES.in: Updated
2005-03-08 Sergey Poznyakoff
TODO:121 said: "file viewer, based on the mimetypes api. I want to do
a "v foo.blah", have it look up .blah in mime.types, and do the
action spec'ed in mailcap."
So, here it goes:
* mimeview: New directory
* mimeview/mimetypes.y: New file
* mimeview/mimetypes.l: New file
* mimeview/mimeview.c: New file
* mimeview/mimeview.h: New file
* mimeview/Makefile.am: New file
* mimeview/.cvsignore: New file
* configure.ac: Added mimeview
* Makefile.am: Likewise
* doc/texinfo/programs.texi (mimeview): New section.
(mail): Document recently added variables.
* mailbox/mailcap.c (mu_mailcap_entry_copiousoutput): Bugfix
2005-03-07 Sergey Poznyakoff
* TODO: Updated
* NEWS: Updated
* mail/decode.c (mail_decode): Implemented new variable
`metamail' that turns on use of metamail program for
displaying MIME messages.
(run_metamail): New function
* mailbox/mutil.c (mu_spawnvp): Minor fixes
2005-03-06 Sergey Poznyakoff
* NEWS: Updated
* auth/sql.c: Use a uniform way of filename quoting in diagnostic
messages.
* frm/common.c: Likewise
* frm/from.c: Likewise
* imap4d/authenticate.c: Likewise
* imap4d/login.c: Likewise
* libsieve/actions.c: Likewise
* libsieve/extensions/vacation.c: Likewise
* mail/var.c: Likewise
* mail.local/mailquota.c: Likewise
* mail.local/main.c: Likewise
* mail.remote/mail.remote.c: Likewise
* mailbox/mu_argp.c: Likewise
* messages/messages.c: Likewise
* mh/forw.c: Likewise
* mh/mh_ctx.c: Likewise
* mh/mh_init.c: Likewise
* mh/send.c: Likewise
* movemail/movemail.c: Likewise
* pop3d/apop.c: Likewise
* pop3d/lock.c: Likewise
* pop3d/user.c: Likewise
* readmsg/readmsg.c: Likewise
* sieve/sieve.c: Likewise
* mailbox/errors (MU_ERR_NO_QUERY): Fixed wording
2005-03-05 Wojciech Polak
* frm/Makefile.am: Removed install-exec-hook after the changes
from 2005-03-02.
2005-03-05 Sergey Poznyakoff
POSIX compatibility issues in mail
* mail/alt.c (mail_is_my_name): Do not check `metoo'. The
caller is responsible for that.
* mail/reply.c (reply0): Check for `metoo' before calling
mail_is_my_name().
(mail_reply): Honor `flipr' variable
* mail/decode.c: Mark message as read and shown
* mail/mbox.c: Likewise
* mail/pipe.c: Likewise
* mail/print.c: Likewise
* mail/top.c: Likewise
* mail/undelete.c: Likewise
* mail/visual.c: Likewise
* mail/from.c (mail_from0): If `showto' is set and the
mail comes from the user that invoked the program, show
`To:' address instead of `From:'.
* mail/mail.c (default_setup): Added variables, required by
POSIX: flipr, showto, bang. Added placeholders for debug,
onehop and sendwait.
* mail/mail.h (util_mark_read): New function
* mail/shell.c: If `bang' is set, expand every occurrence
of ! in argument array.
* mail/touch.c: Rewritten in accordance with POSIX specs:
do not mbox deleted and saved messages.
* mail/util.c (util_mark_read): New function
2005-03-04 Sergey Poznyakoff
* mail/mail.h (MAIL_ATTRIBUTE_SHOWN): New attribute. Shows
that the message has been displayed during the current session.
* mail/next.c (mail_next): Rewritten in accordance with POSIX:
if the current message has not been shown yet, then show
it. Otherwise advance to the nearest next non-deleted message.
* mail/print.c (mail_print_msg): Set MAIL_ATTRIBUTE_SHOWN after
displaying the message
* mail/top.c (top0): set read attribute and MAIL_ATTRIBUTE_SHOWN
after displaying the message
2005-03-02 Sergey Poznyakoff
* frm/Makefile.am: Build `from'
* frm/frm.c: Moved part of code to be shared between `frm' and
`from' to common.c
* frm/common.c: New file
* frm/from.c: New file
* frm/frm.h: New file
* mail/quit.c: Save messages that were marked for saving to mbox
and then deleted
* mailbox/mbox/mbox.c (mbox_scan): Store the number of messages
into *pcount if we don't need to rescan the mailbox.
* po/POTFILES.in: Updated
* from/from.c: Removed
* from/Makefile.am: Removed
* from/.cvsignore: Removed
* from/testsuite: Removed
* from/testsuite/from/test.exp: Removed
* from/testsuite/from/DISTFILES: Removed
* configure.ac: Removed from
* Makefile.am: Likewise
* doc/texinfo/programs.texi: Document `from'
2005-02-28 Sergey Poznyakoff
* configure.ac: Check for FriBidi
* frm/Makefile.am: Link with libfribidi
* frm/frm.c: Rewritten output routines using FriBidi. Arabic
subject lines look almost OK, except that all characters are
displayed in isolated variant.
* frm/testsuite/frm/test.exp: Fixed to match the new frm output.
2005-02-27 Wojciech Polak
* frm/Makefile.am: Added install-exec-hook for creating
the symbolic link 'from' to 'frm'.
* from/Makefile.am: Changed bin_PROGRAMS to noinst_PROGRAMS.
2005-02-27 Sergey Poznyakoff
* gnulib.modules: Add mbswidth
* frm/frm.c: Implemented -t. Changed implementation of -Q.
Rewritten action() to correctly handle multibyte characters
and to provide for eventual using the BIDI algorithm.
(print_line,format_field,format_field_simple)
(format_field_align): New functions
(util_getcols): Measure /dev/tty if unable to open stdout.
(to work correctly with piped output).
(rfc2047_decode_wrapper): Cache the determined locale.
(get_personal): Do not limit the returned string length.
Do not attempt to decode the raw header text, since
parse822 will skip non-ascii characters, decode the already
obtained personal part instead.
* mailbox/address.c (address_aget_personal)
(address_aget_comments): Bugfix
* sql/mysql.c: Provide place handlers for handling MySQL 4.1.x
scrambled passwords.
Update by gnulib-sync:
* m4/mbrtowc.m4: New file
* m4/mbswidth.m4: New file
* lib/mbswidth.c: New file
* lib/mbswidth.h: New file
* lib/Makefile.am: Updated
* m4/gnulib.m4: Updated
2005-02-26 Wojciech Polak
* mh/send.c (expand_aliases): Bugfix. Do not use statically
allocated buffer. Use header_aget_field_name() instead.
The utility froze with header names longer than 16 bytes.
2005-02-26 Wojciech Polak
* mailbox/url_smtp.c (_url_smtp_init): Do not reject
an URL with user name, password, or auth method specified.
We will use it in further ESMTP authentication.
2005-02-26 Sergey Poznyakoff
* sql/mysql.c: Do not use any libmysql functions to
scramble passwords: mysql people are evidently
unable to keep this API stable.
2005-02-25 Sergey Poznyakoff
* NEWS: Updated
* auth/sql.c (mu_sql_password_type): New variable
(--sql-password-type): New command line option
(mu_sql_getpass): New function.
(mu_sql_authenticate): Recognize hashed, plaintext
and mysql scrambled passwords.
* auth/sql.h (sql_interface): new decl
(mu_sql_expand_query): New proto.
* imap4d/auth_gsasl.c (cb_retrieve): Fall back to SQL
if plaintext password file is not available.
* include/mailutils/sql.h (mu_sql_getpass)
(mu_sql_password_type,mu_sql_expand_query):
(mu_check_mysql_scrambled_password): New function
* mail.local/mailquota.c: Include <auth/sql.h>. A temporary
solution.
* mailbox/muerror.c (mu_syslog_error_printer): Bugfix.
* sql/mysql.c (mu_check_mysql_scrambled_password): New function.
* mail/mail.c: Updated copyright date.
2005-02-25 Sergey Poznyakoff
* NEWS: Updated
* include/mailutils/libsieve.h (sieve_get_identifier): New
function.
(sieve_arg_error): New function.
* libsieve/actions.c: Removed spurious indications of action
names in diagnostic messages. Sieve_error prepends them
automatically now.
* libsieve/tests.c: Likewise.
* libsieve/extensions/list.c: Likewise.
* libsieve/extensions/timestamp.c: Likewise.
* libsieve/extensions/vacation.c: Likewise.
* libsieve/runtime.c (instr_action,instr_test): Update
mach->identifier.
* libsieve/sieve.h (struct sieve_machine.identifier): New
field.
* libsieve/util.c (sieve_value_create): Bugfix.
(sieve_error): Prepend action or test identifier to the diagnostic
message.
(sieve_arg_error): New function.
* po/POTFILES.in: Updated
2005-02-24 Sergey Poznyakoff
Update by gnulib-sync.
* lib/stdbool.h: New file
* m4/unlocked-io.m4: New file
* m4/argp.m4: Updated
* m4/gnulib.m4: Updated
* mailbox/Makefile.am: Updated
2005-02-23 Sergey Poznyakoff
Synchronized with the recent gnulib. Provide a way to
facilitate further synchronizations.
* gnulib.modules: New file
* scripts/gnulib-sync: New file. Script for synchronizing
mailutils tree with gnulib.
* configure.ac: Updated to use new gnulib files.
* m4/mu_libobj.m4 (MU_LIBSOURCES,MU_REPLACE_FUNCS): New defun.
(MU_CHECK_FUNCS): Removed.
* Makefile.am: Remove headers/
* frm/frm.c (parse_opt): Bugfix. Was using optarg instead of arg
* mail.local/main.c: Likewise
* pop3d/popauth.c: Likewise
* readmsg/readmsg.c: Likewise
* include/mailutils/argp.h: Include errno.h
* include/mailutils/gnu/Makefile.am: Remove posix/regex.h
* libsieve/argp.c (sieve_argp_option): Use N_()
* mailbox/message.c: Use new md5 calls
* mailbox/pop/mbox.c: Likewise
* mailbox/pop/pop3_apop.c: Likewise
* mailbox/message.c: Likewise
* mh/mh_error.c: Include mailutils/argp.h
* mh/mh_getopt.c: Include string.h
* pop3d/Makefile.am (INCLUDES): Add $(top_srcdir)/mailbox
* pop3d/pop3d.h: Minor fix
* lib/xalloc_die.c: New file
* m4/gnulib.m4: New file
* headers/.cvsignore
* headers/Makefile.am
* headers/getopt.h
* headers/regex.h
* headers/argp.h
* headers/posix/.cvsignore
* headers/posix/Makefile.am
* headers/posix/regex.h
* headers/posix
Update by gnulib-sync.
* lib/asprintf.c: New file
* mailbox/alloca.h: New file
* mailbox/argp.h: New file
* mailbox/getopt.h: New file
* lib/allocsa.c: Added to the repository
* lib/allocsa.h: Added to the repository
* lib/allocsa.valgrind: Added to the repository
* lib/asprintf.c: Updated
* lib/error.c: Added to the repository
* lib/error.h: Updated
* lib/exit.h: Added to the repository
* lib/exitfail.c: Added to the repository
* lib/exitfail.h: Added to the repository
* lib/fnmatch.c: Updated
* lib/fnmatch_.h: Added to the repository
* lib/fnmatch_loop.c: Added to the repository
* lib/getpass.c: Updated
* lib/getpass.h: Added to the repository
* lib/malloc.c: Updated
* lib/obstack.c: Updated
* lib/obstack.h: Updated
* lib/realloc.c: Updated
* lib/setenv.c: Updated
* lib/setenv.h: Added to the repository
* lib/snprintf.c: Updated
* lib/snprintf.h: Updated
* lib/stdbool_.h: Added to the repository
* lib/unsetenv.c: Added to the repository
* lib/vasprintf.c: Updated
* lib/vasprintf.h: Added to the repository
* lib/xalloc.h: Updated
* lib/xmalloc.c: Updated
* lib/xsize.h: Added to the repository
* lib/xstrtol.c: Updated
* lib/xstrtol.h: Updated
* lib/xstrtoul.c: Added to the repository
* m4/alloca.m4: Added to the repository
* m4/allocsa.m4: Added to the repository
* m4/argp.m4: Added to the repository
* m4/eealloc.m4: Added to the repository
* m4/eoverflow.m4: Added to the repository
* m4/error.m4: Added to the repository
* m4/exitfail.m4: Added to the repository
* m4/extensions.m4: Added to the repository
* m4/fnmatch.m4: Added to the repository
* m4/getline.m4: Added to the repository
* m4/getndelim2.m4: Added to the repository
* m4/getopt.m4: Updated
* m4/getpass.m4: Added to the repository
* m4/gettext_gl.m4: Added to the repository
* m4/glibc21_gl.m4: Added to the repository
* m4/iconv.m4: Added to the repository
* m4/intmax.m4: Added to the repository
* m4/intmax_t.m4: Added to the repository
* m4/intmax_t.m4: Added to the repository
* m4/inttypes.m4: Added to the repository
* m4/inttypes_h_gl.m4: Added to the repository
* m4/inttypes_h_gl.m4: Added to the repository
* m4/lib-ld_gl.m4: Added to the repository
* m4/lib-prefix_gl.m4: Added to the repository
* m4/longdouble.m4: Added to the repository
* m4/longdouble.m4: Added to the repository
* m4/longlong_gl.m4: Added to the repository
* m4/longlong_gl.m4: Added to the repository
* m4/mailbox-link.m4: Added to the repository
* m4/mbstate_t.m4: Added to the repository
* m4/md5.m4: Added to the repository
* m4/mempcpy.m4: Added to the repository
* m4/nls.m4: Added to the repository
* m4/obstack.m4: Added to the repository
* m4/onceonly.m4: Added to the repository
* m4/onceonly.m4: Added to the repository
* m4/po_gl.m4: Added to the repository
* m4/printf-posix.m4: Added to the repository
* m4/progtest.m4: Added to the repository
* m4/regex.m4: Updated
* m4/restrict.m4: Added to the repository
* m4/setenv.m4: Added to the repository
* m4/signed.m4: Added to the repository
* m4/size_max.m4: Added to the repository
* m4/size_max.m4: Added to the repository
* m4/snprintf.m4: Added to the repository
* m4/ssize_t.m4: Added to the repository
* m4/stdbool.m4: Added to the repository
* m4/stdint_h_gl.m4: Added to the repository
* m4/stdint_h_gl.m4: Added to the repository
* m4/strcase.m4: Added to the repository
* m4/strchrnul.m4: Added to the repository
* m4/strerror_r.m4: Added to the repository
* m4/strndup.m4: Added to the repository
* m4/strnlen.m4: Added to the repository
* m4/strtok_r.m4: Added to the repository
* m4/sysexits.m4: Added to the repository
* m4/uint32_t.m4: Added to the repository
* m4/uintmax_t_gl.m4: Added to the repository
* m4/uintmax_t_gl.m4: Added to the repository
* m4/ulonglong_gl.m4: Added to the repository
* m4/ulonglong_gl.m4: Added to the repository
* m4/vasnprintf.m4: Added to the repository
* m4/vasprintf.m4: Added to the repository
* m4/vsnprintf.m4: Added to the repository
* m4/wchar_t.m4: Added to the repository
* m4/wint_t.m4: Added to the repository
* m4/xalloc.m4: Added to the repository
* m4/xsize.m4: Added to the repository
* m4/xsize.m4: Added to the repository
* m4/xstrtol.m4: Added to the repository
* mailbox/alloca.c: Added to the repository
* mailbox/alloca_.h: Added to the repository
* mailbox/argp-ba.c: Updated
* mailbox/argp-eexst.c: Updated
* mailbox/argp-fmtstream.c: Updated
* mailbox/argp-fmtstream.h: Updated
* mailbox/argp-fs-xinl.c: Updated
* mailbox/argp-help.c: Updated
* mailbox/argp-namefrob.h: Updated
* mailbox/argp-parse.c: Updated
* mailbox/argp-pv.c: Updated
* mailbox/argp-pvh.c: Updated
* mailbox/argp-xinl.c: Updated
* mailbox/argp.h: Updated
* mailbox/asnprintf.c: Added to the repository
* mailbox/getline.c: Updated
* mailbox/getline.h: Updated
* mailbox/getndelim2.c: Added to the repository
* mailbox/getndelim2.h: Added to the repository
* mailbox/getopt.c: Updated
* mailbox/getopt1.c: Updated
* mailbox/getopt_.h: Added to the repository
* mailbox/getopt_int.h: Added to the repository
* mailbox/gettext.h: Added to the repository
* mailbox/md5.c: Updated
* mailbox/md5.h: Updated
* mailbox/mempcpy.c: Added to the repository
* mailbox/mempcpy.h: Added to the repository
* mailbox/minmax.h: Added to the repository
* mailbox/printf-args.c: Added to the repository
* mailbox/printf-args.h: Added to the repository
* mailbox/printf-parse.c: Added to the repository
* mailbox/printf-parse.h: Added to the repository
* mailbox/regex.c: Updated
* mailbox/regex.h: Added to the repository
* mailbox/strcase.h: Added to the repository
* mailbox/strcasecmp.c: Added to the repository
* mailbox/strchrnul.c: Updated
* mailbox/strchrnul.h: Added to the repository
* mailbox/strncasecmp.c: Added to the repository
* mailbox/strndup.c: Updated
* mailbox/strndup.h: Added to the repository
* mailbox/strnlen.c: Updated
* mailbox/strtok_r.c: Updated
* mailbox/strtok_r.h: Added to the repository
* mailbox/sysexit_.h: Added to the repository
* mailbox/vasnprintf.c: Added to the repository
* mailbox/vasnprintf.h: Added to the repository
* mailbox/vsnprintf.c: Added to the repository
* mailbox/vsnprintf.h: Added to the repository
* mailbox/xsize.h: Added to the repository
* scripts/config.rpath: Added to the repository
2005-02-21 Sergey Poznyakoff
* libsieve/actions.c: Further unification of diagnostic style.
* libsieve/argp.c: Likewise.
* mail/mail.c: Likewise.
* mail.local/mailquota.c: Likewise.
* mailbox/mu_argp.c: Likewise.
* mh/forw.c: Likewise.
* mh/refile.c: Likewise.
* mh/repl.c: Likewise.
* mh/send.c: Likewise.
* sieve/sieve.c: Likewise.
* mail.local/main.c: Add debug flag 'i' for symmetry with sieve
2005-02-16 Sergey Poznyakoff
Fix a long-standing issue in mailbox and imap4d:
be able to handle a case when a third-party program deletes
some messages in the mailbox being open by imap4d (imap4d
cannot and should not lock it, hence the possibility).
* mailbox/amd.c (amd_pool_flush): New function.
(amd_close): Call amd_pool_flush()
and initialize amd data so that subsequent amd_open() works
properly.
(amd_destroy): Call amd_pool_flush.
* mailbox/mbox/mbox.c (mbox_close): Initialize all private data
so that subsequent mailbox_open() works properly.
(mbox_is_updated): Updated comment
* imap4d/bye.c (imap4d_bye0): Handle ERR_MAILBOX_CORRUPTED
* imap4d/imap4d.h (ERR_MAILBOX_CORRUPTED): New error code.
(imap4d_set_observer): New function
* imap4d/select.c (imap4d_select0): Call imap4d_set_observer()
* imap4d/sync.c (imap4d_set_observer): New function.
(imap4d_sync): Check if the mailbox was shrunk (in libmailbox
terms 'corrupted'). If so, reopen it and issue untagged alert.
2005-02-16 Sergey Poznyakoff
* imap4d/auth_gsasl.c (cb_validate): Provide normal authentication
for PLAIN and LOGIN mechanisms.
2005-02-11 Sergey Poznyakoff
* imap4d/unsubscribe.c: Rewritten. Thanks Andrew Barnes
for reporting the bug.
2005-02-03 Sergey Poznyakoff
* guimb/main.c (parse_opt): Use arg instead of optarg.
Thanks James Dolter for reporting.
2005-01-17 Sergey Poznyakoff
* mailbox/parsedate.y (mu_parse_date): Initialize struct tm
* mailbox/nntp/folder.c (nntp_folder_open): Do not use alloca
* mailbox/nntp/mbox.c: Do not use alloca
* doc/texinfo/Makefile.am: Rewritten to use gendocs.sh
* doc/texinfo/index.html.in: Removed
* doc/texinfo/gendocs_template: New file
* doc/texinfo/fdl.texi: Fixed sectioning
* doc/texinfo/programs.texi: Likewise.
* doc/texinfo/url.texi: Likewise.
* doc/texinfo/mailutils.texi: Fixed sectioning. Print table
of contents after summary page, as suggested by GNU standards.
2005-01-05 Sergey Poznyakoff
* configure.ac (AUTHLIBS_DEPENDENCY,SQLLIB_DEPENDENCY): New
variables. I still hope to find a better solution, though
(see comment to imap4d_DEPENDENCIES in imap4d/Makefile.am).
New SQL driver: ODBC (--with-sql=odbc or --with-odbc)
Raised version number to 0.6.1
* NEWS: Updated
* README: Updated
* auth/Makefile.am: Use explicit PROG_DEPENDENCIES
* imap4d/Makefile.am: Likewise.
* pop3d/Makefile.am: Likewise.
* include/mailutils/sql.h (mu_sql_dispatch.errstr): Changed
return type to const char*
* sql/mysql.c: Likewise
* sql/postgres.c: Likewise
* sql/sql.c: Likewise
* sql/odbc.c: New file. ODBC SQL driver.
* sql/Makefile.am: Add odbc.c
* mail/testsuite/mail/read.exp: Updated to match recent changes
in diagnostic messages.
2005-01-04 Sergey Poznyakoff
* libsieve/extensions/vacation.c: New action. Based on
guimb/scm/vacation.scm and on ideas and code fragments from
Felix Egli <fegli@goldnet.ch>.
* libsieve/extensions/Makefile.am: Add vacation
* include/mailutils/libsieve.h (sieve_get_message_sender)
(stream_printf): New prototypes.
* THANKS: Add Felix Egli
2005-01-04 Sergey Poznyakoff
* auth/sql.c: Revise error messages for accordance with GNU standards:
begin messages with a capital letter, unless they are prefixed
with `file:line:' or their exact look is important due to
compatibility reasons. Do not end messages with a period.
Avoid using contracted negations
* auth/tls.c: Likewise
* comsat/action.c: Likewise
* comsat/cfg.c: Likewise
* comsat/comsat.c: Likewise
* dotlock/dotlock.c: Likewise
* frm/frm.c: Likewise
* from/from.c: Likewise
* guimb/collect.c: Likewise
* guimb/main.c: Likewise
* guimb/util.c: Likewise
* imap4d/auth_gss.c: Likewise
* imap4d/imap4d.c: Likewise
* imap4d/list.c: Likewise
* imap4d/signal.c: Likewise
* imap4d/util.c: Likewise
* libsieve/actions.c: Likewise
* libsieve/comparator.c: Likewise
* libsieve/prog.c: Likewise
* libsieve/runtime.c: Likewise
* libsieve/sieve.l: Likewise
* libsieve/tests.c: Likewise
* libsieve/util.c: Likewise
* mail/alt.c: Likewise
* mail/copy.c: Likewise
* mail/decode.c: Likewise
* mail/file.c: Likewise
* mail/if.c: Likewise
* mail/mail.c: Likewise
* mail/mailline.c: Likewise
* mail/quit.c: Likewise
* mail/send.c: Likewise
* mail/source.c: Likewise
* mail/unalias.c: Likewise
* mail/util.c: Likewise
* mail/var.c: Likewise
* mail/z.c: Likewise
* mail.local/mailquota.c: Likewise
* mail.local/main.c: Likewise
* mail.local/script.c: Likewise
* mailbox/mailutils-config.c: Likewise
* mailbox/mu_argp.c: Likewise
* messages/messages.c: Likewise
* mh/fmtcheck.c: Likewise
* mh/folder.c: Likewise
* mh/forw.c: Likewise
* mh/inc.c: Likewise
* mh/mark.c: Likewise
* mh/mh_argp.c: Likewise
* mh/mh_ctx.c: Likewise
* mh/mh_fmtgram.y: Likewise
* mh/mh_format.c: Likewise
* mh/mh_init.c: Likewise
* mh/mh_list.c: Likewise
* mh/mh_msgset.c: Likewise
* mh/mh_whom.c: Likewise
* mh/mhl.c: Likewise
* mh/mhn.c: Likewise
* mh/pick.c: Likewise
* mh/refile.c: Likewise
* mh/repl.c: Likewise
* mh/rmf.c: Likewise
* mh/scan.c: Likewise
* mh/send.c: Likewise
* movemail/movemail.c: Likewise
* pop3d/apop.c: Likewise
* pop3d/extra.c: Likewise
* pop3d/lock.c: Likewise
* pop3d/pop3d.c: Likewise
* pop3d/popauth.c: Likewise
* pop3d/signal.c: Likewise
* readmsg/readmsg.c: Likewise
* sieve/sieve.c: Likewise
* mail/testsuite/mail/read.exp: Updated to match new output format
of the decode command
2005-01-04 Sergey Poznyakoff
* mailbox/errors: Add gettext markers
* po/POTFILES.in: Depend on mailbox/errors directly
* scripts/generr.awk: Assume textual messages are
already quoted.
2005-01-02 Jordi Mallach
* doc/texinfo/programs.texi: Typo fix.
2005-01-01 Sergey Poznyakoff
Generate automatically errno.h and muerrno.c from a single
plain text file. This facilitates maintaining of mailutils-
specific error codes.
* include/mailutils/errno.h: Removed
* include/mailutils/errno.hin: New file
* include/mailutils/Makefile.am: Generate errno.h
* mailbox/muerrno.c: Removed
* mailbox/muerrno.cin: New file
* mailbox/errors: New file
* mailbox/Makefile.am: Generate muerrno.c
* scripts/generr.awk: New file
* scripts/Makefile.am: Add generr.awk
Fix a recently spotted problem in the testsuite:
* imap4d/testsuite/imap4d/list.exp: Use new -sort flag to
avoid dependency on any particular ordering. Also corrected
expected outputs due to inclusion of two new mailboxes quite
some time ago (went unnoticed so far due to fuzzy matching
technique + ordering-dependent output).
* imap4d/testsuite/lib/imap4d.exp (imap4d_test): New flag -sort
toggles on sorting of untagged responses. Notice that -sort
and -re are mutually exclusive.
* testsuite/lib/mailutils.exp (mu_test): Upvar expect_out
2004-12-28 Wojciech Polak
Fixed displaying mail headers in different languages.
* mail/util.c (util_rfc2047_decode): Fixed reading
a language environment variable.
* frm/frm.c (rfc2047_decode_wrapper): Likewise.
(util_getcols): Imported function from mail/util.c.
(action): Try to print only one line per message.
* from/from.c (rfc2047_decode_wrapper): Fixed.
2004-12-23 Sergey Poznyakoff
* configure.ac: Version 0.6
* NEWS: Likewise
* README: Updated
* auth/gsasl.c: Updated for GSASL >=0.2.3. Previous versions
won't work.
* auth/lbuf.c (_auth_lb_writelines): Bugfix
* mail.local/mail.local.h (USE_MAILBOX_QUOTAS): New define
* mail.local/mailquota.c: Use USE_MAILBOX_QUOTAS.
(sql_retrieve_quota): Assume unlimited quotas for empty fields.
* mail.local/main.c: Use USE_MAILBOX_QUOTAS.
2004-12-17 Sergey Poznyakoff
* configure.ac: Do not allow to specify modules more than once
* auth/sql.c (sql_escape_string): Escape occurrences of ' and "
in string.
(mu_sql_expand_query): prevent possible sql injection
* mail.local/mailquota.c (sql_retrieve_quota): Allow for NULL
columns
* sql/postgres.c (destroy): Bugfix: do not free pgconn
2004-12-05 Sergey Poznyakoff
* Makefile.am: Added sql/
* configure.ac: Rewritten sql-related part. Allow to specify
several SQL libraries simultaneously.
* sql: New directory
* sql/Makefile.am: New file
* sql/.cvsignore: New file
* sql/sql.c: New file
* sql/mysql.c: New file
* sql/postgres.c: New file
* auth/mysql.c: Removed
* auth/pgsql.c: Removed
* auth/sql.c: Rewritten using general SQL interface.
* auth/Makefile.am: Removed mysql.c and pgsql.c
* include/mailutils/sql.h: New file
* include/mailutils/Makefile.am: Added sql.h
* include/mailutils/errno.h: Added new error codes.
* mailbox/muerrno.c: Likewise.
* mail.local/mail.local.h (quota_query): New variable
* mail.local/mailquota.c: Retrieve quotas from SQL database
* mail.local/main.c: New option --quota-query
* scripts/sqlmod.sh: New file
* scripts/Makefile.am: Added sqlmod.sh
* doc/texinfo/programs.texi: Documented mailbox quotas
* NEWS: Updated
* README: Updated
* po/POTFILES.in: Updated
2004-12-02 Sergey Poznyakoff
* doc/texinfo/programs.texi: Documented movemail.
2004-11-18 Sergey Poznyakoff
* mailbox/imap/folder.c (authenticate_imap_select): Use
ENOSYS as the default status value to allow MU_ERR_AUTH_FAILURE
to be propagated back to the caller.
(imap_parse): Display "NO/Bad Tagged" error diagnostics only if
status != MU_ERR_AUTH_FAILURE. Should we display it at all?
* movemail/movemail.c: Emacs-interaction mode (--emacs)
2004-11-17 Wojciech Polak
Added initial version of `libmu_cpp',
a C++ wrapper for Mailutils.
* libmu_cpp: Added new directory.
* libmu_cpp/address.cc: New file.
* libmu_cpp/filter.cc: Likewise.
* libmu_cpp/iterator.cc: Likewise.
* libmu_cpp/mailbox.cc: Likewise.
* libmu_cpp/mailer.cc: Likewise.
* libmu_cpp/message.cc: Likewise.
* libmu_cpp/stream.cc: Likewise.
* libmu_cpp/header.cc: Likewise.
* libmu_cpp/list.cc: Likewise.
* libmu_cpp/mailcap.cc: Likewise.
* libmu_cpp/pop3.cc: Likewise.
* libmu_cpp/url.cc: Likewise.
* libmu_cpp/Makefile.am: Likewise.
* include/mailutils/cpp: Added new directory.
* include/mailutils/cpp/address.h: New file.
* include/mailutils/cpp/error.h: Likewise.
* include/mailutils/cpp/header.h: Likewise.
* include/mailutils/cpp/list.h: Likewise.
* include/mailutils/cpp/mailcap.h: Likewise.
* include/mailutils/cpp/mailutils.h: Likewise.
* include/mailutils/cpp/message.h: Likewise.
* include/mailutils/cpp/stream.h: Likewise.
* include/mailutils/cpp/filter.h: Likewise.
* include/mailutils/cpp/iterator.h: Likewise.
* include/mailutils/cpp/mailbox.h: Likewise.
* include/mailutils/cpp/mailer.h: Likewise.
* include/mailutils/cpp/pop3.h: Likewise.
* include/mailutils/cpp/url.h: Likewise.
* include/mailutils/cpp/Makefile.am: Likewise.
* examples/cpp/addr.cc: New file.
* examples/cpp/http.cc: Likewise.
* examples/cpp/listop.cc: Likewise.
* examples/cpp/sfrom.cc: Likewise.
* examples/cpp/iconv.cc: Likewise.
* examples/cpp/mailcap.cc: Likewise.
* examples/cpp/murun.cc: Likewise.
* examples/cpp/url-parse.cc: Likewise.
* examples/cpp/Makefile.am: Likewise.
2004-11-15 Wojciech Polak
* examples/config: New directory.
* examples/cpp: Likewise.
* examples/scheme: Likewise.
* examples/config/Makefile.am: New file.
* examples/cpp/Makefile.am: Likewise.
* examples/scheme/Makefile.am: Likewise.
* examples/comsat.conf: Moved to config/.
* examples/dot.biffrc: Likewise.
* examples/gnu-imap4d.pam: Likewise.
* examples/gnu-pop3d.pam: Likewise.
* examples/mailutils.rc: Likewise.
* examples/reply.scm: Moved to scheme/.
* examples/Makefile.am: Updated.
* configure.ac: Updated.
2004-11-15 Sergey Poznyakoff
* imap4d/imap4d.c: New option --tls-required: do not allow
authentication until TLS negotiation succeeds.
* imap4d/authenticate.c (imap4d_authenticate): Do not proceed if
tls_required is set.
* imap4d/login.c (imap4d_login): Likewise.
* imap4d/imap4d.h (IMAP_CAPA_STARTTLS,IMAP_CAPA_LOGINDISABLED)
(IMAP_CAPA_XTLSREQUIRED): New defines
* imap4d/starttls.c (imap4d_starttls): Clear tls_required upon
successful TLS handshake.
(starttls_init): Use IMAP_CAPA_STARTTLS instead of hardcoded
literal.
* include/mailutils/header.h (MU_HEADER_X_EXPIRE_TIMESTAMP): New
define.
* pop3d/pop3d.c: New option --tls-required: do not allow
authentication until TLS negotiation succeeds.
New option --delete-expired: delete expired messages before
closing the mailbox.
* pop3d/capa.c (pop3d_capa): Announce XTLSREQUIRED if appropriate
* pop3d/expire.c (expire_mark_message): New function
* pop3d/pop3d.h: New declarations.
* pop3d/quit.c (pop3d_fix_mark): Use expire_mark_message to
process expired messages. Apart from the new functionality, it
also fixes a bug: len was incorrectly used as a replace indicator
in header_set_value, thus each retrieval of the message was
resetting its expiration date.
* pop3d/stls.c (pop3d_stls): Set state to AUTHORIZATION upon
successful completion of TLS negotiation.
* configure.ac: Raised version number to 0.5.1
* NEWS: Entry for 0.5.1
2004-11-03 Sergey Poznyakoff
* dotlock/dotlock.c: Removed -T option (CAN-2004-0984)
2004-10-26 Sergey Poznyakoff
* imap4d/store.c (imap4d_store0): Send \r\n at the end of
the unsolicited response.
2004-09-18 Sergey Poznyakoff
* configure.ac: Bugfix
* mailbox/mime.c (_mime_munge_content_header): Bugfix
2004-08-31 Wojciech Polak
* mailbox/file_stream.c (prog_stream_create): Changed type
of the second argument to const char*.
(filter_prog_stream_create): Likewise.
(_prog_stream_create): Changed type of the third argument
to const char*.
* include/mailutils/stream.h (prog_stream_create): Changed
type of the second argument to const char*.
(filter_prog_stream_create): Likewise.
* doc/texinfo/stream.texi: Updated.
* configure.ac (AM_GNU_GETTEXT_VERSION): Bump to 0.14.1.
2004-08-24 Sergey Poznyakoff
* mail/util.c (util_do_command): Fixed coredump on unparseable
input strings.
* THANKS: Added Dan Jacobson
2004-08-20 Sergey Poznyakoff
* include/mailutils/guile.h (MU_SCM_SYMBOL_VALUE): New define
(_mu_scm_mailer,_mu_scm_debug): Removed externs.
* include/mailutils/list.h (list_set_destroy_item): Use __PMT in
nested declarations.
* libmu_scm/mu_message.c: Properly access mu-mailer and mu-message
values.
2004-08-11 Sergey Poznyakoff
* mail/send.c (mail_send0): Fixed coredump on reading a
single escape char.
2004-08-08 Sergey Poznyakoff
* headers/argp.h: Protect typedef int error_t by an additional
#ifndef. Thanks Alex S. Moore <asmoore@edge.net> for helping
find out the problem.
2004-08-07 Sergey Poznyakoff
* Makefile.am: Raised automake requirements to version
1.8.5
* examples/nntpclient.c: Minor fixes.
* imap4d/Makefile.am (INCLUDES): Added -Imailbox
* imap4d/imap4d.h: Added missing includes
* include/mailutils/nls.h [!ENABLE_NLS]: Define gettext()
* include/mailutils/nntp.h: Minor changes. The screen is 80x24!
* mailbox/locker.c (_locker_lock_dotlock): Make sure the lock file
is writable for the owner.
* mailbox/imap/folder.c (authenticate_imap_sasl_anon): Use
auth_state instead of state. Possibly this was a typo...
* mailbox/include/imap0.h (struct _f_imap.capac): Changed
type to int.
* mailbox/maildir/mbox.c (maildir_gethostname): Fixed a gross
memory allocation bug.
* mailbox/message.c: Minor changes.
* mailbox/mbox/url.c: Likewise.
* mailbox/nntp/folder.c: Likewise.
* mailbox/nntp/mbox.c: Likewise.
* mailbox/nntp/nntp_article.c: Likewise.
* mailbox/nntp/nntp_connect.c: Likewise.
* mailbox/nntp/nntp_date.c: Likewise.
* mailbox/nntp/nntp_head.c: Likewise.
* mailbox/nntp/nntp_ihave.c: Likewise.
* mailbox/nntp/nntp_post.c: Likewise.
* scripts/guile-1.6/guile-doc-snarf: Bugfix. Always use $AWK.
2004-08-06 Sergey Poznyakoff
* include/mailutils/daemon.h: Include types.h
2004-07-07 Sergey Poznyakoff
* libsieve/extensions/spamd.c (decode_float): Return
signed long value, as SpamAssassin scores can be negative.
(spamd_test): Updated accordingly
2004-07-05 Sergey Poznyakoff
* include/mailutils/registrar.h (mu_register_extra_formats): New
macro.
(mu_register_all_formats): Call mu_register_extra_formats()
* mailbox/mu_argp.c (mu_conf_option): Added ENABLE_NNTP
* mailbox/nntp/Makefile.am: Add nntp0.h
* mh/Makefile.am: Added libmu_nntp.la
* readmsg/readmsg.c (main): Call mu_register_extra_formats()
2004-07-05 Sergey Poznyakoff
* include/mailutils/registrar.h (mu_register_all_mbox_formats):
Removed nntp_record. It is not a *mailbox* format.
* mailbox/mailutils-config.c: Added mu_nntp
* mailbox/include/iterator0.h (_iterator.getitem): Changed
declaration. There's no use passing a pointer to the const
location, since the function *must* assign to it anyway.
* include/mailutils/iterator.h (iterator_set_getitem): Changed
declaration
* mailbox/iterator.c (iterator_set_getitem): Changed
declaration
(iterator_current): Additional typecast on pitem
* mailbox/list.c: Updated declaration of getitem method.
* mailbox/nntp/nntp_iterator.c: Likewise
* mailbox/pop/pop3_iterator.c: Likewise
* mailbox/mailbox.c: Include <list.h>
* mailbox/mailer.c: Likewise
2004-07-05 Alain Magloire
* configure.ac: enable NNTP support.
* example/Makefile.am: Enable NNTP.
* frm/Makefile.am: Enable NNTP.
* from/Makefile.am: Enable NNTP.
* messages/Makefile.am: Enable NNTP.
* readmsg/Makefile.am: Enable NNTP.
* guimb/Makefile.am: Enable NNTP.
* mail/Makefile.am: Enable NNTP.
* sieve/Makefile.am: Enable NNTP.
* imap4d/Makefile.am: Put @AUTHLIBS@ before libmailbox.a (failed
on cygwin if not).
* pop3d/Makefile.am: Put @AUTHLIBS@ before libmailbox.a (failed on
cygwin if not).
* mail.local/Makefile.am: Put @AUTHLIBS@ before libmailbox.a
(failed on cygwin if not).
* mailbox/stream.c (stream_wait): Bugfix. If we buffer return
true if the cache still have data.
* include/mailutils/nntp.h: Define the default NNTP port number.
* include/mailutils/pop3.h: Define the default POP3 port number.
* include/mailutils/registrar.h: Enable NNTP.
* mailbox/nntp/folder.c: New file.
* mailbox/nntp/mbox.c: New file.
* mailbox/nntp/url.c: New file.
* mailbox/nntp/Makefile.am: Updated.
2004-07-03 Sergey Poznyakoff
* mailbox/list.c (list_data_dup): Bugfix: *ptr was not assigned.
* doc/texinfo/muint.texi: Automake does not allow two independent
texi sources to include the same file (version.texi, in this
case). What a stupid lossage! However it handles all files whose
name matches "vers*.texi" as version.texi, which allows to
override the bug: include vers-muint.texi instead of version.texi.
2004-07-01 Sergey Poznyakoff
* include/mailutils/iterator.h (iterator_current)
(iterator_set_getitem): Changed proto
(iterator_get_list): Removed.
* mailbox/include/iterator0.h (struct _iterator.getitem): Changed
declaration.
* mailbox/iterator.c (iterator_current)
(iterator_set_getitem): Changed declaration
* mailbox/list.c (getitem): Changed declaration
* mailbox/rfc2047.c (rfc2047_decode): Fixed buffer
handling
* examples/mta.c: Minor fix
* examples/nntpclient.c: Fixed printf formats
(com_newgroups,com_newnews): Variable declarations are only allowed
before the statements.
* mailbox/nntp/nntp_article.c: Fixed printf formats
* mailbox/nntp/nntp_body.c: Likewise
* mailbox/nntp/nntp_head.c: Likewise
* mailbox/nntp/nntp_iterator.c: Added missing include
(nntp_itr_getitem): Changed declaration
* mailbox/pop/pop3_iterator.c (pop3_itr_getitem): Changed
declaration
2004-06-30 Alain Magloire
* configure.ac: Add nntp directory.
* doc/rfc/pop3.texit: add new API.
* mailbox/Makefile.am: Add nntp directory.
* mailbox/nntp/Makefile.am: Add new files.
* mailbox/nntp/nntp_iterator.c: New file.
* mailbox/nntp/nntp_list_active.c: Use the an iterator_t instead of a lis_t..
* mailbox/nntp/nntp_list_distribpats.c: instead of a lis_t. file.
* mailbox/nntp/nntp_list_times.c: instead of a lis_t. file.
* mailbox/nntp/nntp_list_newgroups.c: instead of a lis_t. file.
* mailbox/nntp/nntp_list_newnews.c: instead of a lis_t. file.
* mailbox/pop3/Makefile.am: Add new files.
* mailbox/pop3/pop3_iterator.c: New file.
* mailbox/pop3/pop3_capa.c: instead of a lis_t. file.
* mailbox/pop3/pop3_lista.c: instead of a lis_t. file.
* mailbox/pop3/pop3_uidla.c: instead of a lis_t. file.
* include/mailutils/Makefile.am: Add nntp.h and pop3.h.
* include/mailutils/nntp.h: Add new declarations.
* include/mailutils/sys/Makefile.am: Add nntp and pop3.hh
* include/mailutils/sys/nntp.h: Add new declarations.
* include/mailutils/pop3.h: NAdd new declarations.
* example/Makefile.am: Adjusted to new API.
* example/nntpclient.c: Adjusted to new API.
* example/pop3client.c: Adjusted to new API.
* example/.cvsignore: Add nntpclient.
2004-06-30 Alain Magloire
* mailbox/list.c (list_get_iterator): Bug fix, wrong size for calloc()
(list_data_dup): Copy the elements.
2004-06-30 Sergey Poznyakoff
* libsieve/extensions/spamd.c (spamd_shutdown): Bugfix
2004-06-29 Alain Magloire
Continuing the framework for NNTP support
* mailbox/nntp/.cvsignore: New file.
* mailbox/nntp/nntp_help.c: New file.
* mailbox/nntp/nntp_ihave.c: New file.
* mailbox/nntp/nntp_list_active.c: New file.
* mailbox/nntp/nntp_list_distribpats.c: New file.
* mailbox/nntp/nntp_list_distributions.c: New file.
* mailbox/nntp/nntp_list_newsgroups.c: New file.
* mailbox/nntp/nntp_list_times.c: New file.
* mailbox/nntp/nntp_newgroups.c: New file.
* mailbox/nntp/nntp_newnews.c: New file.
* mailbox/nntp/nntp_post.c: New file.
* mailbox/nntp/nntp_article.c: implementation.
* mailbox/nntp/nntp_body.c: implementation.
* mailbox/nntp/nntp_connect.c: implementation.
* mailbox/nntp/nntp_date.c: implementation.
* mailbox/nntp/nntp_destroy.c: implementation.
* mailbox/nntp/nntp_group.c: implementation.
* mailbox/nntp/nntp_head.c: implementation.
* mailbox/nntp/nntp_list_extensions.c: implementation.
* mailbox/nntp/nntp_stat.c: implementation.
* mailbox/nntp/nntp_stream.c: implementation.
* include/mailutils/nntp.h: Declarations.
* include/mailutils/sys/nntp.h: Declarations.
* examples/nntpclient.c: Adjusted.
* examples/pop3client.c: Minor bug fixes.
2004-06-28 Sergey Poznyakoff
* mailbox/filter_iconv.c (internal_icvt_read)
(copy_pass): Fixed mistyped conditions.
* mailbox/include/iterator0.h (struct _iterator): rewritten as
a general-purpose iterator structure.
* include/mailutils/iterator.h (iterator_create): Changed
proto.
(iterator_attach,iterator_detach,iterator_advance)
(iterator_set_first,iterator_set_next)
(iterator_set_getitem,iterator_set_finished_p)
(iterator_set_dup,iterator_set_destroy): New functions.
* mailbox/iterator.c: Likewise
* include/mailutils/list.h (list_get_iterator): New function
* mailbox/list.c: Likewise
* examples/listop.c: Replace iterator_create with
list_get_iterator.
* examples/nntpclient.c: Likewise
* examples/pop3client.c: Likewise
* imap4d/util.c: Likewise
* libsieve/comparator.c: Likewise
* libsieve/prog.c: Likewise
* libsieve/register.c: Likewise
* libsieve/require.c: Likewise
* libsieve/sieve.l: Likewise
* mail/retain.c: Likewise
* mail/util.c: Likewise
* mailbox/filter.c: Likewise
* mailbox/folder.c: Likewise
* mailbox/mailbox.c: Likewise
* mailbox/mailer.c: Likewise
* mailbox/mu_auth.c: Likewise
* mailbox/mutil.c: Likewise
* mailbox/observer.c: Likewise
* mh/ali.c: Likewise
* mh/mh_alias.y: Likewise
* mh/pick.y: Likewise
* mh/refile.c: Likewise
2004-06-27 Sergey Poznyakoff
* direntry: New file
2004-06-27 Sergey Poznyakoff
-= Version 0.5 released =-
2004-06-27 Sergey Poznyakoff
* doc/texinfo/muint.texi: Include version.texi
* NEWS: Updated
* configure.ac: Raised version number to 0.5
* mailbox/memory_stream.c (_memory_write): Minor fix
* mailbox/filter_iconv.c (internal_icvt_read)
(copy_octal): Fixed memory allocation errors.
2004-06-23 Sergey Poznyakoff
* guimb/collect.c (guimb_catch_body): Use scm_c_eval_string
* include/mailutils/guile.h: Provide a definition of
scm_c_eval_string for Guile 1.4x
* include/mailutils/mutil.h: Forward declaration of struct timeval
needed for the prototype of mu_fd_wait().
* libmu_scm/Makefile.am (mailutils.scm): Fixed producing rule.
* libmu_scm/mailutils.scm.in: Added an end-of-file comment
* libmu_scm/mu_mailbox.c: Use SCM_UNSPECIFIED where appropriate.
* libmu_scm/mu_message.c: Likewise.
2204-06-20 Alain Magloire
* examples/nntpclient.c: An example of using nntp.
* mailbox/nntp/nntp_date.c: New file.
* mailbox/nntp/nntp_group.c: New file.
* mailbox/nntp/nntp_last.c: New file.
* mailbox/nntp/nntp_list_extensions.c: New file.
* mailbox/nntp/nntp_mode_reader.c: New file.
* mailbox/nntp/nntp_next.c: New file.
* mailbox/nntp/nntp_quit.c: New file.
* mailbox/nntp/nntp_stat.c: New file.
* mailbox/nntp/Makefile.am
* mailbox/nntp/nntp_article.c: Use new macros.
* mailbox/nntp/nntp_body.c: Use new macros.
* mailbox/nntp/nntp_connect.c: Use new macros.
* mailbox/nntp/nntp_head.c: Use new macros.
* mailbox/nntp/nntp_response.c: Use new macros.
* include/mailutils/nntp.h: New declarations.
* include/mailutils/sys/nntp.h: New declarations and macros..
2204-06-20 Alain Magloire
* mailbox/pop/pop3_lista.c: Destroy the list on error.
* mailbox/pop/pop3_uidla.c: Destroy the list on error.
2004-06-15 Alain Magloire
* mailbox/tcp.c(_tcp_close): Check the return value of close(2).
2004-06-15 Sergey Poznyakoff
* libmu_scm/Makefile.am (mailutils.scm): Fixed producing rule.
2004-06-14 Alain Magloire
* mailbox/nntp/Makefile.am: New file
* mailbox/nntp/nntp_article.c: New file
* mailbox/nntp/nntp_header.c: New file
* mailbox/nntp/nntp_body.c: New file
* include/mailutils/nntp.h: adjustment.
2004-06-12 Alain Magloire
* THANKS: Move part of it to AUTHORS file, reorder alphabetically
* AUTHORS: Reorder alpha.
2004-06-12 Alain Magloire
Putting the framework for NNTP support.
* include/mailutils/nntp.h: New file
* include/mailutils/sys/nntp.h: New file
* mailbox/nntp/nntp_carrier.c: New file
* mailbox/nntp/nntp_connect.c: New file
* mailbox/nntp/nntp_create.c: New file
* mailbox/nntp/nntp_debug.c: New file
* mailbox/nntp/nntp_destroy.c: New file
* mailbox/nntp/nntp_disconnect.c: New file
* mailbox/nntp/nntp_readline.c: New file
* mailbox/nntp/nntp_response.c: New file
* mailbox/nntp/nntp_sendline.c: New file
* mailbox/nntp/nntp_stream.c: New file
* mailbox/nntp/nntp_timeout.c: New file
2004-06-12 Sergey Poznyakoff
* auth/gsasl.c: Revised use of const modifiers
* auth/lbuf.c: Likewise
* auth/lbuf.h: Likewise
* auth/mysql.c: Likewise
* auth/pam.c: Likewise
* auth/pgsql.c: Likewise
* auth/sql.c: Likewise
* auth/tls.c: Likewise
* auth/virtual.c: Likewise
* examples/iconv.c: Likewise
* imap4d/auth_gsasl.c: Likewise
* imap4d/imap4d.c: Likewise
* imap4d/util.c: Likewise
* include/mailutils/mu_auth.h: Likewise
* include/mailutils/mutil.h: Likewise
* include/mailutils/stream.h: Likewise
* libmu_scm/mu_mailbox.c: Likewise
* mailbox/file_stream.c: Likewise
* mailbox/filter_iconv.c: Likewise
* mailbox/mapfile_stream.c: Likewise
* mailbox/mu_auth.c: Likewise
* mailbox/mutil.c: Likewise
* mailbox/stream.c: Likewise
* mailbox/system.c: Likewise
* mailbox/include/stream0.h: Likewise
* mailbox/maildir/maildir.h: Likewise
* mailbox/maildir/mbox.c: Likewise
* mh/mh_format.c: Likewise
* mh/mh_init.c: Likewise
* mh/send.c: Likewise
* pop3d/extra.c: Likewise
* mail/util.c: Commented out unused static functions
* comsat/cfg.c: Likewise
* mail/from.c: Minor fix
* mailbox/daemon.c: Likewise
* mailbox/muerrno.c: Added missing includes
* mailbox/rfc2047.c: Likewise
* mailbox/maildir/folder.c: Likewise
* mailbox/mbox/url.c: Likewise
* mailbox/mh/folder.c: Likewise
* mh/mh.h: Likewise
* mh/mh_alias.l: Likewise
* mh/mh_fmtgram.y: Provide forward declarations for yyerror and
yylex.
* libsieve/sieve.y: Likewise
2004-06-09 Sergey Poznyakoff
* NEWS: Updated
* doc/texinfo/programs.texi: Updated
* include/mailutils/mutil.h (mu_decode_filter): New function
(mu_default_fallback_mode): New variable.
(mu_set_default_fallback): New function.
* mailbox/mutil.c: Likewise
* libmu_scm/Makefile.am: Do not use $< in explicit rules
* mail/util.c (util_setenv): Special handling for decode-fallback
variable
* mail.remote/mail.remote.c: Fixed doc string
* mailbox/mu_auth.c: Add missing gettext markers
* mailbox/rfc2047.c: Use mu_decode_filter.
* mh/mh_global.c (mh_read_profile): Handle new profile
variable "Decode-Fallback".
* pop3d/pop3d.c (options): Fixed typo in doc string
* include/mailutils/stream.h: Forward declaration of struct
timeval is needed for stream_wait().
2004-06-06 Sergey Poznyakoff
* include/mailutils/filter.h (filter_iconv_create): New prototype.
* mailbox/filter_iconv.c: Fixed several bugs. Use an extra
argument to filter_iconv_create to decide what to do
if conversion fails (mu_iconv_fallback_mode).
* examples/iconv.c: Updated call to filter_iconv_create()
* mailbox/rfc2047.c: Likewise.
2004-06-05 Sergey Poznyakoff
* NEWS: Updated
* configure.ac: Check for iconv.h and iconv_t
(MU_COMMON_LIBRARIES): New subst symbol
* comsat/Makefile.am: Use MU_COMMON_LIBRARIES
* dotlock/Makefile.am
* examples/Makefile.am: Likewise.
* frm/Makefile.am: Likewise.
* from/Makefile.am: Likewise.
* guimb/Makefile.am: Likewise.
* imap4d/Makefile.am: Likewise.
* mail/Makefile.am: Likewise.
* mail.local/Makefile.am: Likewise.
* mail.remote/Makefile.am: Likewise.
* mailbox/Makefile.am: Likewise.
* messages/Makefile.am: Likewise.
* mh/Makefile.am: Likewise.
* movemail/Makefile.am: Likewise.
* pop3d/Makefile.am: Likewise.
* readmsg/Makefile.am: Likewise.
* sieve/Makefile.am: Likewise.
* mailbox/file_stream.c (_file_read, _file_readline): Check for
eof.
* mailbox/list.c (list_set_destroy_item): Minor fix
* include/mailutils/errno.h (MU_ERR_BUFSPACE): New error code
* mailbox/muerrno.c: Likewise
* include/mailutils/stream.h (MU_STREAM_STRICT): New flag
* libsieve/extensions/spamd.c: Minor formatting fix
* mailbox/mailutils-config.c (main): add LINK_POSTFLAGS
* mailbox/rfc2047.c: (rfc2047_decode): Implemented charset
recoding using iconv filters.
* mailbox/filter_iconv.c: New file. Implementation of
iconv filter streams.
* examples/iconv.c: New file
* po/POTFILES.in: Updated
2004-06-04 Sergey Poznyakoff
* NEWS: Updated
* examples/pop3client.c: Minor fixes.
* libsieve/extensions/spamd.c: Minor formatting changes
* mailbox/pop/pop3_sendline.c: Bugfix
2004-06-04 Sergey Poznyakoff
Use abstract transport layer in streams, instead of
integer file descriptors. Among other things, this
fixes a long standing bug in imap4d: now it can use
SASL over TLS.
* auth/gsasl.c: Use stream transport instead of fd.
* auth/tls.c: Likewise.
* pop3d/extra.c: Likewise.
* include/mailutils/types.h (mu_transport_t): New data type
* include/mailutils/gsasl.h (gsasl_stream_create): Changed
prototype
* include/mailutils/tls.h (tls_stream_create)
(tls_stream_create_client): Changed prototype
* include/mailutils/mutil.h (mu_fd_wait): New function
* include/mailutils/stream.h (stream_get_fd)
(stream_get_fd2,stream_set_fd): Removed
(stream_get_transport2,stream_get_transport)
(stream_wait,stream_set_get_transport2)
(stream_set_wait): New functions
* mailbox/stream.c: Likewise
* mailbox/include/stream0.h (struct _stream._get_fd): Removed
(_get_transport2,_wait): New methods
* examples/http.c: Use new stream functions
* imap4d/auth_gsasl.c: Likewise
* imap4d/util.c: Likewise
* libsieve/extensions/spamd.c: Likewise
* mailbox/body.c: Likewise
* mailbox/file_stream.c: Likewise
* mailbox/filter.c: Likewise
* mailbox/mapfile_stream.c: Likewise
* mailbox/message.c: Likewise
* mailbox/mime.c: Likewise
* mailbox/mutil.c: Likewise
* mailbox/tcp.c: Likewise
* mailbox/imap/mbox.c: Likewise
* mailbox/mbox/mbox.c: Likewise
* mailbox/pop/mbox.c: Likewise
* mailbox/pop/pop3_readline.c: Likewise
* mailbox/pop/pop3_sendline.c: Likewise
* mh/mhn.c: Likewise
* examples/http.c: Likewise
* imap4d/idle.c: Likewise
* include/mailutils/sys/pop3.h: Likewise
* mail/file.c (mail_file): minor fix
* mailbox/folder.c: minor fix
* mailbox/mailcap.c: minor fix
2004-06-02 Sergey Poznyakoff
* configure.ac: Raised version number to 0.4.90
* NEWS: Likewise
* mailbox/muerrno.c (MU_ERR_CONN_CLOSED,MU_ERR_PARSE):
New error codes.
(MU_ERR_NOENT): New error code. Use it instead
of ENOENT to avoid misguiding diagnostics
'No such file or directory'. Use ENOENT only for its
direct purpose.
* include/mailutils/errno.h: Likewise.
* auth/gsasl.c: Revise the usage of return codes.
* auth/tls.c: Likewise.
* examples/addr.c: Likewise.
* imap4d/namespace.c: Likewise.
* lib/mu_dbm.c: Likewise.
* mail/util.c: Likewise.
* mailbox/address.c: Likewise.
* mailbox/amd.c: Likewise.
* mailbox/attachment.c: Likewise.
* mailbox/attribute.c: Likewise.
* mailbox/auth.c: Likewise.
* mailbox/body.c: Likewise.
* mailbox/debug.c: Likewise.
* mailbox/envelope.c: Likewise.
* mailbox/file_stream.c: Likewise.
* mailbox/filter.c: Likewise.
* mailbox/filter_trans.c: Likewise.
* mailbox/folder.c: Likewise.
* mailbox/header.c: Likewise.
* mailbox/iterator.c: Likewise.
* mailbox/list.c: Likewise.
* mailbox/mailcap.c: Likewise.
* mailbox/mailer.c: Likewise.
* mailbox/mapfile_stream.c: Likewise.
* mailbox/mbx_default.c: Likewise.
* mailbox/memory_stream.c: Likewise.
* mailbox/message.c: Likewise.
* mailbox/mime.c: Likewise.
* mailbox/monitor.c: Likewise.
* mailbox/mu_auth.c: Likewise.
* mailbox/observer.c: Likewise.
* mailbox/property.c: Likewise.
* mailbox/refcount.c: Likewise.
* mailbox/registrar.c: Likewise.
* mailbox/rfc2047.c: Likewise.
* mailbox/sendmail.c: Likewise.
* mailbox/smtp.c: Likewise.
* mailbox/stream.c: Likewise.
* mailbox/tcp.c: Likewise.
* mailbox/ticket.c: Likewise.
* mailbox/url.c: Likewise.
* mailbox/wicket.c: Likewise.
* mailbox/imap/folder.c: Likewise.
* mailbox/imap/mbox.c: Likewise.
* mailbox/mbox/folder.c: Likewise.
* mailbox/mbox/mbox.c: Likewise.
* mailbox/mbox/url.c: Likewise.
* mailbox/pop/mbox.c: Likewise.
* mailbox/pop/pop3_capa.c: Likewise.
* mailbox/pop/pop3_carrier.c: Likewise.
* mailbox/pop/pop3_list.c: Likewise.
* mailbox/pop/pop3_lista.c: Likewise.
* mailbox/pop/pop3_retr.c: Likewise.
* mailbox/pop/pop3_stat.c: Likewise.
* mailbox/pop/pop3_timeout.c: Likewise.
* mailbox/pop/pop3_top.c: Likewise.
* mailbox/pop/pop3_uidl.c: Likewise.
* mailbox/pop/pop3_uidla.c: Likewise.
* mh/mh_ctx.c: Likewise.
2004-06-01 Sergey Poznyakoff
* examples/mailcap.c (main): Bugfix: fields_count had wrong type.
* include/mailutils/mailutils.h: Remove guile.h. (reverses another
part of changes made 2004-01-10).
2004-05-27 Sergey Poznyakoff
* NEWS: Updated
* include/mailutils/filter.h (rfc_2047_Q_filter): New filter
type.
* mailbox/filter.c (mailbox/filter.c): Register rfc_2047_Q_filter
* mailbox/filter_trans.c: New implementation of RFC 2047 "Q" filter.
Reorganized all functions.
* mailbox/rfc2047.c: Correctly decode "Q" encoding.
* mail/send.c (mail_send0): Check ignoreeof variable for
interactive sessions only.
* mailbox/mbox/folder.c: Include mutil.h
2004-05-07 Sergey Poznyakoff
* mail/from.c (mail_from0): Use Date: header if 'datefield' is
set.
* mail/mail.c (main): Start interactive mode with an empty mailbox
if 'emptystart' is set.
* NEWS: Updated
* doc/texinfo/programs.texi (Mail Variables): Documented new
variables.
2004-05-07 Sergey Poznyakoff
* mail/util.c (util_get_sender): Updated to match recent
changes (see the previous entry).
* mailbox/argcv.c (argcv_scan): Honor escaped whitespace.
2004-04-27 Sergey Poznyakoff
* NEWS: Updated
* doc/texinfo/mailutils.texi: Added variable and keyword
index
* doc/texinfo/programs.texi: Documented new features
* doc/texinfo/Makefile.am: Updated
* mail/mail.c (main): Changed initialization sequence.
Set xmailer and default sender fields on startup.
* mail/mail.h (mail_sender,mail_nosender)
(get_sender_address): New functions.
* mail/retain.c: Likewise.
* mail/send.c: Do not add X-Mailer if xmailer variable is
unset.
* mail/table.c (sender,nosender): New commands
* include/mailutils/Makefile.am: Added daemon.h
2004-04-26 Wojciech Polak
Added -P, --pidfile=FILE options for the daemons.
* mailbox/daemon.c: New file. Added pidfile support
and a placeholder for a further universal daemon routines.
* mailbox/mu_argp.c: Added new pidfile option.
* mailbox/Makefile.am: Added daemon.c.
* include/mailutils/daemon.h: New file.
* include/mailutils/argp.h (daemon_param): Added *pidfile.
* pop3d/pop3d.c (main): Call daemon_create_pidfile()
if the -P or --pidfile option was specified.
(daemon_param): Set initial NULL for the pidfile name.
* imap4d/imap4d.c (main): Likewise.
* pop3d/pop3d.h: Include <mailutils/daemon.h>.
* imap4d/imap4d.h: Likewise.
2004-04-14 Sergey Poznyakoff
* mail.remote/mail.remote.c: Use "auth" capability.
* mail.remote/Makefile.am (mail_remote_LDADD): Add @AUTHLIBS@
* mailbox/mu_argp.c (read_rc, mu_create_argcv): Do not bail
out if mu_tilde_expansion() returns NULL. There may be users
without homedir.
* mailbox/mutil.c (mu_get_user_email): Use mu_get_auth_by_uid()
instead of getpwuid().
2004-04-14 Jordi Mallach
* examples/pop3client.c (pop_completion): Use rl_completion_matches.
Fixes potential crash on 64-bit architectures.
2004-04-08 Sergey Poznyakoff
* configure.ac: Add AM_ICONV
* mailbox/smtp.c (smtp_send_message): Correctly handle long
header lines. Fixes bug reported by William MacBain
<macbain@ott-fortimail.dnsalias.org>
* comsat/comsat.c (comsat_main): Make info text clearer.
* sieve/sieve.c (options): Likewise
* frm/frm.c: Likewise
* dotlock/dotlock.c (main): Fixed diagnostics to better suit
i18n.
* guimb/main.c (options): Add translators comment
* libsieve/actions.c: Likewise.
* libsieve/tests.c: Likewise.
* libsieve/comparator.c (sieve_match_part_checker): Likewise.
* mail/if.c (mail_if): Likewise.
* pop3d/popauth.c: Likewise.
* mail.remote/testsuite/mail.remote/send.exp: Updated copyright
date
* mailbox/mutil.c: Add missing gettext marker
* examples/pop3client.c: Rewritten to drop the readline dependency.
2004-02-08 Wojciech Polak
* pop3d/pop3d.c (pop3d_mainloop): Terminate the session
after receiving an illegal TLS packet.
* imap4d/starttls.c (imap4d_starttls): Likewise.
2004-02-08 Wojciech Polak
* doc/texinfo/*: Updated to the current API.
* doc/man/*: Too many outdated stuff... Replaced it
with the "always fresh" man pages ;).
2004-02-05 Sergey Poznyakoff
* include/mailutils/header.h (MU_HEADER_DELIVERY_DATE)
(MU_HEADER_ENVELOPE_TO): New macros.
* mailbox/amd.c (amd_envelope_date): Use Delivery-Date
if X-Envelope-Date is not present.
2004-02-03 Sergey Poznyakoff
* mailbox/maildir/mbox.c (maildir_message_cmp): Compare the
rest of filenames if the timestamps are equal
* mail/if.c (mail_if): 'if t' is true if stdout is connected
to a terminal.
* mailbox/mbox/url.c (_url_path_init): Missed typecast.
2004-02-03 Sergey Poznyakoff
* scripts/texify.sed: New file
* scripts/Makefile.am: Added texify.sed
* doc/texinfo/Makefile.am (.c.inc rule): Use texify.sed
2004-02-03 Linus Nordberg <linus@nordberg.se>
* mailbox/pop/pop3_readline.c: Include sys/time.h.
* mailbox/maildir/mbox.c: Include limits.h.
(maildir_uniq): Use _POSIX_PATH_MAX if PATH_MAX is not
defined.
* mailbox/file_stream.c: Include signal.h.
2004-02-01 Sergey Poznyakoff
* mailbox/maildir/mbox.c (maildir_message_lookup): Fixed bug
(rc could have been used uninitialized). Thanks Wojciech
for noticing
(maildir_scan0): Fixed typo in notification loop.
2004-01-27 Sergey Poznyakoff
* mailbox/smtp.c: Control the value
of READ_RECIPIENTS property to decide whether the message
should be scanned for recipient addresses.
* mailbox/sendmail.c: Likewise.
* mail.remote/mail.remote.c: New option -t (compatible with
sendmail).
Simplified the help message.
(main): Restructured.
* mail.remote/testsuite/mail.remote/send.exp (mail_remote_test):
Added OPTION statement
* mail.remote/testsuite/Data: Added new test.
* mailbox/mailbox.c (mailbox_lock, mailbox_unlock): New
functions.
* include/mailutils/mailbox.h: Likewise
* imap4d/close.c (imap4d_close): Return NO on failure.
* mailbox/include/mailer0.h (struct _mailer): Removed
unused field properties_count.
* TODO: Updated
* NEWS: Updated
2004-01-22 Sergey Poznyakoff
* mailbox/amd.c: Use sorted message array with binary
searches/inserts. This speeds up the mh/maildir
operations considerably. Testing on a MH folder
with 6000 messages shows the following data:
Time of execution
List Array+Bsearch % Speedup (times)
scan 24.795 7.526 30.3 3.294
refile (to) 10.915 0.068 0.6 160.514
rmm 10.893 0.105 1 103.742
* mailbox/include/amd.h: Likewise.
* mailbox/maildir/mbox.c: Likewise.
* mailbox/mh/mbox.c: Likewise.
* imap4d/auth_gss.c: Support for GSS. Submitted by
Simon Josefsson.
* m4/gssapi.m4: Likewise.
2004-01-20 Wojciech Polak
* doc/texinfo/*.texi: Major reorganization in the documentation.
2004-01-19 Wojciech Polak
* libsieve/tests.c (retrieve_header): Unfold the header,
use header_aget_field_value_unfold().
2004-01-15 Sergey Poznyakoff
* imap4d/util.c (util_base64_encode): Bugfix. Patch submitted
by Simon Josefsson.
* imap4d/Makefile.am: Added local folder format support.
* pop3d/Makefile.am: Likewise.
* imap4d/imap4d.c (main): Call mu_register_local_mbox_formats().
* pop3d/pop3d.c: Likewise.
* imap4d/namespace.c (namespace_checkfullpath): Preserve an
eventual URL scheme specification.
Fixed indentation.
* include/mailutils/registrar.h (mu_register_local_mbox_formats)
(mu_register_remote_mbox_formats): New macros.
* mailbox/maildir/mbox.c: Added UID support.
* mailbox/mh/mbox.c (mh_scan0): Removed misleading comment
2004-01-15 Wojciech Polak
* mailbox/mbox/mbox.c: Minor. Use only one printing style
while debugging.
2004-01-14 Sergey Poznyakoff
* mailbox/mbox/mbox.c (mbox_append_message0): Truncate the
stream back to its original size if an error occurred.
* mail.local/main.c (deliver): Likewise.
* frm/frm.c: Minor fix in help output.
* mail/copy.c: Check for error return from mailbox_append_message
* mail/quit.c: Likewise.
* mail/send.c: Likewise.
2004-01-13 Sergey Poznyakoff
* frm/frm.c: Lots of changes for compatibility with ELM.
* frm/testsuite/frm/test.exp: Updated
2004-01-13 Sergey Poznyakoff
Implemented 'file:' URLs
* include/mailutils/registrar.h: Removed file_record
* mailbox/include/registrar0.h: Likewise
* examples/mimetest.c: Likewise
* mailbox/mbox/folder.c: Likewise
* include/mailutils/mutil.h (mu_scheme_autodetect_p): New function
* mailbox/mutil.c: Likewise
* mailbox/amd.c (amd_url_init): Use mu_scheme_autodetect_p().
* mailbox/maildir/folder.c (_maildir_is_scheme): Likewise.
* mailbox/mh/folder.c (_mh_is_scheme): Likewise.
* mailbox/url_file.c: Removed. File not needed anymore.
* mailbox/url_path.c: Likewise.
* mailbox/Makefile.am (url_file.c,url_path.c): Removed
* mailbox/mbox/url.c (_url_path_init): Moved from ../url_path.c
* mailbox/mbox/file.c: Removed. File not needed anymore.
* mailbox/mbox/Makefile.am (file.c): Removed
* frm/frm.c: Improved handling of --select option.
(action): Optimized select condition.
* from/from.c: Include missing headers
2004-01-13 Wojciech Polak
* from/from.c: Use mu_error() where appropriate.
(from_rfc2047_decode): New function.
* messages/messages.c: Use mu_error().
2004-01-12 Wojciech Polak
* frm/frm.c (frm_rfc2047_decode): New function.
(get_personal): Call the frm_rfc2047_decode().
* mail/util.c (util_rfc2047_decode): Test LANG
if LC_ALL is null.
2004-01-12 Sergey Poznyakoff
* include/mailutils/mailutils.h: Removed gsasl.h (reverses part
of changes made 2004-01-10). Reason: unconditional inclusion
causes compilation failure if libgsasl is not installed.
* NEWS: Updated
* mailbox/maildir/maildir.h: New file.
* mailbox/amd.c (amd_url_init): New function
* mailbox/include/amd.h: Likewise.
* mailbox/include/registrar0.h (_url_mh_init,_folder_mh_init)
(_url_maildir_init,_folder_maildir_init): Removed.
* mailbox/maildir/url.c: Removed.
* mailbox/maildir/maildir.h: New file
* mailbox/maildir/folder.c: Auto-detection of maildir format.
* mailbox/maildir/mbox.c (mkfilename): Renamed to
maildir_mkfilename. Made external.
* mailbox/maildir/Makefile.am: Removed url.c, added maildir.h
* mailbox/mbox/folder.c (_path_is_scheme): New
function. Implements auto-detection for the "path" scheme.
* mailbox/mh/url.c: Removed
* mailbox/mh/Makefile.am: Removed url.c
* mailbox/mh/folder.c: Auto-detection of MH format.
* mailbox/url.c: Fixed indentation
* frm/frm.c: Minor changes.
2004-01-11 Sergey Poznyakoff
* mailbox/amd.c (amd_open,amd_close): Bugfix
2004-01-11 Wojciech Polak
* libmu_scm/mailutils.scm.in (mu-libs): Added libmu_maildir.
2004-01-11 Wojciech Polak
* readmsg/readmsg.c (main): Use mu_register_all_mbox_formats().
* guimb/main.c (main): Use mu_register_all_formats().
* scripts/mailutils.spec.in: Updated.
* include/mailutils/Makefile.am: Added missing refcount.h.
2004-01-10 Wojciech Polak
* include/mailutils/mailutils.h: Added missing header files.
* include/mailutils/gsasl.h: Include <gsasl.h>.
* messages/messages.c (main): Use mu_register_all_mbox_formats().
(messages_count): Improved diagnostics.
* messages/Makefile.am: Updated.
* frm/frm.c (main): Unified diagnostic messages.
* frm/Makefile.am: Updated.
2004-01-09 Sergey Poznyakoff
* NEWS: Documented new features.
2004-01-08 Sergey Poznyakoff
* configure.ac (LIBMU_SCM_DEPS): Added maildir
* mailbox/amd.c: New file. Abstract mail directory level.
* mailbox/Makefile.am: Added amd.c
* mailbox/include/amd.h: New file.
* mailbox/include/Makefile.am: Added amd.h
* mailbox/maildir/mbox.c: Implemented
* mailbox/maildir/folder.c: New file
* mailbox/maildir/url.c: New file
* mailbox/maildir/Makefile.am: Added folder.c and url.c
* mailbox/mh/mbox.c: Re-implemented via AMD.
* mailbox/include/registrar0.h: Added maildir support
* libmu_scm/mu_scm.c: Likewise.
* mailbox/mu_argp.c: Likewise.
* include/mailutils/registrar.h (mu_register_all_mbox_formats)
(mu_register_all_mailer_formats,mu_register_all_formats): New
macros.
* frm/frm.c (main): Use mu_register_all_mbox_formats
* from/from.c: Likewise.
* movemail/movemail.c: Likewise.
* mail/mail.c (main): Use mu_register_all_formats
* sieve/sieve.c: Likewise
* mh/mh_init.c (mh_init): Likewise
* lib/Makefile.am: Minor formatting change
* messages/messages.c: Likewise
* pop3d/pop3d.h (pop3d_mark_retr,pop3d_is_retr)
(pop3d_unmark_retr): Added external declarations.
2004-01-06 Sergey Poznyakoff
* m4/Makefile.am: Removed.
* m4/.cvsignore: Updated
* configure.ac: Removed m4/Makefile.am
* Makefile.am: Removed m4
2004-01-05 Sergey Poznyakoff
* include/mailutils/mutil.h (mu_true_answer_p): New function.
* mailbox/mutil.c: Likewise
* mail/var.c: (parse_headers): Use mu_true_answer_p()
* mh/mh.h (is_true): Likewise.
* mh/mh_init.c (mh_vgetyn): Likewise.
* sieve/sieve.c (is_true_p): Likewise.
* movemail/movemail.c (move_message): Improved diagnostics
* libsieve/runtime.c (instr_run): Adjust pc before calling handler.
* libsieve/actions.c (sieve_action_stop); Restored zero assignment
to pc. This is possible due to the changes to runtime.c
2004-01-05 Sergey Poznyakoff
* include/mailutils/libsieve.h (sieve_locus_t): New datatype.
(sieve_action_log_t): Changed type of the second argument.
* libsieve/actions.c (sieve_action_stop): Bugfix. Account for
-4 offset.
* libsieve/comparator.c (sieve_match_part_checker): Use
extended regular expressions by default.
* libsieve/prog.c (sieve_code_source,sieve_code_line): New
functions.
(sieve_code_action,sieve_code_test): Include line info before
coding the instruction.
* libsieve/runtime.c (instr_source,instr_line)
(sieve_get_locus): New functions
* libsieve/sieve.h (sieve_op_t.line): New member
* libsieve/sieve.l (push_source,pop_source): Include line info
* libsieve/sieve.y (sieve_machine_destroy)
(sieve_machine_begin): Initialize and destroy source_list
* libsieve/util.c (sieve_log_action): Updated call to
mach->logger.
* libsieve/tests.c: Improved debugging messages
* libsieve/extensions/list.c: Likewise.
* libsieve/extensions/spamd.c: Likewise.
* libsieve/extensions/timestamp.c: Likewise.
* examples/numaddr.c: Likewise.
* mail.local/main.c: Brought in sync with recent changes to
libsieve
* sieve/sieve.c: Likewise.
* sieve/testsuite/lib/sieve.exp: Default to --line-info=no
* include/mailutils/list.h (list_locate): New function
* mailbox/list.c: Likewise
2004-01-04 Wojciech Polak
* mail/send.c (mail_send): Bugfix. Removed free(p)
and prevent from later segmentation fault.
2004-01-03 Wojciech Polak
* auth/tls.c (generate_dh_params): Adapt to GnuTLS >= 1.0.0.
* po/POTFILES.in: Added movemail/movemail.c
2004-01-03 Sergey Poznyakoff
* guimb/scm/sieve.scm.in (sieve-version): New function. Supports
the required --version option.
2004-01-03 Sergey Poznyakoff
* configure.ac: Fixed INTLINCS
* examples/Makefile.am: Reverted to mod_LTLIBRARY for
numaddr.la
* libmu_scm/Makefile.am: Removed a too general implicit rule.
It caused config.h to be rebuilt incorrectly.
2004-01-02 Wojciech Polak
Happy GNU Year! :)
* libsieve/extensions: New directory.
* libsieve/extensions/Makefile.am: New file.
* libsieve/Makefile.am: Added `SUBDIRS = . extensions'.
* examples/timestamp.c: Moved to ../libsieve/extensions/
* examples/list.c: Likewise.
* examples/spamd.c: Likewise.
* examples/Makefile.am: Updated.
Added `noinst_LTLIBRARIES = numaddr.la'.
* configure.ac (AC_PREREQ): Bump to 2.59.
(AC_CONFIG_FILES): Added libsieve/extensions/Makefile.
* Makefile.am: Require at least version 1.8.
2003-12-30 Sergey Poznyakoff
* examples/spamd.c (spamd_test): Use EUID to determine
user's identity.
* movemail/movemail.c: Allow to use traditional Emacs
invocation (password as the last argument) with usual
Mailutils URLs.
2003-12-30 Sergey Poznyakoff
* examples/murun.c: Close output stream
* include/mailutils/locker.h (enum mu_locker_set_mode): New
data type
(locker_set_default_flags): Changed declaration
(locker_set_default_retry_timeout)
(locker_set_default_retry_count)
(locker_set_default_expire_timeout)
(locker_set_default_external_program): New functions
* mailbox/locker.c: Likewise
* mailbox/mu_argp.c: New locker options
* mail.local/main.c: Adapt for new locker functions.
* mailbox/file_stream.c (prog_stream_wait,start_program_filter)
(_prog_close,_prog_open): Bugfixes
* mh/mhl.c: Minor fix
* movemail/movemail.c: --keep-messages option (an alias for -p)
2003-12-29 Sergey Poznyakoff
* comsat/comsat.c (main): Minor fix (do not use hardcoded
log facility)
* mail.local/main.c: New option --message-id-header
* imap4d/imap4d.c: Fixed first argument to socket (Thanks
Daniel Dehennin <nebuchadnezzar@nerim.net> for reporting)
* mailbox/tcp.c: Likewise
* pop3d/pop3d.c: Likewise
* mailbox/mu_argp.c: Minor style fix
2003-12-28 Jeff Bailey <jbailey@nisa.net>
* doc/texinfo/Makefile.am: Use ../$(srcdir) instead of .. to
support srcdir != builddir invocations of make html.
* doc/texinfo/programs.texi: Provide sample invocation of
mail.local. Include note about virtual hosting.
2003-12-28 Sergey Poznyakoff
* movemail/movemail.c: Minor changes for compatibility with
the Emacs implementation.
2003-12-28 Sergey Poznyakoff
* movemail: New directory
* movemail/movemail.c: New file
* movemail/Makefile.am: New file
* movemail/.cvsignore: New file
* Makefile.am: Added movemail
* configure.ac: Likewise
* examples/spamd.c: Minor changes
* examples/list.c: Minor changes
2003-12-26 Sergey Poznyakoff
* COPYING: New file
* COPYING.LIB: Renamed to
* COPYING.LESSER: this
* Makefile.am: Updated
* README: Updated
* autogen.sh: Updated
* configure.ac: Fixes to work with automake 1.8/autoconf 2.59
* m4/db2.m4: Likewise
* m4/debug.m4: Likewise
* m4/getopt.m4: Likewise
* m4/gsasl.m4: Likewise
* m4/gssapi.m4: Likewise
* m4/guile.m4: Likewise
* m4/lib.m4: Likewise
* m4/mu_libobj.m4: Likewise
* m4/tls.m4: Likewise
* doc/texinfo/body.texi: Minor fixes.
* doc/texinfo/libsieve.texi: Likewise
2003-12-26 Sergey Poznyakoff
* examples/list.c: New sieve extension test.
* examples/spamd.c: Modified.
* examples/Makefile.am: Added list.c
* dotlock/dotlock.c: Changed multiline doc string to
a single-line one: gettext 0.13 is unable to handle
translator comments with multiline msgids.
* mail.local/main.c: Likewise
* mail.remote/mail.remote.c: Likewise
* mh/anno.c: Likewise
* mh/fmtcheck.c: Likewise
* mh/folder.c: Likewise
* mh/forw.c: Likewise
* mh/inc.c: Likewise
* mh/install-mh.c: Likewise
* mh/mark.c: Likewise
* mh/mhl.c: Likewise
* mh/mhn.c: Likewise
* mh/mhpath.c: Likewise
* mh/pick.c: Likewise
* mh/refile.c: Likewise
* mh/repl.c: Likewise
* mh/rmf.c: Likewise
* mh/rmm.c: Likewise
* mh/scan.c: Likewise
* mh/send.c: Likewise
* mh/whom.c: Likewise
* sieve/sieve.c: Likewise
2003-12-25 Sergey Poznyakoff
Added changes from the backup repository
2003-12-24 Sergey Poznyakoff
* examples/spamd.c: New file.
* examples/Makefile.am: Added spamd.c
* include/mailutils/libsieve.h (sieve_match_part_checker):
Prototype.
2003-12-23 Sergey Poznyakoff
* examples/pop3client.c: Added typecasts
* include/mailutils/errno.h: New error codes
* mailbox/muerrno.c: Likewise
* mail.remote/testsuite/Data: Updated to synchronize
with the changes dated 2003-12-04
* mailbox/file_stream.c: Rewritten support for program
streams.
(filter_prog_stream_create): New function.
* include/mailutils/stream.h (filter_prog_stream_create): New
function.
* examples/murun.c: New file
* examples/Makefile.am: Added murun.c
2003-12-17 Wojciech Polak
* configure.ac: Set AM_GNU_GETTEXT_VERSION(0.13).
* m4/Makefile.am: Updated (gettext 0.13).
2003-12-17 Sergey Poznyakoff
* dotlock/dotlock.c: Added translators' comment
* mail.local/main.c: Likewise
* mail.remote/mail.remote.c: Likewise
* mh/anno.c: Likewise
* mh/fmtcheck.c: Likewise
* mh/folder.c: Likewise
* mh/forw.c: Likewise
* mh/inc.c: Likewise
* mh/install-mh.c: Likewise
* mh/mark.c: Likewise
* mh/mhl.c: Likewise
* mh/mhn.c: Likewise
* mh/mhpath.c: Likewise
* mh/pick.c: Likewise
* mh/refile.c: Likewise
* mh/repl.c: Likewise
* mh/rmf.c: Likewise
* mh/rmm.c: Likewise
* mh/scan.c: Likewise
* mh/send.c: Likewise
* mh/whom.c: Likewise
* sieve/sieve.c: Likewise
2003-12-12 Sergey Poznyakoff
Temporarily switched to the back-up repository
on mirddin. Change map:
Date from Date to Repository
======== ======= ==========
1999-09-10 2003-12-01 Savannah
2003-12-04 2003-12-25 Mirddin
2003-12-05 Sergey Poznyakoff
* mailbox/imap/mbox.c (mailbox_imap_open): Bugfix. Thanks
Stephen Bylo <Stephen.Bylo@radixs.com> for reporting.
2003-12-04 Sergey Poznyakoff
* mh/mhn.c (stream_getline): Bugfix
* mailbox/parse822.c (parse822_route_addr): Handle empty
addresses. Patch provided by Rob Casey <rob.casey@bluebottle.com>
* mailbox/smtp.c (smtp_send_message): Send sender and recipient
addresses enclosed in angle brackets.
* mailbox/testsuite/Addrs: Fixed null address test.
2003-12-01 Sergey Poznyakoff
* mailbox/sendmail.c (sendmail_send_message): Don't
close the descriptor if it happens to make a part of tunnel
pipe.
2003-11-28 Sergey Poznyakoff
* mailbox/argcv.c (argcv_escape_char,escape_copy): Bugfix
2003-11-04 Sergey Poznyakoff
* mh/anno.c (main): Remove trailing colon from the component name.
2003-11-04 Sergey Poznyakoff
* mailbox/rfc2047.c (rfc2047_decode): Bugfix.
* mh/mh_argp.c (mh_argp_parse): Changed prototype.
* mh/mh_getopt.h: Likewise.
* mh/ali.c: Updated calls to mh_argp_parse()
* mh/anno.c: Likewise.
* mh/comp.c: Likewise.
* mh/fmtcheck.c: Likewise.
* mh/folder.c: Likewise.
* mh/forw.c: Likewise.
* mh/inc.c: Likewise.
* mh/install-mh.c: Likewise.
* mh/mark.c: Likewise.
* mh/mhl.c: Likewise.
* mh/mhn.c: Likewise.
* mh/mhparam.c: Likewise.
* mh/mhpath.c: Likewise.
* mh/pick.c: Likewise.
* mh/refile.c: Likewise.
* mh/repl.c: Likewise.
* mh/rmf.c: Likewise.
* mh/rmm.c: Likewise.
* mh/scan.c: Likewise.
* mh/send.c: Likewise.
* mh/sortm.c: Likewise.
* mh/whatnow.c: Likewise.
* mh/whom.c: Likewise.
2003-11-04 Sergey Poznyakoff
* mailbox/parse822.c: Be more liberal in parsing
local parts.
* mh/ali.c (getcols): Return default of 80 columns if
both ioctl() and getenv() fail.
(ali_print_name_list): Bugfix.
(main): In -user mode, print the argument verbatim if it
is not a member of any alias.
* mh/mh_alias.l (pop_source): Always free ali_filename.
Grammar: Bugfixes.
(mh_alias_read): Provide a debugging hook
(ali_verbatim): New function.
* mh/mh_alias.y: Fixed grammar.
(ali_member): Compare addresses if strcmp() fails.
* mh/mh.h (ali_verbatim): New function.
* examples/pop3client.c: Added missing includes
2003-10-28 Sergey Poznyakoff
* mail/mail.c: Implemented -a (--append) option.
* mail/mail.h (mail_sendheader,send_append_header)
(send_append_header2): New functions.
* mail/send.c: Likewise.
* mail/table.c: New command "sendheader"
2003-10-27 Alain Magloire
* mailbox/mapfile_stream.c(_mapfile_size): Only call msync() if
the file was also open with PROT_WRITE.
(_mapfile_flush): Ditto.
2003-10-25 Sergey Poznyakoff
* mailbox/list.c (list_do): Bugfix
2003-10-24 Sergey Poznyakoff
* mailbox/list.c (list_do): Rewritten using iterators.
* mh/mh_alias.l: Resolve a conflict between the angle bracket
indicating file inclusion and the one starting a valid
RFC822 address.
* mh/mh_alias.y: Allow for full RFC822 addresses.
2003-10-18 Sergey Poznyakoff
* pop3d/quit.c (pop3d_fix_mark): Use only valid C comments.
Fixed erroneous format specification.
Format X-Expire-Timestamp value only if necessary.
* pop3d/pop3d.c (options): Minor fix in help line wording.
(pop3d_parse_opt): Fixed duplicate case.
* pop3d/capa.c: Indicate login-delay capability.
* pop3d/logindelay.c (login_delay_capa): New function.
* pop3d/pop3d.h: Likewise.
2003-10-17 Alain Magloire
First try of implementing CAPA EXPIRE in pop3d.
* pop3d/expire.c: New file.
* pop3d/pop3d.c: New options --expire, expire new global variable.
* pop3d/quit.c (pop3d_fix_mark): Set the X-Expire-Timestamp for
RETR messages.
* pop3d/capa.c: Advertise EXPIRE.
* pop3d/pop3d.h: Declaration of global variable expire.
* pop3d/retr.c: Set a flag on downloaded messages.
2003-10-17 Sergey Poznyakoff
* mailbox2: It is hopelessly obsolete. Removed. We'd better modify
the files "in situ".
2003-10-17 Sergey Poznyakoff
* doc/texinfo/programs.texi (pop3d): Documented new option.
* examples/timestamp.c: New file. Implements sieve extension
test "timestamp".
* examples/Makefile.am: Added timestamp.c
2003-10-13 Sergey Poznyakoff
* NEWS: Updated
* pop3d/logindelay.c: Couple of bugfixes.
* pop3d/popauth.c (options): New option --permissions allows to
override default permissions on the database file.
2003-10-11 Sergey Poznyakoff
* pop3d/logindelay.c: New file
* pop3d/Makefile.am: Added logindelay.c
* pop3d/pop3d.c: New options --login-delay, --stat-file
* pop3d/pop3d.h (check_login_delay,update_login_delay): New
functions.
* pop3d/quit.c (pop3d_quit): Call update_login_delay().
* pop3d/user.c (pop3d_user): Call check_login_delay().
* mh/mh_format.c (builtin_formataddr): Fixed checking for duplicate
addresses.
2003-10-10 Alain Magloire
GNU Mailutils 0.4 was released. New code added.
* configure.ac: Added include/mailutils/sys/Makefile.
* mailbox/pop/Makefile.am (libmu_pop_la_sources): Added all the
pop3_*.c code now part of libmu_pop.a
* include/mailutils/Makefile.am (pkginclude_HEADERS): Added file
pop3d.h
(SUBDIRS): New directory sys added.
* include/mailutils/sys/Makefile.am: new Makefile.am
* example/Makefile.am: pop3client.c Added.
* doc/rfc/rfc3206.txt: New publish RFC for POP3
2003-10-10 Alain Magloire
* mailbox/pop/pop3_readline.c (pop3_getline): Use
stream_sequential_readline() instead of stream_readline() and do
not maintain any offsets.
* include/mailutils/sys/pop3d.h (struct mu_pop3_work_buf): Remove
of the offset field.
* examples/pop3client.c: Changes to check for errors.
2003-10-10 Sergey Poznyakoff
* configure.ac: Raised patchlevel number
* mail/print.c (mail_print): Pass MSG_SILENT flag.
* pop3d/pop3d.c: New option --undelete tells pop3d to
undelete all delete messages on startup.
* pop3d/user.c: Handle undelete_on_startup flag.
* pop3d/extra.c (pop3d_mark_deleted,pop3d_is_deleted)
(pop3d_unset_deleted,pop3d_undelete_all): New functions
* pop3d/pop3d.h: Likewise.
* pop3d/dele.c: Use new pop3d_.*_deleted calls.
* pop3d/list.c: Likewise.
* pop3d/quit.c: Likewise.
* pop3d/retr.c: Likewise.
* pop3d/rset.c: Likewise.
* pop3d/stat.c: Likewise.
* pop3d/top.c: Likewise.
* pop3d/uidl.c: Likewise.
2003-10-09 Alain Magloire
Possible use:
list_count (list, &total);
array = malloc (total *(sizeof *array));
if (users != NULL)
list_to_array (list, users, total, &total);
copy in the array the number of items.
* mailbox/list.c (list_to_array): New function.
* include/mailutils/list.h (list_to_array): Declaration.
2003-10-09 Alain Magloire
Scenario: the attribute_set_delete() use the header field
"Status: d" to store the information. During a POP session,
if messages had the "Status: D", the messages would be
deleted during the update state(QUIT), not what is expected.
Only messages mark deleted with the command DELE, should be deleted.
Sergey proposed an implementation, using attribute_xxx_userflag()
instead for delete markers.
* pop3d/dele.c: Use for attribute_is_userflag()
* pop3d/list.c: Use for attribute_is_userflag()
* pop3d/retr.c: Use for attribute_is_userflag()
* pop3d/rset.c: Use for attribute_is_userflag()
* pop3d/top.c: Use for attribute_is_userflag()
* pop3d/uidl.c: Use for attribute_is_userflag()
* pop3d/pop3d.h (POP3_ATTRIBUTE_DELE): New define.
* pop3d/quit.c (pop3d_fix_mark): Use for attribute_is_userflag()
(pop3d_quit): Call to pop3d_fix_mark.
2003-10-07 Alain Magloire
Reuse the mailutils mu_debug_t object to do debug tracing
no need to reinvent another scheme.
* include/mailutils/pop3.h: New declaration mu_pop3_set_debug.
* include/mailutils/sys/pop3.h: new field mu_debug_t in structure.
* mailbox/pop/pop3_debug.c: Use of mu_debug_t object.
* examples/pop3client.c: Fix SIGSEGV and print error messages.
2003-10-06 Alain Magloire
* mailbox/pop/pop3_stls.c: New file.
* mailbox/pop/pop3_pass.c: Obscure the buffer with the passwd for
security reasons.
* mailbox/pop/pop3_apop.c: Obscure the buffer with the digest for
security reasons.
* include/mailutils/pop3.h: Declaration mu_pop3_stls().
* include/mailutils/sys/pop3.h: New states added to accommodate STLS
command.
* doc/texinfo/pop3.texi: Corrected some typos.
2003-10-06 Sergey Poznyakoff
* configure.ac: Raised version number to 0.4
* lib/getopt.c: Moved to ...
* mailbox/getopt.c: ... here
* lib/getopt1.c: Moved to ...
* mailbox/getopt1.c: ... here
* lib/Makefile.am: Removed getopt.
* mailbox/Makefile.am: Added getopt.
* m4/getopt.m4: New file
* m4/mu_libobj.m4 (MU_HEADER): Prevent multiple inclusions.
* m4/Makefile.am: Added getopt.m4
* imap4d/imap4d.h: Added missing includes
* mail/mail.h: Likewise
* mail/util.c: Likewise
* mailbox/ticket.c: Likewise
* auth/tls.c: Likewise
* from/from.c: Likewise
* readmsg/readmsg.c: Likewise
* readmsg/readmsg.h: Likewise
* mail/decode.c (display_message): Bugfix
* mailbox/locale.c (mu_charset_lookup): Bugfix
* mailbox/mailutils-config.c: Minor fix in the help string.
* mh/repl.c: Likewise.
* mh/mh.h (mh_format_str): Added prototype.
* NEWS: Updated
2003-10-05 Alain Magloire
* examples/pop3client.c: A simple example illustrating the use
of the low level POP3 function calls.
2003-10-05 Alain Magloire
Implementation of the lower level functions for POP3 in a separate
library.
This the first draft, the code is not yet enabled in the Makefile.am
* mailbox/pop/pop3_apop.c: APOP
* mailbox/pop/pop3_capa.c: CAPA
* mailbox/pop/pop3_carrier.c: TCP stream.
* mailbox/pop/pop3_connect.c:
* mailbox/pop/pop3_create.c:
* mailbox/pop/pop3_debug.c:
* mailbox/pop/pop3_dele.c: DELE
* mailbox/pop/pop3_destroy.c:
* mailbox/pop/pop3_disconnect.c:
* mailbox/pop/pop3_lista.c: LIST
* mailbox/pop/pop3_list.c: LIST
* mailbox/pop/pop3_noop.c: NOOP
* mailbox/pop/pop3_pass.c: PASS
* mailbox/pop/pop3_quit.c: QUIT
* mailbox/pop/pop3_readline.c:
* mailbox/pop/pop3_response.c:
* mailbox/pop/pop3_retr.c: RETR
* mailbox/pop/pop3_rset.c: RSET
* mailbox/pop/pop3_sendline.c:
* mailbox/pop/pop3_stat.c: STAT
* mailbox/pop/pop3_stream.c:
* mailbox/pop/pop3_timeout.c:
* mailbox/pop/pop3_top.c: TOP
* mailbox/pop/pop3_uidl.c: UIDL
* mailbox/pop/pop3_uidla.c: UIDL
* mailbox/pop/pop3_user.c: USER
* include/mailutils/pop3.h: Declaration of the public functions.
* include/mailutils/sys/pop3.h: Declaration of the internal
functions and structures.
* doc/texinfo/pop3.texi: updated.
2003-10-05 Alain Magloire
When list_destroy() is called, we need to provide also
a way to free the item is necessary. To do this we added a new
function:
extern int list_set_destroy_item __P ((list_t list,
void (*destroy_item) __P((void *))));
This function let us register a function to call on the item
when the list is being destroy.
Unresolved Problems: What about list_remove() and list_replace() ?
should destroy_item() be called when the item is no longer in the
list ?
* mailbox/list.c (list_destroy) : Call to list->destroy_item() when
the data is free().
(list_set_destroy_item): New function.
* mailbox/include/list0.h (destroy_item): New field in the structure.
* include/mailutils/list.h (list_set_destroy_item): New declaration.
2003-09-27 Wojciech Polak
* mailutils.spec.in: Updated and moved to ...
* scripts/mailutils.spec.in: ... here.
* scripts/Makefile.am: Updated.
* configure.ac: Likewise.
* Makefile.am: Likewise.
2003-09-27 Sergey Poznyakoff
* configure.ac: Moved fgetpwent from AC_CHECK_FUNCS to
MU_CHECK_FUNCS.
* lib/Makefile.am: Removed fgetpwent.c
* mailbox/Makefile.am: Added fgetpwent.c
* lib/fgetpwent.c: Moved to ...
* mailbox/fgetpwent.c: ... here
* imap4d/imap4d.h: Added missing include
* imap4d/search.c (imap4d_search0): Use case-insensitive
comparison
* imap4d/status.c (status_get_handler): Likewise
* imap4d/util.c: Fixed wording of the comment.
* mailbox/locker.c (_locker_destroy_private): Bugfix
2003-09-25 Sergey Poznyakoff
* mailbox/munre.c (munre_set_regex): Bugfix again.
* mailbox/filter_trans.c (qp_decode): Bugfix. According
to RFC, underscore represents space.
* mailbox/rfc2047.c (rfc2047_decode): Ignore whitespace between
the encoded segments.
* mailbox/testsuite/RFC2047: Reflect the recent changes.
* NEWS: Updated
* mail/mail.h (mail_nounfold,mail_unfold)
(mail_header_is_unfoldable): New functions.
* mail/print.c (mail_print_msg): Unfold the header value, if
required.
* mail/retain.c: Rewritten.
(mail_nounfold,mail_unfold)
(mail_header_is_unfoldable): New functions.
* mail/table.c: Added new command words.
* mail/mail.c: Default to "unfold subject"
* mail/util.c (util_slist_remove): New function.
* auth/lbuf.c: Added missing includes.
* auth/lbuf.h: Likewise.
2003-09-22 Sergey Poznyakoff
* mailbox/munre.c (munre_set_regex): Bugfix.
* mh/replgroupcomps: Added trailing newline
2003-09-21 Sergey Poznyakoff
Added decoding of RFC 2047 headers to MUA programs (mail and mh).
Fixed incorrect session termination in imap and pop clients.
* mailbox/locale.c: New file. Contains locale-dependent functions.
* mailbox/Makefile.am: Added locale.c
* include/mailutils/mutil.h (mu_charset_lookup): New function.
* mail/from.c (mail_from0): Use util_rfc2047_decode for
"From" and "Subject" headers.
* mail/mail.c (main): Set default value for the "charset" variable.
* mail/mail.h (util_rfc2047_decode): New function.
* mail/util.c: Likewise.
* mail/print.c: Use util_rfc2047_decode for printing headers.
* doc/texinfo/programs.texi: Documented "charset" mail
variable
* mh/mh_format.c (mh_format): Use header_aget_value_unfold when
retrieving the header value.
(builtin_decode): New function. Implements (decode).
* mh/README: Updated
* mailbox/imap/folder.c (authenticate_imap_sasl_anon): Fixed typo
in debug output.
(folder_imap_open): Issue LOGOUT if all the authentication methods
have failed.
* mailbox/imap/mbox.c (imap_get_fd): Removed. Use imap_get_fd2
instead.
* mailbox/pop/mbox.c (_pop_user): Do not close the stream on
authentication failures.
* imap4d/login.c: Minor fix
2003-09-20 Sergey Poznyakoff
Install under mailutils/gnu only those headers which are
missing on the system.
Include regex to libmailbox if the system's libc lacks it.
Add new functions for handling reply subject headers.
* Makefile.am: Added headers
* m4/mu_libobj.m4 (MU_HEADER,MU_FINISH_LINKS): New macros
* configure.ac: Use MU_HEADER and MU_FINISH_LINKS where needed
* m4/regex.m4: Likewise
* dotlock/Makefile.am: Fixed INCLUDES
* lib/Makefile.am: Updated
* mailbox/Makefile.am: Likewise.
* examples/Makefile.am: Likewise.
* frm/Makefile.am: Likewise.
* guimb/Makefile.am: Likewise.
* imap4d/Makefile.am: Likewise.
* include/mailutils/gnu/Makefile.am: Likewise.
* libsieve/Makefile.am: Likewise.
* mail/Makefile.am: Likewise.
* mail.local/Makefile.am: Likewise.
* mail.remote/Makefile.am: Likewise.
* mailbox/imap/Makefile.am: Likewise.
* mailbox/maildir/Makefile.am: Likewise.
* mailbox/mbox/Makefile.am: Likewise.
* mailbox/mh/Makefile.am: Likewise.
* mailbox/pop/Makefile.am: Likewise.
* messages/Makefile.am: Likewise.
* mh/Makefile.am: Likewise.
* pop3d/Makefile.am: Likewise.
* readmsg/Makefile.am: Likewise.
* sieve/Makefile.am: Likewise.
* from/Makefile.am: Likewise.
* comsat/Makefile.am: Likewise.
* auth/Makefile.am: Likewise.
* headers: New directory
* headers/Makefile.am: New file
* headers/posix/Makefile.am: New file
* include/mailutils/gnu/argp.h: Moved to ...
* headers/argp.h: ... here
* include/mailutils/gnu/getopt.h: Moved to ...
* headers/getopt.h: ... here
* lib/regex.h: Moved to ...
* headers/regex.h: ... here
* lib/posix/regex.h: Moved to ...
* headers/posix/regex.h: ... here
* lib/posix/Makefile.am: Removed
* lib/posix/.cvsignore: Removed
* lib/posix: Removed
* lib/regex.c: Moved to ...
* mailbox/regex.c: ... here
* include/mailutils/gnu/.cvsignore: Updated
* mailbox/munre.c: New file
* include/mailutils/mutil.h (munre_set_regex)
(munre_subject): New functions.
* mail/followup.c: Use munre_subject() and util_reply_prefix().
* mail/reply.c: Likewise
* mail/mail.c (struct argp_option options): Removed irrelevant
OPTION_DOC.
(main): Set default replyprefix
* mail/mail.h (util_reply_prefix): New function
* mail/util.c: Likewise
(util_setenv): A hack to properly handle "replyregex".
* mail/var.c (run_editor): Fixed return type.
* mh/mh_format.c (builtin_unre): Use munre_subject()
(builtin_isreply,builtin_reply_regex): New functions
* mh/mh.h (mh_set_reply_regex): New function.
* mh/mh_init.c: Likewise.
* mh/mh_global.c (mh_read_profile): Read Reply-Regex
* mh/README: Updated
* mh/replcomps: Updated
* mh/replgroupcomps: Updated
* doc/texinfo/programs.texi: Updated
2003-09-18 Sergey Poznyakoff
* mailbox/mh/mbox.c (_mh_message_delete): Zero out the
msg_pool slot occupied by the message being deleted.
(mh_pool_lookup): On success return the address of the
msg_pool slot.
* pop3d/pop3d.h (process_cleanup): New function
* pop3d/signal.c: Likewise
* pop3d/pop3d.c (pop3d_daemon): Collect finished children
synchronously.
2003-09-16 Sergey Poznyakoff
* mh/repl.c (opt_handler): Force RCPT_ALL if --group is given.
2003-09-11 Sergey Poznyakoff
* mailbox/imap/folder.c (authenticate_imap_login): Do not
close the stream on authentication failures.
(authenticate_imap_select): Bugfix
(imap_parse): Use MU_ERR_AUTH_FAILURE where appropriate.
* doc/texinfo/programs.texi: Updated
2003-09-10 Sergey Poznyakoff
* include/mailutils/errno.h (MU_ERR_BAD_AUTH_SCHEME)
(MU_ERR_AUTH_FAILURE): New error codes.
* mailbox/muerrno.c: Likewise.
* mailbox/include/auth0.h (struct _authority): Keep a list
of authentication methods.
* mailbox/auth.c (authority_authenticate): Authentication
methods are now stored as a list.
* mailbox/mailbox.c (mailbox_create): Bugfix. Return failure
if the folder cannot be created.
* mailbox/imap/folder.c: Allow user to specify several possible
authentication methods after AUTH= (an extension to RFC 2192).
(folder_imap_get_authority): Select an appropriate authentication
mechanism if AUTH=*, as suggested by RFC.
* mailbox/pop/folder.c (folder_pop_get_authority): Return
an appropriate error code.
* mh/rmf.c (rmf): Bugfix.
2003-09-10 Sergey Poznyakoff
* mailbox/imap/folder.c (read_capa): New function.
(check_capa): Call read_capa.
(authenticate_imap_login): Check for LOGINDISABLED.
(tls): Reread the capabilities after successful TLS
negotiation.
2003-09-09 Sergey Poznyakoff
* include/mailutils/address.h (address_aget_personal): Added
missing prototype.
2003-09-05 Wojciech Polak
* mailbox/wicket.c: Moved stat() (checking the file
permissions) to wicket_create().
* sieve/sieve.c (tickets_default): New variable.
(main): Check the tickets_default.
2003-09-05 Sergey Poznyakoff
* lib/mu_dbm.c (mu_fcheck_perm, mu_check_perm): Return
MU_ERR_UNSAFE_PERMS when appropriate.
* mailbox/muerrno.c: Fixed indentation.
* pop3d/popauth.c: Use mu_strerror.
* mh/ali.c (main): Bugfix. Lists were not initialized.
* mh/mh_alias.l (push_source): Honor Path variable.
2003-09-04 Wojciech Polak
* include/mailutils/errno.h: Added MU_ERR_UNSAFE_PERMS.
* mailbox/muerrno.c: Likewise.
* mailbox/wicket.c (get_ticket): Check file permissions.
2003-09-02 Wojciech Polak
* mailbox/pop/mbox.c (pop_get_message): Check UIDL capability
before using pop_uidl().
2003-09-02 Sergey Poznyakoff
* mail/mail.c: Fixed description of --file argument.
* mailbox/filter_trans.c (qp_decode): Fixed bug that
could overflow the receiving buffer.
2008-09-02 Wojciech Polak
* mail/next.c (mail_next): Check return code from msgset_parse
to prevent segmentation fault.
* mail/previous.c (mail_previous): Likewise.
2008-09-01 Wojciech Polak
* pop3d/pop3d.c (pop3d_daemon): Added startup notification.
* imap4d/imap4d.c (imap4d_daemon): Likewise.
2003-08-30 Wojciech Polak
* auth/tls.c (mu_check_tls_environment): Improved diagnostics.
* mailbox/pop/mbox.c (POP_AUTH_USER_ACK): Protect password
in debug mode (PASS ***).
2003-08-29 Sergey Poznyakoff
* imap4d/bye.c: Do not attempt to write to the output
stream if a signal was caught.
* imap4d/signal.c (imap4d_signal): Minor fix
* pop3d/extra.c (pop3d_abquit): Flush and close the mailbox
only unless we're not in the AUTHORIZATION state.
Do not attempt to write to the output stream if a signal was
caught.
* include/mailutils/errno.h (MU_ERR_NOUSERNAME)
(MU_ERR_NOPASSWORD): New error codes.
* mailbox/muerrno.c: Likewise.
* mailbox/mailbox.c (mailbox_flush): Test the first argument.
* mailbox/ticket.c (ticket_pop): Fallback to command line
prompt if _pop() failed and stdin is connected to a terminal.
* mailbox/imap/folder.c: Provide a better diagnostics.
* mailbox/pop/mbox.c (_pop_user): Send QUIT before dropping
the connection. Provide a better diagnostics.
* sieve/sieve.c: Destroy the mailbox if the attempt to open it has
failed.
2003-08-29 Wojciech Polak
* mailbox/pop/mbox.c (pop_capa): New function.
Moved CAPA support to pop_capa. Conform to RFC 2595:
reissue CAPA after successful STLS negotiation.
(tls): Renamed to pop_stls().
2003-08-29 Sergey Poznyakoff
* auth/gsasl.c: Lots of fixes.
* auth/lbuf.h (_auth_lb_writelines): New function.
* auth/lbuf.c: Likewise
* imap4d/util.c (util_run_events): Use iterator instead of
list_do. Iterators are safer.
2003-08-28 Sergey Poznyakoff
Implemented the TLS protocol for IMAP and POP mailboxes.
Split libmailbox to the core library (libmailbox) and
the protocol implementation libraries (libmu_$PROTONAME).
* auth/lbuf.h: New file.
* auth/lbuf.c: New file.
* auth/tls.c: Implemented client TLS stream.
* auth/gsasl.c: Use lbuf stuff.
* auth/Makefile.am: Updated.
* mailbox/mbx_file.c: Moved to ...
* mailbox/mbox/file.c: ... here
* mailbox/mbox/Makefile.am: Changed target to lib_LTLIBRARY
* mailbox/mh/Makefile.am: Likewise
* mailbox/imap/Makefile.am: Likewise
* mailbox/pop/Makefile.am: Likewise
* mailbox/maildir/Makefile.am: Likewise
* dotlock/Makefile.am: Adopted _LDADD for the new library layout.
* examples/Makefile.am: Likewise
* from/Makefile.am: Likewise
* guimb/Makefile.am: Likewise
* imap4d/Makefile.am: Likewise
* mail/Makefile.am: Likewise
* mailbox/Makefile.am: Likewise
* messages/Makefile.am: Likewise
* mh/Makefile.am: Likewise
* pop3d/Makefile.am: Likewise
* readmsg/Makefile.am: Likewise
* sieve/Makefile.am: Likewise
* comsat/Makefile.am: Likewise
* frm/Makefile.am: Likewise
* mail.local/Makefile.am: Likewise
* configure.ac: Moved Kerberos libs to SERV_AUTHLIBS.
* Makefile.am: Changed the order of SUBDIRS
* mailbox/mailutils-config.c: --link part rewritten to reflect
the new library layout.
* mailbox/imap/folder.c: Implemented client side TLS
* mailbox/imap/mbox.c (imap_expunge): Use EXPUNGE instead
of closing and reopening the mailbox. This way the user
is not prompted twice for his credentials. Besides, it
appears to be faster, in spite of what the comment before
the function said.
* mailbox/pop/mbox.c: Implemented client side TLS.
* mailbox/include/imap0.h (struct _f_imap): New members
capav and capac to hold the array of capabilities.
* examples/decode2047.c (ISPRINT): Fixed.
* from/from.c: Use "tls" command line capability.
* frm/frm.c: Likewise
* messages/messages.c: Likewise.
* mail/mail.c: Likewise.
* readmsg/readmsg.c: Likewise.
* sieve/sieve.c: Likewise.
* mail/mail.h: Include tls.h
* readmsg/readmsg.h: Likewise.
* include/mailutils/stream.h (stream_get_fd2): New function.
(stream_set_fd): Changed type of the second arg.
* mailbox/stream.c: Likewise.
* mailbox/include/stream0.h (struct _stream): Changed
_get_fd member.
* mailbox/body.c: Fixed _get_fd methods.
* mailbox/file_stream.c: Likewise.
* mailbox/filter.c: Likewise.
* mailbox/message.c: Likewise.
* mailbox/mime.c: Likewise.
* mailbox/mbox/mbox.c: Likewise.
* mailbox/mapfile_stream.c: Likewise.
* mailbox/tcp.c: Likewise.
* include/mailutils/tls.h (tls_stream_create_client)
(tls_stream_create_client_from_tcp): New functions.
(mu_tls_enable): New variable
* libmu_scm/mailutils.scm.in: Modified for the new
library layout.
* mailbox/sendmail.c: Added missing includes
* mailbox/smtp.c: Likewise.
* mailbox/pop/folder.c: Minor wording change.
* NEWS: Updated
* TODO: Updated
2003-08-27 Sergey Poznyakoff
* NEWS: Updated
* mailbox/mime.c (_mime_parse_mpart_message): Allow for
empty part body.
* examples/mimetest.c: Print the number of lines along with the
message sizes.
* testsuite/spool/mbox1: Added fifth message for testing
empty MIME parts.
* mailbox/testsuite/Mime: Updated for the new contents of
mbox1
* frm/testsuite/frm/test.exp: Likewise.
* from/testsuite/from/test.exp: Likewise.
* imap4d/testsuite/imap4d/examine.exp: Likewise.
* imap4d/testsuite/imap4d/expunge.exp: Likewise.
* imap4d/testsuite/imap4d/fetch.exp: Likewise.
* mail/testsuite/mail/folder.exp: Likewise.
* mail/testsuite/mail/write.exp: Likewise.
* messages/testsuite/messages/test.exp: Likewise.
* readmsg/testsuite/readmsg/test.exp: Likewise.
* sieve/testsuite/sieve/header.exp: Likewise.
2003-08-22 Sergey Poznyakoff
* examples/mta.c (mta_send): Fixed printing of envelope
to addresses.
* include/mailutils/address.h (address_format_string): Missed
prototype.
* mailbox/header.c: Added missing include
* mailbox/sendmail.c (sendmail_send_message): Use header
and body streams sequentially instead of using message
stream. This allows to catch the modified/added headers.
* mailbox/smtp.c (smtp_send_message): Likewise.
* mh/TODO: Updated
* mh/ali.c (main): Minor change.
* mh/comp.c (query_mode): Unused variable
* mh/folder.c (create_flag): A three-state flag.
(_scan): Fixed behavior on non-existing folders.
* mh/mh.h: Added new protos
* mh/mh_alias.l (yyparse): Forward declaration.
* mh/mh_alias.y (yyerror,yylex): Forward declarations.
(alias_expand_list,mh_alias_get_internal)
(mh_alias_get_address): Get an extra argument (for handling
';' aliases).
* mh/mh_global.c (mh_global_sequences_drop): New function
* mh/mh_init.c (mh_getyn): Bugfix
* mh/mh_stream.c (struct _mhdraft_message.body_start,body_end):
Changed type to off_t.
* mh/mh_whom.c (mh_alias_expand): New function
(scan_addrs): Expand aliases
* mh/rmf.c: Switch to +inbox after deleting the current folder.
Improved diagnostics.
* mh/send.c: Handle aliases.
* mh/whom.c (main): Bugfix.
2003-08-21 Sergey Poznyakoff
* include/mailutils/iterator.h (iterator_dup): New function
* mailbox/iterator.c: Likewise.
* include/mailutils/list.h (list_insert): New function.
* mailbox/list.c: Likewise.
* mh/ali.c: New file
* mh/mh_alias.y: New file
* mh/mh_alias.l: New file
* mh/Makefile.am: Added new files
* mh/.cvsignore: Likewise.
* mh/mh.h (mh_alias_read,mh_alias_get)
(mh_alias_get_address,mh_alias_get_alias)
(mh_read_aliase,smh_alias_enumerate): New functions.
* mh/mh_getopt.h: Updated
* mh/mh_whom.c (scan_addrs): Added support for aliases
* mh/mhparam.c: Fixed year in the copyleft header.
* mh/whom.c: Added support for aliases.
* mh/mh_init.c: Minor cleanup
2003-08-20 Sergey Poznyakoff
* comsat/action.c (expand_escape): Use argcv_unescape_char()
instead of backslash().
* libsieve/sieve.l: Fixed handling of escape sequences in
strings. Thanks Fabrice Bauzac <fabrice.bauzac@wanadoo.fr>
for reporting.
* mailbox/argcv.c (argcv_unescape_char,argcv_escape_char):
New functions.
* include/mailutils/argcv.h: Likewise.
2003-08-19 Sergey Poznyakoff
* mh/replgroupcomps: New file.
* mh/Makefile.am (mhlib_DATA): Added components and
replgroupcomps.
* mh/repl.c: Implemented -group.
* mh/mh_format.c (builtin_in_reply_to): Bugfix.
* mh/mh_msgset.c (_mh_msgset_parse): Fixed the semantics
of last:N and prev:N.
* mh/mh.h: Updated
2003-08-18 Sergey Poznyakoff
* mail/mail.h (ml_readline_with_intr): New function.
* mail/mailline.c: Likewise.
* mail/send.c: Use ml_readline_with_intr() when prompting
for header fields.
2003-08-18 Sergey Poznyakoff
* pop3d/extra.c (pop3d_abquit): Flush message headers.
* NEWS: Updated.
* mail/mail.c (main): If the send mode was interrupted by
the user, exit with zero status if mailx is set.
* doc/texinfo/programs.texi: Updated.
2003-08-18 Sergey Poznyakoff
* mail/send.c (mail_send, mail_send0): Use `mailx'
to control mailx compatibility mode. Thanks Peter S Galbraith
<p.galbraith@globetrotter.net> for the idea.
* doc/texinfo/programs.texi: Document `mailx' variable
* NEWS: Added entry about `mailx' variable
2003-08-17 Sergey Poznyakoff
* mail/send.c (mail_send0): Fixed typo in variable name.
* mh/mhparam.c: New file
* mh/Makefile.am: Added mhparam
* mh/.cvsignore: Likewise.
* mh/mh.h (mh_global_profile_iterate): New function
* mh/mh_global.c: Likewise.
* mh/mh_getopt.c (mh_getopt): Implemented -version option.
* mh/README: Updated
2003-08-13 Sergey Poznyakoff
* mh/mh_sequence.c (mh_seq_add): Update current_message
if the sequence being set is "cur". Free temporary storage.
* mh/components: New file
* mh/Makefile.am: Added components
* mh/mh.h (mh_interactive_mode_p, mh_getyn_interactive): New
functions.
* mh/mh_init.c (mh_interactive_mode_p, mh_getyn_interactive)
(mh_vgetyn): New functions.
(mh_real_install): Use mh_getyn_interactive().
* mh/pick.c (main): Use mh_interactive_mode_p().
2003-08-12 Sergey Poznyakoff
* mh/folder.c (_scan): Prompt for creating the folder
unless --create was given.
* mh/scan.c (main): Display "no messages in ..." warning
for empty folders.
2003-08-12 Sergey Poznyakoff
* mh/mh_msgset.c (mh_msgset_uids): New function.
* mh/mh.h: Likewise.
* mh/mark.c (main): Convert msgset to uids.
* mh/scan.c (list_message): Output an extra newline only
if the formatted buffer does not end with one.
2003-08-12 Sergey Poznyakoff
* mail/mail.h (mail_execute): New function.
* mail/shell.c (mail_execute): New function.
* mail/var.c (run_editor): A wrapper around mail_execute().
(var_shell): Use run_editor.
* mh/mh_format.c (print_simple_segment): Bugfix.
* mh/replcomps: Improved.
2003-08-11 Sergey Poznyakoff
* mh/mh.h (enum mh_opcode): New opcode mhop_nop.
* mh/mh_fmtgram.y (fi production): Preserve the
result of the last comparison.
* mh/mh_format.c (mh_format): Count the newline as output
character (for compatibility with other implementations).
Set arg_num when evaluating headers.
(mh_format,mh_format_dump): Handle mhop_nop.
* mh/repl.c: New option --format.
* mail/mail.c (main): set rc by default
2003-08-10 Sergey Poznyakoff
* mh/inc.c (opt_handler): Added missing support for
-format option. Thanks Peter S Galbraith
<p.galbraith@globetrotter.net> for reporting.
2003-08-07 Sergey Poznyakoff
* NEWS: Updated
* TODO: Updated
* include/mailutils/header.h (header_get_value_unfold)
(header_aget_value_unfold,header_get_field_value_unfold)
(header_aget_field_value_unfold): New functions.
* mailbox/header.c: Likewise.
* include/mailutils/mutil.h (mu_string_unfold): New function.
* mailbox/mutil.c: Likewise.
* mailbox/mbox/mboxscan.c (FAST_HEADER): Do not remove
intermediate newlines from the folded headers.
* frm/frm.c: use header_get_value_unfold
* mail/from.c: Likewise.
2003-07-26 Sergey Poznyakoff
Done the following from the TODO:
-** First argument to mu_auth_fp (and second one to
mu_auth_runlist) should be struct mu_auth_data ** instead
of void *.
-** (sieve) Implement boolean shortcut evaluation for
`allof' and `anyof'
-* util_strcasestr() from mail/util.c provides the same
functionality as i_ascii_casemap_contains() from
libsieve/comparator. Merge both versions.
Detailed list of changes:
* TODO: Updated
* configure.ac: Fixed --with-mysql, --with-postgres
* include/mailutils/mu_auth.h (mu_auth_fp, mu_auth_runlist):
Changed prototypes.
* include/mailutils/libsieve.h (struct sieve_runtime_tag): Minor
change.
* include/mailutils/mutil.h (mu_strcasestr): New function.
* auth/mysql.c: Reflect changes to mu_auth_fp
* auth/pam.c: Likewise.
* auth/pgsql.c: Likewise.
* auth/sql.c: Likewise.
* auth/tls.c: Likewise.
* auth/virtual.c: Likewise.
* mailbox/system.c: Likewise.
* examples/Makefile.am (INCLUDES): Add mailbox (for getline.h)
* examples/mta.c: include getline.h
* imap4d/authenticate.c (comp): Minor change
* imap4d/fetch.c (send_parameter_list): Minor change
* imap4d/util.c (util_strcasestr): Reimplemented via
mu_strcasestr()
* libsieve/README: Documented boolean shortcuts
* libsieve/comparator.c (i_ascii_casemap_contains): Reimplemented
via mu_strcasestr()
* libsieve/prog.c (sieve_code_anyof, sieve_code_allof): New
functions.
(struct check_arg): Minor change
* libsieve/runtime.c (instr_nop): New function
(instr_allof, instr_anyof): Removed
* libsieve/sieve.h (sieve_code_anyof,sieve_code_allof): New
functions.
(instr_allof, instr_anyof): Removed
* libsieve/sieve.y: Implemented boolean shortcuts for ALLOF and
ANYOF
* mail/mail.h (ml_readline, readline): Removed const from
the declaration.
* mail/mailline.c: Likewise.
* mailbox/body.c (lazy_create): Removed unused function.
* mailbox/iterator.c (iterator_get_list): Minor change
* mailbox/mailcap.c: include <mailutils/stream.h>
* mailbox/mbx_default.c (is_proto): Minor change
* mailbox/rfc2047.c (insert_quoted): Minor change
* mailbox/mu_auth.c (mu_auth_runlist,mu_auth_nosupport): Changed
type of the first argument.
* mailbox/mutil.c (mu_strcasestr): New function.
* pop3d/pop3d.h (pop3d_bye): Added missing prototype
2003-07-22 Sergey Poznyakoff
* mailbox/argcv.c: Implemented escaping/unescaping
of non-printable characters
* TODO: Updated.
* NEWS: Updated
* mh/Makefile.am (mh_finish_install): Fixed. Thanks
Andreas Voegele <voegelas@gmx.net> for the patch.
2003-07-16 Sergey Poznyakoff
* NEWS: Updated
* TODO: Updated
* examples/listop.c: New file. A test shell for list operations.
* examples/Makefile.am: Added listop.c
* include/mailutils/iterator.h (iterator_get_list): New function.
* mailbox/iterator.c: Rewritten to reduce the time of list
traversal.
* mailbox/list.c (list_remove): Call iterator_advance.
* mailbox/include/iterator0.h (struct _iterator): Rewritten
(iterator_advance): New function.
* mailbox/include/list0.h (struct _list): Keep the linked list
of associated iterators.
* mailbox/testsuite/lib/mailbox.exp (mailbox_prog_start)
(mailbox_prog_command,mailbox_prog_stop,mailbox_prog_test): New
functions.
* mailbox/testsuite/mailbox/list.exp: New file. Tests generic list
operations.
* mailbox/testsuite/mailbox/DISTFILES: Added list.exp
2003-07-08 Sergey Poznyakoff
* configure.ac: Raised version number
* NEWS: Started entry for 0.3.2
* comsat/comsat.c: Bugfix.
* pop3d/apop.c: Provide more extensive diagnostics.
2003-07-01 Sergey Poznyakoff
* auth/pam.c: Minor indentation fix.
* comsat/comsat.c (notify_user): Bugfix: do not pass
size_t instead of off_t.
* mail.local/main.c (deliver): Likewise.
2003-06-26 Sergey Poznyakoff
* mailbox/mu_auth.c (mu_auth_register_module): Fixed memory
overrun.
* pop3d/popauth.c: New option --create
2003-06-23 Sergey Poznyakoff
* doc/Readme.mysql: Removed. File not relevant anymore.
* include/mailutils/nls.h: Minor change.
* mail/mail.c (parse_opt): Use util_cache_command, except
for -n, which should be executed immediately.
(main): Run cached commands after sourcing the startup files.
* mail/mail.h (util_cache_command,util_run_cached_commands):
New functions.
* mail/util.c: Likewise.
2003-06-22 Alain Magloire
* doc/texinfo/pop3.texi: First draft documenting the new low level
API for POP3.
2003-06-21 Wojciech Polak
* mailutils.spec.in: Major changes. Added new packages,
changed package names. Thanks Bennett Todd <bet@rahul.net>
for testing.
2003-06-11 Sergey Poznyakoff
* autogen.sh: A hack to force automake to install COPYING file.
* Makefile.am: Changed AUTOMAKE_OPTIONS, added COPYING.LIB
to EXTRA_DIST.
* README: Minor change.
* COPYING.FDL: Moved to ...
* doc/texinfo/COPYING.DOC: ... here
* doc/texinfo/Makefile.am: Added COPYING.DOC.
* mh/mhn.c (store_handler): Fixed indentation.
2003-06-07 Wojciech Polak
* configure.ac (AM_GNU_GETTEXT_VERSION): Bump to 0.12.1.
(INTLINCS): Added `-I../intl'.
* m4/Makefile.am: Added nls.m4 and po.m4.
* po/Makevars: Added MSGID_BUGS_ADDRESS.
2003-06-07 Sergey Poznyakoff
* NEWS: Updated
2003-06-02 Sergey Poznyakoff
* imap4d/fetch.c (fetch_internaldate): Bugfix. Coredumped
on invalid dates.
2003-05-28 Sergey Poznyakoff
* mh/mhn.c (store_handler): Honor the `name' attribute of
the Content-Type header.
2003-05-26 Sergey Poznyakoff
* imap4d/auth_gss.c (auth_gssapi): Check return codes
from gss_wrap, gss_unwrap.
* NEWS: Added entry for 0.3.1
* mh/mhn.c (_message_is_external_body): Check subtype before
dereferencing it.
2003-05-24 Alain Magloire
* configure.ac: Check for "long long" and "long double".
* lib/snprintf.c: Change to be under LGPL not GPL.
(vsnprintf): implement "%lld", "%qd", "%Lg"
* lib/snprintf.h: New macro LONG_LONG, LONG_DOUBLE
default to long long, long double.
2003-05-20 Sergey Poznyakoff
* imap4d/auth_gss.c (auth_gssapi): Do not output surplus text
after the '+'.
Don't use strdup as the username is not zero terminated.
2003-05-19 Wojciech Polak
* mailbox/pop/mbox.c: Moved variable `capa' to struct _pop_data.
2003-05-14 Wojciech Polak
* mailbox/pop/mbox.c: Added the CAPA support (to determine
any protocol extension).
* TODO: Updated.
2003-04-30 Wojciech Polak
* doc/texinfo/mailutils.texi: Changed @dircategory according
to the GNU Directory.
* po/POTFILES.in: Added auth/mysql.c and auth/pgsql.c.
2003-04-23 Sergey Poznyakoff
* configure.ac: Renamed --enable-mysql to --with-mysql. Added
--with-postgres option.
Use AC_FUNC_MALLOC and AC_FUNC_REALLOC instead of old jm_*
versions.
* README: Documented --with-mysql and --with-postgres
* auth/pgsql.c: New file.
* auth/mysql.c: New file.
* auth/sql.h: New file.
* auth/Makefile.am: Added new files.
* auth/sql.c: Moved mysql-specific code to mysql.c
* m4/lib.m4: New file.
* m4/malloc.m4: Removed.
* m4/realloc.m4: Removed.
* m4/Makefile.am: Added lib.m4, removed malloc.m4 and realloc.m4
* lib/xmalloc.c: Adjusted for use with new AC_CHECK_ macros.
* include/mailutils/mu_auth.h: Include <mailutils/types.h>,
protect the file contents by #ifndef .. #endif
* mailbox/mu_argp.c (mu_conf_option): Reflect HAVE_PGSQL
2003-04-22 Sergey Poznyakoff
* mailbox/imap/folder.c (imap_literal_string): Bugfix. Literal
length may be {0}.
2003-04-18 Sergey Poznyakoff
* mailbox/imap/folder.c (imap_string): Bugfix. Handle numbers.
* mh/mhn.c (mhn_store_command): Bugfix. Properly use message
part numbers.
2003-04-11 Sergey Poznyakoff
* mailbox/filter_trans.c (qp_decode): Bugfix.
2003-04-03 Sergey Poznyakoff
* examples/base64.c (main): Use custom ISPRINT macro
so we don't depend on the current locale settings.
* examples/decode2047.c (print): Likewise.
* testsuite/lib/mailutils.exp: Set LC_ALL to C before proceeding.
2003-04-02 Sergey Poznyakoff
* mh/mhn.c (normalize_path): Bugfix.
2003-03-29 Sergey Poznyakoff
Minor changes to avoid duplicating some symbols (namely
argp_program_version and argp_program_bug_address). This
allows the package to build on MacOS.
* include/mailutils/argp.h (mu_argp_init): New function.
* mailbox/mu_argp.c: Likewise.
* comsat/comsat.c (main): Use mu_argp_init.
* frm/frm.c: Likewise.
* from/from.c: Likewise.
* guimb/main.c: Likewise.
* imap4d/imap4d.c: Likewise.
* mail/mail.c: Likewise.
* mail.local/main.c: Likewise.
* mail.remote/mail.remote.c: Likewise.
* mailbox/mailutils-config.c: Likewise.
* messages/messages.c: Likewise.
* mh/anno.c: Likewise.
* mh/comp.c: Likewise.
* mh/fmtcheck.c: Likewise.
* mh/folder.c: Likewise.
* mh/forw.c: Likewise.
* mh/inc.c: Likewise.
* mh/install-mh.c: Likewise.
* mh/mark.c: Likewise.
* mh/mhl.c: Likewise.
* mh/mhn.c: Likewise.
* mh/mhpath.c: Likewise.
* mh/pick.c: Likewise.
* mh/refile.c: Likewise.
* mh/repl.c: Likewise.
* mh/rmf.c: Likewise.
* mh/rmm.c: Likewise.
* mh/scan.c: Likewise.
* mh/send.c: Likewise.
* mh/sortm.c: Likewise.
* mh/whatnow.c: Likewise.
* mh/whom.c: Likewise.
* pop3d/pop3d.c: Likewise.
* pop3d/popauth.c: Likewise.
* readmsg/readmsg.c: Likewise.
* sieve/sieve.c: Likewise.
* dotlock/dotlock.c: Likewise.
* mail.local/mail.local.h: include <sys/types.h> (necessary for
Darwin).
* mail/mail.h (struct message_set): Changed type of msg_part to
size_t.
* libsieve/comparator.c (i_ascii_casemap_contains): Fixed
obsolete label usage.
* THANKS: Added Timothy Carpenter
2003-03-27 Sergey Poznyakoff
* mailbox/filter_trans.c (_hexdigits): Must be zero-terminated,
otherwise the native Darwin loader refuses to load it.
(qp_decode): Bugfix: in accordance with rfc1892 a sequence
of whitespace is allowed in an encoded string provided that
it is followed by a printable character.
(qp_encode): Preserve trailing whitespace.
* include/mailutils/nls.h [!ENABLE_NLS]: Provide defines for
dgettext and ngettext.
* mailbox/argp-parse.c: Include <mailutils/nls.h>
* mh/mhn.c (mhn_store_command): If no message part is available
ignore %p and %P metacharacters.
(store_handler): Unlink the file if it exists.
2003-03-26 Sergey Poznyakoff
* mailbox/mu_auth.c (mu_auth_data_alloc): Fixed COPY macro.
* mh/mhn.c (main): Ignore sighups.
* mh/mh_format.c (builtin_formataddr): Bugfix.
2003-03-26 Sergey Poznyakoff
* include/mailutils/errno.h (MU_ERR_FAILURE): New macro
* mailbox/muerrno.c: Likewise
* mailbox/mutil.c (mu_rfc2822_references,mu_rfc2822_in_reply_to):
Return MU_ERR_FAILURE on error.
* mh/mh_format.c (builtin_concat): Extra safety check
(builtin_in_reply_to,builtin_references): Check return value
from the underlying library calls.
* mh/mh_msgset.c (_mh_msgset_parse): Accept "all" message spec
on folders with only one message.
* mh/mhn.c: Print information about the external body parts.
* mh/whom.c (mh_option): Bugfix
2003-03-24 Sergey Poznyakoff
* mh/mhn.c (stream_getline,parse_content_type): A couple of
bugfixes.
2003-03-24 Sergey Poznyakoff
* mh/mhn.c: Implemented external-body.
* mh/TODO: Updated
* configure.ac (ATTRIBUTE_UNUSED): Renamed to ARG_UNUSED
to avoid confusion.
* auth/pam.c: Use ARG_UNUSED where necessary
* lib/daemon.c: Likewise.
* mail/decode.c: Likewise.
* mail/exit.c: Likewise.
* mail/folders.c: Likewise.
* mail/if.c: Likewise.
* mail/inc.c: Likewise.
* mail/list.c: Likewise.
* mail/mail.c: Likewise.
* mail/tag.c: Likewise.
* mail/var.c: Likewise.
* mail/version.c: Likewise.
* mail/mailline.c: Likewise.
* mail/msgset.y: Likewise.
* mail/quit.c: Likewise.
* mail/source.c: Likewise.
* mail/summary.c: Likewise.
* mailbox/auth.c: Likewise.
* mailbox/body.c: Likewise.
* mailbox/filter_trans.c: Likewise.
* mailbox/monitor.c: Likewise.
* mailbox/parsedate.y: Likewise.
* mailbox/stream.c: Likewise.
* mailbox/url_file.c: Likewise.
* mailbox/url_path.c: Likewise.
* mailbox/url_sendmail.c: Likewise.
* mailbox/mh/folder.c: Likewise.
* mailbox/mh/mbox.c: Likewise.
* mailbox/mh/url.c: Likewise.
* mailbox/pop/mbox.c: Likewise.
* mailbox/pop/url.c: Likewise.
* mailbox/imap/folder.c: Likewise.
* mailbox/imap/url.c: Likewise.
* mailbox/mbox/folder.c: Likewise.
* mailbox/mbox/url.c: Likewise.
* imap4d/capability.c: Likewise.
* imap4d/check.c: Likewise.
* imap4d/close.c: Likewise.
* imap4d/fetch.c: Likewise.
* pop3d/auth.c: Likewise.
* pop3d/signal.c: Likewise.
2003-03-22 Jordi Mallach
* mailbox/Makefile.am (EXTRA_DIST): Added parsedate.y.
2003-03-22 Sergey Poznyakoff
* configure.ac: Raised version number to 0.3.1
Define macro ATTRIBUTE_UNUSED.
* mailbox/parsedate.y: New file
* mailbox/.cvsignore: Updated
* mailbox/Makefile.am: Updated
* mh/Makefile.am: Minor formatting change.
* mh/README: Updated.
* mh/TODO: Updated.
* mh/pick.c: Implemented --after and --before.
* mh/pick.h: Likewise.
* mh/pick.y: Likewise.
* mail/from.c (mail_from0): Bugfix.
* include/mailutils/mutil.h (mu_parse_date): New function.
2003-03-20 Sergey Poznyakoff
* mh/README: Updated.
* mh/mhn.c: Recognize mhn-compose-* profile components.
2003-03-20 Sergey Poznyakoff
* mh/mhn.c: Implemented #forw directive.
* mh/forw.c: Fixed --mime mode.
* mh/TODO: Updated
2003-03-19 Sergey Poznyakoff
* mh/anno.c: Minor changes for consistency with the overall
GNU mh options layout.
* mh/comp.c: Likewise.
* mh/fmtcheck.c: Likewise.
* mh/folder.c: Likewise.
* mh/forw.c: Likewise.
* mh/inc.c: Likewise.
* mh/install-mh.c: Likewise.
* mh/mark.c: Likewise.
* mh/mh_getopt.h: Likewise.
* mh/mhl.c: Likewise.
* mh/mhn.c: Likewise.
* mh/mhpath.c: Likewise.
* mh/pick.c: Likewise.
* mh/refile.c: Likewise.
* mh/repl.c: Likewise.
* mh/rmf.c: Likewise.
* mh/rmm.c: Likewise.
* mh/scan.c: Likewise.
* mh/send.c: Likewise.
* mh/sortm.c: Likewise.
* mh/whatnow.c: Likewise.
* mh/whom.c: Likewise.
2003-03-19 Sergey Poznyakoff
* doc/rfc/Makefile.am: Added rfc1521.txt
* doc/rfc/rfc1521.txt: Added to the repository.
* mailbox/filter_trans.c (base64_encode): Bugfix.
* mh/mhn.c: Implemented basic editing functionality.
* mh/mh_init.c (mh_create_message_id): Minor change.
* mh/README: Updated
* mh/TODO: Updated
2003-03-19 Sergey Poznyakoff
* mh/mhn.c: Added framework for compose mode.
* mh/mh.h (mh_create_message_id): New function.
* mh/mh_init.c: Likewise.
* mh/send.c: Use mh_create_message_id().
2003-03-17 Sergey Poznyakoff
* mh/mh.h (MHL_DISABLE_BODY): New flag.
* mh/mh_list.c (eval_body,mhl_format_run): MHL_DISABLE_BODY
bit inhibits the 'body:' keyword.
* mh/mhn.c: Implemented store mode.
* mh/README: Updated
* mh/TODO: Updated
2003-03-16 Wojciech Polak
* mh/mh_init.c (mh_getyn, mh_real_install): Added an extra
space after the question marks.
* configure.ac: Minor, changed GDBM to GNU DBM.
* mailbox/mailcap.c: Updated copyright.
* include/mailutils/mailcap.h: Likewise.
2003-03-15 Sergey Poznyakoff
* mh/mhn.c: New file. Implementation of mhn utility (partial).
* mh/.cvsignore: Added mhn
* mh/Makefile.am: Likewise.
* mh/forw.c: Implemented --mime.
* mh/TODO: Updated.
* mh/mh.h (mhl_format_run): Changed prototype
(MHL_DECODE,MHL_CLEARSCREEN,MHL_BELL): New defines.
* mh/mh_getopt.h: Updated.
* mh/mh_list.c (mhl_format_run): Changed declaration.
(eval_body): Decode message body on request.
* mh/mh_ctx.c: Bugfix. Thanks Wojciech for noticing!
* mh/mhl.c: Updated invocations of mhl_format_run().
* mh/repl.c: Likewise.
* po/POTFILES.in: Added new files.
2003-03-14 Sergey Poznyakoff
* TODO: Reformatted in Emacs outline mode
* mh/compcommon.c: New file.
* mh/forw.c: New file.
* mh/.cvsignore: Added forw
* mh/Makefile.am: Likewise.
* mh/TODO: Updated
* mh/comp.c (format_str,check_draft_disposition): Removed
(main): Use mh_comp_draft().
* mh/mh.h (mh_comp_draft,check_draft_disposition): New functions.
* mh/mh_stream.c (_body_readline,_body_stream_size): Bugfix.
* mh/mh_whom.c (scan_addrs): Bugfix.
* po/POTFILES.in: Added new files.
2003-03-13 Sergey Poznyakoff
Reorganized directory layout under mailbox/.
* configure.ac: Added mailbox/ subdirectories
* mailbox/Makefile.am: Likewise.
* po/POTFILES.in: Added missing files.
* mh/README: Updated
* mailbox/mbox/Makefile.am: New file
* mailbox/mbox/.cvsignore: New file
* mailbox/mbox/folder.c: Moved from ../
* mailbox/mbox/mbox.c: Moved from ../
* mailbox/mbox/url.c: Moved from ../
* mailbox/mbox/mboxscan.c: Moved from ../
* mailbox/mbox/mbox0.h: New file
* mailbox/mh/Makefile.am: New file
* mailbox/mh/.cvsignore: New file
* mailbox/mh/folder.c: Moved from ../
* mailbox/mh/mbox.c: Moved from ../
* mailbox/mh/url.c: Moved from ../
* mailbox/maildir/Makefile.am: New file
* mailbox/maildir/.cvsignore: New file
* mailbox/maildir/mbox.c: New file
* mailbox/imap/Makefile.am: New file
* mailbox/imap/.cvsignore: New file
* mailbox/imap/folder.c: Moved from ../
* mailbox/imap/mbox.c: Moved from ../
* mailbox/imap/url.c: Moved from ../
* mailbox/pop/Makefile.am: New file
* mailbox/pop/.cvsignore: New file
* mailbox/pop/folder.c: Moved from ../
* mailbox/pop/mbox.c: Moved from ../
* mailbox/pop/url.c: Moved from ../
* mailbox/folder_mbox.c: Moved to mbox/folder.c
* mailbox/mbx_mbox.c: Moved to mbox/mbox.c
* mailbox/url_mbox.c: Moved to mbox/url.c
* mailbox/mbx_mboxscan.c: Moved to mbox/mboxscan.c
* mailbox/folder_mh.c: Moved to mh/folder.c
* mailbox/mbx_mh.c: Moved to mh/mh.c
* mailbox/url_mh.c: Moved to mh/url.c
* mailbox/mbx_maildir.c: Moved to maildir/mbox.c
* mailbox/folder_imap.c: Moved to imap/folder.c
* mailbox/mbx_imap.c: Moved to imap/mbox.c
* mailbox/url_imap.c: Moved to imap/url.c
* mailbox/folder_pop.c: Moved to pop/folder.c
* mailbox/mbx_pop.c: Moved to pop/mbox.c
* mailbox/url_pop.c: Moved to pop/url.c
2003-03-11 Sergey Poznyakoff
* auth/sql.c (mu_sql_authenticate): Bugfix.
* mh/.cvsignore: Added 'whom'.
* mh/mh_whom.c: New file.
* mh/whom.c: New file.
* mh/Makefile.am: Added new files
* mh/TODO: Updated
* mh/mh.h (mh_draft_name,mh_whom): New functions.
* mh/mh_getopt.h: Updated
* mh/mh_init.c (mh_draft_name): New function.
* mh/mh_whatnow.c (whom): Use mh_whom.
* mh/send.c (draft_name): Removed.
* mh/whatnow.c (main): Use 'draft' by default.
2003-03-10 Sergey Poznyakoff
* comsat/comsat.c: Use ngettext.
* mh/sortm.c: New file. Source for the sortm utility.
* mh/.cvsignore: Added sortm
* mh/Makefile.am: Likewise
* mh/README: Updated
* mh/TODO: Updated
* mh/mh_getopt.h: Updated
2003-03-03 Sergey Poznyakoff
* configure.ac: New option --with-included-argp
* README: Documented --with-included-argp
* doc/texinfo/muint.texi: New file. Root for the "Mailutils
internals" manual.
* doc/texinfo/Makefile.am: Added rules to generate muint.info
* doc/texinfo/mom.texi: Minor changes.
* po/POTFILES.in: Added missed files.
2003-02-24 Alain Magloire
* doc/texinfo/mom.texi: Draft explanation of the
Mailutils Object Model (MOM).
2003-02-24 Sergey Poznyakoff
* include/mailutils/mailcap.h: Added missing prototypes, protected
argument decls with __P and the whole stuff with extern "C".
* mailbox/mailcap.c: Fixed indentation, adopted for 80-column
screen.
* doc/texinfo/mailcap.inc: Removed. Auto-generated file
* examples/mailcap.c: New file.
* examples/Makefile.am: Added mailcap.c
* examples/.cvsignore: Added mailcap
* mailbox/testsuite/Mailcap: New file. Test data for mailcap.
* mailbox/testsuite/Makefile.am: Added Mailcap
* mailbox/testsuite/mailbox/mailcap.exp: New file.
* mailbox/testsuite/mailbox/DISTFILES: Added mailcap.exp
2003-02-23 Alain Magloire
* mailbox/refcount.c: Added a simple thread-safe implementation.
* include/mailutils/types.h: Added structure for refcount.
* include/mailutils/refcount.h: Added a simple thread-safe implementation.
2003-02-23 Alain Magloire
* include/mailutils/types.h: Added the mailcap structure.
* include/mailutils/mailcap.h: Include types.h
2003-02-23 Alain Magloire
* doc/texinfo/mailcap.texi: Document the mailcap functions.
* doc/texinfo/mailcap.inc: Code example.
* doc/texinfo/Makefile.am: Added mailcap.texi and mailcap.inc
* mailbox/Makefile.am: Added mailcap.c
* mailbox/mailcap.c: include <mailutils/mailcap.h>
* include/mailutils/Makefile.am: Added mailcap.h
2003-02-22 Alain Magloire
First implementation of rfc1524.
* mailbox/mailcap.c: First implementation of rfc1524.
* include/mailutils/mailcap.h: First implementation of rfc1524.
2003-02-22 Sergey Poznyakoff
* include/mailutils/header.h (MU_HEADER_FCC): New macro
* mailbox/mailer.c: Handle Fcc headers.
* mailbox/sendmail.c: Ignore Fcc.
* mailbox/smtp.c: Likewise.
* mailbox/mbx_default.c (plus_expand): Bugfix
* mailbox/mbx_mh.c (_mh_message_save): Bugfix
* mh/folder.c (action_print): Minor change
* mh/mh_argp.c (parse_opt): Pass the argument to ARG_FOLDER
without the leading '+'. This should be fixed later.
* mh/refile.c: Fixed expanding of the draftfile name.
* mh/send.c (send): Fix up the folder dir by appending a
format specifier (mh:/) to it.
* mh/mh_init.c: Moved .*_to_message stuff to mh_stream.c
* mh/mh_stream.c: Improved .*_to_message functions.
2003-02-21 Sergey Poznyakoff
* mail/testsuite/mail/folder.exp: Reflect changes to mailbox/date.c
* mail/testsuite/mail/write.exp: Likewise
2003-02-21 Sergey Poznyakoff
* configure.ac: New option --with-mh-bindir sets installation
directory for MH binaries
* mh/Makefile.am: Install binaries into a separate directory to
prevent namespace pollution.
* README: Updated
* mailbox/date.c (wdays): Two typos! Ouch...
* mh/README: Updated.
* mh/folder.c: Do not mark current folder when in fast mode
* mh/mh_whatnow.c: Execute default programs using full path
specification.
* mh/mh_stream.c: New file.
* mh/mh.h (mhdraft_stream_create): New function.
* mh/mh_init.c (mh_stream_to_message): Use MH draft streams.
2003-02-20 Sergey Poznyakoff
* mh/README: Updated
* mh/TODO: Updated
* mh/refile.c: New option --copy.
Properly handle trailing folder names. As a side-effect
it accepts messages and folders given in any order. Good!
* mh/mh_argp.c (parse_opt): Call the handler with ARG_FOLDER
key if argument starts with +.
* mh/anno.c (opt_handler): Removed superfluous case '+'.
* mh/comp.c: Likewise.
* mh/folder.c: Likewise.
* mh/inc.c: Likewise.
* mh/mark.c: Likewise.
* mh/mhl.c: Likewise.
* mh/mhpath.c: Likewise.
* mh/pick.c: Likewise.
* mh/repl.c: Likewise.
* mh/rmf.c: Likewise.
* mh/rmm.c: Likewise.
* mh/scan.c: Likewise.
2003-02-18 Sergey Poznyakoff
* configure.ac: Provide a replacement for vsyslog
* lib/vsyslog.c: New file.
* lib/Makefile.am: Add vsyslog.c
* mh/README: Minor changes.
* mh/TODO: Minor changes.
* mh/mh.h (MHA_REQUIRED,MHA_OPTARG,MHA_OPT_CLEAR): New defines.
* mh/mh_fmtgram.y (mh_code_builtin): Minor fix.
* mh/mh_format.c (builtin_me): Enclose the address in <> brackets.
(builtin_formataddr): Minor fix.
(builtin_tab): Fixed optarg column.
2003-02-16 Sergey Poznyakoff
The sources up to here are tagged rel_0_3.
* libmu_scm/Makefile.am: Use $< only in implicit rules. Non-gnu
implementation of make expand it to a null string if used
within an explicit rule.
* mh/Makefile.am: Likewise.
2003-02-16 Sergey Poznyakoff
* configure.ac: Added check for declaration of strerror.
Raised version number to 0.3
* NEWS: Updated
* guimb/Makefile.am: Added $(top_srcdir)/mailbox to INCLUDES.
* guimb/guimb.h: Include <getline.h>
* mail/mail.h (util_noapp): Added prototype.
* mail/msgset.y: Declaration of check_set().
* mail.remote/mail.remote.c: Include <mailutils/error.h>
* mailbox/date.c: Added a clarifying comment.
* mailbox/stream.c (stream_seek): Fixed type of size auto
variable.
* mh/mh_sequence.c: New file.
* mh/pick.h: New file.
* mh/pick.y: New file.
* mh/pick.c: Implemented.
* mh/Makefile.am: Added mh_sequence.c and pick.y. Provide
for multiple parsers within an application.
* mh/.cvsignore: Updated.
* mh/README: Updated
* mh/TODO: Updated
* mh/mh.h (mh_seq_add, mh_seq_delete, mh_seq_read): New functions.
* mh/mh_argp.c (parse_opt): Pass argp_state to the handler
(my_argp_parse): Changed declaration. The new argument `flags'
is accepted. Use my_argp_parse() wrapper instead of
argp_parse().
* mh/mh_getopt.h: Updated.
* mh/anno.c: Changed invocation of mh_argp_parse and updated
the definition of opt_handler.
* mh/comp.c: Likewise.
* mh/mhl.c: Likewise.
* mh/mhpath.c: Likewise.
* mh/refile.c: Likewise.
* mh/repl.c: Likewise.
* mh/rmf.c: Likewise.
* mh/rmm.c: Likewise.
* mh/scan.c: Likewise.
* mh/send.c: Likewise.
* mh/whatnow.c: Likewise.
* mh/fmtcheck.c: Likewise.
* mh/folder.c: Likewise.
* mh/inc.c: Likewise.
* mh/install-mh.c: Likewise.
* mh/mark.c: Likewise. Use new mh_sequence functions.
* doc/texinfo/fdl.texi: Minor change.
* doc/texinfo/programs.texi: Advice on how to use mail.local
with SQL authentication.
2003-02-14 Wojciech Polak
* po/POTFILES.in: Added auth/tls.c.
* doc/texinfo/mailutils.texi: Updated copyright year.
2003-02-14 Sergey Poznyakoff
* mail/msgset.y: Bugfix. '*' should not select deleted
messages.
* mail/next.c: Skip deleted messages.
* mail/previous.c: Likewise.
* mail/undelete.c (undelete0): Set cursor if it is zero.
* mh/pick.c: New file. A framework for pick command
* mh/Makefile.am: Added pick.c
* mh/.cvsignore: Likewise.
* mh/mh_getopt.h: Updated.
* mh/mh_init.c (mh_real_install): Create inbox.
* mh/refile.c: Fixed copyright year.
* mh/send.c: Get personal data from the value of the profile
component "signature" or from the environment variable
SIGNATURE.
2003-02-14 Sergey Poznyakoff
* configure.ac: New option --enable-mh-utils.
Added check for Emacs lisp directory
* include/mailutils/address.h (address_get_nth): New function.
Get Nth subaddress from an address.
* mailbox/address.c: Likewise.
* mh/mailutils-mh.eli: New file. Source for mailutils-mh.el --
an elisp module that configures mh-e.el for use with mailutils.
* mh/Makefile.am: Added rules for generating mailutils-mh.el
* mh/mh_format.c (builtin_formataddr): Rewritten to prevent
formatting the duplicate addresses.
(builtin_putaddr): Use print_hdr_string to format output string.
* po/POTFILES.in: Added more files.
* README: Updated
* mh/README: Updated
2003-02-13 Sergey Poznyakoff
* imap4d/append.c (imap4d_append): Bugfix.
* include/mailutils/stream.h (stream_seek): New function.
* mailbox/stream.c: Likewise.
* mailbox/mbx_mh.c (_mh_message_save): Check if the envelope
date has a newline.
* mailbox/message.c (message_size): Bugfix. Retrieve
the header and the body with appropriate calls instead of
addressing corresponding members of the message_t structure.
* mh/mh_list.c: New file. The parser and run-time driver for
mhl format files.
* mh/mhl.format: New file. The default format for mhl.
* mh/Makefile.am: Added mh_list.c and mhl.format.
* mh/folder.c: Use ARG_ macros instead of single-char option
letters.
* mh/mh_getopt.h: Added new ARG_ macros.
* mh/mh.h (mh_file_to_message,mh_stream_to_message): New
functions.
(mhl_format_compile,mhl_format_run,mhl_format_destroy):
New functions.
* mh/mh_init.c (mh_file_to_message,mh_stream_to_message): New
functions.
* mh/mh_fmtgram.y (mh_format_parse): Bugfix. Initialize prog to
zero.
* mh/mh_format.c (mh_format_str): New function.
* mh/mhl.c: Finished.
* mh/repl.c: Handle --filter argument.
* mh/send.c: Use mh_.*_to_message.
* mh/README: Updated.
* mh/TODO: Updated.
* NEWS: Updated.
2003-02-12 Sergey Poznyakoff
* mailbox/file_stream.c (prog_stream_create): New function.
Creates a stream connected to the stdin or stdout of
a given program.
* include/mailutils/stream.h (prog_stream_create): New function.
* mh/mhl.c: New file. A framework for mhl program.
* mh/Makefile.am: Added mhl
* mh/.cvsignore: Likewise.
* mh/TODO: Updated.
* mh/mh_getopt.h: Added new ARG_ macros.
* NEWS: Added entry for version 0.3
* README: Updated.
2003-02-12 Sergey Poznyakoff
* mh/mh_format.c (builtin_formataddr): Do not include
own email unless RCPT_ME is set.
* mh/mh_init.c (mh_is_my_name): Honor Alternate-Mailboxes
variable, use wildcard matching.
2003-02-10 Wojciech Polak
* */*: Fixed and/or updated copyrights.
* README: Updated.
* auth/tls.c: Changed `--ssl-key' arg to FILE type.
2003-02-10 Frederic Gobry <frederic.gobry@smartdata.ch>
* mailbox/rfc2047.c: avoid cutting utf-8 strings in the middle of
a multibyte character.
2003-02-10 Sergey Poznyakoff
* mailbox/mbx_mh.c (mh_expunge, mh_save_attributes): Bugfix
* mh/mh.h (mh_annotate): New function.
* mh/mh_init.c: Likewise.
* mh/anno.c: Use mh_annotate
2003-02-10 Sergey Poznyakoff
* include/mailutils/header.h (MU_HEADER_ENV_SENDER,
MU_HEADER_ENV_DATE): New macros.
* mailbox/mbx_mh.c (_mh_message_save): Bugfix.
(mh_save_attributes): Implemented
* mh/install-mh.c: New file.
* mh/anno.c: New file.
* mh/mark.c: New file
* mh/Makefile.am: Added install-mh, anno and mark
* mh/.cvsignore: Likewise.
* mh/mh_global.c (mh_auto_install): New global.
(mh_read_profile): Call mh_install() if necessary.
(mh_global_sequences_iterate)
(mh_global_context_iterate): New functions.
* mh/mh_init.c (mh_install_help, mh_real_install)
(mh_install): New functions.
(mh_open_msg_file): Rewritten.
* mh/mh_whatnow.c: Implemented push command.
* mh/TODO: Updated
* mh/mh.h (mh_context_iterator): New type.
(mh_open_msg_file): Changed declaration.
(mh_install, mh_global_context_iterate)
(mh_global_sequences_iterate,mh_context_iterate)
(mh_usedraft): New functions.
* mh/mh_ctx.c (mh_context_iterate): New function.
* mh/mh_getopt.h: Added ARG_ macros.
* mh/comp.c: Fixed option handling.
* mh/fmtcheck.c: Likewise.
* mh/inc.c: Likewise.
* mh/mhpath.c: Likewise.
* mh/refile.c: Likewise.
* mh/repl.c: Likewise.
* mh/rmf.c: Likewise.
* mh/rmm.c: Likewise.
* mh/scan.c: Likewise.
* mh/whatnow.c: Likewise.
* mh/send.c: Add from: header to the outgoing message.
* po/POTFILES.in: Added new files.
2003-02-08 Sergey Poznyakoff
* mh/mh.h: Added new includes.
(mh_open_msg_file,mh_usedraft): New functions.
* mh/mh_init.c (mh_open_msg_file): New function. Based on
refile.c:open_source().
* mh/mh_whatnow.c (mh_usedraft): New function.
* mh/refile.c (open_source): Removed in favor of mh_open_msg_file().
* mh/send.c: Implemented basic functionality.
2003-02-08 Sergey Poznyakoff
* examples/decode2047.c (main): Added return statement.
* mailbox/mbx_mh.c (_mh_message_save): Allow for mh-specific
delimiter (a string of dashes) between the headers and the body.
* mailbox/mutil.c (mu_spawnvp): Bugfix, PROG was not used.
* mh/send.c: New file. A framework for send utility.
* mh/.cvsignore: Added send.
* mh/Makefile.am: Likewise.
* mh/mh_whatnow.c: Implemented refile command.
* mh/mh_getopt.h (struct mh_option): Removed `longopt' member.
* mh/comp.c: Likewise.
* mh/fmtcheck.c: Likewise.
* mh/folder.c: Likewise.
* mh/inc.c: Likewise.
* mh/mh_getopt.c: Likewise.
* mh/scan.c: Likewise.
* mh/whatnow.c: Likewise.
* mh/rmf.c: Likewise.
* mh/refile.c: Likewise.
* mh/repl.c: Likewise.
* mh/TODO: Updated
2003-02-07 Wojciech Polak
* doc/texinfo/programs.texi: Added info about WITH_GNUTLS
and WITH_GSASL to the `General Information' node.
2003-02-07 Frederic Gobry <frederic.gobry@smartdata.ch>
* mailbox/rfc2047.c: implemented a preliminary RFC2047 encoder.
2003-02-06 Sergey Poznyakoff
* libsieve/actions.c (build_mime): Call message_unref.
* mailbox/body.c (lazy_create): Removed. Use mu_tempname()
instead.
2003-02-03 Sergey Poznyakoff
* auth/Makefile.am: Removed leftover AUTH_AUTHOBJS from LIBADD
* auth/gsasl.c (buffer_grow, _gsasl_strerror): Fixed declarations.
* auth/tls.c (_tls_strerror): Fixed declaration.
* guimb/guimb.h: Added missing includes
* guimb/main.c: Removed include <mailutils/argp.h>
* imap4d/auth_gsasl.c (create_gsasl_stream,gsasl_replace_streams):
Fixed declarations.
(auth_step_base64): New function. A wrapper around
gsasl_server_step_base64 to cope with GSASL_TOO_SMALL_BUFFER
error code.
(auth_gsasl): Use auth_step_base64(). Output any surplus
data returned with GSASL_OK code (proposed by Simon Josefsson
<jas@extundo.com>)
* imap4d/bye.c (imap4d_bye0): Added missing argument to syslog.
* pop3d/extra.c (pop3d_abquit): Likewise.
* imap4d/util.c (util_set_input, util_set_output): Bugfix
* include/mailutils/stream.h (stream_set_strerror)
(stream_strerror): Changed prototype
* mailbox/stream.c: Likewise.
* mailbox/include/stream0.h (struct _stream): Changed declaration
of _strerror method.
* mailbox/file_stream.c (_file_strerror): Changed prototype
* mailbox/list.c (list_set_comparator): Bugfix.
* mailbox/mailutils-config.c: include <mu_asprintf.h>
* mailbox/monitor.c [!WITH_PTHREAD] (STATIC_UNLOCK): expand
to empty string to avoid spurious warnings.
* mailbox/mutil.c: Added missing includes
* mailbox/rfc2047.c: Likewise.
* libmu_scm/mu_body.c: Added missing typecasts.
* libmu_scm/mu_mailbox.c: Likewise.
* libmu_scm/mu_message.c: Likewise.
* libmu_scm/mu_mime.c: Likewise.
* libmu_scm/mu_scm.c: Likewise.
* mail.local/script.c (prog_mda): Removed unused variables.
* mailbox/Makefile.am (mailutils_config_CFLAGS): Added
-I${top_srcdir}/lib.
* mh/mh_format.c (print_hdr_segment): Count a tab for eight
spaces.
(builtin_concat): Compress whitespace before further processing.
* mh/mh_getopt.c: Added missing includes.
* mh/comp.c (opt_handler): Removed unused variable
2003-01-31 Sergey Poznyakoff
* mailbox/file_stream.c (_file_readline): Make sure the
terminal zero is always added.
* mh/mh.h (mh_format): Changed declaration.
(mh_format_debug): New function.
* mh/mh_format.c (mh_format): Use dynamically allocated buffer.
(builtin_printstr): Removed.
(builtin_printhdr): New function.
(builtin_putnum,builtin_putnumf)
(builtin_putstr,builtin_putstrf): Bugfix.
* mh/mh_fmtgram.y (mh_format_debug): New function.
* mh/inc.c: Updated calls to mh_format
* mh/scan.c: Likewise.
* mh/repl.c: Updated calls to mh_format.
(format_str): Use printhdr.
(make_draft): Disable interactive prompting when build_only
flag is set.
* mh/replcomps: Use printhdr.
* mh/mh_init.c (mh_read_formfile): Bugfix.
* mh/fmtcheck.c: New command line option --debug.
* mh/README: Changed printstr to printhdr
* pop3d/extra.c (pop3d_readline): Fixed misguiding diagnostics.
Check for eof.
* pop3d/signal.c (pop3d_sigchld): Don't try to print to stdout
if SIGPIPE received.
2003-01-30 Sergey Poznyakoff
* mailbox/rfc2047.c (rfc2047_decode): Bugfix.
* imap4d/idle.c: Fixed wording of OK message.
2003-01-29 Sergey Poznyakoff
* imap4d/idle.c: Do not wait for 'DONE' command longer than
timeout seconds.
* mailbox/rfc2047.c: New file. Initial implementation of
rfc2047_decode. Based on input from Kidong Lee
<brian@ahmlhs.com>.
* mailbox/Makefile.am: Added rfc2047.c
* examples/decode2047.c: New file. Test program for rfc2047
decoder functions.
* examples/Makefile.am: Added decode2047.c
* include/mailutils/errno.h (MU_ERR_BAD_2047_INPUT): New error
code.
* mailbox/muerrno.c: Likewise.
* include/mailutils/mime.h (rfc2047_decode): New function.
* mailbox/testsuite/RFC2047: New file. Test data for rfc 2047.
* mailbox/testsuite/Makefile.am: Added RFC2047
* mailbox/testsuite/mailbox/rfc2047.exp: New file. Testcase for
decoding rfc 2047 strings.
* mailbox/testsuite/mailbox/DISTFILES: Added rfc2047.exp
2003-01-28 Sergey Poznyakoff
* auth/gsasl.c (_gsasl_get_fd): New function.
(gsasl_stream_create): Install _get_fd method
* auth/tls.c (_tls_get_fd): New function.
(tls_stream_create): Install _get_fd method
* imap4d/idle.c: New file. Implements IDLE command
(rfc 2177)
* imap4d/Makefile.am: Added imap4d/idle.c
* imap4d/capability.c (imap4d_capability_init): Announce
IDLE capability.
* imap4d/commands.c: Added entry for IDLE command.
* imap4d/imap4d.h (imap4d_idle, util_wait_input): New functions.
* imap4d/util.c (util_wait_input): New function.
* imap4d/noop.c: Removed misleading comment.
* imap4d/testsuite/imap4d/anystate.exp: Reflect IDLE capability.
2003-01-28 Sergey Poznyakoff
* comsat/comsat.c: Removed unneeded colon in the argument to perror.
* imap4d/imap4d.c: Likewise.
* guimb/main.c: Fixed help output.
* mailbox/mailutils-config.c: Likewise.
2003-01-26 Sergey Poznyakoff
* imap4d/auth_gss.c: Removed newline from the syslog diagnostic
message.
* imap4d/bye.c: Cleaned wording in diagnostics.
* imap4d/search.c: Likewise.
* libsieve/require.c: Likewise.
* mailbox/mu_argp.c: Likewise.
* mh/mh_fmtgram.y: Likewise.
* mh/mh_format.c: Likewise.
* pop3d/extra.c: Likewise.
* sieve/sieve.c: Likewise.
* mail/summary.c: Use ngettext
* mh/folder.c: Likewise.
* mh/refile.c: Likewise.
* mh/repl.c: Likewise.
* pop3d/user.c: Likewise.
* mail.remote/mail.remote.c: Use mu_error instead of fprintf
* readmsg/readmsg.c: Likewise.
* mh/comp.c: Fixed use of OPTION_DOC options.
* mh/fmtcheck.c: Likewise.
* mh/inc.c: Likewise.
* mh/mhpath.c: Likewise.
* mh/rmf.c: Likewise.
2003-01-23 Wojciech Polak
* mailbox/mu_argp.c: Added WITH_GNUTLS and WITH_GSASL
to `mu_conf_option'.
2003-01-23 Wojciech Polak
* doc/texinfo/programs.texi: Added the 'encryption' node.
2003-01-23 Sergey Poznyakoff
* libsieve/util.c (_comp_action): Bugfix. Incorrectly handled
multiple patterns.
* sieve/testsuite/scripts/mul-addr.sv: New file. Script for
testing "multiple patterns" bug.
* sieve/testsuite/sieve/mul-addr.exp: New file. Testcase for
"multiple patterns" bug.
* sieve/testsuite/scripts/DISTFILES: Updated
* sieve/testsuite/sieve/DISTFILES: Updated
* imap4d/auth_gsasl.c: Removed leftover "while"
2003-01-22 Sergey Poznyakoff
Renamed mu_errstring to mu_strerror for consistency
with usual practice.
Files affected:
* comsat/comsat.c
* dotlock/dotlock.c
* examples/http.c
* examples/mimetest.c
* examples/msg-send.c
* examples/mta.c
* examples/sfrom.c
* examples/url-parse.c
* frm/frm.c
* from/from.c
* guimb/collect.c
* imap4d/auth_gsasl.c
* imap4d/select.c
* include/mailutils/errno.h
* libsieve/actions.c
* libsieve/argp.c
* libsieve/prog.c
* libsieve/require.c
* libsieve/runtime.c
* libsieve/sieve.l
* mail/alt.c
* mail/file.c
* mail/mail.c
* mail/send.c
* mail/util.c
* mail/var.c
* mail.local/main.c
* mail.remote/mail.remote.c
* mailbox/mbx_mbox.c
* mailbox/mbx_pop.c
* mailbox/message.c
* mailbox/mu_argp.c
* mailbox/muerrno.c
* mailbox/wicket.c
* mh/comp.c
* mh/inc.c
* mh/mh_ctx.c
* mh/mh_init.c
* mh/mh_msgset.c
* mh/mh_whatnow.c
* mh/refile.c
* mh/repl.c
* pop3d/apop.c
* pop3d/lock.c
* readmsg/readmsg.c
* sieve/sieve.c
2003-01-22 Sergey Poznyakoff
* configure.ac: Raised version number to 0.2.2
Added support for cram-md5 password file
* auth/Makefile.am: Define SITE_CRAM_MD5_PWD
* auth/gsasl.c: Implemented gsasl stream. Added
argp stuff.
* imap4d/auth_gsasl.c (auth_gsasl): Make sure the
streams are reset after issuing OK tagged response.
* imap4d/imap4d.c (imap4d_capa): Require "gsasl" capability
if compiled with gsasl support.
(main): Call auth_.*_init's after mu_argp_parse.
* imap4d/imap4d.h (util_get_input, util_get_output)
(util_set_input, util_set_output): New functions.
(util_register_event, util_event_remove, util_run_events): New
functions.
* imap4d/util.c (util_finish): Check event queue if the
state has changed.
(util_register_event, util_event_remove, util_run_events): New
functions.
* include/mailutils/gsasl.h (gsasl_stream_create): Changed
declaration.
(mu_gsasl_init_argp): New function.
(gsasl_cram_md5_pwd): New global.
* mailbox/stream.c (stream_sequential_readline, stream_strerror):
Check for stream == NULL.
* imap4d/store.c (imap4d_store0): Fixed STORE untagged output in
accordance with rfc2060-errata document.
* imap4d/fetch.c (fetch_flags0): Likewise.
* imap4d/testsuite/imap4d/expunge.exp: Likewise.
* imap4d/testsuite/imap4d/fetch.exp: Likewise.
* imap4d/testsuite/imap4d/search.exp: Likewise.
* doc/rfc/rfc2177.txt: New file.
* doc/rfc/Makefile.am: Added rfc2177.txt
2003-01-22 Sergey Poznyakoff
* configure.ac: Renamed AUTHOBJS to IMAP_AUTHOBJS for
clarity. Added call to MU_CHECK_GSASL.
* m4/gsasl.m4: New file. Detect the presence of libgsasl library.
* m4/Makefile.am: Added gsasl.m4
* auth/gsasl.c: New file. Placeholder for gsasl stream support.
* auth/Makefile.am: Added gsasl.c.
* auth/tls.c: Include stdlib.h
(mu_deinit_tls_libs): Changed return type to void
* imap4d/Makefile.am: Renamed AUTHOBJS to IMAP_AUTHOBJS.
* imap4d/authenticate.c: Rewritten capability and authentication
systems.
* imap4d/capability.c: Use comparator function for list deletions.
* imap4d/imap4d.c (tls_available,tls_done): Removed.
(main): Call auth_gssapi_init, auth_gsasl_init
* imap4d/imap4d.h (tls_available,tls_done): Removed.
(starttls_init,util_atexit): New functions.
(imap4d_auth_handler_fp): New data type.
(auth_gssapi_init,auth_gsasl_init): New functions/macros
* imap4d/starttls.c (tls_available,tls_done): Static variables.
(imap4d_starttls): Register mu_deinit_tls_libs as an 'atexit'
function.
(starttls_init): New function.
* imap4d/util.c (util_setio): Make sure both streams are
line-buffered.
(util_get_input,util_get_output)
(util_set_input,util_set_output): New functions for manipulating
io streams.
(util_atexit): New function.
* imap4d/auth_gss.c (auth_gssapi): Changed declaration and return
values to match new authentication framework.
(auth_gssapi_init): New function
* imap4d/auth_gsasl.c: New file.
* include/mailutils/list.h (list_comparator_t): New datatype.
(list_set_comparator): New function
* include/mailutils/tls.h (mu_deinit_tls_libs): Changed type
to void.
* include/mailutils/gsasl.h: New file.
* include/mailutils/Makefile.am: Added gsasl.h.
* mailbox/include/list0.h (struct _list): New member comp.
* mailbox/list.c (list_set_comparator): New function.
(list_remove, list_replace): Use list->comp for
comparing list items with the supplied data.
* pop3d/extra.c (pop3d_setio): Make sure both streams are
line-buffered.
* mailbox/.cvsignore: Updated
2003-01-21 Sergey Poznyakoff
Implemented LOGINDISABLED.
* imap4d/capability.c (imap4d_capability_add)
(imap4d_capability_remove, imap4d_capability_init): New
functions.
* imap4d/imap4d.h: Likewise.
* imap4d/imap4d.c (login_disabled): New global.
(argp_option options): Added --login-disabled option.
(imap4d_parse_opt): Handle --login-disabled option.
(main): Call imap4d_capability_init().
Register "STARTTLS" capability if tls is OK.
* imap4d/starttls.c: When TLS negotiation succeeds, remove
"STARTTLS" capability and reset login_disabled.
* imap4d/login.c: Fail if login_disabled is set.
* imap4d/util.c (util_msgset): Edited comment.
(util_start,util_getstate): Removed.
2003-01-20 Sergey Poznyakoff
* configure.ac: Invoke AM_GNU_GETTEXT with no-libtool,
need-ngettext
* lib/Makefile.am (INCLUDES): Added @INTLINCS@
* lib/posix/regex.h: Define __restrict_arr to empty string
unless it was already defined elsewhere.
* m4/tls.m4: Reverted order of checks for libgnutls
and libgcrypt.
* mailbox/Makefile.am (mailutils_config_CFLAGS): Define I18NLIBS.
* mailbox/mailutils-config.c (main): Use I18NLIBS instead of
hardcoding library names.
* THANKS: Added Simon Josefsson
2003-01-19 Wojciech Polak
* auth/tls.c (mu_check_tls_environment): Removed file permissions
check for `ssl_cert'. Thanks Simon Josefsson for reporting.
2003-01-18 Sergey Poznyakoff
* imap4d/util.c (util_token): Fixed comment.
* mailbox/mbx_mh.c (mh_check_message): New function.
(mh_body_size,mh_check_message,mh_header_size)
(mh_header_lines): Use mh_check_message() to make sure
the message has been scanned.
* mh/comp.c: New file. Implements comp utility.
* mh/Makefile.am: Added comp.
* mh/mh.h (mh_err_memory,mh_file_copy): New functions.
* mh/mh_init.c: Likewise.
* mh/mh_argp.c: Use mh_err_memory to report low memory
diagnostics.
* mh/mh_ctx.c: Likewise.
* mh/mh_msgset.c: Likewise.
* mh/mh_whatnow.c: Likewise.
* mh/repl.c: Changed semantics of --use option. It takes an
optional argument of yes/no.
(make_draft): Changed declaration.
* mh/TODO: Updated.
* mh/README: Updated.
2003-01-18 Wojciech Polak
* imap4d/util.c (util_bye): Check 'tls_available' before
calling mu_deinit_tls_libs(). Just for make sure...
* pop3d/extra.c (pop3d_bye): Likewise.
2003-01-18 Sergey Poznyakoff
* include/mailutils/stream.h (stream_set_strerror)
(stream_sequential_read,stream_sequential_readline)
(stream_sequential_write,stream_strerror): New functions.
* include/mailutils/tls.h: Removed inclusion of gnutls.h
(tls_stream_create): New declaration.
(mu_check_tls_environment, mu_init_tls_libs)
(mu_deinit_tls_libs): Added prototypes.
* mailbox/file_stream.c (_file_strerror): New function.
(file_stream_create): Register strerror function.
(stdio_stream_create): Enable caching only if the
file is not seekable and MU_STREAM_SEEKABLE bit is
set in flags. Register different sets of
(read,readline,write) handlers depending on the
setting of MU_STREAM_SEEKABLE bit.
* mailbox/include/stream0.h (struct _stream): Removed
unused member `roff'. Added new member `offset' for
support of sequential access functions.
(_strerror): New method. Return stream-specific
error description (if any).
* mailbox/stream.c (stream_set_strerror): New function.
(stream_sequential_read,stream_sequential_readline)
(stream_sequential_write): New functions for sequential
access to stream.
(stream_strerror): New function. Return stream-specific
error description (if any).
* auth/tls.c: Implemented TLS streams. All tls-specific details
are now hidden within this module.
* examples/base64.c: Use sequential access for the output stream
* examples/msg-send.c: Open stdio stream with MU_STREAM_SEEKABLE
bit set.
* mail.remote/mail.remote.c: Likewise.
* imap4d/bye.c (imap4d_bye0): Use util_is_master() and util_bye()
* imap4d/imap4d.c (imap4d_mainloop): Changed proto following
that of pop3.
* imap4d/imap4d.h (util_setio): Changed declaration.
(util_is_ofile): Removed.
(util_is_master): New.
(imap4d_deinit_tls_server): Removed.
* imap4d/signal.c (imap4d_signal): Use util_is_master().
* imap4d/starttls.c (imap4d_starttls): Flush output
before initializing tls.
* imap4d/util.c (ifile, ofile, sfile): Removed.
(istream, ostream): New statics.
(util_send_lowlevel): Removed
(util_send, util_out, util_finish, imap4d_readline)
(util_flush_output): Rewritten using streams.
(util_setio): Changed argument types
(util_is_ofile): Removed.
(util_is_master): New function.
(imap4d_init_tls_server): Rewritten using TLS streams.
(imap4d_deinit_tls_server): Removed.
(util_bye): New function.
* pop3d/extra.c (ifile, ofile): Removed.
(istream, ostream): New streams.
(pop3d_setio,pop3d_init_tls_server): Rewritten using streams.
(pop3d_flush_output,pop3d_is_master): Likewise.
(pop3d_outf,pop3d_readline): Likewise.
(pop3d_deinit_tls_server): Removed.
(pop3d_bye): New function.
* pop3d/pop3d.c (pop3d_mainloop): use pop3d_bye().
* mh/mh_format.c (builtin_references): Fixed typo.
(builtin_package, builtin_package_string)
(builtin_version): New functions.
* mh/replcomps: Emit X-Mailer header.
* mh/repl.c (format_str): Likewise.
* mh/README: Updated
2003-01-17 Wojciech Polak
* imap4d/capability.c: Small fix.
2003-01-17 Wojciech Polak
* imap4d/imap4d.c: Added TLS support.
(ifile, ofile): Removed globals.
(tls_available, tls_done): Added globals.
* imap4d/imap4d.h: Include <mailutils/tls.h>
(ifile, ofile): Removed declarations.
(tls_available, tls_done): Added declarations.
(imap4d_starttls): Added prototype.
(imap4d_init_tls_server): Likewise.
(imap4d_deinit_tls_server): Likewise.
(util_setio): Likewise.
(util_flush_output): Likewise.
(util_is_ofile): Likewise.
(imap4d_readline_ex): Changed prototype. Use void instead of FILE *.
(imap4d_readline): Likewise.
(ERR_TLS): New define.
* imap4d/starttls.c: New file. The STARTTLS command support.
* imap4d/util.c: Added TLS support (via GnuTLS).
(ifile, ofile, sfile): Added static variables.
(util_send_lowlevel): New function.
(imap4d_init_tls_server): Likewise.
(imap4d_deinit_tls_server): Likewise.
(util_setio): Likewise.
(util_flush_output): Likewise.
(util_is_ofile): Likewise.
* imap4d/bye.c: Added TLS support.
* imap4d/commands.c: Likewise.
* imap4d/capability.c: Likewise.
* imap4d/signal.c: Use util_is_ofile().
* imap4d/Makefile.am: Updated.
2003-01-17 Sergey Poznyakoff
* imap4d/sync.c: Always return EXIST and RECENT untagged
responses. Thanks Simon Josefsson <jas@extundo.com>
for reporting.
* libmu_scm/Makefile.am (install-data-hook): Bugfix.
2003-01-17 Sergey Poznyakoff
* pop3d/extra.c (pop3d_readline): Bugfix: add terminating
zero, and check return value from gnutls_record_recv.
* pop3d/pop3d.h (ERR_TLS_IO): New def.
2003-01-16 Sergey Poznyakoff
* mh/mh_getopt.c (mh_getopt): Bugfix
* mh/mh.h (struct mh_whatnow_env): Added `draftfile' member.
* mh/mh_whatnow.c: Reorganized. Implemented disposition
shell.
* mh/repl.c: Handle draft file. Added --use option.
* mh/README: Updated.
2003-01-16 Sergey Poznyakoff
* include/mailutils/mutil.h (mu_rfc2822_references)
(mu_rfc2822_in_reply_to): New functions.
* mail/reply.c (concat,strip_message_id)
(get_msgid_header): Removed
(make_in_reply_to,make_references): Rewritten using new rfc2822
functions.
* mailbox/mutil.c (mu_rfc2822_references)
(mu_rfc2822_in_reply_to): New functions.
* mh/replcomps: New file. Default format for repl utility.
* mh/Makefile.am: Added mhlibdir
* mh/mh_getopt.h (struct mh_option): Replaced `int key'
with `char *longopt'.
(mh_argv_preproc): New function.
(mh_optind,mh_optarg): Globals removed.
* mh/mh_argp.c (struct mh_argp_data): Moved to mh_getopt.h
(parse_opt,mh_argp_parse): Rewritten. Argument parsing goes
in two stages: first any old-style mh arguments are expanded
to corresponding GNU long options, then argp_parse is run
over the constructed argv array.
* mh/mh_getopt.c (mh_getopt): Rewritten. The main purpose is
to expand old-style options to their double-dash equivalents.
(mh_argv_preproc): New function. Preprocess the argv array.
* mh/mh_fmtgram.y (want_arg): New lexical tie-in to correctly
process trailing whitespace in calls like %(putaddr To: ).
* mh/mh_format.c (builtin_in_reply_to, builtin_references):
New functions. Interfaces to rfc2822 functions.
* mh/mh.h (RCPT_DEFAULT): Default value for rcpt_mask
* mh/mh_global.c: Initialize rcpt_mask with RCPT_DEFAULT.
* mh/mh_init.c (mh_expand_name): Correctly handle full and
relative pathname specifications.
* mh/fmtcheck.c: Use new struct mh_option
* mh/folder.c: Likewise.
* mh/inc.c: Likewise.
* mh/refile.c: Likewise.
* mh/repl.c: Likewise.
* mh/rmf.c: Likewise.
* mh/scan.c: Likewise.
* mh/whatnow.c: Likewise.
* mh/README: Updated.
* mh/TODO: Updated.
2003-01-15 Wojciech Polak
* auth/tls.c: Fixed typo.
* pop3d/pop3d.h (pop3d_init_tls_server): Added prototype.
(pop3d_deinit_tls_server): Likewise.
* pop3d/pop3d.c: Fixed TLS cleanup.
2003-01-15 Sergey Poznyakoff
* m4/db2.m4: Fixed version reference in the comment.
* mail/msgset.y: Added missing NLS markers.
* mailbox/mutil.c: Fixed indentation.
* mh/mh_whatnow.c: New file.
* mh/whatnow.c: New file. Source for whatnow utility.
* mh/Makefile.am: Removed unnecessary _SOURCE declarations.
Added new files and targets.
* mh/mh.h: Include argcv.h and getline.h
(struct mh_whatnow_env): New datatype.
(mh_spawnp, mh_whatnow): New functions.
* mh/mh_argp.c (mh_argp_parse): Fixed parsing order: global
profile arguments first, then the command line arguments.
* mh/mh_format.c: Added missing NLS markers.
(builtin_concat,builtin_printstr): New functions.
* mh/mh_init.c (mh_spawnp): New function.
* mh/repl.c: Almost finished.
* mh/mh_ctx.c: Shut compiler warnings.
* mh/TODO: Updated.
* mh/README: Updated.
* mh/.cvsignore: Updated.
* po/POTFILES.in: Added missing files.
2003-01-14 Wojciech Polak
* auth/tls.c (mu_init_tls_libs): gnutls_global_init() returns
zero on success, so reverse this state for 'tls_available'
variable.
2003-01-14 Sergey Poznyakoff
* m4/db2.m4: New file. Version-specific stuff for Berkeley DB.
* m4/tls.m4: Added copyleft header.
* m4/Makefile.am: Added db2.m4
* configure.ac: Check for newer version of Berkeley DB
* lib/mu_dbm.c [WITH_BDB2] (mu_dbm_firstkey): db->cursor
takes three or four arguments, depending on the release
of DB 2. Take care of it.
* auth/tls.c (mu_init_tls_server): Check return value from
gnutls_certificate_set_x509_key_file(). Use gnutls_strerror(),
instead of gnutls_perror(), as the latter confuses mail clients.
(mu_init_tls_libs): Removed useless initialization of the auto
variable.
* mail/mail.h (msgset_parse,util_get_message):
In order to get rid of superfluous 'Inappropriate message'
diagnostics and provide a behaviour consistent with that
of standard implementations, moved the flags argument
from util_get_message to msgset_parse.
(msgset_count): New function.
(util_isdeleted): Reverted to older declaration (before
2002-10-13).
* mail/msgset.y (msgset_parse): Take a new argument: flags
(meaning the same as in the util_get_message call).
(msgset_count): New function.
* mail/util.c (util_foreach_msg,util_range_msg): Updated
calls to msgset_parse.
(util_isdeleted): Reverted to older declaration.
* mail/copy.c: Updated calls to msgset_parse.
* mail/decode.c: Likewise.
* mail/delete.c: Likewise.
* mail/eq.c: Likewise.
* mail/followup.c: Likewise.
* mail/from.c: Likewise.
* mail/headers.c: Likewise.
* mail/next.c: Likewise.
* mail/pipe.c: Likewise.
* mail/previous.c: Likewise.
* mail/quit.c: Likewise.
* mail/tag.c: Likewise.
* mail/write.c: Likewise.
2003-01-14 Wojciech Polak
* pop3d/pop3d.h (ERR_TLS_ACTIVE, TLS_ACTIVE): New defines.
* pop3d/pop3d.c: Added support for ERR_TLS_ACTIVE.
* pop3d/stls.c: Likewise.
* doc/rfc/Makefile.am: Added rfc2595.txt
* TODO: Updated.
2003-01-13 Wojciech Polak
* auth/tls.c: New file. Added main TLS/SSL code (via GnuTLS).
* include/mailutils/tls.h: New file. TLS header file.
* auth/Makefile.am: Updated.
* include/mailutils/Makefile.am: Likewise.
* pop3d/pop3d.c: Added TLS support.
* pop3d/pop3d.h: include <mailutils/tls.h>
(pop3d_stls): New prototype.
* pop3d/stls.c: New file. The STLS command support.
* pop3d/extra.c (pop3d_init_tls_server): New function.
(pop3d_deinit_tls_server): New function.
(pop3d_outf): Added TLS support (GnuTLS).
(pop3d_readline): Added TLS support (GnuTLS).
* pop3d/capa.c (pop3d_capa): Added STLS.
* pop3d/Makefile.am: Updated.
* m4/tls.m4: New file. Implements MU_CHECK_TLS defun.
* m4/Makefile.am: Updated.
* configure.ac: Added GnuTLS support (--with-gnutls).
2003-01-13 Sergey Poznyakoff
* m4/gssapi.m4: Fixed typo.
* mh/mh.h (RCPT_NONE,RCPT_TO,RCPT_ME,RCPT_ALL): New defines.
(rcpt_mask): New global declaration.
(mh_get_message): Added missing __P().
(mh_decode_rcpt_flag): New function.
* mh/mh_format.c (mh_decode_rcpt_flag,builtin_rcpt): New
functions.
* mh/mh_global.c (rcpt_mask): New global. Keeps cumulative
value of all --cc/--nocc command line options.
* mh/repl.c: Changed default format to use (rcpt) to decide
whether or not to include an address to the cc: header.
Implemented --cc/--nocc.
* mh/README: New file. A list of differences from standard
MH implementation.
2003-01-12 Wojciech Polak
* auth/sql.c: Added missing NLS markers.
2003-01-12 Jordi Mallach <jordi@gnu.org>
* mail/mail.c: Update year in copyright notice.
2003-01-12 Sergey Poznyakoff
* imap4d/fetch.c: Properly quote return strings.
In envelope responses emit a single NIL to represent
a non-existent envelope structures.
Thanks Nic Ferrier <nferrier@tapsellferrier.co.uk> for
reporting the bug.
* imap4d/testsuite/imap4d/fetch.exp: Test new fetch responses.
* imap4d/testsuite/imap4d/create.exp: Likewise.
2003-01-11 Sergey Poznyakoff
* mailbox/mbx_mh.c (mh_scan0): Do not actually read
contents of the message files, only register them in
the message pool.
Moved notification into a separate loop. This way
observable action receives notifications
in the proper order.
* mh/mh_format.c (builtin_unre): New function. Implements
extension format function 'unre': remove leading whitespace
and eventual 're:' prefix from the subject header line.
* mh/mh.h (mh_expand_name): Changed declaration.
* mh/mh_init.c: Likewise.
* mh/mh_global.c: Changed calls to mh_expand_name.
* mh/refile.c: Likewise.
* mh/rmf.c: Likewise.
* mh/scan.c: When called without arguments do the work by
installing observable action. This speeds up execution
by the factor of three.
* mh/repl.c: Added --build option. Implemented --[no]draftfolder
--[no]query.
2003-01-10 Sergey Poznyakoff
* libmu_scm/Makefile.am (mailutils.scm target): Bugfix. Use $<
instead of $?.
* libmu_scm/mailutils.scm.in: Explicitly load libmailbox before
loading libmu_scm. Fixed 1.6 branch of the conditional.
2003-01-10 Sergey Poznyakoff
* lib/posix/regex.h: Removed redefinition of __restrict_arr
* libsieve/comparator.c (comp_false): Fixed declaration.
(sieve_match_part_checker): shut compiler warnings
about possibly uninitialized variables.
* libsieve/sieve.h: include <string.h>
* libsieve/tests.c (sieve_test_address,sieve_test_header): Removed
unused variables.
* examples/.cvsignore: Added base64
2003-01-06 Sergey Poznyakoff
* doc/texinfo/libsieve.texi: Reflect recent changes to
libsieve.
* pop3d/extra.c (pop3d_setio, pop3d_flush_output)
(pop3d_is_master): New functions.
(pop3d_readline): Fixed prototype: second arg should be size_t.
* pop3d/pop3d.c (ifile,ofile): Removed globals.
(pop3d_mainloop): Changed declaration.
* pop3d/pop3d.h (ifile,ofile): Removed declarations.
(getpwnam_ip_virtual,getpwnam_host_virtual): Removed
prototypes.
(pop3d_setio, pop3d_flush_output, pop3d_is_master): New
functions.
(pop3d_readline): Fixed prototype.
* pop3d/signal.c (pop3d_signal): Use pop3d_is_master().
* pop3d/user.c (pop3d_user): Use pop3d_flush_output().
2003-01-06 Sergey Poznyakoff
* libsieve/tests.c
(do_count): New function. A common handler for :count tag.
(retrieve_header): Use header_get_field_{name|value}, since
header_aget_value cannot return multiple header values.
(sieve_test_address,sieve_test_header,sieve_test_envelope):
Use do_count.
* sieve/testsuite/sieve/relational.exp: Enabled rel-header.sv
testcase.
* libsieve/require.c: Handle "relational" as a special case.
* libsieve/sieve.h: Updated.
* libsieve/sieve.l (multiline_strip_tabs): Forward declaration.
* libsieve/util.c (sieve_tag_lookup): Check for taglist != NULL
before calling list_do().
2003-01-05 Sergey Poznyakoff
* doc/rfc/rfc3431.txt: New file.
* doc/rfc/Makefile.am: Add rfc3431.txt
* testsuite/spool/relational.mbox: Mailbox for testing relational
operations in sieve.
* testsuite/spool/DISTFILES (relational.mbox): Added.
* include/mailutils/libsieve.h (sieve_relcmp_t,sieve_relcmpn_t):
New types.
(sieve_register_comparator): Changed prototype.
(sieve_require_relational,sieve_str_to_relcmp)
(sieve_get_relcmp): New functions.
* libsieve/relational.c: New file.
* libsieve/Makefile.am: Added relational.c.
* libsieve/comparator.c (sieve_register_comparator)
(_find_comparator,comp_false,sieve_match_part_checker):
Added support for relational tests.
* libsieve/tests.c (sieve_test_address,sieve_test_header):
Likewise.
* sieve/testsuite/scripts/rel-address.sv: New file.
* sieve/testsuite/scripts/rel-hairy.sv: New file.
* sieve/testsuite/scripts/rel-header.sv: New file.
* sieve/testsuite/scripts/DISTFILES (rel-address.sv,rel-hairy.sv)
(rel-header.sv): New files
* sieve/testsuite/sieve/relational.exp: New file.
* sieve/testsuite/sieve/DISTFILES (relational.exp): Added
* mail/z.c (mail_z): Fixed scrolling.
* po/POTFILES.in: Added libsieve/relational.c.
2003-01-03 Wojciech Polak
* pop3d/extra.c (pop3d_readline): Don't use `static char buffer[512]'.
Use also ifile directly instead of FILE *fp.
* pop3d/pop3d.h (pop3d_readline): Changed prototype.
* pop3d/pop3d.c: Use pop3d_readline(buffer, sizeof (buffer)).
* pop3d/user.c: Likewise.
2003-01-02 Sergey Poznyakoff
* configure.ac: New ac_subst variable BUILD_MH_EXEC_HOOK
* mh/Makefile.am: Enable install-exec-hook only if
BUILD_MH_EXEC_HOOK is set.
2003-01-01 Wojciech Polak
* COPYING: Removed.
2002-12-31 Jeff Bailey <jbailey@gnu.org>
* auth/Makefile.am: Correct copyright year, add license
information.
* sieve/testsuite/Makefile.am: Likewise.
* testsuite/Makefile.am: Likewise.
* sieve/Makefile.am: Likewise.
* scripts/guile-1.6/Makefile.am: Likewise.
* scripts/guile-1.4/Makefile.am: Likewise.
* scripts/Makefile.am: Likewise.
* readmsg/testsuite/Makefile.am: Likewise.
* readmsg/Makefile.am: Likewise.
* mh/Makefile.am: Likewise.
* messages/testsuite/Makefile.am: Likewise.
* messages/Makefile.am: Likewise.
* pop3d/testsuite/Makefile.am: Likewise.
* pop3d/Makefile.am: Likewise.
* mapi/Makefile.am: Likewise.
* mail.remote/testsuite/Makefile.am: Likewise.
* mail.remote/Makefile.am: Likewise.
* mail.local/testsuite/Makefile.am: Likewise.
* mail.local/Makefile.am: Likewise.
* mailbox2/pop3/Makefile.am: Likewise.
* mailbox2/mbox/Makefile.am: Likewise.
* mailbox2/include/mailutils/sys/Makefile.am: Likewise.
* mailbox2/include/mailutils/Makefile.am: Likewise.
* mailbox2/include/Makefile.am: Likewise.
* mailbox2/Makefile.am: Likewise.
* mailbox/testsuite/Makefile.am: Likewise.
* mailbox/include/Makefile.am: Likewise.
* mailbox/Makefile.am: Likewise.
* mail/testsuite/Makefile.am: Likewise.
* mail/Makefile.am: Likewise.
* m4/Makefile.am: Likewise.
* libsieve/Makefile.am: Likewise.
* libmu_scm/Makefile.am: Likewise.
* lib/posix/Makefile.am: Likewise.
* lib/Makefile.am: Likewise.
* include/mailutils/gnu/Makefile.am: Likewise.
* include/mailutils/Makefile.am: Likewise.
* include/Makefile.am: Likewise.
* imap4d/Makefile.am: Likewise.
* imap4d/testsuite/Makefile.am: Likewise.
* guimb/scm/Makefile.am: Likewise.
* guimb/Makefile.am: Likewise.
* from/testsuite/Makefile.am: Likewise.
* from/Makefile.am: Likewise.
* frm/testsuite/Makefile.am: Likewise.
* examples/Makefile.am: Likewise.
* frm/Makefile.am: Likewise.
* dotlock/Makefile.am: Likewise.
* doc/texinfo/Makefile.am: Likewise.
* doc/rfc/Makefile.am: Likewise.
* doc/man/Makefile.am: Likewise.
* doc/Makefile.am: Likewise.
* comsat/Makefile.am: Likewise.
* Makefile.am: Likewise.
* configure.ac: Update FSF Address
2002-12-31 Wojciech Polak
* COPYING: New file.
* mailutils.spec.in: Fixed.
2002-12-31 Sergey Poznyakoff
* include/mailutils/guile.h: New file. Interface declarations
for libmu_scm.h
* include/mailutils/Makefile.am: Added guile.h.
* libmu_scm/mu_scm.h: Include <mailutils/guile.h>
* libmu_scm/mu_mime.c: Removed unneeded includes.
* libmu_scm/mu_scm.c: Likewise.
* libmu_scm/mu_util.c: Likewise.
* libmu_scm/mu_guimb.c: Include "mu_scm.h"
* guimb/Makefile.am: Removed -I$(top_srcdir)/libmu_scm
* mail.local/Makefile.am: Likewise.
* mail.local/script.c: Include <mailutils/guile.h>
* mailbox/Makefile.am (mailutils_config_CFLAGS): Corrected
definition of AUTHLIBS.
* guimb/guimb.h: Added missing includes.
* include/mailutils/body.h: Use __PMT in nested declarations
for C++ compatibility.
* include/mailutils/debug.h: Likewise.
* include/mailutils/envelope.h: Likewise.
* include/mailutils/error.h: Likewise.
* include/mailutils/filter.h: Likewise.
* include/mailutils/header.h: Likewise.
* include/mailutils/message.h: Likewise.
* include/mailutils/mutil.h: Likewise.
* include/mailutils/observer.h: Likewise.
* include/mailutils/registrar.h: Likewise.
* include/mailutils/stream.h: Likewise.
* include/mailutils/attribute.h: Likewise.
* include/mailutils/auth.h: Likewise.
* include/mailutils/argp.h: Enclosed declarations in extern "C"
block.
2002-12-29 Wojciech Polak
* mail/mail.c: Updated FSF address.
* mailbox/mu_argp.c: Likewise.
* mh/mh_argp.c: Likewise.
2002-12-29 Wojciech Polak
* Makefile.am: Added "dist-bzip2" to AUTOMAKE_OPTIONS.
2002-12-29 Sergey Poznyakoff
* mail/mail.c (realcursor): Removed. The position of the point
is kept in the cursor variable.
* mail/util.c (util_msglist_command, util_msglist_esccmd): Removed.
(util_foreach_msg,util_range_msg): New functions. Iterate across
message set or range calling given function for each message.
* mail/mail.h (util_msglist_command, util_msglist_esccmd): Removed.
(realcursor): Removed.
(util_foreach_msg,util_range_msg): New functions.
* mail/delete.c: Rewritten using new iterator functions.
* mail/dp.c: Likewise.
* mail/edit.c: Likewise.
* mail/eq.c: Likewise.
* mail/file.c: Likewise.
* mail/followup.c: Likewise.
* mail/from.c: Likewise.
* mail/headers.c: Likewise.
* mail/hold.c: Likewise.
* mail/mbox.c: Likewise.
* mail/msgset.y: Likewise.
* mail/next.c: Likewise.
* mail/previous.c: Likewise.
* mail/print.c: Likewise.
* mail/reply.c: Likewise.
* mail/size.c: Likewise.
* mail/summary.c: Likewise.
* mail/top.c: Likewise.
* mail/undelete.c: Likewise.
* mail/var.c: Likewise.
* mail/visual.c: Likewise.
* mail/write.c: Likewise.
* mail/z.c: Likewise.
2002-12-29 Wojciech Polak
* auth/*: Fixed C source copyrights to be compatible with the
GNU 'Maintaining' document, i.e. "This program" -> "GNU Mailutils".
* cmc/*: Likewise.
* examples/*: Likewise.
* imap4d/*: Likewise.
* include/mailutils/*: Likewise.
* libmu_scm/*: Likewise.
* libsieve/*: Likewise.
* mailbox/*: Likewise.
* mailbox2/*: Likewise.
* mapi/*: Likewise.
* mh/*: Likewise.
* pop3d/*: Likewise.
* po/POTFILES.in: Added missing mail/msgset.y.
2002-12-29 Sergey Poznyakoff
* mail/util.c: Removed unneeded global env_cursor.
* mailbox/mailutils-config.c: Reflect addition
of NLS libraries.
2002-12-28 Sergey Poznyakoff
* dotlock/dotlock.c: Reverted today's changes. Failed experiment.
* mail.remote/mail.remote.c: Likewise.
* mail.local/main.c: Added call to mu_init_nls.
* sieve/testsuite/Redirect: Reflect changes to libsieve/actions.c.
2002-12-28 Sergey Poznyakoff
* doc/texinfo/Makefile.am: Added fdl.texi
* include/mailutils/stream.h: New flag MU_STREAM_ALLOW_LINKS:
allow links on a file. Needed for MH.
* mailbox/file_stream.c: Handle MU_STREAM_ALLOW_LINKS.
* mailbox/mbx_mh.c: Create message stream with
MU_STREAM_ALLOW_LINKS bit set.
* libsieve/actions.c: Use X-Loop-Prevention header instead
of X-Sender.
* mail/followup.c: Bugfix: do not translate header names
* mail/from.c: Bugfix: date field has always fixed length.
* mailbox/argp-help.c: include mailutils/nls.h. Otherwise
i18n is disabled.
2002-12-28 Wojciech Polak
* doc/texinfo/mailutils.texi: Fixed copyright (FDL).
* doc/texinfo/fdl.texi: New file.
2002-12-28 Sergey Poznyakoff
* dotlock/dotlock.c: Exclude '\v' from xgettext markers.
* mail.local/main.c: Likewise.
* mail.remote/mail.remote.c: Likewise.
2002-12-27 Wojciech Polak
* doc/texinfo/mailutils.texi: Use @copying.
* doc/texinfo/programs.texi: Minor formatting.
2002-12-27 Sergey Poznyakoff
* auth/Makefile.am: Added NLS support.
* auth/pam.c: Likewise.
* auth/sql.c: Likewise.
* auth/virtual.c: Likewise.
* mail/reply.c: The To: and Cc: needn't be translated.
* dotlock/dotlock.c: Added missing N_() markers.
* frm/frm.c: Likewise.
* guimb/main.c: Likewise.
* imap4d/imap4d.c: Likewise.
* libsieve/argp.c: Likewise.
* mail/mail.c: Likewise.
* mail.local/main.c: Likewise.
* mail.remote/mail.remote.c: Likewise.
* mailbox/mu_argp.c: Likewise.
* mailbox/mu_auth.c: Likewise.
* mh/fmtcheck.c: Likewise.
* mh/folder.c: Likewise.
* mh/inc.c: Likewise.
* mh/mhpath.c: Likewise.
* mh/refile.c: Likewise.
* mh/repl.c: Likewise.
* mh/rmf.c: Likewise.
* mh/rmm.c: Likewise.
* mh/scan.c: Likewise.
* readmsg/readmsg.c: Likewise.
* sieve/sieve.c: Likewise.
* pop3d/popauth.c: Likewise.
* comsat/comsat.c: Likewise.
* po/POTFILES.in: Updated
2002-12-27 Jordi Mallach <jordi@gnu.org>
* mh/inc.c: Fixed typo.
* mh/repl.c: Likewise.
2002-12-27 Sergey Poznyakoff
* configure.ac: Set version number to 0.2.1.
* mail/mail.c: Removed startup banner.
Bugfix: --quit option was handled incorrectly
* doc/texinfo/programs.texi: Removed references to `set quiet'
* mail/quit.c: Use ngettext
* mail/summary.c: Likewise.
* frm/frm.c: Likewise.
* mail/testsuite/mail/folder.exp: Reflect recent changes in
the handling of plurals.
* mail/testsuite/mail/write.exp: Likewise.
* mail.remote/Makefile.am: Added @INTLINCS@ and @LTLIBINTL@
* AUTHORS: Added Wojciech Polak.
2002-12-27 Wojciech Polak
* mail/summary.c: Small NLS improvement.
* mail/quit.c: Likewise.
* frm/frm.c: Likewise.
2002-12-26 Wojciech Polak
* po/POTFILES.in: Updated.
* dotlock/dotlock.c: Added NLS.
* from/from.c: Likewise.
* mail.remote/mail.remote.c: Likewise.
* mh/fmtcheck.c: Likewise.
* mh/folder.c: Likewise.
* mh/inc.c: Likewise.
* mh/mh_argp.c: Likewise.
* mh/mh_ctx.c: Likewise.
* mh/fmtgram.y: Likewise.
* mh/mh_getopt.c: Likewise.
* mh/mh_init.c: Likewise.
* mh/mh_msgset.c: Likewise.
* mh/mhpath.c: Likewise.
* mh/refile.c: Likewise.
* mh/repl.c: Likewise.
* mh/rmf.c: Likewise.
* mh/rmm.c: Likewise.
* mh/scan.c: Likewise.
2002-12-26 Wojciech Polak
* po/POTFILES.in: Updated.
* sieve/sieve.c: Enabled NLS.
* doc/texinfo/mailutils.texi: Small improvement.
* COPYING.FDL: The Free Documentation License has been
upgraded from 1.1 to 1.2.
2002-12-25 Wojciech Polak
* po/POTFILES.in: Updated.
* mailbox/mu_argp.c: Added NLS.
* mailbox/muerrno.c: Likewise.
* mailbox/message.c: Likewise.
* libsieve/*: Likewise.
2002-12-25 Sergey Poznyakoff
* comsat/action.c: Do not include \r\n to the i18n strings.
* pop3d/popauth.c: Fixed typo in docstring.
Thanks to Jordi Mallach for both.
2002-12-25 Sergey Poznyakoff
* imap4d/fetch.c (fetch_internaldate) Do not use %X in strftime
format: it produces locale-dependent output.
* mh/mh_format.c (mh_format): Fixed format spec.
2002-12-24 Wojciech Polak
* po/POTFILES.in: Updated.
* po/.cvsignore: Removed Makevars.
* mail.local/*: Added NLS.
* mailbox/Makefile.am: Removed "-I${top_srcdir}/intl" from INCLUDES
due to @INTLINCS@.
2002-12-24 Sergey Poznyakoff
* doc/texinfo/Makefile.am: Fixed referencing /scripts/missing
program.
* po/.cvsignore: Removed LINGUAS.
2002-12-24 Sergey Poznyakoff
* configure.ac: Specify use-libtool to AM_GNU_GETTEXT.
Define WITH_INCLUDED_LIBINTL and INTLINCS if we are using
the included gettext.
* include/mailutils/nls.h: When using included libintl, use
only intl/libgnuintl.h. Using system default libintl.h
on systems with older libintls causes random coredumps.
* mailbox/mu_argp.c (mu_conf_option): Added WITH_INCLUDED_LIBINTL.
* libsieve/sieve.l: Documented the grammar.
* po/.cvsignore: New file
* .cvsignore: Updated.
* m4/.cvsignore: Ignore gettext's m4 files.
* m4/Makefile.am: Include gettext's m4 into the distribution.
* scripts/.cvsignore: Ignore autogenerated files.
* auth/Makefile.am: Added @INTLINCS@ and @LTLIBINTL@ where
appropriate.
* comsat/Makefile.am: Likewise.
* dotlock/Makefile.am: Likewise.
* examples/Makefile.am: Likewise.
* frm/Makefile.am: Likewise.
* from/Makefile.am: Likewise.
* guimb/Makefile.am: Likewise.
* imap4d/Makefile.am: Likewise.
* libmu_scm/Makefile.am: Likewise.
* libsieve/Makefile.am: Likewise.
* mail/Makefile.am: Likewise.
* mail.local/Makefile.am: Likewise.
* mailbox/Makefile.am: Likewise.
* messages/Makefile.am: Likewise.
* mh/Makefile.am: Likewise.
* pop3d/Makefile.am: Likewise.
* readmsg/Makefile.am: Likewise.
* sieve/Makefile.am: Likewise.
2002-12-24 Wojciech Polak
* po/POTFILES.in: Updated.
* imap4d/*: Added NLS.
* guimb/*: Likewise.
* sieve/sieve.c: Likewise.
2002-12-23 Wojciech Polak <polak@gnu.org>
* po/: New directory.
* po/Makevars: New file.
* po/POTFILES.in: Likewise.
* po/LINGUAS: Likewise.
* po/ChangeLog: Likewise.
* mailbox/nls.c: New file. NLS main code.
* mailbox/Makefile.am: Updated.
* include/mailutils/nls.h: New file. NLS main header file.
* include/mailutils/Makefile.am: Updated.
* configure.ac: Added NLS support, added AC_CONFIG_AUX_DIR([scripts]).
* Makefile.am: Added 'intl po' to SUBDIRS.
* mail/*: Added NLS support.
* messages/*: Likewise.
* readmsg/*: Likewise.
* comsat/*: Likewise.
* pop3d/*: Likewise.
* frm/*: Likewise.
* mail/delete.c: Fixed. MSG_NODELETED.
2002-12-22 Jeff Bailey <jbailey@nisa.net>
* mailbox/mbx_maildir.c: Initial checking of template
* mailbox/Makefile.am: (libmailbox_la_SOURCES) Add mbx_maildir.c
2002-12-20 Sergey Poznyakoff
* libsieve/sieve.l: Implemented shell-like extension for
multiline strings. They can start now with text:[-][delimiter],
the dash meaning 'strip leading tabs', the 'delimiter'
overriding default end-of-text delimiter (.)
* doc/texinfo/libsieve.texi: Documented text:[-][delimiter]
extension.
* TODO: Updated
2002-12-16 Sergey Poznyakoff
* doc/texinfo/Makefile.am: Added trailing slash to the default
BASE_URL
* doc/texinfo/libmu_scm.texi: Fixed use of @deffn
* doc/texinfo/libmuauth.texi: Likewise.
* doc/texinfo/libsieve.texi: Likewise.
The sources are tagged "rel_0_2".
2002-12-15 Sergey Poznyakoff
* configure.ac: Raised version number to 0.2
* doc/texinfo/libmuauth.texi: Spell check.
* doc/texinfo/libsieve.texi: Likewise.
* TODO: Updated.
2002-12-14 Sergey Poznyakoff
* mail/previous.c: Skip deleted messages
* mail/next: Likewise.
* auth/sql.c (mu_auth_sql_by_uid): Fixed typo.
* include/mailutils/libsieve.h: Changed type of `number'
to size_t.
* libsieve/sieve.y (union): Likewise
* include/mailutils/mu_auth.h: Removed duplicate declaration
of mu_auth_data_free.
* libsieve/actions.c (build_mime): To improve readability,
output additional newline before reporting the reason.
* libsieve/sieve.l: Allow backslashes in quoted strings.
* sieve/testsuite/Reject: Updated
* doc/texinfo/libmu_scm.texi: New file. Documents libmu_scm
library.
* doc/texinfo/Makefile.am: Added libmu_scm.texi
* doc/texinfo/libmuauth.texi: Updated
* doc/texinfo/libsieve.texi: Updated
* doc/texinfo/mailutils.texi: Updated
* doc/texinfo/programs.texi: Updated
* doc/texinfo/imap4.texi: Updated
* doc/texinfo/mailer.texi: Updated
* TODO: Updated
* mh/TODO: New file
* NEWS: Updated
2002-12-13 Sergey Poznyakoff
* mail.local/mail.local.h: Create temporary mailbox instead of
the temporary message, to avoid problems when running sieve
fileinto.
* mail.local/main.c: Likewise.
* mail.local/script.c: Likewise.
* doc/texinfo/Makefile.am: Added rules for generating
web documentation.
* doc/texinfo/index.html.in: New file. Template for generating
web documentation index page.
* doc/texinfo/framework.texi: Updated.
* doc/texinfo/libsieve.texi: Likewise.
* doc/texinfo/mailutils.texi: Likewise.
* doc/texinfo/programs.texi: Likewise.
2002-12-12 Sergey Poznyakoff
* mail.local/main.c (_sieve_action_log): Use vasprintf.
* libsieve/sieve.l: Allow #include within a :text block
* mh/inc.c: Use mu_errstring instead of strerror.
* mh/mh_init.c (mh_open_folder): Changed default open
flags to MU_STREAM_RDWR.
2002-12-11 Sergey Poznyakoff
* examples/numaddr.c: Fixed malformed comment.
* doc/texinfo/libsieve.texi: Updated.
2002-12-11 Sergey Poznyakoff
* configure.ac: Added --enable-experimental option to enable
building of experimental/unfinished utilities. Currently it
controls mh utils.
* README: Document --enable-experimental option.
* examples/addr.c: Include string.h. Add typecasts to the
arguments of printf-like functions where necessary.
* examples/base64.c: Likewise.
* examples/mimetest.c: Add typecasts to the
arguments of printf-like functions where necessary.
* examples/mta.c: Likewise.
* mail/var.c: Likewise.
* mailbox/folder_imap.c: Likewise.
* mailbox/mbx_imap.c: Likewise.
* mailbox/mbx_mbox.c: Likewise.
* mailbox/mbx_mh.c: Likewise.
* mh/mh_global.c: Likewise.
* mh/mh_format.c (struct mh_machine): Changed type of arg_num to
long.
* imap4d/imap4d.c: Cast third argument to accept to
socklen_t*. Add typecasts to the arguments of printf-like
functions where necessary.
* pop3d/pop3d.c: Likewise.
* lib/mu_dbm.c: Include xalloc.h
* sieve/sieve.c: Include mu_asprintf.h
* examples/numaddr.c: Added extensive comments.
* doc/texinfo/libsieve.texi: Updated.
* doc/texinfo/programs.texi: Updated.
2002-12-10 Sergey Poznyakoff
* mailbox/filter_trans.c (qp_decode): Bugfix: extend chr to
accommodate three characters and terminate it with zero.
* libsieve/comparator.c (i_octet_regex): Removed misleading
comment.
* mail/mail.h: Include mu_asprintf.h
* TODO: Updated
* doc/texinfo/libsieve.texi: Likewise.
2002-12-10 Sergey Poznyakoff
* configure.ac: Define and export SIEVE_MODDIR.
* examples/Makefile.am: Use SIEVE_MODDIR.
* libsieve/Makefile.am: Likewise.
* libsieve/actions.c (sieve_register_standard_actions):
Register "fileinto" in non-required state to comply to the
RFC.
* libsieve/argp.c (sieve_argp_parser): Always add SIEVE_MODDIR
to sieve_library_path.
* doc/texinfo/libsieve.texi: Documented some aspects of the`
input language.
* doc/texinfo/programs.texi: Documented :sieve option group
* examples/addr.c: Include mutil.h
* guimb/guimb.h: Include mu_asprintf.h
* mail/mail.h: Likewise.
* imap4d/append.c: Removed debugging hook
* imap4d/auth_gss.c: Added typecasts to shut the compiler
warnings.
* libmu_scm/mu_body.c: Likewise.
* libmu_scm/mu_message.c: Likewise.
* mailbox/locker.c: Likewise.
* imap4d/util.c: Initialize automatic variable.
* libsieve/tests.c: Likewise.
* mail/util.c: Likewise.
* mailbox/adxodress.c: Likewise.
* mailbox/file_stream.c: Likewise.
* mailbox/date.c: Added missing includes
* mailbox/tcp.c: Removed unused variables.
* imap4d/search.c (_scan_body): Bugfix. Add null terminator to
the string read.
* imap4d/testsuite/imap4d/search.exp: Fixed `wine' testcase.
Fixed `SELECT INBOX' testcase.
2002-12-10 Sergey Poznyakoff
* include/mailutils/libsieve.h
(sieve_include_path,sieve_library_path): New globals
* libmu_scm/Makefile.am: Fixed install-data-hook. Thanks to
Jordi Mallach.
* libsieve/argp.c: New file. Sieve-specific command line handling.
* libsieve/Makefile.am: Added argp.c
* libsieve/load.c (sieve_load_add_path,sieve_load_add_dir): New
functions.
* libsieve/sieve.h: Likewise.
* libsieve/sieve.l: New extension statement #searchpath controls
the search path for dynamically loaded extensions.
* mail.local/main.c (argp_capa): Added "sieve" capability.
(main): Invoke mu_sieve_argp_init().
* sieve/sieve.c: Likewise.
* sieve/testsuite/sieve/ext.exp: Use -L option instead of setting
environment variable.
* mailbox/mu_argp.c (mu_license_argp_option): Removed short
option 'L', it is used by sieve argp stuff.
2002-12-09 Sergey Poznyakoff
* libsieve/actions.c (build_mime,sieve_action_redirect): free
return from mu_get_user_email().
* libsieve/sieve.y (statement production): Gross bugfix: do not
run sieve_slist_destroy on the list, just list_destroy. All the
items are already registered in the memory pool and will be
freed by sieve_machine_destroy.
* libsieve/tests.c (_get_address_part): Bugfix: assign to *data
only if ret is not null.
* libsieve/util.c (_comp_action): Do not run comparator if the
sample is NULL.
* mail.local/main.c (sieve_test): Bugfix: run
sieve_machine_destroy() only if the compilation succeeded.
(deliver): Removed unused variable sb. Use isize instead.
* mailbox/mutil.c (mu_get_user_email): Added comment.
2002-12-05 Sergey Poznyakoff
* lib/Makefile.am (INCLUDES): Fixed path.
* configure.ac: Check for libltdl only if enable_shared
is set.
* examples/mta.c: Do not use asprintf.
* lib/pin.c: It is needed by argp stuff. Moved to ...
* mailbox/pin.c: ... here
* lib/Makefile.am: Moved pin.c from lib to mailbox
* mailbox/Makefile.am: Likewise.
* comsat/comsat.h: Removed unneeded inclusion of getopt.h
* frm/frm.c: Likewise.
* imap4d/imap4d.h: Likewise.
* pop3d/pop3d.h: Likewise.
* mail.local/mail.local.h: Likewise.
* mh/mh_getopt.c: Likewise.
* readmsg/readmsg.h: Likewise.
* imap4d/fetch.c (fetch_internaldate): Added typecast to shut up
the compiler warning.
* mailbox/mbx_default.c (get_homedir): Returned value is not
const.
2002-12-05 Sergey Poznyakoff
* configure.ac: Check for presence of getopt.h
* examples/mta.c: Do not use program_invocation_short_name:
examples are not linked against libmailutils.
* frm/testsuite/frm/test.exp: Override FOLDER environment
variable.
* from/testsuite/from/test.exp: Likewise.
* messages/testsuite/messages/test.exp: Likewise.
* readmsg/testsuite/readmsg/test.exp: Likewise.
* sieve/testsuite/lib/sieve.exp: Likewise.
* guimb/scm/Makefile.am: Use $? instead of $< in explicit rules.
* libmu_scm/Makefile.am: Likewise.
* lib/getopt.h: Moved to ...
* include/mailutils/gnu/getopt.h: ... here.
* include/mailutils/gnu/Makefile.am: getopt.h moved from lib to
include/mailutils/gnu
* lib/Makefile.am: Likewise.
* include/mailutils/gnu/argp.h: Include local copy of getopt.h if
the system does not provide one.
* mailbox/Makefile.am (mailutils_config_LDADD): Added
libmailutils.la
* mailbox/mailutils-config.c (main): Do not print duplicate
--link arguments.
2002-12-04 Sergey Poznyakoff
* include/mailutils/argp.h (mu_print_options, mu_check_option):
New functions.
* mailbox/mu_argp.c: Likewise.
* mailbox/mailutils-config.c: Added --info option (prints and
tests for the values of compilation options). Improved help
output.
* doc/texinfo/programs.texi: Documented mailutils-config.
2002-12-04 Sergey Poznyakoff
* TODO: Updated
* configure.ac: Add mysql libraries to MYSQLLIBS
* mailbox/Makefile.am: New target mailutils-config
* mailbox/mailutils-config.c: New file. A utility
program that prints compiler and loader flags
necessary to build a program using mailutils
libraries.
2002-12-03 Sergey Poznyakoff
* libsieve/actions.c (sieve_action_reject): Fixed diagnostic
messages.
* m4/gssapi.m4: Bugfix: Properly restore LIBS, LDFLAGS and CFLAGS.
2002-12-02 Frederic Gobry <frederic.gobry@smartdata.ch>
* mailbox/mime.c (_mime_body_read): reset the part offset when
resetting the message.
2002-11-29 Sergey Poznyakoff
* mailbox/date.c: New version of mu_tm2time function.
The previous version of mu_tm2time incorrectly handled dates within
the DST period.
* mailbox/mutil.c: Moved time functions to date.c
* mailbox/Makefile.am: Added date.c
* imap4d/fetch.c (fetch_internaldate): Use
mu_parse_ctime_date_time.
* imap4d/testsuite/imap4d/fetch.exp: Fixed wrong dates.
* NEWS: Updated.
* doc/texinfo/libsieve.texi: Updated.
* libsieve/actions.c (sieve_action_keep): Remove the delete
mark from the message.
* guimb/scm/sieve-core.scm (action-keep): Likewise.
* libsieve/sieve.y (sieve_machine_init): Fixed inconsistent return
value.
* auth/Makefile.am: Removed traces of ansi2knr.c
* comsat/Makefile.am: Likewise.
* dotlock/Makefile.am: Likewise.
* frm/Makefile.am: Likewise.
* from/Makefile.am: Likewise.
* guimb/Makefile.am: Likewise.
* imap4d/Makefile.am: Likewise.
* libmu_scm/Makefile.am: Likewise.
* mail/Makefile.am: Likewise.
* mail.local/Makefile.am: Likewise.
* mail.remote/Makefile.am: Likewise.
* mapi/Makefile.am: Likewise.
* messages/Makefile.am: Likewise.
* pop3d/Makefile.am: Likewise.
* readmsg/Makefile.am: Likewise.
2002-11-29 Sergey Poznyakoff
* mailbox/file_stream.c (_stdin_file_read): Test for eof
condition.
* examples/base64.c: New file. Sample base64 encoder-decoder.
* examples/Makefile.am: Added base64
* mailbox/testsuite/Encode: New file. Data for base64 test.
* mailbox/testsuite/Decode: Likewise.
* mailbox/testsuite/Makefile.am: Added Encode, Decode.
* mailbox/testsuite/mailbox/base64.exp: New file. Testcase for
base64 filters.
* mailbox/testsuite/mailbox/DISTFILES: Added base64.exp
* testsuite/lib/mailutils.exp (mu_test_file): Fixed comment.
2002-11-28 Frederic Gobry <frederic.gobry@smartdata.ch>
* mailbox/filter_trans.c (qp_encode): fixed quoted-printable
encoding.
* mailbox/mime.c (_mime_set_content_type): when a MIME message has
only one part, set the Content-transfer-encoding of the message to
be the one of the part.
2002-11-27 Frederic Gobry <frederic.gobry@smartdata.ch>
* mailbox/filter_trans.c (trans_read): applied patch from Sergey
Poznyakoff, so that filters don't forget the last bytes of a
file. Fixed an uninitialized variable problem.
* libsieve/load.c: fixed compilation when HAVE_LIBLTDL is not
defined.
2002-11-25 Sergey Poznyakoff
* doc/texinfo/Makefile.am: Fake configure into including
srcdir to VPATH.
* include/mailutils/libsieve.h (sieve_malloc,sieve_mstrdup)
(sieve_mrealloc,sieve_mfree): New functions.
* libsieve/util.c: Likewise.
* libsieve/comparator.c: Use sieve_m.* memory allocation
functions.
* libsieve/prog.c: Likewise.
* libsieve/sieve.l: Likewise.
* libsieve/sieve.y: Likewise.
* doc/texinfo/libsieve.texi: Updated
2002-11-25 Frederic Gobry <frederic.gobry@smartdata.ch>
* mailbox/address.c (address_concatenate): cleanup the address
cache during concatenation.
2002-11-25 Sergey Poznyakoff
* mail.local/main.c (deliver): Bugfix: n and isize were not
declared.
* sieve/sieve.c (options): Fixed spelling in the help line.
* libsieve/load.c: Removed debugging hacks. Always call lt_dlinit
and add a call to lt_dlexit to the destructor.
* examples/Makefile.am: Pointed moddir to more appropriate
place.
* mail/z.c: Bugfix. Use mail_from0(), not mail_from().
* doc/texinfo/libmuauth.texi: New file. A placeholder for
documentation regarding libmuauth.
* doc/texinfo/libsieve.texi: New file. Documentation for the
sieve library.
* doc/texinfo/Makefile.am: Replaced explicit rules to generate
*.c.texi files with an implicit rule generating *.inc files.
The rule itself is modified to preserve the heading comment.
Added libmuauth.texi and libsieve.texi to sources.
* doc/texinfo/.cvsignore: Added *.inc
* doc/texinfo/programs.texi: Documented new version of sieve (not
fully, still...)
* doc/texinfo/mailutils.texi: Added references to libmuauth and
libsieve.
* doc/texinfo/framework.texi: Include *.inc files instead of
*.c.texi. Added standard GNU copyright header.
* doc/texinfo/address.texi: Likewise.
* doc/texinfo/attribute.texi: Likewise.
* doc/texinfo/auth.texi: Likewise.
* doc/texinfo/body.texi: Likewise.
* doc/texinfo/c-api.texi: Likewise.
* doc/texinfo/encoding.texi: Likewise.
* doc/texinfo/envelope.texi: Likewise.
* doc/texinfo/folder.texi: Likewise.
* doc/texinfo/headers.texi: Likewise.
* doc/texinfo/imap4.texi: Likewise.
* doc/texinfo/iterator.texi: Likewise.
* doc/texinfo/locker.texi: Likewise.
* doc/texinfo/mailbox.texi: Likewise.
* doc/texinfo/maildir.texi: Likewise.
* doc/texinfo/mailer.texi: Likewise.
* doc/texinfo/mbox.texi: Likewise.
* doc/texinfo/message.texi: Likewise.
* doc/texinfo/mh.texi: Likewise.
* doc/texinfo/mime.texi: Likewise.
* doc/texinfo/nntp.texi: Likewise.
* doc/texinfo/parse822.texi: Likewise.
* doc/texinfo/pop3.texi: Likewise.
* doc/texinfo/sendmail.texi: Likewise.
* doc/texinfo/smtp.texi: Likewise.
* doc/texinfo/stream.texi: Likewise.
* doc/texinfo/url.texi: Likewise.
2002-11-22 Sergey Poznyakoff
* configure.ac: Added check for installed libltdl. Bumped
version number to 0.1.3.
* mailbox/mu_argp.c (mu_conf_option): Added HAVE_LIBLTDL
* examples/numaddr.c: New file. Sample loadable test for sieve.
* examples/Makefile.am: Added numaddr.c
(AM_LDFLAGS): Removed libmailutils. It's not used by examples.
* libsieve/load.c: New file. Support for loadable extensions for
sieve.
* libsieve/Makefile.am: Added load.c
* libsieve/require.c (sieve_require): Implemented loadable tests.
* libsieve/comparator.c (sieve_require_comparator): Implemented
loadable comparators.
* include/mailutils/libsieve.h (sieve_require_action)
(sieve_require_test): New functions.
* libsieve/register.c: Likewise.
* sieve/Makefile.am (sieve_LDFLAGS): Added -export-dynamic
* sieve/sieve.c (main): Removed unneeded goto. Added call
to sieve_machine_destroy at the end.
* sieve/testsuite/Reject: Use regexp instead of hardcoded
version number.
* testsuite/spool/bigto.mbox: New file. A mailbox for
testing the behaviour of various utilities on
structured headers that contain long lists of addresses.
* testsuite/spool/DISTFILES: Added bigto.mbox
* frm/testsuite/frm/test.exp: Test frm -l on long to: headers.
* sieve/testsuite/scripts/numaddr.sv: New file. A script invoking
loadable test.
* sieve/testsuite/scripts/DISTFILES: Added numaddr.sv
* sieve/testsuite/sieve/ext.exp: New file. Test for sieve loadable
extensions.
* sieve/testsuite/sieve/DISTFILES: Added ext.exp
2002-11-21 Sergey Poznyakoff
* mailbox/file_stream.c (_file_destroy): Bugfix. Do not close the
stream.
* imap4d/append.c (imap4d_append0): Simplified a lot.
* imap4d/testsuite/lib/imap4d.exp (default_imap4d_start): Save
imap4d spawn id in the global variable.
(default_imap4d_stop): Moved functionality from imap4d_exit
(imap4d_stop): Call default_imap4d_stop unless it has already
been called.
(imap4d_exit): Call imap4d_stop
* imap4d/testsuite/imap4d/anystate.exp: Call imap4d_stop at the
end.
* imap4d/testsuite/imap4d/append.exp: Likewise.
* imap4d/testsuite/imap4d/create.exp: Likewise.
* imap4d/testsuite/imap4d/examine.exp: Likewise.
* imap4d/testsuite/imap4d/expunge.exp: Likewise.
* imap4d/testsuite/imap4d/fetch.exp: Likewise.
* imap4d/testsuite/imap4d/list.exp: Likewise.
* imap4d/testsuite/imap4d/search.exp: Likewise.
* imap4d/testsuite/imap4d/x.exp: Likewise.
* mail/testsuite/lib/mail.exp (default_mail_start): Save
mail spawn id in the global variable.
(default_mail_stop): Moved functionality from mail_exit
(mail_stop): Call default_mail_stop unless it has already
been called.
(mail_exit): Call mail_stop
* mail/testsuite/mail/alias.exp: Call mail_stop at the end.
* mail/testsuite/mail/folder.exp: Likewise.
* mail/testsuite/mail/read.exp: Likewise.
* mail/testsuite/mail/send.exp: Likewise.
* mail/testsuite/mail/tag.exp: Likewise.
* mail/testsuite/mail/write.exp: Likewise.
* pop3d/testsuite/lib/pop3d.exp: Fixed exit functions.
* mailbox/mailbox.c (mailbox_flush,mailbox_append_message)
(mailbox_save_attributes,mailbox_expunge): Return EACCES
if mailbox was open read only.
2002-11-21 Sergey Poznyakoff
* mailbox/parse822.c (parse822_quoted_string): Free qstr before
returning error status. Otherwise, addresses like
"A wrong quote\" <addr@dom.ain>
hit the assert in parse822_word() and coredump.
(parse822_word_dot): Removed misleading comment.
* mailbox/testsuite/Addrs: Added a testcase for this.
2002-11-20 Sergey Poznyakoff
* mailbox/mailer.c: Fixed indentation.
* include/mailutils/libsieve.h (sieve_test_lookup)
(sieve_action_lookup,sieve_register_test)
(sieve_register_action,sieve_register_comparator)
(sieve_comparator_lookup,sieve_require_comparator)
(sieve_get_comparator): Accept the pointer to
sieve machine as first argument.
* libsieve/sieve.h (struct sieve_machine): New members
test_list, action_list and comp_list provide independent
symbol space for this particular instance of sieve.
* libsieve/actions.c (build_mime,sieve_action_redirect): Removed
unused argument.
(sieve_register_standard_actions): Changed declaration.
* libsieve/comparator.c (sieve_register_comparator)
(sieve_require_comparator,sieve_comparator_lookup)
(sieve_get_comparator)
(sieve_register_standard_comparators): Accept the pointer
to sieve machine as first argument.
* libsieve/register.c (sieve_test_lookup,sieve_action_lookup)
(sieve_register_test,sieve_register_action): Accept the pointer
to sieve machine as first argument.
* libsieve/require.c: Adjust for above changes.
* libsieve/sieve.y: Likewise.
* libsieve/tests.c: Likewise.
(sieve_test_header): New tag :mime. Directs header to test
headers in all parts of a multipart message, not only main
message headers.
* libsieve/util.c (sieve_tag_lookup): New function.
* sieve/sieve.c: Added "mailer" capability. Removed spurious
--mailer-url command line switch.
(main): Do not create mailer. sieve_message() will do it
if necessary.
* sieve/testsuite/scripts/header-mime.sv: New file. Test script
for 'header :mime' extension.
* sieve/testsuite/scripts/DISTFILES: Added header-mime.sv
* sieve/testsuite/sieve/header.exp: Test :mime tag.
* mail.local/mail.local.h (mda): Changed prototype.
(struct mda_data): Replaced FILE *fp with message_t msg.
* mail.local/script.c: Adjust for above changes.
* mail.local/main.c (make_tmp): Create a message instead
of returning file pointer.
(argp_capa): Added "mailer" capability.
(sieve_test): Second argument.
(mda,deliver): Take message_t as first argument, instead of
FILE*.
2002-11-19 Sergey Poznyakoff
* libsieve/comparator.c (i_ascii_casemap_contains): Fixed
typecast.
* mailbox/mutil.c (mu_set_user_email): Set user's domain as
well.
* sieve/testsuite/Reject: Fixed `envelope from' address.
2002-11-19 Sergey Poznyakoff
* sieve/sieve.c: New options: --verbose to verbosely log executed
actions, --log-facility to switch all diagnostic output to
syslog.
* libsieve/comparator.c (i_ascii_numeric_is): Support for
:comparator i;ascii-numeric. Fixed handling of
:comparator i;ascii-casemap :matches and :contains.
Added i;ascii-numeric :is comparator.
* libsieve/runtime.c (sieve_message): New function.
* libsieve/sieve.y (sieve_machine_init,sieve_machine_destroy):
Fixed inconsistencies.
* libsieve/tests.c (_get_address_part): Made static to avoid
name clashes.
* libmu_scm/mu_address.c: Likewise.
* libsieve/util.c (sieve_slist_destroy): Use list_do. It is
faster.
* sieve/testsuite/lib/sieve.exp (sieve_test): Pass --verbose
switch to sieve. Added -retcode option.
* sieve/testsuite/scripts/i-casemap-contains.sv: New file.
* sieve/testsuite/scripts/i-casemap-is.sv: New file.
* sieve/testsuite/scripts/i-casemap-matches.sv: New file.
* sieve/testsuite/scripts/i-casemap-regex.sv: New file.
* sieve/testsuite/scripts/i-numeric-contains.sv: New file.
* sieve/testsuite/scripts/i-numeric-is.sv: New file.
* sieve/testsuite/scripts/i-octet-contains.sv: New file.
* sieve/testsuite/scripts/i-octet-is.sv: New file.
* sieve/testsuite/scripts/i-octet-matches.sv: New file.
* sieve/testsuite/scripts/i-octet-regex.sv: New file.
* sieve/testsuite/scripts/DISTFILES: Added scripts for testing
comparators.
* sieve/testsuite/sieve/i-casemap.exp: New file.
* sieve/testsuite/sieve/i-numeric.exp: New file.
* sieve/testsuite/sieve/i-octet.exp: New file.
* sieve/testsuite/sieve/DISTFILES: Added scripts for testing
comparators.
* testsuite/spool/sieve.mbox: Add X-Number header to msg 2
for testing i;ascii-numeric comparator.
* sieve/testsuite/Redirect: Reflect changed headers in msg 2
* sieve/testsuite/Reject: Likewise
* sieve/testsuite/sieve/action.exp: Likewise.
* testsuite/lib/mailutils.exp: Bugfix: always check for newline
after matched pattern.
* mail.local/Makefile.am: Added libsieve.la
* mail.local/mail.local.h: Include libsieve.h
* mail.local/main.c: Support for user-defined sieve filters.
Improved debugging.
* TODO: Updated.
2002-11-18 Sergey Poznyakoff
* mailbox/mailer.c (mailer_get_url): New function.
* mailbox/sendmail.c (sendmail_send_message): Bugfix: stream_read
should not use sendmail->offset for positioning.
* examples/mta.c: Test if environment variable MTA_APPEND is set.
* include/mailutils/libsieve.h: Added comments.
* libsieve/actions.c: Implemented reject and redirect.
* libsieve/sieve.h (struct sieve_machine): New members
mailer and daemon_email.
* libsieve/sieve.l: Call multiline_add for each line in ML state.
* libsieve/sieve.y (sieve_get_mailer,sieve_set_mailer)
(sieve_get_daemon_email,sieve_set_daemon_email): New functions.
* sieve/Makefile.am: Enable testsuite subdir.
* sieve/sieve.c: New option --email sets user email address.
* sieve/testsuite/Reject: New file
* sieve/testsuite/Redirect: New file
* sieve/testsuite/Makefile.am: Added Reject and Redirect
* sieve/testsuite/lib/sieve.exp (sieve_test): Pass --email
and --mailer options to sieve.
(sieve_driver_test): New procedure.
* sieve/testsuite/scripts/redirect.sv: New file
* sieve/testsuite/scripts/reject.sv: New file
* sieve/testsuite/scripts/DISTFILES: Added redirect.sv and
reject.sv
* sieve/testsuite/sieve/redirect.exp: New file
* sieve/testsuite/sieve/reject.exp: New file
* sieve/testsuite/sieve/DISTFILES: Added redirect.exp and
reject.exp
* libmu_scm/mu_message.c (mu_message_set_header): Fixed memory
leak.
2002-11-15 Sergey Poznyakoff
* sieve/examples/ex-3.1b.sv: Require redirect.
* sieve/examples/example.sv: Likewise.
* sieve/testsuite/sieve/action.exp: Adapted for changed sieve
diagnostics format.
* sieve/testsuite/sieve/address.exp: Likewise.
* sieve/testsuite/sieve/allof.exp: Likewise.
* sieve/testsuite/sieve/anyof.exp: Likewise.
* sieve/testsuite/sieve/envelope.exp: Likewise.
* sieve/testsuite/sieve/exists.exp: Likewise.
* sieve/testsuite/sieve/false.exp: Likewise.
* sieve/testsuite/sieve/header.exp: Likewise.
* sieve/testsuite/sieve/size.exp: Likewise.
2002-11-15 Sergey Poznyakoff
* mailbox/list.c (list_replace): New function.
* include/mailutils/list.h: Likewise.
* mailbox/address.c (address_aget_local_part,address_aget_domain):
New functions.
* include/mailutils/address.h: Likewise.
* mail.local/main.c (parse_opt): Use argp_error to report
diagnostics.
* include/mailutils/libsieve.h (sieve_retrieve_t): Extra argument.
(sieve_destructor_t,sieve_tag_checker_t): New types.
(sieve_value_t): New member v.ptr.
(sieve_tag_def_t): Removed num member.
(sieve_tag_group_t): New data type.
(sieve_runtime_tag): Changed type of tag member to char *.
(sieve_register_t): Removed unused members. Changed type of
tags member.
(sieve_register_test,sieve_register_action): Changed type of
fourth argument (tags).
(sieve_machine_destroy,sieve_machine_add_destructor): New
functions.
* libsieve/comparator.c: Added support for :regex matching type.
* libsieve/prog.c: More thorough checking of tags.
* libsieve/register.c (sieve_register_test)
(sieve_register_action): Changed type of fourth argument (tags).
* libsieve/require.c (sieve_require): Commented unimplemented
parts of code.
* libsieve/runtime.c (instr_run): Do not run the handler when
in disassemble mode.
* libsieve/sieve.h (struct sieve_machine): New member destr_list.
(sieve_match_part_checker): New function.
* libsieve/sieve.y (sieve_machine_init): Fixed return value.
(sieve_machine_add_destructor,sieve_machine_destroy): New
functions.
* libsieve/tests.c: Implemented the rest of required sieve tests
(address and envelope).
* libsieve/util.c (sieve_value_create,sieve_type_str)
(sieve_print_value): Handle SVT_POINTER data type.
(sieve_print_value_list) tag member is now char *.
(_comp_action): Call cp->retr continuously until it returns
non-zero.
2002-11-14 Frederic Gobry <frederic.gobry@smartdata.ch>
* include/mailutils/address.h: added declaration of address_dup.
2002-11-14 Sergey Poznyakoff
* sieve/lex-sieve.lex: Removed
* include/mailutils/libsieve.h
(sieve_comparator_t,sieve_retrieve_t): New datatypes.
(sieve_vlist_do,sieve_vlist_compare,sieve_comparator_lookup)
(sieve_register_comparator,sieve_get_comparator): New functions.
* libsieve/actions.c: (sieve_action_discard): Log output made
compatible with that of CMU ported sieve.
* libsieve/require.c (sieve_require): Handle "comparator-" prefix
in require statements.
* libsieve/runtime.c (instr_action): Increase action_count.
(sieve_run): Log implicit keep action.
* libsieve/sieve.h (struct sieve_machine) New member action_count.
(sieve_register_standard_comparators): New function.
(sieve_require_comparator): New function.
* libsieve/sieve.y (action production): Fixed number of arguments
in call to sieve_compile_error().
* libsieve/tests.c: Implemented header test.
* libsieve/util.c (sieve_vlist_do, sieve_vlist_compare): New
functions.
* libsieve/comparator.c: New file.
* libsieve/Makefile.am: Added comparator.c
* sieve/examples/t-complex.sv: require "redirect".
2002-11-14 Sergey Poznyakoff
Started actually rewriting sieve to use libsieve library.
The CMU-based sources are available under the tag
ver-0-1-2-with-cmu-sieve.
* Makefile.am: Added libsieve.
* configure.ac: Likewise.
* mailbox/mbx_mboxscan.c (mbox_scan0): Compute uids before
calling DISPATCH_ADD_MSG.
* mailbox/mbx_mh.c (mh_scan0): Implemented EVT_MESSAGE_ADD
notification.
* include/mailutils/libsieve.h: Changed sieve_machine_t to be
a pointer to structure.
* libsieve/Makefile.am: Removed sv.c
* libsieve/sv.c: Removed.
* libsieve/runtime.c: Reflect change of sieve_machine_t type.
* libsieve/sieve.y: Likewise.
* libsieve/sieve.h (struct sieve_machine): New members: filename,
logger, ticket, mu_debug.
* libsieve/actions.c: Implemented stop, keep, discard and
fileinto.
* libsieve/tests.c: Implemented true, false, exists and size.
* libsieve/util.c (sieve_value_get, sieve_log_action)
(sieve_mark_deleted): New functions.
* sieve/gram-sieve.y: Removed.
* sieve/parseaddr.c: Removed.
* sieve/sv.h: Removed.
* sieve/tree.h: Removed.
* sieve/addr-lex.l: Removed.
* sieve/imparse.c: Removed.
* sieve/parseaddr.h: Removed.
* sieve/sieve-lex.l: Removed.
* sieve/svcb.c: Removed.
* sieve/util.c: Removed.
* sieve/imparse.h: Removed.
* sieve/script.c: Removed.
* sieve/svctx.c: Removed.
* sieve/util.h: Removed.
* sieve/interp.c: Removed.
* sieve/script.h: Removed.
* sieve/sieve.h: Removed.
* sieve/svfield.c: Removed.
* sieve/addr.y: Removed.
* sieve/interp.h: Removed.
* sieve/sieve_err.c: Removed.
* sieve/svfield.h: Removed.
* sieve/comparator.c: Removed.
* sieve/message.c: Removed.
* sieve/sieve_err.h: Removed.
* sieve/svutil.c: Removed.
* sieve/comparator.h: Removed.
* sieve/message.h: Removed.
* sieve/sieve-gram.y: Removed.
* sieve/sieve_interface.h: Removed.
* sieve/tree.c: Removed.
* sieve/AUTHORS: Removed.
* sieve/COPYING: Removed.
* sieve/NEWS: Removed.
* sieve/README: Removed.
* sieve/Makefile.am: Pruned for the new implementation.
* sieve/sieve.c: Use libsieve calls.
2002-11-13 Sergey Poznyakoff
* include/mailutils/libsieve.h: (sieve_vprintf_t): Removed.
(sieve_parse_error_t): New data type.
(sieve_compile): Changed prototype declaration.
(sieve_get_data,sieve_get_message,sieve_get_message_num)
(sieve_get_debug_level,sieve_mailbox,sieve_disass)
(sieve_machine_init,sieve_machine_set_error)
(sieve_machine_set_parse_error): New functions.
* libsieve/README: Replaced BNZ with BZ.
* libsieve/actions.c (fileinto_args): Fileinto takes string,
not string-list.
* libsieve/prog.c (sieve_code_command): Implemented implicit
typecast from string to string-list.
* libsieve/require.c: Use sieve_compile_error() to report parse
errors.
* libsieve/sieve.l: Likewise.
* libsieve/util.c: Likewise.
* libsieve/runtime.c: Verbose debugging.
(instr_branch, instr_brz): New functions.
(sieve_get_data,sieve_get_message,sieve_get_message_num)
(sieve_get_debug_level,sieve_disass,sieve_mailbox): New
functions
* libsieve/sieve.h (sieve_op_t): New member `pc'.
(struct sieve_machine): New members: errbuf,mailbox,msgno,
msg,parse_error_printer.
(sieve_error,sieve_debug): Removed prototype.
(sieve_compile_error,instr_branch,instr_brz): New function.
* libsieve/sieve.y: Implemented conditional blocks. The grammar
is complete.
* libsieve/sv.c: Modified to reflect changes in the API.
2002-11-13 Sergey Poznyakoff
* mail/util.c (util_do_command): Interpret empty line as "next"
command only when in interactive mode.
2002-11-12 Sergey Poznyakoff
* libsieve/prog.c: New file. Code generator functions.
* libsieve/runtime.c: New file. Runtime support.
* libsieve/Makefile.am: Added prog.c and runtime.c.
* include/mailutils/libsieve.h: Added basic code generation and
debugging (conditional blocks still not implemented).
* libsieve/actions.c: Likewise.
* libsieve/register.c: Likewise.
* libsieve/sieve.h: Likewise.
* libsieve/sieve.l: Likewise.
* libsieve/sieve.y: Likewise.
* libsieve/sv.c: Likewise.
* libsieve/tests.c: Likewise.
* libsieve/util.c: Likewise.
2002-11-08 Sergey Poznyakoff
* include/mailutils/libsieve.h: New file.
* include/mailutils/Makefile.am: Added libsieve.h
* libsieve/sieve.h: Moved publicly available declarations to
<mailutils/libsieve.h>
* libsieve/sieve.y: Fixed the grammar. Added union, types and the
basic actions.
* libsieve/sieve.l: Likewise.
* libsieve/Makefile.am: Added new files.
* libsieve/util.c (sieve_slist_destroy, sieve_value_create): New
functions.
* libsieve/tests.c: New file. Provides standard sieve tests (all
noops, so far).
* libsieve/actions.c: New file. Provides standard sieve actions (all
noops, so far).
* libsieve/require.c: New file. Handles "require" statement.
* libsieve/register.c: New file. Contains the sieve namespace
functions.
2002-11-07 Sergey Poznyakoff
* mailbox/stream.c: Fix memory leak. Patch provided by
Frederic Gobry <frederic.gobry@smartdata.ch>
* mailbox/tcp.c: Likewise.
* mail.local/mailquota.c: Fixed comment.
* mail.local/main.c: Avoid unnecessary memory allocation.
* libsieve/: New directory
* libsieve/Makefile.am: New file.
* libsieve/.cvsignore: New file.
* libsieve/sieve.y: New file.
* libsieve/sieve.l: New file.
* libsieve/sieve.h: New file.
* libsieve/util.c: New file.
* libsieve/sv.c: New file.
* sieve/ylwrap: Moved to ...
* scripts/ylwrap: ... here
* scripts/Makefile.am: Added ylwrap
* sieve/Makefile.am: Removed ylwrap
2002-11-07 Sergey Poznyakoff
* mail/mail.h (msgset_member,msgset_negate): New functions.
* mail/msgset.y: Added negation of message sets.
`from ! subject:/daily/' outputs all messages whose subject
does not contain the word 'daily'.
* mail/z.c: Fixed behaviour of z. when the total number of
messages is less than the number of line per page of output.
2002-11-05 Sergey Poznyakoff
* mail/reply.c: Add In-Reply-To and References headers to the
outgoing message.
* mail/var.c (var_quote): Output prefix sequence before each line
of multiline headers.
* mail/from.c (mail_from0): Function shared between from.c and
headers.c
* mail/headers.c: Use mail_from0 to avoid spurious diagnostics
about deleted messages.
* mail/msgset.y (yylex): allow for '-' in field names. Notice,
that if the dash means 'range' and the first message in the
range is not numeric, there should be whitespace between
them.
* mail/util.c (util_get_message): Expanded semantics of the last
argument. It now contains flags that control how
util_get_message operates. Flags are a bitwise sum of the
following:
MSG_ALL Return any message (deleted or not)
MSG_NODELETED Do not return deleted messages.
MSG_SILENT Do not output warnings about deleted
messages.
* mail/mail.h (mail_from0): New function.
(MSG_ALL,MSG_NODELETED,MSG_SILENT): New macros.
* mail/copy.c: Use MSG_.* macros in calls to util_get_message.
* mail/delete.c: Likewise.
* mail/followup.c: Likewise.
* mail/hold.c: Likewise.
* mail/mbox.c: Likewise.
* mail/pipe.c: Likewise.
* mail/print.c: Likewise.
* mail/quit.c: Likewise.
* mail/size.c: Likewise.
* mail/top.c: Likewise.
* mail/undelete.c: Likewise.
* mail/write.c: Likewise.
* mail/testsuite/mail/send.exp: Changed to reflect new reply behaviour.
* include/mailutils/header.h: Added MU_HEADER_REFERENCES.
* mail.local/main.c (make_tmp): Initialize auth to NULL.
2002-11-04 Sergey Poznyakoff
* auth/virtual.c (mu_auth_virt_domain_by_name): Bugfix. Didn't
allocate enough storage for mailbox_name.
* mh/mh_format.c (print_string): Pad right if necessary.
* m4/enable.m4: Translate dot to underscore in variable names.
* configure.ac: Use MU_ENABLE_SUPPORT for virtual-domains.
* imap4d/testsuite/lib/imap4d.exp: Use ENABLE_VIRTUAL_DOMAINS
* pop3d/testsuite/lib/pop3d.exp: Likewise.
* mailbox/mu_argp.c: Likewise.
* mailbox2/mutil.c: Likewise.
* README: Documented new --disable options.
* doc/texinfo/message.texi: correct the prototype of
message_is_multipart() (patch by Olivier Bornet).
* examples/http.c: Removed include <sys/select.h>
* pop3d/pop3d.c (main): Improved check for debugging mode.
* imap4d/imap4d.c: Likewise.
* pop3d/testsuite/Makefile.am: Added config to test_dirs.
* imap4d/testsuite/Makefile.am: Likewise.
* testsuite/lib/mailutils.exp (mailer_test): New procedure for
testing mailers.
(mu_init): New option -noflags skips the default initialization
of MU_TOOL_FLAGS.
* mail.remote/testsuite/lib/mail.remote.exp: Invoke mu_init with
-noflags.
* mail.remote/testsuite/lib/mail.remote.exp (mailer_remote_test):
Use mailer_test.
* mail.local/mail.local.h (switch_user_id): Changed prototype
to honour mu_auth_data->change_uid member.
* mail.local/main.c: Likewise.
* mail.local/script.c: Likewise.
* mail.remote/testsuite/mail.remote/send.exp: Broke long lines.
Added testsuite framework for mail.local:
* mail.local/Makefile.am: Added SUBDIRS.
* mail.local/testsuite: New directory
* mail.local/testsuite/Makefile.am: New file
* mail.local/testsuite/.cvsignore: New file
* mail.local/testsuite/Data: New file
* mail.local/testsuite/lib: New directory
* mail.local/testsuite/lib/mail.local.exp: New file
* mail.local/testsuite/lib/DISTFILES: New file
* mail.local/testsuite/mail.local: New directory
* mail.local/testsuite/mail.local/deliver.exp: New file
* mail.local/testsuite/mail.local/DISTFILES: New file
2002-11-04 Sergey Poznyakoff
* examples/mta.c: include <mailutils/argp.h>
* mailbox/getline.c: include <unistd.h> (for ssize_t)
* mh/mh_fmtgram.y (cond production): added missing semicolon,
required by modern yaccs.
* sieve/sieve-gram.y (sizetag production): Likewise.
2002-11-03 Sergey Poznyakoff
* configure.ac: Added testsuite for mail.remote
* examples/mta.c: New file. A "fake" MTA for testing "mail" and
"mail.remote"
* examples/Makefile.am: Added mta.c
* examples/.cvsignore: Likewise.
* testsuite/etc/mail.rc: Added indentprefix.
* mail/testsuite/mail/send.exp: New file. Test sending commands.
* mail/testsuite/mail/DISTFILES: Added send.exp
* mail/testsuite/Makefile.am: Add top_builddir to site.exp
* mail.remote/testsuite: New directory.
* mail.remote/Makefile.am: Added testsuite
* mail.remote/testsuite/Makefile.am: New file.
* mail.remote/testsuite/.cvsignore: New file.
* mail.remote/testsuite/Data: New file. Data for testing mail.remote.
* mail.remote/testsuite/lib: New directory
* mail.remote/testsuite/lib/mail.remote.exp: New file.
* mail.remote/testsuite/lib/DISTFILES: New file.
* mail.remote/testsuite/mail.remote: New directory
* mail.remote/testsuite/mail.remote/send.exp: New file.
* mail.remote/testsuite/mail.remote/DISTFILES: New file.
* mail.local/main.c: Fixed indentation.
* mailbox/smtp.c: Likewise.
(smtp_address_add): New function. A wrapper around
address_union.
(_smtp_set_rcpt): Rewritten based on address_union call.
* mail.remote/Makefile.am: Renamed some variables to avoid name
clashes.
* mh/Makefile.am: Likewise.
* mailbox/file_stream.c: Some applications (e.g. mail.remote)
implicitly rely on the possibility to seek on stdin streams.
To provide this functionality:
(struct _file_stream): Added cache member.
It is a memory stream used to provide seeking capability for
stdio streams.
(_file_destroy): Destroy cache if necessary.
(_stdin_file_read,_stdin_file_readline,_stdout_file_write): New
functions. Provide IO operations for stdio streams.
(stdio_stream_create): Register new IO functions.
* testsuite/lib/mailutils.exp (mu_test_file): Minor fixes.
2002-11-01 Jeff Bailey <jbailey@gnu.org>
* mh/Makefile.am: Use MHPROGRAMS and MHLIBRARIES instead of
MH_PROGRAMS and MH_LIBRARIES so that automake doesn't complain.
* mail.remote/Makefile.am: Use SMTPPROGRAMS instead of
SMTP_PROGRAMS so that automake doesn't complain.
* configure.ac: Adjust for above changes.
* mh/Makefile.am: Use AM_YFLAGS instead of YFLAGS.
* libmu_scm/Makefile.am: Use AM_CPPFLAGS instead of CPPFLAGS
* autogen.sh: Redo using 'autoreconf'. This is now the right
tool to use for generating the build environment.
* Makefile.am: Require version 1.7.1, add std-options to
AUTOMAKE_OPTIONS
* configure.in: Require version 2.54. Update quoting. Change
AC_ARG_WITH and AC_ARG_ENABLE to use AC_HELP_STRING
* m4/enable.m4: Change AC_ARG_ENABLE to use AC_HELP_STRING
* lib/Makefile.am: Remove ansi2knr
* lib/ansi2knr.c: Remove
* lib/ansi2knr.1: Remove
2002-11-01 Sergey Poznyakoff
* m4/enable.m4: Fixed action-if-false.
* Makefile.am: Restored to pre-2002-10-29 state.
* configure.ac: Substitute MH_PROGRAMS, MH_LIBRARIES and
SMTP_PROGRAMS variables.
* mh/Makefile.am: Build the targets conditionally.
* mail.remote/Makefile.am: Likewise.
2002-10-29 Sergey Poznyakoff
Following the proposition of Olivier Bornet
<Olivier.Bornet@smartdata.ch>, added a possibility to
disable the support for certain protocols.
* m4/enable.m4: New file. Implements MU_ENABLE_SUPPORT defun.
* m4/Makefile.am: Added enable.m4
* configure.ac: New switches --disable-pop, --disable-imap
--disable-mh, --disable-smtp and --disable-sendmail allow
to disable corresponding protocols.
* Makefile.am: Conditionally build directories depending on
protocols that may be disabled.
* mailbox/mu_argp.c: Updated to reflect the set of ENABLE_
defines.
* mailbox/folder_imap.c: Conditionally compile the contents.
* mailbox/folder_mh.c: Likewise.
* mailbox/folder_pop.c: Likewise.
* mailbox/mbx_imap.c: Likewise.
* mailbox/mbx_mh.c: Likewise.
* mailbox/mbx_pop.c: Likewise.
* mailbox/sendmail.c: Likewise.
* mailbox/smtp.c: Likewise.
* mailbox/url_imap.c: Likewise.
* mailbox/url_mh.c: Likewise.
* mailbox/url_pop.c: Likewise.
* mailbox/url_sendmail.c: Likewise.
* mailbox/url_smtp.c: Likewise.
* sieve/sieve.c: Option -M none disables creating
the mailer.
* sieve/testsuite/lib/sieve.exp: Start sieve with "-M none".
Bugfixes to the docs, contributed by Olivier Bornet:
* doc/texinfo/mailbox.texi: Documented the return code.
* doc/texinfo/headers.texi: Fixed names of the macro-
definitions.
2002-10-15 Sergey Poznyakoff
* guimb/scm/README: Updated.
* mailbox/parse822.c (parse822_phrase): Allow for dots
in non-quoted personal phrase.
* mailbox/testsuite/Addrs: New test: parse non-quoted
phrase containing dots.
2002-10-14 Alain Magloire
* mailbox/getline.c: New LGPL implementation,
With a patch for Sergey.
* mailbox/getline.h: New LGPL implementation.
2002-10-14 Sergey Poznyakoff
* configure.ac: Provide GUILE_BINDIR variable for Makefiles.
* guimb/scm/Makefile.am: Likewise.
* guimb/scm/reject.scm: Fixed Reporting-UA line.
* guimb/scm/sieve-core.scm: Allow to be executed directly by
guile.
* guimb/scm/sieve.scm.in: Cleaned up the source.
* libmu_scm/Makefile.am: Use install-data-hook to create the
libguile-mailutils symlink.
* libmu_scm/mu_scm.c (mu-path-maildir, mu-path-folder-dir): New
globals.
* libmu_scm/mailutils.scm.in: Export new globals.
2002-10-13 Sergey Poznyakoff
* guimb/scm/sieve-core.scm: Changed sieve-register-.* functions
to allow for actions to accept tags.
(sieve-get-opt-arg): New function. Returns the argument to a
given tag.
* guimb/scm/sieve.scm.in: Use new sieve-register style.
(sieve-preprocess-arguments): New function. Preprocess
and group arguments into optional and positional types.
(sieve-parse-arguments): New function. Parses arguments
to an action or a test.
(sieve-register-action,sieve-register-test): Rewritten.
* guimb/scm/mimeheader.scm: Updated to use new register style
* guimb/scm/numaddr.scm: Likewise.
* guimb/scm/redirect.scm: Likewise.
* guimb/scm/reject.scm: Likewise.
* guimb/scm/vacation.scm: New file. Implements "vacation"
extension.
* guimb/scm/Makefile.am: Added vacation.scm
* libmu_scm/mu_message.c (mu_message_set_header): Bugfix.
* libmu_scm/mu_scm.c (_mu_scm_package_string, in scheme
mu-package-string): New global.
* mail/eq.c: Allow a single argument as an extension to the
standard '=' command. The effect is to move the current
pointer to the given message.
* mail/util.c (util_error_range): New function. Outputs "message
out of range" diagnostics.
(util_get_message): New function. A wrapper around
mailbox_get_message with the proper diagnostics.
* mail/mail.h: Likewise.
* mail/copy.c: Use util_get_message()
* mail/delete.c: Likewise.
* mail/followup.c: Likewise.
* mail/from.c: Likewise.
* mail/hold.c: Likewise.
* mail/mbox.c: Likewise.
* mail/pipe.c: Likewise.
* mail/print.c: Likewise.
* mail/quit.c: Likewise.
* mail/reply.c: Likewise.
* mail/size.c: Likewise.
* mail/top.c: Likewise.
* mail/undelete.c: Likewise.
* mail/var.c: Likewise.
* mail/write.c: Likewise.
* mail/decode.c: Updated util_isdeleted() invocation.
* mail.local/Makefile.am: Added /mailbox to INCLUDES
* lib/getline.h: Removed.
* mailbox/Makefile.am: Added /mailbox to INCLUDES
2002-10-02 Sergey Poznyakoff
* configure.ac: Check if environ is declared.
* mail/setenv.c: Protect the declaration of environ by #if.
* mail/send.c (mail_send): Set save_to right after entering
the function.
(mail_send0): deduce savefile basing on the localpart of
the first address (when save_to is set).
Expand aliases in every address-related header.
* mail/alias.c (alias_expand): Return NULL if no suitable
expansion was found.
* mail/followup.c: Removed unneeded typecasts.
* mail/mailline.c: Likewise.
* mail/shell.c: Likewise.
* mail/util.c (util_header_expand): New function. Expand
the address-related fields of a header.
* mail/mail.h: Likewise.
* mail.local/mail.local.h: Added missing includes.
* pop3d/popauth.c: Likewise.
2002-10-02 Sergey Poznyakoff
* mailbox/address.c (_address_get_nth): Get nth sub-address
from an address.
(most of the functions): Rewritten using _address_get_nth
(address_aget_personal, address_aget_comments): new functions.
(address_dup): New function. Create a copy of a (single)
address.
(address_contains_email): New function. Check if the given email
is contained in the address.
(address_union): New function. Create a union of two addresses.
* include/mailutils/address.h (address_contains_email,
address_union): new functions.
* mail/setenv.c: New file. Implements `setenv' command: an
extension allowing to manipulate the shell environment.
* mail/table.c: Added setenv command.
* mail/Makefile.am: Added setenv.c
* mail/decode.c: Use util_get_crt() to check the value of
the crt variable.
* mail/print.c: Likewise.
* mail/mail.h (mail_setenv, util_get_crt, util_merge_addresses):
New functions.
* mail/reply.c (mail_reply): Bugfix.
* mail/send.c (compose_header_set): COMPOSE_SINGLE_LINE part
rewritten.
* mail/util.c (util_get_crt): Return the value of the "crt"
variable. The variable may be either boolean or numeric,
meaning the minimum number of lines the body of the message
must contain in order to be put through the pager.
(util_merge_addresses): Add new address to the comma-separated
address list, unless it is already present there.
* mail/var.c (dump_headers): Do not print extra newline after
the headers.
* doc/texinfo/programs.texi: Documented crt variable
and setenv command.
2002-10-01 Sergey Poznyakoff
* guimb/scm/sieve-core.scm: Added :regex tag -- an
extension allowing to use POSIX regexp in address
and header tests.
* mh/repl.c: New file. A framework for the `repl' program.
* mh/Makefile.am: Added repl
* mh/.cvsignore: Likewise.
2002-09-30 Sergey Poznyakoff
* configure.ac: Changed check for CURSES_LIBS
* mh/Makefile.am (scan_LDADD): Use CURSES_LIBS instead of
directly linking -lcurses
2002-09-27 Sergey Poznyakoff
* mh/mh_format.c (strobj_len,print_string): Extra safety not to
dereference NULL pointer.
(_parse_date): Use local time if the date cannot be parsed.
* mh/refile.c: Implemented --draft and --file switches.
2002-09-27 Sergey Poznyakoff
* mail/file.c: Fixed typo.
* mh/folder.c (main): Correctly set current message number.
* mh/inc.c: Do not use current_folder global.
* mh/mh.h (mh_msgset_reverse,mh_msgset_negate,mh_msgset_current,
mh_msgset_free): new functions.
(mh_context_get_value,mh_msgset_parse): Changed.
* mh/mh_ctx.c: Descriptive comment regarding the allocation
of the return values.
* mh/mh_msgset.c (mh_msgset_reverse,mh_msgset_negate,
mh_msgset_current, mh_msgset_free): new functions.
Added comments.
* mh/mhpath.c: Minor fixes.
* mh/refile.c: Use new mh_msgset_parse() syntax.
* mh/rmm.c: Fixed args_doc string. Use new mh_msgset_parse()
syntax.
* mh/scan.c: Use mh_iterate(). Accept message specifications
from the command line.
* mh/mh_format.c (mh_format_dump): Bugfix: missed break;
2002-09-26 Sergey Poznyakoff
* mail/mail.h (struct compose_env): Changed structure. Renamed
to compose_env_t.
(compose_init, compose_header_set, compose_header_get,
compose_destroy): New functions.
* mail/send.c: Likewise. Use new compose functions.
* mail/followup.c: Use new compose functions.
* mail/reply.c: Likewise.
* mail/util.c (util_msglist_esccmd): Declaration updated.
* mail/var.c: Implemented "editheaders" variable.
* doc/texinfo/programs.texi: Documented "editheaders" variable.
* mh/Makefile.am (install-exec-hook): Remove "folders" before
linking "folder" to it.
2002-09-25 Sergey Poznyakoff
* mailbox/mutil.c: Fixed typo in #if directive.
* mailbox/parse822.c (const char *days): Bugfix. "Sun" must
be the first entry in the array.
* mh/fmtcheck.c: New file. Source for fmtcheck command. It is
planned as a replacement for fmtdump, providing a broader
set of options for debugging user formats. Currently only
dump (listing) mode is implemented.
* mh/mh_format.c (mh_format_dump): New function. Produces the
listing of compiled format code.
(builtin_me, builtin_profile, builtin_putstr, print_string,
builtin_putnum, builtin_putnumf, builtin_tws,
builtin_pretty): Implemented.
(builtin_pers): Enclose the return in a pair of double-quotes.
* mh/mh_init.c (mh_my_email): New function.
* mh/mh.h (mh_format_dump, mh_my_email): New function.
* mh/Makefile.am: Added fmtcheck
2002-09-24 Sergey Poznyakoff
* mail/mail.c (mail_cmdline): removed unnecessary conditional.
* mail/send.c (mail_send0): Bugfix. A dot ends the message
only if it is the only character on the line. Thanks
to Thomas Esser <te@dbs.uni-hannover.de> for noticing.
* mail/util.c (util_save_outgoing): Removed extra newline
at the end of the envelope `from' line.
* mh/folder.c: Fixed scanning of folders and output.
* mh/mh.h: Changed mh_opcode_t type.
* mh/mh_fmtgram.y: Stricter typing of productions. The cntl
production allows for empty lists (e.g. %<{reply-to}%?{from}%>).
Enable debugging when MHFORMAT_DEBUG environment variable is
set.
(yylex): Skip whitespace after the function name.
(branch_fixup): The produced jump offset was wrong. Fixed.
(mh_code_builtin): Fixed passing of escape arguments.
* mh/mh_format.c (strobj_is_null,strobj_realloc): New function.
(print_string): Accept an explicit width argument.
(print_obj): New function.
(mh_format): Use the new functions.
(builtin_lit): Fixed.
(builtin_formataddr,builtin_putaddr): Implemented.
2002-09-22 Sergey Poznyakoff
* mh/mh_argp.c (mh_argp_parse): Complain about non-processed
arguments unless "index" is non-null.
* mh/folder.c: Implemented -header. Several fixes.
* mh/rmf.c: New file. Implements rmf command.
* mh/Makefile.am: Added rmf. Added install hook to link 'folder'
to 'folders'
* mh/.cvsignore: Added rmf.
2002-09-21 Sergey Poznyakoff
* mailbox/header.c (header_parse): Bugfix: do not
bail out if len==0.
* mailbox/mbx_mh.c (mh_append_message): Scan the
mailbox if it has not been scanned yet.
* mh/mh_global.c: New file. Global configuration
functions.
* mh/folder.c: New file. Implementation of the folder
command.
* mh/mh.h: New prototypes.
* mh/inc.c (opt_handler): Use is_true().
* mh/refile.c: Likewise.
* mh/mh_argp.c: Use new configuration functions.
* mh/mh_init.c: Likewise.
* mh/scan.c: Likewise.
* mh/Makefile.am: Added folder.c and mh_global.c
* mh/.cvsignore: Added folder.
* frm/frm.c: Fixed indentation.
2002-09-19 Sergey Poznyakoff
* mh/mhpath.c: New file. Source for mhpath command.
* mh/Makefile.am: Added mhpath.
* mh/.cvsignore: Likewise.
* mh/mh_msgset.c (msgset_preproc): Expand the second part
of the message spec as well (the one after dash).
(mh_msgset_parse): Fill message set with message ordinal
numbers.
(mh_search_message): Binary search for a message with the
given sequence number.
(mh_get_message): Retrieve the message with the given sequence
number.
* mh/mh.h (mh_get_message): New prototype.
* mh/mh_init.c (mh_iterate): Rewritten to expect msgset to
contain message ordinal numbers.
2002-09-19 Sergey Poznyakoff
* mailbox/mbx_mh.c (_mh_message_save): Take into account
trailing newline returned by envelope_date (should it
be returned, by the by?)
Output a newline to separate the headers from the body.
(mh_envelope_date): Make sure the returned value is
terminated with a '\n' character (if the buffer space
permits).
* mh/inc.c (main): Use mh_open_folder.
* mh/mh.h (mh_init2, mh_is_my_name, mh_iterate): Added prototypes.
(mh_open_folder, mh_expand_name): Changed prototypes.
* mh/mh_init.c (mh_init2): Fixed generation of the sequence file
name.
(mh_open_folder): Take an extra argument: a flag specifying
whether the folder should be created.
(mh_expand_name): Changed return data type.
* mh/mh_msgset.c (mh_msgset_parse): Sort the message set and
remove any duplicates from it.
* mh/refile.c: Initial implementation.
* mh/rmm.c: Updated mh_open_folder invocations.
* mh/scan.c: Likewise.
* mh/.cvsignore: Updated.
2002-09-18 Sergey Poznyakoff
* mailbox/mailbox.c: Include message.h
* mailbox/mbx_default.c (mu_path_folder_dir): New global. Holds
the name of the user's folder directory.
* include/mailutils/mailbox.h: Likewise
* mailbox/mbx_mh.c: Preserve the envelope information in the
message header.
* libmu_scm/mu_guimb.c (_scheme_main): Removed unused variable.
* mh/mh_ctx.c: New file. Context-related functions.
* mh/mh_msgset.c: New file. Mh-specific message sets.
* mh/refile.c: New file. The framework for the refile command.
* mh/Makefile.am: Added new programs.
* mh/mh.h (mh_builtin_fp, mh_msgset_t): New types.
Added new prototypes.
* mh/mh_argp.c (struct mh_argp_data): New member `doc'. Keeps the
documentation string.
(parse_opt): Pass the data->doc member to mh_getopt.
(mh_argp_parse): Initialize data.doc.
* mh/mh_getopt.c (mh_getopt, mh_help): Accept new argument:
a pointer to the doc string.
* mh/mh_getopt.h: Likewise.
* mh/mh_init.c: Changed handling of MH profiles.
(mh_open_folder, mh_get_dir, mh_expand_name, mh_iterate): New
functions
* mh/rmm.c: Use new mh functions.
* mh/scan.c: Likewise.
2002-09-17 Sergey Poznyakoff
* m4/gssapi.m4: Removed unused variable
* mh/rmm.c: New file. Source for rmm program.
* mh/Makefile.am: Added rmm.c
* mh/mh.h (mh_open_folder): new function.
* mh/mh_init.c: Split mh_init() in two. The second part,
mh_init2(), gets called after parsing the arguments.
(mh_open_folder): New function. Open current folder.
* mh/mh_format.c (mh_format): Bugfix (NULL pointer dereference).
* mh/mh_argp.c (mh_argp_parse): Increased number of arguments.
The last argument points to a location where to store the
ordinal number of the first non-option argument (can be NULL).
Call mh_init2() after parsing.
* mh/mh_getopt.h (mh_argp_parse): Updated declaration.
* mh/inc.c (main): Updated invocation of mh_argp_parse.
* mh/scan.c: Likewise.
2002-09-12 Sergey Poznyakoff
In order to make libmailutils self-contained, shuffled several
files from lib/ to mailutils/.
Added standalone guile module.
* m4/mu_libobj.m4: New file. mu-specific version of
AC_LIBOBJS.
* m4/Makefile.am: Added mu_libobj.m4
* configure.ac: Use MU_LIBOBJS on functions needed for
libmailbox.
Add mailutils.scm to GUILE_PKGDATA.
* libmu_scm/Makefile.am: Install libmu_scm. Added new rule
for building guile standalone mailutils module -- mailutils.scm
* libmu_scm/.cvsignore: Updated.
* libmu_scm/mu_scm.c (mu-register-format): New
primitive. Registers desired mailbox/mailer formats.
(mu_scm_init): Unconditionally register path_record format.
* libmu_scm/mailutils.scm.in: Source for mailutils.scm -- a module
interface file for mailutils.
* libmu_scm/.cvsignore: Updated
* guimb/Makefile.am: Load libmu_scm.la
* lib/Makefile.am: Removed argp-related stuff.
* lib/strndup.c: Moved to mailbox/
* lib/strtok_r.c: Likewise.
* lib/strnlen.c: Likewise.
* lib/getline.c: Likewise.
* lib/strchrnul.c: Likewise.
* lib/argp-ba.c: Likewise.
* lib/argp-eexst.c: Likewise.
* lib/argp-fmtstream.c: Likewise.
* lib/argp-fs-xinl.c: Likewise.
* lib/argp-help.c: Likewise.
* lib/argp-parse.c: Likewise.
* lib/argp-pv.c: Likewise.
* lib/argp-pvh.c: Likewise.
* lib/argp-xinl.c: Likewise.
* lib/argcv.c: Likewise.
* lib/argp-fmtstream.h: Likewise.
* lib/argp-namefrob.h: Likewise.
* lib/getopt.h: Likewise.
* mailbox/Makefile.am: Added argp-related stuff.
* mailbox/strndup.c: Moved from lib/
* mailbox/strtok_r.c: Likewise.
* mailbox/strnlen.c: Likewise.
* mailbox/getline.c: Likewise.
* mailbox/strchrnul.c: Likewise.
* mailbox/argp-ba.c: Likewise.
* mailbox/argp-eexst.c: Likewise.
* mailbox/argp-fmtstream.c: Likewise.
* mailbox/argp-fs-xinl.c: Likewise.
* mailbox/argp-help.c: Likewise.
* mailbox/argp-parse.c: Likewise.
* mailbox/argp-pv.c: Likewise.
* mailbox/argp-pvh.c: Likewise.
* mailbox/argp-xinl.c: Likewise.
* mailbox/argcv.c: Likewise.
* mailbox/argp-fmtstream.h: Likewise.
* mailbox/argp-namefrob.h: Likewise.
* mailbox/getopt.h: Likewise.
* include/mailutils/gnu/: New directory. Holds GNU headers that
might be missing on the system, but are necessary for mailutils.
* include/mailutils/Makefile.am: Added gnu to SUBDIRS.
* include/mailutils/gnu/Makefile.am: New file.
* include/mailutils/gnu/.cvsignore: New file.
* lib/argp.h: Moved to ...
* include/mailutils/gnu/argp.h: ... here
* lib/argcv.h: Moved to ...
* include/mailutils/argcv.h: ... here
* include/mailutils/argp.h: Conditionally include <gnu/argp.h>
* mailbox/mu_argp.c: Changed license to Lesser GPL
* mailbox/mu_auth.c: Likewise.
* mailbox/system.c: Likewise.
* auth/pam.c: Likewise
* auth/sql.c: Likewise
* auth/virtual.c: Likewise
* comsat/cfg.c: Removed include <argcv.h>
* comsat/comsat.h: Include mailutils/argcv.h
* sieve/sieve.c: Likewise.
* imap4d/fetch.c: Likewise.
* mail/mail.h: Likewise.
* mailbox/argcv.c: Likewise.
* mh/mh_argp.c: Likewise.
* dotlock/dotlock.c: Include mailutils/argp.h
* mh/mh_getopt.h: Likewise.
* mailbox/Makefile.am: Fixed INCLUDES
* mh/mh.h: Removed include <argp.h>
* mh/mh_error.c: Likewise.
* mailbox/mu_argp.c: Removed include <xalloc.h>
2002-09-10 Sergey Poznyakoff
Added support for Guile 1.6.0:
* configure.ac: Changed check for guile. Raised patchlevel to
0.1.1
* m4/guile.m4: New file. Check for guile presence and usability.
Determine its version.
* m4/Makefile.am: Add guile.m4
* scripts/Makefile.am: Updated
* scripts/guile-1.4: New directory. Contains scripts for use
with guile 1.4.x
* scripts/guile-1.6: New directory. Contains scripts for use
with guile 1.6 and hopefully higher.
* scripts/guile-1.4/Makefile.am: New file.
* scripts/guile-doc-snarf: Moved to ...
* scripts/guile-1.4/guile-doc-snarf: ... here
* scripts/guile-func-name-check: Moved to ...
* scripts/guile-1.4/guile-func-name-check: ... here
* scripts/guile-snarf.awk: Moved to ...
* scripts/guile-1.4/guile-snarf.awk: ... here
* scripts/guile-1.6/Makefile.am: New file.
* scripts/guile-1.6/guile-doc-snarf: New file.
* scripts/guile-1.6/guile-doc-snarf.awk: New file.
* guimb/Makefile.am: Added @GUILE_INCLUDES@ and @GUILE_LIBS@.
* libmu_scm/Makefile.am: Added @GUILE_INCLUDES@. Changed
snarfing rules.
* mail.local/Makefile.am: Added @GUILE_INCLUDES@ and @GUILE_LIBS@.
* guimb/scm/sieve.scm.in: string->obarray-symbol is deprecated
in 1.6.0. Use another approach.
* libmu_scm/mu_address.c: Upgrade to guile 1.6.0
* libmu_scm/mu_body.c: Likewise.
* libmu_scm/mu_guimb.c: Likewise.
* libmu_scm/mu_logger.c: Likewise.
* libmu_scm/mu_mailbox.c: Likewise.
* libmu_scm/mu_message.c: Likewise.
* libmu_scm/mu_scm.c: Likewise.
* libmu_scm/mu_scm.h: Likewise.
* auth/sql.c (mu_sql_authenticate): Removed unused variable.
2002-09-05 Sergey Poznyakoff
* mailbox/mbx_mh.c: Rewritten to use MH sequence numbers
as UIDs. This allows to simplify the code and to get rid
of mh_message_number(), which didn't fit well in the
mailutils framework.
* mh/mh.h: Changed type of `prog' to mh_instr_t, which is
a union of all objects that can be held in a program text
cell. This fixes potential problems due to sizeof(int)!=
sizeof(void*).
* mh/mh_fmtgram.y: Likewise.
* mh/mh_format.c: Likewise.
* mh/mh_init.c (mh_message_number): A wrapper around
message_get_uid call. Returns the sequence number of
the message.
2002-09-04 Sergey Poznyakoff
* README: Verbose description of --with-mail-spool configuration
option. Spell-checked the file.
* examples/http.c: New file. Example of stream functions.
* examples/Makefile.am: Added http.c
* doc/texinfo/Makefile.am: Added http.c.texi.
* doc/texinfo/.cvsignore: Likewise.
* doc/texinfo/stream.texi: Include http.c.texi.
2002-09-03 Sergey Poznyakoff
* mailbox/md5-rsa.c: Removed.
* mailbox/md5-rsa.h: Removed.
* mailbox/md5.c: Introduced instead.
* mailbox/md5.h: Likewise.
* mailbox/Makefile.am: Use md5.[ch]
* mailbox/message.c: Likewise.
* mailbox/mbx_pop.c: Likewise.
(pop_get_message): Bugfix: check that the message number be not
out of range.
* doc/texinfo/framework.texi: Included parse822 as extra node.
2002-09-03 Sergey Poznyakoff
* configure.ac: Bumped version number to 0.1
* Makefile.am: Added copyleft header. Removed README-alpha from
EXTRA_DIST and added it to AUTOMAKE_OPTIONS. Removed incomplete
mh.
* auth/Makefile.am: Added copyleft header.
* comsat/Makefile.am: Likewise
* doc/Makefile.am: Likewise
* doc/man/Makefile.am: Likewise
* doc/rfc/Makefile.am: Likewise
* doc/texinfo/Makefile.am: Likewise
* dotlock/Makefile.am: Likewise
* examples/Makefile.am: Likewise
* frm/Makefile.am: Likewise
* frm/testsuite/Makefile.am: Likewise
* from/Makefile.am: Likewise
* from/testsuite/Makefile.am: Likewise
* guimb/Makefile.am: Likewise
* guimb/scm/Makefile.am: Likewise
* imap4d/Makefile.am: Likewise
* imap4d/testsuite/Makefile.am: Likewise
* include/Makefile.am: Likewise
* include/mailutils/Makefile.am: Likewise
* lib/Makefile.am: Likewise
* lib/posix/Makefile.am: Likewise
* libmu_scm/Makefile.am: Likewise
* m4/Makefile.am: Likewise
* mail/Makefile.am: Likewise
* mail/testsuite/Makefile.am: Likewise
* mail.local/Makefile.am: Likewise
* mail.remote/Makefile.am: Likewise
* mailbox/Makefile.am: Likewise
* mailbox/include/Makefile.am: Likewise
* mailbox/testsuite/Makefile.am: Likewise
* mapi/Makefile.am: Likewise
* messages/Makefile.am: Likewise
* messages/testsuite/Makefile.am: Likewise
* mh/Makefile.am: Likewise
* pop3d/Makefile.am: Likewise
* pop3d/testsuite/Makefile.am: Likewise
* readmsg/Makefile.am: Likewise
* readmsg/testsuite/Makefile.am: Likewise
* scripts/Makefile.am: Likewise
* sieve/testsuite/Makefile.am: Likewise
* testsuite/Makefile.am: Likewise
* doc/texinfo/mailutils.texi: Commented out inclusion of
c-api.texi
* examples/url-parse.c: Indent output with explicit \t.
* mailbox/testsuite/Urls: Add comment regarding the use of tabs.
* sieve/md5-rsa.h: Removed.
* sieve/md5-rsa.c: Removed.
* sieve/Makefile.am: Added copyleft header. Removed
RSA-copyrighted code, use lib/md5 instead.
* sieve/script.c: Use FSF md5 functions.
2002-09-02 Sergey Poznyakoff
* NEWS: Updated.
* README: Updated.
* TODO: Updated.
* doc/texinfo/mailer.texi: Removed confusing note: yes, one
always has to give -t to sendmail to force it to get recipient
addresses from the headers.
* doc/texinfo/mailutils.texi: Commented out references to
mailbox2 stuff.
* examples/addr.c: Untabified. Needed for proper conversion to
*.texi
* examples/mimetest.c: Likewise.
* examples/msg-send.c: Likewise.
* examples/muemail.c: Likewise.
* examples/sfrom.c: Likewise.
* examples/url-parse.c: Likewise.
2002-09-02 Sergey Poznyakoff
* comsat/comsat.c: Removed erroneous redeclaration of
getutent.
* doc/texinfo/c-api.texi: Removed reference to non-implemented
NNTP.
* doc/texinfo/programs.texi: Documented sieve.
* guimb/scm/sieve.scm: Removed.
* guimb/scm/sieve.scm.in: Added to the repository.
* guimb/scm/Makefile.am: Make sieve.scm from sieve.scm.in
* guimb/scm/.cvsignore: Added sieve.scm
* guimb/scm/sieve-core.scm (sieve-expand-filename): Fixed syntax error.
* mailbox/mutil.c (mu_tempname): New function. Creates a unique
temporary file name in tmpdir.
* include/mailutils/mutil.h: Likewise.
* mail/edit.c: Use mu_tempname
* mail/visual.c: Likewise.
* examples/mimetest.c: Likewise.
* testsuite/lib/mailutils.exp: Couple of fixes.
* sieve/testsuite/sieve/DISTFILES: Temporarily removed compile.exp:
it uses files not included in the distribution.
2002-08-29 Sergey Poznyakoff
* Makefile.am: Added examples/ to SUBDIRS.
* configure.ac: Build mailbox/testsuite/Makefile and
examples/Makefile
* doc/texinfo/Makefile.am: Rules to generate examples .texi
from sources in ../examples.
* doc/texinfo/address.texi: include address.c.texi
* doc/texinfo/url.texi: include url-parse.c.texi
* doc/texinfo/ex-address.texi: Removed. Auto-generated file.
* doc/texinfo/ex-url.texi: Likewise.
* doc/texinfo/sfrom.c.texi: Likewise.
* doc/texinfo/.cvsignore: Added autogenerated files.
* examples/Makefile: Removed.
* examples/Addrs: Removed. Incorporated into mailbox/testsuite.
* examples/Addrs.good: Likewise.
* examples/Urls: Likewise.
* examples/Urls.good: Likewise.
* examples/mail.MysqlMailer.c: Removed obsolete file. mail.local
provides the same functionality.
* examples/mbox-check.c: Removed.
* examples/mbox-dates.c: Removed.
* examples/mbox-explode.c: Removed.
* examples/Makefile.am: New file.
* examples/sfrom.c: New file.
* examples/addr.c: Added copyleft header. Set user email domain
to localhost on startup.
* examples/mimetest.c: Added copyleft header. Changed output
format to better suit testing.
* examples/msg-send.c: Added copyleft header. Reindented.
* examples/muemail.c: Likewise.
* examples/url-parse.c: Likewise.
* guimb/scm/sieve-core.scm (sieve-expand-filename): Do not attempt
to expand meta-characters understood by mailbox_create_default.
* lib/argp-help.c: Define __P() if necessary.
* mail/copy.c (mail_copy0): Make sure we really got the message.
* mail/next.c (mail_next): Do not allow the cursor to grow past
total number of messages.
* mailbox/locker.c: Provide definition for MAXHOSTNAMELEN, if
necessary.
* testsuite/lib/mailutils.exp (mu_version): Check if MU_CAPABILITY
exists. One never knows...
(mu_command): Additional diagnostics
(mu_expect_list,mu_test): Commented out extra checks.
* mailbox/Makefile.am: Added testsuite
* mailbox/testsuite: New directory.
* mailbox/testsuite/Makefile.am: New file.
* mailbox/testsuite/.cvsignore: New file.
* mailbox/testsuite/Addrs: New file.
* mailbox/testsuite/Mime: New file.
* mailbox/testsuite/Urls: New file.
* mailbox/testsuite/lib: New directory.
* mailbox/testsuite/lib/DISTFILES: New file.
* mailbox/testsuite/lib/mailbox.exp: New file.
* mailbox/testsuite/mailbox: New directory.
* mailbox/testsuite/mailbox/DISTFILES: New file.
* mailbox/testsuite/mailbox/address.exp: New file.
* mailbox/testsuite/mailbox/mime.exp: New file.
* mailbox/testsuite/mailbox/url.exp: New file.
2002-08-28 Sergey Poznyakoff
* sieve/interp.c (sieve_interp_alloc): Fill allocated memory
with zeroes.
* sieve/svcb.c: Implemented envelope test (see comment, though)
* sieve/sieve-gram.y: Include "sieve.h"
* sieve/sieve-lex.l: Handle C-style comments.
* sieve/sieve.c: Handle --license option. Additional debugging
flags: 'a' to produce address parser traces, 'g' to produce
main parser traces.
* sieve/sieve_interface.h (addrdebug, yydebug): external
declarations.
* include/mailutils/argp.h (mu_license_text): External
declaration.
* mailbox/mu_argp.c (mu_license_text): removed static
qualifier.
* configure.ac: Added testsuite for sieve. Changed version number
to 0.0.9e.
* sieve/Makefile.am: Likewise
* sieve/testsuite: New directory.
* sieve/testsuite/Makefile.am: New file.
* sieve/testsuite/.cvsignore: New file.
* sieve/testsuite/lib: New directory.
* sieve/testsuite/lib/DISTFILES: New file.
* sieve/testsuite/lib/sieve.exp: New file.
* sieve/testsuite/scripts: New directory.
* sieve/testsuite/scripts/DISTFILES: New file.
* sieve/testsuite/scripts/addr_is_all.sv: New file.
* sieve/testsuite/scripts/addr_is_domain.sv: New file.
* sieve/testsuite/scripts/addr_is_local.sv: New file.
* sieve/testsuite/scripts/addr_matches.sv: New file.
* sieve/testsuite/scripts/address.sv: New file.
* sieve/testsuite/scripts/allof00.sv: New file.
* sieve/testsuite/scripts/allof01.sv: New file.
* sieve/testsuite/scripts/allof11.sv: New file.
* sieve/testsuite/scripts/anyof00.sv: New file.
* sieve/testsuite/scripts/anyof01.sv: New file.
* sieve/testsuite/scripts/anyof11.sv: New file.
* sieve/testsuite/scripts/discard.sv: New file.
* sieve/testsuite/scripts/envelope1.sv: New file.
* sieve/testsuite/scripts/exists1.sv: New file.
* sieve/testsuite/scripts/exists2.sv: New file.
* sieve/testsuite/scripts/exists3.sv: New file.
* sieve/testsuite/scripts/false.sv: New file.
* sieve/testsuite/scripts/fileinto.sv: New file.
* sieve/testsuite/scripts/header1.sv: New file.
* sieve/testsuite/scripts/header2.sv: New file.
* sieve/testsuite/scripts/header3.sv: New file.
* sieve/testsuite/scripts/keep.sv: New file.
* sieve/testsuite/scripts/not.sv: New file.
* sieve/testsuite/scripts/null.sv: New file.
* sieve/testsuite/scripts/size1.sv: New file.
* sieve/testsuite/scripts/size2.sv: New file.
* sieve/testsuite/scripts/stop.sv: New file.
* sieve/testsuite/scripts/true.sv: New file.
* sieve/testsuite/sieve: New directory.
* sieve/testsuite/sieve/DISTFILES: New file.
* sieve/testsuite/sieve/action.exp: New file.
* sieve/testsuite/sieve/address.exp: New file.
* sieve/testsuite/sieve/allof.exp: New file.
* sieve/testsuite/sieve/anyof.exp: New file.
* sieve/testsuite/sieve/compile.exp: New file.
* sieve/testsuite/sieve/envelope.exp: New file.
* sieve/testsuite/sieve/exists.exp: New file.
* sieve/testsuite/sieve/false.exp: New file.
* sieve/testsuite/sieve/header.exp: New file.
* sieve/testsuite/sieve/not.exp: New file.
* sieve/testsuite/sieve/size.exp: New file.
* sieve/testsuite/sieve/true.exp: New file.
* testsuite/lib/mailutils.exp (mu_exec): added -arg-list option.
* testsuite/spool/sieve.mbox: New file. Mailbox for testing sieve.
* testsuite/spool/DISTFILES: Added sieve.mbox
* imap4d/testsuite/imap4d/list.exp: Updated to match new spooldir
contents.
2002-08-27 Sergey Poznyakoff
* frm/frm.c: Fixed return status when the mailbox does not exist.
* frm/Makefile.am: Added testsuite
* frm/testsuite: new directory.
* frm/testsuite/Makefile.am: new file.
* frm/testsuite/.cvsignore: new file.
* frm/testsuite/frm: new directory.
* frm/testsuite/frm/DISTFILES: new file.
* frm/testsuite/frm/test.exp: new file.
* from/Makefile.am: Added testsuite
* from/testsuite: new directory.
* from/testsuite/Makefile.am: new file.
* from/testsuite/.cvsignore: new file.
* from/testsuite/from: new directory.
* from/testsuite/from/DISTFILES: new file.
* from/testsuite/from/test.exp: new file.
* messages/messages.c: Added "mailbox" command line capability.
* messages/Makefile.am: Added testsuite
* messages/testsuite: new directory.
* messages/testsuite/Makefile.am: new file.
* messages/testsuite/.cvsignore: new file.
* messages/testsuite/messages: new directory.
* messages/testsuite/messages/DISTFILES: new file.
* messages/testsuite/messages/test.exp: new file.
* readmsg/readmsg.h: Added include <mailutils/url.h>
* readmsg/readmsg.c (struct argp_option options): Fixed definition
of -a option.
(print_header): Last header was never seen.
* readmsg/Makefile.am: Added testsuite
* readmsg/testsuite: new directory.
* readmsg/testsuite/Makefile.am
* readmsg/testsuite/.cvsignore: new file.
* readmsg/testsuite/readmsg: new directory.
* readmsg/testsuite/readmsg/DISTFILES: new file.
* readmsg/testsuite/readmsg/test.exp: new file.
* imap4d/testsuite/config/unix.exp: Renamed to ...
* imap4d/testsuite/config/default.exp: ... this
* imap4d/testsuite/config/DISTFILES: Likewise.
* mail/testsuite/config/unix.exp: Renamed to ...
* mail/testsuite/config/default.exp: ... this
* mail/testsuite/config/DISTFILES: Likewise.
* pop3d/testsuite/config/unix.exp: Renamed to ...
* pop3d/testsuite/config/default.exp: ... this
* pop3d/testsuite/config/DISTFILES: Likewise.
* configure.ac: Added new testsuites.
* testsuite/lib/mailutils.exp (mu_start): Modified.
2002-08-26 Sergey Poznyakoff
* frm/frm.c: Don't bail out if the mailbox does not exist.
* imap4d/append.c (imap4d_append0): Skip leading whitespace.
* imap4d/fetch.c (fetch_envelope0): Emit whitespace before
"from" header.
* imap4d/util.c: Fixed typo in comment.
* imap4d/testsuite/imap4d/append.exp: New file
* imap4d/testsuite/imap4d/create.exp: New file
* imap4d/testsuite/imap4d/expunge.exp: New file
* imap4d/testsuite/imap4d/examine.exp: Replaced
[imap4d_uidvalidity] with simple regexp.
* imap4d/testsuite/imap4d/fetch.exp: Likewise.
* imap4d/testsuite/lib/imap4d.exp (imap4d_test): Added new
options: -long to emit long IMAP4D literal after the command,
-silent to be silent about the results of the testcase.
* imap4d/testsuite/imap4d/DISTFILES: Added new files.
* testsuite/lib/mailutils.exp (mu_expect_list): New procedure
2002-08-23 Sergey Poznyakoff
* configure.ac: Added check for socklen_t.
* imap4d/commands.c: Fixed allowed states for X-VERSION command.
* imap4d/fetch.c (fetch_operation) Fix section specification
output.
* mail/testsuite/mail/folder.exp: Enabled "folders" test.
* imap4d/testsuite/imap4d/examine.exp: Moved get_uidvalidity
to imap4d.exp and renamed it to imap4d_uidvalidity.
* imap4d/testsuite/lib/imap4d.exp: Likewise
(imap4d_test): Added new switches: -literal and -noliteral
* imap4d/testsuite/imap4d/fetch.exp: New file
* imap4d/testsuite/imap4d/x.exp: New file
* imap4d/testsuite/imap4d/DISTFILES: Added fetch.exp, x.exp
* imap4d/testsuite/imap4d/search.exp: Added comments
* testsuite/spool/mbox: Changed `organization' header
* testsuite/spool/mbox1: Likewise.
* mail/testsuite/mail/write.exp: Adjusted tests to the changes in
mbox and mbox1.
* libmu_scm/mu_address.c (mu_address_get_count): Fixed
type of `count' variable
* mailbox/list.c (list_remove): Removed cast from void* to int,
it does not work on 64-bit machines. Besides, pointer comparison
is strictly defined by C.
* mailbox/observer.c (observable_detach): Likewise.
* mailbox/tcp.c (_tcp_open): Changed type of `namelen' to
socklen_t.
* mh/mh_format.c: Changed type of `len' to size_t.
* mail/folders.c (mail_folders): Protect directory name with
quotes.
2002-08-23 Sergey Poznyakoff
* testsuite/lib/mailutils.exp: Introduced -re flag
to handle a pattern as a regular expression, and --
flag to escape exact strings that actually happen
to start with "-re".
* imap4d/testsuite/lib/imap4d.exp: Properly handle
--re and -- flags.
* imap4d/testsuite/imap4d/examine.exp: Use -re to check
uidvalidity value, as we can never be sure the seconds
don't change between computing the uidvalidity value and
running the test.
2002-08-23 Sergey Poznyakoff
* configure.ac: Check if crypt is declared.
* auth/sql.c: Include <crypt.h> when available
* imap4d/imap4d.h: Include <url.h>
* imap4d/util.c: Descriptive comment on util_uidvalididty.
* lib/mu_asprintf.c: Removed.
* lib/mu_asprintf.h: Provide declarations for (v)asprintf.
* lib/Makefile.am: Removed mu_asprintf.c
* mailbox/mu_argp.c: Do not use asprintf.
* mailbox/mutil.c: Do not use asprintf.
* mailbox/parse822.c (parse822_time): Tolerate unknown
timezone abbreviations.
* mailbox/system.c: Include <crypt.h> when available
* imap4d/testsuite/imap4d/search.exp: New file. Provides tests
for SEARCH command.
* imap4d/testsuite/imap4d/DISTFILES: Added search.exp
* testsuite/spool/teaparty.mbox: Fixed timestamps.
* pop3d/testsuite/pop3d/read.exp: Updated to match new mailbox.
* mail/testsuite/mail/z.exp: Likewise.
* mail/testsuite/mail/tag.exp: Likewise.
2002-08-22 Sergey Poznyakoff
* configure.ac: Create imap4d/testsuite/Makefile
* imap4d/Makefile.am: Added testsuite
* imap4d/testsuite: Added to repository
* imap4d/testsuite/Makefile.am: Likewise.
* imap4d/testsuite/config: Likewise.
* imap4d/testsuite/config/DISTFILES: Likewise.
* imap4d/testsuite/config/unix.exp: Likewise.
* imap4d/testsuite/lib: Likewise.
* imap4d/testsuite/lib/DISTFILES: Likewise.
* imap4d/testsuite/lib/imap4d.exp: Likewise.
* imap4d/testsuite/imap4d: Likewise.
* imap4d/testsuite/imap4d/DISTFILES: Likewise.
* imap4d/testsuite/imap4d/anystate.exp: Likewise.
* imap4d/testsuite/imap4d/examine.exp: Likewise.
* imap4d/testsuite/imap4d/list.exp: Likewise.
* imap4d/util.c (util_uidvalidity): New function. A wrapper
around mailbox_uidvalidity. When a mailbox is selected whose
first message does not keep X-UIDVALIDITY value, the uidvalidity
is computed based on the return of time(). Now, if we call
"EXAMINE mailbox" or "STATUS mailbox (UIDVALIDITY)" the same
mailbox is opened second time and the uidvalidity recalculated.
Thus each subsequent call to EXAMINE or STATUS upon an already
selected mailbox will return different uidvalidity value. To
avoid this, util_uidvalidity() first sees if it is asked to
operate upon an already opened mailbox and if so, returns
previously computed value.
* imap4d/imap4d.h (util_uidvalidity): New function
* imap4d/select.c (imap4d_select_status): Use util_uidvalidity.
* imap4d/status.c (status_uidvalidity): Likewise.
* imap4d/list.c (imap4d_list): Added comment describing
when INBOX should be output.
* frm/frm.c: Fixed coredump when MAIL environment variable
has an empty value.
* mailbox/mutil.c (mu_tilde_expansion): Bugfix. Was freeing
passed homedir, which caused grief later.
2002-08-21 Jeff Bailey <jbailey@outpost.dnsalias.org>
* README: Make this a bit more current.
2002-08-21 Sergey Poznyakoff
Added pop3d testsuite.
* testsuite/makespool: New option -subst: sets sed command
to be used.
* testsuite/etc/passwd.in: New file. Template for etc/passwd
for testing pop3d and imap4d.
* testsuite/etc/DISTFILES: Added passwd.in
* testsuite/lib/mailutils.exp (mu_init,mu_version): Modified.
* configure.ac: Added pop3d/testsuite/Makefile
* pop3d/Makefile.am: Likewise.
* pop3d/testsuite: Added to repository
* pop3d/testsuite/Makefile.am: Likewise.
* pop3d/testsuite/config: Likewise.
* pop3d/testsuite/config/DISTFILES: Likewise.
* pop3d/testsuite/config/unix.exp: Likewise.
* pop3d/testsuite/lib: Likewise.
* pop3d/testsuite/lib/DISTFILES: Likewise.
* pop3d/testsuite/lib/pop3d.exp: Likewise.
* pop3d/testsuite/pop3d: Likewise.
* pop3d/testsuite/pop3d/DISTFILES: Likewise.
* pop3d/testsuite/pop3d/read.exp: Likewise.
* mail/testsuite/lib/mail.exp: Updated
* mailbox/mu_argp.c: New hidden option
--show-config-options. Displays a list of configuration
defines from config.h
2002-08-20 Sergey Poznyakoff
* Makefile.am: Added testsuite subdirectory
* configure.ac: Likewise.
* auth/virtual.c: A couple of bugfixes. Introduced
--virtual-passwd-dir switch to override the
default placement of virtual domain password files.
* testsuite: New dir. Common files for all testsuites.
* testsuite/lib: New dir.
* testsuite/lib/mailutils.exp: New file. Common test driver.
* mail/testsuite/spool: Moved to ...
* testsuite/spool: ... here
* mail/testsuite/folder: Moved to ...
* testsuite/folder: ... here
* mail/testsuite/etc: Moved to ...
* testsuite/etc: ... here
* mail/testsuite/Makefile.am: Removed etc, spool and folder test
dirs.
* mail/testsuite/lib/mail.exp: Updated.
* mail/testsuite/mail/folder.exp: Updated.
* mail/testsuite/mail/write.exp: Updated.
2002-08-15 Sergey Poznyakoff
* configure.ac: If -lcrypt is present, add it to LIBS
not to AUTHLIBS.
* auth/system.c: Moved to ...
* mailbox/system.c: ... here.
* auth/Makefile.am: Moved system.c to
* mailbox/Makefile.am: ... here.
* mailbox/mu_auth.c: Provide "generic:system" as
default.
* mailbox/sendmail.c (sendmail_send_message): Bugfix. In spite
of what the comment said, -t option is not implicit and must
be specified.
* mail/from.c: Bugfix: display even messages without Subject: or
From: headers.
* mail/reply.c: Fixed improper use of header_aget_value().
* mail/util.c (util_do_command): For compatibility with older
mails treat a number alone on the line as "print NUMBER".
2002-08-14 Sergey Poznyakoff
* auth/virtual.c: Removed vestiges of mu_virtual_domain.
* doc/texinfo/programs.texi: Documented authentication concepts
and related command line options.
* mail/testsuite/makespool: Added GNU copyleft header.
2002-08-13 Sergey Poznyakoff
* pop3d/apop.c: Switched to the new authentication/authorization
functions.
2002-08-13 Sergey Poznyakoff
To avoid confusion, pruned libmailbox directory.
* libmailbox/mailbox.c: Removed obsolete files.
* libmailbox/maildir.c: Likewise.
* libmailbox/mh.c: Likewise.
* libmailbox/unixmbox.c: Likewise.
* libmailbox/Makefile.am: Likewise.
* libmailbox/mailbox.h: Likewise.
* libmailbox/maildir.h: Likewise.
* libmailbox/mh.h: Likewise.
* libmailbox/unixmbox.h: Likewise.
* MySql/Makefile.am: Removed.
* MySql/MySql.c: Likewise.
* MySql/MySql.h: Likewise.
* MySql/.cvsignore
* auth/sql.c: Merged sql core stuff from MySql/MySql.c.
* auth/virtual.c: All functions made static.
* auth/system.c: Likewise.
* Makefile.am: Removed MySql
* configure.ac: Likewise.
2002-08-13 Sergey Poznyakoff
Moved authentication specific calls scattered all over the
code to one place: libmuauth library. The new code returns
authorization credentials in struct mu_auth_data. It contains
all information from struct passwd as well as some
mailutils-specific information. New options `--authentication'
and `--authorization' provide a way to override default
settings.
* configure.ac: Check for prototypes of strtok_r, strchrnul,
strndup, asprintf, vasprintf. Create auth/Makefile
* Makefile.am: Added auth to SUBDIRS.
* MySql/Makefile.am: Added INCLUDES
* MySql/MySql.c: Include <mailutils/error.h>
* comsat/comsat.c: Switched to the new
authentication/authorization functions.
* guimb/scm/sieve-core.scm: Likewise.
* imap4d/authenticate.c: Likewise.
* imap4d/bye.c: Likewise.
* imap4d/imap4d.c: Likewise.
* imap4d/login.c: Likewise.
* imap4d/namespace.c: Likewise.
* imap4d/rename.c: Likewise.
* pop3d/pop3d.c: Likewise.
* pop3d/user.c: Likewise.
* libmu_scm/mu_util.c: Likewise.
* mail.local/main.c: Likewise.
* mail.local/script.c: Likewise.
* mailbox/mbx_default.c: Likewise.
* mailbox/message.c: Likewise.
* mailbox/wicket.c: Likewise.
* mailbox/mu_argp.c: Removed pam- and sql-specific stuff
* mailbox/mu_auth.c: New file. Basic authentication/authorization
functions.
* mailbox/Makefile.am: Added mu_auth.c
* auth/: New directory. The libmuauth library.
* auth/system.c: New file. System-specific
(passwd/shadow) auth functions.
* auth/pam.c: New file. PAM-specific auth functions.
* auth/sql.c: New file. SQL-specific auth functions.
* auth/virtual.c: New file. Virtual-domain-specific auth functions.
* auth/Makefile.am: New file.
* pop3d/virtual.c: Removed.
* pop3d/Makefile.am: Removed virtual.c
* include/mailutils/mu_auth.h: New file. Prototypes for mailutils
authentication/authorization functions.
* include/mailutils/Makefile.am: Added mu_auth.h.
* include/mailutils/argp.h (mu_register_capa): New prototype.
* include/mailutils/mutil.h (mu_register_getpwnam,
mu_register_getpwuid,mu_getpwnam,mu_getpwuid,
mu_virtual_domain): Removed.
* mailbox/mutil.c: Likewise.
* lib/argp-help.c: Provide declarations for strchrnul, strndup
if necessary.
* lib/mu_asprintf.c: Likewise for vasprintf,asprintf
* imap4d/imap4d.h: Include <mailutils/mu_auth.h>
* comsat/comsat.h: Likewise.
* mail.local/mail.local.h: Likewise.
* pop3d/pop3d.h: Likewise.
* mailbox/smtp.c (message_has_bcc): Fixed inconsistency in
passing arguments to header_get_value().
* mail/set.c (mail_set): Fixed inconsistency in passing arguments
to strtoul().
* mail/util.c (util_get_homedir): Do not strdup return.
mu_get_homedir() does it now.
* mail/var.c (var_insert): Changed declaration to avoid
`auth shadows parameter' warning.
* mailbox/locker.c (_locker_lock_dotlock): Bugfix: do not leave
temporary lock file in case of errors
* mailbox/mailbox.c: Include <mailutils/attribute.h>
* mh/mh_init.c: Free return value of mu_get_homedir().
2002-08-08 Sergey Poznyakoff
* .cvsignore: Updated
* mail/testsuite/.cvsignore: Updated
* mail/testsuite/lib/mail.exp (default_mail_test): Ignore trailing
whitespace.
* mail/testsuite/mail/alias.exp: Remove trailing whitespace from
the patterns.
* mail/testsuite/mail/read.exp: Likewise.
* mail/testsuite/mail/tag.exp: Likewise.
* mail/testsuite/mail/write.exp: Likewise.
* mailbox/mu_argp.c: Initialize argp_program_bug_address.
* comsat/comsat.c: Removed argp_program_bug_address. Use
PACKAGE_STRING, provided by the new autoconf.
* dotlock/dotlock.c: Likewise.
* frm/frm.c: Likewise.
* from/from.c: Likewise.
* guimb/main.c: Likewise.
* imap4d/imap4d.c: Likewise.
* mail/mail.c: Likewise.
* mail.local/main.c: Likewise.
* mail.remote/mail.remote.c: Likewise.
* messages/messages.c: Likewise.
* mh/inc.c: Likewise.
* mh/scan.c: Likewise.
* sieve/sieve.c: Likewise.
* pop3d/capa.c: Likewise.
* pop3d/pop3d.c: Likewise. Imply debug mode if the input stream is
connected to a tty. Don't try to switch to "mail" group id in
debug mode.
* pop3d/popauth.c: Parse arguments using mu_argp instead of
getopt_long.
* readmsg/readmsg.c: Likewise.
2002-08-07 Sergey Poznyakoff
* mail/mail.h (struct mail_env_entry): Reorganized. Added
type member and changed "value" to be a union.
(environment functions): Changed prototypes.
(util_folder_path): New prototype.
* mail/util.c: Rewritten internal environment functions.
Environment variables are now typed, so setting "set folder=1"
won't cause coredumps anymore. The function util_getenv() is
used to retrieve a variable of given data type. util_find_env()
takes second argument specifying whether it should create a
missing variable. This function is used only in util.c and
var.c.
* mail/set.c: Use util_setenv().
* mail/alt.c: Use util_getenv().
* mail/copy.c: Use util_getenv(). Honour outfolder variable, when
set.
* mail/decode.c: Use util_getenv().
* mail/delete.c: Likewise.
* mail/file.c (mail_expand_name): Use util_getenv() and
util_folder_path().
* mail/folders.c: Use util_getenv().
* mail/if.c: Likewise.
* mail/mail.c: Likewise. Provide default for "regexp" internal
variable.
* mail/msgset.y: Likewise.
* mail/pipe.c: Likewise.
* mail/print.c: Likewise.
* mail/quit.c: Likewise.
* mail/send.c: Likewise.
* mail/top.c: Likewise.
* mail/var.c: Likewise.
* mail/mailline.c: Likewise.
* mail/write.c: Honour "outfolder" variable. If called without
arguments, deduce output file name from the number of current
message.
* mail/testsuite/makespool: Bugfix.
* mail/testsuite/lib/mail.exp (mail_start): New flag -reuse-spool.
(default_mail_test): If command is empty do not send anything.
(mail_test_file): New function. Test the contents of an
arbitrary file.
* mail/testsuite/mail/write.exp: New file. Tests for message
saving and disposing commands: delete, mbox, [sS]ave, [wW]rite
* mail/testsuite/mail/DISTFILES: Added write.exp
2002-08-06 Sergey Poznyakoff
* Makefile.am: Removed distcheck kludge. Testsuite doesn't
need it anymore.
* mail/testsuite/makespool: New file. Prepares data
for testsuite.
* mail/testsuite/Makefile.am: Added EXTRA_DIST and
distclean-local
* mail/testsuite/lib/mail.exp: Fixed paths.
(mail_prepare_spools,mail_cleanup_spools): new procedures.
* mail/testsuite/mail/folder.exp: Corrected paths.
2002-08-06 Sergey Poznyakoff
* Makefile.am: Added distcheck rule needed for
test suite.
* configure.ac: Added missing AH_BOTTOM and descriptions to
AC_DEFINEs. Replaced sr_STRUCT_TM.* with AC_CHECK_MEMBERS
(no aggregate members, so it's safe here).
* acconfig.h: Removed
* doc/texinfo/Makefile.am: DISTCLEANFILES
* lib/Makefile.am: Use LTLIBOBJS.
* m4/tm_gmtoff.m4: Removed.
* m4/tm_isdst.m4: Removed.
* m4/tm_zone.m4: Removed.
* m4/Makefile.am: Removed tm_ files.
* mail/testsuite/Makefile.am: Fixed generation of site.exp. Added
DISTCLEANFILES.
* mailbox/mutil.c: Changed HAVE_TM_.* to HAVE_STRUCT_TM_.*
* mailbox/parse822.c: Likewise.
* mailbox2/mutil.c: Likewise.
* mailbox2/parse822.c: Likewise.
* mh/mh_format.c: Likewise.
* imap4d/authenticate.c (imap4d_auth_capability): New function.
* imap4d/imap4d.h: Likewise.
* imap4d/capability.c (imap4d_capability): call
imap4d_auth_capability() to output AUTH= capabilities.
2002-08-05 Jeff Bailey <jbailey@outpost.dnsalias.org>
* lib/Makefile.am: Remove libtool hacks, automake now handles
LIBOBJS correctly.
* .cvsignore: Add autom4te.cache
* configure.in: Rename to ...
* configure.ac: ... this, and update to autoconf 2.5
* Makefile.am: Now requires Automake 1.6
* m4/malloc.m4: Update from gnulib
* m4/realloc.m4: Update from gnulib
* m4/regex.m4: Update from gnulib
* m4/utmp.m4: Change LIBOBJS to use AC_LIBOBJ
2002-08-05 Sergey Poznyakoff
* imap4d/version.c: New file. Support for X-VERSION command
* imap4d/Makefile.am: Added version.c
* imap4d/imap4d.c (main): Imply debug mode if the input stream is
connected to a tty. Don't try to switch to "mail" group id in
debug mode.
(imap4d_mainloop): Do not reveal our version. One may issue
X-VERSION command in authenticated state to get it.
* imap4d/imap4d.h (imap4d_version): New function.
* imap4d/list.c (imap4d_list): Remove state check. Bugfix:
allow a meta-closure (*) in any position of the word.
* imap4d/util.c (util_finish): Do not allow to switch to
a higher state in case of command failure.
(util_do_command): Run the command only if it is allowed in
the current state.
* imap4d/commands.c: Added entry for X-VERSION
* imap4d/capability.c: Indicate X-VERSION capability.
* imap4d/append.c: Remove state check.
* imap4d/authenticate.c: Likewise.
* imap4d/check.c: Likewise.
* imap4d/close.c: Likewise.
* imap4d/copy.c: Likewise.
* imap4d/create.c: Likewise.
* imap4d/delete.c: Likewise.
* imap4d/examine.c: Likewise.
* imap4d/expunge.c: Likewise.
* imap4d/fetch.c: Likewise.
* imap4d/login.c: Likewise.
* imap4d/logout.c: Likewise.
* imap4d/lsub.c: Likewise.
* imap4d/namespace.c: Likewise.
* imap4d/noop.c: Likewise.
* imap4d/rename.c: Likewise.
* imap4d/search.c: Likewise.
* imap4d/select.c: Likewise.
* imap4d/status.c: Likewise.
* imap4d/store.c: Likewise.
* imap4d/subscribe.c: Likewise.
* imap4d/uid.c: Likewise.
* imap4d/unsubscribe.c: Likewise.
2002-08-03 Sergey Poznyakoff
Use of attributes made consistent throughout the package:
* imap4d/fetch.c (fetch_flags0): Use util_print_flags.
* imap4d/search.c (cond_keyword): Likewise for
util_attribute_matches_flag.
* imap4d/imap4d.h (util_print_flags,util_attribute_to_type,
util_attribute_matches_flag): New prototypes.
* imap4d/select.c (imap4d_select_status): Run imap4d_sync()
to output EXISTS and RECENT untagged responses.
* imap4d/store.c (get_attribute_type): Removed.
util_attribute_to_type() does the job.
(imap4d_store0): Use util_attribute_to_type().
* imap4d/sync.c: Output the actual number of recent messages.
* imap4d/util.c: For consistency, reduced all operations
with flags to manipulations with _imap4d_attrlist array
RFC2060 states that \Seen flag means "Message has been read",
so it should be mapped to our MU_ATTRIBUTE_READ.
(util_print_flags, util_attribute_matches_flag): New functions.
* include/mailutils/mutil.h (mu_register_getpwuid): Fixed proto.
* mailbox/mutil.c: Likewise.
* include/mailutils/attribute.h (MU_ATTRIBUTE_IS_UNSEEN,
MU_ATTRIBUTE_IS_UNREAD): New macros.
* mailbox/attribute.c (attribute_is_recent): Use
MU_ATTRIBUTE_IS_UNSEEN.
(attribute_set_flags): If the required bits are already set,
do not modify anything
(attribute_unset_flags): If the required bits are already
cleared, do not modify anything
* mailbox/mbx_mbox.c (mbox_messages_recent): use
MU_ATTRIBUTE_IS_UNSEEN.
(mbox_message_unseen): use MU_ATTRIBUTE_IS_UNREAD.
* mailbox/mbx_mh.c (mh_messages_recent, mh_message_unseen): Likewise.
* imap4d/bye.c (imap4d_bye0): Use mailbox_flush.
* imap4d/close.c (imap4d_close): Likewise.
* mail/quit.c (mail_mbox_close): Likewise.
* pop3d/quit.c (pop3d_quit): Likewise.
* include/mailutils/mailbox.h (mailbox_flush): New prototype.
* mailbox/mailbox.c (mailbox_flush): New function. Marks all
messages as seen and saves the attributes to the mailbox,
optionally expunging it.
* mailbox/folder_imap.c (imap_flags): Empty attribute
list means MU_ATTRIBUTE_SEEN.
* mailbox/mbx_imap.c (flags_to_string): Map \Seen to
MU_ATTRIBUTE_READ.
2002-08-02 Sergey Poznyakoff
* MySql/MySql.c (getMpwuid): Bugfix. It should take a pointer as
its argument;
* MySql/MySql.h: Likewise
* imap4d/sync.c: Rearranged functions to let implicit prototyping
work.
* imap4d/fetch.c: include argcv.h
(fetch_send_address): Added const specifier to the declaration.
2002-08-01 Sergey Poznyakoff
* imap4d/util.c (util_msgset): Some comments
* mailbox/mu_argp.c (read_rc): Bugfix. linebuf must be freed
no matter was the string accepted or not.
* pop3d/pop3d.c (pop3d_argp_capa): Bugfix. Was missing
"mailbox" capability.
2002-08-01 Sergey Poznyakoff
* imap4d/util.c (util_msgset): Bugfix.
* imap4d/sync.c (notify_deleted): Implemented "immediate decrement
rule" required by RFC2060
Interchanged reset_uid() and notify(). Notify decides whether
and when reset_uid must be called.
(notify): Call reset_uid(). when necessary.
(reset_uid): Do not call notify().
(imap4d_sync): Call notify().
* imap4d/imap4d.h (fetch_flags0): New prototype.
* imap4d/fetch.c (fetch_flags0): New function. Produces untagged
fetch response for FETCH and STORE commands. If necessary outputs
also UID.
* imap4d/store.c (imap4d_store0): Use fetch_flags0.
2002-07-27 Sergey Poznyakoff
* imap4d/fetch.c: Do not use strtok_r to parse header values (it
ignores the quotes). *Lots* of bugfixes beside that.
* imap4d/util.c (util_msgset): Always return sorted msgset with
no duplicates. Fixed transcript support.
* THANKS: Added Jordy Mallach
2002-07-26 Sergey Poznyakoff
Provide session transcript support for the daemons. The
transcript is triggered by --transcript option to the
daemon. Its output goes to LOG_FACILITY.debug.
Fixed a couple of bugs in imap4d (Thanks, Jordy!)
* include/mailutils/argp.h (struct daemon_param): New member
`transcript'.
* mailbox/mu_argp.c (daemon option group): New option
--transcript.
* imap4d/util.c: Provide session transcript support.
* imap4d/fetch.c (bodystructure,send_parameter_list): Fixed
possible NULL dereference.
* imap4d/imap4d.c (struct daemon_param): Initialize typescript
member.
* imap4d/login.c: Changed PAM error handling.
* imap4d/signal.c: Handle SIGPIPE separately. Many clients seem to
not wait for a response to LOGOUT command.
* pop3d/extra.c (pop3d_outf): New function. Provides output
functionality with session transcript support.
(pop3d_readline): Support for session transcript.
* pop3d/pop3d.h (pop3d_outf): New prototype.
* pop3d/apop.c: Use pop3d_outf instead of fprintf
* pop3d/capa.c: Likewise.
* pop3d/dele.c: Likewise.
* pop3d/list.c: Likewise.
* pop3d/noop.c: Likewise.
* pop3d/quit.c: Likewise.
* pop3d/retr.c: Likewise.
* pop3d/rset.c: Likewise.
* pop3d/stat.c: Likewise.
* pop3d/top.c: Likewise.
* pop3d/uidl.c: Likewise.
* pop3d/user.c: Likewise.
(pop3d_user): Removed unneeded PAM_ERROR.
* pop3d/pop3d.c: Likewise.
(struct daemon_param): Initialize transcript member.
2002-07-23 Sergey Poznyakoff
* imap4d/imap4d.c (imap4d_parse_opt): Fixed dereference of
child_inputs. Thanks to Jordi Mallach.
* pop3d/pop3d.c (pop3d_parse_opt): Likewise.
(pop3d_argp_capa): Reordered capabilities to match those of
imap4d.
* comsat/comsat.c (comsatd_parse_opt): Likewise.
header_aget_value was modified on May 9 but its invocations
throughout the code were not examined. Here goes the fix:
* imap4d/fetch.c: Properly check the return from
headers_aget_value.
* mail/followup.c: Likewise.
* mail/reply.c: Likewise.
2002-07-22 Sergey Poznyakoff
* mail/delete.c (mail_delete): Initialize auto variables.
* mail/testsuite/mail/tag.exp: Test "tag" command and message
selection.
* mail/testsuite/mail/z.exp: Test "z" command.
* mail/testsuite/mail/DISTFILES: Added tag.exp, z.exp
* mail/testsuite/spool/teaparty.mbox: A mailbox for tag.exp and z.exp.
* mail/testsuite/spool/DISTFILES: Added teaparty.mbox
* mail/testsuite/etc/mail.rc: Set screen and columns.
2002-07-17 Sergey Poznyakoff
* mail/quit.c (mail_mbox_commit): Do not store deleted messages
into mbox (Thanks Matthew Whitworth).
2002-07-16 Sergey Poznyakoff
Based on ideas of Matthew Whitworth, moved mailbox file
expansion into a separate function:
* mail/file.c (mail_expand_name): New function. Expands mail
special characters in a filename.
* mail/mail.h: Likewise.
* mail/copy.c (mail_copy0): Use mail_expand_name().
* mail/quit.c (mail_mbox_commit): Fixed typo.
(mail_mbox_close): Do not expunge mailboxes if readonly is set.
Helps in testing mail.
* mail/alt.c: Use mu_errstring() where appropriate.
* mail/testsuite/mail/folder.exp: (new file) A regression test
for folder and file commands.
* mail/testsuite/mail/DISTFILES: Added folder.exp
* mail/testsuite/folder: (new dir) Data for folder.exp test.
* mail/testsuite/folder/DISTFILES: New file
* mail/testsuite/folder/one: New file
* mail/testsuite/folder/two: New file
* mail/testsuite/Makefile.am: Added folder.
* mail/testsuite/lib/mail.exp: Set MBOX variable.
* mail/testsuite/mail/read.exp: Force readonly mode before
proceeding.
* mail/testsuite/spool/mbox: (new)
* mail/testsuite/spool/DISTFILES: Added mbox
* THANKS: Added Matthew Whitworth
2002-07-15 Sergey Poznyakoff
* mail/folders.c (mail_folders): If the value of "folder" variable
does not start with '/' or '~', assume it is relative to the
user's homedir.
* mail/file.c (mail_file): Likewise. Thanks to Matthew Whitworth
<matthew@okcomputer.org> for reporting.
2002-07-13 Sergey Poznyakoff
* mailbox/mbx_default.c (mailbox_create_default): If the
mailbox name does not start with a '/' and does not contain
a protocol specification, assume it is a file name relative
to the cwd and convert it to the absolute file name.
* mail/size.c: Do not move the cursor after running the command.
* mail/testsuite/lib/mail.exp: Expect the prompt to appear after
the last pattern.
* mail/testsuite/mail/read.exp: Added tests for size and decode
commands.
* mail/testsuite/spool/mbox1: Added two MIME messages.
2002-07-03 Sergey Poznyakoff
* mail/testsuite/lib/mail.exp: Be more stringent in testing.
* mail/testsuite/mail/read.exp: Added tests for Print, top,
ignore and retain commands.
2002-07-02 Sergey Poznyakoff
* mail/mail.c (mail_capa): Added "mailbox" capability.
Added framework for dejagnu testsuite.
* configure.in: Call AC_CANONICAL_SYSTEM.
Create mail/testsuite/Makefile
* mail/Makefile.am: Added testsuite to SUBDIRS.
* mail/testsuite: New dir.
* mail/testsuite/Makefile.am: new file.
* mail/testsuite/.cvsignore: new file.
* mail/testsuite/config: New dir.
* mail/testsuite/config/DISTFILES: new file.
* mail/testsuite/config/unix.exp: Configuration file for Unix.
* mail/testsuite/etc: New dir.
* mail/testsuite/etc/DISTFILES: new file.
* mail/testsuite/etc/mail.rc: site-specific config for testing mail.
* mail/testsuite/lib: New dir.
* mail/testsuite/lib/DISTFILES: new file.
* mail/testsuite/lib/mail.exp: Dejagnu entry points for testing mail.
* mail/testsuite/mail: New dir.
* mail/testsuite/mail/DISTFILES: new file.
* mail/testsuite/mail/alias.exp: Test alias/unalias commands
* mail/testsuite/mail/read.exp: Test mail reading commands
* mail/testsuite/spool: New dir.
* mail/testsuite/spool/DISTFILES: new file.
* mail/testsuite/spool/mbox1: A mailbox for testing.
2002-06-29 Sergey Poznyakoff
* mail/headers.c: Fix divide by zero (noted by Matthew Whitworth).
2002-06-27 Sergey Poznyakoff
* libmu_scm/mu_message.c (mu_message_set_header_fields): Bugfix.
* imap4d/login.c (imap4d_login): Removed FIXME note: the user
need not have a homedir at all.
* mail.local/main.c (make_progfile_name): moved to ...
* mailbox/mutil.c (mu_expand_path_pattern): ... there.
* mail.local/mail.local.h (make_progfile_name): Removed
prototype.
* include/mailutils/mutil.h (mu_expand_path_pattern): new
prototype.
* mail.local/script.c (mda_init,mda_next): use mu_expand_path_pattern.
2002-05-24 Walter J. Mack <wmack@componentsw.com>
* include/mailutils/types.h: Include definition for __PMT
* include/mailutils/list.h: use __PMT in typedef
* include/mailutils/registrar.h: change all callback function
specs from __P to __PMT
* include/mailutils/filter.h: Likewise.
* include/mailutils/envelope.h: Add conditional closing bracket
to balance earlier extern "C" {
2002-05-16 Sergey Poznyakoff
* guimb/scm/sieve-core.scm (sieve-expand-filename): New function.
Expands ~ in the given pathname, using geteuid.
(action-fileinto): Use sieve-expand-filename. Be more robust
in error handling.
* libmu_scm/mu_util.c: Interfaces to functions from mutil.c
* libmu_scm/mu_scm.h (mu_scm_mutil_init): Prototype.
* libmu_scm/mu_scm.c (mu_scm_init): Init mu_util.c.
* libmu_scm/Makefile.am: Added mu_util.c.
* mail.local/mail.local.h (switch_user_id): prototype.
* mail.local/script.c (mda_catch_body): Switch to the
user's uid and change to his homedir before running his
filtering script. Switch back to root before running
mda().
2002-05-14 Sergey Poznyakoff
* mail.remote/Makefile.am: Removed reference to non-existent
mail.remote.h
2002-05-13 Sam Roberts
* comsat/comsat.h, frm/frm.c, from/from.c, guimb/main.c,
imap4d/imap4d.h, include/mailutils/Makefile.am,
include/mailutils/argp.h, include/mailutils/mailutils.h,
include/mailutils/mu_argp.h, mail/mail.h, mail.local/mail.local.h,
messages/messages.c, pop3d/pop3d.h, sieve/sieve.c: Removed
redundant mu_ prefix from mailutils/mu_argp.h.
* TODO: Updated.
* Makefile.am, mail.remote/.cvsignore, mail.remote/mail.remote.c,
configure.in: mail.remote now working as an SMTP forwarder.
* include/mailutils/: mu_features.h, types.h: Merged mu_features.h
into types.h.
* mailbox/mu_argp.c: Added :mailer group, with option --mailer,-M
to set the default mailer URL.
* mailbox/smtp.c: Now clearing Bcc: even when there is an explicit
TO argument. Not the best thing to do, but it seems to be What
Everybody Does.
* doc/texinfo/mailer.texi: Updated now that smtp mailer is working.
* mailbox/sendmail.c: Looking at other utilities makes me think
that providing -t to sendmail is optional, need to test this.
* mailbox/parse822.c: Updated TODO list and ran through GNU indent.
* include/mailutils/errno.h, mailbox/muerrno.c: An unsupported
mailer URL now gives a more specific error than EINVAL.
* mail/mailline.c: Silenced warnings that can appear depending on
the presence of readline, and various terminal APIs.
* include/mailutils/mailer.h, mailbox/mailer.c,
mailbox/include/mailer0.h: mailer_get|set_url_default() new
functions to set the default mailer
* lib/mu_asprintf.h: Removed dependency on mailutils.
2002-05-13 Sergey Poznyakoff
To avoid dependency problems moved mu_argp.c to mailbox. Changed
license to Lesser GPL.
* lib/mu_argp.h: Moved to ...
* include/mailutils/mu_argp.h: here.
* lib/mu_argp.c: Moved to ...
* mailbox/mu_argp.c: here.
* lib/Makefile.am: Removed mu_argp.* stuff.
* mailbox/Makefile.am: Added mu_argp.c
* include/mailutils/Makefile.am: Added mu_argp.h
* comsat/comsat.h: Changed mu_argp.h to mailutils/mu_argp.h
* frm/frm.c: Likewise.
* from/from.c: Likewise.
* guimb/main.c: Likewise.
* imap4d/imap4d.h: Likewise.
* imap4d/search.c: Likewise.
* mail/mail.h: Likewise.
* mail.local/mail.local.h: Likewise.
* messages/messages.c: Likewise.
* pop3d/pop3d.h: Likewise.
* sieve/sieve.c: Likewise.
* lib/utmp.c: Added missing includes.
2002-05-12 Sam Roberts
* doc/xml2texi.rb: Converts doxygen XML output to texinfo function
documentation.
2002-05-10 Sam Roberts
* mailbox/tcp.c: Not a good day, second typo in a row in
tcp_stream_create.
* include/mailutils/errno.h, mailbox/muerrno.c, mailbox/tcp.c:
tcp_stream_create now has more informative errors for no host or
port
* from/from.c: From now uses mu_argp, and has a debug flag.
* mailbox/tcp.c: The arg check I added was checking floating data
instead of actual args, serious error, fixed.
* examples/: Addrs, Addrs.good, Makefile, mbox-check.c,
mbox-dates.c, mbox-explode.c, mimetest.c, msg-send.c: Tweaked
header files to build without errors.
* examples/muemail.c: Test program for current email address
completion configuration.
* mailbox/parse822.c: Group names no longer appearing in address
lists (still parsed correctly).
2002-05-08 Sam Roberts
* mailbox/: smtp.c, include/mailer0.h: Implemented correct
semantics for sending mail to bcc'ed addresses.
* include/mailutils/mailer.h, mailbox/mailer.c:
mailer_check_to(): ensures that there all the to addresses are
qualified.
mailer_check_from(): ensures that there is only one address, and
it is qualified.
* include/mailutils/header.h, mailbox/header.c:
header_parse(): wasn't ignoring LWSP after "bcc : ...", fixed. header_set_value():
header_set_value(): there was no way to remove a field, now
calling set with a field value of NULL removes the field.
header_get_value(): was concatenating the values of all the
fields with the same name, now it doesn't.
header_get_address(): convenience function to get an address_t
from a header field.
header.h: sorted API functions to top of header, and ones used in
implementing header_t to the bottom.
* include/mailutils/address.h, mailbox/address.c:
address_concatenate() - appends one address list to another
address_get_group_count() - the number of groups in an address_t
address_get_unix_mailbox_count() - the number of unix mailboxes..
* include/mailutils/mutil.h, mailbox/mutil.c:
mu_get_host_name(): returns this host name, looking gethostname()
up with gethostbyname() if possible.
mu_get_user_email_domain() and family now use mu_get_host_name()
* mailbox/parse822.c: address parsing now creates email addresses
for unqualified "unix" style mailboxes by using the
mu_get_user_email_domain().
* include/mailutils/message.h, mailbox/message.c:
message_create_copy(): creates a copy of a message, useful when you
want to operate on a temporary copy of a message.
* mailbox/mbx_imap.c: Moved message copy code into
message_create_copy().
* mailbox/tcp.c: Attempting to connect to port 0 is now an error,
and resolver failures cause MU_ERR_GETHOSTBYNAME instead of the
less-than-useful EINVAL.
* include/mailutils/errno.h, mailbox/muerrno.c: Added smtp and
mailer return codes.
* mailbox/url_smtp.c: _url_smtp_init(): using url_parse(), now
accepts host AND port as args
* include/mailutils/url.h, mailbox/url.c:
url_is_scheme(url_t, const char*): new function
2002-05-02 Sergey Poznyakoff
* comsat/comsat.c: Provide extern declarations for *utent calls.
* lib/utmp.c: (new) Replacements for {set,get,end}utent calls.
* lib/Makefile.am: Added utmp.c
* m4/utmp.m4: (new) Detect presense of utmp.h and
{set,get,end}utent calls.
* m4/Makefile.am: Added utmp.m4
* configure.in: Call MU_CHECK_UTMP.
* readmsg/msglist.c: Renamed isnumber to is_number. Apparently,
OS X defines a macro with this name.
* libmu_scm/mu_address.c (_get_address_part): Bugfix. Was passing
too short a length to fun().
* guimb/scm/numaddr.scm: Changed runtime error reporting.
* guimb/scm/redirect.scm: Likewise. Initialize sender variable.
* guimb/scm/sieve-core.scm: Provide new runtime-message function.
* imap4d/select.c (imap4d_select0): Removed unused variable.
* mail.local/mail.local.h: Changed mda() declaration.
* mail.local/main.c: Likewise.
* mail.local/script.c (mda_catch_body): Check if the message is
to be delivered here, instead of doing it in deliver(). If the
message was modified, drop it to the separate temporary file
first, so that all modifications get to the user's maildrop.
2002-04-26 Sam Roberts
* include/mailutils/mutil.h: Included <mailutils/types.h>, which
will get <sys/types.h> & uid_t.
* lib/argp-help.c, messages/messages.c: Made inclusions of
<malloc.h> conditional on autoconf check.
2002-04-19 Sergey Poznyakoff
* guimb/scm/sieve.scm (sieve-parse-command): Bugfix: must always
return a list whose car is the token type.
New command line options: --debug and --lib-dir
* guimb/scm/mimeheader.scm: (new) Implements "mimeheader"
extension test. The test is similar to "header" but works
on multipart MIME messages also.
* guimb/scm/Makefile.am: Added mimeheader.scm
* libmu_scm/mu_message.c: New interfaces: mu-message-multipart?,
mu-message-get-num-parts, mu-message-get-part
* libmu_scm/mu_port.c (mu_port_mark): Do nothing if the port
is not in open state.
2002-04-15 Sam Roberts
* doc/texinfo/programs.texi, include/mailutils/mutil.h,
lib/mu_argp.c, mailbox/mutil.c: mu_get_user_email() assumed
we could deliver to the current host, on dialup systems,
and workstations this may not be true, so allow user names
to be qualified with the domain that should be used for email
mu_set_user_email() - email address to use for NULL (current) user
mu_set_user_email_domain() - domain to use to qualify an @-less
username
mu_get_user_email() - now uses default address and domain, if set
-E,--email-addr - config option, calls mu_set_user_email()
-D,--email-domain - config option, calls mu_set_user_email_domain()
:address - group for the above config options
* lib/Makefile.am, lib/mu_asprintf.c, lib/mu_asprintf.h,
mailbox/Makefile.am: One way to get rid of the annoying warnings
about asprintf() not being declared is to always call a mailutils
wrapper function, which in turn calls the real function. That means
the wrappers (and other functions in lib) will still compile with
warnings, but the mailbox and utility code can compile clean.
* doc/texinfo/programs.texi: Updated to match lib/mu_argp.c.
2002-04-15 Sergey Poznyakoff
* acconfig.h: Added placeholders for
PROGRAM_INVOCATION_NAME_DECLARED and
HAVE_PROGRAM_INVOCATION_NAME.
(@BOTTOM@): Provide external declarations for
program_invocation_.*name if necessary.
* configure.in: Check if program_invocation_.*name are
declared and/or defined.
* lib/Makefile.am: Always compile pin.c
* lib/pin.c: include <config.h>
* mh/mh.h: Added missing includes. Removed external
declaration of program_invocation_short_name.
* mh/mh_argp.c (mh_argp_parse): Removed local declarations
of program_invocation_.* variables.
* mh/mh_getopt.c: Removed include <mh.h>
* mh/mh_init.c: Added include <stdarg.h>
* libmu_scm/mu_scm.h: include <mailutils/url.h>
2002-04-15 Sergey Poznyakoff
* imap4d/namespace.c (namespace_getfullpath): Translate
INBOX to the corresponding filename.
* imap4d/copy.c (imap4d_copy0): Removed unnecessary code:
namespace_getfullpath() now translates INBOX to filename.
* imap4d/select.c: Likewise.
* imap4d/status.c: Likewise.
2002-04-14 Sam Roberts
* include/mailutils/mutil.h, mailbox/locker.c, mailbox/mutil.c:
Implemented symlink unrolling before locking.
* lib/mu_argp.c: Config files in ~/ all start with .mu again.
2002-04-12 Jeff Bailey <jbailey@outpost.dnsalias.org>
* configure.in: Bump version to 0.0.9d
2002-04-11 Sergey Poznyakoff
* lib/mu_argp.c: Fixed auto-arranging of
options groups. Fixed spelling of license option.
* comsat/comsat.c: Fixed spelling of "license" option.
* frm/frm.c: Likewise.
* guimb/main.c: Likewise.
* imap4d/imap4d.c: Likewise.
* mail/mail.c: "mailutils" capability does not exist any more.
Changed to "common", "license".
* messages/messages.c: Likewise.
* pop3d/pop3d.c: Likewise.
* mail.local/main.c: Added "license" capability.
2002-04-10 Sam Roberts
* mail.local/main.c: split mailutils capabilities
* frm/frm.c: mailutils capabilities were split, and it now reports
failure, rather than calling failure success.
* comsat/comsat.c, guimb/main.c, imap4d/imap4d.c: mailutils
capabilities were split up
* mail.remote/: Makefile.am, mail.remote.c: A stub mail.remote. It
is waiting on completion of the smtp mailer_t.
* lib/mu_argp.c: Default per-utility config files are ~/.programrc.
If you want to segregate you mailutils configuration, make
~/.mailutils a directory, and put your config files in it (same
name, minus the leading "."). Also organized all common options
under the heading "Common options", moved the daemon and auth
options before the common options, and implemented a --lock-flags
option.
* include/mailutils/locker.h, mailbox/locker.c:
(locker_set_default_flags) new function to set the default locking
flags Fixed bug wherein lock count wasn't incremented for external
locking. Fixed bug wherein the right flags wasn't checked during
union init.
2002-04-10 Sergey Poznyakoff
* imap4d/list.c: Removed imap_match().
* imap4d/util.c (util_wcard_match): from list.c
* imap4d/imap4d.h: Proto for util_wcard_match() and defines
for its return values.
* imap4d/lsub.c: Output only those list items that match
given wildcard expression.
* mailbox/mutil.c (mu_register_retriever): Register a retrieving
function.
(mu_retrieve): Retrieve information using stack of retriever
functions.
(mu_getpwnam,mu_register_getpwnam): Rewritten using retriever
functions.
(mu_getpwuid,mu_register_getpwuid): Likewise.
* include/mailutils/mutil.h: Prototypes for general-purpose
retrieval functions.
2002-04-08 Sergey Poznyakoff
* include/mailutils/locker.h (MU_LOCKER_KERNEL): New locker
type: implies kernel-locking.
* mailbox/locker.c: Reorganized. Default locking type is DOTLOCK.
If the mailbox to be locked is not writable for the user,
locking type changes to NULL (no locking at all). If the
directory where the mailbox resides is not writable, the
locking type switches to KERNEL.
* m4/gssapi.m4: Fixed typo.
2002-04-04 Sergey Poznyakoff
* imap4d/lsub.c (imap4d_lsub): Return OK response, unless
something grave has happened.
2002-03-28 Sergey Poznyakoff
Several bugfixes:
1. mail -f~user/path coredumps
2. mail --mail-spool [other than mbox URL]://hostname did not
work (same for frm and others).
3. mail --mail-spool imap://hostname did not work (at least
with our imap4d).
* imap4d/list.c (print_dir): Enclose empty filename
in doublequotes.
* mailbox/folder_imap.c (imap_string): Return 1 if
the input is not a quoted string.
(imap_list): Ignore NIL delimiters, correctly handle
strings, not enclosed in doublequotes.
* mailbox/mbx_default.c (user_mailbox_name): Operate
only on mbox: and path URLs.
* guimb/main.c (main): initialize c.
2002-03-28 Sergey Poznyakoff
* lib/mu_argp.c: Renamed --maildir to --mail-spool.
* doc/texinfo/programs.texi: Documented --mail-spool option.
* configure.in: Renamed --with-maildir to --with-mail-spool for
symmetry.
* mail/mail.c: Some measures to help avoid the confusion about
--file option:
(Help output): Print additional note about --file taking
optional argument.
(parse_opt): Try to figure out if argument to -f was
separated by a whitespace. If so, print a warning and
switch to mail-reading mode. Hopefully this will help
avoid the confusion.
(main): Print more detailed diagnostics if mailbox_scan
failed.
* include/mailutils/errno.h: New error code MU_ERR_NO_SUCH_USER
* mailbox/muerrno.c: Likewise.
* mailbox/mbx_default.c (split_shortcut): Properly handle "~/"
filenames.
(tilde_expand): Return MU_ERR_NO_SUCH_USER if an invalid username
was specified.
2002-03-25 Sergey Poznyakoff
Was too quick about _exit :^)
* configure.in: Check for _exit.
* mailbox/mutil.c (mu_spawnvp): Protected _exit by #ifdef.
2002-03-25 Sergey Poznyakoff
Bunch of fixes:
Use of ~/.<program>rc caused problems with mail utility,
whose native profile is ~/.mailrc:
* lib/mu_argp.c: Renamed program-specific profiles to
~/.mu.<program>rc.
* doc/texinfo/programs.texi: Documented use of ~/.mu.<program>rc
* libmu_scm/mu_scm.h: Added some includes, needed after
yesterday's modifications.
* mailbox/locker.c: include <sys/wait.h>
* mailbox/mutil.c: _exit is not portable.
* mailbox2/include/mailutils/types.h: (new)
* mailbox2/include/mailutils/Makefile.am: Added types.h
* mailbox2/debug.c: Include <mailutils/debug.h>
* mailbox2/include/mailutils/address.h: Removed typedefs. Included
<mailutils/types.h>
* mailbox2/include/mailutils/attribute.h: Likewise.
* mailbox2/include/mailutils/body.h: Likewise.
* mailbox2/include/mailutils/debug.h: Likewise.
* mailbox2/include/mailutils/envelope.h: Likewise.
* mailbox2/include/mailutils/folder.h: Likewise.
* mailbox2/include/mailutils/header.h: Likewise.
* mailbox2/include/mailutils/iterator.h: Likewise.
* mailbox2/include/mailutils/list.h: Likewise.
* mailbox2/include/mailutils/lockfile.h: Likewise.
* mailbox2/include/mailutils/mailbox.h: Likewise.
* mailbox2/include/mailutils/mbox.h: Likewise.
* mailbox2/include/mailutils/message.h: Likewise.
* mailbox2/include/mailutils/observable.h: Likewise.
* mailbox2/include/mailutils/observer.h: Likewise.
* mailbox2/include/mailutils/pop3.h: Likewise.
* mailbox2/include/mailutils/property.h: Likewise.
* mailbox2/include/mailutils/refcount.h: Likewise.
* mailbox2/include/mailutils/stream.h: Likewise.
* mailbox2/include/mailutils/ticket.h: Likewise.
* mailbox2/include/mailutils/url.h: Likewise.
2002-03-24 Sam Roberts
* dotlock/dotlock.c, include/mailutils/locker.h, mailbox/locker.c:
Added lock mode MU_LOCK_EXTERNAL which calls an external program to
do the locking. Default is "dotlock", which is setgid mail so can
lock in a mailspool that users may not have write permissions to.
* mailbox/mutil.c: mu_spawnvp(): new function - like system, but
doesn't use /bin/sh, just forks and calls execvp(), with
system-like signal handling.
* configure.in: Check for vfork().
* mail/echo.c: %d fmt not matching long arg
* mail/msgset.y: fixed warning about included regex.h redefining
RE_DUP_MAX from limits.h
* TODO: Added Alain's suggestions about read/write lock
optimization, etc.
* include/mailutils/*.h, comsat/comsat.h, frm/frm.c, from/from.h,
imap4d/imap4d.h, url.h, mail/mail.h, mail.local/mail.local.h,
mailbox/attachment.c, mailbox/filter.c, mailbox/filter_rfc822.c,
mailbox/filter_trans.c, mailbox/folder.c, mailbox/folder_imap.c,
mailbox/folder_mbox.c, mailbox/folder_pop.c, mailbox/iterator.c,
mailbox/mailbox.c, mailbox/mailer.c, mailbox/mbx_default.c,
mailbox/mbx_file.c, mailbox/mbx_imap.c, mailbox/mbx_mbox.c,
mailbox/mbx_mh.c, mailbox/mbx_pop.c, mailbox/message.c,
mailbox/muerrno.c, mailbox/observer.c, mailbox/registrar.c,
mailbox/sendmail.c, mailbox/smtp.c, mailbox/stream.c,
mailbox/url_mbox.c, mailbox2/include/mailutils/authority.h,
messages/messages.c, pop3d/pop3d.h, readmsg/readmsg.h,
sieve/sieve.c, sieve/sieve.h, sieve/sv.h, sieve/svcb.c,
sieve/svctx.c, sieve/svfield.c, sieve/svfield.h, sieve/svutil.c:
Finished split of forward declarations into <mailutils/types.h>.
Now you have to include the header for the functions you want to
use, but you can change a header without causing a recompile of
everything. Also added some missing LGPL file headers.
2002-03-21 Sergey Poznyakoff
* include/mailutils/locker.h: New flag MU_LOCKER_NULL
to be used with temporary mailboxes stored in memory.
* mailbox/locker.c: Do not try to lock "/dev/null"
mailboxes. These are used in several programs
(namely, comsat, imap4d, pop3d).
* mailbox2/pop3/Makefile.am: libpop3_la_SOURCES was
missing.
2002-03-19 Sam Roberts
* doc/texinfo/programs.texi: Document use of ~/.<program>rc.
2002-03-18 Sam Roberts
* sieve/sieve.c: Now using mu_argp_parse(), but not the capa[]
(yet).
* lib/: mu_argp.c, mu_argp.h: Added ~/.<progname>rc to be last
config file. Fixed segv for NULL capa and added header file blurb.
* mailbox/locker.c: Implemented NFS-safe locking, using link()
from a uniquely named file.
2002-03-15 Alain Magloire
Nuking of some useless warnings, and make "char *" --> "const char *"
when required.
* mailbox/include/imap0.h: warning: comma at end of enumerator list.
* mailbox/locker.c (locker_set_expire_time): warning: declaration of `time'
shadows global declaration
(locker_get_expire_time): declaration of `time' shadows global declaration
* mailbox/mbx_default.c (mu_path_maildir): Use "const" to reinforce a constant string.
* include/mailutils/mailbox.h (mu_path_maildir): constant "const".
* mailbox/mbx_mbox.c (mbox_append_message): status already declared.
* mailbox/memory_stream.c (_memory_truncate): Cast before doing the comparison.
* mailbox/parse822.c (parse822_time): useless ';' outside function definition.
* mailbox/smtp.c (smtp_send_message): warning: declaration of `from' shadows a parameter
declaration of `to' shadows a parameter.
2002-03-14 Sergey Poznyakoff <gray@Mirddin.farlep.net>
* mail/util.c (util_do_command): Coredumped in false branches
of `if ... endif' statement. Fixed.
2002-03-13 Alain Magloire
* lib/mu_dmb.c(mu_check_perm): Reinforce
by using (const char *name) in the argument.
* pop3d/pop3d.c: The variable state was already
use as a global, use "astate" in function pop3_parse_opt().
* mail/next.c: Wrong return value;
* mail/previous.c: Wrong return value;
2002-03-13 Alain Magloire
* mail/echo.c: Make it aware of escape char '\'.
* mail/next.c: Should print the message also.
* mail/previous.c: Should print the message also.
* mail/util.c(util_do_command): Memory leak cmd
was not free(cmd). An empty line means now "next".
2002-03-13 Sergey Poznyakoff
* include/mailutils/Makefile.am: Added types.h
* argp/{argp-eexst.c,argp-namefrob.h,argp.h,
argp-fmtstream.c,argp-parse.c,argp-fmtstream.h,argp-pv.c,
argp-fs-xinl.c,argp-pvh.c,pin.c,argp-ba.c,argp-help.c,
argp-xinl.c}: Moved to ../lib
* argp/Makefile.am: Removed
* argp/.cvsignore: Removed
* lib/{argp-eexst.c,argp-namefrob.h,argp.h,argp-fmtstream.c,
argp-parse.c,argp-fmtstream.h,argp-pv.c,
argp-fs-xinl.c,argp-pvh.c,pin.c,argp-ba.c,argp-help.c,
argp-xinl.c}: Added from ../argp
* lib/Makefile.am: Added argp* files.
* Makefile.am: Removed argp from SUBDIRS.
* configure.in: Changed replace code for argp* functions.
* comsat/Makefile.am: Removed @ARGPINCS@ and @ARGPLIBS@
* dotlock/Makefile.am: Likewise.
* frm/Makefile.am: Likewise.
* guimb/Makefile.am: Likewise.
* imap4d/Makefile.am: Likewise.
* pop3d/Makefile.am: Likewise.
* mail/Makefile.am: Likewise.
* mail.local/Makefile.am: Likewise.
* messages/Makefile.am: Likewise.
* sieve/Makefile.am: Likewise.
* mh/Makefile.am: Likewise.
Synchronized mailbox2/include with changes dated 2002-02-27:
* mailbox2/include/mailutils/mu_features.h: Added
* mailbox2/include/mailutils/Makefile.am: Added mu_features.h
Removed definition of __P, included <mailutils/mu_features.h>.
Files affected:
* mailbox2/include/mailutils/address.h,
* mailbox2/include/mailutils/attribute.h,
* mailbox2/include/mailutils/authority.h,
* mailbox2/include/mailutils/body.h,
* mailbox2/include/mailutils/debug.h,
* mailbox2/include/mailutils/envelope.h,
* mailbox2/include/mailutils/error.h,
* mailbox2/include/mailutils/folder.h,
* mailbox2/include/mailutils/header.h,
* mailbox2/include/mailutils/iterator.h,
* mailbox2/include/mailutils/list.h,
* mailbox2/include/mailutils/lockfile.h,
* mailbox2/include/mailutils/mailbox.h,
* mailbox2/include/mailutils/mbox.h,
* mailbox2/include/mailutils/message.h,
* mailbox2/include/mailutils/mutil.h,
* mailbox2/include/mailutils/observable.h,
* mailbox2/include/mailutils/observer.h,
* mailbox2/include/mailutils/parse822.h,
* mailbox2/include/mailutils/pop3.h,
* mailbox2/include/mailutils/property.h,
* mailbox2/include/mailutils/refcount.h,
* mailbox2/include/mailutils/stream.h,
* mailbox2/include/mailutils/ticket.h,
* mailbox2/include/mailutils/url.h,
* mailbox2/include/mailutils/sys/address.h,
* mailbox2/include/mailutils/sys/attribute.h,
* mailbox2/include/mailutils/sys/authority.h,
* mailbox2/include/mailutils/sys/debug.h,
* mailbox2/include/mailutils/sys/envelope.h,
* mailbox2/include/mailutils/sys/folder.h,
* mailbox2/include/mailutils/sys/header.h,
* mailbox2/include/mailutils/sys/list.h,
* mailbox2/include/mailutils/sys/lockfile.h,
* mailbox2/include/mailutils/sys/mailbox.h,
* mailbox2/include/mailutils/sys/message.h,
* mailbox2/include/mailutils/sys/observable.h,
* mailbox2/include/mailutils/sys/observer.h,
* mailbox2/include/mailutils/sys/refcount.h,
* mailbox2/include/mailutils/sys/ticket.h,
* mailbox2/include/mailutils/sys/url.h.
2002-03-11 Sam Roberts
* include/mailutils/: address.h, locker.h, mailbox.h, message.h,
types.h: Got tired of recompiling EVERYTHING when I touched
locker.h, so started splitting common types into
<mailutils/types.h>.
* include/mailutils/error.h: mu_verror() wasn't prototyped.
* mailbox/: filter_trans.c, folder_imap.c, mailbox.c,
mbx_default.c, mbx_mbox.c, sendmail.c, stream.c, include/imap0.h:
Corrected type mismatches visible on 64-bit systems, and including
locker.h, some misc compiler warnings.
* mail.local/mail.local.h: Need to include locker.h.
* lib/strchrnul.c, mail/mail.c, mail/mail.h, mail/send.c,
mail/size.c, mail/util.c: Corrected type mismatches visible on
64-bit systems.
* argp/argp-parse.c: alloca wasn't included.
* messages/messages.c: Corrected type mismatches visible on 64-bit
systems.
* imap4d/: copy.c, store.c, util.c: Corrected type mismatches
visible on 64-bit systems.
* imap4d/: imap4d.h, select.c: Select now fails if the locking
fails.
* TODO: more things todo
(Steven Michael ROBBINS <stever@po-box-cgrl-lab.cs.mcgill.ca>
contributed a patch to fix 64-bit type mismatches.)
2002-03-09 Sergey Poznyakoff
* lib/mu_argp.c: Process user's private initialization file
after processing the site-wide one.
(mu_create_argcv): was allocating an extra slot in argv array.
* mail.local/main.c: Added `auth' capability.
* doc/texinfo/programs.texi: Documented new configuration file
mechanism.
2002-03-09 Sergey Poznyakoff
* configure.in: Check for libresolv.
Based on the discussion with Sam, changed handling of
mailutils' command line options. Command line is parsed using
mu_argp_parse() call. mu_argp_parse scans global configuration
file and processes any options found there before those from
the command line. The options are separated by categories
(capabilities):
mailutils --maildir, --license
auth --sql-.* family, --pam-service
logging --log-facility
daemon --daemon, --inetd, --port, --timeout
If a capability name appears in configuration file, it
should be prefixed with : to discern it from the utility
name.
* examples/mailutils.rc: Updated to reflect changes in the syntax.
* lib/mu_argp.c: New function mu_argp_parse is intended to be used
by all programs in the package in order to do command line parsing.
* lib/mu_argp.h: Removed unneeded prototypes. Added prototype for
mu_argp_parse().
* comsat/comsat.c: Use mu_argp_parse.
* frm/frm.c: Likewise.
* guimb/main.c: Likewise.
* imap4d/imap4d.c: Likewise.
* mail/mail.c: Likewise.
* messages/messages.c: Likewise.
* pop3d/pop3d.c: Likewise.
* mail.local/main.c: Likewise.
(deliver): Restored erroneously removed variable sb.
* pop3d/apop.c (pop3d_apopuser): Changed scope of auto variable
rc.
2002-03-01 Sam Roberts
* mailbox/mbx_mboxscan.c: Check return value of locker_lock().
* Makefile.am, configure.in: Added dotlock.
* mailbox/: mbx_mbox.c, mbx_mboxscan.c, mbx_mh.c: locker API
modified. using mu_errstring() instead of strerror().
* mailbox/mbx_pop.c: Using mu_errstring() instead of strerror().
* pop3d/lock.c: locker_lock() api changed. pop3d uses MU_LOCKER_PID.
* mail.local/main.c: Retrying the dot lock is now handled by the
locker_t.
* dotlock/: .cvsignore, Makefile.am, dotlock.c: dotlock - setgid
program to dot lock a file, modelled on mutt_dotlock.
* mailbox/locker.c, include/mailutils/locker.h: New modes,
including a retry mode (the default), removed fcntl and stub
read/write lock mode. New function, to remove a lock even if not
owned (useful for the external dotlock utility). New functions,
to set the expire time for MU_LOCKER_TIME, the flags, and the
retries and retry sleep for MU_LOCKER_RETRY.
2002-02-27 Sam Roberts
* examples/: Addrs.good, addr.c: New addr return codes.
* mail.local/mail.local.h: Including <mailutils/errno.h>.
* mail/mail.h: Added <strings.h> for systems that have it.
2002-02-27 Sergey Poznyakoff
* imap4d/status.c: Provide better diagnostics.
* comsat/comsat.c: Use mu_path_maildir instead of maildir.
* guimb/collect.c: Likewise.
* imap4d/select.c: Likewise.
* lib/mu_argp.c: Likewise.
* mail.local/main.c: Likewise.
* pop3d/apop.c: Likewise.
* pop3d/user.c: Likewise.
* lib/mu_argp.h: Removed extern char *maildir.
* mailbox/mbx_default.c: Essentially rewritten.
mailbox_open_default() supports the following naming schemes:
% --> system mailbox for the real uid
%user --> system mailbox for the given user
~/file --> /home/user/file
~user/file --> /home/user/file
+file --> /home/user/Mail/file
=file --> /home/user/Mail/file
* mail/file.c: Do not handle '%name' separately:
mailbox_open_default now does it.
* mail/mail.c: Properly handle --user (open user's system
mailbox).
* mailbox/mutil.c (mu_getcwd): New function. Return the name
of current working directory. The return value is malloc'ed
(mu_get_full_path): New function. Translate cwd-relative
pathname to its absolute equivalent. Both moved from
mbx_default.c.
* mail.local/mailquota.c (check_quota): Initialize contentd
to all zeroes before mu_dbm_fetch. This is needed by
(at least) Berkeley DBM.
* include/mailutils/mu_features.h: (new) Define system-dependent
macros, used by all mailutils. Currently, it contains only
__P() definition.
* include/mailutils/Makefile.am: Added mu_features.h.
Removed definitions of __P() scattered over multiple header
files. Included <mailutils/mu_features.h> instead. Files
affected:
* imap4d/imap4d.h,
* mail/mail.h,
* pop3d/pop3d.h,
* readmsg/readmsg.h,
* include/mailutils/address.h,
* include/mailutils/attribute.h,
* include/mailutils/auth.h,
* include/mailutils/body.h,
* include/mailutils/debug.h,
* include/mailutils/envelope.h,
* include/mailutils/errno.h,
* include/mailutils/error.h,
* include/mailutils/filter.h,
* include/mailutils/folder.h,
* include/mailutils/header.h,
* include/mailutils/iterator.h,
* include/mailutils/list.h,
* include/mailutils/locker.h,
* include/mailutils/mailbox.h,
* include/mailutils/mailer.h,
* include/mailutils/message.h,
* include/mailutils/mime.h,
* include/mailutils/monitor.h,
* include/mailutils/mutil.h,
* include/mailutils/observer.h,
* include/mailutils/parse822.h,
* include/mailutils/property.h,
* include/mailutils/registrar.h,
* include/mailutils/stream.h,
* include/mailutils/url.h,
* mailbox/include/address0.h,
* mailbox/include/attribute0.h,
* mailbox/include/auth0.h,
* mailbox/include/body0.h,
* mailbox/include/debug0.h,
* mailbox/include/envelope0.h,
* mailbox/include/filter0.h,
* mailbox/include/folder0.h,
* mailbox/include/header0.h,
* mailbox/include/imap0.h,
* mailbox/include/iterator0.h,
* mailbox/include/list0.h,
* mailbox/include/mailbox0.h,
* mailbox/include/mailer0.h,
* mailbox/include/message0.h,
* mailbox/include/mime0.h,
* mailbox/include/monitor0.h,
* mailbox/include/observer0.h,
* mailbox/include/property0.h,
* mailbox/include/registrar0.h,
* mailbox/include/stream0.h,
* mailbox/include/url0.h.
* lib/argcv.h: Use PROTOTYPES to determine whether the compiler
understands function prototypes.
2002-02-25 Sam Roberts
* sieve/examples/: .cvsignore, Makefile, Test, mbox.complex,
t-exists.sv, test.out: Exercise a little more of sieve.
* mailbox/wicket.c, mailbox/message.c,
imap4d/imap4d.h, mail/mail.c, mail/mail.h, pop3d/apop.c,
pop3d/pop3d.h, readmsg/readmsg.c, readmsg/readmsg.h, sieve/sieve.c,
sieve/sv.h, sieve/svcb.c, sieve/svctx.c examples/Makefile,
examples/addr.c, examples/mbox-check.c, examples/mbox-dates.c,
examples/mbox-explode.c, examples/mimetest.c, examples/msg-send.c,
examples/url-parse.c, comsat/comsat.c, comsat/comsat.h, from/from.c,
guimb/collect.c, guimb/guimb.h:
Replaced strerror() with mu_errstring().
* include/mailutils/errno.h, mailbox/Makefile.am,
mailbox/muerrno.c: Added muerrno.c to the build, added locker
error numbers.
2002-02-23 Sam Roberts
* mailbox/: message.c, smtp.c: Include <mailutils/mutil.h> for
mu_getpwuid() prototype.
* doc/texinfo/programs.texi: A # must be preceded by whitespace to
start an rcfile comment.
2002-02-20 Sam Roberts
* TODO: Updated.
2002-02-23 Sergey Poznyakoff
* lib/argcv.c: Yesterday's fix makes argcv_get include trailing
whitespace to the argv array. To fix:
(argcv_scan): Return len+1 if called on or after
the terminating null character.
(argcv_get): Initialize *argc to zero and continue scanning
until argcv_scan return is > len. Thanks Sam for noticing.
More fixes:
(argcv_scan): Correctly handle comments without intervening
whitespace between the comment character and remaining text,
e.g.:
set a=2 #comment
2002-02-22 Sergey Poznyakoff
* lib/argcv.c (argcv_get): Bugfix, *argc must be initialized to 1.
* lib/mu_argp.c (mu_common_argp_parser): Handle ARGP_KEY_FINI
case.
(mu_argp_error_code): new global. Specifies exit code for
exits on error.
* lib/mu_argp.h: extern declaration for mu_argp_error_code.
* comsat/comsat.c: Removed call to mu_normalize_maildir.
* imap4d/imap4d.c: Likewise.
* mail.local/main.c: Likewise.
* pop3d/pop3d.c: Likewise.
* imap4d/status.c: Syntax cleanup.
* mail/mail.h: include mu_argp.h
* mail/mail.c (main): Handle mailutils-common arguments.
* frm/frm.c: Likewise.
* guimb/main.c: Likewise.
* messages/messages.c: Likewise.
* frm/Makefile.am: Added ARGP stuff.
* guimb/Makefile.am: Likewise.
* imap4d/Makefile.am: Restored imap4d_DEPENDENCIES. Without it
@AUTHOBJS@ do not get into dependencies.
2002-02-21 Jeff Bailey <jbailey@outpost.dnsalias.org>
* sieve/Makefile.am: Link @ARGPLIBS@ before libmailutils.la to
compensate for lack of interlibrary dependencies
* configure.in: Detect either curses or ncurses
* include/mailutils/Makefile.am: Add errno.h
2002-02-20 Sam Roberts
* comsat/action.c, comsat/cfg.c, lib/argcv.c, lib/argcv.h,
lib/mu_argp.c, mail/send.c, mail/util.c, mh/mh_argp.c,
pop3d/popauth.c: argcv_get() now (optionally) strips comments while
parsing. Its the right place because it tokenizes, and whether a
char is a comment or not depends on whether its in the middle of a
token or not: "hi # there" # comment.
* sieve/sieve.c: Now supports a ~/.sieverc file. Mine looks like:
# ~/.sieverc
# Just moves my mail into my local spool.
-dTt --ticket=~/.tickets
-f pop://pop.uniserve.com
~/.filter.sv
* include/mailutils/debug.h: The debug levels are a bitmask, and
I'd started to enumerate them. Oops.
* mailbox/muerrno.c: Began the task of returning more informative
error numbers. If this looks useful, we should all spread it
through the files we touch!
* doc/texinfo/: mailutils.texi, programs.texi: The info docs were
getting installed in the "Miscellaneous" section of the info
directory, now they go in GNU Libraries, with links to the programs
under GNU Utilities, as seemed to be suggested by the texinfo docs.
Maybe there's a better convention?
* include/mailutils/errno.h, mailbox/address.c, mailbox/mailbox.c,
mailbox/parse822.c: Began the task of returning more informative
error numbers. If this looks useful, we should all spread it
through the files we touch!
* sieve/svcb.c: Was using the POSIX (1003.1b) ENOTSUP, changed to
ENOSYS, which will exist most places, as Jeff pointed out.
2002-02-20 Sergey Poznyakoff
* imap4d/status.c (imap4d_status): Bugfix: was using improperly
created mailbox name for INBOX. Be more robust in handling
erroneous constructs. Thanks Sam for reporting.
2002-02-20 Jeff Bailey <jbailey@outpost.dnsalias.org>
* argp/Makefile.am: Remove inter-library dependency. Until QNX
has a recent libtool that will support this. Thanks Sam,
Sergey for reporting and finding the fix.
2002-02-20 Sam Roberts <sroberts@uniserve.com>
* frm/Makefile.am, from/Makefile.am, imap4d/Makefile.am,
messages/Makefile.am, readmsg/Makefile.am, sieve/Makefile.am: The
exe_DEPENDENCIES lines prevent the _LDADD lines being used for
dependencies, so the exes don't' get rebuilt when the libraries are
rebuilt, unless explicitly listed.
2002-02-19 Sergey Poznyakoff <gray@Mirddin.farlep.net>
Use of system getpwuid() in many places of the code
actually broke mu_getpwnam() paradigm. To fix it,
a wrapper function, mu_getpwuid(), is introduced.
It allows to use 'overloaded' getpwuid calls. In the
simplest case, it boils down to calling getpuid().
Applications, registering getpwname function by using
mu_register_getpwname() are expected to register its
getpwuid counterpart by using mu_register_getpwname().
"Virtual domains" (mutil.c:407) seem to be an exception:
there is no easy way to create appropriate getpwuid()
function. This does not break the virtual domain
functionality, however.
* mailbox/mutil.c (mu_getpwuid): new function. Allows
to use overloaded getpwuid() in the same way as
mu_getpwnam() does it for getpwnam().
(mu_register_getpwuid): Overload getpwuid function.
* include/mailutils/mutil.h: Proto for mu_getpwuid().
* lib/mu_argp.c: New options: --sql-getpwuid for setting
sql query returning passwd data for a given uid, and
--pam-service for setting the PAM service name to be
used.
* lib/mu_argp.h: Added extern for pam_service.
* MySql/MySql.c (getMpwnam): Return username along with
other data.
(getMpwuid): New function.
* MySql/MySql.h: Added extern declaration for sql_getpwuid_query.
* examples/mailutils.rc: Fixed queries.
* mail.local/main.c: register getMpwuid().
* imap4d/imap4d.c: Initialize pam_service. Register getMpwuid().
* pop3d/pop3d.c: Likewise.
* imap4d/login.c: Use pam_service instead of hardcoding PAM
service name.
* pop3d/user.c: Likewise.
* imap4d/bye.c: Use mu_getpwuid() instead of getpwuid().
* imap4d/copy.c: Likewise.
* imap4d/rename.c: Likewise.
* imap4d/select.c: Likewise.
* imap4d/status.c: Likewise.
* mailbox/mbx_default.c: Likewise.
* mailbox/message.c: Likewise.
* mailbox/smtp.c: Likewise.
* mailbox/wicket.c: Likewise.
* mailbox2/mutil.c: Likewise.
2002-02-19 Sergey Poznyakoff
* lib/mu_argp.c (mu_create_argcv): Fixed memory overrun.
2002-02-18 Sergey Poznyakoff
* acconfig.h: Define rl_completion_matches for readline < 4.2
* configure.in: Check for rl_completion_matches being present.
* guimb/guimb.h: Include <string.h>.
* mail/mailline.c: Changed declaration of ml_command_generator().
(ml_command_completion): use rl_completion_matches(). Patch
provided by John R. Daily.
2002-02-18 Jeff Bailey <jbailey@outpost.dnsalias.org>
* mail.local/Makefile.am: Fix install_exec_hook so that
DESTDIR installs work correctly.
* comsat/Makefile.am: Use libmailutils.la
2002-02-17 Sergey Poznyakoff
* imap4d/list.c: Take into account st_dev. Patch provided
by Sam Roberts.
* acconfig.h: Placeholder for dev_t.
* configure.in: AC_CHECK_TYPE(dev_t)
2002-02-17 Sergey Poznyakoff
* imap4d/list.c: Prevent possible infinite recursion (Fixes
Bug#134330).
* acconfig.h: Placeholder for ino_t.
* configure.in: AC_CHECK_TYPE(ino_t)
* comsat/comsat.c: Removed unused function.
2002-02-16 Sergey Poznyakoff
* configure.in (LTLIBOBJS hack): escape '[' and ']'
2002-02-15 Jeff Bailey <jbailey@outpost.dnsalias.org>
* configure.in: Hack to make AC_REPLACE_FUNCS refer to .lo instead
of .o
* lib/Makefile.am: Use libtool objects instead.
2002-02-14 Sergey Poznyakoff
* mail.local/main.c: Removed confusing print_help()
function.
* imap4d/authenticate.c: Fixed indentation.
2002-02-13 Jeff Bailey <jbailey@outpost.dnsalias.org>
This change permits linking on systems that don't support
interlibrary dependencies inherently like SCO Openserver.
* sieve/Makefile.am: Link in libtool-based libmailutils.
* readmsg/Makefile.am: Link in libtool-based libmailutils.
* pop3d/Makefile.am: Link in libtool-based libmailutils.
* mh/Makefile.am: Link in libtool-based libmailutils.
* messages/Makefile.am: Link in libtool-based libmailutils.
* mapi/Makefile.am: Link in libtool-based libmailutils.
* mail.local/Makefile.am: Link in libtool-based libmailutils.
* mail/Makefile.am: Link in libtool-based libmailutils.
* lib/Makefile.am: Generate libtool-based libmailutils.
* lib/.cvsignore: Add files that libtool generates
* imap4d/Makefile.am: Link in libtool-based libmailutils.
* guimb/Makefile.am: Link in libtool-based libmailutils.
* from/Makefile.am: Link in libtool-based libmailutils.
* frm/Makefile.am: Link in libtool-based libmailutils.
* argp/Makefile.am: Use libtool
* configure.in: Build libtool ARGP libraries
2002-02-11 Sergey Poznyakoff
* imap4d/auth_gss.c (auth_gssapi): Use imap4d_gss_userok() to
check if the principal is allowed to use a given mailbox.
2002-02-11 Sam Roberts
* pop3d/pop3d.c: Removed static prototype for non-existent
function.
* doc/rfc/: rfc1891.txt, rfc1892.txt, rfc1893.txt, rfc1894.txt:
Added RFCs related to delivery and message status notification.
* sieve/: sieve.c, svcb.c: better logging and error reporting
* include/mailutils/debug.h, mailbox/debug.c,
mailbox/include/debug0.h: Added level argument of mu_debug_print()
to the print callback, useful for determining the level and
forwarding to syslog, or something.
2002-02-09 Sam Roberts
* mailbox/mbx_default.c: removed unused variable
2002-02-08 Sam Roberts
* TODO: More things I think should be done, or did.
* mailbox/wicket.c: wicket: a ticket file now can contain multiple
URLs, when looking for a ticket, the first one which contains
authentication information for the incomplete url is returned.
wildcards are OK, so you can do:
# my ~/.tickets
pop://sam:pass@pop.uniserve.com
*://sroberts:gnuless@mail.certicom.com
imap://;AUTH=anon@*
Actually, the last doesn't work, but it SHOULD. Another day.
* include/mailutils/url.h, mailbox/url.c: url_is_ticket() - new
function, determines whether a url_t contains ticket information
for another url
* doc/texinfo/url.texi: missing an @var{}
* mailbox/url_mbox.c: gcc doesn't like signed chars as array
indexes, they could be negative
* sieve/sieve.c: buglet, forgot to initialize opts
2002-02-07 Sergey Poznyakoff
* imap4d/util.c (util_localname): return FQDN
* imap4d/capability.c: Forgotten to commit.
2002-02-07 Sergey Poznyakoff
* acconfig.h: Added WITH_GSSAPI define.
* configure.in: New option: --with-gssapi
* imap4d/auth_gss.c: (new) GSSAPI authentication.
* imap4d/Makefile.am: Added auth_gss.c
* imap4d/append.c (imap4d_append0): Added missing call to
stream_open().
* imap4d/authenticate.c: Basic framework for AUTHENTICATE command.
Added auth_gssapi hook.
* imap4d/capability.c: AUTH=GSSAPI if supported.
* imap4d/imap4d.c: ifile should be global as well as ofile. It
will be needed by authentication handlers.
* imap4d/imap4d.h: Added new protos.
* imap4d/util.c: Base64 encoding/decoding functions. filter_trans
can't be used for this purpose, since its encoder inserts
newlines after each 76 characters of output.
* m4/gssapi.m4: (new) Check for gssapi libraries and header files.
* m4/Makefile.am: Added gssapi.m4
* mail/mail.c (main): Fixed 'No mail for...' reporting.
* mailbox/filter_trans.c (trans_read): Control number of
bytes read by stream_read().
* mailbox/memory_stream.c (_memory_truncate): Bugfix.
* TODO: Updated.
2002-02-07 Jeff Bailey <jbailey@outpost.dnsalias.org>
* guimb/.cvsignore: Add .libs
* .cvsignore: Add stamp-h1
* sieve/Makefile.am: Add sieve.h for make dist.
* doc/texinfo/programs.texi: Put break between @end itemize and }
to quiet error from texi2dvi.
* doc/texinfo/mailer.texi: Add space to quiet error from makeinfo.
* readmsg/.cvsignore: New File
* doc/man/popauth.1: New file.
* doc/man/Makefile.am: Add popauth.1
2002-02-05 Sergey Poznyakoff
Use argp_ functions instead of getopt to parse command
line arguments. This allows all mailutils programs
to share common code and to have the same subset
of command line options. Besides, this allows to have
a single configuration file for entire package.
The common command-line subsets are (struct argp_child):
1. mu_common_argp_child: handles --maildir,--log-facility,
--license and --sql-.* family of options. (The latter
are used to supply data for SQL getpwnam et al. functions
instead of hard-coding them).
2. mu_daemon_argp_child: handles --daemon,--inetd,--port
and --timeout options.
* lib/mu_argp.c: (new) Handle command line arguments,
common for all mailutils programs.
* lib/mu_argp.h: (new) Definitions for handling common
mailutils command-line arguments.
* lib/Makefile.am: Added mu_argp.[ch]
* comsat/Makefile.am: Added @ARGP.*@ substitutions
* imap4d/Makefile.am: Likewise.
* mail.local/Makefile.am: Likewise.
* pop3d/Makefile.am: Likewise.
* comsat/comsat.c: Use argp_parse instead of getopt_long.
* imap4d/imap4d.c: Likewise.
* mail.local/main.c: Likewise.
* pop3d/pop3d.c: Likewise.
* comsat/comsat.h: Added mu_argp.h and related stuff
* imap4d/imap4d.h: Likewise.
* imap4d/util.c: Likewise.
* mail.local/mail.local.h: Likewise.
* pop3d/extra.c: Likewise.
* pop3d/pop3d.h: Likewise.
* examples/mailutils.rc: (new) Sample mailutils configuration
file.
* doc/texinfo/programs.texi: Added entry about mailutils.rc
configuration file.
* MySql/MySql.c: Use configurable queries instead
of hardcoded ones.
* MySql/MySql.h: Added new external declarations.
Removed unneeded defines.
* configure.in: Removed notice about MySql.h
2002-02-04 Sergey Poznyakoff
* mail.local/Makefile.am (mail_local_LDADD): Add @AUTHLIBS@.
* mail.local/mail.local.h: Include "../MySql/MySql.h" when
necessary.
* mail.local/main.c (main): Register virtual domain handlers.
Use mu_getpwnam.
(deliver): Set MU_LOCKER_PID bit on the locker.
2002-01-30 Sergey Poznyakoff
* mail.local/main.c (main): Return EX_USAGE on command line
usage errors.
(deliver): Return EX_TEMPFAIL if mailbox cannot be locked.
* mailbox/url_mbox.c (_url_path_index): Use character translation
table to allow for '.', etc. in the usernames.
Fixed memory overrun.
(_url_path_rev_index): Use character translation table.
2002-01-26 Sam Roberts
* mailbox/folder_imap.c:
folder_imap_create() - removed, code now in mailbox_imap_open().
imap_mailbox_name_match() - new function, uses strcasecmp() for
INBOX, since INBOX is itself in any case combination, and
fnmatch() otherwise.
imap_list() - mailbox name (an ASTRING) wasn't being unquoted.
folder_imap_list() - always failed to match it's name arg against
the mailbox name (imap_list needed to unquote the name, and the
name comparison needed to treat INBOX specially).
* mailbox/mbx_imap.c: Moved the mailbox creation functionality of
folder_imap_create() into mailbox_imap_open(). Now
mailbox_imap_open() will fail if the mailbox doesn't exist, or
can't be created despite creation being requested (like the other
types of mailbox).
* mailbox/include/imap0.h: m_imap_t - added state to keep track of
which folder function is in progress when a mailbox function calls
several folder functions.
2002-01-25 Sam Roberts
* doc/rfc/rfc2060.txt: LIST section was 6.3..8., not 6.3.8, made it
hard to search for!
2002-01-23 Sergey Poznyakoff
* mail.local/mail.local.h: Define correct EX_ values if
sysexits.h is missing.
2002-01-22 Sam Roberts
* sieve/: sieve.c, sieve.h, sv.h, svcb.c, svctx.c: Implemented
redirect action, and added option for sieve to specify the mailer.
* configure.in: Check for <sysexits.h>.
* mail.local/mail.local.h: Work around missing <sysexits.h>.
* mailbox/sendmail.c: State now tracks whether its been opened,
rather than segving.
* include/mailutils/address.h: Removed prototype for function that
isn't defined anywhere.
* mailbox/mailer.c: Return ENOENT if the url type wasn't
registered, like the other factory creation functions.
* include/mailutils/list.h, mailbox/list.c: New function:
list_do(), calls a function on each item in the list.
* mailbox/mutil.c: Needed <sys/stat.h> on QNX6.
2002-01-22 Sergey Poznyakoff
* mail.local/mail.local.h: Added network-related includes.
* mail.local/main.c: Implemented biff notification.
* mail.local/script.c: Added configurable debugging.
* guimb/main.c: Fixed help display.
* doc/texinfo/programs.texi: Updated.
2002-01-21 Sergey Poznyakoff
* acconfig.h: Added WITH_GUILE define.
* configure.in: Define WITH_GUILE. Added mail.local.
* Makefile.am: Added mail.local.
* guimb/run_scm.c: Deleted.
* guimb/Makefile.am: Removed run_scm.c
* guimb/collect.c (guimb_catch_body, guimb_catch_handler) New
functions.
* guimb/guimb.h: Added new declarations.
* guimb/main.c: New command line options: --maildir (set
mailspool pathname), --source (set scheme source file name).
Use mu_process_mailbox instead of run_main.
* guimb/scm/sieve.scm: Add "#!" magic to the beginning of
the output script. Improved diagnostics. Fixed bug in
next-token-from-port.
* libmu_scm/mu_guimb.c: (new)
* libmu_scm/Makefile.am: Added mu_guimb.c
* libmu_scm/mu_message.c (mu_message_send): Initialize mailer
to NULL.
* libmu_scm/mu_scm.h: Added proto for mu_process_mailbox.
* mail.local: Added to repository.
* mail.local/Makefile.am: Likewise.
* mail.local/.cvsignore: Likewise.
* mail.local/mail.local.h: Likewise.
* mail.local/main.c: Likewise.
* mail.local/mailquota.c: Likewise.
* mail.local/script.c: Likewise.
2002-01-21 Sergey Poznyakoff
* configure.in: New option --with-maildir allows to
specify the location of mailspool instead of the
default _PATH_MAILDIR.
* acconfig.h: Include <paths.h>. Define MU_PATH_MAILDIR.
* mailbox/mbx_default.c (mailbox_create_default):
Use MU_PATH_MAILDIR.
* guimb/collect.c (collect_output): Likewise.
* imap4d/imap4d.c: Likewise.
* pop3d/pop3d.c: Likewise.
* comsat/comsat.c: Introduced --maildir option.
* pop3d/apop.c (pop3d_apop): Use maildir instead of
_PATH_MAILDIR (should have been committed 2002-01-15).
* mailbox/parse822.c (str_append): Check for NULL.
* mailbox/message.c (message_destroy): Fixed typo in comment.
* imap4d/imap4d.h: Removed superfluous definition of
_PATH_MAILDIR.
* pop3d/pop3d.h: Likewise.
* lib/mu_dbm.c: (mu_fcheck_perm, mu_check_perm): Return
OK if mode is 0.
2002-01-19 Sam Roberts
* sieve/: svcb.c, svutil.c: sv_mu_save_to() became
mailbox/message.c:message_save_to_mailbox()
* sieve/sieve.c: Was setting debug on the mailbox before creating
it...
* include/mailutils/message.h, mailbox/message.c:
message_save_to_mailbox(): convenience function, perhaps it should
go in mailbox/mutil.c, but nothing else in there is a mailutils API
wrapper.
* include/mailutils/mailbox.h, mailbox/mailbox.c:
mailbox_has_debug(): wasn't a way to see if a mailbox had one
* mailbox/folder_mbox.c: Give mbox folders a null authentication
object, mailbox_get_authority() will now return one instead of
succeeding, but not returning an object.
* include/mailutils/folder.h, mailbox/folder.c: folder_has_debug():
there wasn't a way to see if folder had a debug object
* include/mailutils/auth.h, mailbox/auth.c:
authority_create_null(): creates an authority that successfully
does nothing, useful for concrete types that need to return an
authority, but don't do any authentication.
* mailbox/mbx_imap.c: Append to INBOX if an explicit path wasn't
supplied.
* mailbox/mbx_mbox.c: X-UID is 5 chars, not 4, and this line will
match X-UIDL too, is that intended?
* mailbox/url_mbox.c: including strings.h as well
* mailbox/debug.c: Removed a FIXME that seems to have been fixed.
2002-01-18 Sergey Poznyakoff
* mailbox/mutil.c: New function mu_tempfile().
* include/mailutils/mutil.h: Declaration for mu_tempfile().
* guimb/collect.c: Use mu_tempfile.
* mail/send.c: Likewise.
* mail/var.c: Likewise.
* mailbox/body.c: Likewise.
* mailbox/mbx_mh.c: Likewise.
* mailbox/muerror.c: New function mu_verror().
* guimb/util.c: Removed util_tempfile().
* mail/util.c: Likewise.
2002-01-15 Sam Roberts
* sieve/: sieve.c, sv.h, svcb.c, svctx.c, svutil.c,
examples/Makefile, examples/Test, examples/mbox.complex,
examples/t-complex.sv, examples/t-mailutils.sv: More testing and
resultant polishing, -k switch to sieve to keep on going after an
error sieving a message, don't discard a message unless the script
completed all the actions successfully on a message, better error
reporting and logging, workarounds around problems/differences
between mailbox types, and a test script that exercises sieve on an
mbox.
2002-01-15 Sergey Poznyakoff
* imap4d/imap4d.c: New command line option --maildir (-m).
Register mbox_record at startup.
* pop3d/pop3d.c: Likewise.
* imap4d/imap4d.h: Extern declaration for maildir.
* pop3d/pop3d.h: Likewise.
* imap4d/select.c: Use maildir instead of _PATH_MAILDIR.
* pop3d/user.c: Likewise.
* mailbox/mutil.c: (mu_normalize_maildir) New function.
Makes sure the mailbox specification either is a
pathname ending with '/', or matches regexp 'mbox:.*user='.
* include/mailutils/mutil.h: (mu_normalize_maildir) Added
prototype.
* mailbox/url_mbox.c: Handle extended URL specification.
Implemented three hash schemes.
* comsat/action.c: (expand_line): Removed unused variable.
* libmu_scm/mu_mailbox.c: Fixed indentation.
* libmu_scm/mu_address.c: (_get_address_part) Removed unused
variable.
* libmu_scm/mu_mime.c: (mu_scm_mime_print) Added missing return
value.
* pop3d/apop.c: Fixed typecasts.
2002-01-14 Sergey Poznyakoff
* argp/argp-parse.c (parser_init): Fixed erroneous typecasts.
* guimb/scm/Makefile.am: Added numaddr.scm to pkgdata_DATA.
2002-01-12 Sam Roberts
* sieve/: sieve.c, sieve.h, svcb.c, svctx.c, svfield.c, svutil.c, sv.h:
API of sieve engine now includes diagnostic callbacks, and is close
to stable, implementation will be soon.
2002-01-05 Sam Roberts
* sieve/: Makefile.am, sieve.c, sv.h, svcb.c, svctx.c, svutil.c:
Split the implementation of the mailutils-based sieve engine out of
sieve.c, which now contains only a utility that uses the engine to
sieve mailboxes.
* sieve/sieve_interface.h: exposed sieve_errstr() in public API,
and declare sieve_errname()
* sieve/script.c: lower-cased some error strings, and added
str_errname() to return the string of an error enum.
2001-12-31 Alain Magloire
* doc/texinfo/programs.texi: Describe the readmsg utility.
* configure.in: Enable readmsg.
* Makefile.in: Enable readmsg.
* readmsg/readmsg.c: Implementation.
* readmsg/msglist.c: Implement Elm weird expansion.
2001-12-29 Sergey Poznyakoff
* guimb/scm/numaddr.scm: (new) Implements "numaddr" extension
test. The test counts Internet addresses in structured headers
that contain addresses. It returns true if the total number of
addresses satisfies the requested relation, e.g.:
if numaddr :over [ "To", "Cc" ] 50 { discard; }
* guimb/scm/Makefile.am: Added numaddr.scm.
* guimb/scm/redirect.scm: Use mu-message-send instead of
sieve-message-bounce.
* guimb/scm/reject.scm: Likewise.
* guimb/scm/sieve-core.scm: Introduced sieve-daemon-email
variable. Removed sieve-message-bounce, since recent modifications
to mailer_send_message() and mu-message-send provide all the
required functionality.
* libmu_scm/mu_message.c: Optional parameters may be #f.
* pop3d/popauth.c: Reset the user privileges in case popauth is
installed setuid.
2001-12-28 Sergey Poznyakoff
* comsat/comsat.h: Added include <argcv.h>
* guimb/collect.c: (collect_create_mailbox) Removed unused auto
variable.
* guimb/guimb.h: Added missing includes and prototypes.
* lib/mu_dbm.h: Likewise.
* libmu_scm/mu_message.c: (mu_message_send) Synchronized
with recent changes to mailer_send_message().
(mu_message_get_user_flag) Removed unused variable.
* libmu_scm/mu_port.c: Removed unused variables.
* mh/inc.c: Renamed static truncate to avoid name clash
with the libc function.
* mh/mh.h: Added missing includes and prototypes.
* mh/mh_argp.c: Added missing includes.
* mh/mh_format.c: (strobj_create) Removed unused variable.
2001-12-17 Sam Roberts
* doc/texinfo/mailer.texi, include/mailutils/mailer.h,
mailbox/mailer.c, mailbox/sendmail.c, mailbox/smtp.c,
mailbox/include/mailer0.h: mailer_send_message() now takes
optional from and to addresses, so they can be specified rather
than deduced from the env or message body.
* mail/send.c: modified to compile against the changed
mailer_send_message()
* examples/: Makefile, msg-send.c: Added msg-send example of using
the mailer_t API.
* mailbox/url_sendmail.c: Now takes advantage of url_parse().
* TODO: Idea for a popen() stream_t wrapper.
* doc/texinfo/stream.texi, include/mailutils/stream.h: Forgot to
add stdio_stream_create() to the header, it opens a stream_t on an
existing FILE, and you can choose whether it fcloses() it or not.
* examples/.cvsignore: updated
2001-12-16 Alain Magloire
* mailbox/address.c: Problem between signed and unsigned comparison.
2001-12-16 Sam Roberts
* TODO: updated with some notes about the doc examples
* examples/mimetest.c, include/mailutils/message.h,
mailbox/attachment.c:
(message_get_attachment_name, message_aget_attachment_name): new
APIs, used to be private to mailbox/attachment.c.
(message_save_attachment): filename can be NULL, it defaults to
the attachment's name
* doc/texinfo/stream.texi: updated - not much text, but at least
the args are correct.
* TODO: updated
* mailbox/attachment.c: gnu indented
* examples/: mbox-dates.c, mbox-explode.c: Added -d flags.
* examples/mimetest.c: gnu indented
2001-12-16 Alain Magloire
* mailbox/body.c: Call lazy_create() _before__ file_stream_create()
to create the temporary file.
* examples/mimetest.c: An example on how to play with attachments.
The code was written by Dave Inglis.
2001-12-16 Sam Roberts
* comsat/: comsat.c
imap4d/: append.c, fetch.c
include/mailutils/: stream.h
mailbox/: attachment.c, body.c, file_stream.c, filter.c,
folder_imap.c, header.c, mapfile_stream.c, mbx_mbox.c,
mbx_mh.c, mbx_pop.c, memory_stream.c, smtp.c, stream.c, tcp.c
mailbox/include/: Makefile.am, stream0.h, tcp0.h
Modified stream creation and opening. The *_stream_create()
functions now take the specific arguments appropriate to them
and setup a stream_t so that stream_open(), which now takes
no arguments, can perform whatever actions are appropriate
when opening that particular kind of stream. I have tested the
changes with the example programs and sieve, but not with the
imap or pop servers.
2001-12-12 Sam Roberts
* lib/: argcv.c, xmalloc.c: Fixed warnings about functions called
without prototypes.
* sieve/sieve.c: First crack at including wicket_t's ticket, not
tested.
* m4/debug.m4: Added -Wall in debug mode.
2001-12-10 Sam Roberts
* comsat/.cvsignore, doc/rfc/.cvsignore, examples/.cvsignore,
mail/.cvsignore, sieve/examples/.cvsignore: Ignored.
* mailbox/tcp.c: I'm about to modify this file, so I'm GNU
indenting it so I can see reasonable diffs. No other changes.
2001-12-03 Alain Magloire
Surprisingly some OSes do not have getpass()
drop a dumb version in lib/getpass.c for missing platforms.
* configure.in: Check for getpass ();
* lib/getpass.c: New file.
* lib/Makefile.am: Updated.
2001-12-03 Sergey Poznyakoff
* configure.in: Fixed inconsistency: --with-dbm flag
was erroneously named --with-old-dbm in the help output.
* lib/mu_dbm.c: New function mu_dbm_stat(): retrieve
struct stat for a database file (or its *.pag part
for ndbm/gdbm).
* pop3d/popauth.c: Added --modify, --add, --delete
and --create options. Allow only --modify when the user
is not the owner of the database. This allows usual
users to use popauth the way they use system passwd
command, provided popauth is installed setuid.
* guimb/scm/sieve.scm: Delete temp-file after running
the script.
2001-11-26 Alain Magloire
* doc/texinfo/mailer.texi: Replace @func with @code
missing @end deftypefun
2001-11-26 Sam Roberts
* doc/texinfo/mailer.texi: Hacked up work-in-progress of the mailer
API, but worth committing before I commit all the code.
* mailbox/folder_pop.c: Added <strings.h> for QNX6.
* .cvsignore, doc/.cvsignore: ignores sorted, and added _*
* doc/texinfo/address.texi, include/mailutils/address.h,
mailbox/address.c:
address_aget_email() - like _get_email() but mallocs.
address_createv() - like address_create(), but takes an
array of strings.
* examples/: Makefile, Urls, Urls.good: Updated url_parse() test
case.
* comsat/comsat.h: Need <paths.h> and <strings.h> under QNX6.
* doc/texinfo/url.texi, mailbox/url.c: Url syntax extended. If
scheme: is not followed by a "//", then the rest of the line is
returned as the path. Also a bare scheme is now legal. So
"sendmail:" and "sendmail:/sbin/mail-inject" are now legal.
2001-11-21 Sergey Poznyakoff
* comsat/comsat.c: Provide default for _PATH_MAILDIR for
systems lacking it.
2001-11-20 Jeff Bailey <jbailey@outpost.dnsalias.org>
* configure.in: Set CPPFLAGS last. $(sysconfdir) requires
make to get it expanded, and it fubars autoconf tests.
2001-11-17 Alain Magloire
* include/mailutils/mailbox.h: Remove prototype
mailbox_destroy_folder().
* mailbox/mailbox.c (mailbox_destroy_folder): Remove.
* comsat/comsat.c (notify_user): remove mailbox_destroy_folder().
2001-11-17 Alain Magloire
* mailbox/folder_imap.c (authenticate_imap_login): Pass the
url in ticket_pop.
* mailbox/mbx_pop.c (pop_get_user): Pass the url in ticket_pop()
* mailbox/mbx_pop.c (pop_get_passwd): Pass the url in ticket_pop()
* mailbox/ticket.c (ticket_set_pop): Change the prototype.
(ticket_pop): Change the prototype.
* mailbox/wicket.c (get_pass): New function get passwd.
(get_user): New function get user.
(myticket_create): Take filenanme as argument and
save the information.
(_get_ticket): Removed.
(myticket_pop): Take an url in argument.
* mailbox/include/auth0.h: field _pop() prototype changed.
* include/mailutils/auth.h: ticket_pop and ticket_set_pop
prototype changed, add url. Include <mailutils/url.h>
2001-11-17 Alain Magloire
Move util_cpystr() in the mu_ namespace.
* include/mailutils/mutil.h: util_cpystr() to mu_cpystr().
* mailbox/address.c: util_cpystr() to mu_cpystr().
* mailbox/url.c: util_cpystr() to mu_cpystr().
* mailbox/mutil.c: util_cpystr() to mu_cpystr().
* mailbox/wicket.c: util_cpystr() to mu_cpystr().
2001-11-15 Alain Magloire
After exchange with Sam Roberts, it should be possible to
set a stream on the message and have the message_t do
the rfc822 parsing.
{
message_t mesg = NULL;
header_t header = NULL;
stream_t stream = NULL;
char buffer[512];
off_t off = 0;
size_t n = 0;
message_create (mesg, NULL);
file_stream_create (&stream, "/home/user/mh/mesg_1");
message_set_stream (mesg, stream, NULL);
stream = NULL;
message_get_header (mesg, &header);
header_get_stream (header, &stream);
while (stream_readline (stream, buffer, sizeof buffer, off, &n) == 0
&& n > 0) {
printf ("%s", buffer);
off += n;
}
message_destroy (&mesg, NULL);
}
* mailbox/message.c (message_header_fill): New
function implements a header if there was a stream set on the message.
(message_body_read): Implements the stream_read of body_t of
a message if there were a stream set.
(message_is_modified): Check if an object was set to message_t
and flag it as modified.
(message_get_body): If a stream was set on the message create a
temporary stream for the body.
(message_set_body): Set the message modified.
(message_set_header): Set the message modified.
(message_set_envelope): Set the message modified.
(message_set_attribute): Set the message modified.
* mailbox/include/message0.h: field hdr_buf removed.
* mailbox/wicket.c (wicket_destroy): return void.
* include/mailutils/auth.h: wicket_destroy ()
should return void.
* mailbox/body.c (body_is_modified): Implemented.
(body_clear_modified): Implemented.
(_body_get_size0): New function.
(_body_get_lines0): New function.
(body_get_lines): Call _body_get_lines0().
(body_get_size): Call _body_get_size0().
(body_lines): Fall back on the stream and iterate
the entire stream to find the line numbers.
(body_size): Fall back on the stream for the size.
* mailbox/folder_imap.c: Check if memory_stream_create()
succeed and bailout if not.
* mailbox/header.c (header_destroy): Free header->mstream.
(fill_blurb): Remove redundant code, header_free_cache was
doing the same. Implement the code in term of a memory
stream to hold the temporary header blurb.
(header_write): Implemented.
* mailbox/include/header0.h: Remove fields temp_blurb and
temp_blurb_len, we use mstream a memory stream and stream_len.
* mailbox/memory_stream.c (_memory_read): Cast the offset to size_t
(_memory_readline): Cast the offset to size_t.
(_memory_write): Cast the offset to size_t.
2001-11-15 Sergey Poznyakoff
* imap4d/append.c: Removed mailbox_destroy_folder kludge. It is
not needed due to yesterday's mods of mailbox/mailbox.c.
* comsat/comsat.c: Likewise.
2001-11-14 Alain Magloire
* mailbox/wicket.c (_get_ticket): Reset the buffer.
* mailbox/mailbox.c (mailbox_get_stream): Get the stream
for the mailbox object if it is null try the folder.
(mailbox_set_stream): Always set it on the mailbox object.
2001-11-14 Alain Magloire
To provide an easy way to create a ticket_t from
a file, one can create a wicket_t and fetch ticket_t's
for different users to set on the authority.
{
wicket_t (&wicket, "/home/alain/.tickets");
wicket_get_ticket (wicket, &ticket, "alain", NULL);
authority_set_ticket (wicket, ticket);
}
* include/mailutils/auth.h: Added wicket_t prototypes
functions: wicket_create(), wicket_destroy,
wicket_get_ticket(). New prototype ticket_set_data ()
ticket_get_data () ticket_set_destroy (), ticket_set_owner();
* mailbox/wicket.c: New file, implements wicket_t.
* mailbox/ticket.c: New file, implements ticket_t.
* mailbox/auth.c: Implements only authority_t.
* mailbox/Makefile.am: Update for ticket.c and wicket.c
2001-11-14 Sergey Poznyakoff
* comsat/action.c: Expand \n only for `echo'.
2001-11-13 Alain Magloire
Try to use const whenever appropriate to make it clear
that a string should not be modified. Nuke some
trailing spaces, thanks to emacs. Reduce the scope
of functions with static. GNU ident style for
switch() promote a empty line after the break;
* comsat/action.c (expand_escape): size and lncount
could have been use uninitialized.
(expand_escape): const char *cr.
(expand_line): cr == "\n\r" make it const.
variable i and size unneeded.
variable c initialize to zero.
(expand_line): obstack_1grow() pass *p instead of c.
(default_action): const char*.
(run_user_action): fprintf () missing argument.
(open_rc): const char *filename.
* comsat/comsat.c (username): const char *username.
(mailbox_path): const prototype.
(change_user): const prototype.
(notify_user): const prototype.
body and header unneeded variables.
(find_user): const prototype.
* comsat/comsat.h: Prototype updates.
2001-11-13 Sergey Poznyakoff
* lib/daemon.c: Use of errx() is a bsd-ism.
* comsat/action.c: Use maxlines instead of hardcoding the default
value. Exit if execv() fails.
* comsat/comsat.c: Missed newline in help output.
* doc/texinfo/mailutils.texi: Common index is too hard
to use. Split it into Function, Program and Concept indices.
* doc/texinfo/programs.texi: Added nodes for comsatd. Put
@pindex and page breaks wherever needed. Fixed use of @deffn.
* doc/texinfo/.cvsignore: Updated
* Makefile.am: Enabled comsat directory.
2001-11-12 Sergey Poznyakoff
* examples/comsat.conf: (new) A sample configuration file
for comsatd utility.
* examples/dot.biffrc: (new) A sample per-user biff configuration
file.
* comsat/action.c: Implemented exec. Fixed trivial bug in
expand_escape().
* comsat/cfg.c: New keyword: allow-biffrc.
* comsat/comsat.c: Likewise.
* comsat/comsat.h: extern declarations.
* lib/argcv.c: Ignore trailing whitespace and terminate output array
with a NULL entry.
* mail/mail.c: Use quotes when setting default string values.
* mail/set.c: Bugfix: possible dereference of NULL pointer (on
input: set var=<eol> ).
2001-11-12 Alain Magloire
Support in POP3 mailbox client for APOP authentication.
This should work, now:
#MAIL='pop://alain;AUTH=+APOP@localhost' ./frm
Pop passwd: secret <--- apop secret
...
* mailbox/folder_pop.c (folder_pop_get_authority):
Enable APOP code.
* mail bx/mbx_pop.c: Add md5-rsa.h.
(_pop_apop): New function to do APOP authentication.
(_pop_user): Factor some code in pop_get_user() and
pop_get_passwd() to share with _pop_apop().
(pop_get_user): New function, get the user login.
(pop_get_passwd): New function, get the user passwd.
(pop_get_md5): New function get timestamp.
* mailbox/url_pop.c: Add 2001 in Copyright.
* pop3d/apop.c: Remove trailing spaces.
* frm/frm.c: New option -d, --debug.
To put the mailbox_t in debug mode, very practical
to watch the traffic.
2001-11-11 Alain Magloire
Most daemon will share the same code to daemonize(), we use
a generic one, lib/daemon.c, so any bug fix will impact the
others and reduce maintenance/duplication.
* lib/Makefile.am: Addition daemon.c
* lib/daemon.c: New file.
* pop3d/pop3d.c (pop3d_daemon_init): Use lib/daemon.c:daemon() code
instead.
* imap4d/imap4d.c (imap4d_daemon_init): Use lib/daemon.c:daemon code
instead.
* comstat/comstat.c (comstat_daemon_init): Use lib/daemon.c:daemon code
instead. Remove trailing spaces.
2001-11-11 Sergey Poznyakoff
* comsat/action.c: (new) User-defined actions for comsat.
* comsat/Makefile.am: Added action.c to sources
* comsat/cfg.c: Removed confusing comment
* comsat/comsat.c: Call run_user_action instead of
dumping message contents to user's tty.
* comsat/comsat.h: Include mailutils headers.
2001-11-11 Alain Magloire
* lib/mu_dbm.c: Add <errno.h>.
Remove trailing spaces.
2001-11-11 Sergey Poznyakoff
* lib/mu_dbm.c: (new) These functions provide an
intermediate layer between the DBM API and mailutils'
applications.
* lib/mu_dbm.h: (new) Declarations for DBM support.
* lib/Makefile.am: Added mu_dbm.[ch]
* acconfig.h: Added DBM-related WITH- defines
* configure.in: New options: --with-gdbm, --with-ndbm,
--with-old-dbm
* pop3d/popauth.c: (new) A tool for manipulating authentication
databases.
* pop3d/Makefile.am: Added popauth.
* pop3d/.cvsignore: Likewise.
* pop3d/apop.c: Bunch of changes due to introduction of new
DBM interface.
* pop3d/pop3d.h: Likewise.
* comsat/Makefile.am: Added comsat.h to sources
2001-11-10 Jeff Bailey <jbailey@outpost.dnsalias.org>
* pop3d/pop3d.h: Use SYSCONFDIR, not hardcoded /etc
* doc/man/.cvsignore: New File
* doc/Makefile.am: Add man to SUBDIRS
* configure.in: Build doc/man/Makefile
Provide -DSYSCONFDIR in CPPFLAGS
* doc/man/pop3d.1: New File
* doc/man/imap4d.1: New File
* doc/man/Makefile.am: New File
* pop3d/pop3d.c: Change timeout to unsigned int from size_t.
Thanks to James Troup <james@nocrew.org>
2001-11-05 Alain Magloire
* mailbox/mutil.c (mu_parse_imap_date_time): This one is so
obvious that it is embarrassing. In a struct tm { }
tv_wday [0,6] Sunday == 0. Change the Array for it to
start with "Sun" instead of "Mon".
2001-11-05 Sergey Poznyakoff
* configure.in: check for vsyslog
* mailbox/muerror.c: New function mu_syslog_error_printer().
Removed static qualifier from default_error_printer, added mu_
prefix to it.
* include/mailutils/error.h: Protos for mu_.*_error_printer
functions.
* imap4d/imap4d.c: Use mu_syslog_error_printer.
* pop3d/pop3d.c: Likewise.
* comsat/comsat.c: Likewise. Also fixed misplaced condition.
2001-11-02 Alain Magloire
* mailbox/folder_imap.c: If authority is null default to
user/passwd.
* mailbox/folder_pop.c: If authority is null default to
user/passwd.
* mailbox/mbx_pop.c(pop_open): Do not try to reconnect.
2001-11-02 Sergey Poznyakoff
* comsat/comsat.c: Restart on sighup when in daemon mode.
Fight floods by increasing delays exponentially.
Fill in `hostname' on startup.
* comsat/comsat.h: include <ctype.h>.
* comsat/cfg.c: Removed include <ctype.h>.
2001-11-01 Alain Magloire
There were confusion, about the authority_t and the ticket_t.
An authority_t is an object that implements an authentication
mechanism i.e. APOP, SASL, User/Passwd. To retrieve or get
information from the client/user, authority_t will use the
ticket_t, it will call ticket_pop (). For example, on an
authority_t object that implements the user/passwd mechanism
ticket_pop () will be call two times once for the user and
the other for the passwd, by the authority_t object.
So far so good, but the problem here was we had
mailbox_{g,s}et_ticket(), folder_{g,s}et_ticket() and
mailbox_{g,s}et_authority() and folder_{g,s}_authority().
For example for a ticket , depending on when xx_set_ticket ()
was done, a ticket_t could have been set on the mailbox_t structure
or on the folder_t structure. This was leading to use the wrong one,
folder->ticket or mailbox->ticket. Same problem occurs for
authority_t. To clear this up, ticket_t can only be set on the
authority_t and authority_t can only be on a folder. Having only one
way to get at the authority or at the ticket fix the race conditions:
{
// No error checking is done.
mailbox_t mbox;
folder_t folder;
authority_t auth;
ticket_t ticket; ..
..
// Setting the ticket
mailbox_create (&mbox, where);
mailbox_get_folder (mbox, &folder);
folder_get_authority (folder, &auth)
authority_set_ticket (auth, ticket);
....
}
* include/mailutils/mailbox.h: Remove mailbox_{g,s}et_ticket().
mailbox_{gs}et_authority ().
* include/mailutils/folder.h: Remove folder_{gs}et_authority().
* mailbox/mailbox.c (mailbox_get_folder): New function.
(mailbox_get_ticket): Removed.
(mailbox_set_ticket): Removed.
(mailbox_set_authority): Removed.
(mailbox_get_authority): Removed.
* mailbox/folder.c (folder_get_ticket): Removed.
(folder_set_ticket): Removed.
(folder_destroy): Removed destruction of ticket.
* mailbox/folder_imap.c (folder_imap_get_authority): New function.
(_folder_imap_init): Create authority.
* mailbox/folder_pop.c (folder_pop_get_authority): New function.
(folder_pop_open): New function.
(folder_pop_close): New function.
(_folder_pop_init): Create authority.
* mailbox/mbx_imap.c (_mailbox_imap_init): Remove the creation
of authority here, moved to _folder_imap_init().
* mailbox/mbx_pop.c (_mailbox_pop_init): Remove the creation
of authority here, moved to _folder_imap_init().
* messages/messages.c (messages_count): Argument should
be const.
2001-11-01 Sergey Poznyakoff
* configure.in: Added check for utmp.h & utmpx.h
* mailbox/mutil.c: New function: mu_normalize_path() moved
from imap4d/util.c
* include/mailutils/mutil.h: Added declaration for
mu_normalize_path().
* imap4d/imap4d.h: Removed declaration of util_normalize_path().
* imap4d/login.c: Use LOG_FACILITY instead of LOG_MAIL.
Use mu_normalize_path().
* imap4d/namespace.c: Use mu_normalize_path().
* imap4d/util.c: Removed declaration of util_normalize_path().
* mailbox/mailbox.c: mailbox_get_stream(): Fixed funny bug,
(introduced Dec 4, 2000).
* mailbox/mbx_imap.c: Use ENOSYS instead of ENOTSUP.
* comsat/: New directory. An implementation of comsat daemon.
* comsat/Makefile.am: (new)
* comsat/.cvsignore: (new)
* comsat/comsat.c: (new) Main module
* comsat/cfg.c: (new) Configuration and ACL routines.
* comsat/comsat.h: (new) Declarations for comsat.
2001-11-01 00:15 sroberts
* TODO: Added suggestion for a mailcap based file viewer.
2001-10-31 Alain Magloire
* messages/message.c (messages_count): getenv ("MAIL") may return NULL.
In this case we were trying to printf (" ..%s\n", NULL); GNU/Linux
seems to cope with it but QNX/Neutrino sigsegv miserably. Fix the code
by getting the url of the mailbox and calling url_to_string().
* mailbox/mbx_default.c: If the argument is NULL __or__ an empty
string check MAIL and FOLDER environment.
* imap4d/namespace.c: Put namespace_enumerate() and namespace_enumerate()
static scope.
* mail/msgset.y: search "mail.h" in the current dir.
2001-10-31 Alain Magloire
* mailbox/mbx_imap.c (delete_to_string): Try to turn a sequence
of number to IMAP msgset. Call add_number for the work.
(add_number): New function to add number to string for
IMAP msgset.
2001-10-30 Alain Magloire
* mailbox/body.c: Remove unneeded prototype.
* mailbox/mbx_imap.c (mailbox_imap_close): Clear the callback
string structure.
(imap_scan0): Clear the callback string structure.
(imap_append_message): Remove unused variable.
2001-10-30 Sam Roberts
* mailbox/: folder_imap.c, mbx_imap.c, include/imap0.h: Implemented
AUTH=ANON, the anonymous SASL mechanism.
* TODO: Updated AUTH=ANON todo, and added some wish-list utilities.
* doc/rfc/: rfc2195.txt, rfc2222.txt, rfc2444.txt, rfc2595.txt,
rfc2808.txt, rfc2831.txt, sasl-mechanisms: added SASL rfcs and
registry
* examples/.cvsignore: mbox-check
* examples/: Makefile, mbox-check.c: Added new example,
mbox-check.c
2001-10-30 Alain Magloire
* acconfig.h: #define ssize_t.
* configure.in: Add AC_CHECK_TYPE(ssize_t, int);
2001-10-26 Sergey Poznyakoff
Fixed behavior in send mode when the stdin is not a terminal
(i.e. when used as mail addr@dom.ain < message): do not ask
for cc, bcc, and do not echo the contents of the message
(when compiled with readline).
* mail/mail.c: Use ml_readline(). Check for `!interactive' and
force appropriate settings _after_ sourcing mail.rc files.
Force `set quiet' if in non-interactive mode.
* mail/mail.h: Declaration for ml_readline().
* mail/mailline.c: New functions ml_readline_internal(),
ml_readline().
* mail/send.c: Use ml_readline().
* mail/source.c: Do not complain if the file does not exist.
2001-10-24 Alain Magloire
* configure.in: Check for getdelim().
* lib/getline.c: change the return values from int to ssize_t
to follow GNU LibC.
2001-10-23 Alain Magloire
The message_t object makes no guaranty about the size and the lines
that it returns, if it is pointing to non-local file messages,
i.e POP3, IMAP4, the entire message may not have been downloaded yet.
IMAP is very susceptible on the size, example:
A003 APPEND saved-messages (\Seen) {310}
Date: Mon, 7 Feb 1994 21:52:25 -0800 (PST)
From: Fred Foobar <foobar@Blurdybloop.COM>
Subject: afternoon meeting
To: mooch@owatagu.siam.edu
Message-Id: <B27397-0100000@Blurdybloop.COM>
MIME-Version: 1.0
......
(1) If the IMAP4 server does not get the right size advertise in the
string literal, it will misbehave.
(2) Since we are assuming that the message will be in (unix)native
file system format meaning ending with NEWLINE, we will have
to do some calculations about the RFC822.SIZE of the message.
(3) As pointed above, it is not possible to rely on message_size()
nor message_lines() to return the right count and even missing by
one can be deadly.
So we download the message to a floating message to guaranty that
we know the exact size when transmitting it back the IMAP server,
this is the only sane thing to do IMHO. We could always
be smart; check if the message is local (i.e from the local file
system: mbox, mh, etc ..) and was not modified. If those two
requirements are true we can assume that the sizes/lines are right.
But for now do it simple, and create a temporary file/message_t.
* mailbox/mbx_imap.c (imap_append_message): If the message
is from the same IMAP server optimize by doing COPY. If not
call imap_append_message0() save the original message to a
floating message i.e. file, and use that floating message for
the append. Temporary message is destroyed when finish.
The drawback is this function is no long nonblocking safe.
2001-10-23 Alain Magloire
* mailbox/body.c: body_lines () nd body_size () were not
properly overridden given the wrong size and line number, fixed.
* mailbox/mbx_imap.c (mailbox_imap_close): Not to send another SELECT
but rather just close the mailbox if not selected.
(imap_scan0): If there is no messages in the mailbox no need to
send the FETCH 1:*.
* mailbox/message.c (message_is_modified): Protect against null
pointer.
* mailbox/mutil.c: Add <errno.h> if we use errno directly.
(mu_get_user_email): size not used, nuked.
* TODO: Some stuff todo 8).
2001-10-23 Sergey Poznyakoff
* mailbox/mutil.c: New function mu_get_user_email.
* include/mailutils/mutil.h: Prototype for mu_get_user_email.
* mail/alt.c: Determine full user email address (mail_set_my_name).
* libmu_scm/mu_address.c: New function mu-username->email, deduces
user's email from his username.
* libmu_scm/mu_message.c: New function mu-message-destroy.
mu_scm_message_free(): Destroy the underlying message if its owner
is NULL.
* guimb/scm/sieve-core.scm: Use mu-username->email to initialize
sieve-my-email.
* guimb/scm/redirect.scm: Use close-pipe instead of close-output-port.
Use mu-message-destroy.
* guimb/scm/reject.scm: Delete message after sending reject
notification.
MH: Implemented user profiles.
* mh/mh.h: New prototypes.
* mh/mh_argp.c: Honor `progname:' entries in the user's profile.
* mh/mh_init.c: Read user's profile. Use values from there instead
of hardcoded ones.
* mh/inc.c: Do not call mh_init() explicitly.
* mh/scan.c: Likewise.
2001-10-22 Jeff Bailey <jbailey@outpost.dnsalias.org>
* doc/texinfo/Makefile.am: Remove version.texi, it's implied.
* libmu_scm/Makefile.am: Clean @GUILE_PROCEDURES_TXT@
* guimb/Makefile.am: Clean @GUILE_PROCEDURES_TXT@
2001-10-21 Sergey Poznyakoff
Changes for compatibility with automake 1.5:
* guimb/Makefile.am: Restored -I.
* mh/Makefile.am: Renamed ALL_LDADD to mh_LIBS.
2001-10-20 Alain Magloire
* configure.in: Set to 0.0.9c.
* doc/texinfo/mbox.texi: Updated the docs for mbox(Unix).
* doc/texinfo/pop.texi: Updated the docs for pop3.
* imap4d/expunge.c: Bug: Expunge was not sending the
untag "* %d EXPUNGED" for message deleted. Call imap4d_sync ()
v which will do the right thing.
* imap4d/noop.c: Bug: It should call imap4d_sync () to notify
the client of any changes.
* imap4d/sync.c (notify_deleted): Typo should be EXPUNGED
with a D.
(imap4d_sync): Bug: Checked also if the number of messages changed.
* mailbox/folder_imap.c (imap_flags): Bug: Rewrite it to be generic
and sets the flags for the attribute.
(imap_fetch_flags): Call imap_flags().
(imap_permanentflags): Call imap_flags().
* mailbox2/include/mailutils/mbox.h: Update prototypes.
* mailbox2/include/mailutils/sys/mbox.h: Update prototypes.
* mailbox2/include/mailutils/pop3.h: Update prototypes.
* mailbox2/mbox/mbox_expunge.c (mbox_expunge): Calls mbox_expunge0 ().
(mbox_save): Calls mbox_expunge0().
* mailbox2/mbox/mbox_scan.c (mbox_scan): Calls mbox_scan0 ().
(mbox_count): Calls mbox_scan0().
* mailbox2/pop3/pop3_capa.c: Provide a special iterator.
* mailbox2/pop3/pop3_lista.c: Provide a special iterator.
* mailbox2/pop3/pop3_uidla.c: Provide a special iterator.
2001-10-19 Sergey Poznyakoff
MH inc is fully functional:
* mh/inc.c: Implemented -audit.
* mh/mh_init.c: New functions mh_audit_open(), mh_audit_close().
* mh/mh.h: Protos for new functions.
* mh/mh_format.c: Minor bugfix in builtin_mbox().
* guimb/Makefile.am: Removed superfluous -I.
2001-10-19 Sergey Poznyakoff
Implemented saving of MH context.
* mh/inc.c: Fixed truncate option. Implemented -changecur. The only
feature inc lacks so far is -audit.
* mh/mh_format.c: Minor fix in builtin_match().
* mh/mh_getopt.c: Fixed option recognition heuristics.
* mh/mh_init.c: New globals: ctx_name -- keeps full context file
name, ctx_header -- keeps current context (as a MU header).
mh_init(): Use new globals.
New functions: mh_save_context, mh_write_context_file, mh_check_folder,
mh_getyn.
* mh/mh.h: Prototypes for new functions.
2001-10-17 Sam Roberts
* README-alpha : Update cvs repository path.
2001-10-17 Sergey Poznyakoff
After discussion with Jeff, removed maintainer-mode quirks
and introduced --enable-debug switch.
* configure.in: Use MU_DEBUG_MODE.
* m4/maintainer.m4: removed.
* m4/debug.m4: (new) Handle --enable-debug option. When
the option is specified, adds -ggdb to the invocation of
gcc, and removes any optimization directives from CFLAGS.
* m4/Makefile.am: Removed maintainer.m4, added debug.m4
and regex.m4 (committed earlier, but apparently forgotten
to add).
* guimb/Makefile.am: Removed MAINTAINER_MODE conditionals.
* libmu_scm/Makefile.am: Likewise.
* mail/Makefile.am: Likewise.
* imap4d/imap4d.h: Added proto for strtok_r.
* .cvsignore: Updated (config.sub, ltconfig, etc.)
2001-10-16 Alain Magloire
According to rfc2060 the minimum timeout is 30 minutes. But
it is not unusual to see server with a shorter timeout. When
the timeout occurs, the server sends a BYE. To catch this
all functions in folder_imap.c and mbx_imap.c use a prologue
folder_open() or imap_messages_count to check if the server
timed out and reconnect. This is not bullet proof since the
"* BYE" will be act upon on the second request, the first
is where we catch "* BYE". On mailbox2 this behaviour will
be disable/enable with a property and make more reliable,
so client set the property "AUTORECONNECT".
* mailbox/folder_imap.c: Prologue to must functions calling
folder_open().
* mailbox/mbx_imap.c: Prologue to must functions calling
folder_open() or imap_messages_count.
(section_name): Buglet passed the wrong argument to sizeof().
For debugging purposes, to see the traffic
* mailbox/folder_imap.c:
Print to stderr the command sent to the IMAP server.
#define DEBUG_SHOW_COMMAND 1
Print to stderr the responses received from the IMAP server.
#define DEBUG_SHOW_RESPONSE 1
Print to stderr the literal/quoted string received from the IMAP
server. #define DEBUG_SHOW_DATA 1
2001-10-16 Sergey Poznyakoff
* doc/texinfo/mailutils.texi: Eliminated overfull \hboxes in printed
output.
* doc/texinfo/programs.texi: Likewise. Use @ref instead of @xref
wherever appropriate.
2001-10-15 Alain Magloire
* mailbox/sendmail.c: Use vfork() instead of fork(). In a
multithreaded environment, fork () may not be supported.
Since we do fork()/exec(), vfork() will do fine.
This was trigger by QNX/Neutrino, where fork()ing is not
supported after threads have been created.
2001-10-15 Sam Roberts
* doc/texinfo/programs.texi: Typo and semantics corrections.
2001-10-15 Alain Magloire
* mailbox/mbx_imap.c (imap_message_readline imap_body_readline):
Bad analysis on my part. Functions removed.
* configure.in: Bump to 0.0.9b
* TODO: Put a note apropos mailbox2.
2001-10-14 Alain Magloire
* mailbox/mbx_imap.c(imap_message_readline imap_body_readline):
The buffer was not null terminated if no newline was found.
2001-10-14 Alain Magloire
The code for IMAP, is a pain, the rewrite should clean all those
hacks. Something to remember for the mailbox2 is to do some
smart caching, the current buffered stream is not good enough.
* configure.in: VERSION is set to 0.0.9a for the alpha.
* frm/frm.c: Prototype for usage(). get_personal() should use
const char *.
* mail/mail.c (main): Use mailbox_scan() instead of
mailbox_messages_count () it is faster for IMAP.
* mailbox/mbx_imap.c(imap_get_message0): Remove the
stream_setbufsiz() it is no longer used.
(imap_message_readline imap_body_readline):
Bug fix, readline will only consume up to '\n' even though the
buffer is bigger. So we have to adjust the offset/lines/size
to reflect what we consume. This is not very good for example
doing:
{
off_t offset = 14;
char buffer[512];
stream_readline (stream, buffer, sizeof buffer, offset, NULL);
...
}
Will send to the impap server.
C: g445 FETCH 4 BODY.PEEK[2]<0.2048>
S: * 4 FETCH (BODY[2]<0> {739}
S: g445 OK FETCH completed
This is waste since the first line is only 37 bytes. We will
have to come up on the second API with some smart caching.
* mailbox/memory_stream.c (_memory_write): Nasty bug
was not updating the stream size.
* mailbox/stream.c(stream_readline): Take care of known
case where the buflen is 0 or 1.
2001-10-14 Alain Magloire
The code for property.c has been changed for a more simple approach,
it is the same approach as mail/util.c(environment) settings.
The old code was simply overkill, property_t was seldom used,
if at all, no need for heavy hash table and all that jazz.
* mailbox/property.c: New code, the same as mail/util.c environment.
* mailbox/mbx_mbox.c (_mbx_init): Remove property_add_defaults() etc ..
no longer in use in the initialization code.
* mailbox/mbx_imap.c: Likewise
* mailbox/mbx_pop.c: Likewise
* mailbox/mbx_mh.c: Likewise
* mailbox/header.c: Removed property code.
* mailbox/body.c: Removed property code.
* mailbox/message.c: Removed property code.
* mailbox/filter.c: Changed the code according to the new property_t.
* mailbox/filter_rfc822.c: Changed the code according to the new
property_t structure.
* include/mailutils/header.h: Removed property.
* include/mailutils/body.h: Removed property.
* include/mailutils/message.h: Removed property.
* include/mailutils/property.h: Removed property_add_defaults()
property_set_valued () takes one more argument for overwrite.
* mailbox/include/header0.hy: Removed property field.
* mailbox/include/body0.hy: Removed property field.
* mailbox/include/message0.hy: Removed property field.
* mailbox/mailbox.c(mailbox_get_property mailbox_set_property):
Changed Property code.
* mailbox/mailer.c(mailer_set_property mailer_get_property):
Changed Property code.
* mailbox/folder_imap.c (imap_search imap_expunge imap_status): Stubs
SEARCH is not implemented yet, STATUS neither and EXPUNGE is not used.
* mailbox/list.c: Renamed variable index to indx to shutup
gcc that was confused with index() when warning level was high.
* mailbox/md5-rsa.c: Likewise.
* mailbox/mailbox.c (mailbox_get_debug mailbox_set_debug):
The debug object was being set on the folder not the mailbox.
* mailbox/mbx_imap.c (imap_messages_count): Attempt to reconnect
if the connection timeout. Is this wise?
(imap_scan0): Moved gut of imap_scan() code here.
(imap_scan): Stub calling imap_scan0() with notification enable.
(imap_expunge): After CLOSE, call imap_scan0() with notification
disable.
Memory leak in parse822, this was a real pain to trace, because
of the recursive nature of the algorithm. Sam should buy me
a beer for this.
* mailbox/parse822.c: Used more assert to catch errors.
(parse822_group): phrase was not free() in case of failure.
(parse822_mail_box): Dead "else if" branch removed and free phrase.
(parse822_route): accumulator was not being freed.
(parse822_local_part): Moved down st_free(more).
(parse822_domain): Moved down st_free(more).
2001-10-14 Sergey Poznyakoff
Small fixes:
* frm/frm.c: Do not output extra newline when running with
--field option.
* mail/reply.c: Do not prefix subject line with Re: if it
already starts with it
* mail/send.c: Handle ~x escape properly.
* mail/table.c: Removed entry for ~x: it is handled by send.c
* mail/var.c: Delimit addresses with space (~t, ~c and ~b escapes).
Removed var_exit().
* guimb/main.c: Fixed typo in --help output.
* guimb/scm/README: (new).
Reorganized /doc. Added some documentation (primarily, program.texi)
* configure.in: Added doc/*/Makefile
* doc/*.texi, doc/*.rfc: removed.
* doc/Makefile.am: Reorganized doc structure
* doc/.cvsignore: Likewise.
* doc/texinfo: New directory
* doc/texinfo/Makefile.am: (new)
* doc/texinfo/.cvsignore: (new)
* doc/texinfo/.ispell_english: (new) User dictionary for spell-checking
docs.
* doc/texinfo/address.texi: Moved from ..
* doc/texinfo/attribute.texi: Likewise.
* doc/texinfo/auth.texi: Likewise.
* doc/texinfo/body.texi: Likewise.
* doc/texinfo/c-api.texi: Likewise.
* doc/texinfo/encoding.texi: Likewise.
* doc/texinfo/envelope.texi: Likewise.
* doc/texinfo/ex-address.texi: Likewise.
* doc/texinfo/ex-url.texi: Likewise.
* doc/texinfo/folder.texi: Likewise.
* doc/texinfo/framework.texi: Likewise.
* doc/texinfo/headers.texi: Likewise.
* doc/texinfo/imap4.texi: Likewise.
* doc/texinfo/iterator.texi: Likewise.
* doc/texinfo/locker.texi: Likewise.
* doc/texinfo/mailbox.texi: Likewise.
* doc/texinfo/maildir.texi: Likewise.
* doc/texinfo/mailer.texi: Likewise.
* doc/texinfo/mailutils.texi: Likewise.
* doc/texinfo/mbox.texi: Likewise.
* doc/texinfo/message.texi: Likewise.
* doc/texinfo/mh.texi: Likewise.
* doc/texinfo/mime.texi: Likewise.
* doc/texinfo/nntp.texi: Likewise.
* doc/texinfo/parse822.texi: Likewise.
* doc/texinfo/pop3.texi: Likewise.
* doc/texinfo/programs.texi: Likewise.
* doc/texinfo/sendmail.texi: Likewise.
* doc/texinfo/sfrom.c.texi: Likewise.
* doc/texinfo/smtp.texi: Likewise.
* doc/texinfo/stream.texi: Likewise.
* doc/texinfo/url.texi: Likewise.
* doc/texinfo/version.texi: Likewise.
* doc/rfc: New directory
* doc/rfc/Makefile.am: (new)
* doc/rfc/.cvsignore: (new)
* doc/rfc/rfc1731.txt: Moved from ..
* doc/rfc/rfc1734.txt: Likewise.
* doc/rfc/rfc1738.txt: Likewise.
* doc/rfc/rfc1939.txt: Likewise.
* doc/rfc/rfc1957.txt: Likewise.
* doc/rfc/rfc2045.txt: Likewise.
* doc/rfc/rfc2046.txt: Likewise.
* doc/rfc/rfc2047.txt: Likewise.
* doc/rfc/rfc2049.txt: Likewise.
* doc/rfc/rfc2060-errata: Likewise.
* doc/rfc/rfc2060.txt: Likewise.
* doc/rfc/rfc2088.txt: Likewise.
* doc/rfc/rfc2111.txt: Likewise.
* doc/rfc/rfc2192.txt: Likewise.
* doc/rfc/rfc2193.txt: Likewise.
* doc/rfc/rfc2221.txt: Likewise.
* doc/rfc/rfc2245.txt: Likewise.
* doc/rfc/rfc2298.txt: Likewise.
* doc/rfc/rfc2342.txt: Likewise.
* doc/rfc/rfc2368.txt: Likewise.
* doc/rfc/rfc2384.txt: Likewise.
* doc/rfc/rfc2449.txt: Likewise.
* doc/rfc/rfc2821.txt: Likewise.
* doc/rfc/rfc2822.txt: Likewise.
* doc/rfc/rfc3028.txt: Likewise.
* doc/rfc/rfc821.txt: Likewise.
* doc/rfc/rfc822.txt: Likewise.
2001-10-13 Alain Magloire
* mail/mail.c: Possibility to enable debugging output.
It should probably be a runtime option via set debug=1 or something
for now it is disable between if (0) {...}.
More cleanup in the IMAP code. A memory stream buffer is
use to save the string literal sent by the IMAP server.
The allocation is handle by the memory_stream which simplifies
the code.
* folder_imap.c (folder_imap.c): Create a memory stream to
hold the literal or quoted string send by the IMAP server.
(folder_imap_list folder_imap_lsub): There is no callback
field the struct folder_list is in struct _f_imap now.
(imap_literal_string imap_quoted_string imap_string): Use the
memory string stream to save the result.
(imap_body): Still need to be clean, but creates the cache
header when doing the scan.
(imap_parse): Do not use alloca().
2001-10-13 Jeff Bailey
* guimb/Makefile.am: Remove GNU Makeism.
* libmu_scm/Makefile.am: Remove GNU Makeism.
2001-10-12 Jeff Bailey
* libmu_scm/Makefile.am: Fixes for RO srcdir.
* guimb/Makefile.am: Fixes for RO srcdir.
2001-10-11 Alain Magloire
A small cleanup of the IMAP code.
* mailbox/folder_imap.c (imap_body): Destroy the cache header
if it was previously set on a SCAN.
* mailbox/mbx_imap.c (delete_to_string): New function, to generate
a string of IMAP message numbers.
(imap_expunge): use delete_to_string;
(attribute_string): Removed.
(flags_string): Removed.
(flags_to_string): Replace attribute_string() and flags_string().
(message_operation): Rename to fetch_operation.
* mailbox/include/imap0.h(struct _f_imap): field func and id
removed, never used.
2001-10-11 Alain Magloire
* mailbox/folder_imap.c (imap_quoted_string): Free the buffer.
(imap_string): Free the buffer.
(imap_body): Check if we already have the fheader header.
(imap_scan): Forgot the break in the switch.
2001-10-11 Alain Magloire
In order to boost performance, when doing the scan, we use
the approach of downloading a subset of the header from all
of messages. The way it was done before was that the headers
were requested one by one per message. This was causing performance
issues because we were doing a lot of small transactions on
the TCP/IP stack. By bundling the entire thing in one request
"a0000 FETCH 1:* (FLAGS RFC822.SIZE BODY.PEEK[HEADER.FIELDS(..)])\r\n"
there were less transactions and the speed was increase
by a factor of 100+.
The Imap code folder_imap.c and mbx_imap.c is now messy.
The rewrite in mailbox2 should clean this up though.
* mailbox/folder_imap.c (imap_quoted_string): Allocated the
memory instead.
(imap_body): If we were doing the scan free the memory and create
the cache header.
(imap_fetch): Create the message if was not done, important for
the scan.
* mailbox/mbx_imap.c (imap_scan): Bundle one big request to
fetch as much information as possible.
(message_operation): Free the buffer when done.
* mailbox/include/imap0.h: Add IMAP_SCAN states.
* mailbox/file_stream.c (_file_readline): It seems that fgets() can
not handle binary data. Try to do our best.
2001-10-11 Alain Magloire
* mailbox/header.c (header_get_fvalue): When it fails set the number
of byte written to 0.
(header_get_value): Likewise.
* mailbox/mbx_imap.c (imap_envelope_sender): Go through
header_get_value() to fetch the "Sender" field, it may be cache.
(imap_header_get_fvalue): Put parentheses around the FETCH, the
WU-IMAPD likes it that way.
2001-10-10 Alain Magloire
* mailbox/mbx_pop.c (_mbox_pop_init): Authority is set on the folder.
For pop this a little hackish, since there is no proper folder.
As a hack we set for the pop folder the actual mailbox as data pointer.
(pop_user): the owner of the authority is the folder.
2001-10-08 Alain Magloire
* mailbox/mbx_mbox.c (mbox_expunge0): New function.
Move all the previous mbox_expunge() to mbox_expunge0()
with a new argument deciding whether or not to remove
messages set deleted.
(mbox_save_attributes): Stub calling mbox_expunge0().
(mbox_expunge): Stub calling mbox_expunge0()
* mailbox/mbx_mh.c: Provide a prototype for mh_message_number()
there is no provision for it in the current Mailbox API.
* mailbox/mbx_imap.c (imap_message_lines): If the message_size
is not set fallback on body_lines and header_lines.
* mail/print.c: Lines number are not always known for
example for POP or IMAP, it is not known until the mail
is downloaded so take a guess base on the size.
2001-10-08 Sergey Poznyakoff
* mail/z.c: Bugfix: Did not display the last message when the
number of lines in last page was less than pagelines.
* mailbox/mbx_pop.c: Use ENOSYS instead of ENOTSUP.
* mh/mh_format.c: Fixed memory leak in strobj_free().
2001-10-05 Alain Magloire
* mailbox/folder_imap.c (imap_flags): Bailout at the matching
LPAREN.
* mailbox/header.c (header_get_fvalue): Return 0 as the
number of byte returned by the last argument, even when no header
field matched.
(header_get_value): Likewise.
* mailbox/mbx_imap.c (imap_header_get_fvalue): Also cache
the message size and the FLAGS.
(imap_message_size): If we already have the size do not request
it again.
2001-10-05 Sergey Poznyakoff
* guimb/scm/Makefile.am: Added reject.scm.
* mailbox/parse822.c: (parse822_word): Additional check
for qstr != NULL: parse822_quoted_string() sometimes returns
EOK and does not fill qstr (e.g. when parsing empty string: "")
2001-10-04 Alain Magloire
* imap4d/select.c(imap4_select_status): According to RFC2060
There is no parenthesis when we send the UIDVALIDITY/UNSEEN.
* mailbox/header.c (header_free_cache): New function.
(fill_blurb): Call header_free_cache to release memory.
(header_destroy): Move the code to header_free_cache().
(header_set_fvalue): Accept a NULL value, it will permanent
failure i.e. the header does not exist.
(header_get_value): Check the cache provided by the header object
then the cache from _get_fvalue() and fall back to downloading
the entire header.
* mailbox/mbx_imap.c (imap_header_get_fvalue): Implement a cache
in IMAP for the most use headers like "FROM, SUBJECT ....".
* mailbox/include/imap0.h: New field in _m_imap to hold the
header cache.
* mailbox/mapfile_stream.c: signed and unsigned cast.
2001-10-03 Alain Magloire
* mailbox/mbx_imap.c (imap_attr_set_flags): Do not send
the \\Delete flag and just keep it locally. The expunge
will take care of resending it.
(imap_attr_unset_flags): Likewise.
2001-10-03 Sergey Poznyakoff
* mailbox/attribute.c: Fixed funny bug in
attribute_{set,clear}_modified.
2001-10-01 Alain Magloire
* mailbox2/attribute.c: Add user flags.
* mailbox2/dattribute.c: Add user flags.
To be compatible with the old mailbox, all stream read
and write take an offset. Removed stream_seek () and add
stream_is_seekable() instead.
* mailbox2/stream.c: Likewise.
* mailbox2/bstream.c: Likewise.
* mailbox2/fdstream.c: Likewise.
* mailbox2/fstream.c: Likewise.
* mailbox2/mapstream.c: Likewise.
* mailbox2/memstream.c: Likewise.
* mailbox2/tcpstream.c: Likewise.
* mailbox2/include/mailutils/error.h: Add EBADFD.
* mailbox2/include/mailutils/mbox.h: New prototypes.
* mailbox2/include/mailutils/sys/mbox.h: New prototypes.
* mailbox2/mbox/*.c: Finish implementation.
2001-09-26 Alain Magloire
* mailbox2/mbox/mbox_append.c: Implemented, first draft.
2001-09-23 Alain Magloire
First draft of the mailbox/mbox2. Not functional.
Changes are too numerous to enumerate.
* mailbox2/mbox/*.[ch]: First mbox implementation.
* mailbox2/mbox/Makefile.am: New file.
2001-09-22 Alain Magloire
In order to provide inheritance, it is necessary to make
the base functions/methods visible so the extended object
could reuse some base methods if necessary. Inheritance
is possible because we always add to the end of the vtable
structure new functions.
For example, mime_t object will be also a message_t.
and it will be possible to do
{
mime_t mime;
header_t header;
...
message_get_header ((message_t)mime, header);
}
Another example is tcpstream(socket stream) extends
fdstream(file descriptor stream);
Also the name of the functions have change to match there purpose.
* mailbox2/Makefile.am: lockfile.c added.
* mailbox2/bstream.c: Reorganization to make the
functions visible.
* mailbox2/dattribute.c: Likewise.
* mailbox2/dotlock.c: Likewise.
* mailbox2/fdstream.c: Likewise.
* mailbox2/fstream.c: Likewise.
* mailbox2/mapstream.c: Likewise.
* mailbox2/memstream.c: Likewise.
* mailbox2/pticket.c: Likewise.
* mailbox2/sdebug.c: Likewise.
* mailbox2/tcpstream.c: Likewise.
* mailbox2/include/mailutils/Makefile.am: lockfile.h added.
* mailbox2/include/mailutils/attribute.h: Add the new prototypes.
* mailbox2/include/mailutils/mbox.h: Add the new prototypes.
* mailbox2/include/mailutils/stream.h: Add the new prototypes.
* mailbox2/include/mailutils/sys/Makefile.am: dattribute.h lockfile.h
mapstream.h pticket.h added.
* mailbox2/include/mailutils/sys/bstream.h: Add new prototypes.
* mailbox2/include/mailutils/sys/fdstream.h: Likewise.
* mailbox2/include/mailutils/sys/fstream.h: Likewise.
* mailbox2/include/mailutils/sys/mbox.h: Likewise.
* mailbox2/include/mailutils/sys/memstream.h: Likewise.
* mailbox2/include/mailutils/sys/sdebug.h: Likewise.
* mailbox2/include/mailutils/sys/tcpstream.h: Likewise.
2001-09-20 Sergey Poznyakoff
* frm/frm.c: Print newline not depending on the presence
of Subject header.
* mh/mh_fmtgram.y: Builtin functions return their values
in arg_num,arg_str. reg_num,reg_str gets set only when reducing
to pitems.
Fixed if-blocks to save the result of the last evaluated conditional
to reg_num.
* mh/mh_format.c: Builtin functions return their values
in arg_num,arg_str.
Compress whitespace only in component escapes.
* mh/mh_init.c: mh_read_formfile(): Handle end-of-line comments
and '\' line continuation.
2001-09-19 Alain Magloire
* mailbox2/debug.c: Remove mu_debug_printv() and only keep
mu_debug_print().
* mailbox2/sdebug.c (mu_debug_stream_create): New function
replace mu_debug_stdio_create().
* mailbox2/fdstream.c (_fds_destroy): Do not close the stream
when destroying, it should have been done explicitly with
stream_close ();
* mailbox2/fstream.c (_fs_destroy): Do not close the stream
when destroying, it should have been done explicitly with
stream_close ();
* mailbox2/mapstream.c (_map_destroy): Do not close the stream
when destroying, it should have been done explicitly with
stream_close ();
* mailbox2/memstream.c (_memory_destroy): Do not close the stream
when destroying, it should have been done explicitly with
stream_close ();
* mailbox2/tcpstream.c (_tcp_destroy): Do not close the stream
when destroying, it should have been done explicitly with
stream_close ();
2001-09-18 Sam Roberts
* mailbox/mbx_pop.c: Check url authentication type at
initialization to trap invalid ones early.
* mailbox/: mbx_mbox.c, mbx_mh.c: The pthread headers seem to
define things that make the system headers not prototype some
non-POSIX but essential APIS, so I moved them (on QNX6).
* mailbox/url.c: Set zero-length strings to NULL.
* mailbox/: url_imap.c, url_pop.c: Check harder for URLs that are
not invalid for the particular scheme.
* mailbox/auth.c: authority_authenticate() was returning success if
authority was NULL, this is an error for all the other authority_*
APIs, now it is here, as well.
2001-09-18 Sergey Poznyakoff
* mh/mh.h: Changed proto of mh_read_formfile(). Thanks to Alain
for noticing.
* mh/inc.c: Likewise.
* mh/scan.c: Likewise.
* mh/mh_init.c: Likewise.
2001-09-18 Sergey Poznyakoff
* mailbox/mbx_mh.c: Optimized for speed.
_mh_message_save(): scan the message while saving it. If expunge==0,
do not create temporary, operate directly on the message file instead.
mh_append_message(): Do not rescan appended message.
mh_scan_message(): Do not rescan the message if it's not changed
since last scan.
* mh/.cvsignore: Updated.
* mh/mh_argp.c: Pass '+' key when handling +folder option.
* mh/mh_getopt.c: Handle +folder.
* mh/inc.c: Handle '+' key.
* mh/scan.c: Likewise.
2001-09-17 Alain Magloire
Pop3 now has a debug object, mu_debug_t, to follow the protocol
exchanges between the library and the server.
* mailbox2/pop3/*: Add debug prints in all.
* mailbox2/sdebug.c: New entry.
* mailbox2/debug.c: New entry.
* mailbox2/Makefile.am: Add debug object
* mailbox2/include/mailutils/Makefile.am: Add debug.h
* mailbox2/include/mailutils/sys/Makefile.am: Add debug.h and sdebug.h
* mailbox2/include/mailutils/debug.h: New file.
* mailbox2/include/mailutils/sys/debug.h: New file.
* mailbox2/include/mailutils/sys/sdebug.h: New file.
* mailbox2/fdstream.c: Bug in fdstream do not call FD_SET if
the file descriptor is -1;
* mailbox2/tcpstream.c: Bug in fdstream do not call FD_SET if
the file descriptor is -1;
2001-09-17 Sergey Poznyakoff
* mail/mailline.c: fixed declaration of ml_reread, it did not
match the changed proto.
* acconfig.h: Added HAVE_OBSTACK
* mailbox/mbx_mbox.c: _mh_next_seq(): add 1 to the last used
sequence number. mh_append_message(): missed assignment to
mhd member of struct _mh_data.
mh_message_number(): new function. It is the only way to get
the message sequence number.
Further changes to mh/: Implemented inc command. Added missing
options to scan.
* mh/Makefile.am: Added inc.c. Restructured .*_LDADD assignments.
* mh/mh.h: Extern declarations for current_folder, current_message,
mh_list_format, etc.
* mh/mh_format.c: builtin_msg(): return sequence number of the
message, not its ordinal number in mailbox.
builtin_cur(): implemented.
* mh/mh_init.c: New globals: current_folder, current_message,
mh_list_format, etc.
mh_init(): initialize current_folder and current message.
mh_read_context_file(), mh_read_formfile(): new functions.
* mh/scan.c: Changed initialization of format_str. Removed
scan_folder: use current_folder instead. Implemented
-form and -header options. Use \f to clear screen if
stdout is not a tty.
* mh/inc.c: (new) Implementation of inc command.
2001-09-16 Alain Magloire
* doc/mbox.texi: Starts to document the concrete Unix mbox
API.
* doc/pop3.texi: Typos.
* mailbox/mbx_mh.c: Initialized variables. Typecast to void
expunge since it is never used.
* mail/delete.c : Typo.
2001-09-16 Alain Magloire
This is after a exchange with Dave Inglis and Sam Roberts.
Basically they recommend to drop the XX_release() functions
and only to keep XX_create (), XX_destroy (). We have simple
reference count strategy for memory management.
* mailbox2/* : Way too much to enumerate.
* mailbox2/refcount.c: New file
* mailbox2/include/mailutils/refcount.h: New file
* mailbox2/include/mailutils/sys/refcount.h: New file
* mailbox2/fdstream.c: stream_fd_create ().
2001-09-15 Alain Magloire
The exercise is to crank up the warnings from gcc and cleanup
the code based on the hints generated by the compiler. The usual
errors:
- signed vs unsigned, signedness or unsignedness problems.
- printf() wrong formats
- wrong prototypes declarations
- and different buglets
- "const char *" vs "char *"
- unused variables
- unused arguments. Tell the compiler by typecasting to void
(void)var.
- Some variable when shadowed, meaning in another block variable
of the same name where reused.
- atoi() is not an ANSI C function, we should use strtol().
Changes to comply to GNU coding standards, and nuke trailing spaces.
* mail/alias.c (alia_lookup): No prototypes and scope static.
(hash_num, max_rehash, aliases): Scope static and unsigned.
(hash): unsigned.
(alias_rehash): i unsigned.
(alias_lookup_or_install): slot variable unused.
(alias_destroy): unsigned.
* mail/copy.c (mail_copy0): fprintf wrong format.
* mail/decode.c: dislay_message change prototype.
(mail_decode): Cast when calling util_msgset_iterate().
(display_message): Prototype change.
(display_headers): unsigned issues.
* mail/delete.c: Buglet was calling mail_delete0() instead of
mail_delete.
* mail/eq.c: Unused arguments.
* mail/exit.c: Unused arguments.
* mail/folders.c: Unused arguments.
* mail/followup.c: Unused variables.
* mail/from.c (mail_from): variable buffer was shadowing use variable
name instead. snprintf() formatting issues.
* mail/headers.c: Unsigned issues.
* mail/if.c: Unused arguments.
* mail/inc.c: Unused arguments.
* mail/list.c: Use const char *.
* mail/mail.c: options[], argp[] initialized all elements.
(mail_cmdline): Unused arguments.
(main): Unsigned issues.
(mail_warranty): Unused arguments.
* mail/mail.h: function_t with complete prototype this necessary
to let the compiler do proper checks.
struct mail_command_entry rearrange the fields and a new field
int (*escfunc) __P ((int, char **, struct send_environ *));
Indentation rearrangements.
* mail/mailline.c (ml_getc): Scope is static now.
typecast for const char *.
(ml_reread): Typecast.
* mail/msgset.y: Declare yyerror() and yylex().
(msgset_select): Change of prototype to let the compiler do checks.
(selec_sender): Unused arguments.
* mail/pipe.c: Rename variable pipe to tube.
* mail/print.c: Unsignedness and some shadow variables.
* mail/quit.c: Shadow variables.
* mail/send.c: Typecast when necessary. Use the second (escfunc)
field now. Some shadow variables.
* mail/shell.c: Unsigned.
* mail/table.c: Readjust the table to correspond to the signature
change in mail.h.
* mail/tag.c: Prototype change.
* mail/util.c (util_msglist_esccmd): New function.
(util_find_entry): Prototype change. And check return value
of getenv().
(util_screen_lines): Change atoi() to strtoul().
(util_screen_columns): Change atoi() to strtoul().
(util_find_env): Signedness.
(util_fullpath): Prototype changed(const).
(util_slist_to_string):Prototype changed (const).
(util_strcat) :Prototype changed (const).
(util_tempfile): const.
* mail/var.c: Unsignedness, Unused arguments.
(var_quote): Use new function util_msglist_esccmd().
* mail/version.c: Unused arguments.
* mail/write.c: printf formats.
* mail/z.c: Signedness.
2001-09-14 Sergey Poznyakoff
* mailbox/mbx_mh.c: Properly handle messages with null body.
Fixed bug in cyclic stream pool. Lowered MAX_OPEN_STREAMS
limit. It probably should be configurable.
A framework for porting MH utilities. Scan utility is in
working order, except that it ignores -form and -header
options.
* configure.in: Check for presence of GNU obstack functions.
* lib/Makefile.am: Added obstack.[ch]
* lib/obstack.c: (new)
* lib/obstack.h: (new)
* mh: (New directory) Implementation of MH commands.
* mh/Makefile.am: (new)
* mh/.cvsignore: (new)
* mh/mh.h: (new) Main header for mh functions.
* mh/mh_argp.c: (new) Coexistence between GNU long options,
traditional UNIX-style short options and traditional MH long options.
* mh/mh_error.c: (new) Diagnostic output.
* mh/mh_fmtgram.y: (new) Parser for format strings.
* mh/mh_format.c: (new) Run-time execution of format strings.
* mh/mh_getopt.c: (new) MH-style options parsing.
* mh/mh_getopt.h: (new) Its prototypes.
* mh/mh_init.c: (new) Initialization module.
* mh/scan.c: (new) Implementation of scan command.
2001-09-10 Sergey Poznyakoff
* mailbox/mbx_mh.c: Implemented append. Disabled reading of deleted
messages when doing mailbox scan.
* mail/summary.c: Do not set first_unread or first_new to the
message which is marked as deleted.
* mail/z.c: Do not count deleted messages into the total number
of lines output.
2001-09-09 Alain Magloire
This was done when cranking the number of warning generated
by gcc (-Wall, etc ...)
* mailbox/mbx_mh.c: Add include for pthread.
seq_number is size_t.
(_mh_message_name): The problem here is that asprintf()
is a GNU extension. We want libmailbox to be as independent
as possible, so it will not be required for program to be
link with libmailutils(it is not even install). Default to
snprintf ().
(mh_close): return an int.
(_mh_message_insert): n should be size_t.
2001-09-09 Alain Magloire
* doc/pop3.texi: Update the doc.
* doc/sfrom.c.texi: Line too long.
* doc/stream.texi: Line too long.
For the new mailbox, one of the short coming with the old stream_t
object was that select() was not cover, meaning it was not possible
to check if a stream was {read,write} ready. The old was to get
the fd (stream_get_fd()) and do the select. Providing,
stream_is_readready (stream_t, int timeout);
stream_is_writeready (stream_t, int timeout);
stream_is_exceptionpending (stream_t, int timeout);
stream_is_open (stream_t);
Takes care of it. It will work specially for tcp stream.
* mailbox2/stream.c: New functions for the select calls:
(stream_is_readready): New function.
(stream_is_writeready): New function.(stream_t, int timeout);
(stream_is_exceptionpending): New function.
(stream_is_open): New function.
* mailbox2/bstream.c (_bs_readline): Bug was truncating the string
to early.
(_bs_is_readready): New file.
(_bs_is_writeready): New file.
(_bs_is_exceptionpending): New file.
(_bs_is_open): New file.
* mailbox2/fstream.c: stubs for the select functions.
* mailbox2/memstream.c: stubs for the select functions.
* mailbox2/mapstream.c: stubs for the select functions.
* mailbox2/tcpstream.c: stubs for the select functions.
* mailbox2/include/mailutils/stream.h: Adjust the prototypes
* mailbox2/include/mailutils/sys/stream.h: Adjust the prototypes
It is better not to put threading (Pthread) code in the low level
API. But instead in mailbox_t framework, where it can be control.
* mailbox2/include/mailutils/pop3.h: Adjust the prototypes.
* mailbox2/pop3/*.c: Remove threading code.
2001-09-09 Sergey Poznyakoff
* mailbox/mbx_mh.c: Bug fix: both pool_first and pool_last must
be biased by MAX_OPEN_STREAMS;
2001-09-08 Sergey Poznyakoff
Initial implementation of MH mailbox format. It is functional
in read-only mode. In read-write, it is able to delete and
undelete messages but lacks `append message' functionality.
Expunge does not unlink message files but rather renames them
prepending ',' to a filename, after MH fashion.
* mailbox/mbox_mh.c: (new)
* mailbox/url_mh.c: (new)
* mailbox/folder_mh.c: (new)
* mailbox/Makefile.am: Added mh-related sources.
* mail/mail.c: Register mh_record.
* mailbox/include/registrar0.h: Added mh-related declarations.
* include/mailutils/registrar.h: Declare mh_record.
* mailbox/mbx_mbox.c: Check for MU_ATTRIBUTE_DELETED in
mbox_expunge.
* libmu_scm/mu_mailbox.c: mu_scm_mailbox_print(): handle
mailbox == #f case.
* libmu_scm/mu_message.c: mu_scm_message_print(): handle
message == #f case.
2001-09-06 Alain Magloire
* mailbox/folder_mbox.c (folder_mbox_open): Implemented.
2001-09-05 Sergey Poznyakoff
* MySql/MySql.h: New defines MHOST, MPORT, etc.
* MySql/MySql.c: Improved error logging. Fixed memory leak due
to absence of mysql_close() calls (noticeable on imap4d when
doing multiple login attempts).
Provide configurable parameters to mysql_real_reconnect to
allow connecting to the remote database and/or non-standard
ports.
2001-09-04 Alain Magloire
* mailbox/mbx_imap.c (message_operation): Check if the
imap server went away(f_imap->isopen) and flag an error.
2001-09-03 Alain Magloire
* mailbox/folder_imap.c (imap_use): Check return value.
* mailbox/mailbox.c (mailbox_get_debug): Get the mu_debug_t
object from the folder if available.
* mailbox/mbx_imap.c (imap_append_message): Check for
EAGAIN.
(imap_header_get_value): If the operation return 0, set
error to ENOENT.
2001-09-03 Alain Magloire
* configure.in: AC_REPLACE_FUNCS(fgetpwent);
* include/mailutils/parse822.h: Add a prototype for
parse822_skip_nl().
* lib/Makefile.am: add fgetpwent.c
* lib/fgetpwent.c: New file.
* mail/from.c (mail_from): Use the cover functions
attribute_is_xxxx() instead of getting the flag.
* mailbox/attribute.c: Cleanup the mess.
attribute_set_{read,delete,seen,flagged,answered}.
attribute_unset_{read,delete,seen,flagged,answered}.
attribute_is_{read,delete,seen,flagged,answered}
should be no more then cover functions calling
attribute_set_flags(), attribute_get_flags() and
attribute_unset_flags().
* mailbox/folder_imap.c: MU_ATTRIBUTE_READ, is not
part of IMAP protocol use \\Seen.
* mailbox/mbx_imap.c: Remove the hack trying to reconnect,
it does not work.
* mailbox/mbx_pop.c(pop_get_messages): Set the new
functions for the attribute.
(pop_get_attribute): New functions.
(pop_set_attribute): New functions.
(pop_unset_attribute): New functions.
(pop_attr_flags): Removed.
* mutil.c (mu_hex2ul): GNU coding std.
(parse822_time): Do not use tzname as a variable name tzname
is global variable in libc, better clear away.
(parse822_date_time): Likewise.
* pop3d/Makefile.am: add virtual.c
* pop3d/pop3d.c (main): register getpwnam_ip_virtual,
getpwnam_host_virtual
* pop3d/pop3d.h: declare,
getpwnam_ip_virtual(), getpwnam_host_virtual().
* pop3d/virtual.c: New file.
2001-09-02 Alain Magloire
* mailbox/mutil.c (getpwma_virtual): Memory overrun, did not
reserve enough space to accommodate the extra slash, when
doing the sprintf().
Include <string.h>, since we use strdup().
2001-08-31 Jakob 'sparky' Kaivo <jkaivo@elijah.nodomainname.net>
* imap4d/list.c (list_file): don't show INBOX if virtual
2001-08-31 Sergey Poznyakoff
* mailbix/mutil.c: Fixed declaration of _app_getpwnam.
Moved mu_virtual_domain out of #ifdef guard. Fixed typo
in getpwnam_virtual: erroneously returned NULL instead of
p.
2001-08-31 Sergey Poznyakoff
Generalized mu_getpwnam interface. mu_register_getpwnam allows
to register several functions which will be tried in turn in
order to obtain struct passwd*. Changed virtual domain code
in pop3d and imap4d to use this approach.
* mailbox/mutil.c: _app_getpwnam is a list of getpwnam functions.
mu_getpwnam calls each function in succession until it finds one
which returns non-NULL value.
* include/mailutils/mutil.h: Fixed mu_.*getpwnam declarations. Added
declaration for mu_virtual_domain and getpwnam_virtual()
* mailbox/Makefile.am: Add -DSITE_VIRTUAL_PWDDIR to CFLAGS.
* configure.in: New option --with-virtual-pwddir allows to configure
the path to domain passwd files. Defaults to <sysconfdir>/domain.
* imap4d/copy.c: Use mu_virtual_domain instead of is_virtual.
* imap4d/select.c: Likewise.
* imap4d/status.c: Likewise.
* imap4d/imap4d.c: Register getpwnam_virtual for handling virtual
domains.
* pop3d/pop3d.c: Likewise.
* imap4d/login.c: Removed imap4d_virtual. Its functionality passed
to getpwnam_virtual.
* pop3d/pop3d.h: Include mutil.h
* pop3d/user.c: Removed pop3d_virtual. Its functions are performed
by getpwnam_virtual. Renamed is_virtual to mu_virtual_domain.
* mail/alias.c: Use linear hash ordering.
2001-08-30 Alain Magloire
In the virtual code, change the chdir() and build the full
pathname in a buffer. For a daemon, it is better to stay
in "/" the root. Moving in subdirectories, will not permit
the volume to be unmounted. But we do not follow the
same rule for imap4d, it should be fix.
* pop3d/signal.c: Shutup unused parameter warning from gcc.
* pop3d/user.c: Define macro VIRTUAL_PWDDIR. use sprintf()
to build filename instead of chdir().
(PAM_gnupop3d_conv): Shutup unused parameter warning from gcc.
Make sure variable mailbox_name is initialized.
* include/mailutils/mutil.h: Typo "struct password" instead of
"struct passwd". Use const appropriately in the declaration
of mu_register_getpwnam() and mu_getpwnam().
* mailbox/mutil.c: Use const appropriately in the definition
of mu_register_getpwnam() and mu_getpwnam(). Typo "struct password"
instead of "struct passwd".
2001-08-30 Sergey Poznyakoff
More changes to better integrate mysql support. Introduced
mu_getpwnam function. The function first calls system getpwnam,
if it fails, it calls application-defined getpwnam function.
mu_register_getpwnam can be used to register such a function.
* configure.in: Add -lm to AUTHLIBS when configured with
--enable-mysql.
When checking for PAM: Append to AUTHLIBS instead of just
assigning to it.
* imap4d/Makefile.am: Moved @AUTHLIBS@ before libmailutils.
Needed when using mysql.
* pop3d/Makefile.am: Likewise.
* imap4d/imap4d.c: use mu_register_getpwnam.
* pop3d/pop3d.c: Likewise.
* pop3d/user.c: Use mu_getpwnam.
* imap4d/login.c: Likewise.
* mailbox/mbx_default.c: use mu_getpwnam. Removed inclusion
of MySql.h.
* mailbox/mutil.c: new functions: mu_getpwnam() and
mu_register_getpwnam().
Removed inclusion of MySql.h
* include/mailbox/mutil.h: Prototypes for the new functions.
2001-08-30 Sergey Poznyakoff
* MySql/MySql.c: Use asprintf instead of sprintf, use xmalloc
instead of malloc.
Return values were allocated dynamically but never freed, this
caused memory leaks if authentication functions were called more
than once. Made them static, so that they get reallocated at each
new invocation of getM functions, thus reclaiming lost storage.
Made <config.h> the first file to be included and guard it with
#ifdef HAVE_CONFIG_H
Reindented text to conform to GNU coding style.
* MySql/Makefile.am: Use @BUILD_LIBMYSQL@ substitution instead
of direct assignment to noinst_LIBRARIES, so the subdir gets
distributed properly.
* configure.in: New substitution variable BUILD_LIBMYSQL. Append
linker flags to AUTHLIBS, since modifying LIBS effectively
breaks compilation.
2001-08-29 Jakob 'sparky' Kaivo <jkaivo@elijah.nodomainname.net>
* imap4d/select.c (imap4d_select0):
* imap4d/copy.c (imap4d_copy0):
* imap4d/status.c (imap4d_status): treat INBOX differently if virtual
* imap4d/login.c (imap4d_virtual): new function
(imap4d_login): call imap4d_virtual
* imap4d/imap4d.h: add is_virtual variable
* configure.in (USE_VIRTUAL_DOMAINS): add virtual domain option
* pop3d/user.c (pop3d_virtual): new function for "virtual domains"
(pop3d_user): call pop3d_virtual
2001-08-28 Alain Magloire
* mailbox2/include/mailutils/list.h: the typedef list_t
is rename mu_list_t, as a suggestion from Sam R.
* mailbox2/list.c: All the function names are prefix with "mu_".
2001-08-27 Alain Magloire
* mailbox/folder_imap.c (imap_list): When \NoSelect, it is
also mean that the file is a directory.
2001-08-27 Jakob 'sparky' Kaivo
* mail/send.c (mail_send0): change readline (NULL) to readline
(" \b") so there is really no prompt
2001-08-24 Jim Hull
* Makefile.am:
* acconfig.h: Added support for new MySql addition to mailutils
* configure.in:
* MySql/Makefile.am:
* MySql/MySql.c: Mini lib to link to when mysql support
* MySql/MySql.h: enabled (with --enable-mysql)
* doc/Readme.mysql: Readme file for setup.
* imap4d/login.c:
* mailbox/mbx_default.c: The Patch pretty much works the same
* mailbox/mutil.c: all around. if getpwnam() returns null
* mailbox2/mutil.c: then your db is checked for the user,
* pop3d/apop.c: and the struct is filled if found,
* pop3d/user.c: returns null if not. If shadow support
is used, then the same is done with getspnam().
* examples/mail.MysqlMailer.c: Simple sendmail backend support.
2001-08-24 Alain Magloire
* sieve/Makefile.am: To EXTRA_DIST add md5-rsa.{c,h}.
* mailbox2/header.c(header_aget_value): Base on discussion with Sergey
if the call fails no memory should be allocated and the return status
should be return i.e. status != 0.
* imap4d/fetch.c (fetch_bodystructure0): Check for sp != NULL.
* imap4d/fetch.c (send_parameter_list): Check for sp != NULL.
2001-08-23 Sergey Poznyakoff
* mail/msgset.y: Fixed erroneous call to msgset_select
(second arg should have been a pointer). Added :t (tagged)
and :T (untagged) selection criteria.
* mail/tag.c: (new) Implementation of tag command.
* mail/table.c: Added entries for "tag" and "untag".
* mail/Makefile.am: Added tag.c
* mail/from.c: Display tagged messages.
* mail/mail.h: Added protos and defines for mail_tag().
2001-08-22 Jakob 'sparky' Kaivo <jkaivo@elijah.nodomainname.net>
* imap4d/fetch.c (bodystructure): check sp != NULL before using
2001-08-18 Sergey Poznyakoff
* libmu_scm/mu_mime.c: (new) Scheme primitives for handling
mime messages.
* libmu_scm/mu_message.c: mu_scm_message_add_owner() - add new
object to the owner chain of the message.
* libmu_scm/mu_scm.h: Prototypes for new functions.
* libmu_scm/mu_scm.c: Call mu_scm_mime_init().
* guimb/scm/reject.scm: (new) Implementation of Sieve "reject"
action.
* guimb/scm/redirect.scm: Moved sieve-message-bounce to
sieve-core.scm
* guimb/scm/sieve-core.scm: New function sieve-message-bounce.
2001-08-16 Sergey Poznyakoff
* mail/msgset.y: Implemented :/expr/ -- search in the message
body. Fixed memory leak in select_header (missed regfree).
2001-08-14 Sergey Poznyakoff
* mail/msgset.y: Extended regexp syntax: IDENT:/EXPR/ fetches
all messages whose header IDENT matches given EXPR. The match
is case-sensitive if IDENT starts with a capital letter and
is case-insensitive otherwise.
2001-08-12 Alain Magloire
* mailbox2/*: Move more code from the original mailbox
To much to enumerate.
2001-08-07 Alain Magloire
* m4/regex.m4: New file to check for GNU regex.
* lib/regex.c: New file, GNU regex implementation.
* lib/regex.h: New file.
* lib/posix: New directory.
* lib/posix/Makefile.am: New file.
* lib/posix/regex.h: New file.
* lib/Makefile.am: Add SUBDIRS=posix and regex.c dependencies.
* mail/msgset.y: Remove HAVE_REGEX macro and check variable
"noregex" before using regex.
* configure.in: Check for GNU regex.
2001-08-07 Alain Magloire
* mail/msgset.y: Draft implementation of a proposition
to allow regular expressions.
(REGEXP): Passing the address of the pointer instead of the pointer.
(INDENT): Likewise.
* mail/Makefile.am: Add in EXTRA_DIST msgset.c to force its
generation when doing the distribution, having yacc should
not be required.
* mailbox/mutil.c (mu_hexstr2ul): Properly cast the expression
before doing the comparison.
2001-08-06 Sergey Poznyakoff
* mail/msgset.y: (new) A parser for message set specifications
of arbitrary complexity. Returns a singly linked list of
message specifications that can be iterated without need
for recursion.
* mail/mail.h: Prototypes for msgset_ functions. Removed proto
for util_expand_msglist.
* mail/Makefile.am: Added msgset.y
* mail/{copy.c, followup.c, headers.c, next.c, pipe.c,
previous.c, util.c, write.c}: Use msgset_parse instead of
util_expand_msglist.
* mail/util.c: Added util_msgset_iterate() to iterate over a
message set. Added util_get_content_type() and
util_get_hdr_value() (from decode.c).
* mail/decode.c: Use util_msgset_iterate(). Moved get_content_type()
and get_hdr_value() to util.c
* mail/table.c: Fixed synopsis for decode.
* libmu_scm/Makefile.am: Removed .x and .doc files from EXTRA_DIST.
Thanks to Alain.
* guimb/Makefile.am: Likewise.
* m4/Makefile.am: Added maintain.m4
2001-08-06 Alain Magloire
* sieve/{exitcodes.h hmac-md5.h md5.c md5.h md5global.h}: Removed.
* sieve/md5-rsa.c: New file, clearly identify that the algo.
is from RSA and not GNU md5.
* sieve/md5-rsa.h : New file.
* sieve/Makefile.am: added md5-rsa.[ch].
* sieve/message.h: lcase() change for strlower ().
* sieve/script.c: Include md5-rsa.h.
* sieve/sieve-gram.y: lcase changed for strlower ().
* sieve/util.c: Remove all the unnecessary code and
only implement strlower() and strupper().
* sieve/util.h: Only export strlower and struppper ().
* messages/messages.c: Also include pop_record
amd imap_record.
2001-08-05 Sergey Poznyakoff
* mailbox/mbx_mbox.c: Added mbox_stream_size().
* mailbox/message.c: Added message_stream_size().
* mailbox/stream.c: Fixed some comments.
* libmu_scm/mu_port.c: (new) I/O port functions. This allows to
write and read mailboxes/messages using usual scheme primitives
and thus effectively obsoletes mu_body interface, but I'll keep
it for a while.
* libmu_scm/mu_scm.c: Call to mu_scm_port_init().
* libmu_scm/mu_scm.h: Prototypes for port functions.
* libmu_scm/mu_message.c: Added mu-message-get-port.
mu-message-set-header: don't bail out if third argument is boolean,
to allow for constructs like
(mu-message-set-header
m1 "From"
(mu-message-get-header m2 "To"))
* libmu_scm/mu_maibox.c: Added mu-mailbox-get-port.
* guimb/scm/sieve.scm: Documented some obscure data structures.
* guimb/scm/sieve-core.scm: Use sieve-mailbox-open instead of
mu-mailbox-open. The former searches the list of open mailboxes
and returns one if found. All the mailboxes get closed at once
when the sieve program finishes execution. This saves memory and
speeds up the execution (fewer calls to gc, if any).
sieve-regexp-to-posix: escape special characters.
action-reject: Use ports instead of mu-body- interface.
* examples/reply.scm: Use ports instead of mu-body- interface.
* mail/var.c: Added checks for missing arguments.
2001-08-04 Sergey Poznyakoff
* mailbox/header.c: Return value of header_aget_value() was always
0. Made it consistent with that of header_get_value(). Same for
header_aget_field_value().
* guimb/main.c: Fixed handling of default mailbox in the absence of
other mailbox arguments.
* guimb/collect.c: Likewise.
* guimb/guimb.h: Removed unused declarations.
* libmu_scm/mu_message.c: Changed mu-message-get-header-fields
to allow for second optional argument. The argument is a list
of header names to narrow output to.
* guimb/scm/sieve-core.scm: Changed action-keep: it couldn't be just
#f. Fixed and tested action-stop, action-redirect and test-exists.
Fixed handling of null-length keys in sieve-str-str.
test-address and test-header: use mu-message-get-header-fields
to speed the things up.
Implemented "envelope" test.
* guimb/scm/sieve.scm: Add final #t to the generated code, so the
empty scripts work.
2001-08-03 Sergey Poznyakoff
* libmu_scm/mu_logger.c: (new) Interface to syslog functions.
* libmu_scm/mu_mailbox.c: Added mu-mailbox-get-url.
* libmu_scm/mu_message.c: Added mu-message-get-size,
mu-message-get-lines.
* libmu_scm/mu_address.c: Provide mu_scm_address_init() function.
* libmu_scm/mu_scm.c: Call mu_scm_address_init(), mu_scm_logger_init().
Added mu-package and mu-version variables.
* libmu_scm/mu_scm.h: Prototypes for mu_scm_address_init() and
mu_scm_logger_init().
* libmu_scm/Makefile.am: Added mu_logger.c
* guimb/main.c: Added --mailbox and --user options. Added escape for
Scheme arguments (-{ and -}).
* guimb/run_scm.c: Call collect_output() before dropping mailbox.
Added exception handling. Added user-name variable.
* guimb/collect.c: Added collect_output().
* guimb/guimb.h: Added prototypes.
* guimb/Makefile.am: Added SUBDIRS.
* guimb/scm: (new) Directory containing guimb modules and scripts.
* guimb/scm/Makefile.am: (new)
* guimb/scm/sieve.scm: (new) Sieve to Scheme translator.
* guimb/scm/sieve-core.scm: (new) Sieve core functions for scripts
generated by sieve.scm.
* guimb/scm/redirect.scm: (new) Implementation of sieve "redirect"
action.
* configure.in: Output guimb/scm/Makefile.
* mail/mail.c: Use mailbox_create_default for --file=MBOX.
Some calls to exit() were placed *before* issuing diagnostics.
Fixed.
* mailbox/folder_imap.c: Changed ENOTSUP to ENOSYS.
2001-08-02 Sam Roberts
* folder_imap.c: don't pretend to be authorized if we are not, it
only leads to confusion
* mailbox.c: mailbox created the folder, it should set it's
folder's debug object when it's is set, otherwise there is no way
to get debug messages from a mailbox's folder (I was getting all
the pop protocol traces but not the imap ones)
* TODO: updated
* sieve/: script.c, sieve.c: Fixed bug, I was deleting a message
after a fileinto, which was wrong. Tweaked the logging, it's
little cleaner and more useful.
* sieve/COPYING: Removed the RCS keyword in the imported copyright
notice.
* sieve/: sieve-gram.y, sieve-lex.l: Now using xmalloc() from
../lib.
* examples/mbox-explode.c: Don't mkdir unless the mailbox can be
opened, and better cleanup on error detection.
* sieve/examples/: Test, test.out: Committing my example/test sieve
scripts so I can maintain them with cvs (I use them at work and
home).
* mail/util.c: Not all systems have <sys/fcntl.h>, changed to use
HAVE_FCNTL_H.
* mailbox/mbx_pop.c: imap logged the passwd in protocol traces, pop
didn't, so I made them both be the same (the way that is most
useful when debugging protocol traces)
* sieve/examples/: INBOX.orig, Makefile, box.sv, ex-1.10.2.sv,
ex-2.3a.sv, ex-2.5.1.sv, ex-2.7.3.sv, ex-3.1a.sv, ex-3.1b.sv,
ex-3.2.sv, ex-4.1.sv, ex-4.2.sv, ex-4.4a.sv, ex-4.4b.sv, ex-4.5.sv,
ex-5.1.sv, ex-5.7.sv, ex-9.sv, ex-null.sv, ex-save-all.sv,
example.sv, exn-2.3b.sv, exn-5.4.sv, t-exists.sv, t-fileinto.sv,
t-mailutils.sv: Committing my example/test sieve scripts so I can
maintain them with cvs (I use them at work and home).
2001-08-01 Alain Magloire
* mailbox2/header.c: Put the stubs.
* mailbox2/include/mailutils/header.h: Prototypes.
* mailbox2/include/mailutils/sys/header.h: Prototypes.
2001-07-31 Alain Magloire
More intelligence was put in decode to detect mime messages.
This temporary until we articulate how to present mime messages.
decode will probably replace print.c. Parsing of mailcap is
not yet done.
* mail/decode.c: Aware of the content_type and the encoding
for mime message, will supersede [Pp]rint.
* mail/mail.c: Set the columns variable at startup.
* mail/mail.h: Prototype fpr util_screen_columns().
* mail/mailline.c: Reset COLUMNS on SIGWINCH.
* mail/util.c: New function util_screen_columns();
* sieve/Makefile.am: Remove gcc specific flags.
* sieve/xmalloc.c: Removed, use lib/xmalloc.c instead.
* sieve/xmalloc.h: Removed.
* sieve/sysexists.h: Removed.
2001-07-31 Alain Magloire
* mailbox2/Makefile.am: add new files.
* mailbox2/fstream.c (_fs_write): n uninitialized.
(_fs_open): Use S_ISREG() macro.
* mailbox2/include/mailutils/base.h: Remove superfluous.
* mailbox2/iterator.c: Define struct _iterator.
* mailbox2: New files: observer.c observable.c
address.c parse822.c list.c attribute.c envelope.c
2001-07-30 Sergey Poznyakoff
* guimb/main.c: Set g_argv[0] to the program file name for consistency
with guile.
* libmu_scm/mu_message.c: Added new primitives:
mu_message_copy
mu_message_delete
mu_message_get_flag
mu_message_set_flag
mu_message_get_user_flag
mu_message_set_user_flag
* libmu_scm/mu_scm.c: Define MU-ATTRIBUTE- constants.
* libmu_scm/mu_address.c: (new) Address-related functions.
* libmu_scm/Makefile.am: Added mu_address.c
2001-07-27 Sergey Poznyakoff
* lib/xmalloc.c: call mu_error() instead of error().
* lib/malloc.c,lib/realloc.c: (new) Provide rpl_malloc() and
rpl_realloc() (required by m4/malloc.m4, m4/realloc.m4)
* lib/Makefile.am: Added malloc.c, realloc.c.
* mail/mail.h: Include <xalloc.h>
* mail/util.c: Removed util_[mc]alloc() in favor of x[mc]alloc().
* mail/alias.c: Use x[mc]alloc() instead of util_[cm]alloc().
* mail/alt.c: Likewise.
* mail/mail.c: Likewise.
* mail/mailline.c: Likewise.
* mail/shell.c: Likewise.
* mail/unset.c: Likewise.
* mail/var.c: Likewise.
* TODO: updated.
2001-07-25 Alain Magloire
Based on Jakob's idea, an implementation for decode.
But it is clearly not flexible enough:
decode [msgno] [part]
? decode 28 2
IF message 28 is a multipart(mime) with two parts, the second part
will be decoded and sent to stdout.
* mail/decode.c: First implementation behind Jakob's proposal.
2001-07-23 Sergey Poznyakoff
* configure.in,libmu_scm/Makefile.am,guimb/Makefile.am : Fixed to
compile properly on systems with missing/incomplete guile.
* include/mailutils/Makefile.am: Added mailutils.h to
pkginclude_HEADERS.
2001-07-23 Alain Magloire
* libmu_scm/mu_scm.h: Remove HAVE_LIBGUILE_H guard.
* guimb/guimb.h: Remove HAVE_LIBGUILE_H guard.
2001-07-23 Alain Magloire
* util.c (util_msglist_command): Check for interruption here
also and that will permit interruption on long commands like
"from *"
2001-07-23 Alain Magloire
The reason the interrupt code did not work for me, is that
by default using signal will make function calls restartable,
at least on my default RH5.1, when read() was interrupted
it did not return EINTR inside ml_getc().
* mail.c (main): Use sigaction if available to set SIGPIPE.
* mailline.c (sig_handler): Reset "lines" variable.
Recall signal() if we did not have sigaction.
(ml_readline_init): Use sigaction to set SIGWINCH and SIGINT.
* libmu_scm/mu_scm.h: Guard with HAVE_LIBGUILE_H.
* guimb/guimb.h : Guard with HAVE_LIBGUILE_H.
2001-07-22 Sergey Poznyakoff
Renamed debug_.* symbols to mu_debug_.* to avoid nameclashes.
Files affected:
* examples/mbox-dates.c, mbox-explode.c;
* from/from.c;
* include/mailutils/{debug.h,folder.h,mailbox.h,mailer.h};
* libmu_scm/mu_message.c;
* mail/send.c;
* mailbox/{debug.c,folder.c,mailbox.c,mailer.c};
* mailbox/include/{debug0.h,folder0.h,mailbox0.h,mailer0.h};
* mailbox2/include/mailutils/base.h;
* readmsg/readmsg.c;
* sieve/sieve.c;
* configure.in: Added --without-guile. Uncommented making
libmu_scm and guimb. Added check for -ldl before
checking for -lpam: both FreeBSD and OpenBSD lack libdl, but
have working libpam.
* messages/Makefile.am: Added missing @ARGP.*@ substitutes.
2001-07-21 Jakob 'sparky' Kaivo <jkaivo@elijah.nodomainname.net>
* mail/Makefile.am (mail_SOURCES): add decode.c
* mail/mail.h: add mail_decode prototype
* mail/decode.c (mail_decode): new file, new function
* mail/table.c: add decode command
* mail/util.c (util_expand_msglist): insert placeholder for
attachment operations
2001-07-20 Jakob 'sparky' Kaivo <jkaivo@elijah.nodomainname.net>
* messages/messages.c: new file, implement of elm messages command
(parse_opt): add --silent and --quit options
(messages_count): new function
2001-07-20 Alain Magloire
* mailbox/misc.c: Removed, _cpystr() function move in mutil.c
and rename to util_cpystr().
* mailbox/include/misc.h: Removed.
* include/mailutils/mutil.h: Added prototype for util_cpystr().
* mailbox/mutil.c (util_cpystr): New function, move
the _cpystr() from misc.c and move here.
* mailbox/Makefile.am: Removed misc.c in dependencies.
* mailbox/include/Makefile.am: Removed misc.h in dependencies.
* mailbox/address.c: Use util_cpystr() instead of _cpystr().
Added <mailutils/mutil.h> prototype.
* mailbox/auth.c: Likewise.
* mailbox/url.c: Likewise.
* mailbox/folder.c: Likewise.
2001-07-19 Sergey Poznyakoff
Added guile interface library.
* Makefile.am: Added scripts libmu_scm guimb.
* configure.in: Checks for presence of Guile components.
Making libmu_scm and guimb commented out until we solve
debug_print name clash
(libguile/debug.h vs. mailutils/debug.h).
* scripts: (new) Contains scripts for preparing guile
documentation strings from C sources. The reason for
their presence is that guile-doc-snarf scripts distributed
with guile up to version 1.4 do not work. The comment at
the beginning of scripts/guile-doc-snarf describes why. We'll
have to use these until next version of guile fixes the bug.
* scripts/{Makefile.am,guile-doc-snarf,guile-func-name-check,
guile-snarf.awk: (new)
* scripts/.cvsignore: (new)
* libmu_scm: (new) Guile interface library:
* libmu_scm/Makefile.am: (new).
* libmu_scm/mu_scm.c: (new) Main module.
* libmu_scm/mu_mailbox.c: (new) Mailbox primitives.
* libmu_scm/mu_message.c: (new) Message primitives.
* libmu_scm/mu_body.c: (new) Message body primitives.
* libmu_scm/mu_scm.h: (new) Library prototypes.
* libmu_scm/.cvsignore: (new)
* guimb: (new) Process mailbox(es) using Guile program or
expression.
* guimb/Makefile.am: (new)
* guimb/main.c: (new) Main functions.
* guimb/collect.c: (new) Collect input.
* guimb/util.c: (new) Some utilities.
* guimb/run_scm.c: (new) Initialization of libguile and libmu_scm
* guimb/guimb.h: Prototypes.
* guimb/.cvsignore: (new)
* examples/reply.scm: Automatic mail responder for use with guimb.
2001-07-18 Sam Roberts
* include/mailutils/url.h: New api functions for parsing.
* doc/: Makefile.am, framework.texi, url.texi: Updated and
corrected URL documentation.
* doc/ex-url.texi: The url api example. Derived from
../example/url-parse by a perl script.
* mailbox/url.c: Added a function to do generalized URL parsing.
* mailbox/: url_imap.c, url_pop.c: Use the url_parse() function to
parse the URL.
* mailbox/mbx_pop.c: Added checks for low-memory conditions, and
look for passwd in url before prompting user.
* mailbox/folder_imap.c: Look for passwd in the url before
prompting.
* examples/: .cvsignore, Makefile, Urls, url-parse.c: Added example
of URL parsing, and test for parsing.
* examples/Urls.good: Added test for % decoding.
* mailbox/mbx_mbox.c: Needed <stdlib.h> on QNX6.
* mailbox/include/: registrar0.h, url0.h: Comment on schemes, and
removed comment on encoding.
2001-07-18 Alain Magloire
* mailbox/mbx_mbox.c (mbox_messages_count): This function does
not call the observers, the callback function, on the mbox_scan()
does.
* frm/frm.c (main): call mailbox_scan () instead of
mailbox_messages_count () since we want to be notified.
2001-07-12 Sam Roberts
* examples/mbox-dates.c: Added pop and imap records.
* include/mailutils/mutil.h, mailbox/mutil.c: New functions -
mu_hex2ul(), mu_hexstr2ul().
* mailbox/message.c: unistd.h needed on QNX6
* TODO: Added Sergey's todo items and mine for sieve.
2001-07-12 Jakob 'sparky' Kaivo <jkaivo@elijah.nodomainname.net>
* include/mailutils/mailutils.h: new "catchall" header, includes
all mailutils headers
2001-07-10 Sam Roberts
* examples/Addrs.good: Now mapping ENOENT to EPARSE in error
reporting, its clearer.
2001-07-09 Sergey Poznyakoff
* configure.in: check for termios.h termio.h sgtty.h
Added MU_MAINTAINER_MODE.
* m4/maintain.m4: (new) Settings specific to maintainer-mode.
* m4/Makefile.am: Added maintain.m4.
* mailbox/attribute.c: Fixed flags_to_string(): MU_ATTRIBUTE_SEEN
and MU_ATTRIBUTE_READ were swapped: the former produced 'R',
and the latter 'O'.
* mail/file.c: run "summary" after opening new mailbox.
Issue diagnostics if mailbox cannot be opened.
Display summary when called without arguments.
* mail/from.c: Changed flags display.
* mail/mailline.c: Provide ml_reread() when compiled without
readline.
Check for interrupt in (both versions of) ml_reread().
Use util_[cm]alloc() instead of [cm]alloc().
* mail/{print.c,visual.c}: set READ instead of SEEN attribute on
read messages.
* mail/z.c: case D_FWD missed break; Fixed typos in the comment
to D_NONE.
* mail/version.c: display options with which the program is
compiled.
* mail/util.c: Added util_malloc(), util_calloc().
* mail/mail.h: Protos for the above;
* mail/alias.c: use util_[cm]alloc() instead of library functions
wherever appropriate.
* mail/alt.c: Likewise.
* mail/mail.c: Likewise.
* mail/shell.c: Likewise.
* mail/unset.c: Likewise.
* mail/var.c: Likewise.
Implemented ~A (read signature from file).
* mail/quit.c: Raise hold flag when not closing system mailbox (%).
2001-07-06 Alain Magloire
* mail/mailline.c: "interrupt" is actually a key word
for some C compiler i.e. Watcomm C, rename it to "interrupted".
* mail/util.c: The macros O_CREAT etc needs <sys/fnct.h>.
2001-07-06 Alain Magloire
* mail/mail.c: Be a little more verbose when mailbox_{create,open}()
fails at startup.
* doc/Makefile.am: Add the missing *.texi in the list of EXTRA_DIST.
2001-07-06 Sergey Poznyakoff
* imap4d/fetch.c: imap4d_fetch0(): return RESP_OK on success.
* imap4d/bye.c: split imap4d_bye() into imap4d_bye() and imap4d_bye0().
* imap4d/logout.c: call imap4d_bye0() instead of imap4d_bye().
Reason: rfc 2060 requires that the server send a BYE untagged response
before the (tagged) OK response. With our implementation it was
vice-versa.
* imap4d/imap4d.h: proto for imap4d_bye0().
* mail/mail.c: changed startup banner.
* mail/mailline.c: handle SIGWINCH.
* mail/util.c: Include <termios.h> when present.
* configure.in: test for the presence of <termios.h>
2001-07-05 Alain Magloire
* mail/send.c(mail_send0): Put the mailer in debug mode
if util_find_env("verbose")->set, good for debugging.
2001-07-05 Alain Magloire
According to the man page:
"sendmail contains a command, possibly with options, that mailx
invokes to send mail. You must manually set the default for this
environment variable by editing ROOTDIR/etc/mailx.rc to specify the
mail agent of your choice. The default is sendmail, but it can be any
command that takes addresses on the command line and message contents
on standard input."
* mail/mail.c (main): Register smtp_record too as a mailer.
Set variable sendmail to _PATH_SENDMAIL as the default mailer.
* mail/mail.h: New proto util_setenv(), util_find_env()
change to be const char *.
* mail/send.c (msg_to_pipe): New function, open a pipe()
and write a message to it.
(mail_send0): Now create the mailer according to
util_find_env("sendmail")->value. Use a pipe() if mailer_create()
fails.
* mail/set.c (mail_set): After free(entry->value) set the value
to NULL.
* mail/util.c (util_find_env): Change the prototype to be const.
Remove hack about need_free and use a static variable to hold
"asksub".
* mail/util.c (util_setenv): New function to set environment
model on libc call setenv().
* mailbox/message.c (message_sender): Set the default sender base on
the passwd entry.
2001-07-05 Alain Magloire
We can send a message and if the address starts with '|'
the message is pipe to the cmd and if starts with '/' it is
save to a file.
mailx ghislaine '|cat >save'
mails a message to ghislaine and also copies the message into a file
called save.
* mail/mail.h: Change struct send_environ to contain
two new fields char **outfiles and int nfiles.
* mail/send.c: Look for '/' and '|' when parsing the addresses
and add them to struct send_environ outfiles.
(mail_send0): Memory overflow, we were free(buf) twice.
made char *buf local where it is needed. Save the message
to outfiles when set.
(isfilename): New function.
* mail/followup.c: Initialize the struct send_environ new fields.
* mail/reply.c: Initialize the struct send_environ new fields.
* lib/argcv.c: Add support to consider string between
single quote like one word(same as double quotes).
2001-07-04 Alain Magloire
* mailbox2/stream.c: stream_read() and stream_write()
change prototype to be "void *" instead of "char *".
* mailbox2/bstream.c: Adjust bstream_{read,write} to the
new prototypes.
* mailbox2/pop3/pop3_stream.c: Likewise.
* mailbox2/Makefile.am: New file.
* mailbox2/pop3/Makefile.am: New file.
* mailbox2/mstream.c: Mapfile stream Implementation.
* mailbox2/fstream.c: File stream implementation.
* mailbox2/include/mailutils/sys/fstream.h: New file.
* mailbox2/include/mailutils/sys/mstream.h: New file.
* mailbox2/tcp.c: rename to tcpstream.c.
* mailbox2/include/mailutils/sys/tcp.h: Rename to tcpstream.h
* mailbox/mapfile_stream.c (_mapfile_write): Make sure
the size is not zero before making the memcpy().
2001-07-03 Alain Magloire
* mail/headers.c: Catch the overflow in the calculation by
resetting the number of lines to default screen lines.
* mail/mail.c (main): Add a "summary" call also for the
initial commands on startup(in interactive).
* mail.h: Proto for mail_summary() and mail_version().
* table.c: Add mail_summary() and mail_version() in the cmd table.
* util.c (util_getcols): First try an ioctl(TIOCGWINSZ,..) call
not all shells set the COLUMNS environ.
(util_getlines): Likewise. Also take to account the prompt
in the lines number.
* z.c (mail_z): Change the behaviour of "z." to show a screenful
when the last page is reach. This is very practical when starting
mail, since "z." is the initial command to show the header summary.
* mail/version.c: New file, show mail version, mail_version().
* mail/summary.c: New file, display a short summary of the mailbox.
mail_summary().
* mail/Makefile.am: add summary.c and version.c
* mailbox2/include/mailutils/mbox.h: Proto for Unix-Mbox.
2001-07-03 Jakob 'sparky' Kaivo <jkaivo@elijah.nodomainname.net>
* README-alpha: note that INSTALL is generated
2001-07-03 Sergey Poznyakoff
* configure.in: --with-mail-rc option: set path to system-wide
mail.rc file.
* mail/Makefile.am,mail/mail.c: Likewise.
* mail/send.c: check for "dot" variable. Implemented "~.",
"appenddeadletter".
* mail/inc.c: (new) inc[orporate] command.
* mail/{mail.c,mail.h,table.c}: Ditto.
* mail/print.c: Handle interrupts when fetching message body.
* mail/followup.c: insert ',' between recipients' addresses.
* mail/quit.c: use mailbox_save_attributes(). Implemented
"hold" variable. Raise MU_ATTRIBUTE_READ on every message with
MU_ATTRIBUTE_SEEN bit set (compatibility with existing mails).
* mail/from.c: Changed order of checking message attribute bits to
be compatible with existing implementations.
* mail/z.c: removed break from the loop.
* mailbox/attribute.c: added attribute_set_modified() function.
Fixed attribute_unset.* functions to raise MU_ATTRIBUTE_MODIFIED bit.
* include/mailutils/attribute.h: Proto for attribute_set_modified().
2001-07-02 Alain Magloire
* mailbox2/tcp.c: make it thread-safe.
* mailbox2/bstream.c: Implement buffered stream.
* mailbox2/pop3_stream.c: Use a buffered stream.
2001-07-02 Alain Magloire
Feedback from Sergey for the need of saving the attribute flags
without expunging. Note, this is a hack, the code is taken from
mbox_expunge(mbx_mbox.c) and there is lot of duplication. But
since we are moving toward a new mailbox API, the code will be
rewritten more cleanly in the new API.
* include/mailutils/mailbox.h: Add proto mailbox_save_attributes()
* mailbox/include/mailbox0.h: New field in struct _mailbox
_save_attributes (mailbox_t);
* mailbox/mailbox.c: New function mailbox_save_attributes ().
* mailbox/mbx_mbox.c: New function mbox_save_attributes (),
implement saving the attribute flags in header field "Status:"
* imap4d/bye.c: call mailbox_save_attributes() when exiting.
it will save the attribute flags.
* imap4d/close.c: Typo.
* imap4d/logout: Remove the mailbox_close() and mailbox_destroy()
it is being call imap4d_bye ().
* imap4d/select.c (imapr3d_select0): call mailbox_save_attributes()
if a mailbox was already selected.
2001-07-01 Alain Magloire
* mail/util.c (util_strupper): The first implementation was
buggy, corrected.
2001-07-01 Alain Magloire
* mailbox2/pop3/*: Pop3 functions are thread-safe and cancel-safe.
The problem is monitor.h, we will probably end up doing a monitor.h.in
and set at compile time if threading is enable or not.
2001-07-01 Alain Magloire
* mail/util.c (util_expand_msglist): Cleanup the expand by pattern
by moving some code in util_strupper(), the comparison must be
case insensitive.
(util_strupper): Convert the string to uppercase.
2001-07-01 Sergey Poznyakoff
* mailbox/attribute.c: set MU_ATTRIBUTE_MODIFIED bit in the underlying
structure when setting the flags.
* mail/mail.c: Initialize readline and set user name before
determining working mode.
For an empty mailbox output diagnostics and quit.
Read system-wide mail.rc file.
Implemented "set ignoreeof".
* mail/send.c: Implemented "set ignore", "set ignoreeof", "set nosave".
Use doubled escape character to insert a single escape to the
message body.
* mail/delete.c: Implemented "set autoprint"
* mail/dp.c: removed util_do_command("next"): delete does this anyway.
2001-06-30 Sergey Poznyakoff
* configure.in:
define READLINE_LIBS instead of linking libreadline
to every binary.
AC_CHECK_LIB(pthread) was missing comma before
ACTION_IF_NOT_FOUND, thus have_libpthread was always no.
* mail/Makefile.am: Use READLINE_LIBS
* lib/argcv.[ch]: Treat a sequence of whitespace characters as
a single whitespace. Break string on given delimiters. Do not
split quoted arguments.
* mail/set.c: Modified to use new argcv_get() syntax.
* mail/delete.c: After deleting move realcursor to the next
non-deleted message.
* mail/alt.c: Honour "metoo" variable. Try to determine users
full email address.
* mail/mail.c: do not put empty or comment lines into readline
history. Handle keyboard interrupts properly.
Implemented `warranty' command. Warn user about arrival of a new
mail.
* mail/send.c: Handle keyboard interrupts. Use util_tempfile().
* mail/{send.c,reply.c}: change args in call to mail_send0(): packed
all header strings into one structure to facilitate escape handling.
Warn user about null message body.
* mail/mailline.c: (new) readline-related functions.
* mail/var.c: (new) Functions for escape variable handling.
* mail/util.c: added extra argument to util_find_entry(): a pointer
to the table where to look up. Added util_error(), util_help(),
util_tempfile().
* mail/*.c: use util_error() instead of printing diagnostics to ofile.
* mail/{source.c,if.c}: removed mail_is_terminal(),
mail_set_is_terminal(): `interactive' is used instead.
* mail/mail.h: in struct mail_command_entry changed `isflow' field
to `flags'. It contains information about semantics of the command.
* mail/table.c: Initialize `flags' field.
2001-06-29 Alain Magloire
* mail/util.c (util_expand_msglist): Implement expansion of
:d All deleted messages
:n All new messages
:o All old messages
:r All messages that have already been read
:u All unread messages
/string All messages with string in the subject line
(the case of characters in string is ignored)
2001-06-27 Alain Magloire
* configure.in: We were not checking for thread support
at all because the test was faulty.
* readmsg: New directory.
* readmsg/readmsg.c: New file.
* readmsg/readmsg.h: New file.
* readmsg/msglist.c: New file.
This is base on a old testing program Dave inglis wrote
to test the mime parsing code. It is still work in progress
but a good base for the readmsg(1) elm utility clone.
Not enable yet in the TOP Makefile.
2001-06-26 Alain Magloire
* mail/from.c: Use address_get_personal() for a more
pretty print when showing the headers.
2001-06-26 Sergey Poznyakoff
* mail/util.c:
Added extra argument to util_msglist_command(), controlling
whether it should move the cursor to the last message
processed.
* mail/delete.c,mail/dp.c,mail/edit.c,mail/from.c,mail/hold.c,
mail/mbox.c,mail/print.c,mail/reply.c,mail/size.c,mail/top.c,
mail/undelete.c,mail/util.c,mail/visual.c: Likewise.
* mail/util.c: util_screen_lines() function.
util_outfolder_name().
util_save_outgoing()
* mail/z.c: removed z_lines() in favor of util_screen_lines().
* mail/headers.c: use util_screen_lines().
* mail/touch.c: Initial implementation. Simply calls mail_mbox.
Maybe the table.c entry should point to mail_mbox instead?
* mail/write.c: use util_fullpath().
* mail/send.c: call util_save_outgoing() to preserve sent message.
Set umask 077 before calling mkstemp().
* mail/folders.c: Use $LISTER.
* mail/followup.c: Implemented.
* mail/from.c: Changed output format.
* mail/mbox.c: move mail_mbox_commit to quit.c.
* mail/quit.c: Likewise. Honour "keepsave" variable.
2001-06-25 Alain Magloire
* mail/header.c: We were looping forever in here. The loop
is not need it, header only prints one page that includes
the message specified i.e. the header command only takes
a message number as an argument that will serve as a reference
to display a screen full.
* mail/help.c: Use the pager code, the help is long.
2001-06-25 Alain Magloire
* doc/Makefile.am: add {c-api,framework,programs}.texi EXTRA_DIST
* imap4d/imap4d.c (imap4d_usage): Cut and paste typo.
* pop3d/pop3d.c (pop3d_usage): Cut and paste typo.
* include/mailutils/Makefile.am: add mutil.h to the list.
* lib/strisignal.c: Define __P if not set.
* m4/Makefile.am: Added tm_gmtoff.m4 tm_isdst.m4 tm_zone.m4
2001-06-25 Sergey Poznyakoff
* mail/if.c: Removed confusing comment.
* mail/copy.c: Split off mail_copy0. It is shared between mail_copy
and mail_save. Implemented Copy command.
Use mailbox_open_default() instead of mailbox_open().
Fixed possible memory leaks.
* mail/write.c: Implemented Write. Fixed memory leaks.
* mail/Makefile.am: removed discard.c
* mail/discard.c: removed. Implemented in retain.c.
* mail/retain.c: Implemented retain/ignore. It is more convenient
to keep them in one module so they can share static data.
* mail/alias.c: Implemented.
* mail/unalias.c: Implemented.
* mail/alt.c: Implemented.
* mail/file.c:
Check number of arguments.
Display current mailbox name when called without args.
Honour %, &, and + in mailbox names (possibly should
be implemented in mailbox_open_default ?).
Use mail_mbox_close(). After opening new mailbox,
run "z." instead of "from *".
* mail/folders.c: A (very rudimentary) implementation.
* mail/headers.c: Removed if (num) clause: util_expand_msglist()
now returns at least 1.
* mail/pipe.c: Likewise.
* mail/hold.c: Implemented.
* mail/mail.c: Escape % signs in the command line before passing
it to util_do_command().
* mail/mail.h: Protos for implemented functions. Proto for
readline() if libreadline is not linked in.
Definition for MAIL_ATTRIBUTE_MBOXED.
* mail/mbox.c: Implemented.
* mail/print.c: Print only header fields allowed by retain/ignore
settings.
* mail/quit.c: mail_mbox_close() shared between this module and
file.c.
Print statistics information on closing the mailbox (number
of messages held and saved in mbox).
* mail/reply.c: Implemented.
* mail/save.c: Use mail_copy0().
* mail/send.c: Split off mail_send0(). It is used by mail_send()
and mail_reply().
* mail/util.c:
util_expand_msglist(): return 1 and set msglist[0]=cursor
if argc == 1.
util_do_command(): Added missing va_end().
util_get_sender(): Returns sender email for the given msgno.
Optionally strips off domain part.
util_slist_.*(): "string lists" used by alias,alt,retain,
ignore.
util_strcat(): Concat two strings, reallocating first
to the necessary length.
util_escape_percent(): Excape % signs in a string, so
it can be used as format in .*printf calls.
2001-06-22 Sergey Poznyakoff
* mailbox/mutil.c: added mu_get_homedir() and mu_tilde_expansion();
* include/mailutils/mutil.h: protos for new mu_ functions
* imap4d/util.c: use mu_tilde_expansion().
* mail/z.c: implemented.
* mail/if.c: implemented.
* mail/mail.c: A read-eval loop function shared between mail.c and
source.c. Quits gracefully upon reading EOF.
Expand '~' in pathnames.
Upon startup in read mode, display first screenful of from
lines, instead of listing the whole mailbox. This is
compatible with existing implementations.
Do not display prompt when not reading from a terminal.
* mail/source.c: Use common read-eval loop.
* mail/mail.h: Protos for new functions.
struct mail_command_entry: added isflow field, needed
for if/else/endif flow control.
* mail/table.c: changes due to addition of isflow field.
* mail/send.c: removed unconditional #include <paths.h>: it already
was included from "mail.h".
* mail/util.c: Added util_get_homedir() and util_fullpath().
2001-06-21 Sergey Poznyakoff
* mailbox/mutil.c: Fixed error introduced in the initial
implementation of mu_mktime (now mu_tm2time). The comment
on mu_tm2time() describes it.
Revert the sign of the return value of mu_utc_offset(), so it
agrees with the accepted timezone rules (+ for eastern
hemisphere, - for western).
2001-06-19 Sam Roberts
* include/mailutils/debug.h, mailbox/debug.c: New function:
debug_printv() to complement debug_print().
* examples/mbox-dates.c: parse822_date_time now takes a timezone
argument. We don't actually use the arguments, though.
* include/mailutils/parse822.h: parse82_date_time() now uses the
mu_timezone structure for portability.
* include/mailutils/mailbox.h: Prototyped mailbox_destroy_folder().
* mailbox/mu_mktime.c: Moved mu_mktime to mutil.c as mu_tm2time,
and removed mu_mktime.c
* include/mailutils/mutil.h, mailbox/Makefile.am,
mailbox/mbx_imap.c, mailbox/mutil.c, mailbox/parse822.c: Moved some
generically useful date/time handling functions to mutil.c, fixed
problems with portability of timezone information in struct tm, and
created a new structure to hold timezone information, since
struct tm doesn't do so reliably.
* imap4d/: append.c, fetch.c, imap4d.h, namespace.c, search.c,
util.c: Moved date/time parsing utility functions to
mailbox/mutil.c. Added braces to initializers and removed unused
variables prototyped shared functions, made functions that didn't
return return void. (to quiet gcc -Wall),
2001-06-17 Sam Roberts
* sieve/Makefile.am: More fixes to the packaging structure by
Sergey.
* acconfig.h, configure.in, m4/tm_gmtoff.m4, m4/tm_isdst.m4,
m4/tm_zone.m4: Added tests for isdst, gmtoffset, and zone in struct
tm.
* mailbox/folder_pop.c: Confusing typo in comment.
2001-06-16 Sergey Poznyakoff
* mailbox/mu_mktime.c(added): a wrapper around system mktime()
function that honours the timezone.
* mailbox/Makefile.am: add mu_mktime.c.
* imap4d/fetch.c: date conversion in fetch_internaldate.
get_timezone() not used anymore, removed.
* imap4d/search.c: removed confusing comment.
* imap4d/util.c: changed mktime() calls to mu_mktime(), this
solves the timezone problem.
use imap_parse_date_time() in util_parse_internal_date0().
(Proposed by Sam).
* imap4d/imap4d.h: Added missing declarations.
* mailbox/mbx_imap.c: Patch from Sam: added imap_parse_date_time().
imap_parse_date_time() returns tm/timezone pair.
* mailbox/folder_mbox.c: added #include <sys/types.h>. It is needed
on FreeBSD before inclusion of <dirent.h>
* sieve/sieve.c: swapped arguments in a call to va_start().
2001-06-15 Sergey Poznyakoff
Bunch of patches provided by Sam Roberts:
* imap4d/util.c: Fixed format bugs in util_parse.*_date functions.
Use parse822_date_time() in util_parse_header_date().
Some changes to pacify gcc -Wall.
* imap4d/util.c,imap4d/search.c,imap4d/imap4d.h:
Rename the confusing functions:
util_parse_header_date -> util_parse_822_date
util_parse_rfc822_date -> util_parse_ctime_date
include <ctype.h>
2001-06-14 23:01 Sam Roberts
* mailbox/parse822.c: I think timezone info is now placed in struct
tm correctly.
* include/mailutils/parse822.h: Prototypes for functions to parse
rfc822 date-time.
* sieve/: Makefile.am, test.c: Patches from Sergey to make the
auto* stuff work, now uses lex/yacc portably, and puts all the
necessary files into the distribution.
* sieve/ylwrap: Portable wrapper for lex/yacc invocations, by Tom
Tromey <tromey@cygnus.com>, modified by Sergey Poznyakoff
<gray@farlep.net> to replace yy prefixes, so multiple grammars can
co-exist.
* sieve/sieve.c: Define EOK ifndefed.
* examples/showmail.c: No longer relevant to the current APIs.
* examples/mbox-dates.c: GNU indented.
* examples/addr.c: GNU indented
* examples/.cvsignore: Added example executables.
* examples/mbox-explode.c: Made so it now saves all the attachments
from all the messages in a folder. Also GNU indented.
* doc/envelope.texi: Added some text to the envelope docs, still
incomplete.
* doc/url.texi: Noted the IMAP url syntax.
* doc/mailutils.texi: Some of the RFCs were missing, or
miscategorized in the references sect.
* doc/.cvsignore: Ignoring files.
* doc/rfc1939.txt: Was checked in with DOS line terminators,
converted to Unix.
2001-06-11 Alain Magloire
* imap4d/util.c (util_msgset): When '*' was define in the
set it was not added to the count.
Bug reported by Jakob Kaivo.
2001-06-09 Alain Magloire
* mailbox2/pop3/pop3_open.c: Remove for pop3_connect.c
* mailbox2/pop3/pop3_close.c: Remove for pop3_disconnect.c
* mailbox2/pop3/pop3_connect.c: New.
* mailbox2/pop3/pop3_disconnect.c: New.
* mailbox2/include/mailutiils/error.h: New macro
MU_ERROR_OPERATION_CANCELED
* mailbox2/include/mailutils/pop3.h: Move the enum state in sys/pop3.h
2001-06-09 Sam Roberts
* rfc1738.txt, rfc2045.txt, rfc2046.txt, rfc2047.txt, rfc2049.txt,
rfc2088.txt, rfc2111.txt, rfc2192.txt, rfc2193.txt, rfc2221.txt,
rfc2298.txt, rfc2342.txt, rfc2368.txt, rfc2384.txt, rfc2821.txt,
rfc2822.txt, rfc3028.txt, rfc821.txt, rfc822.txt: These RFCs are
relevant to mailutils, and many (all?) are referenced in the
mailutils documentation.
2001-06-09 Alain Magloire
* examples/mbox-explode.c: message_save_attachment, should take
the part. Continue if the message does have a Date or Subject field.
* mailbox/mapfile_stream.c (_mapfile_open): Indentation.
2001-06-09 Alain Magloire
* mailbox/tcp.c (_tcp_get_fd): Buglet, comparing fd against EINVAL
instead of -1.
* mailbox2/pop3/pop3_apop.c: New.
* mailbox2/pop3/pop3_capa.c: New.
* mailbox2/pop3/pop3_close.c: New.
* mailbox2/pop3/pop3_create.c: New.
* mailbox2/pop3/pop3_dele.c: New.
* mailbox2/pop3/pop3_destroy.c: New.
* mailbox2/pop3/pop3_iterator.c: New.
* mailbox2/pop3/pop3_list.c: New.
* mailbox2/pop3/pop3_lista.c: New.
* mailbox2/pop3/pop3_noop.c: New.
* mailbox2/pop3/pop3_open.c: New.
* mailbox2/pop3/pop3_pass.c: New.
* mailbox2/pop3/pop3_quit.c: New.
* mailbox2/pop3/pop3_readline.c: New.
* mailbox2/pop3/pop3_response.c: New.
* mailbox2/pop3/pop3_retr.c: New.
* mailbox2/pop3/pop3_rset.c: New.
* mailbox2/pop3/pop3_sendline.c: New.
* mailbox2/pop3/pop3_stat.c: New.
* mailbox2/pop3/pop3_stream.c: New.
* mailbox2/pop3/pop3_timeout.c: New.
* mailbox2/pop3/pop3_top.c: New.
* mailbox2/pop3/pop3_uidl.c: New.
* mailbox2/pop3/pop3_uidla.c: New.
* mailbox2/pop3/pop3_user.c: New.
* mailbox2/tcp.c: New.
* mailbox2/iterator.c: New.
* mailbox2/stream.c: New.
* mailbox2/pop3/pop3client.c: Test case should probably somewhere else
in example/ perhaps?
2001-06-09 Alain Magloire
* mailbox2/*: First attempt to define the new API.
POP3 was implemented.
2001-06-07 Sam Roberts
* .cvsignore, AUTHORS, COPYING, Makefile.am, NEWS, README,
addr-lex.l, addr.y, comparator.c, comparator.h, exitcodes.h,
hmac-md5.h, imparse.c, imparse.h, interp.c, interp.h, md5.c, md5.h,
md5global.h, message.c, message.h, parseaddr.c, parseaddr.h,
script.c, script.h, sieve-gram.y, sieve-lex.l, sieve.c,
sieve_err.c, sieve_err.h, sieve_interface.h, svfield.c, svfield.h,
sysexits.h, test.c, tree.c, tree.h, util.c, util.h, xmalloc.c,
xmalloc.h: Initial commit of the port of CMU's sieve engine. It
builds, and some actions work, but has seen very little use.
2001-06-03 Sam Roberts
* mailbox/file_stream.c,mailbox/mapfile_stream.c: Return EINVAL
for meaningless combination of MU_STREAM_READ + WRITE.
2001-06-03 Alain Magloire
* doc/*; Bunch of typos corrected.
Patch from Thomas Fletcher.
2001-06-02 Sam Roberts
* mailbox/parse822.c,include/mailutils/parse822.h: functions
to parse rfc822 date-time.
* examples/mbox-explode.c: example of saving all mime attachments
for messages in a mailbox.
* examples/mbox-dates.c: example of using the date-time parser, it
prints all the dates in a mailbox that it can't parse.
* examples/Makefile: makes the mbox-* examples.
2001-06-01 Alain Magloire
* mailbox/mbx_pop.c (pop_writeline): if buffer is NULL noop.
2001-06-01 Sergey Poznyakoff
* imap4d/search.c: case-insensitive comparison for text fields.
Error checking for stray symbols at the end of criteria.
* imap4d/util.c: util_strcasestr() function. Functions for
converting between text and integer representation of
attributes. Split util_parse_internal_date: the helper
function util_parse_internal_date0 also returns the
pointer to the location in the string where parsing
stopped.
* imap4d/util.h: protos for util_strcasestr() and
util_parse_.*_date() functions.
* imap4d/imap4d.c: force ofile to be line-buffered, so command
continuation requests are immediately visible.
* imap4d/append.c: implemented. Currently this needs the
helper function mailbox_destroy_folder(), so that
mailbox_set_stream does its work. Also the situation
with message attributes needs to be cleared.
2001-06-01 Alain Magloire
* mailbox/debug.c(debug_print): Noop is format is NULL;
* mailbox/mbx_imap.c (imap_messages_count): Hack! Force a
reconnect if the server timeout on us. This is not the right
approach and does not work well, fix later.
(message_operation): Check if selected is not null, first.
* mailbox/folder_imap.c (folder_imap_create): Wrong state.
* mailbox/mime.c: Pass down the return value if not ENOENT.
2001-05-30 Dave Inglis
* mailbox/mbx_pop.c (CHECK_ERROR): Force the mailbox to call connect
again when an error occurred. For example the QPopper(Qalcomm) POP3
server timeout very quickly, 30 seconds violating the RFC. So when
Readin the stream again we reconnect.
2001-05-30 Dave Inglis
* mailbox/filter_trans.c (base64_decode): The variable should
be unsigned char not signed char. By default gcc treats a
declaration of "char*" like "signed char*", CC Watcom did not.
(base64_encode): Likewise.
* mailbox/mime.c: Read 'itl the end of the stream.
2001-05-29 Sergey Poznyakoff
* imap4d/uid.c, imap4d/search.c: support for UID SEARCH command;
* imap4d/util.c: forgotten fix to util_msgset().
2001-05-27 Sergey Poznyakoff
* imap4d/search.c: Added missing <message set> condition.
2001-05-27 Sergey Poznyakoff
* imap4d/imap4d.c, imap4d/capability.c, imap4d/copy.c,
imap4d/create.c, imap4d/delete.c, imap4d/imap4d.h,
imap4d/list.c, imap4d/rename.c, imap4d/select.c,
imap4d/status.c, imap4d/namespace.c (added):
implemented NAMESPACE (rfc2342) support
* imap4d/util.c:
added util_normalize_path() function.
util_msgset() bailed out at 1:1 -- fixed.
Added util_parse_internal_date(), util_parse_header_date(),
util_parse_rfc822_date().
* imap4d/bye.c: typo in diagnostic output
* imap4d/noop.c: issue unsolicited response (as per rfc2060)
* imap4d/select.c: ditto
* imap4d/store.c: set MU_ATTRIBUTE_MODIFIED on a message, so
expunge will know it was modified.
* imap4d/search.c: implemented. Charsets other than US-ASCII are
not supported, though.
2001-05-27 Sam Roberts
* mailbox/address.c: removed unfolding of lines at a NL before parsing.
* mailbox/parse822.c: consider LF and CRLF equivalent for purposes
of unfolding lines.
2001-05-23 Alain Magloire
* mailbox/mbx_default.c (mailbox_create_default): Check
for URL in the mailbox name.
2001-05-23 Dave Inglis
* mailbox/mime.c (_mimepart_body_read): Use stream_is_seekable()
to detect if the stream is POP for example and read 'til the end.
(mime_get_part): Reuse the stream the original stream flags on the
newly created message.
Fix and patches provided by Dave Inglis.
2001-05-23 Sergey Poznyakoff
* pop3d/user.c: check for NULL return from getpwnam()
* imap4d/login.c: Likewise.
2001-05-21 Alain Magloire
GNU md5 is GPL, but we agreed that the libraries should
fall under LGPL.
Same goes for basename() and pretty much everything under
lib/*.[ch]
* mailbox/message.c (message_get_uidl): Remove the dependency
from GNU md5.
* mailbox/md5-rsa.c: New File.
* mailbox/md5-rsa.h: New File.
* mailbox/attachment.c (message_create_attachment): Remove
the dependency from lib/basename.c
* mailbox/mbx_mbox.c (mbox_tempfile): Remove
the dependency from lib/basename.c
* lib/signame.c: Replace in favor of the well-known strsignal().
* lib/strsignal.c: New file, use the mu_signame() written by
Sergey.
* pop3d/signal.c: Use strsignal() unconditionally.
* imap4d/signal.c: Use strsignal() unconditionally.
* configure.in: autoconf-2.50 is having difficulty parsing
a long AC_CHECK_LIB, break it in two.
Check for strsignal()
* doc/auth.texi: Bug fixes in texinfo.
* doc/Makefile.am: Commented the ex-address.texi generation.
* doc/ex-address.texi: New file.
2001-05-21 Alain Magloire
* configure.in, imap4d/signal.c, pop3d/signal.c:
sys_siglist is not defined on some systems (namely, Solaris).
* lib/signame.c: (added) Provide mu_signame() function to convert
signal number to string representation.
* lib/strtok_r.c: bugfix
2001-05-19 Alain Magloire
* AUTHORS: Update to reflect Sergey and Sam contributions.
2001-05-20 Sergey Poznyakoff
* mailbox/mbx_mboxscan.c:* Bug in mailbox/mbx_mboxscan.c made the
stuff coredump upon encountering more than one subject in the header.
* pop3d/pop3d.c: Typo.
2001-05-19 Sam Roberts
* mailbox/parse822.c: parse822 is a little smarter in the way
it handles CRLF.
2001-05-19 Alain Magloire
* mailbox/mbx_default (mailbox_create_default): Base on a
suggestion/patch by Sam Roberts to provide tilde, plus and equal
(~ + = ) expansion.
* mailbox/address.c: Unfold field-bodies with NL.
* mailbox/parse822.c (parse822_field_body): New function.
(parse822_field_name): New function.
* pop3d/user.c: Use mailbox_create() now instead of
mailbox_create_default.
* pop3d/apop.c: Likewise.
2001-05-16 Dave Inglis
* mailbox/mime.c (_mime_parse_mpart): Better check for the
boundary.
2001-05-14 Sergey Poznyakoff
* pop3d/user.c: After unsuccessful authorization frees cmd twice,
2001-05-13 Alain Magloire
* imap4d/fetch.c: Lots of bug fixing. To many to enumerate.
* imap4d/imap4d.h: New prototypes.
* imap4d/login.c: syslog() the user.
* imap4d/select.c: Remove the call to mailbox_create_default.
* imap4d/util.c (util_getitem): New function.
(util_send_qstring): New function.
(util_send_literal): New function.
* mailbox/address.c: Parse822 can not handle '\n' inside
the buffer, prune them out before.
* mailbox/mime.c (_mime_parse_mpart_message): The mime->stream
was destroy when doing mime_get_part () better get it every time.
(_mime_body_fd): Likewise.
* mailbox/smtp.c: Do not close the stream on destroy.
2001-05-11 Alain Magloire
* imap4d/fetch.c: More cleanup in the bodystructure code,
arrange response indentation etc ...
* impa4d/utils.c (util_send_string): New helper function.
2001-05-10 Alain Magloire
* imap4d/fetch.c: Implemented INTERNALDATE.
* mailbox/mbx_imap.c (imap_envelope_date): ctime() always
append a newline, nuke it.
* mailbox/stream.c (stream_read): If the amount requested is bigger
then the buffer cache size, bypass the buffering mechanism.
2001-05-09 Alain Magloire
Take the missing pieces from the pop3d and make the
imap4d a standalone daemon.
* imap4d/fetch.c: Remove fetch_body_peek().
and use fetch_body() instead.
(fetch_operation): Malloc the entire message... not good.
* imap4d/bye.c: New file.
* imap4d/imap4d.c: Put the networking code taken from
pop3d.c.
* imap4d/lsub.c: Implemented.
* imap4d/subscribe.c: Implemented.
* imap4d/unsubscribe.c: Implemented.
* pop3d/pop3d.c: pop3d_usage() move from extra.c
* pop3d/signal.c: pop3d_signal () move from extra.c
* mailbox/url_imap.c: It was not checking for the port number.
* mailbox/filter_rfc822.c: Check for the lines if available.
2001-05-07 Alain Magloire
Now we can have multiple access to the mailbox and the server
will update the mailbox and send the unsolicited responses.
This is implemented in imap4d/sync.c.
* imap4d/copy.c: Move the code into imap4d_copy0() to allow
the use of UID COPY.
(imaprd_copy0): New function.
* imap4d/fetch.c: Define a new structure command for FETCH.
(fetch_getcommand): New function.
(imap4d_fetch0): New function to allow the use of UID COPY.
(fetch_envelope0): New function to permit to reuse the function
in bodystructure.
(fetch_bodystructure): Implemented.
(fetch_bodystructure0): The implementation.
(bodystructure): The helper function for fetch_bodystructure.
* imap4d/imap4d.c (imap4d_mainloop): call imap4d_sync() in the
mainloop. Now use FILE *ifile.
* imap4d/imap4d.h: Update prototypes. Define ERR_NO_MEM and
ERR_NO_OFILE.
* imap4d/select.c (imap4d_select0): Call imap4d_sync() to update.
* imap4d/store.c (ima4d_store): Cal imap4d_sync_flags() to
update the flags in the uid_table.
* imap4d/uid.c: Implemented.
* imap4d/util.c (imap4d_readline): Use fgets() and deal
with literals send from the client.
* imap4d/sync.c: New file.
* include/mailutils/header.c: Added some new headers.
* mailbox/attribute.c (attribute_copy): Do a shallow copy.
* mailbox/file_stream.c: Check if FILE * is null in all functions.
* mailbox/mailbox.c (mailbox_is_updated): Should not return ENOSYS
but rather 1.
2001-05-07 Sam Roberts
* mailbox/parse822.c: Now allow a unix mailbox in an address.
* include/mailutils/parse822.h: Declare the function to parse them.
* doc/address.texi: Document the fact.
* doc/Makefile.am: Automatically build the example code from addr.c.
* examples/addr.c: And update the parser test.
* examples/Addrs.good: Update the parser test.
2001-05-03 Sam Roberts
* mail/mail.c: Typo
2001-05-03 Alain Magloire
* argp/argp-help.c (hol_entry_help): Some compiler like Watcomm
can not initialize a local structure struct .. = { .. }. Do it
explicitly field by field.
* argp/arpg-parse.c: Watcomm choke on N_() macro.
(parser_init): Watcomm does not like operation on a void * pointer.
* imap4d/login.c: Cast the return of crypt(), since some platforms
do not provide a prototype in <unistd.h>
* pop3d/user.c: Cast the return of crypt(), since in may not be
declare in <unistd.h>.
* lib/snprintf.c: Use only __STDC__ to detect <stdarg.h>
* lib/snprintf.h: Use only __STDC__.
* mail/mail.h: The global variable should be declare extern.
* mail/pipe.c: Use 512 buffer instead of BUFSIZ, go easy on the stack.
* mail/print.c: Use 512 buffer instead of BUFSIZ, go easy on the stack.
* mail/write.c: Use 512 buffer instead of BUFSIZ, go easy on the stack.
* mailbox/folder_imap.c: Declare strtock_r ().
2001-05-03 Sergey Poznyakoff
* pop3d/user.c: Misplace parentheses around the mailbox_xx() calls.
Do not free (buf) since it is now static storage. Unfortunately most
of the pam modules do openlog() on their own, thus after
authentication all logging output flows to where the last pam module
has directed it, which is usually `auth' facility.
Put back closelog()/openlog().
* pop3d/pop3d.h: ifile is now FILE *.
pop3d_realine () take FILE * as a prototype.
* pop3d/pop3d.c (pop3d_mainloop): Refresh lock, pop3d_touchlock().
Register SIGALRM in the child.
Do not free (buf) since it is now static storage.
* pop3d/extra.c (pop3d_readline): Change to use
fgets () and alarm ().
With small modification from Alain.
(pop3d_signal): ofile will be NULL in the *child* process:
whereas in the parent one, ofile will always be NULL, since it lives
in the BSS (FILE *ofile;) and gets initialized only in the child
process. Thus, when the parent receives any signal, SIGTERM for
example, it does pop3d_abquit(ERR_SIGNAL) and dies doing
fprintf(ofile, ...)
2001-05-02 Alain Magloire
Some of the Makefile.am contain gcc specific options
like -Wall, -pedantic or -ansi remove them.
* configure.in: Check for stdarg and sysconf.
* mailbox/mime.c (_mime_set_content_type): Delayed the
creation of the header-field content-type until the message
is requested via mime_get_message().
* pop3d/lock.: new File to implement the locking.
* pop3d/apop.c: Rearrange the code around the #ifdefs
to be clearrer.
Make sure that when we use strncpy() that the buffer is
null terminated. Added the locking propose by Sergey to apop.
* pop3d/capa.c: Announce we support PIPELINING.
* pop3d/extra.c (pop3d_abquit): Remove ERR_DEAD_SOCK.
Remove the extra fflush(), the call to exit() always
flush the buffers.
(pop3d_readline): Implement PIPELINING.
* pop3d/pop3d.c: Remove the typedef struct sockaddr SA
for more clarity since it is not use that often.
port is not longer a global variable.
children should have the volatile qualification.
2001-04-29 Alain Magloire
* pop3d/extra.c (pop3d_readline): Modify the loop to be able
to support PIPELINING.
* pop3d/capa.c: Advertise that we support PIPELINING.
2001-04-29 Sergey Poznyakoff
Return values of all signal handlers are changed to RETSIGTYPE
and configure.in is modified accordingly. This is more portable.
* configure.in: New Macro AC_TYPE_SIGNAL.
* mailbox/locker.c (locker_lock): while trying to read pid value
from the pidfile passed wrong buffer length to read() call, namely:
read(fd, buf, sizeof (pid_t)).
2001-04-29 Sergey Poznyakoff
I have modified locker.c to implement reference count. The
struct _locker is now:
struct _locker { int fd; int refcnt; char *fname; int flags; };
The refcnt member gets incremented each time locker_lock is called and
decremented each time locker_unlock is called. Actual locking is
performed only if refcnt == 0 on entry to locker_lock. Similarly,
unlocking is performed only when refcnt gets decremented to 0 by
locker_unlock. Also I have added basic support for NFS-secure
locking.
* mailbox/locker.c: Reference count implementation.
2001-04-25 Alain Magloire
* imap4d/store.c: First implementation.
* mailbox/attribute.c (attribute_unset_flags): New function.
2001-04-23 Sergey Poznyakoff
* mailbox/mbx_mbox.c (mbx_expunge): It assumes that mbox_get_message()
will place the pointer to message into mum->message member. But
mbox_get_message() relies on 1-based message numbers, whereas `mum'
pointer is obtained using 0-based indexing.
2001-04-23 Alain Magloire
Sergey Poznyakoff noted: When the user's mailbox has zero size, mmap
fails on Solaris. On GNU/Linux it return NULL buf subsequent munmap
fails.
* mailbox/mapfile_stream.c: To take care of this, mfs->ptr is set
to NULL for len == 0;
*mailbox/mbx_mbox.c (mbox_is_updated): Should I have return 0 (FALSE)
when size change.
2001-04-23 Sergey Poznyakoff
Several sources from mailbox subdirectory call fprintf(stderr,...)
to issue error messages. As the stderr usually gets connected to
the output socket, the client program receives all these error
messages and gets confused, since they do not start with
rfc-compliant +OK, -ERR keywords. So I have added a module
error.c and changed all these fprintf's to error()'s. Actual
function that ouputs the messages can be supplied by the
application using error_set_print() call.
2001-04-23 Alain Magloire
* pop3d/*.[ch]: Rename all the pop function pop3d_xx()
instead of pop3_xx() to be consistent with imap4d/*.
* mailbox/mbx_pop.c (pop_user): This is sudden death; for many pop
servers, it is important to let them time to remove locks or move
the .user.pop files. This happen when we do BUSY_CHECK(). For
example, the user does not want to read the entire file, and wants
start to read a new message, closing the connection and immediately
contact the server again, and we'll end up having
"-ERR Mail Lock busy" or something similar. To prevent this race
condition we sleep 2 seconds.
2001-04-23 Sergey Poznyakoff
It is often convenient to separate log outputs from POP and SMTP
servers. --with-log-facility flag which allows to specify to which
log facility the logging output should be directed.
System administrators often prefer to have more information about
unsuccessful authentications. I have added more verbose logging
to pop3d/user.c. Both failed attempts and possible account probes
(USER immediately followed by QUIT) are logged.
Made pop3d to be less verbose about its WELCOME prompt. When the
symbol TERSE_MODE is defined, pop3d introduces itself just as
+OK POP3 ready <apop_hash>
instead of divulging its type and version. This is a bit paranoid,
but it is better to be on the safe side...
* configure.in: ARGPINC gets assigned a relative path, due
to which the compilation fails if the package is configure with
--srdir=<path> option.
* configure.in: --with-log-facility new option.
* acconfig.h: LOG_FACILITY
* doc/mailutils.texi: Typo.
* mailbox/mapfile_stream.c: Define MAP_FAILED.
* pop3d/extra.c (pop3_abquit): new case ERR_MBOX_SYNC.
(pop3_signal): Syslog the reason.
* pop3d/pop3d.c (pop_mainloop): Syslog the hostname of
the user on connect.
(pop3_daemon): Log to many children. Lacks call to exit(), so if
pop3d is run as a daemon, any child after exiting from
pop3_mainloop tries to accept() from already closed socket
and issues spurious error messages.
(pop3_mainloop): Check if the mailbox is uptodate if not
and the size shrink, bail out. Do not send version number.
* pop3d/pop3d.h: ERR_MBOX_SYNC define. WELCOME removed.
* pop3d/signal (pop3_sigchld): Lacks signal() call, due to which
the signal handler gets cleared after first SIGCHLD and all
subsequent children, when finished, just hang around like zombies.
* pop3d/user.c: Log to LOG_FACILITY all the errors.
2001-04-23 Alain Magloire
Sergey Poznyakoff pointed out that errno changes depending
if _REENTRANT is set or not. So for enable thread we take
the approach of always defining _REENTRANT.
He also noted that when in standalone the child was not exiting.
* acconfig.h: Define _REENTRANT.
* configure.in: Check for sigaction().
* configuire.in: AC_DEFINE(_REENTRANT).
* doc/Makefile.am: add rfc2060-errata.
* doc/rfc2060-errata: New File.
* imap4d/copy.c: First Implementation.
* imap4d/status.c: First implementation.
* mailbox/file_stream.c (_file_open): For CREAT, close
the fd if we failed.
* mailbox/folder_imap.c: Remove the _REENTRANT.
* mailbox/mbx_mbox.c: Remove the _REENTRANT.
* mailbox/monitor.c: Remove the _REENTRANT.
* pop3d/pop3d.c (main): maxchildren boosted to 20.
(pop3_daemon_init): Use sigaction() for SIGCHLD,
the semantics of signal() is unreliable on some platforms.
* pop3d/signal.c: Save errno.
2001-04-22 Alain Magloire
* imap4d/create.c: First implementation.
* imap4d/delete.c: First implementation.
* imap4d/list.c: First implementation.
* imap4d/rename.c: First implementation.
* imap4d/util.c: New functions.
(util_tilde_expansion): expand ~.
(util_unquote): Remove surrounding double quotes.
(util_getfullpath): Expand the path to absolute.
* imap4d/fetch.c: Did not cycle through the items.
(fetch_send_address): Patch from Sam Roberts, did not
use the index.
* mailbox/attachement.c (message_unencapsulate): Little buglet
strncasemp() passing the wrong size.
2001-04-19 Alain Magloire
* mailbox/smtp.c(smtp_readline): Because of the buffering mechanism,
we must maintain the offset.
* imap4d/list.c: partially implemented the LIST command.
* imap4d/imap4d.c: homedir new global variable.
* imap4d/login.c: same ${HOME} in homedir.
* imap4d/util.c (util_getword): Be aware of the quotes.
* lib/fnmatch.c: New replacement file.
* lib/fnmatch.h: New replacement file.
* configure.in: Check for fnmatch().
2001-04-18 Alain Magloire
Finally took time to put the code in from Jakob first draft, in
an email excerpt:
states is the valid states for a command (eg. LOGIN is only valid in
non-authenticated state, SELECT is valid in authenticated or
selected). success is the state to enter when the command completes
successfully (STATE_NONE means no change) and failure is the state to
enter when the command fails.
* imap4d/*.c: All the commands check there state.
* imap4d/fetch.c: Cleanup the fetch code, and broke
the fetch_operation() routine in multiple routines.
(fetch_message): New function.
(fetch_header): Likewise
(fetch_content): Likewise
(fetch_io): Likewise
(fetch_header_fields): Likewise
(fetch_header_fields_not): Likewise
(fetch_send_address): Likewise
* mailbox/header.c: Some functions were useful while
programming the imap server, put them here.
(header_aget_value): New function.
(header_aget_field_name): New function.
(header_aget_field_value): New function.
* mailbox/memory_stream.c: New file, implemented a
malloc() buffer that you can access via the stream interface.
* mailbox/file_stream.c: Remove spurious checks.
* mailbox/mapfile_stream.c: Remove spurious checks.
(_mapfile_read): check if there is no newline left.
2001-04-16 Alain Magloire
To get things to compile on Solaris, change configure to check
for -lpthread since in libc the thread functions are defined
but all return ENOSYS, you need to explicitly link with -lphtread.
the ctype functions is*() arguments should be explicitly cast
since Solaris use them as indexes. __REENTRANT as to be define
if compile with support for threads. Never realize this but
setenv() is a BSD/GNU thing, so took a variant from libiberty
to cope.
* configure.in: Check for setenv. First check if -lphtread is ok.
* lib/setenv.c: New functions.
* lib/Makefile.am: add setenv.c in EXTRA_DIST.
* imap4d/imap4d.h: Include <alloca.h>
* mailbox/attachment.c: Include <alloca.h>
* (_header_get_param): isspace() cast argument.
* mail/mail.h: check if <paths.h> is available if not
define _PATH_SENDMAIL=/usr/lib/sendmail.
* mailbox/folder_imap.c: if pthread available, define _REENTRANT.
Include <alloca.h>.
(imap_bodystructure0): isdigit() cast argument.
* mailbox/mbx_mbox.c: if pthread available, define _REENTRANT.
Include <alloca.h>.
* mailbox/parse822.c: isdigit() cast argument unsigned.
2001-04-15 Alain Magloire
The FILE* stream "stdout" is not an lvalue so it is an error to
attempt to assign to it. To be able to redirect at will stdout
we need to assign it. In GNU lib C, it was not error since stdout
stderr, and stdin are variables, but to be portable we can not
assume this. The way out is to always use fprintf () and have
a global variable "ofile" pointing to stdout.
* mail/*: All the files under mail been change to use fprintf()
and ofile as the default stdout.
Copyright updated.
2001-04-15 Alain Magloire
Create a argp directory, it contains the necessary
files to build a standalone libargp.a
* argp: New directory.
argp-ba.c, argp-eexst.c, argp-fmtstream.c, argp-fmtstream.h
argp-fs-xinl.c, argp-help.c, argp-namefrob.h, argp-parse.c
argp-pv.c, argp-pvh.c, argp-xinl.c, argp.h, pin.c.
* mail/mail.c: Comment out the code that use readline
specifics WITH_READLINE.
* mail/mail.h: Likewise.
* mail/util.c: Likewise.
2001-04-15 Alain Magloire
* Makefile.am: Add argp in the list of subdirs.
* configure.am: Check for argp.h and look for
argp_parse().
* lib/strchrnul.c: New function.
* lib/strndup.c: New function.
* lib/strnlen.c: New function.
* lib/vasnprintf.c: New function.
* lib/getopt.c: Updated.
* lib/getopt1.c: Updated.
* lib/getopt.h: Updated.
* frm/Makefile.am: Remove -DTESTING in CFLAGS.
* from/Makefile.am: Remove -DTESTING in CFLAGS.
Add AUTOMAKE_OPTIONS.
* imapd/Makefile.am: Likewise.
* pop3d/Makefile.am: Likewise.
* mail/Makefile.am: Likewise. Added ARGPLIB macro
2001-04-14 Sam Roberts
* examples/{Makefile,Addrs,addr.c,Addrs.good}: address test f/w.
* include/mailutils/address.h,mailbox/{address.c,parse822.c}: now
stuff a group name into an _address, and added a function to do
a quick check if it is a group.
* mailbox/parse822.c: fixed bug where ",sam@foo.bar" wasn't valid.
2001-04-14 Alain Magloire
* mailbox/folder_imap.c: When calling imap_writeline () the
cookie for the tag should be unsigned %d --> %u.
(imap_send) : The number of bytes in memmove was wrong.
* mailbox/mbx_imap.c: Some duplicate debug calls MAILBOX_DEBUG0()
removed.
(attribute_string): IMAP does not have a \\Read flag it should be
the same as \\Seen so attribute_read() == attribute_seen().
(flag_string): New function.
(imap_attr_set_flags): Use flag_string(), instead.
* mailbox/include/imap0.h: CLEAR_STATE() should also deselect
the current mailbox.
* mailbox/mbx_pop.c (pop_write): The number of bytes in the memmove
was wrong.
* imap4d/imap4d.h: Add HAVE_SECURITY_PAM_APPL_H.
* imap4d/login.c: PAM_ERROR wrongly define.
* imap4d/expunge.c: Initialize variable sp.
* imap4d/logout.c: Initialize variable sp.
* imap4d/noop.c: Initialize variable sp.
* mailbox/attachement.c (message_create_attachment): Use base_name().
* mailbox/mbx_mbox.c (mbox_tmpfile): Use base_name().
* configure.in: AC_REP_FUNC(vasprintf strcasecmp strncasecmp).
* include/mailutils/Makefile.am: Add property.h, parse822.h.
* lib/vasprintf.c: Taken from libit.
* lib/basename.c: Taken from libit/fileutils.
* lib/Makefile.am.c: Always use our basename(base_name).
(AM_INIT_AUTOMAKE): Change version to 0.0.9
2001-04-13 Sam Roberts
QNX needed to include <strings.h> for many of the useful string
functions also to define _QNX_SOURCE so <sys/time.h> doesn't have
an internal warning.
* configure.in: Check for libgen.h.
* imap4d/imap4d.h: Define __QNX_SOURCE.
* mailbox/mime.c: wasn't including config.h
* mailbox/attachment.c: QNX needed libgen.h for basename(),
include <strings.h> if define.
* mailbox/filter.c: Include <strings.h>.
* mailbox/mbx_mbox.c: Include <strings.h>.
* mailbox/folder_imap.c: Include <strings.h>.
* mailbox/header.c: Include <strings.h>.
* mailbox/property.c: Include <strings.h>.
* mailbox/registrar.c: Include <strings.h>.
* mailbox/url.c: Include <strings.h>.
* mailbox/url_pop.c: Include <strings.h>.
* pop3d/user.c: QNX says getspnam(char* n), I cast away the error.
2001-04-13 Sam Roberts
* mailbox/parse822.c, include/mailutils/parse822.h: now can
quote the local-part of and addr-spec, and a string.
2001-04-13 Sam Roberts
* doc/address.texi: updated docs, now they match the parse822.
* mailbox/parse822.c: small tweaks to the new parser, the changes
made during the tidying over the last month were:
- use C comments only.
- don't use C++ reserved words.
- fix is_digit() to be like the other is functions
- Changed return codes to:
. no mem (ENOMEM)
. function wasn't called correctly, usually a missing
argument (EINVAL)
. invalid syntax found during parsing (ENOENT)
. success == 0
- const-corrected the APIs
- removed unnecessary (in C) casts.
- mailbox_t* removed in favor of address_t.
- fix handful of memory leaks detected by Alain.
2001-04-10 Alain Magloire
* pop3d/retr.c (pop3_retr): Typo.
* pop3d/top.c (pop3_top): No need to reallocate when sending the
headers.
* doc/mailbox.texi: Put the functions in alphabetic orders.
2001-04-10 Alain Magloire
* mailbox/Makefile.am: filter_trans.c added, trans_stream.c deleted.
* mailbox/attachment.c (message_create_attachment): use
filter_create().
(message_save_attachment): use filter_create().
* mailbox/body.c (body_set_lines): Wrong comparison for the owner.
* mailbox/mbx_mbox.c: Do not count the line separator of part
of the mailbox.
* mailbox/url.c (url_is_same_scheme): New function.
(url_is_same_user): New function.
(url_is_same_path): New function.
(url_is_same_host): New function.
(url_is_same_port): New function.
* mailbox/folder.c : Moved the is_same_*() functions in url.c
they can be generally useful.
(is_same_scheme): Removed.
(is_same_user): Removed.
(is_same_path): Removed.
(is_same_host): Removed.
(is_same_port): Removed.
* mailbox/folder_imap.c (folder_imap_create): New function,
CREATE a new mailbox.
(folder_imap_open): Calls folder_imap_create when the MU_STREAM_CREAT
flag is set.
* mailbox/mbx_imap.c: Appending messages implemented, if the message
comes from the same imap folder, it is COPY otherwise APPEND.
(is_same_folder): New function.
(imap_append_message): Implemented.
(attribute_string): New functions.
(imap_copy_message): New function.
* mailbox/include/imap0.h: New enum, IMAP_APPEND, IMAP_APPEND_ACK,
IMAP_APPEND_CONT, IMAP_APPEND_SEND, IMAP_COPY, IMAP_COPY_ACK,
IMAP_CREATE, IMAP_CREATE_ACK.
2001-04-06 Alain Magloire
* mailbox/parse822.c: New parser.
* include/mailutils/parse822.h: New file.
* mailbox/address.c (address_create): Remove the old parsing and use
parse822 as the underlying engine.
(address_parse): Removed.
(gettoken): Removed.
(quotes): Removed.
(address_get_personal): Remove the code to unquote, parse822 takes
care if it. Return value when no field is ENOENT.
(address_get_comments): Return value when no field ENOENT.
(address_get_local_part): Return value when no field ENOENT.
(address_get_domain): Return value when no field ENOENT.
(address_get_email): Return value when no field ENOENT.
(address_get_route): Return value when no field ENOENT.
* mailbox/message.c (message_sender): Use parse822 to retrieve
the email from the From: field.
(message_set_mailbox): New function.
* mailbox/misc.c : Removed the old parsing code.
(gettoken): Removed.
(parseaddr): Removed.
* mailbox/include/misc.h : Removed parseaddr() prototypes.
From Sam Roberts, the new parse822 parser..
2001-04-04 Alain Magloire
Introduction of the notion of filter_t object takes a stream and
perform some filtering on it. All the decoding streams will move
to this i.e. quoted-printable, base64 etc .. This scheme will also
permit users to add to the list new filters. Still work in progress.
* mailbox/Makefile.am : Add filter.c filter_rfc822.c.
* mailbox/body.c : When creating a floating body i.e creating
a temporary file, the stream was not "own" by the body_t.
(_body_get_fd): Likewise.
(_body_read):_ Likewise.
(_body_readline): Likewise.
(_body_write): Likewise.
(_body_truncate): Likewise.
(_body_size): Likewise.
(_body_flush): Likewise.
* mailbox/folder_imap.c (imap_literal_string): Check if the
callback.buffer is NULL.
(imap_body): Do no set the callback.type if "FIELDS" is part of the
string.
* mailbox/header.c: Remove the support for RFC822 it will be part
of the filter_t object.
* mailbox/mbx_mbox.c: Likewise.
* mailbox/mailbox.c (mailbox_size): Rename to mailbox_get_size().
* mailbox/stream.c (stream_is_seekable): New function.
(stream_set_property): New function.
(stream_get_property): New function.
* mailbox/trans_stream.c: Beautify.
* include/mailutils/filter.h: new file.
* doc/mailbox.texi: Updated.
More changes to come.
2001-03-20 Alain Magloire
* mailbox/folder_imap.c (imap_readline) : If the server goes away
suddenly return an error.
* mailbox/smtp.c (smtp_readline) : If the server goes away
suddenly return an error.
* mailbox/mbx_pop.c (pop_readline) : If the server goes away suddenly
return an error.
* mailbox/mbx_pop.c (pop_open) : The ticket comes from the folder.
2001-03-17 Vesselin Atanasov
* configure.in: AC_REQUIRE is not .. required. Just call
jm_FUNC_MALLOC and jm_FUNC_REALLOC.
2001-03-17 Alain Magloire
Clean the property object, mailbox and mailer have property object
that you can examine. Still a draft: the value of objects are ints.
This feature was put in to help the imap4d server, in this protocol
you can get a substring of the message starting from a certain offset.
To make the coding of imap4d simpler the complexity was move to the
* mailbox/smtp.c(smtp_readline): Because of the buffering mechanism,
we must maintain the offset.
* imap4d/list.c: partially implemented the LIST command.
* imap4d/imap4d.c: homedir new global variable.
* imap4d/login.c: same ${HOME} in homedir.
* imap4d/util.c (util_getword): Be aware of the quotes.
* lib/fnmatch.c: New replacement file.
* lib/fnmatch.h: New replacement file.
* configure.in: Check for fnmatch().
2001-04-18 Alain Magloire
Finally took time to put the code in from Jakob first draft, in
an email excerpt:
states is the valid states for a command (eg. LOGIN is only valid in
non-authenticated state, SELECT is valid in authenticated or
selected). success is the state to enter when the command completes
successfully (STATE_NONE means no change) and failure is the state to
enter when the command fails.
* imap4d/*.c: All the commands check there state.
* imap4d/fetch.c: Cleanup the fetch code, and broke
the fetch_operation() routine in multiple routines.
(fetch_message): New function.
(fetch_header): Likewise
(fetch_content): Likewise
(fetch_io): Likewise
(fetch_header_fields): Likewise
(fetch_header_fields_not): Likewise
(fetch_send_address): Likewise
* mailbox/header.c: Some functions were useful while
programming the imap server, put them here.
(header_aget_value): New function.
(header_aget_field_name): New function.
(header_aget_field_value): New function.
* mailbox/memory_stream.c: New file, implemented a
malloc() buffer that you can access via the stream interface.
* mailbox/file_stream.c: Remove spurious checks.
* mailbox/mapfile_stream.c: Remove spurious checks.
(_mapfile_read): check if there is no newline left.
2001-04-16 Alain Magloire
To get things to compile on Solaris, change configure to check
for -lpthread since in libc the thread functions are defined
but all return ENOSYS, you need to explicitly link with -lphtread.
the ctype functions is*() arguments should be explicitly cast
since Solaris use them as indexes. __REENTRANT as to be define
if compile with support for threads. Never realize this but
setenv() is a BSD/GNU thing, so took a variant from libiberty
to cope.
* configure.in: Check for setenv. First check if -lphtread is ok.
* lib/setenv.c: New functions.
* lib/Makefile.am: add setenv.c in EXTRA_DIST.
* imap4d/imap4d.h: Include <alloca.h>
* mailbox/attachment.c: Include <alloca.h>
* (_header_get_param): isspace() cast argument.
* mail/mail.h: check if <paths.h> is available if not
define _PATH_SENDMAIL=/usr/lib/sendmail.
* mailbox/folder_imap.c: if pthread available, define _REENTRANT.
Include <alloca.h>.
(imap_bodystructure0): isdigit() cast argument.
* mailbox/mbx_mbox.c: if pthread available, define _REENTRANT.
Include <alloca.h>.
* mailbox/parse822.c: isdigit() cast argument unsigned.
2001-04-15 Alain Magloire
The FILE* stream "stdout" is not an lvalue so it is an error to
attempt to assign to it. To be able to redirect at will stdout
we need to assign it. In GNU lib C, it was not error since stdout
stderr, and stdin are variables, but to be portable we can not
assume this. The way out is to always use fprintf () and have
a global varialbe "ofile" pointing to stdout.
* mail/*: All the files under mail been change to use fprintf()
and ofile as the default stdout.
Copyright updated.
2001-04-15 Alain Magloire
Create a argp directory, it contains the necessary
files to build a standalone libargp.a
* argp: New directory.
argp-ba.c, argp-eexst.c, argp-fmtstream.c, argp-fmtstream.h
argp-fs-xinl.c, argp-help.c, argp-namefrob.h, argp-parse.c
argp-pv.c, argp-pvh.c, argp-xinl.c, argp.h, pin.c.
* mail/mail.c: Comment out the code that use readline
specifics WITH_READLINE.
* mail/mail.h: Likewise.
* mail/util.c: Likewise.
2001-04-15 Alain Magloire
* Makefile.am: Add argp in the list of subdirs.
* configure.am: Check for argp.h and look for
argp_parse().
* lib/strchrnul.c: New function.
* lib/strndup.c: New function.
* lib/strnlen.c: New function.
* lib/vasnprintf.c: New function.
* lib/getopt.c: Updated.
* lib/getopt1.c: Updated.
* lib/getopt.h: Updated.
* frm/Makefile.am: Remove -DTESTING in CFLAGS.
* from/Makefile.am: Remove -DTESTING in CFLAGS.
Add AUTOMAKE_OPTIONS.
* imapd/Makefile.am: Likewise.
* pop3d/Makefile.am: Likewise.
* mail/Makefile.am: Likewise. Added ARGPLIB macro
2001-04-14 Sam Roberts
* examples/{Makefile,Addrs,addr.c,Addrs.good}: address test f/w.
* include/mailutils/address.h,mailbox/{address.c,parse822.c}: now
stuff a group name into an _address, and added a function to do
a quick check if it is a group.
* mailbox/parse822.c: fixed bug where ",sam@foo.bar" wasn't valid.
2001-04-14 Alain Magloire
* mailbox/folder_imap.c: When calling imap_writeline () the
cookie for the tag should be unsigned %d --> %u.
(imap_send) : The number of bytes in memmove was wrong.
* mailbox/mbx_imap.c: Some duplicate debug calls MAILBOX_DEBUG0()
removed.
(attribute_string): IMAP does not have a \\Read flag it should be
the same as \\Seen so attribute_read() == attribute_seen().
(flag_string): New function.
(imap_attr_set_flags): Use flag_string(), instead.
* mailbox/include/imap0.h: CLEAR_STATE() should also deselect
the current mailbox.
* mailbox/mbx_pop.c (pop_write): The number of bytes in the memmove
was wrong.
* imap4d/imap4d.h: Add HAVE_SECURITY_PAM_APPL_H.
* imap4d/login.c: PAM_ERROR wrongly define.
* imap4d/expunge.c: Initialize variable sp.
* imap4d/logout.c: Initialize variable sp.
* imap4d/noop.c: Initialize variable sp.
* mailbox/attachement.c (message_create_attachment): Use base_name().
* mailbox/mbx_mbox.c (mbox_tmpfile): Use base_name().
* configure.in: AC_REP_FUNC(vasprintf strcasecmp strncasecmp).
* include/mailutils/Makefile.am: Add property.h, parse822.h.
* lib/vasprintf.c: Taken from libit.
* lib/basename.c: Taken from libit/fileutils.
* lib/Makefile.am.c: Always use our basename(base_name).
(AM_INIT_AUTOMAKE): Change version to 0.0.9
2001-04-13 Sam Roberts
QNX needed to include <strings.h> for many of the useful string
functions also to define _QNX_SOURCE so <sys/time.h> doesn't have
an internal warning.
* configure.in: Check for libgen.h.
* imap4d/imap4d.h: Define __QNX_SOURCE.
* mailbox/mime.c: wasn't including config.h
* mailbox/attachment.c: QNX needed libgen.h for basename(),
include <strings.h> if define.
* mailbox/filter.c: Include <strings.h>.
* mailbox/mbx_mbox.c: Include <strings.h>.
* mailbox/folder_imap.c: Include <strings.h>.
* mailbox/header.c: Include <strings.h>.
* mailbox/property.c: Include <strings.h>.
* mailbox/registrar.c: Include <strings.h>.
* mailbox/url.c: Include <strings.h>.
* mailbox/url_pop.c: Include <strings.h>.
* pop3d/user.c: QNX says getspnam(char* n), I cast away the error.
2001-04-13 Sam Roberts
* mailbox/parse822.c, include/mailutils/parse822.h: now can
quote the local-part of and addr-spec, and a string.
2001-04-13 Sam Roberts
* doc/address.texi: updated docs, now they match the parse822.
* mailbox/parse822.c: small tweaks to the new parser, the changes
made during the tidying over the last month were:
- use C comments only.
- don't use C++ reserved words.
- fix is_digit() to be like the other is functions
- Changed return codes to:
. no mem (ENOMEM)
. function wasn't called correctly, usually a missing
argument (EINVAL)
. invalid syntax found during parsing (ENOENT)
. success == 0
- const-corrected the APIs
- removed unnecessary (in C) casts.
- mailbox_t* removed in favor of address_t.
- fix handful of memory leaks detected by Alain.
2001-04-10 Alain Magloire
* pop3d/retr.c (pop3_retr): Typo.
* pop3d/top.c (pop3_top): No need to reallocate when sending the
headers.
* doc/mailbox.texi: Put the functions in alphabetic orders.
2001-04-10 Alain Magloire
* mailbox/Makefile.am: filter_trans.c added, trans_stream.c deleted.
* mailbox/attachment.c (message_create_attachment): use
filter_create().
(message_save_attachment): use filter_create().
* mailbox/body.c (body_set_lines): Wrong comparison for the owner.
* mailbox/mbx_mbox.c: Do not count the line separator of part
of the mailbox.
* mailbox/url.c (url_is_same_scheme): New function.
(url_is_same_user): New function.
(url_is_same_path): New function.
(url_is_same_host): New function.
(url_is_same_port): New function.
* mailbox/folder.c : Moved the is_same_*() functions in url.c
they can be generally useful.
(is_same_scheme): Removed.
(is_same_user): Removed.
(is_same_path): Removed.
(is_same_host): Removed.
(is_same_port): Removed.
* mailbox/folder_imap.c (folder_imap_create): New function,
CREATE a new mailbox.
(folder_imap_open): Calls folder_imap_create when the MU_STREAM_CREAT
flag is set.
* mailbox/mbx_imap.c: Appending messages implemented, if the message
comes from the same imap folder, it is COPY otherwise APPEND.
(is_same_folder): New function.
(imap_append_message): Implemented.
(attribute_string): New functions.
(imap_copy_message): New function.
* mailbox/include/imap0.h: New enum, IMAP_APPEND, IMAP_APPEND_ACK,
IMAP_APPEND_CONT, IMAP_APPEND_SEND, IMAP_COPY, IMAP_COPY_ACK,
IMAP_CREATE, IMAP_CREATE_ACK.
2001-04-06 Alain Magloire
* mailbox/parse822.c: New parser.
* include/mailutils/parse822.h: New file.
* mailbox/address.c (address_create): Remove the old parsing and use
parse822 as the underlying engine.
(address_parse): Removed.
(gettoken): Removed.
(quotes): Removed.
(address_get_personal): Remove the code to unquote, parse822 takes
care if it. Return value when no field is ENOENT.
(address_get_comments): Return value when no field ENOENT.
(address_get_local_part): Return value when no field ENOENT.
(address_get_domain): Return value when no field ENOENT.
(address_get_email): Return value when no field ENOENT.
(address_get_route): Return value when no field ENOENT.
* mailbox/message.c (message_sender): Use parse822 to retrieve
the email from the From: field.
(message_set_mailbox): New function.
* mailbox/misc.c : Removed the old parsing code.
(gettoken): Removed.
(parseaddr): Removed.
* mailbox/include/misc.h : Removed parseaddr() prototypes.
From Sam Roberts, the new parse822 parser..
2001-04-04 Alain Magloire
Introduction of the notion of filter_t object takes a stream and
perform some filtering on it. All the decoding streams will move
to this i.e. quoted-printable, base64 etc .. This scheme will also
permit users to add to the list new filters. Still work in progress.
* mailbox/Makefile.am : Add filter.c filter_rfc822.c.
* mailbox/body.c : When creating a floating body i.e creating
a temporary file, the stream was not "own" by the body_t.
(_body_get_fd): Likewise.
(_body_read):_ Likewise.
(_body_readline): Likewise.
(_body_write): Likewise.
(_body_truncate): Likewise.
(_body_size): Likewise.
(_body_flush): Likewise.
* mailbox/folder_imap.c (imap_literal_string): Check if the
callback.buffer is NULL.
(imap_body): Do no set the callback.type if "FIELDS" is part of the
string.
* mailbox/header.c: Remove the support for RFC822 it will be part
of the filter_t object.
* mailbox/mbx_mbox.c: Likewise.
* mailbox/mailbox.c (mailbox_size): Rename to mailbox_get_size().
* mailbox/stream.c (stream_is_seekable): New function.
(stream_set_property): New function.
(stream_get_property): New function.
* mailbox/trans_stream.c: Beautify.
* include/mailutils/filter.h: new file.
* doc/mailbox.texi: Updated.
More changes to come.
2001-03-20 Alain Magloire
* mailbox/folder_imap.c (imap_readline) : If the server goes away
suddenly return an error.
* mailbox/smtp.c (smtp_readline) : If the server goes away
suddenly return an error.
* mailbox/mbx_pop.c (pop_readline) : If the server goes away suddenly
return an error.
* mailbox/mbx_pop.c (pop_open) : The ticket comes from the folder.
2001-03-17 Vesselin Atanasov
* configure.in: AC_REQUIRE is not .. required. Just call
jm_FUNC_MALLOC and jm_FUNC_REALLOC.
2001-03-17 Alain Magloire
Clean the property object, mailbox and mailer have property object
that you can examine. Still a draft: the value of objects are ints.
This feature was put in to help the imap4d server, in this protocol
you can get a substring of the message starting from a certain offset.
To make the coding of imap4d simpler the complexity was move to the
library. It is possible now by setting a property of the mailbox
to make it output rfc822 stream i.e. "\r\n" terminated stream, the
offset and the size are also in term of rfc822.
* mailbox/property.c (property_set_int): Removed.
* mailbox/property.c (property_set_long): Removed.
* mailbox/property.c (property_set_double): Removed.
* mailbox/property.c (property_set_set_value): Removed.
* mailbox/property.c (property_set_get_value): Removed.
* mailbox/property.c (property_add_property): New function.
* mailbox/property.c (hash): Renamed property_hash.
* include/mailutils/property.h (struct property_list): New structure.
* mailbox/include/mailbox0.h: new fields properties, properties_count.
* mailbox/mailbox.c (mailbox_get_property): The function will create
the propriety and add the default properties.
(mailbox_destroy): The default properties and property are freed.
(mailbox_is_updated): Return ENOSYS if the arguments are wrong.
(mailbox_scan): Return ENOSYS if the arguments are wrong.
(mailbox_uidvalidity): Return ENOSYS if the arguments are wrong.
(mailbox_uidnext): Return ENOSYS if the arguments are wrong.
* mailbox/mbx_mbox.c (mbx_init): Set its default properties.
(mbx_header_get_fvalue): Return the len, even if buffer is null.
(mbx_body_read): If property rfc822 is set call
mbx_body_readstream_rfc822 to the conversion.
(mbx_body_readstream_rfc822): New function, do the conversion.
(struct _mbox_message): Remove the stream field.
added struct rfc822.
(mbox_get_header_readstream): Removed.
(mbox_header_size): Do the conversion if rfc822 set.
(mbox_body_size): Do the conversion if rfc822 set.
(mbox_get_message): Set the property on the header_t.
* mailbox/mbx_pop.c (pop_init): Set its default properties.
(pop_open): Remove MU_STREAM_POP flag obsolete.
(pop_readline): Do the conversion if rfc822 is set.
* mailbox/mbx_imap.c (mbx_imap_init): Set its default properties.
* mailbox/folder_imap.c (folder_imap_open): Remove MU_STREAM_IMAP,
no longer pertinent.
(imap_readline): If property rfc822 is set don't strip '\r'.
* mailbox/header.c (header_set_property): New functions.
(header_get_property): New functions.
(header_destroy): Destroy property object.
(header_get_value): If property rfc822 is set
convert all "\n" to "\r\n".
(header_read): If property rfc822 is et convert to \n to \r\n.
(header_readline): If property rfc822 is et convert to \n to \r\n.
(fill_blurb): Clear the function overloading, when the blurb is fill.
* mailbox/include/header0.h: New field property.
* include/mailutils/header.h: Added prototypes for
header_set_property and header_get_property.
* include/mailutils/stream.h: Remove the identification macros;
MU_STREAM_IMAP, MU_STREAM_FILE, MU_STREAM_POP, it is part of the
properties of each object.
* mailbox/mailer.c (mailer_destroy): Free the properties.
* mailbox/mailer.c (mailer_get_property): New function, return the
property of the mailbox.
* mailbox/smtp.c (_mailer_smtp_init): Set its default properties.
* mailbox/sendmail.c (_sendmail_init): Set its default properties.
* mailbox/include/Makefile.am: Add property0.h.
2001-03-09 Sam Roberts
* include/mailutils/address.h: api for new parser,
address_create0(), and to get route, local-part, and domain.
* mailbox/address.c: implementation of 3 new get functions, first
cut, needs cleanup
* mailbox/include/address0.h: new members of _address, deleted
one that looked unused.
* mailbox/parse822.c: implementation of address_create0(),
which handles groups, routes, and the hoary old comment phrase
* addr/addr.c - parses addresses from its command line or
stdin using create() or create0().
* mailbox/mbx_imap.c: need strings.h on some systems, like Nto
2001-03-12 Sam Roberts
* frm/frm.c (main): Changed to only print subject if
header_get_value(SUBJECT) returned success, otherwise I assume
it would print the stack.
(usage): Corrected a tiny typo in usage message.
(long_options): Added an option -f,--field that prints the named field
in the mailbox, and nothing else.
2001-03-09 Alain Magloire
* mailbox/Makefile.am: add property.c in the src list.
* doc/mailutils.texi: add Sam to the list of acknowledgment.
2001-03-09 Sam Roberts
* doc/address.texi: documented all the functions in address.h
* doc/url.texi: corrected location or url.h header
2001-03-08 Sam Roberts
* README-alpha: Be clearer on how to configure.
* doc/address.texi : New File, description of address_t object.
* doc/mailutils.texi : add include address.texi.
2001-03-03 Alain Magloire
* imap4d/fetch.c (fetch_operation) : HEADER.FIELDS.NOT implemented.
fetch_operation() take a new argument.
* imap4d/util.c (util_upper) : New function string upper.
* mailbox/heder.c: Added new functionality to help the imap4d
fetch command.
(header_get_field_count) : New function returns the number of header
fields in the header.
(header_get_field_name): New function returns the field name.
(header_get_field_value): New function returns the field value.
2001-03-03 Alain Magloire
* include/mailutils/address.h: s/_cplusplus/__cplusplus/g
(include/mailutils/auth.h): Likewise.
(include/mailutils/body.h): Likewise.
(include/mailutils/debug.h): Likewise.
(include/mailutils/header.h): Likewise.
(include/mailutils/iterator.h): Likewise.
(include/mailutils/list.h): Likewise.
(include/mailutils/mailer.h): Likewise.
(include/mailutils/message.h): Likewise.
(include/mailutils/mime.h): Likewise.
(include/mailutils/observer.h): Likewise.
(include/mailutils/property.h): Likewise.
(include/mailutils/registrar.h): Likewise.
(mailbox/include/address0.h): Likewise.
(mailbox/include/auth0.h): Likewise.
(mailbox/include/body0.h): Likewise.
(mailbox/include/debug0.h): Likewise.
(mailbox/include/header0.h): Likewise.
(mailbox/include/iterator0.h): Likewise.
(mailbox/include/list0.h): Likewise.
(mailbox/include/mailer0.h): Likewise.
(mailbox/include/message0.h): Likewise.
(mailbox/include/mime0.h): Likewise.
(mailbox/include/observer0.h): Likewise.
Pointed by Sam Roberts.
2001-02-28 Alain Magloire
* mailbox/address.c (address_get_personal): Remove surrounding quotes.
* mailbox/mbx_mbox.c (mbox_scan): If the mailbox is updated don't
rescan again.
(mbox_expunge): Same the uidvalidity in the header field "IMABase:"
on the first message of the mailbox.
* imap4d/fetch.c (fetch_envelope): Envelope imap4 command implemented.
(fetch_send_address): New function.
2001-02-26 Alain Magloire
* mailbox/mbx_imap.c (imap_submessage_size): New function to
retrieve message size of attachments.
* imap4d/fetch.c: More functionality for the FETCH command.
(fetch_operation): New operation.
* imap4d/util.c (util_token): little helper function.
2001-02-25 Alain Magloire
* lib/strtok_r.c: If there are no delimiters left save the old string
and return NULL.
* mailbox/folder_imap.c (imap_fetch): Finish imap FETCH command.
(imap_rfc822): New Function.
(imap_rfc822_text): New Function.
(imap_rfc822_size): New Function.
(imap_rfc822_header): New Function.
(imap_uid): New Function.
(imap_body): New Function.
(imap_bodystructure0): Save the size.
2001-02-22 Alain Magloire
* mailbox/property.c: New file.
* include/mailutils/property.h: New file.
* mailbox/mailbox.c (mailbox_get_property): New function,
a first draft to let set "property" on a mailbox that can
change its behaviour.
* mailbox/include/mailbox0.h: New field in struct _mailbox, property.
* sieve/lex-sieve.lex: Add LGPL banner.
* sieve/gram-sieve.y: Add LGPL banner.
2001-02-22 Alain Magloire
* sieve: New Directory.
* sieve/lex-sieve.lex: RFC3028 tokenizer.
* sieve/gram-sieve.y: RFC3028 grammar.
2001-02-20 Alain Magloire
* mailbox/mailbox.c (mailbox_set_ticket): Those objects are now part
of the folder if a folder is attached to the mailbox.
(mailbox_set_authority: Likewise.
(mailbox_set_stream): Likewise.
* mailbox/mbx_imap.c (imap_message_read): If offset == 0, reset
the lines to 0.
(imap_body_read): Likewise.
2001-02-19 Alain Magloire
* mailbox/mbx_pop.c (pop_body_read): Move the CHECK_BUSY higher
it should be the first thing done. If the state is POP_NO_STATE
reset the offset and the size to 0 i.e we are starting fresh.
(pop_header_read): Likewise.
(pop_message_read): Likewise.
* mailbox/stream.c (stream_write): Don't call stream_flush().
2001-02-04 Alain Magloire
* mailbox/message.c (message_get_uid): Add message_get_uid() for
the UID of the message (IMAP definition) and message_get_uidl() for
the POP3 definition.
* mailbox/attachment.c: Indentation fixes.
* mailbox/file_stream.c: Make sure that the FILE* is close before opening.
* mailbox/folder_imap.c: Use strcasecmp() not strcmp().
* mailbox/mailbox.c: Added mailbox_uidnext() and mailbox_uidvalidity.
* mailbox/mapfile_stream.c: When munmap() failed we should check
against MAP_FAILED, not NULL.
* mailbox/mbx_imap.c: Implement imap_uidnext(), imap_uidvalidity()
imap_message_uid().
* mailbox/mbx_mbox.c: Implement mbox_uidnext(), mbox_uidvalidity()
mbox_message_uid().
* mailbox/mbx_mboxscan.c: Implement uidvalidity, it is save int the
header of the first message, "X-IMAPbase: 127673838 12", a la c-client.
Save UID, it is save in "X-UID".
* mailbox/mbx_pop.c: Implement pop_messages_recent(),
pop_message_unseen() and pop_uid().
* mailbox/trans_stream.c: Indentation fixes.
* include/mailutils/message.h: New prototypes message_get_uid(),
message_set_get_uid().
* include/mailutils/mailbox.h: New prototypes mailbox_uidnext(),
mailbox_uidvalidity().
* lib/snprintf.c lib/snprintf.h: Put it under the LGPL term.
* mailbox/imap4d/fetch.c: First draft implementation, very yucky.
* mailbox/imap4d/select.c: First draft implementation.
* mailbox/imap4d/util.c: Add util_msgset() and util_send().
Reuse of util_getcommand() for subcommands.
* mailbox/pop3d/uidl.c: API change the call is message_get_uidl()
to have UIDL POP3.
2001-02-03 Alain Magloire
* mailbox/mailbox.c mailbox/mbx_mbox.c mailbox/mbx_imap.c:
Implement mailbox_messages_recent() and mailbox_message_unseen(), this
time as define by the IMAP rfc.
2001-02-02 Alain Magloire
* mailbox/header.c: ENOENT was not return if the header was
not found.
* mailbox/mbx_mbox.c: When expunging check to see if the registar
the path_record too.
2001-02-02 Alain Magloire
* pop3d/extra.c (pop3_readline): Since the length of the string
is known, we can use memcpy() and friends for string manipulations.
memXXX() functions are builtin in GNU C (gcc) and are much faster
then the strXXX() counterparts. Small change in the loop to take
advantage of this.
* pop3d/quit.c: The rfc1939 insist that after a QUIT, we must
release any resources and close the connection:
"Whether the removal was successful or not, the server
then releases any exclusive-access lock on the maildrop
and closes the TCP connection." This was not done if error
occurred while expunging, now we will close the connection and
notify the client of the error(ERR_FILE).
2001-02-01 Alain Magloire
"Premature Optimization Is The Root Of All Evil", Knuth.
* mailbox/attachment.c: Typo should be "Content-Disposition"
* mailbox/mbx_mbox.c mailbox/mbx_mboxscan.c mailbox/header.c:
Attempt to optimize the header, header_get_fvalue() is created,
The mailbox save/cache the most common headers, when doing a
header_get_value(), header_get_fvalue() is call first hoping
that the requested header was cache, if it fails we fall back
to the usual parsing. The common elected headers are : From,
To, Cc, Subject, Date, Content-Type, X-UIDL, X-UID.
* mailbox/mailbox.c mailbox/mbx_mbox.c mailbox/mbx_imap.c:
I've confuse the semantic of "unseen" and "recent", "unseen"
means new mail, not recent. Renamed mailbox_recent_count()
to mailbox_unseen_count().
* include/mailutils/mailbox.h: updated for mailbox_unseen_count()
2001-01-25 Alain Magloire
* frm/frm.c: Forget to add --summary option and fix return status.
When being very quiet just freopen(/dev/null, w, stdout).
2001-01-25 Alain Magloire
* pop3d/capa.c: Add UIDL in the capability list.
and update Copyright.
* pop3d/pop3d.c: Remove mbox_record register, only need path_record.
* pop3d/retr.c: When retrieve a message should be mark as read.
since we do not strip out the header "Status:".
* pop3d/top.c: Adjust stream_readline().
2001-01-25 Alain Magloire
While working on the new version of the API mailbox, ChangeLog was
discontinued, since the API could literally change overnight a
maintenance of the entries were of a particular burden.
The API of the library, and some utilities like pop3d are
stable enough to restart normal entries.
* mailbox/*: New Api to access mailbox.
* include/mailutils: Public prototypes of the API.
* frm/frm.c frm/Makefile.am: A clone of elm frm utility.
* from/from.c from/Makefile.am: A utility to scan mailboxes.
* pop3d/* : GNU pop3d server.
2000-05-19 Sean 'Shaleh' Perry <shaleh@debian.org>
* libmailbox/mh.c: fleshed out mh_open() some more
2000-05-18 Sean 'Shaleh' Perry <shaleh@debian.org>
* libmailbox/mh.c: fleshed out mh_open() some more
2000-05-15 Sean 'Shaleh' Perry <shaleh@debian.org>
* libmailbox/*: ran some files thru emacs indent, I think I introduced
some oddness with vi
* libmailbox/mh.[ch]: new files, based on maildir
the mh work is very empty -- just mh_open right now
2000-04-19 Jeff Bailey <jbailey@nisa.net>
* configure.in: Test for limits.h and inttypes.h, add malloc
and realloc checks.
* m4/: New directory
* m4/Makefile.am: New file to support directory
* m4/malloc.m4: File to support lib/ directory
* m4/realloc.m4: File to support lib/ directory
* lib/Makefile.am: Distribute xalloc.h
* lib/xalloc.h: New file to support xmalloc.c
* lib/xmalloc.c: New version from sh-utils-2.0g
* autogen.sh: Look in m4 for extra macros
* doc/Makefile.am: Rearrange to quiet automake
2000-03-28 Jakob 'sparky' Kaivo <jkaivo@elijah.nodomainname.net>
* pop3d/pop3d.c (main): handle SIGPIPE
2000-01-19 Sean 'Shaleh' Perry
* mailbox/mbx_mh.c: some more code fleshing, still ugly
* README README-alpha: updates, corrected README to list mailbox as LGPL
2000-01-19 Sean 'Shaleh' Perry
* mailbox/mbx_mh.c: new file
no header, no error checking, no hable englais
* url/url_mh.[ch]: new files
url support for MH mailboxes
2000-01-17 Sean 'Shaleh' Perry
* examples/from.c: remove extraneous copyright notice
1999-12-15 Alain Magloire
* url/url_mbox.h url/url_pop.h url/url_imap.h url/url_mailto.h
New files.
1999-12-01 Alain Magloire
* url/_cpystr.c url/chewurl.c url/url.c url/url_imap.c
url/url_mailto.c url/url_mbox.c url/url_pop.c : New files,
first attempt to define the URL API.
* lib/Makefile.am: added xmalloc.c, xstrdup.c, xstrtol.{c,h}
* lib/xmalloc.c lib/xstrdup.c lib/xstrtol.c lib/xstrtol.h : New files
1999-11-21 Jeff Bailey
* doc/rfc*: Add. Standards followed should be included here.
1999-11-23 Jakob 'sparky' Kaivo
* TODO: Mention Maildir
* libmailbox/mailbox.c (mbox_init): new function
* libmailbox/maildir.h: new file
* libmailbox/maildir.c: new file
* libmailbox/mailbox.c (mbox_open): uncommented maildir_open attempt
1999-11-15 Jeff Bailey
* lib/ansi2knr.c lib/ansi2knr.h: Add
* configure.in: Add AM_C_PROTOTYPES
* libmailbox/Makefile.am: Add ansi2knr handling
1999-11-08 Sean 'Shaleh' Perry
* cleaned up some of the automake autoconf magic for non-Linux
1999-11-07 Sean 'Shaleh' Perry
* TODO: restructuring, now split into sections
* libmailbox/mailbox.c libmailbox/mailbox.h: added two new functions
to the api and began implementing them in unixmbox
is_updated() => has this mailbox been updated externally?
scan() => build info on mailbox, removing old data as needed
currently not implemented
1999-11-06 Sean 'Shaleh' Perry
* libmailbox/mailbox.c: more work on expunge
* libmailbox/mailbox.c: added a tester routine
* Makefile.am: added -g
1999-11-06 Sean 'Shaleh' Perry
* libmailbox/unixmbox.c: work on expunge
use read/write along with lseek still blows up -- getting there
* mail/mail.c: check return value of mbox_open()
1999-10-23 Alain Magloire
* ChangeLog: Cleanup according to GNU std, and remove
of email addresses. The emails should be AUTHORS or THANKS
so if they change no need to sed everything.
1999-10-11 Jeff Bailey
* libmailbox/Makefile.am: Remove no-install option, add -pedantic
1999-10-12 Sean 'Shaleh' Perry
* made sure that the imap4 was REALLY broken
1999-10-11 Jeff Bailey
* imap4d/Makefile.am: New file
* configure.in: Create imap4d/Makefile, and no install option
for library
* pop3d/Makefile.am: Add warnings, remove unneeded variable
* TODO: Update
* impa4rev1/: Rename to imap4d. (I asked first, really I did...)
* lib/Makefile.am: Update for new files
* lib/getline.c: New File
* lib/getline.h: New file
1999-10-11 Sean 'Shaleh' Perry
* added my imap code -- PLEASE DO NOT TOUCH
1999-10-10 Jeff Bailey
* THANKS: New file
* doc/mailutils.texi: New File
Provided by Alain Magloire <alainm@rcsm.ece.mcgill.ca> with some
changes so that Makeinfo reports no errors.
* doc/Makefile.am: New file
* configure.in: Deal with libsrc to lib rename
* pop3d/Makefile.am: Deal with libsrc to lib rename
* Makefile.am: Deal with libsrc to lib rename.
Add reference to doc/ subdirectory.
* libsrc/: Rename to lib/
1999-10-09 Sean 'Shaleh' Perry
* Made changelog.pl output in approved format -- I miss the time stamp
1999-10-09 Sean 'Shaleh' Perry
* added examples/gnu-pop3d.pam
1999-10-08 Jeff Bailey
* doc/: New directory
* pop3d/Makefile.am: Remove pam detection, now handled by configure
in the @AUTHLIBS@ spot.
* configure.in: Detect pam correctly/handle crypt case correctly
Add option: --disable-pam
* acconfig.h: New File
1999-10-08 Sean 'Shaleh' Perry
* added showmail.c to examples
* libmailbox: some minor code cleanups
1999-10-08 Sean 'Shaleh' Perry
* fixed the "if empty mailbox, return not implemented"
NB: seems there was a large assumption being made:
if unixmbox_open() failed, it was because it was not mbox
this was wrong for many reasons, so on actual "not mbox",
return EBADMSG.
Prolly want to come up with a better error, but this works for now
* more cleaning in the mailbox code
a) added stat() call -- we can bomb earlier, plus detect if
passed object is a directory or file
b) unixmbox_close() free()'s mbox. This will hamper the use
when we add support for more mailboxes later. Need to find
a solution. Perhaps a unixmbox_free() call.
There was also a small leak there -- mbox->name was being left.
c) To aid checking in unixbox_open(), added checks around fgets call.
Now properly detects EOF, errors, etc. This was a large cause of the
spurious "not implemented" bug.
d) all of unixmbox_open()'s function calls should now be checked
NB: need to do the same for rest of file
1999-10-07 Sean 'Shaleh' Perry
* removed spurious code in from.c
* added TODO file
1999-10-07 Jeff Bailey
* Makefile.am: Compile libsrc/ first.
* pop3d/Makefile.am: Link properly with crypt and libmailutils.a
from libsrc/
* libsrc/Makefile.am: Produce one library for all functions.
Do not use libtool for this library, it will never be shared.
* configure.in: Remove AM_MAINTAINER_MODE. Export crypt detection
to Makefiles
1999-10-07 Sean 'Shaleh' Perry
* included my read_a_line() in examples/
1999-10-06 Sean 'Shaleh' Perry
* Cleanup some compilation issues
* changed "w+" to "w" in called to pop3_mainloop():ofile = fdopen()
why was it called with w+? It is only ever used for writing.
* catch EINTR in call to accept() (play nice w/ our UNIX friends)
* set SO_REUSEADDR on daemon's socket
1999-10-05 Sean 'Shaleh' Perry
* Added changelog.pl so we can have automated entries
set CVS_EMAIL=me@here.com and CVS_FULLNAME="Joe Blow"
usage: changelog.pl "added signal.c" or changelog.pl, an editor will
then appear (uses $VISUAL and $EDITOR)
the format is controlled simply via the format call at the end
and the section of perl code directly above it
1999-10-05 Sean 'Shaleh' Perry
* added pop3d/signal.c -- contains pop3_sigchld() currently
1999-10-05 Sean 'Shaleh' Perry
* initial fork() rewrite, not even compiled it yet
1999-10-04 Sean 'Shaleh' Perry
* changed lock(int mode) to lock(mailbox_lock_t mode), this will allow
the type to be changed later without affecting code compatibility
* added name to AUTHORS
* noticed mention of IMAP4 server and went back to coding it (-:
1999-10-03 Jeff Bailey
* mail/mail.c: Support --help, --version.
* mail/Makefile.am: Add -Wall to compile line.
* libmailbox/Makefile.am: Add -Wall to compile line.
* libmailbox/mailbox.c: Warning cleanup, second parameter of lock
should be unsigned int, not int.
* libmailbox/mailbox.h: ""
* libmailbox/unixmbox.h: ""
* libmailbox/unixmbox.c: ""
* AUTHORS: Include my name. =)
* README: Rewrite for public consumption
* README-alpha: New file, add mailing list address, CVS information.
* libmailbox/unixmbox.c: Include config.h if defined
* libmailbox/mailbox.c: Include config.h if defined
* mail/mail.c: Include config.h if defined, update copyright.
1999-10-01 Sean 'Shaleh' Perry
* added an examples directory and the first example, from.c
1999-10-01 Jakob 'sparky' Kaivo
* libmailbox/*.[ch]: added cleanup patches from Shaleh while he works
on getting CVS access
1999-09-22 Jakob 'sparky' Kaivo
* mail/mail.c (main): added 'f' and 'F' to test mbox_header_line
* pop3d/apop.c (pop3_apop): cleanup, partial rewrite for libmailbox
* pop3d/retr.c (pop3_retr): fixed a potential segfault
* pop3d/user.c (pop3_user): cleanup and use mbox_lock
* libmailbox/mailbox.c (mbox_header_line): new function
(mbox_body_lines): new function
* mail/Makefile.am (mail_DEPENDENCIES): added libmailbox.la
* pop3d/top.c (pop3_top): made it work with libmailbox
* libmailbox/unixmbox.c (unixmbox_open): added check to see if it's
actually an mbox file
(unixmbox_open): Set mbox->_lock to unixmbox_lock
(unixmbox_lock): new function
* libmailbox/unixmbox.h: Added prototype for locking
* libmailbox/mailbox.c: Add dummy initializer for locking
* libmailbox/mailbox.h: Added interface for locking
Added interfaces for mbox_header_line and mbox_body_lines
* pop3d/*.[ch]: changed copyright info to FSF
* libmailbox/*.[ch]: added copyright/licensing info
1999-09-21 Jakob 'sparky' Kaivo
* pop3d/Makefile.am (pop3d_LDADD): add $(AUTHLIBS)
* configure.in: Added libsrc/Makefile to AC_OUTPUT (duh, Jake!)
fixed the PAM and crypt checks
* README: actually put something here, noted necessary tools to build
from CVS
1999-09-14 Jakob 'sparky' Kaivo
* pop3d/pop3d.c (main): moved setgid() call to after option parsing
(main): make --version report PACKAGE and VERSION
* libmailbox/mailbox.c (mbox_open): changed parameter type to const
* pop3d/Makefile.am (INCLUDES): change relative directories to
top_srcdir base
* configure.in: Added checks for PAM and crypt
1999-09-13 Jakob 'sparky' Kaivo
* pop3d/retr.c (pop3_retr): fixed calls mbox_header => mbox_get_header
and mbox_body => mbox_get_body
* pop3d/user.c (pop3_user): removed references to mailbox variable
* pop3d/stat.c (pop3_stat): fixed mbox->is_deleted => mbox_is_deleted
* pop3d/pop3d.c (pop3_mainloop): removed reference to lockfile variable
* pop3d/extra.c (pop3_abquit): change fclose(mbox) to mbox_close(mbox)
removed calls to free(messages) and pop3_unlock()
* pop3d/dele.c (pop3_dele): fixed call to mbox_delete()
* Makefile.am (SUBDIRS): added pop3d and libsrc
* configure.in: Added checks needed for pop3d/*
made it work with libtool
* libsrc/*: imported from gnu-pop3d tree
* pop3d/*: imported from gnu-pop3d tree
1999-09-11 Jeff Bailey
* libmailbox/unixmbox.h: Do not prefix config.h defines with _
1999-09-10 Jeff Bailey
* */*: Accommodate directory rearrange
Local Variables:
mode: change-log
version-control: never
buffer-read-only: t
End:
|