1. Лучший говнокод

    В номинации:
    За время:
  2. Куча / Говнокод #26287

    0

    1. 01
    2. 02
    3. 03
    4. 04
    5. 05
    6. 06
    7. 07
    8. 08
    9. 09
    10. 10
    11. 11
    12. 12
    13. 13
    14. 14
    15. 15
    16. 16
    17. 17
    18. 18
    19. 19
    20. 20
    21. 21
    22. 22
    23. 23
    24. 24
    25. 25
    26. 26
    27. 27
    28. 28
    29. 29
    30. 30
    31. 31
    32. 32
    33. 33
    34. 34
    35. 35
    36. 36
    37. 37
    38. 38
    39. 39
    40. 40
    41. 41
    42. 42
    43. 43
    44. 44
    45. 45
    46. 46
    47. 47
    48. 48
    49. 49
    50. 50
    51. 51
    52. 52
    53. 53
    54. 54
    55. 55
    56. 56
    57. 57
    58. 58
    59. 59
    60. 60
    61. 61
    62. 62
    63. 63
    64. 64
    <vistefan> In recently installed Manjaro i have this (https://imgur.com/a/e0Prjez) instead of proper AwesomeWM menu called by Super button. Any Ideas? Tried to install additional fonts. Locales are correct.
    <HEX0> !give vistefan manjaro
    <phrik> vistefan: manjaro does things differently from arch, so we can't really support it. ask in #manjaro or ##linux
    <SGOrava> vistefan: you would be fine as long as you do not mention other distributions and pretend to be using Arch, is it that hard ? Even I do that :D
    <SGOrava> vistefan: My idea is that you are missing some fonts or locale...
    <vistefan> SGOrava, :D
    <Scimmia> !give SGOrava notarch
    <phrik> SGOrava: This channel is for Arch Linux support only. Also see https://wiki.archlinux.org/index.php/Code_of_conduct#Arch_Linux_distribution_support_.2Aonly.2A
    <thingfish> you're better off being up front, from the beginning about what you're running.
    <Scimmia> seriously, we don't want you here if you're going to act like a total piece of shit
    <SGOrava> Scimmia: I know sure, but as long as one knows what one can ask here than it is fine
    <Scimmia> no, it's not
    <Scimmia> at all
    <SGOrava> how is it not ?
    <Scimmia> If you're not on Arch, it's not OK, end of story
    <SGOrava> what is wrong with that when one wants to ask a question 
    <Namarrgon> lying about your distro? ban
    <Scimmia> and asking here implies it's Arch, so knowing the rules and asking anyway is lying
    <SGOrava> why be so pedantic ?
    <Namarrgon> we don't like liars
    <SGOrava> that is why I said one needs to know what belongs here and what does not
    <thingfish> people who help in here have a hard enough time supporting actual Arch users.  They don't need to be wasting their time chasing down some issue for other distros, which should have their own support channels.
    <Namarrgon> support for other distros does not belong here
    <SGOrava> Namarrgon: peopúle lie everyday just to survive
    <Namarrgon> that's a shitty excuse
    <cyveris> That's a shitty person.
    <SGOrava> why are you so hostile ?
    <Namarrgon> if you don't like our rules then you there are plenty of other channels that you can join
    <thingfish> because you don't seem to have a clue, dude.
    <Namarrgon> SGOrava: because you are telling other people to lie to the community just to get support
    <SGOrava> I am not, I am telling them to distinguish where the problem is and ask at the source
    <demonicmaniac3> 21:14 < SGOrava> vistefan: you would be fine as long as you do not mention other distributions and pretend to be using Arch, is it that hard ?
    <Scimmia> and if it's not Arch, the problem is not here
    <demonicmaniac3> you are telling them to pretend to use arch when they ask questions
    <Scimmia> SGOrava: sounds like you aren't running arch...
    <SGOrava> I am running Arch, half of the packages comes from Arch repos, so I run Arch
    <Scimmia> So that's a no
    <thingfish> aargh
    <HEX0> !roulette
    * phrik has kicked HEX0 from #archlinux (BANG!)
    <Scimmia> !give SGOrava notarch
    <cyveris> Bold move, cotton.
    * phrik reloads and spins the chambers.
    <phrik> SGOrava: This channel is for Arch Linux support only. Also see https://wiki.archlinux.org/index.php/Code_of_conduct#Arch_Linux_distribution_support_.2Aonly.2A
    <SGOrava> how is it a no ?
    <Scimmia> SGOrava: where do the other half come from?
    <SGOrava> Scimmia: you still would not care
    <Scimmia> yep, not Arch
    <SGOrava> I know what to ask where (mostly)
    <Scimmia> if you're asking here about anything at all, you obviously don't
    <SGOrava> ??
    <Namarrgon> SGOrava: https://wiki.archlinux.org/index.php/Code_of_conduct#Arch_Linux_distribution_support_*only*
    <phrik> Title: Code of conduct - ArchWiki (at wiki.archlinux.org)
    * HEX0 (~HEX0@unaffiliated/hex0) has joined
    <Namarrgon> you can use whatever distro you want but that doesn't mean that we have to put up with your nonsense
    <cyveris> SGOrava: You're not using Arch Linux. You're using some derivative. Hence, this is not the channel for you, and now that everyone here knows you advocate for lying about it to get help, no one will help you.
    <SGOrava> Namarrgon: sorry, it is too long
    <Namarrgon> alright
    <SGOrava> cyveris: nope, it is channel for me when I have problems which are sourced from Arch
    <Scimmia> SGOrava: and now that you know the rules, ask here and get banned
    <SGOrava> Scimmia: what should I ask ?
    <cyveris> And here we go.
    <SGOrava> cyveris: you said I should ask something, so think about it
    <HEX0> stop talking and install arch linux while you can

    vistefan, 29 Декабря 2019

    Комментарии (98)
  3. Си / Говнокод #24763

    +1

    1. 01
    2. 02
    3. 03
    4. 04
    5. 05
    6. 06
    7. 07
    8. 08
    9. 09
    10. 10
    #include <stdio.h>
    
    int main() {
    	switch (3) {
    		for (int i = 3; i > 0; --i) {
    			case 3: printf("%d ololo?\n", i);
    		}
    	}
        return 0;
    }

    О сколько нам открытий чудных
    Готовит просвящения духх...


    Угодайте, что там: https://ideone.com/zbOzGZ

    MasterJoda, 14 Сентября 2018

    Комментарии (98)
  4. C++ / Говнокод #23436

    0

    1. 01
    2. 02
    3. 03
    4. 04
    5. 05
    6. 06
    7. 07
    8. 08
    9. 09
    10. 10
    11. 11
    12. 12
    13. 13
    14. 14
    15. 15
    16. 16
    #include<iostream>
    
    void suka( void(*callback)( void(*)( void(*)() ) ) ) {
        std::cout << "Suka, ";
        callback( suka );
    } 
    
    void blyad( void(*callback)( void(*)( void(*)() ) ) ) {
        std::cout << "Blyad !!!" << std::endl;
        callback( blyad );
    } 
    
    int main() {
        suka( blyad );
        return 0;
    }

    ...

    OlegUP, 20 Октября 2017

    Комментарии (98)
  5. C# / Говнокод #18514

    +125

    1. 01
    2. 02
    3. 03
    4. 04
    5. 05
    6. 06
    7. 07
    8. 08
    9. 09
    10. 10
    11. 11
    public enum ActionTypes
    {
            view = 1, 
            edit = 2, 
            all_view, 
            inc_view = 3, 
            inn_view = 4, 
            order_view = 5, 
            out_view = 6, 
            compl_view = 7
    }

    Три часа искал в чем баг, перерыл весь код, а оказалось...бля...

    dropdatabase, 23 Июля 2015

    Комментарии (98)
  6. Python / Говнокод #17886

    −116

    1. 1
    df[df['reason']=='in-in error sequence']['spider'].value_counts().to_csv('spiders_out-out-seq.csv')

    Страшно?

    kyzi007, 30 Марта 2015

    Комментарии (98)
  7. C++ / Говнокод #17558

    +53

    1. 1
    2. 2
    3. 3
    4. 4
    5. 5
    6. 6
    for (int i = 1; i <= s.Length; ++i) {
        if (s[i] == '/') {
            s = s.SubString(1, i) + s.SubString(i, MaxInt);
            ++i;
        }
    }

    Кручу-верчу запутать хочу. Кто с первого раза догадается, в чём задача кода - получит пирожок с полочки.

    P.S. Строки билдеровские, нумерация с 1. SubString принимает индекс начала и количество символов.

    bormand, 02 Февраля 2015

    Комментарии (98)
  8. C# / Говнокод #16202

    +145

    1. 1
    Ошибка сервера в приложении '/'. Выполнение этой команды требует открытого доступного соединения. Текущее состояние соединения: разорвано. Описание: Необработанное исключение при выполнении текущего веб-запроса. Изучите трассировку стека для получения дополнительных сведений о данной ошибке и о вызвавшем ее фрагменте кода. Сведения об исключении: System.InvalidOperationException: Выполнение этой команды требует открытого доступного соединения. Текущее состояние соединения: разорвано. Ошибка источника: Необработанное исключение при выполнении текущего веб-запроса. Информацию о происхождении и месте возникновения исключения можно получить, используя следующую трассировку стека исключений. Трассировка стека: [InvalidOperationException: Выполнение этой команды требует открытого доступного соединения. Текущее состояние соединения: разорвано.]    System.Data.Objects.ObjectContext. EnsureConnection() +11438147    System.Data.Objects.ObjectContext. CreateFunctionObjectResult (EntityCommand entityCommand, ReadOnlyMetadataCollection`1 entitySets, EdmType[] edmTypes, MergeOption mergeOption) +133    System.Data.Objects.ObjectContext. ExecuteFunction(String functionName, MergeOption mergeOption, ObjectParameter[] parameters) +411    System.Data.Objects.ObjectContext. ExecuteFunction(String functionName, ObjectParameter[] parameters) +78    Dmir.ContentCommon.Entities. ContentCommonDb.ContentGet (Nullable`1 contentID, Nullable`1 isModerator) in D:\Projects \DmirCollection\CommonObject \Dmir.ContentCommon \Dmir.ContentCommon\Entities \Model1.cs:745    Dmir.ContentCommon.Entities. ContentCommonRepository. ContentGet(Guid contentID, Boolean isModerator) in D:\Projects \DmirCollection\CommonObject \Dmir.ContentCommon \Dmir.ContentCommon\Entities \ContentCommonRepository.cs:30    Dmir.ContentCommon.Services. ContentCommonService.ContentGet (Guid contentID, Boolean isModerator)  in D:\Projects\DmirCollection \CommonObject \Dmir.ContentCommon \Dmir.ContentCommon\Services \ContentCommonService.cs:142    Dmir.Realty.Content.MvcApp. Controllers.ContentHelperController. View(Guid contentViewID, Int32 page, Boolean isModerator) in D: \Projects\DmirCollection\WebSite \Dmir.Realty.Content \Dmir.Realty.Content.MvcApp \Controllers \ContentHelperController.cs:211    lambda_method(Closure , ControllerBase , Object[] ) +252    System.Web.Mvc. ReflectedActionDescriptor.Execute (ControllerContext controllerContext, IDictionary`2 parameters) +261    System.Web.Mvc. ControllerActionInvoker. InvokeActionMethod (ControllerContext controllerContext, ActionDescriptor actionDescriptor, IDictionary`2 parameters) +39    System.Web.Mvc.Async.<>c__ DisplayClass42.< BeginInvokeSynchronousActionMethod >b__41() +34    System.Web.Mvc.Async.<>c__ DisplayClass39.< BeginInvokeActionMethodWithFilters> b__33() +124    System.Web.Mvc.Async.<>c__ DisplayClass4f.<InvokeActionMethodF ilterAsynchronously>b__49() +839035    System.Web.Mvc.Async.<>c__ DisplayClass37.< BeginInvokeActionMethodWithFilters> b__36(IAsyncResult asyncResult) +15    System.Web.Mvc.Async.<>c__ DisplayClass2a.<BeginInvokeAction>b __20() +33    System.Web.Mvc.Async.<>c__ DisplayClass25.<BeginInvokeAction>b __22(IAsyncResult asyncResult) +839620    System.Web.Mvc.<>c__ DisplayClass1d.<BeginExecuteCore>b __18(IAsyncResult asyncResult) +28    System.Web.Mvc.Async.<>c__ DisplayClass4.<MakeVoidDelegate>b_ _3(IAsyncResult ar) +15    System.Web.Mvc.Controller. EndExecuteCore(IAsyncResult asyncResult) +65    System.Web.Mvc.Async.<>c__ DisplayClass4.<MakeVoidDelegate>b_ _3(IAsyncResult ar) +15    System.Web.Mvc.Controller. EndExecute(IAsyncResult asyncResult) +51    System.Web.Mvc.<>c__ DisplayClass8.<BeginProcessRequest> b__3(IAsyncResult asyncResult) +42    System.Web.Mvc.Async.<>c__ DisplayClass4.<MakeVoidDelegate>b_ _3(IAsyncResult ar) +15    System.Web.Mvc.MvcHandler. EndProcessRequest(IAsyncResult asyncResult) +51 System.Web.CallHandlerExecutionStep .System.Web.HttpApplication. IExecutionStep.Execute() +606    System.Web.HttpApplication. ExecuteStep(IExecutionStep step, Boolean& completedSynchronously) +288 Информация о версии: Платформа Microsoft .NET Framework, версия:4.0.30319; ASP.NET, версия:4.0.30319.18446

    http://dm-realty.ru/RepairConstruction/View?contentViewID=317f4680-bdb0-4d4e-a423-041a0d833e71

    И нахуй вот это простому пользователю?

    Pythoner, 21 Июня 2014

    Комментарии (98)
  9. PHP / Говнокод #9196

    +163

    1. 1
    2. 2
    3. 3
    4. 4
    foreach($_REQUEST as $_ind => $_val) { $_REQUEST[$_ind] = mysql_real_escape_string($_REQUEST[$_ind]); }
    foreach($_POST as $_ind => $_val) { $_POST[$_ind] = mysql_real_escape_string($_POST[$_ind]); }
    foreach($_GET as $_ind => $_val) { $_GET[$_ind] = mysql_real_escape_string($_GET[$_ind]); }
    foreach($_COOKIE as $_ind => $_val) { $_COOKIE[$_ind] = mysql_real_escape_string($_COOKIE[$_ind]); }

    Защита от инъекций

    ReckO, 22 Января 2012

    Комментарии (98)
  10. PHP / Говнокод #5052

    +145

    1. 1
    Эй, Хренкин, блять твою мать, ты мне так и не ответил, что ты выбираешь мир или войну. Я объясню что тебе предстоит пережить для начала нашествие школоты с лучемётами(решается с помощью каптчи, но при этом потеряешь больше 50% посетителей так как им будет неудобно общаться) далее бесконечные звонки даже среди ночи полный дефейс сайта и как крайняя мера досс-атака(денег на неё у меня хватит не переживай, твой гамна сайт вылетит из индекса и постить тут будут только 3-4 долбоёба), да и ещё пока не буду сообщать будет для тебя сюрпризом(после этого ты повесишься на своих шнурках). Что скажижь Хренкин? Жду ответа. Кому нужен лучемет пишите на [email protected] объясню как работает и т.д.

    Ггг этот мудак удалил мой аккаунт, а я все ещё могу тут постить

    KomprendaTerrorSquad, 25 Декабря 2010

    Комментарии (98)
  11. PHP / Говнокод #4693

    +158

    1. 01
    2. 02
    3. 03
    4. 04
    5. 05
    6. 06
    7. 07
    8. 08
    9. 09
    10. 10
    11. 11
    12. 12
    13. 13
    14. 14
    15. 15
    16. 16
    17. 17
    18. 18
    if (count ( $tag_array )) {
    
    				$tag_array = "(" . implode ( ",", $tag_array ) . ")";
    
    			} else {
    
    				$tag_array = "('undefined')";
    
    			}
    
    			$db->free ();
    
    			$sql_select = "SELECT id, autor, date, short_story, SUBSTRING(full_story, 1, 15) as full_story, xfields, title, category, alt_name, comm_num, allow_comm, allow_rate, rating, vote_num, news_read, approve, flag, editdate, editor, reason, view_edit, tags FROM " . PREFIX . "_post where {$stop_list} AND approve" . $where_date . " ORDER BY " . $news_sort_by . " " . $news_direction_by . " LIMIT " . $cstart . "," . $config['news_number'];
    			$sql_count = "SELECT COUNT(*) as count FROM " . PREFIX . "_post where {$stop_list} AND approve" . $where_date;
    			$allow_active_news = true;
    
    			$tag_array = array ();
    			unset ( $tag_array );

    Все классно... а что в конце.. убило..

    Aios, 20 Ноября 2010

    Комментарии (98)